-
Notifications
You must be signed in to change notification settings - Fork 843
Social: Integrate post list share action with the unified modal #46336
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
Social: Integrate post list share action with the unified modal #46336
Conversation
Updated handleSharePostAction to open the unified modal when the UNIFIED_UI_V1 feature is enabled, otherwise fallback to the original share post modal.
|
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! |
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.
Pull request overview
This PR integrates the post list share action with the unified modal by updating the handleSharePostAction function to conditionally use the new unified modal when the UNIFIED_UI_V1 feature flag is enabled.
Key Changes
- Added feature flag check to conditionally open either the unified modal or the legacy share post modal
- Imported necessary dependencies (
siteHasFeatureandfeatures) to support the feature flag logic - Added changelog entry documenting this integration
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
projects/js-packages/publicize-components/src/components/block-editor/shared-utils.ts |
Updated handleSharePostAction to check the UNIFIED_UI_V1 feature flag and call openUnifiedModal() when enabled, otherwise fallback to openSharePostModal() |
projects/js-packages/publicize-components/changelog/update-social-integrate-post-list-share-action-n-unified-modal |
Added changelog entry documenting this patch-level change |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Code Coverage SummaryCoverage changed in 1 file.
|
gmjuhasz
left a comment
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.
Works well with the feature flag, and also compatible with sites not having it
We allow users to click on the "Share" link from the post list screen which redirects to the editor with resharing modal open.
We need to update that logic to make it work with the unified modal via the feature flag.
Related to #46323
Closes SOCIAL-277
Proposed changes:
handleSharePostActionto open the unified modal when theUNIFIED_UI_V1feature is enabled, otherwise fallback to the original share post modal.Other information:
Jetpack product discussion
Does this pull request change what data or activity we track or use?
Testing instructions: