Shared task board where people and AI coding agents work as teammates. Source-available, self-hostable.
Go
MUL-8988 feat(theme): give floating layers their own border colour (#10359)
Jiayuan Zhangc21565416ce5
diff --git a/docs/theming.md b/docs/theming.mdindex a632a33274..54aa9a2845 100644--- a/docs/theming.md+++ b/docs/theming.md@@ -503,6 +503,7 @@ and dark differ, both defaults are given.| `--menu-item-hover-background` | `var(--accent)` | Highlighted menu item. || `--menu-item-hover-color` | `var(--accent-foreground)` | Text of the highlighted menu item. || `--popover-radius` | `var(--radius)` | Popovers. |+| `--floating-border-color` | `color-mix(in oklab, var(--surface-border), var(--foreground) 6%)` | Hairline around layers that float over the page without a backdrop: menus, popovers, select lists and floating panels. || `--dialog-radius` | `calc(var(--radius) * 1.5)` | Dialogs and alert dialogs. || `--tooltip-radius` | `var(--radius)` | Tooltips. || `--avatar-radius` | `calc(infinity * 1px)` | Avatars. Set a length for square avatars. |diff --git a/packages/core/appearance/theme-variables.ts b/packages/core/appearance/theme-variables.tsindex 3986593d6b..a664f65206 100644--- a/packages/core/appearance/theme-variables.ts+++ b/packages/core/appearance/theme-variables.ts@@ -209,6 +209,7 @@ const CONTROLS: Entry[] = [["menu-item-hover-background", "Highlighted menu item.", "var(--accent)"],["menu-item-hover-color", "Text of the highlighted menu item.", "var(--accent-foreground)"],["popover-radius", "Popovers.", "var(--radius)"],+ ["floating-border-color", "Hairline around layers that float over the page without a backdrop: menus, popovers, select lists and floating panels.", "color-mix(in oklab, var(--surface-border), var(--foreground) 6%)"],["dialog-radius", "Dialogs and alert dialogs.", "calc(var(--radius) * 1.5)"],["tooltip-radius", "Tooltips.", "var(--radius)"],["avatar-radius", "Avatars. Set a length for square avatars.", "calc(infinity * 1px)"],diff --git a/packages/ui/components/ui/context-menu.tsx b/packages/ui/components/ui/context-menu.tsxindex acb571db5c..c243343f6b 100644--- a/packages/ui/components/ui/context-menu.tsx+++ b/packages/ui/components/ui/context-menu.tsx@@ -54,7 +54,7 @@ function ContextMenuContent({><ContextMenuPrimitive.Popupdata-slot="context-menu-content"- className={cn("z-50 max-h-(--available-height) min-w-36 origin-(--transform-origin) overflow-x-hidden overflow-y-auto rounded-menu bg-surface-raised p-1.5 text-popover-foreground shadow-[var(--menu-shadow)] ring-1 ring-surface-border duration-100 outline-none data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95", className )}+ className={cn("z-50 max-h-(--available-height) min-w-36 origin-(--transform-origin) overflow-x-hidden overflow-y-auto rounded-menu bg-surface-raised p-1.5 text-popover-foreground shadow-[var(--menu-shadow)] ring-1 ring-floating-border duration-100 outline-none data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95", className )}{...props}/></ContextMenuPrimitive.Positioner>diff --git a/packages/ui/components/ui/dropdown-menu.tsx b/packages/ui/components/ui/dropdown-menu.tsxindex ecfcad5b10..27121028aa 100644--- a/packages/ui/components/ui/dropdown-menu.tsx+++ b/packages/ui/components/ui/dropdown-menu.tsx@@ -53,7 +53,7 @@ function DropdownMenuContent({e.stopPropagation()onClick?.(e)}}- className={cn("z-50 max-h-(--available-height) min-w-32 origin-(--transform-origin) overflow-x-hidden overflow-y-auto rounded-menu bg-surface-raised p-1.5 text-popover-foreground shadow-[var(--menu-shadow)] ring-1 ring-surface-border duration-100 outline-none data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:overflow-hidden data-closed:fade-out-0 data-closed:zoom-out-95", className )}+ className={cn("z-50 max-h-(--available-height) min-w-32 origin-(--transform-origin) overflow-x-hidden overflow-y-auto rounded-menu bg-surface-raised p-1.5 text-popover-foreground shadow-[var(--menu-shadow)] ring-1 ring-floating-border duration-100 outline-none data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:overflow-hidden data-closed:fade-out-0 data-closed:zoom-out-95", className )}{...props}/></MenuPrimitive.Positioner>@@ -147,7 +147,7 @@ function DropdownMenuSubContent({return (<DropdownMenuContentdata-slot="dropdown-menu-sub-content"- className={cn("w-auto min-w-[96px] rounded-menu bg-surface-raised p-1.5 text-popover-foreground shadow-[var(--menu-shadow)] ring-1 ring-surface-border duration-100 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95", className )}+ className={cn("w-auto min-w-[96px] rounded-menu bg-surface-raised p-1.5 text-popover-foreground shadow-[var(--menu-shadow)] ring-1 ring-floating-border duration-100 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95", className )}align={align}alignOffset={alignOffset}side={side}diff --git a/packages/ui/components/ui/popover.tsx b/packages/ui/components/ui/popover.tsxindex 24d9fb221d..5ee403574e 100644--- a/packages/ui/components/ui/popover.tsx+++ b/packages/ui/components/ui/popover.tsx@@ -45,7 +45,7 @@ function PopoverContent({<PopoverPrimitive.Popupdata-slot="popover-content"className={cn(- "z-50 flex w-72 origin-(--transform-origin) flex-col gap-2.5 rounded-popover bg-surface-raised p-2.5 text-body text-popover-foreground shadow-[var(--menu-shadow)] ring-1 ring-surface-border outline-hidden duration-100 data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95",+ "z-50 flex w-72 origin-(--transform-origin) flex-col gap-2.5 rounded-popover bg-surface-raised p-2.5 text-body text-popover-foreground shadow-[var(--menu-shadow)] ring-1 ring-floating-border outline-hidden duration-100 data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95",className)}{...props}diff --git a/packages/ui/components/ui/select.tsx b/packages/ui/components/ui/select.tsxindex 964726921c..dc0435fbfe 100644--- a/packages/ui/components/ui/select.tsx+++ b/packages/ui/components/ui/select.tsx@@ -98,7 +98,7 @@ function SelectContent({<SelectPrimitive.Popupdata-slot="select-content"data-align-trigger={alignItemWithTrigger}- className={cn("relative isolate z-50 max-h-(--available-height) w-(--anchor-width) min-w-36 origin-(--transform-origin) overflow-x-hidden overflow-y-auto rounded-menu bg-surface-raised text-popover-foreground shadow-[var(--menu-shadow)] ring-1 ring-surface-border duration-100 data-[align-trigger=true]:animate-none data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95", className )}+ className={cn("relative isolate z-50 max-h-(--available-height) w-(--anchor-width) min-w-36 origin-(--transform-origin) overflow-x-hidden overflow-y-auto rounded-menu bg-surface-raised text-popover-foreground shadow-[var(--menu-shadow)] ring-1 ring-floating-border duration-100 data-[align-trigger=true]:animate-none data-[side=bottom]:slide-in-from-top-2 data-[side=inline-end]:slide-in-from-left-2 data-[side=inline-start]:slide-in-from-right-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-open:animate-in data-open:fade-in-0 data-open:zoom-in-95 data-closed:animate-out data-closed:fade-out-0 data-closed:zoom-out-95", className )}{...props}><SelectScrollUpButton />diff --git a/packages/ui/styles/theme-variables.css b/packages/ui/styles/theme-variables.cssindex ef363d59f9..0389d04d72 100644--- a/packages/ui/styles/theme-variables.css+++ b/packages/ui/styles/theme-variables.css@@ -28,6 +28,7 @@--radius-board-card: var(--board-card-radius, var(--radius));--color-page-border: var(--page-border-color, var(--surface-border));+ --color-floating-border: var(--floating-border-color, color-mix(in oklab, var(--surface-border), var(--foreground) 6%));--color-menu-item-hover: var(--menu-item-hover-background, var(--accent));--color-menu-item-hover-foreground: var(--menu-item-hover-color, var(--accent-foreground));--color-nav-item: var(--nav-item-color, var(--muted-foreground));diff --git a/packages/views/chat/components/chat-bar-history.tsx b/packages/views/chat/components/chat-bar-history.tsxindex b2441e8cba..4ecc803a07 100644--- a/packages/views/chat/components/chat-bar-history.tsx+++ b/packages/views/chat/components/chat-bar-history.tsx@@ -78,7 +78,7 @@ export function ChatBarHistory({side="top"sideOffset={8}aria-label={label}- className="max-h-[min(28rem,var(--available-height))] w-80 gap-0 overflow-hidden p-1 ring-foreground/15"+ className="max-h-[min(28rem,var(--available-height))] w-80 gap-0 overflow-hidden p-1"><div className="shrink-0 px-2 py-1.5 text-caption font-medium text-muted-foreground">{label}diff --git a/packages/views/chat/components/chat-window.tsx b/packages/views/chat/components/chat-window.tsxindex aa0b7b8bb3..2bac0728b5 100644--- a/packages/views/chat/components/chat-window.tsx+++ b/packages/views/chat/components/chat-window.tsx@@ -752,7 +752,7 @@ export function ChatWindow() {"absolute z-50 flex flex-col overflow-hidden bg-surface-raised @container",isMobile? "inset-x-0"- : "rounded-xl shadow-[var(--floating-shadow)] ring-1 ring-foreground/15",+ : "rounded-xl shadow-[var(--floating-shadow)] ring-1 ring-floating-border",);// Soft keyboards shrink only the *visual* viewport — the layout viewport// (and this panel's bottom-anchored parent) keeps its full height, sodiff --git a/packages/views/issues/components/issue-peek.tsx b/packages/views/issues/components/issue-peek.tsxindex 6e55903a37..765e6588c0 100644--- a/packages/views/issues/components/issue-peek.tsx+++ b/packages/views/issues/components/issue-peek.tsx@@ -151,7 +151,7 @@ const IssuePeekPanel = memo(function IssuePeekPanel({ issueId }: { issueId: stridata-issue-peek=""className={cn("absolute right-2 top-2 z-30 flex w-[min(var(--issue-peek-width),calc(100%-1rem))] flex-col overflow-hidden",- "rounded-xl bg-background shadow-[var(--floating-shadow)] ring-1 ring-surface-border",+ "rounded-xl bg-background shadow-[var(--floating-shadow)] ring-1 ring-floating-border",// Stops above the chat launcher, which owns the dashboard's// bottom-right corner — the panel's composer would sit under it."above-chat-launcher",diff --git a/packages/views/layout/rail-styles.ts b/packages/views/layout/rail-styles.tsindex b6cec484a3..b38931a122 100644--- a/packages/views/layout/rail-styles.ts+++ b/packages/views/layout/rail-styles.ts@@ -19,7 +19,7 @@ export const LIST_COLUMN_WIDTH_CLASS = "w-[min(var(--list-column-width),40vw)]";/** A collapsed panel or list column previewed over the card's leading edge. */export const NAV_PEEK_CLASS =- "absolute inset-y-0 left-0 z-30 flex w-(--sidebar-width) flex-col overflow-hidden rounded-xl bg-page-canvas shadow-[var(--floating-shadow)] ring-1 ring-surface-border";+ "absolute inset-y-0 left-0 z-30 flex w-(--sidebar-width) flex-col overflow-hidden rounded-xl bg-page-canvas shadow-[var(--floating-shadow)] ring-1 ring-floating-border";export const RAIL_ICON_BUTTON_CLASS ="relative inline-flex size-9 shrink-0 cursor-pointer items-center justify-center rounded-lg text-muted-foreground transition-colors outline-none hover:bg-sidebar-accent/70 hover:text-sidebar-accent-foreground focus-visible:outline-2 focus-visible:outline-ring data-popup-open:bg-sidebar-accent data-popup-open:text-sidebar-accent-foreground aria-[current=page]:bg-sidebar-accent aria-[current=page]:text-sidebar-accent-foreground [&_svg:not([class*='size-'])]:size-[18px]";diff --git a/packages/views/star-prompt/star-prompt.tsx b/packages/views/star-prompt/star-prompt.tsxindex e33357a169..cd8d894aa6 100644--- a/packages/views/star-prompt/star-prompt.tsx+++ b/packages/views/star-prompt/star-prompt.tsx@@ -131,7 +131,7 @@ export function StarPrompt() {aria-live="polite"data-slot="star-prompt"className={cn(- "absolute right-[var(--chat-launcher-inset)] z-50 w-[min(23.75rem,calc(100%-2*var(--chat-launcher-inset)))] rounded-xl bg-surface-raised p-4 pb-3 text-popover-foreground shadow-[var(--floating-shadow)] ring-1 ring-surface-border",+ "absolute right-[var(--chat-launcher-inset)] z-50 w-[min(23.75rem,calc(100%-2*var(--chat-launcher-inset)))] rounded-xl bg-surface-raised p-4 pb-3 text-popover-foreground shadow-[var(--floating-shadow)] ring-1 ring-floating-border","animate-in fade-in-0 slide-in-from-bottom-2 duration-200 motion-reduce:animate-none",launcherVisible ? "above-chat-launcher" : "bottom-[var(--chat-launcher-inset)]",)}