File tree Expand file tree Collapse file tree 2 files changed +23
-0
lines changed
ui/packages/consul-ui/app/templates Expand file tree Collapse file tree 2 files changed +23
-0
lines changed Original file line number Diff line number Diff line change 1+ ```release-note:improvement
2+ ui: Adds a copyable token accessor/secret on the settings page when signed in
3+ ```
Original file line number Diff line number Diff line change @@ -35,6 +35,26 @@ as |item|}}
3535 <A .Title>Local Storage</A .Title>
3636 <A .Description>These settings are immediately saved to local storage and persisted through browser usage.</A .Description>
3737 </Hds::Alert >
38+
39+ <DataSource
40+ @src ={{ uri " settings://consul:token" }}
41+ @onchange ={{ action (mut token ) value =" data" }}
42+ @onerror ={{ action (mut error ) value =" error" }}
43+ />
44+ {{ #if token }}
45+ <Hds::Alert @type =" inline" @color =" highlight" class =" mb-3 mt-2" @icon =" token" as |A|>
46+ <A .Title>Your Access Token</A .Title>
47+ <A .Description>
48+ <Hds::Form::MaskedInput::Field readonly @isContentMasked ={{ false }} @hasCopyButton ={{ true }} @value ={{ token.AccessorID }} as |F|>
49+ <F .Label>Accessor ID</F .Label>
50+ </Hds::Form::MaskedInput::Field >
51+ <Hds::Form::MaskedInput::Field readonly @hasCopyButton ={{ true }} @value ={{ token.SecretID }} as |F|>
52+ <F .Label>Secret ID</F .Label>
53+ </Hds::Form::MaskedInput::Field >
54+ </A .Description>
55+ </Hds::Alert >
56+ {{ /if }}
57+
3858 <form >
3959 {{ #if (not (env ' CONSUL_UI_DISABLE_REALTIME' ))}}
4060 <Disclosure as |disclosure|>
You can’t perform that action at this time.
0 commit comments