Browser: Chrome 137 / Firefox 141
OS: Windows
URLs:
After updating to v2.0-rc2, some styles for elements in components such as SVGs/icons and text are missing. When I inspect the page, I see that these styles have been added inline on Production but are missing on Staging.
Switching the CSS loading method between ‘External files’ and ‘Inline styles’ and clearing the cache several times does not seem to have any effect. Strangely, only the components seem to be affected.
Furthermore, I would actually expect these styles to be included in a stylesheet when ‘External files’ is selected, but that’s perhaps a topic for another day.
Hi @rikhen ,
Can you please send staging site admin credentials to help@bricksbuilder.io so I can follow your component setup and replicate the issue? (Please include this thread URL as a reference)
Regards,
Jenn
1 Like
Done! Thanks for the quick reply @itchycode
Just for clarification: what is the expected place to define styles for components?
I just did a fresh install with only Bricks v2.0-RC2 and created a simple card component. All styles added to this card are being rendered as inline styles inside bricks-frontend-inline-inline-css
inside the <head>
, unless I style them at the ID level!
Is this intentional?
Hi @rikhen ,
Thank you so much for the login details.
I can replicate the issue. (Nested component classes styles not generated in 2.0-rc2)
I have installed a temp fix on your staging site. Can you help check if it’s working correctly?
Regarding the global classes style rendered as inline, it’s the expected behaviour in the current Bricks code base. We had a plan to improve this but we have higher priority tasks to be completed currently. Please follow the thread here WIP: How to transfer bricks-frontend-inline-inline-css styles to a file? - #29 by pmjcreations
Regards,
Jenn
1 Like
Hey @itchycode,
Yes, thank you very much! Your temporary fix does seem to be working. Could you please provide some more information about what you’ve added? Nevertheless, I’ll wait for the update in the next release. I’m sure it will include other minor bug fixes.
Also, thanks for confirming that. I found that thread earlier and was surprised by its creation date.
Hi @rikhen ,
You can check in your staging site. These 2 lines changed.
/includes/assets.php
1 Like