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

Fix: React Customizer controls #606

Merged
merged 1 commit into from
Apr 30, 2024

Conversation

tomusborne
Copy link
Owner

This fixes some Customizer bugs introduced in #600.

Using createRoot caused all of our React-based Customizer controls to break.

To fix this, I had to:

  1. Convert our "wrapper" control to PHP, as createRoot doesn't build HTML in the order you would expect, which caused some of our color controls to no longer be wrapped together on one line.
  2. Prevent our React controls from re-rendering on every setting change. Instead, we update state directly inside the controls.

@tomusborne tomusborne added the bug Bugs, unexpected and weird behaviors label Apr 30, 2024
@tomusborne tomusborne added this to the 3.5.0 milestone Apr 30, 2024
@tomusborne tomusborne merged commit c23bde2 into release/3.5.0 Apr 30, 2024
8 checks passed
@tomusborne tomusborne deleted the fix/customizer-control-render branch April 30, 2024 17:08
@iansvo iansvo mentioned this pull request Jul 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Bugs, unexpected and weird behaviors
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant