2022-07-05 13:41:31 -04:00
|
|
|
{{#if this.collection}}
|
2018-10-15 01:03:53 -04:00
|
|
|
<div class="values">
|
2022-07-05 13:41:31 -04:00
|
|
|
{{#each this.collection as |value index|}}
|
2018-10-15 01:03:53 -04:00
|
|
|
<div class="value" data-index={{index}}>
|
2022-06-30 06:30:50 -04:00
|
|
|
<DButton
|
|
|
|
@action={{action "removeValue"}}
|
|
|
|
@actionParam={{value}}
|
|
|
|
@icon="times"
|
|
|
|
@class="remove-value-btn btn-small"
|
|
|
|
/>
|
2022-07-08 07:00:33 -04:00
|
|
|
<Input
|
|
|
|
@value={{value.key}}
|
|
|
|
class="value-input"
|
|
|
|
{{on "focusout" (fn (action "changeKey") index)}}
|
|
|
|
/>
|
|
|
|
<Input
|
|
|
|
@value={{value.secret}}
|
|
|
|
class="value-input"
|
|
|
|
@type={{if this.isSecret "password" "text"}}
|
|
|
|
{{on "focusout" (fn (action "changeSecret") index)}}
|
|
|
|
/>
|
2018-10-15 01:03:53 -04:00
|
|
|
</div>
|
|
|
|
{{/each}}
|
|
|
|
</div>
|
|
|
|
{{/if}}
|
|
|
|
|
|
|
|
<div class="value">
|
2022-07-05 13:41:31 -04:00
|
|
|
<TextField
|
|
|
|
@value={{this.newKey}}
|
|
|
|
@class="new-value-input key"
|
|
|
|
@placeholder={{this.setting.placeholder.key}}
|
|
|
|
/>
|
|
|
|
<Input
|
|
|
|
@type="password"
|
|
|
|
@value={{this.newSecret}}
|
|
|
|
class="new-value-input secret"
|
|
|
|
placeholder={{this.setting.placeholder.value}}
|
|
|
|
/>
|
2022-06-30 06:30:50 -04:00
|
|
|
<DButton
|
|
|
|
@action={{action "addValue"}}
|
|
|
|
@icon="plus"
|
|
|
|
@class="add-value-btn btn-small"
|
|
|
|
/>
|
2018-10-15 01:03:53 -04:00
|
|
|
</div>
|
2018-11-04 15:18:58 -05:00
|
|
|
|
2022-07-05 13:41:31 -04:00
|
|
|
<SettingValidationMessage @message={{this.validationMessage}} />
|