-
Notifications
You must be signed in to change notification settings - Fork 836
Forms: Add response view actions #45352
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Are you an Automattician? Please test your changes on all WordPress.com environments to help mitigate accidental explosions.
Interested in more tips and information?
|
Thank you for your PR! When contributing to Jetpack, we have a few suggestions that can help us test and review your patch:
This comment will be updated as you work on your PR and make changes. If you think that some of those checks are not needed for your PR, please explain why you think so. Thanks for cooperation 🤖 Follow this PR Review Process:
If you have questions about anything, reach out in #jetpack-developers for guidance! Jetpack plugin: No scheduled milestone found for this plugin. If you have any questions about the release process, please ask in the #jetpack-releases channel on Slack. |
Code Coverage SummaryCoverage changed in 2 files.
Full summary · PHP report · JS report Coverage check overridden by
Coverage tests to be added later
|
This is 🔥! 👏 |
I can't test the read/unread, I suppose due to other PR being open, but I suspect it works well. 🙌 |
be7d29e
to
ec994e0
Compare
const unread = ( | ||
<SVG xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none"> | ||
<Path d="M20.991 9.263c0-.644-.333-1.208-.846-1.52L12 3 3.855 7.742A1.78 1.78 0 0 0 3 9.263v8.947A1.8 1.8 0 0 0 4.8 20h14.4a1.8 1.8 0 0 0 1.8-1.79l-.009-8.947Zm-1.8 0v.01L12 13.736 4.8 9.263 12 5.076l7.191 4.187ZM4.8 18.21v-6.853l7.2 4.491 7.191-4.464.009 6.826H4.8Z" /> | ||
</SVG> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's use @wordpress/icons
instead of shipping our own SVGs.
I pushed improvements:
Modal version will still need more work, we can inject actions in the modal header component directly using ![]() ![]() ![]() ![]() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- Tested previous and new behaviour for sticky/non sticky response sidebar on scrolling long and short messages 👍
- Tested actions mobile/modal/desktop
- Tested last/first items
- Deleting, markign as spam, all correct actions
I fixed several issues (listed in comment above) and there's more work to do on mobile version, but this is good to go now to release.
@ilonagl I think the X comes from upstream DataViews component so would need to be upstream change to remove it. |
Gotcha! Can we change the icon and use the bigger x to keep it consistent with the one on the preview then? |
const handleMoveToTrash = useCallback( async () => { | ||
setIsMovingToTrash( true ); | ||
await moveToTrashAction.callback( [ response ], { registry } ); | ||
setIsMovingToTrash( true ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This needed to be false
, fixed in follow-up.
Proposed changes:
This PR adds action buttons on inbox response view while also improving the response view behavior:
There's still room for improvement, as the selection vs checkbox is still not perfect UX.
Showcase:
Screen.Recording.2025-10-06.at.00.08.51.mov
Other information:
Jetpack product discussion
p1HpG7-xga-p2
13siIQaeu2Q587EzImrUwk-fi-5020_26486
Does this pull request change what data or activity we track or use?
No
Testing instructions:
Load the dashboard inbox. Check the behaviors described on the description.