mirror of https://github.com/status-im/consul.git
ui: Adds localStorage to <html class=""> mapping for user controlled theming (#9496)
This commit is contained in:
parent
b0574c9839
commit
1304dc8820
|
@ -1,11 +1,23 @@
|
||||||
<HeadLayout />
|
<HeadLayout />
|
||||||
{{page-title 'Consul' separator=' - '}}
|
{{page-title 'Consul' separator=' - '}}
|
||||||
|
|
||||||
{{#if (env 'CONSUL_ACLS_ENABLED')}}
|
{{#if (env 'CONSUL_ACLS_ENABLED')}}
|
||||||
{{document-attrs class="has-acls"}}
|
{{document-attrs class="has-acls"}}
|
||||||
{{/if}}
|
{{/if}}
|
||||||
{{#if (env 'CONSUL_NSPACES_ENABLED')}}
|
{{#if (env 'CONSUL_NSPACES_ENABLED')}}
|
||||||
{{document-attrs class="has-nspaces"}}
|
{{document-attrs class="has-nspaces"}}
|
||||||
{{/if}}
|
{{/if}}
|
||||||
|
|
||||||
|
<DataSource
|
||||||
|
@src="settings://consul:theme"
|
||||||
|
as |source|>
|
||||||
|
{{#each-in source.data as |key value|}}
|
||||||
|
{{#if (and value (contains key (array "color-scheme" "contrast")))}}
|
||||||
|
{{document-attrs class=(concat 'prefers-' key '-' value)}}
|
||||||
|
{{/if}}
|
||||||
|
{{/each-in}}
|
||||||
|
</DataSource>
|
||||||
|
|
||||||
{{#if (not-eq router.currentRouteName 'application')}}
|
{{#if (not-eq router.currentRouteName 'application')}}
|
||||||
<HashicorpConsul
|
<HashicorpConsul
|
||||||
id="wrapper"
|
id="wrapper"
|
||||||
|
|
Loading…
Reference in New Issue