consul/ui/packages/consul-ui/app/styles
John Cowen 9eab715149
ui: Move all our icons to use CSS custom properties instead of SASS vars (#10298)
* ui: Move all our icons to use CSS custom properties

The good thing about SASS vars is, if you don't use them they get removed from the final build. Whereas with CSS we have no tree-shaking to get rid of unused CSS custom properties. We can mostly work around this and for some things like colors its no big deal if we have some hex-codes in the build that we don't use as hex-codes are relatively small.

We've been slowly but surely moving all of our colors (and other things) to use CSS custom properties instead of SASS vars now that we have them available.

This commit makes use of the 'tree-shaking' abilities of @extend to ensure that we only compile in the icons that we use.

This commit is mostly churn-less as we already use @extend for the majority of our icons, so generally there is zero change here for working on the UI, but I did spot one single place where we were using SASS vars instead of @extend. This now uses the new form (second commit)

Interestingly this reduces our CSS payload by ~2kb to ~53kb (around 25kb of that is these icons)
2021-06-21 11:54:58 +01:00
..
base ui: Move all our icons to use CSS custom properties instead of SASS vars (#10298) 2021-06-21 11:54:58 +01:00
components ui: Move all our icons to use CSS custom properties instead of SASS vars (#10298) 2021-06-21 11:54:58 +01:00
layouts ui: Side navigation tweaks (#9812) 2021-02-25 09:35:53 +00:00
routes/dc ui: Minor CSS tweaks (#10295) 2021-05-26 14:35:19 +01:00
variables ui: Loader amends/improvements (#10181) 2021-05-07 12:23:29 +01:00
app.scss ui: Sidebar navigation / redesign (#9553) 2021-01-26 17:40:33 +00:00
components.scss ui: %horizontal-kv-list CSS component (and related) (#10285) 2021-06-21 11:40:14 +01:00
debug.scss ui: %horizontal-kv-list CSS component (and related) (#10285) 2021-06-21 11:40:14 +01:00
layout.scss ui: Remove top border from Consul::AuthMethod::List (#10195) 2021-05-07 16:53:09 +01:00
prism-coldark-cold.scss ui: Remove storybook, add docfy (#9831) 2021-03-08 12:22:01 +00:00
prism-coldark-dark.scss ui: Remove storybook, add docfy (#9831) 2021-03-08 12:22:01 +00:00
routes.scss ui: Controller dead code removal (#9367) 2020-12-11 11:43:13 +00:00
themes.scss ui: Side navigation tweaks (#9812) 2021-02-25 09:35:53 +00:00
typography.scss ui: Add information regarding Host header for ingress gateways (#10050) 2021-04-22 12:16:56 +01:00
variables.scss ui: Loader amends/improvements (#10181) 2021-05-07 12:23:29 +01:00