Global Styles: Duplicate slugs aren't handled correctly #57733
Labels
Global Styles
Anything related to the broader Global Styles efforts, including Styles Engine and theme.json
Needs Testing
Needs further testing to be confirmed.
[Status] Stale
Gives the original author opportunity to update before closing. Can be reopened as needed.
[Type] Bug
An existing feature does not function as intended
Taken from #56661 (comment).
#53558 may be related; however, that issue is dealing with duplicate
"size"
properties instead of duplicate"slug"
properties that are being described here.Description
Generating the global stylesheet doesn't filter out duplicates, so the later CSS overrides the earlier. This example shows the issue within a single theme.json
settings.typography.fontSizes
.The issue also extends to overriding defaults as well. You should be able to override default values because
prevent_override
isfalse
inPRESETS_METADATA
, but for some reason that doesn't work. The core defaults are shown and used instead when including these in the theme.jsonsettings.typography.fontSizes
presets.The text was updated successfully, but these errors were encountered: