insightsengineering / teal.slice

Reproducible slice module for teal applications
https://insightsengineering.github.io/teal.slice/
Other
11 stars 5 forks source link

CSS good practices #563

Closed chlebowa closed 6 months ago

chlebowa commented 7 months ago

Our CSS file includes multiple expressions like this: color: var(--bs-body-color, #333333); background-color: var(--bs-gray-200, #e9ecef);

Is overwriting theme colors the proper way to style our elements? Why are we replacing variable values with hard coded values? Should we not rather use the hard coded values directly?

donyunardi commented 7 months ago

bs are custom css values in Bootstrap so if I think this setup automatically change the UI colors for filter panel if they choose to use different Bootstrap themes.

It was added in #165 so maybe @gogonzo can confirm.

chlebowa commented 7 months ago

I don't think he will, styling was an afterthought in that PR :laughing:

chlebowa commented 6 months ago

I just realized I misunderstood the var function. Sorry for raising a ruckus.