b574093cf1
* ui: Loader amends/improvements 1. Create a JS compatible template only 'glimmer' component so we can use it with or without glimmer. 2. Add a set of `rose` colors. 3. Animate the brand loader to keep it centered when the side navigation appears. 4. Tweak the color of Consul::Loader to use a 'rose' color. 5. Move everything loader related to the `app/components/` folder and add docs.
47 lines
994 B
Handlebars
47 lines
994 B
Handlebars
<Route
|
|
@name={{routeName}}
|
|
@title='Consul'
|
|
@titleSeparator=" - "
|
|
>
|
|
|
|
{{#if (env 'CONSUL_ACLS_ENABLED')}}
|
|
{{document-attrs class="has-acls"}}
|
|
{{/if}}
|
|
{{#if (env 'CONSUL_NSPACES_ENABLED')}}
|
|
{{document-attrs class="has-nspaces"}}
|
|
{{/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')}}
|
|
<HashicorpConsul
|
|
id="wrapper"
|
|
@dcs={{dcs}}
|
|
@dc={{or dc dcs.firstObject}}
|
|
@nspaces={{nspaces}}
|
|
@nspace={{or nspace nspaces.firstObject}}
|
|
@onchange={{action "reauthorize"}}
|
|
as |consul|>
|
|
<Outlet
|
|
@name="application"
|
|
@model={{hash
|
|
app=consul
|
|
}}
|
|
as |o|>
|
|
{{outlet}}
|
|
</Outlet>
|
|
<Consul::Loader
|
|
class="view-loader"
|
|
/>
|
|
</HashicorpConsul>
|
|
{{/if}}
|
|
</Route>
|