Description
Custom CSS from a theme.json file à la "styles": { "css": "..." } populates the Additional CSS textarea in the Site Editor.
Any edit to this field (even emptying it) is (rightfully) considered an intentional modification and decouples the field from theme.json defaults.
Whether this is a bug or a feature request, I don't know, but I think there should be a way to go back to theme.json defaults without resetting all other style changes.
Step-by-step reproduction instructions
- Activate a Block theme with custom CSS à la
"styles": { "css": "..." } in its theme.json file.
- Open Site Editor, go to Styles.
- Custom CSS from
theme.json file shows up in the Additional CSS field.
- Once edited and saved, there is no logical way to restore the
theme.json styles other than resetting all style changes.
Screenshots, screen recording, code snippet
No response
Environment info
Please confirm that you have searched existing issues in the repo.
Yes
Please confirm that you have tested with all plugins deactivated except Gutenberg.
Yes
Description
Custom CSS from a
theme.jsonfile à la"styles": { "css": "..." }populates the Additional CSS textarea in the Site Editor.Any edit to this field (even emptying it) is (rightfully) considered an intentional modification and decouples the field from
theme.jsondefaults.Whether this is a bug or a feature request, I don't know, but I think there should be a way to go back to
theme.jsondefaults without resetting all other style changes.Step-by-step reproduction instructions
"styles": { "css": "..." }in itstheme.jsonfile.theme.jsonfile shows up in the Additional CSS field.theme.jsonstyles other than resetting all style changes.Screenshots, screen recording, code snippet
No response
Environment info
Please confirm that you have searched existing issues in the repo.
Yes
Please confirm that you have tested with all plugins deactivated except Gutenberg.
Yes