-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
Add color palette edit functionality to global styles #25711
Add color palette edit functionality to global styles #25711
Conversation
Size Change: +1.73 kB (0%) Total Size: 1.18 MB
ℹ️ View Unchanged
|
Just tested this one 👍 |
38eca3e
to
bfc494a
Compare
There is an important related point: the state of having no user color palette (using the default/theme colors) and the state of the user intentionally setting an empty color palette are different. I added a button to allow the user to remove the user color palette and get back to defaults after removing all the colors. |
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.
Feels nice! Looking forward for the subsequent PRs for the rest of the system.
renderToggle={ ( { isOpen, onToggle } ) => ( | ||
<> | ||
<DropdownOpenOnMount | ||
shouldOpen={ isEditingColorOnMount } | ||
isOpen={ isOpen } | ||
onToggle={ onToggle } | ||
/> |
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.
Interesting :)
Co-authored-by: Miguel Fonseca <[email protected]>
This PR allows the user to configure a global color palette or even a color palette for a specific block.
Limitations
Screenshots
Tests
I added a custom color palette I saved the design and verified the colors were persisted.
I verified I could change the color code, name, and slug of existing colors.
I verified I could remove colors.