Skip to content
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

AlignmentMatrixControl: do not use Composite store #64850

Merged

Conversation

ciampo
Copy link
Contributor

@ciampo ciampo commented Aug 27, 2024

What?

Requires #64832 to be merged first
Extracted from #64723

Refactor AlignmentMatrixControl so that it doesn't use the store from useCompositeStore to function.

Why?

See #63704 (comment)

How?

By controlling the activeId state via props.

Testing Instructions

Make sure that existing usages of AlignmentMatrixControl continue to work as expected.

In particular, make sure that the onChange callback is fired as expected, and that setting value and/or defaultValue props works like on trunk

@ciampo ciampo force-pushed the feat/stabilize-composite/alignment-matrix-control-no-store branch 2 times, most recently from eaeecba to 3ed5268 Compare August 31, 2024 09:19
@ciampo ciampo force-pushed the feat/stabilize-composite/alignment-matrix-control-no-store branch from 3ed5268 to 0170060 Compare August 31, 2024 09:23
@ciampo ciampo self-assigned this Aug 31, 2024
@ciampo ciampo requested a review from a team August 31, 2024 09:28
@ciampo ciampo added [Type] Enhancement A suggestion for improvement. [Package] Components /packages/components labels Aug 31, 2024
@ciampo ciampo marked this pull request as ready for review August 31, 2024 09:28
@ciampo ciampo requested a review from ajitbohra as a code owner August 31, 2024 09:28
Copy link

github-actions bot commented Aug 31, 2024

The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the props-bot label.

If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message.

Co-authored-by: ciampo <[email protected]>
Co-authored-by: tyxla <[email protected]>

To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook.

@ciampo ciampo force-pushed the feat/stabilize-composite/alignment-matrix-control-no-store branch from 3ad9d44 to b01b194 Compare September 2, 2024 12:17
Copy link
Member

@tyxla tyxla left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code LGTM 👍

Works well in storybook and when tested with the Cover block content alignment. ✅

🚀

@ciampo ciampo merged commit ade6863 into trunk Sep 2, 2024
62 checks passed
@ciampo ciampo deleted the feat/stabilize-composite/alignment-matrix-control-no-store branch September 2, 2024 13:07
@github-actions github-actions bot added this to the Gutenberg 19.2 milestone Sep 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
[Package] Components /packages/components [Type] Enhancement A suggestion for improvement.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants