-
Notifications
You must be signed in to change notification settings - Fork 816
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
WordPress 6.8 Compatibility: Replace ButtonGroup usage. #42627
base: trunk
Are you sure you want to change the base?
Conversation
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: The Jetpack plugin has different release cadences depending on the platform:
If you have any questions about the release process, please ask in the #jetpack-releases channel on Slack. |
Are you an Automattician? Please test your changes on all WordPress.com environments to help mitigate accidental explosions.
Interested in more tips and information?
|
Code Coverage SummaryThis PR did not change code coverage! That could be good or bad, depending on the situation. Everything covered before, and still is? Great! Nothing was covered before? Not so great. 🤷 |
Partially fixes #42579
Remaining instances fixed here: #42636
Proposed changes:
ButtonGroup
component in the Map Block with the recommendedToggleGroupControl
, and adds some adjusted styling to more closely match the previous styling.wp.components.ButtonGroup is deprecated since version 6.8. Please use wp.components.__experimentalToggleGroupControl instead
__unstableIsPreviewMode
, now replaced withisPreviewMode
, which also existed in the Map block and is also deprecated as of WordPress 6.8.ButtonGroup
with aFlex
component to more easily keep the styling consistent with the previous style.Other information:
Jetpack product discussion
Does this pull request change what data or activity we track or use?
No.
Testing instructions:
On a self-hosted test site, to replicate the issue on trunk, you will need script debug enabled:
define( 'SCRIPT_DEBUG', true );
inwp-config.php
. Then:__unstableIsPreviewMode
console warning, open up the block selector and hover over 'Map' to view the block preview:cd projects/js-packages/storybook && pnpm run storybook:dev
. Story book should open in a new tab in your current browser.Components
>Split Button
>Default
. Make note of how it looks and behaves.To test the changes, apply this PR locally.
ButtonGroup
component, and the Mapbox Token button should look and behave as expected.__unstableIsPreviewMode
when previewing the Map block.On WoA and Simple: