[wp-trac] [WordPress Trac] #64280: Unable to change the lightbox settings of the Image block within Global Styles when KSES is active
WordPress Trac
noreply at wordpress.org
Thu Nov 20 05:39:32 UTC 2025
#64280: Unable to change the lightbox settings of the Image block within Global
Styles when KSES is active
-------------------------+-------------------------------------------------
Reporter: ramonopoly | Owner: (none)
Type: defect | Status: new
(bug) |
Priority: normal | Milestone: Awaiting Review
Component: Themes | Version: trunk
Severity: normal | Keywords: has-patch has-unit-tests gutenberg-
Focuses: | merge
-------------------------+-------------------------------------------------
This ticket corresponds to the bug report in
https://github.com/WordPress/gutenberg/issues/73157
When KSES filters are active (via `add_action( 'init', 'kses_init_filters'
)`), valid non-preset settings in Global Styles are being incorrectly
filtered out. Specifically:
- `lightbox.enabled` and `lightbox.allowEditing` for Image blocks
The issue occurs because `remove_insecure_settings()` only preserved:
1. Presets (from `PRESETS_METADATA`)
2. Indirect CSS properties (from `INDIRECT_PROPERTIES_METADATA`)
**Step-by-step reproduction instructions**
1. Enable the KSES filters with add_action( 'init', 'kses_init_filters' );
2. Go to Appearance > Editor
3. Open the Styles sidebar
4. Select "Blocks"
5. Select "Image"
6. Change the "Enlarge on click" options
7. Save the changes
⚠️ Note how the changes are reverted
--
Ticket URL: <https://core.trac.wordpress.org/ticket/64280>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list