An open-source, faster Devin alternative
TypeScript
fix(web): visual polish pass from design review
Igor Zalutski3e24a936df89
diff --git a/web/src/assets/logo.svg b/web/src/assets/logo-mark.svgsimilarity index 65%rename from web/src/assets/logo.svgrename to web/src/assets/logo-mark.svgindex c05e33fe..6bd25645 100644--- a/web/src/assets/logo.svg+++ b/web/src/assets/logo-mark.svg@@ -1,8 +1,7 @@-<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 180 32" fill="none">+<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 32 32" fill="none"><rect width="32" height="32" rx="6" fill="#6366F1"/><path d="M8 12L16 7L24 12V20L16 25L8 20V12Z" stroke="white" stroke-width="2" fill="none"/><path d="M16 7V25" stroke="white" stroke-width="1.5" opacity="0.5"/><path d="M8 12L24 20" stroke="white" stroke-width="1.5" opacity="0.5"/><path d="M24 12L8 20" stroke="white" stroke-width="1.5" opacity="0.5"/>- <text x="40" y="22" font-family="system-ui, sans-serif" font-size="16" font-weight="700" fill="#0F172A">OpenComputer</text></svg>diff --git a/web/src/components/app-shell.tsx b/web/src/components/app-shell.tsxindex 769f4292..b13ea7d3 100644--- a/web/src/components/app-shell.tsx+++ b/web/src/components/app-shell.tsx@@ -17,7 +17,7 @@ import {} from 'lucide-react'import { useAuth } from '@/hooks/useAuth'import { logout, getAutumnBilling } from '@/api/client'-import logo from '@/assets/logo.svg'+import logoMark from '@/assets/logo-mark.svg'import { Button } from '@/components/ui/button'import {Sheet,@@ -49,8 +49,11 @@ const NAV: NavItem[] = [function Brand() {return (- <Link to="/" className="flex items-center" aria-label="OpenComputer">- <img src={logo} alt="OpenComputer" className="h-7 w-auto" />+ <Link to="/" className="flex items-center gap-2" aria-label="OpenComputer">+ <img src={logoMark} alt="" className="size-6" />+ <span className="text-foreground text-[15px] font-semibold tracking-tight">+ OpenComputer+ </span></Link>)}@@ -140,24 +143,22 @@ function SidebarBody({ onNavigate }: { onNavigate?: () => void }) {))}</nav>- <div className="border-t p-3">- <div className="mb-2 flex items-center gap-2.5 px-1">- <span className="bg-secondary flex size-7 shrink-0 items-center justify-center rounded-full text-xs font-semibold">+ <div className="space-y-2.5 border-t p-3">+ <div className="flex items-center gap-2.5 px-1">+ <span className="bg-secondary text-muted-foreground flex size-7 shrink-0 items-center justify-center rounded-full text-xs font-medium">{user?.email?.charAt(0).toUpperCase() || '?'}</span><span className="text-muted-foreground truncate text-xs">{user?.email}</span></div>- <Button- variant="ghost"- size="sm"- className="text-muted-foreground w-full justify-start"+ <buttononClick={() => logout()}+ className="text-muted-foreground hover:text-foreground flex items-center gap-2 px-1 text-xs transition-colors">- <LogOut className="size-4" aria-hidden />+ <LogOut className="size-3.5" aria-hidden />Sign out- </Button>+ </button></div></div>)diff --git a/web/src/components/panel.tsx b/web/src/components/panel.tsxindex 87678356..81872b53 100644--- a/web/src/components/panel.tsx+++ b/web/src/components/panel.tsx@@ -6,7 +6,7 @@ export function Panel({ className, ...props }: ComponentProps<'div'>) {return (<divclassName={cn(- 'bg-panel text-card-foreground rounded-lg border shadow-sm',+ 'bg-panel text-card-foreground rounded-lg border',className,)}{...props}diff --git a/web/src/components/ui/table.tsx b/web/src/components/ui/table.tsxindex 22dca015..8f197214 100644--- a/web/src/components/ui/table.tsx+++ b/web/src/components/ui/table.tsx@@ -55,7 +55,7 @@ function TableRow({ className, ...props }: React.ComponentProps<'tr'>) {<trdata-slot="table-row"className={cn(- 'hover:bg-muted/50 has-aria-expanded:bg-muted/50 data-[state=selected]:bg-muted border-b transition-colors',+ 'hover:bg-row-hover has-aria-expanded:bg-row-hover data-[state=selected]:bg-row-selected border-b transition-colors',className,)}{...props}@@ -68,7 +68,7 @@ function TableHead({ className, ...props }: React.ComponentProps<'th'>) {<thdata-slot="table-head"className={cn(- 'text-foreground h-10 px-2 text-left align-middle font-medium whitespace-nowrap [&:has([role=checkbox])]:pr-0',+ 'text-muted-foreground h-11 px-4 text-left align-middle text-xs font-medium whitespace-nowrap [&:has([role=checkbox])]:pr-0',className,)}{...props}@@ -81,7 +81,7 @@ function TableCell({ className, ...props }: React.ComponentProps<'td'>) {<tddata-slot="table-cell"className={cn(- 'p-2 align-middle whitespace-nowrap [&:has([role=checkbox])]:pr-0',+ 'px-4 py-3 align-middle whitespace-nowrap [&:has([role=checkbox])]:pr-0',className,)}{...props}diff --git a/web/src/index.css b/web/src/index.cssindex 4ec82eab..4e1d39e6 100644--- a/web/src/index.css+++ b/web/src/index.css@@ -113,7 +113,7 @@--radius-sm: calc(var(--radius) - 2px);--radius-md: var(--radius);--radius-lg: calc(var(--radius) + 2px);- --radius-xl: calc(var(--radius) + 6px);+ --radius-xl: calc(var(--radius) + 4px);}/* ------------------------------------------------------------------@@ -128,7 +128,7 @@--foreground: hsl(45 8% 8%); /* ink */--primary: hsl(45 8% 8%); /* ink */--primary-foreground: hsl(40 33% 97%); /* paper */- --radius: 0.375rem;+ --radius: 0.25rem; /* sharper corners (was 0.375rem) *//* Raised surfaces (cards, popovers, dropdowns, dialogs) — warm near-white */--card: hsl(40 40% 99%);@@ -153,11 +153,13 @@/* Lines + focus */--border: hsl(40 14% 87%);--input: hsl(40 14% 82%);- --ring: hsl(45 8% 8%); /* ink focus ring (high contrast, on-brand) */+ --ring: hsl(+ 45 5% 48%+ ); /* soft grey focus ring (ink was too heavy on inputs) *//* Table rows */- --row-hover: hsl(40 24% 95%);- --row-selected: hsl(40 30% 92%);+ --row-hover: hsl(40 22% 93%);+ --row-selected: hsl(40 26% 90%);/* Destructive (solid button bg; darker than site 60% for AA white text) */--destructive: hsl(0 70% 45%);@@ -234,10 +236,21 @@--sidebar-accent-foreground: hsl(40 10% 92%);}-/* Minimal base reset — the slice of Preflight shadcn assumes, scoped so it- does not fight theme.css. (box-sizing is already global via theme.css.)- Tailwind border-* utilities need a default style+color to render. */+/* Document font: Inter everywhere — including portaled overlays (dialogs,+ dropdowns, toasts) that render outside the AppShell subtree. Unlayered so it+ wins over the legacy body font during coexistence; per-element `font-mono`+ utilities still override for code/terminal surfaces. */+html,+body {+ font-family: var(--font-sans);+ font-optical-sizing: auto;+}++/* Minimal base reset — the slice of Preflight we still need during coexistence+ (Preflight itself is off so it doesn't fight theme.css). box-sizing is+ already global via theme.css. */@layer base {+ /* border-* utilities need a default style + color to render. */*,::before,::after {@@ -245,4 +258,28 @@border-style: solid;border-color: var(--border);}++ /* Links: no browser-default underline / blue (we style links explicitly).+ Without Preflight the UA would underline every <a>, incl. nav + the logo. */+ a {+ color: inherit;+ text-decoration: inherit;+ }++ /* Form controls inherit the page font — otherwise buttons/inputs fall back+ to the UA system font (the "looks like Arial" effect) instead of Inter. */+ button,+ input,+ optgroup,+ select,+ textarea {+ font-family: inherit;+ font-feature-settings: inherit;+ font-variation-settings: inherit;+ font-size: 100%;+ font-weight: inherit;+ line-height: inherit;+ letter-spacing: inherit;+ color: inherit;+ }}diff --git a/web/src/pages/Dashboard.tsx b/web/src/pages/Dashboard.tsxindex 19baf401..7576e9ae 100644--- a/web/src/pages/Dashboard.tsx+++ b/web/src/pages/Dashboard.tsx@@ -130,7 +130,7 @@ export default function Dashboard() {/></div>- <Panel>+ <Panel className="overflow-hidden"><PanelHeader><PanelTitle>Live sandboxes</PanelTitle>{active.length > 0 ? (@@ -140,24 +140,22 @@ export default function Dashboard() {</span>) : null}</PanelHeader>- <PanelContent>- {loadingRunning ? (- <div className="space-y-2">- <Skeleton className="h-12 w-full" />- <Skeleton className="h-12 w-full" />- </div>- ) : active.length === 0 ? (- <p className="text-muted-foreground py-6 text-center text-sm">- No sandboxes running- </p>- ) : (- <div className="flex max-h-[320px] flex-col gap-1.5 overflow-y-auto">- {active.map((s) => (- <SandboxRow key={s.id} session={s} />- ))}- </div>- )}- </PanelContent>+ {loadingRunning ? (+ <PanelContent className="space-y-2">+ <Skeleton className="h-10 w-full" />+ <Skeleton className="h-10 w-full" />+ </PanelContent>+ ) : active.length === 0 ? (+ <p className="text-muted-foreground px-5 py-8 text-center text-sm">+ No sandboxes running+ </p>+ ) : (+ <div className="max-h-80 divide-y overflow-y-auto">+ {active.map((s) => (+ <SandboxRow key={s.id} session={s} />+ ))}+ </div>+ )}</Panel><Panel className="overflow-hidden">@@ -189,7 +187,7 @@ function SandboxRow({ session }: { session: Session }) {return (<Linkto={`/sessions/${session.sandboxId}`}- className="hover:bg-row-hover flex items-center justify-between rounded-md border px-3 py-2.5 transition-colors"+ className="hover:bg-row-hover flex items-center justify-between px-5 py-3 transition-colors"><div className="flex items-center gap-2.5"><span className="bg-status-running size-1.5 shrink-0 animate-pulse rounded-full" />diff --git a/web/src/pages/Sessions.tsx b/web/src/pages/Sessions.tsxindex 86f99081..839546ba 100644--- a/web/src/pages/Sessions.tsx+++ b/web/src/pages/Sessions.tsx@@ -272,12 +272,6 @@ function ActivityChart({{days.map((day) => {const barHeight =maxCount > 0 ? Math.round((day.count / maxCount) * 110) : 0- const tone =- day.errored > 0- ? 'bg-status-error'- : day.hibernated > 0- ? 'bg-status-hibernated'- : 'bg-foreground/75'return (<divkey={day.date}@@ -285,8 +279,8 @@ function ActivityChart({day.hibernated ? ` (${day.hibernated} hibernated)` : ''}${day.errored ? ` (${day.errored} errors)` : ''}`}className={cn(- 'relative flex-1 rounded-t-sm transition-[height] duration-300',- day.count > 0 ? tone : 'bg-transparent',+ 'bg-foreground/70 relative flex-1 rounded-t-sm transition-[height] duration-300',+ day.count > 0 ? '' : 'bg-transparent',)}style={{ height: day.count > 0 ? Math.max(barHeight, 4) : 0 }}>@@ -311,30 +305,8 @@ function ActivityChart({</div>))}</div>-- {/* Legend */}- <div className="mt-3 flex justify-center gap-4" aria-hidden>- <LegendItem className="bg-foreground/75" label="Sessions" />- <LegendItem className="bg-status-hibernated" label="Hibernated" />- <LegendItem className="bg-status-error" label="Errors" />- </div></div>)}</Panel>)}--function LegendItem({- className,- label,-}: {- className: string- label: string-}) {- return (- <div className="flex items-center gap-1.5">- <div className={cn('size-2 rounded-[2px]', className)} />- <span className="text-muted-foreground text-[10px]">{label}</span>- </div>- )-}