chore: reorganize settings code layout
This commit is contained in:
parent
ece304638f
commit
785d5a663f
12 changed files with 27 additions and 23 deletions
23
app/routes/settings/auth-keys/dialogs/expire-auth-key.tsx
Normal file
23
app/routes/settings/auth-keys/dialogs/expire-auth-key.tsx
Normal file
|
|
@ -0,0 +1,23 @@
|
|||
import Dialog from '~/components/Dialog';
|
||||
import type { PreAuthKey } from '~/types';
|
||||
|
||||
interface ExpireAuthKeyProps {
|
||||
authKey: PreAuthKey;
|
||||
}
|
||||
|
||||
export default function ExpireAuthKey({ authKey }: ExpireAuthKeyProps) {
|
||||
return (
|
||||
<Dialog>
|
||||
<Dialog.Button>Expire Key</Dialog.Button>
|
||||
<Dialog.Panel method="DELETE" variant="destructive">
|
||||
<Dialog.Title>Expire auth key?</Dialog.Title>
|
||||
<input type="hidden" name="user" value={authKey.user} />
|
||||
<input type="hidden" name="key" value={authKey.key} />
|
||||
<Dialog.Text>
|
||||
Expiring this authentication key will immediately prevent it from
|
||||
being used to authenticate new devices. This action cannot be undone.
|
||||
</Dialog.Text>
|
||||
</Dialog.Panel>
|
||||
</Dialog>
|
||||
);
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue