fix(ui): sidebar footer in one row, no user name
This commit is contained in:
@@ -80,50 +80,32 @@
|
|||||||
</nav>
|
</nav>
|
||||||
<div
|
<div
|
||||||
class={cn(
|
class={cn(
|
||||||
"flex flex-col gap-2 border-t",
|
"flex items-center gap-1 border-t",
|
||||||
open ? "p-3" : "items-center p-2"
|
open ? "px-3 py-2" : "flex-col px-1 py-2"
|
||||||
)}
|
)}
|
||||||
>
|
>
|
||||||
<span title="event stream from the gateway (SSE)">
|
<span
|
||||||
|
class={cn(open && "mr-auto")}
|
||||||
|
title="event stream from the gateway (SSE)"
|
||||||
|
>
|
||||||
<LiveDot
|
<LiveDot
|
||||||
detail={gateway.live.detail}
|
detail={gateway.live.detail}
|
||||||
label={open}
|
label={open}
|
||||||
state={gateway.live.state}
|
state={gateway.live.state}
|
||||||
/>
|
/>
|
||||||
</span>
|
</span>
|
||||||
{#if open}
|
<ThemeToggle />
|
||||||
<div class="flex items-center justify-between gap-2">
|
<Button
|
||||||
<span class="truncate text-muted-foreground text-xs">
|
aria-label="Sign out"
|
||||||
{session.user}
|
onclick={signOut}
|
||||||
</span>
|
size="icon-sm"
|
||||||
<div class="flex items-center">
|
title="Sign out"
|
||||||
<ThemeToggle />
|
variant="ghost"
|
||||||
<Button
|
>
|
||||||
aria-label="Sign out"
|
<LogOutIcon class="size-4" />
|
||||||
onclick={signOut}
|
</Button>
|
||||||
size="icon-sm"
|
|
||||||
title="Sign out"
|
|
||||||
variant="ghost"
|
|
||||||
>
|
|
||||||
<LogOutIcon class="size-4" />
|
|
||||||
</Button>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
{:else}
|
|
||||||
<ThemeToggle />
|
|
||||||
<Button
|
|
||||||
aria-label="Sign out"
|
|
||||||
onclick={signOut}
|
|
||||||
size="icon-sm"
|
|
||||||
title="Sign out"
|
|
||||||
variant="ghost"
|
|
||||||
>
|
|
||||||
<LogOutIcon class="size-4" />
|
|
||||||
</Button>
|
|
||||||
{/if}
|
|
||||||
<Button
|
<Button
|
||||||
aria-label={open ? "Collapse sidebar" : "Expand sidebar"}
|
aria-label={open ? "Collapse sidebar" : "Expand sidebar"}
|
||||||
class={open ? "self-end" : ""}
|
|
||||||
onclick={() => ui.toggleNav()}
|
onclick={() => ui.toggleNav()}
|
||||||
size="icon-sm"
|
size="icon-sm"
|
||||||
title="{open ? 'Collapse' : 'Expand'} sidebar (⌘B)"
|
title="{open ? 'Collapse' : 'Expand'} sidebar (⌘B)"
|
||||||
|
|||||||
Reference in New Issue
Block a user