feat(desktop): quick-create profile from rail + pin rail on empty sidebar

- Add a "+" in the profile rail that opens a self-contained CreateProfileDialog
  (name + clone toggle + optional SOUL.md); extract it and ActionStatus from
  the profiles view so both surfaces share one flow.
- Keep the profile rail pinned to the bottom when a profile has no sessions by
  rendering a flex-1 spacer (previously the rail floated up to the nav).
This commit is contained in:
Brooklyn Nicholson 2026-06-04 16:55:16 -05:00
parent b94b3622b5
commit 5df732a355
5 changed files with 209 additions and 161 deletions

View file

@ -0,0 +1,25 @@
import type { ReactNode } from 'react'
import { Check, Loader2 } from '@/lib/icons'
// idle → saving → done label+icon for action buttons (create / rename / delete…).
export function ActionStatus({
state,
idle,
busy,
done,
idleIcon = null
}: {
state: 'done' | 'idle' | 'saving'
idle: string
busy: string
done: string
idleIcon?: ReactNode
}) {
return (
<>
{state === 'saving' ? <Loader2 className="size-4 animate-spin" /> : state === 'done' ? <Check /> : idleIcon}
{state === 'saving' ? busy : state === 'done' ? done : idle}
</>
)
}