mirror of https://github.com/portainer/portainer
feat(ui): ui change for create access token EE-3541 (#7366)
* ui change for create access tokenpull/7391/head
parent
0ba10b44ec
commit
d4d80ed8f7
|
@ -1,6 +1,8 @@
|
||||||
import { PropsWithChildren } from 'react';
|
import { PropsWithChildren } from 'react';
|
||||||
import clsx from 'clsx';
|
import clsx from 'clsx';
|
||||||
|
|
||||||
|
import { Icon } from '@@/Icon';
|
||||||
|
|
||||||
import { Button } from '../Button';
|
import { Button } from '../Button';
|
||||||
|
|
||||||
import styles from './CopyButton.module.css';
|
import styles from './CopyButton.module.css';
|
||||||
|
@ -31,7 +33,7 @@ export function CopyButton({
|
||||||
title="Copy Value"
|
title="Copy Value"
|
||||||
type="button"
|
type="button"
|
||||||
>
|
>
|
||||||
<i className="fa fa-copy space-right" aria-hidden="true" /> {children}
|
<Icon icon="copy" feather /> {children}
|
||||||
</Button>
|
</Button>
|
||||||
|
|
||||||
<span
|
<span
|
||||||
|
@ -41,7 +43,7 @@ export function CopyButton({
|
||||||
'space-left'
|
'space-left'
|
||||||
)}
|
)}
|
||||||
>
|
>
|
||||||
<i className="fa fa-check" aria-hidden="true" />
|
<Icon icon="check" feather />
|
||||||
{displayText && <span className="space-left">{displayText}</span>}
|
{displayText && <span className="space-left">{displayText}</span>}
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -74,7 +74,6 @@ export function CreateAccessToken({
|
||||||
/>
|
/>
|
||||||
</FormControl>
|
</FormControl>
|
||||||
<div className="row mt-5">
|
<div className="row mt-5">
|
||||||
<div className="col-sm-12">
|
|
||||||
<Button
|
<Button
|
||||||
disabled={!!errorText || !!accessToken}
|
disabled={!!errorText || !!accessToken}
|
||||||
onClick={() => generateAccessToken()}
|
onClick={() => generateAccessToken()}
|
||||||
|
@ -83,9 +82,8 @@ export function CreateAccessToken({
|
||||||
</Button>
|
</Button>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
|
||||||
{accessToken && (
|
{accessToken && (
|
||||||
<>
|
<div className="mt-5">
|
||||||
<FormSectionTitle>
|
<FormSectionTitle>
|
||||||
<Trans ns={translationNS}>New access token</Trans>
|
<Trans ns={translationNS}>New access token</Trans>
|
||||||
</FormSectionTitle>
|
</FormSectionTitle>
|
||||||
|
@ -106,7 +104,7 @@ export function CreateAccessToken({
|
||||||
>
|
>
|
||||||
<Trans ns={translationNS}>Done</Trans>
|
<Trans ns={translationNS}>Done</Trans>
|
||||||
</Button>
|
</Button>
|
||||||
</>
|
</div>
|
||||||
)}
|
)}
|
||||||
</WidgetBody>
|
</WidgetBody>
|
||||||
</Widget>
|
</Widget>
|
||||||
|
|
Loading…
Reference in New Issue