2022-05-24 18:02:15 +00:00
|
|
|
<div ...attributes>
|
|
|
|
{{#if @label}}
|
|
|
|
<label for={{@name}} class="is-label">
|
|
|
|
{{@label}}
|
|
|
|
{{#if @helpText}}
|
|
|
|
<InfoTooltip>
|
|
|
|
<span data-test-help-text>{{@helpText}}</span>
|
|
|
|
</InfoTooltip>
|
|
|
|
{{/if}}
|
|
|
|
</label>
|
|
|
|
{{/if}}
|
|
|
|
{{#if this.authMethods.isRunning}}
|
|
|
|
<div>
|
|
|
|
<span class="loader is-inline-block"></span>
|
|
|
|
</div>
|
|
|
|
{{else if this.authMethods.last.value}}
|
|
|
|
<div class="control is-expanded">
|
|
|
|
<div class="select is-fullwidth">
|
|
|
|
<select name={{@name}} id={{@name}} {{on "change" this.change}} data-test-mount-accessor-select>
|
|
|
|
{{#if this.noDefault}}
|
|
|
|
<option value="">Select one</option>
|
|
|
|
{{/if}}
|
|
|
|
{{#each this.authMethods.last.value as |method|}}
|
|
|
|
{{! token type does not need to be authorized via MFA }}
|
|
|
|
{{#if this.filterToken}}
|
|
|
|
{{#if (not-eq method.id "token")}}
|
|
|
|
<option selected={{eq @value method.accessor}} value={{method.accessor}}>
|
|
|
|
{{method.path}}
|
|
|
|
({{if @showAccessor method.accessor method.type}})
|
|
|
|
</option>
|
|
|
|
{{/if}}
|
|
|
|
{{else}}
|
|
|
|
<option selected={{eq @value method.accessor}} value={{method.accessor}}>
|
2022-05-21 00:40:16 +00:00
|
|
|
{{method.path}}
|
2022-05-24 18:02:15 +00:00
|
|
|
({{if @showAccessor method.accessor method.type}})
|
2022-05-21 00:40:16 +00:00
|
|
|
</option>
|
|
|
|
{{/if}}
|
2022-05-24 18:02:15 +00:00
|
|
|
{{/each}}
|
|
|
|
</select>
|
|
|
|
</div>
|
2018-04-03 14:16:57 +00:00
|
|
|
</div>
|
2022-05-24 18:02:15 +00:00
|
|
|
{{else}}
|
|
|
|
<input
|
|
|
|
name={{@name}}
|
|
|
|
id={{@name}}
|
|
|
|
class="input"
|
|
|
|
value={{@value}}
|
|
|
|
placeholder="Mount accessor"
|
|
|
|
{{on "change" this.change}}
|
|
|
|
data-test-mount-accessor-default
|
|
|
|
/>
|
|
|
|
{{/if}}
|
|
|
|
</div>
|