Adds copy button to entity, alias and mfa method ID fields (#28742)

* make id buttons copyable

* add changelog
This commit is contained in:
claire bontempo
2024-10-21 12:48:00 -07:00
committed by GitHub
parent efd6148f43
commit 9097689d2a
4 changed files with 6 additions and 3 deletions

3
changelog/28742.txt Normal file
View File

@@ -0,0 +1,3 @@
```release-note:improvement
ui: Adds copy button to identity entity, alias and mfa method IDs
```

View File

@@ -4,12 +4,11 @@
~}} ~}}
<InfoTableRow @label="Name" @value={{@model.name}} data-test-alias-name={{true}} /> <InfoTableRow @label="Name" @value={{@model.name}} data-test-alias-name={{true}} />
<InfoTableRow @label="ID" @value={{@model.id}} /> <InfoTableRow @label="ID" @value={{@model.id}} @addCopyButton={{true}} />
<InfoTableRow @label={{if (eq @model.identityType "entity-alias") "Entity ID" "Group ID"}} @value={{this.model.canonicalId}}> <InfoTableRow @label={{if (eq @model.identityType "entity-alias") "Entity ID" "Group ID"}} @value={{this.model.canonicalId}}>
<LinkTo <LinkTo
@route="vault.cluster.access.identity.show" @route="vault.cluster.access.identity.show"
@models={{array (if (eq @model.identityType "entity-alias") "entities" "groups") @model.canonicalId "details"}} @models={{array (if (eq @model.identityType "entity-alias") "entities" "groups") @model.canonicalId "details"}}
class="has-text-black is-font-mono"
> >
{{@model.canonicalId}} {{@model.canonicalId}}
</LinkTo> </LinkTo>

View File

@@ -19,7 +19,7 @@
{{/if}} {{/if}}
<InfoTableRow @label="Name" @value={{@model.name}} data-test-identity-item-name={{true}} /> <InfoTableRow @label="Name" @value={{@model.name}} data-test-identity-item-name={{true}} />
<InfoTableRow @label="Type" @value={{@model.type}} /> <InfoTableRow @label="Type" @value={{@model.type}} />
<InfoTableRow @label="ID" @value={{@model.id}} /> <InfoTableRow @label="ID" @value={{@model.id}} @addCopyButton={{true}} />
<InfoTableRow @label="Merged Ids" @value={{@model.mergedEntityIds}}> <InfoTableRow @label="Merged Ids" @value={{@model.mergedEntityIds}}>
<div> <div>
{{#each @model.mergedEntityIds as |id|}} {{#each @model.mergedEntityIds as |id|}}

View File

@@ -60,6 +60,7 @@
</ToolbarActions> </ToolbarActions>
</Toolbar> </Toolbar>
<div class="box is-fullwidth is-sideless is-paddingless is-marginless"> <div class="box is-fullwidth is-sideless is-paddingless is-marginless">
<InfoTableRow @label="ID" @value={{this.model.method.id}} @addCopyButton={{true}} />
{{#each this.model.method.attrs as |attr|}} {{#each this.model.method.attrs as |attr|}}
{{#if (eq attr.type "object")}} {{#if (eq attr.type "object")}}
<InfoTableRow <InfoTableRow