mirror of
https://github.com/kemko/nomad.git
synced 2026-01-01 16:05:42 +03:00
31 lines
905 B
Handlebars
31 lines
905 B
Handlebars
{{!
|
|
Copyright (c) HashiCorp, Inc.
|
|
SPDX-License-Identifier: BUSL-1.1
|
|
~}}
|
|
|
|
{{keyboard-commands this.keyCommands}}
|
|
|
|
{{#if this.system.shouldShowRegions}}
|
|
<span data-test-region-switcher-parent>
|
|
<PowerSelect
|
|
data-test-region-switcher
|
|
@ariaLabel="label-region-switcher"
|
|
@ariaLabelledBy="label-region-switcher"
|
|
@tagName="div"
|
|
@triggerClass={{this.decoration}}
|
|
@options={{this.sortedRegions}}
|
|
@selected={{or this.system.activeRegion 'Select a Region'}}
|
|
@searchEnabled={{false}}
|
|
@onChange={{action this.gotoRegion}} as |region|>
|
|
{{#if this.system.activeRegion}}
|
|
<span class="ember-power-select-prefix">Region: </span>
|
|
{{/if}}
|
|
{{region}}
|
|
</PowerSelect>
|
|
</span>
|
|
{{else if this.system.hasNonDefaultRegion}}
|
|
<div class="navbar-item single-region">
|
|
<span>Region: </span>{{this.system.activeRegion}}
|
|
</div>
|
|
{{/if}}
|