Follow

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use
Contact

Blazor: How to customise colour variables in _root.scss?

It seems that the generated project already has lots of colour variables like --bs-body-bg. Dev.tools say it is in _root.scss, but that file does not seem to exist, and I suspect it is inside of bootstrap.in.css. Can I customise those existing colour variables?

enter image description here

MEDevel.com: Open-source for Healthcare and Education

Collecting and validating open-source software for healthcare, education, enterprise, development, medical imaging, medical records, and digital pathology.

Visit Medevel

>Solution :

It’s coming from scss.

You should have other _XXX.scss. SCSS compiler will make a global CSS file for the whole project. Dev tools present you the origin _root.scss not the compiled CSS.

Find the big CSS file of your project, you will find your variables.

If you know scss and have access to the whole tree of scss and all the files, you can rebuild the global CSS in house.

Other way, you make another CSS file, you put it after the global CSS, and you override definition you need… Not the smartest, but if only some changes to do lot quicker.

Add a comment

Leave a Reply

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use

Discover more from Dev solutions

Subscribe now to keep reading and get access to the full archive.

Continue reading