mirror of
https://github.com/nikdoof/pocket-id.git
synced 2025-12-14 23:32:18 +00:00
fix: layout of OIDC client details page on mobile
This commit is contained in:
@@ -27,15 +27,13 @@
|
|||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<button onclick={onClick}>
|
<Tooltip.Root closeOnPointerDown={false} {onOpenChange} {open}>
|
||||||
<Tooltip.Root closeOnPointerDown={false} {onOpenChange} {open}>
|
<Tooltip.Trigger class="text-start" onclick={onClick}>{@render children()}</Tooltip.Trigger>
|
||||||
<Tooltip.Trigger>{@render children()}</Tooltip.Trigger>
|
<Tooltip.Content onclick={copyToClipboard}>
|
||||||
<Tooltip.Content onclick={copyToClipboard}>
|
{#if copied}
|
||||||
{#if copied}
|
<span class="flex items-center"><LucideCheck class="mr-1 h-4 w-4" /> Copied</span>
|
||||||
<span class="flex items-center"><LucideCheck class="mr-1 h-4 w-4" /> Copied</span>
|
{:else}
|
||||||
{:else}
|
<span>Click to copy</span>
|
||||||
<span>Click to copy</span>
|
{/if}
|
||||||
{/if}
|
</Tooltip.Content>
|
||||||
</Tooltip.Content>
|
</Tooltip.Root>
|
||||||
</Tooltip.Root>
|
|
||||||
</button>
|
|
||||||
|
|||||||
@@ -112,15 +112,15 @@
|
|||||||
</Card.Header>
|
</Card.Header>
|
||||||
<Card.Content>
|
<Card.Content>
|
||||||
<div class="flex flex-col">
|
<div class="flex flex-col">
|
||||||
<div class="mb-2 flex items-center">
|
<div class="mb-2 flex flex-col sm:flex-row sm:items-center">
|
||||||
<Label class="mb-0 w-44">Client ID</Label>
|
<Label class="mb-0 w-44">Client ID</Label>
|
||||||
<CopyToClipboard value={client.id}>
|
<CopyToClipboard value={client.id}>
|
||||||
<span class="text-muted-foreground text-sm" data-testid="client-id"> {client.id}</span>
|
<span class="text-muted-foreground text-sm" data-testid="client-id"> {client.id}</span>
|
||||||
</CopyToClipboard>
|
</CopyToClipboard>
|
||||||
</div>
|
</div>
|
||||||
{#if !client.isPublic}
|
{#if !client.isPublic}
|
||||||
<div class="mb-2 mt-1 flex items-center">
|
<div class="mb-2 mt-1 flex flex-col sm:flex-row sm:items-center">
|
||||||
<Label class="w-44">Client secret</Label>
|
<Label class="mb-0 w-44">Client secret</Label>
|
||||||
{#if $clientSecretStore}
|
{#if $clientSecretStore}
|
||||||
<CopyToClipboard value={$clientSecretStore}>
|
<CopyToClipboard value={$clientSecretStore}>
|
||||||
<span class="text-muted-foreground text-sm" data-testid="client-secret">
|
<span class="text-muted-foreground text-sm" data-testid="client-secret">
|
||||||
@@ -128,23 +128,25 @@
|
|||||||
</span>
|
</span>
|
||||||
</CopyToClipboard>
|
</CopyToClipboard>
|
||||||
{:else}
|
{:else}
|
||||||
<span class="text-muted-foreground text-sm" data-testid="client-secret"
|
<div>
|
||||||
>••••••••••••••••••••••••••••••••</span
|
<span class="text-muted-foreground text-sm" data-testid="client-secret"
|
||||||
>
|
>••••••••••••••••••••••••••••••••</span
|
||||||
<Button
|
>
|
||||||
class="ml-2"
|
<Button
|
||||||
onclick={createClientSecret}
|
class="ml-2"
|
||||||
size="sm"
|
onclick={createClientSecret}
|
||||||
variant="ghost"
|
size="sm"
|
||||||
aria-label="Create new client secret"><LucideRefreshCcw class="h-3 w-3" /></Button
|
variant="ghost"
|
||||||
>
|
aria-label="Create new client secret"><LucideRefreshCcw class="h-3 w-3" /></Button
|
||||||
|
>
|
||||||
|
</div>
|
||||||
{/if}
|
{/if}
|
||||||
</div>
|
</div>
|
||||||
{/if}
|
{/if}
|
||||||
{#if showAllDetails}
|
{#if showAllDetails}
|
||||||
<div transition:slide>
|
<div transition:slide>
|
||||||
{#each Object.entries(setupDetails) as [key, value]}
|
{#each Object.entries(setupDetails) as [key, value]}
|
||||||
<div class="mb-5 flex items-center">
|
<div class="mb-5 flex flex-col sm:flex-row sm:items-center">
|
||||||
<Label class="mb-0 w-44">{key}</Label>
|
<Label class="mb-0 w-44">{key}</Label>
|
||||||
<CopyToClipboard {value}>
|
<CopyToClipboard {value}>
|
||||||
<span class="text-muted-foreground text-sm">{value}</span>
|
<span class="text-muted-foreground text-sm">{value}</span>
|
||||||
|
|||||||
@@ -76,7 +76,7 @@
|
|||||||
</script>
|
</script>
|
||||||
|
|
||||||
<form onsubmit={onSubmit}>
|
<form onsubmit={onSubmit}>
|
||||||
<div class="grid grid-cols-2 gap-x-3 gap-y-7 sm:flex-row">
|
<div class="grid grid-cols-1 md:grid-cols-2 gap-x-3 gap-y-7 sm:flex-row">
|
||||||
<FormInput label="Name" class="w-full" bind:input={$inputs.name} />
|
<FormInput label="Name" class="w-full" bind:input={$inputs.name} />
|
||||||
<OidcCallbackUrlInput
|
<OidcCallbackUrlInput
|
||||||
class="w-full"
|
class="w-full"
|
||||||
|
|||||||
Reference in New Issue
Block a user