One issue I was having with the latest release of sage, is that the styles in wp-reset & common were overriding tailwind utility classes in the Gutenberg editor.
For example, lets say I am using acf composer to make my gutenberg blocks. My simple block contains an h1 containing the classes bg-gray-900 text-gray-200.
Due to the wp-reset styles not being loaded into any layer - they take priority over the tailwind utilities:
My question is: what is the preferred way to handle this?
Im sure i could setup a post css plugin to wrap all the utilities - but that seemed like potential overkill.
The solution I have been working with currently is:
Reminder to read our guidelines and be upfront about what your setup is like — it’s important to know off the bat that you’re using ACF Composer.
Have you looked into what it might look like to contribute support for that in ACF Composer?
I apologize - i had just worked out by deduction that the only changes to my latest setup compared to my previous install, was the latest Sage theme.
I never thought to check the block version until you mentioned it - Ill be submitting a PR to that repo later today to change the API version from within the block generated by ACF Composer.
But based on this post, it feels like there’s still something we need to figure out when someone adds a v2 block to the editor. Will at least mention this gotcha in the docs at a minimum. Thank you for reporting this, and we definitely want to know if there’s anything else you run into while building with Sage 11.
I have same problem with layers. Clean installation, without any plugins, just sage 11 out of the box.
Editor is with iframe, I have only default v3 blocks.
All styles from app.css/editor.css is overridden by other styles without layers.
Unfortunately css doesn’t allow you to change the order so that unassigned styles come before layers, which is really stupid. For now I’ll probably try the solution above
What’s up with your editor showing app.css on the right in your screenshot? How’s that relevant to editor styles? If you’re wanting to style the editor, you should be modifying editor.css
Give us some code that shows us how to reproduce what you’re discussing, because “sage 11 out of the box” implies you’ve made no changes
This topic was originally about the editor not being iframed, which isn’t what you’re running into. Please make a new topic with all the relevant details
Chiming in with an alternative solution to the above. With this stylesheet only being loaded in the editor, I’d possibly lean towards Styling with utility classes - Core concepts - Tailwind CSS and never think about a specificity issue again.