@devries-cameron20 / t3code Mirror · read-only / commits / 3816296021
Fork 0

The best way to control Claude Code, Codex and more from any computer or phone

Mirrored from https://github.com/Camo67/t3code.git

Synced Nov 22, 17:00 UTC

feat(web): UI design overhaul, with the new look behind a Beta toggle (#24865)

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>

Theo Browne committed Oct 25, 2026 at 13:44 UTC 38162960213e4952d6d225c5054c3976234f41e6
59 files changed +583 -269
apps/mobile/src/features/settings/SettingsThreadsRouteScreen.tsx
+2 -2
@@ -179,14 +179,14 @@ function AutoSettleSettingsRows() {
179 <SettingsSection title="Usage limits">
180 <SettingsSwitchRow
181 icon="clock"
182 - label="Auto-resume limited threads"
182 + label="Resume after usage limits"
183 value={uniformMobileSetting(displayTargets, "autoResumeLimitedThreads")}
184 disabled={disabled}
185 onValueChange={(value) => writeToAll({ autoResumeLimitedThreads: value })}
186 />
187 <SettingsSwitchRow
188 icon="clock"
189 - label="Snooze limited threads"
189 + label="Snooze until limits reset"
190 value={uniformMobileSetting(displayTargets, "snoozeLimitedThreads")}
191 disabled={disabled}
192 onValueChange={(value) => writeToAll({ snoozeLimitedThreads: value })}
apps/web/index.html
+2 -1
@@ -398,7 +398,8 @@
398 body {
399 background: #ffffff;
400 color: #262626;
401 - font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
401 + font-family:
402 + -apple-system, BlinkMacSystemFont, "Inter Variable", "Segoe UI", system-ui, sans-serif;
403 }
404
405 html.dark body {
apps/web/package.json
+1
@@ -22,6 +22,7 @@
22 "@dnd-kit/sortable": "^10.0.0",
23 "@dnd-kit/utilities": "^3.2.2",
24 "@effect/atom-react": "catalog:",
25 + "@fontsource-variable/inter": "^5.3.0",
26 "@formkit/auto-animate": "^0.9.0",
27 "@legendapp/list": "catalog:",
28 "@noble/hashes": "catalog:",
apps/web/src/appearanceFonts.ts
+1 -1
@@ -11,7 +11,7 @@ import {
11 } from "@t3tools/contracts";
12
13 export const DEFAULT_SANS_FONT_STACK =
14 - '-apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif';
14 + '-apple-system, BlinkMacSystemFont, "Inter Variable", "Segoe UI", system-ui, sans-serif';
15
16 // Some engines map `ui-monospace` to a proportional font, so prefer concrete names.
17 export const DEFAULT_CODE_FONT_STACK =
apps/web/src/components/BranchToolbar.tsx
+35 -27
@@ -225,11 +225,7 @@ const RunContextSelector = memo(function RunContextSelector({
225 <Tooltip>
226 <TooltipTrigger render={<span className="inline-flex shrink-0" />}>
227 <WorkspaceIcon
228 - className={
229 - isPanel
230 - ? THREAD_DETAILS_PANEL_ICON_CLASS
231 - : cn("size-3 shrink-0", showEnvironmentIndicator && "mx-0!")
232 - }
228 + className={isPanel ? THREAD_DETAILS_PANEL_ICON_CLASS : "size-3 shrink-0 mx-0!"}
229 />
230 </TooltipTrigger>
231 <TooltipPopup>
@@ -241,29 +237,39 @@ const RunContextSelector = memo(function RunContextSelector({
237 </TooltipPopup>
238 </Tooltip>
239 );
244 - const icon = showEnvironmentIndicator ? (
240 + const environmentIcon = (
241 + <Tooltip>
242 + <TooltipTrigger render={<span className="inline-flex shrink-0" />}>
243 + {autoEnvironmentLabel ? (
244 + <ScaleIcon
245 + className={isPanel ? THREAD_DETAILS_PANEL_ICON_CLASS : "size-3 shrink-0 mx-0!"}
246 + aria-hidden="true"
247 + />
248 + ) : (
249 + <EnvironmentMachineIcon
250 + kind={activeEnvironment?.machine ?? "server"}
251 + // Wide machine glyphs need a little more box to match the square row icons.
252 + className={
253 + isPanel
254 + ? cn(THREAD_DETAILS_PANEL_ICON_CLASS, "-mx-px size-4.5")
255 + : "size-3 shrink-0 mx-0!"
256 + }
257 + />
258 + )}
259 + </TooltipTrigger>
260 + <TooltipPopup>{autoEnvironmentLabel ?? activeEnvironment?.label ?? "Run on"}</TooltipPopup>
261 + </Tooltip>
262 + );
263 + const icon = !showEnvironmentIndicator ? (
264 + workspaceIcon
265 + ) : isPanel ? (
266 + environmentIcon
267 + ) : (
268 // Button's SVG margins consume 4px of the gap; mx-0! restores the intended 2px.
269 <span className="inline-flex shrink-0 items-center gap-0.5">
247 - <Tooltip>
248 - <TooltipTrigger render={<span className="inline-flex shrink-0" />}>
249 - {autoEnvironmentLabel ? (
250 - <ScaleIcon
251 - className={isPanel ? THREAD_DETAILS_PANEL_ICON_CLASS : "size-3 shrink-0 mx-0!"}
252 - aria-hidden="true"
253 - />
254 - ) : (
255 - <EnvironmentMachineIcon
256 - kind={activeEnvironment?.machine ?? "server"}
257 - className={isPanel ? THREAD_DETAILS_PANEL_ICON_CLASS : "size-3 shrink-0 mx-0!"}
258 - />
259 - )}
260 - </TooltipTrigger>
261 - <TooltipPopup>{autoEnvironmentLabel ?? activeEnvironment?.label ?? "Run on"}</TooltipPopup>
262 - </Tooltip>
270 + {environmentIcon}
271 {workspaceIcon}
272 </span>
265 - ) : (
266 - workspaceIcon
273 );
274 const triggerContent = (
275 <>
@@ -272,6 +278,8 @@ const RunContextSelector = memo(function RunContextSelector({
278 {autoEnvironmentLabel ??
279 (showEnvironmentIndicator ? (activeEnvironment?.label ?? "Run on") : workspaceLabel)}
280 </ComposerContextLabel>
281 + {/* Trailing in the panel, so every row label starts on the same edge. */}
282 + {isPanel && showEnvironmentIndicator ? workspaceIcon : null}
283 </>
284 );
285
@@ -279,7 +287,7 @@ const RunContextSelector = memo(function RunContextSelector({
287 return (
288 <span
289 className={cn(
282 - "inline-flex h-7 min-w-0 max-w-[48%] flex-initial items-center justify-start gap-1 rounded-md border border-transparent px-1.75 font-normal text-muted-foreground/70 text-xs sm:h-6",
290 + "inline-flex h-7 min-w-0 max-w-[48%] flex-initial items-center justify-start gap-1 rounded-md border border-transparent px-1.75 font-normal text-foreground/70 text-xs sm:h-6 dark:text-muted-foreground",
291 isPanel && "max-w-full",
292 isPanel && THREAD_DETAILS_PANEL_LOCKED_ROW_CLASS,
293 )}
@@ -313,7 +321,7 @@ const RunContextSelector = memo(function RunContextSelector({
321 ].join(" ")}
322 >
323 {triggerContent}
316 - {!isPanel ? <ChevronDownIcon className="size-3 shrink-0 opacity-50" /> : null}
324 + {!isPanel ? <ChevronDownIcon className="size-3 shrink-0 mx-0!" /> : null}
325 </MenuTrigger>
326 <MenuPopup
327 align="start"
@@ -748,7 +756,7 @@ export const BranchToolbar = memo(function BranchToolbar({
756 ref={setStripElement}
757 data-compact={labelsOverflow ? "" : undefined}
758 className={cn(
751 - "gap-1 text-xs font-normal text-muted-foreground/70",
759 + "gap-1 text-xs font-normal text-foreground/70 dark:text-muted-foreground",
760 // Hide empty non-Git strips while retaining host width so controls can reappear as the chat grows.
761 !contextStripVisible && "pointer-events-none invisible absolute inset-x-0 top-full",
762 )}
apps/web/src/components/BranchToolbarBranchSelector.tsx
+2 -4
@@ -721,7 +721,7 @@ export function BranchToolbarBranchSelector({
721 >
722 <GitBranchIcon
723 className={cn(
724 - "size-3 shrink-0 opacity-70",
724 + "size-3 shrink-0",
725 displayMode === "panel" && THREAD_DETAILS_PANEL_ICON_CLASS,
726 )}
727 />
@@ -732,9 +732,7 @@ export function BranchToolbarBranchSelector({
732 className="w-full"
733 />
734 </ComposerContextLabel>
735 - {displayMode !== "panel" ? (
736 - <ChevronDownIcon className="size-3 shrink-0 opacity-50" />
737 - ) : null}
735 + {displayMode !== "panel" ? <ChevronDownIcon className="size-3 shrink-0" /> : null}
736 </ComboboxTrigger>
737 </span>
738 {displayMode === "panel" && prNumber !== undefined && prUrl !== undefined ? (
apps/web/src/components/ChatMarkdown.tsx
+1 -1
@@ -1628,7 +1628,7 @@ function ChatMarkdown({
1628 className={cn(
1629 "chat-markdown w-full min-w-0 [overflow-wrap:anywhere] [word-break:break-word]",
1630 !inline &&
1631 - "text-sm leading-relaxed text-foreground/[calc(80%+var(--appearance-contrast-boost)/5)]",
1631 + "text-sm leading-relaxed text-foreground/[calc(90%+var(--appearance-contrast-boost)/10)]",
1632 className,
1633 )}
1634 data-streaming={componentState.isStreaming ? "" : undefined}
apps/web/src/components/ComposerPromptEditorTiptap.tsx
+2 -2
@@ -1101,7 +1101,7 @@ function ComposerPromptEditorTiptapInner(
1101
1102 const editorAttributes = {
1103 class: cn(
1104 - "composer-tiptap -m-1 block max-h-52 min-h-19.5 overflow-y-auto p-1 whitespace-pre-wrap wrap-break-word bg-transparent leading-relaxed text-foreground focus:outline-none",
1104 + "composer-tiptap -m-1 block max-h-52 min-h-19.5 redesign:min-h-12 overflow-y-auto p-1 whitespace-pre-wrap wrap-break-word bg-transparent leading-relaxed text-foreground focus:outline-none",
1105 className,
1106 ),
1107 "data-testid": "composer-editor",
@@ -1839,7 +1839,7 @@ function ComposerPromptEditorTiptapInner(
1839 {isEmpty && contextRecords.size === 0 && placeholder ? (
1840 <div
1841 className={cn(
1842 - "pointer-events-none absolute inset-0 leading-relaxed text-placeholder/75",
1842 + "pointer-events-none absolute inset-0 leading-relaxed text-placeholder",
1843 placeholderClassName,
1844 )}
1845 >
apps/web/src/components/EnvironmentMachineIcon.tsx
+3 -3
@@ -12,7 +12,7 @@ function LucideLike(props: SVGProps<SVGSVGElement>) {
12 viewBox="0 0 24 24"
13 fill="none"
14 stroke="currentColor"
15 - strokeWidth="2"
15 + strokeWidth="1.75"
16 strokeLinecap="round"
17 strokeLinejoin="round"
18 {...props}
@@ -23,8 +23,8 @@ function LucideLike(props: SVGProps<SVGSVGElement>) {
23 function MacMiniIcon(props: SVGProps<SVGSVGElement>) {
24 return (
25 <LucideLike {...props}>
26 - <rect width="20" height="8" x="2" y="8" rx="2" />
27 - <path d="M6 12h.01" />
26 + <rect width="18" height="12" x="3" y="6" rx="2.5" />
27 + <circle cx="7.5" cy="12" r="1" fill="currentColor" stroke="none" />
28 </LucideLike>
29 );
30 }
apps/web/src/components/GitActionsControl.tsx
+27 -5
@@ -120,6 +120,7 @@ import { getSourceControlPresentation, sourceControlIcon } from "~/sourceControl
120 import { sourceControlClients } from "@t3tools/client-runtime/source-control-clients";
121 import { formatDiffCount } from "@t3tools/client-runtime/diff-count";
122 import { useOpenLink } from "~/browser/useOpenLink";
123 +import { useClientSettings } from "~/hooks/useSettings";
124
125 interface GitActionsControlProps {
126 presentation?: "toolbar" | "menu";
@@ -1151,6 +1152,17 @@ export default function GitActionsControl({
1152 ? (quickAction.hint ?? "This action is currently unavailable.")
1153 : null;
1154 const gitActionProgress = resolveGitActionProgressPresentation(vcsActionState);
1155 + const redesign = useClientSettings((s) => s.redesignEnabled);
1156 + // A fresh draft with nothing to commit, push, or diff hides those rows until there is work.
1157 + const quietEmptyDraft =
1158 + redesign &&
1159 + isPanel &&
1160 + draftId !== undefined &&
1161 + gitActionProgress === null &&
1162 + !gitStatusError &&
1163 + quickAction.disabled &&
1164 + !changesTotals?.insertions &&
1165 + !changesTotals?.deletions;
1166 const pendingDefaultBranchActionCopy = pendingDefaultBranchAction
1167 ? resolveDefaultBranchActionDialogCopy({
1168 action: pendingDefaultBranchAction.action,
@@ -1684,7 +1696,7 @@ export default function GitActionsControl({
1696 {initAction.isPending ? "Initializing..." : "Initialize Git"}
1697 </span>
1698 </ThreadDetailsControl>
1687 - ) : compact && !gitActionProgress && !visibleInlineSuccess ? null : (
1699 + ) : quietEmptyDraft || (compact && !gitActionProgress && !visibleInlineSuccess) ? null : (
1700 <ActionGroup
1701 role="group"
1702 aria-label="Git actions"
@@ -1821,7 +1833,7 @@ export default function GitActionsControl({
1833 </ActionGroup>
1834 )}
1835
1824 - {isPanel && isRepo ? (
1836 + {isPanel && isRepo && !quietEmptyDraft ? (
1837 <ThreadDetailsControl
1838 type="button"
1839 variant="ghost"
@@ -1832,11 +1844,21 @@ export default function GitActionsControl({
1844 >
1845 <FileDiffIcon className={THREAD_DETAILS_PANEL_ICON_CLASS} aria-hidden />
1846 <span className={cn("flex-1 text-left", THREAD_DETAILS_PANEL_LABEL_CLASS)}>Changes</span>
1835 - <span className="flex items-center gap-1 font-mono text-2xs tabular-nums">
1836 - <span className="text-diff-addition">
1847 + <span className="flex items-center gap-1.5 font-mono text-xs tabular-nums">
1848 + <span
1849 + className={
1850 + changesTotals?.insertions
1851 + ? "text-diff-addition-foreground"
1852 + : "text-muted-foreground"
1853 + }
1854 + >
1855 +{formatDiffCount(changesTotals?.insertions ?? 0)}
1856 </span>
1839 - <span className="text-diff-deletion">
1857 + <span
1858 + className={
1859 + changesTotals?.deletions ? "text-diff-deletion-foreground" : "text-muted-foreground"
1860 + }
1861 + >
1862 -{formatDiffCount(changesTotals?.deletions ?? 0)}
1863 </span>
1864 </span>
apps/web/src/components/Sidebar.tsx
+6 -13
@@ -3136,11 +3136,8 @@ export default function Sidebar({ routeReveal }: { routeReveal: SidebarRouteReve
3136 key="working-shelf-header"
3137 marker="working-header"
3138 className="mt-auto"
3139 - label={
3140 - workingShelfExpanded
3141 - ? "Working"
3142 - : `Working (${workingThreads.length})`
3143 - }
3139 + label="Working"
3140 + count={workingThreads.length}
3141 toggle={{
3142 expanded: workingShelfExpanded,
3143 onToggle: toggleWorkingShelf,
@@ -3154,11 +3151,8 @@ export default function Sidebar({ routeReveal }: { routeReveal: SidebarRouteReve
3151 key="snoozed-shelf-header"
3152 marker="snoozed-header"
3153 className={cn(workingThreads.length === 0 && "mt-auto")}
3157 - label={
3158 - snoozedShelfExpanded
3159 - ? "Snoozed"
3160 - : `Snoozed (${snoozedThreads.length})`
3161 - }
3154 + label="Snoozed"
3155 + count={snoozedThreads.length}
3156 toggle={{
3157 expanded: snoozedShelfExpanded,
3158 onToggle: toggleSnoozedShelf,
@@ -3174,9 +3168,8 @@ export default function Sidebar({ routeReveal }: { routeReveal: SidebarRouteReve
3168 className={cn(
3169 workingThreads.length + snoozedThreads.length === 0 && "mt-auto",
3170 )}
3177 - label={
3178 - settledShelfExpanded ? "Settled" : `Settled (${settledCount})`
3179 - }
3171 + label="Settled"
3172 + count={settledCount}
3173 dragging={from !== null}
3174 isDropTarget={dragTargetSection === "settled"}
3175 toggle={{
apps/web/src/components/ThreadStatusIndicators.tsx
+2 -2
@@ -291,7 +291,7 @@ function PullRequestBadge({
291 className={cn("contents font-normal text-xs tabular-nums", presentation.toneClassName)}
292 >
293 <presentation.Icon aria-hidden className="size-3 shrink-0" />
294 - <span>{presentation.text}</span>
294 + <span className="redesign:text-secondary-label">{presentation.text}</span>
295 </span>
296 </TooltipTrigger>
297 <TooltipPopup
@@ -800,7 +800,7 @@ export function ThreadWorktreeIndicator({
800 />
801 }
802 >
803 - <FolderGit2Icon className="size-3 text-muted-foreground/40" />
803 + <FolderGit2Icon className="size-3.5 shrink-0 text-icon-muted" />
804 </TooltipTrigger>
805 <TooltipPopup side="top">{tooltip}</TooltipPopup>
806 </Tooltip>
apps/web/src/components/chat/ChatComposer.tsx
+5 -7
@@ -72,7 +72,7 @@ import {
72 extendReplacementRangeForTrailingSpace,
73 replaceTextRange,
74 } from "../../composer-logic";
75 -import { DISCONNECTED_COMPOSER_PLACEHOLDER } from "../../composerPlaceholder";
75 +import { DEFAULT_COMPOSER_PLACEHOLDER } from "../../composerPlaceholder";
76 import {
77 deriveComposerSendState,
78 getAntigravitySendBlockReason,
@@ -3596,7 +3596,7 @@ export const ChatComposer = memo(function ChatComposer(props: ChatComposerProps)
3596 data-chat-composer-surface="true"
3597 data-chat-composer-mobile-collapsed={isComposerCollapsedMobile ? "true" : "false"}
3598 className={cn(
3599 - "rounded-3xl transition-[background-color] duration-200",
3599 + "rounded-2xl transition-[background-color] duration-200",
3600 "in-data-[thread-context-over]:bg-accent/45 in-data-[thread-context-over]:ring-1 in-data-[thread-context-over]:ring-inset in-data-[thread-context-over]:ring-primary/70",
3601 isDragOverComposer ? "bg-accent/45 ring-1 ring-inset ring-primary/70" : null,
3602 projectSelectionRequired ? "opacity-75" : null,
@@ -3763,7 +3763,7 @@ export const ChatComposer = memo(function ChatComposer(props: ChatComposerProps)
3763 className={cn(
3764 showMobilePendingAnswerActions && "max-sm:pb-12",
3765 isComposerResting &&
3766 - "my-0 max-h-8 min-h-8 overflow-hidden py-0 whitespace-pre! leading-8",
3766 + "my-0 max-h-8 min-h-8 redesign:min-h-8 overflow-hidden py-0 whitespace-pre! leading-8",
3767 )}
3768 placeholderClassName={cn(
3769 isComposerResting &&
@@ -3793,9 +3793,7 @@ export const ChatComposer = memo(function ChatComposer(props: ChatComposerProps)
3793 ? "Choose a project above to start a thread"
3794 : showProviderUnavailable
3795 ? "Enable a provider in Settings to send a message"
3796 - : phase === "disconnected"
3797 - ? DISCONNECTED_COMPOSER_PLACEHOLDER
3798 - : "Ask anything, @tag files/folders, $use skills, or / for commands"
3796 + : DEFAULT_COMPOSER_PLACEHOLDER
3797 }
3798 disabled={
3799 isConnecting ||
@@ -3863,7 +3861,7 @@ export const ChatComposer = memo(function ChatComposer(props: ChatComposerProps)
3861 data-chat-composer-controls="left"
3862 data-chat-composer-footer-controls="true"
3863 className={cn(
3866 - "relative -m-1 -ms-3.5 flex min-w-0 flex-1 items-center gap-1 overflow-x-auto p-1 ps-3.5 [scrollbar-width:none] [&::-webkit-scrollbar]:hidden",
3864 + "relative -m-1 -ms-3.5 flex min-w-0 flex-1 items-center gap-0 overflow-x-auto p-1 ps-3.5 [scrollbar-width:none] [&::-webkit-scrollbar]:hidden",
3865 isComposerResting && "hidden",
3866 )}
3867 >
apps/web/src/components/chat/ComposerControl.tsx
+3 -3
@@ -14,8 +14,8 @@ function composerControlClassName(size: ComposerControlSize, className?: string)
14 "relative inline-flex shrink-0 cursor-pointer items-center justify-center whitespace-nowrap rounded-(--control-radius) border border-transparent text-base outline-none hover:bg-accent data-pressed:bg-accent focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-ring focus-visible:ring-offset-1 focus-visible:ring-offset-background disabled:pointer-events-none disabled:opacity-64 data-disabled:pointer-events-none data-disabled:opacity-64 pointer-coarse:after:absolute pointer-coarse:after:size-full pointer-coarse:after:min-h-11 pointer-coarse:after:min-w-11 [&:active:not([aria-haspopup])]:scale-[0.97] [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg]:-mx-0.5 [&_svg[data-composer-control-icon]]:mx-0",
15 "[&_:is([data-composer-control-label],[data-chat-provider-model-picker-label])]:[text-box:trim-both_cap_alphabetic] supports-[text-box:trim-both_cap_alphabetic]:[&_:is([data-composer-control-label],[data-chat-provider-model-picker-label])]:py-1.5",
16 size === "xs"
17 - ? "h-7 gap-1 px-1.75 font-normal text-muted-foreground/70 text-sm hover:text-foreground/80 sm:h-6 sm:text-xs [&_svg:not([class*='size-'])]:size-4 sm:[&_svg:not([class*='size-'])]:size-3.5 [&_svg[data-composer-control-chevron]]:ms-0 [&_svg[data-composer-control-chevron]]:-me-1"
18 - : "h-7 gap-1.5 px-2.5 font-medium text-secondary-label [&_svg:not([class*='text-'])]:text-muted-foreground hover:text-foreground sm:text-sm [&_svg:not([class*='size-'])]:size-4.5 sm:[&_svg:not([class*='size-'])]:size-4",
17 + ? "h-7 gap-1 px-1.75 font-normal text-foreground/70 text-sm hover:text-foreground dark:text-muted-foreground sm:h-6 sm:text-xs [&_svg:not([class*='size-'])]:size-4 sm:[&_svg:not([class*='size-'])]:size-3.5 [&_svg[data-composer-control-chevron]]:ms-0 [&_svg[data-composer-control-chevron]]:-me-1"
18 + : "h-7 gap-1.5 px-2 font-medium text-foreground/80 [&_svg:not([class*='text-'])]:text-muted-foreground hover:text-foreground sm:text-sm [&_svg:not([class*='size-'])]:size-4.5 sm:[&_svg:not([class*='size-'])]:size-4",
19 "aria-pressed:bg-accent aria-pressed:text-accent-foreground aria-pressed:hover:bg-accent/80",
20 className,
21 );
@@ -78,7 +78,7 @@ export function ComposerControlChevron({
78 aria-hidden="true"
79 className={cn(
80 "shrink-0",
81 - size === "xs" ? "size-3 text-current opacity-50" : "size-3.5 text-icon-muted",
81 + size === "xs" ? "size-3 text-current" : "size-3.5 text-icon-muted",
82 className,
83 )}
84 data-composer-control-chevron
apps/web/src/components/chat/ComposerControlsBar.tsx
+2 -7
@@ -166,12 +166,7 @@ export function ComposerControlsBar(props: {
166 ? [
167 {
168 id: "traits",
169 - content: (
170 - <>
171 - <ComposerControlSeparator size={composerControlsCollapsed ? "xs" : "sm"} />
172 - {restingProviderTraitsPicker}
173 - </>
174 - ),
169 + content: restingProviderTraitsPicker,
170 },
171 ]
172 : []),
@@ -229,7 +224,7 @@ export function ComposerControlsBar(props: {
224 !showInlineRestingControls &&
225 "@max-[640px]/composer-surface:[&_[data-chat-provider-model-picker-label]]:w-0 @max-[640px]/composer-surface:[&_[data-chat-provider-model-picker-label]]:flex-none",
226 )
232 - : "-ms-2.5 min-w-13"
227 + : "-ms-2 min-w-13"
228 }
229 terminalOpen={terminalOpen}
230 open={modelPickerOpen}
apps/web/src/components/chat/ComposerFooterControls.tsx
+33 -43
@@ -11,12 +11,7 @@ import { type ComponentProps, memo } from "react";
11 import type { ContextWindowSnapshot } from "../../lib/contextWindow";
12 import { Select, SelectItem, SelectPopup, SelectValue } from "../ui/select";
13 import { Tooltip, TooltipPopup, TooltipTrigger } from "../ui/tooltip";
14 -import {
15 - ComposerControl,
16 - ComposerControlIcon,
17 - ComposerControlSeparator,
18 - ComposerSelectControl,
19 -} from "./ComposerControl";
14 +import { ComposerControl, ComposerControlIcon, ComposerSelectControl } from "./ComposerControl";
15 import { useComposerMenuProps } from "./composerEventScope";
16 import { ComposerPrimaryActions } from "./ComposerPrimaryActions";
17 import { ContextWindowMeter, ContextWindowMeterPlaceholder } from "./ContextWindowMeter";
@@ -53,47 +48,42 @@ export const ComposerFooterModeControls = memo(function ComposerFooterModeContro
48 : "Default mode. Click to enter plan mode";
49
50 const interactionModeToggle = props.showInteractionModeToggle ? (
56 - <>
57 - <ComposerControlSeparator size={size} />
58 - <Tooltip>
59 - <TooltipTrigger
60 - render={
61 - <ComposerControl
62 - size={size}
63 - className="shrink-0 whitespace-nowrap"
64 - aria-pressed={props.interactionMode === "plan"}
65 - type="button"
66 - onClick={props.onToggleInteractionMode}
67 - aria-label={interactionModeTooltip}
68 - />
69 - }
70 - >
71 - {props.interactionMode === "plan" ? (
72 - <ComposerControlIcon
73 - icon={PencilRulerIcon}
74 - size={size}
75 - className="text-current opacity-100"
76 - />
77 - ) : (
78 - <ComposerControlIcon
79 - icon={BotIcon}
80 - size={size}
81 - opticalSize={size === "xs" ? "default" : "large"}
82 - />
83 - )}
84 - <span data-composer-control-label className="sr-only sm:not-sr-only">
85 - {props.interactionMode === "plan" ? "Plan" : "Build"}
86 - </span>
87 - </TooltipTrigger>
88 - <TooltipPopup side="top">{interactionModeTooltip}</TooltipPopup>
89 - </Tooltip>
90 - </>
51 + <Tooltip>
52 + <TooltipTrigger
53 + render={
54 + <ComposerControl
55 + size={size}
56 + className="shrink-0 whitespace-nowrap"
57 + aria-pressed={props.interactionMode === "plan"}
58 + type="button"
59 + onClick={props.onToggleInteractionMode}
60 + aria-label={interactionModeTooltip}
61 + />
62 + }
63 + >
64 + {props.interactionMode === "plan" ? (
65 + <ComposerControlIcon
66 + icon={PencilRulerIcon}
67 + size={size}
68 + className="text-current opacity-100"
69 + />
70 + ) : (
71 + <ComposerControlIcon
72 + icon={BotIcon}
73 + size={size}
74 + opticalSize={size === "xs" ? "default" : "large"}
75 + />
76 + )}
77 + <span data-composer-control-label className="sr-only sm:not-sr-only">
78 + {props.interactionMode === "plan" ? "Plan" : "Build"}
79 + </span>
80 + </TooltipTrigger>
81 + <TooltipPopup side="top">{interactionModeTooltip}</TooltipPopup>
82 + </Tooltip>
83 ) : null;
84
85 return (
86 <>
95 - <ComposerControlSeparator size={size} />
96 -
87 <Tooltip>
88 <Select
89 open={open}
apps/web/src/components/chat/ComposerPrimaryActions.tsx
+28 -12
@@ -2,7 +2,7 @@ import { memo, type MouseEventHandler, type PointerEventHandler } from "react";
2 import { CheckIcon, ChevronDownIcon, ChevronLeftIcon, Minimize2Icon, PlayIcon } from "lucide-react";
3 import { CornerUpRight, ListPlus } from "lucide";
4 import { MorphIcon } from "~/components/MorphIcon";
5 -import { useEnvironmentIdentificationMode } from "~/hooks/useSettings";
5 +import { useClientSettings, useEnvironmentIdentificationMode } from "~/hooks/useSettings";
6 import { formatContextWindowTokens } from "~/lib/contextWindow";
7 import { cn } from "~/lib/utils";
8 import { useShortcutModifierState } from "../../shortcutModifierState";
@@ -113,6 +113,7 @@ export const ComposerPrimaryActions = memo(function ComposerPrimaryActions({
113 ? { onPointerDown: preventPointerFocus }
114 : undefined;
115 const environmentIdentificationMode = useEnvironmentIdentificationMode();
116 + const redesign = useClientSettings((s) => s.redesignEnabled);
117 const shortcutModifiers = useShortcutModifierState();
118 const isQueuing =
119 !isEditingQueuedMessage &&
@@ -310,10 +311,10 @@ export const ComposerPrimaryActions = memo(function ComposerPrimaryActions({
311 <button
312 type={showResume ? "button" : "submit"}
313 className={cn(
313 - "relative isolate flex h-9 w-9 items-center justify-center overflow-hidden rounded-full shadow-xs transition-all duration-150 enabled:cursor-pointer enabled:inset-shadow-control-highlight hover:scale-105 active:inset-shadow-control-pressed active:shadow-none disabled:pointer-events-none disabled:opacity-64 disabled:shadow-none disabled:hover:scale-100 sm:h-8 sm:w-8 [&_svg]:pointer-events-none",
314 + "relative isolate flex h-9 w-9 items-center justify-center overflow-hidden rounded-full shadow-xs transition-all duration-150 enabled:cursor-pointer enabled:inset-shadow-control-highlight hover:scale-105 active:inset-shadow-control-pressed active:shadow-none disabled:pointer-events-none disabled:shadow-none disabled:hover:scale-100 sm:h-8 sm:w-8 [&_svg]:pointer-events-none",
315 stageBackdropVariant
315 - ? "bg-transparent text-white enabled:shadow-black/24 enabled:hover:brightness-110"
316 - : "bg-message-action text-message-action-foreground enabled:shadow-message-action/24 hover:bg-message-action-hover",
316 + ? "bg-transparent text-white enabled:shadow-black/24 enabled:hover:brightness-110 disabled:opacity-64"
317 + : "bg-message-action text-message-action-foreground enabled:shadow-message-action/24 hover:bg-message-action-hover disabled:bg-foreground/12 disabled:text-muted-foreground",
318 )}
319 {...pointerFocusProps}
320 onClick={showResume ? onResume : onSubmitMessage}
@@ -368,12 +369,16 @@ export const ComposerPrimaryActions = memo(function ComposerPrimaryActions({
369 render={
370 <button
371 type="button"
371 - className={cn(
372 - "flex h-9 shrink-0 cursor-pointer items-center gap-1.5 rounded-full border px-2.5 text-xs tabular-nums outline-none transition-colors focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-64 sm:h-8 [&_svg]:pointer-events-none [&_svg]:size-3.5",
373 - keepFullHistory
374 - ? "border-border text-muted-foreground hover:text-foreground"
375 - : "border-warning/40 text-warning hover:bg-warning/8",
376 - )}
372 + className={
373 + redesign
374 + ? "flex h-7 shrink-0 cursor-pointer items-center gap-1.5 rounded-(--control-radius) px-2 font-medium text-base text-foreground/80 tabular-nums outline-none hover:bg-accent hover:text-foreground focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-64 sm:text-sm aria-pressed:bg-accent/60 aria-pressed:text-foreground [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:text-muted-foreground"
375 + : cn(
376 + "flex h-9 shrink-0 cursor-pointer items-center gap-1.5 rounded-full border px-2.5 text-xs tabular-nums outline-none transition-colors focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-64 sm:h-8 [&_svg]:pointer-events-none [&_svg]:size-3.5",
377 + keepFullHistory
378 + ? "border-border text-muted-foreground hover:text-foreground"
379 + : "border-warning/40 text-warning hover:bg-warning/8",
380 + )
381 + }
382 {...pointerFocusProps}
383 aria-pressed={!keepFullHistory}
384 aria-label={`Compact ${compactTokens} tokens of history before sending`}
@@ -383,8 +388,19 @@ export const ComposerPrimaryActions = memo(function ComposerPrimaryActions({
388 }
389 >
390 <Minimize2Icon aria-hidden="true" />
386 - {keepFullHistory ? "Full" : "Compact"}
387 - <span>{compactTokens}</span>
391 + {/* The new design keeps the token count in the tooltip so the permission label keeps its room. */}
392 + {redesign ? (
393 + keepFullHistory ? (
394 + "Keep full"
395 + ) : (
396 + "Compact next"
397 + )
398 + ) : (
399 + <>
400 + {keepFullHistory ? "Full" : "Compact"}
401 + <span>{compactTokens}</span>
402 + </>
403 + )}
404 </TooltipTrigger>
405 <TooltipPopup>
406 <div>
apps/web/src/components/chat/ComposerSurface.tsx
+6 -6
@@ -18,13 +18,13 @@ function Shell({
18 "[html[data-theme-id]_&]:[--chat-composer-glass-surface:var(--app-theme-surface-raised)] [html[data-theme-id]_&]:[--chat-composer-outline:var(--app-theme-toolbar-border)]",
19 "dark:[html[data-theme-id]:not([data-theme-id=t3-chat])_&]:[--chat-composer-highlight:color-mix(in_srgb,var(--app-theme-input)_12%,transparent)] dark:[html[data-theme-id]:not([data-theme-id=t3-chat])_&]:[--chat-composer-outline:color-mix(in_srgb,var(--app-theme-input)_30%,var(--background))]",
20 "dark:[html[data-theme-id=t3-chat]_&]:[--chat-composer-highlight:color-mix(in_srgb,#432d48_12%,transparent)] dark:[html[data-theme-id=t3-chat]_&]:[--chat-composer-outline:#241e28]",
21 - "before:pointer-events-none before:absolute before:inset-0 before:z-0 before:rounded-3xl before:bg-(--chat-composer-glass-surface)/(--glass-opacity) before:backdrop-blur-(--glass-blur) before:backdrop-saturate-(--glass-saturation)",
21 + "before:pointer-events-none before:absolute before:inset-0 before:z-0 before:rounded-2xl before:bg-(--chat-composer-glass-surface)/(--glass-opacity) before:backdrop-blur-(--glass-blur) before:backdrop-saturate-(--glass-saturation)",
22 "not-supports-[((backdrop-filter:blur(1px))_or_(-webkit-backdrop-filter:blur(1px)))]:before:bg-(--chat-composer-glass-surface)",
23 "has-data-[composer-banner-surface=attached]:before:hidden data-model-strip-transition:before:hidden",
24 contextStrip && [
25 "[--chat-composer-context-extension:2.25rem] sm:[--chat-composer-context-extension:2rem]",
26 "supports-[clip-path:shape(from_0_0,line_to_1px_1px)]:before:rounded-none",
27 - "before:[clip-path:shape(from_0_22px,curve_to_22px_0_with_0_9.85px/9.85px_0,line_to_calc(100%-22px)_0,curve_to_100%_22px_with_calc(100%-9.85px)_0/100%_9.85px,line_to_100%_calc(100%-var(--chat-composer-context-extension)-var(--chat-composer-drawer-inset)),curve_to_calc(100%-var(--chat-composer-drawer-inset))_calc(100%-var(--chat-composer-context-extension))_with_100%_calc(100%-var(--chat-composer-context-extension)-var(--chat-composer-drawer-inset)*0.4477)/calc(100%-var(--chat-composer-drawer-inset)*0.4477)_calc(100%-var(--chat-composer-context-extension)),line_to_calc(100%-var(--chat-composer-drawer-inset))_calc(100%-16px),curve_to_calc(100%-var(--chat-composer-drawer-inset)-16px)_100%_with_calc(100%-var(--chat-composer-drawer-inset))_calc(100%-7.16px)/calc(100%-var(--chat-composer-drawer-inset)-7.16px)_100%,line_to_calc(var(--chat-composer-drawer-inset)+16px)_100%,curve_to_var(--chat-composer-drawer-inset)_calc(100%-16px)_with_calc(var(--chat-composer-drawer-inset)+7.16px)_100%/var(--chat-composer-drawer-inset)_calc(100%-7.16px),line_to_var(--chat-composer-drawer-inset)_calc(100%-var(--chat-composer-context-extension)),curve_to_0_calc(100%-var(--chat-composer-context-extension)-var(--chat-composer-drawer-inset))_with_calc(var(--chat-composer-drawer-inset)*0.4477)_calc(100%-var(--chat-composer-context-extension))/0_calc(100%-var(--chat-composer-context-extension)-var(--chat-composer-drawer-inset)*0.4477),line_to_0_22px,close)]",
27 + "before:[clip-path:shape(from_0_16px,curve_to_16px_0_with_0_7.16px/7.16px_0,line_to_calc(100%-16px)_0,curve_to_100%_16px_with_calc(100%-7.16px)_0/100%_7.16px,line_to_100%_calc(100%-var(--chat-composer-context-extension)-var(--chat-composer-drawer-inset)),curve_to_calc(100%-var(--chat-composer-drawer-inset))_calc(100%-var(--chat-composer-context-extension))_with_100%_calc(100%-var(--chat-composer-context-extension)-var(--chat-composer-drawer-inset)*0.4477)/calc(100%-var(--chat-composer-drawer-inset)*0.4477)_calc(100%-var(--chat-composer-context-extension)),line_to_calc(100%-var(--chat-composer-drawer-inset))_calc(100%-16px),curve_to_calc(100%-var(--chat-composer-drawer-inset)-16px)_100%_with_calc(100%-var(--chat-composer-drawer-inset))_calc(100%-7.16px)/calc(100%-var(--chat-composer-drawer-inset)-7.16px)_100%,line_to_calc(var(--chat-composer-drawer-inset)+16px)_100%,curve_to_var(--chat-composer-drawer-inset)_calc(100%-16px)_with_calc(var(--chat-composer-drawer-inset)+7.16px)_100%/var(--chat-composer-drawer-inset)_calc(100%-7.16px),line_to_var(--chat-composer-drawer-inset)_calc(100%-var(--chat-composer-context-extension)),curve_to_0_calc(100%-var(--chat-composer-context-extension)-var(--chat-composer-drawer-inset))_with_calc(var(--chat-composer-drawer-inset)*0.4477)_calc(100%-var(--chat-composer-context-extension))/0_calc(100%-var(--chat-composer-context-extension)-var(--chat-composer-drawer-inset)*0.4477),line_to_0_16px,close)]",
28 "not-supports-[clip-path:shape(from_0_0,line_to_1px_1px)]:before:bottom-(--chat-composer-context-extension)",
29 ],
30 className,
@@ -45,7 +45,7 @@ function Host({ className, ...props }: ComponentProps<"div">) {
45 <div
46 data-slot="composer-host"
47 className={cn(
48 - "relative z-10 w-full rounded-3xl shadow-composer after:z-1 dark:shadow-none",
48 + "relative z-10 w-full rounded-2xl shadow-composer after:z-1 dark:shadow-none",
49 outlineClasses,
50 contextSeamClasses,
51 "group-has-data-[composer-banner-surface=attached]/composer-surface:shadow-none group-has-data-[composer-banner-surface=attached]/composer-surface:after:hidden",
@@ -61,7 +61,7 @@ function Main({ className, ...props }: ComponentProps<"div">) {
61 <div
62 data-chat-composer-main-surface="true"
63 className={cn(
64 - "group relative z-10 rounded-3xl p-px",
64 + "group relative z-10 rounded-2xl p-px",
65 "group-data-model-strip-transition/composer-surface:bg-(--chat-composer-glass-surface)/(--glass-opacity) group-data-model-strip-transition/composer-surface:backdrop-blur-(--glass-blur) group-data-model-strip-transition/composer-surface:backdrop-saturate-(--glass-saturation)",
66 outlineClasses,
67 contextSeamClasses,
@@ -84,8 +84,8 @@ function ContextStrip({ className, ...props }: ComponentProps<"div">) {
84 data-slot="composer-context-strip"
85 className={cn(
86 "group/composer-context relative isolate mx-auto -mt-4 flex w-[calc(100%-2*var(--chat-composer-drawer-inset))] items-center gap-2 overflow-x-clip overflow-y-visible px-2 pt-5 pb-1",
87 - "before:absolute before:inset-0 before:-z-1 before:rounded-b-2xl before:border before:border-(--chat-composer-outline) before:mask-b-from-transparent before:mask-b-from-(position:--spacing-composer-seam) before:mask-b-to-black before:mask-b-to-(position:--spacing-composer-seam) before:shadow-composer",
88 - "dark:before:border-white/7 dark:before:bg-composer-seam-below dark:before:shadow-composer-dark",
87 + "before:absolute before:inset-0 before:-z-1 before:rounded-b-2xl before:border before:border-(--chat-composer-outline) before:mask-b-from-transparent before:mask-b-from-(position:--spacing-composer-seam) before:mask-b-to-black before:mask-b-to-(position:--spacing-composer-seam)",
88 + "before:bg-(--chat-composer-glass-surface) dark:before:bg-transparent dark:before:bg-composer-seam-below",
89 "group-has-data-[composer-banner-surface=attached]/composer-surface:before:bg-(--chat-composer-glass-surface)/(--glass-opacity) group-has-data-[composer-banner-surface=attached]/composer-surface:before:backdrop-blur-(--glass-blur) group-has-data-[composer-banner-surface=attached]/composer-surface:before:backdrop-saturate-(--glass-saturation)",
90 "not-supports-[clip-path:shape(from_0_0,line_to_1px_1px)]:before:bg-(--chat-composer-glass-surface)/(--glass-opacity) not-supports-[clip-path:shape(from_0_0,line_to_1px_1px)]:before:backdrop-blur-(--glass-blur) not-supports-[clip-path:shape(from_0_0,line_to_1px_1px)]:before:backdrop-saturate-(--glass-saturation)",
91 className,
apps/web/src/components/chat/DiffStatLabel.tsx
+2 -2
@@ -40,10 +40,10 @@ export const DiffStatLabel = memo(function DiffStatLabel(props: {
40 className,
41 )}
42 >
43 - <span aria-hidden="true" className="font-mono text-diff-addition">
43 + <span aria-hidden="true" className="font-mono text-diff-addition-foreground">
44 +{formatCompactDiffCount(additions)}
45 </span>
46 - <span aria-hidden="true" className="font-mono text-diff-deletion">
46 + <span aria-hidden="true" className="font-mono text-diff-deletion-foreground">
47 -{formatCompactDiffCount(deletions)}
48 </span>
49 </span>
apps/web/src/components/chat/MarkdownDetails.tsx
+1 -1
@@ -53,7 +53,7 @@ export function MarkdownDetails({
53 </CollapsibleTrigger>
54 <CollapsiblePanel ref={revealRef} hiddenUntilFound={searching}>
55 <div
56 - className="pb-3 ps-6 text-foreground/[calc(80%+var(--appearance-contrast-boost)/5)]"
56 + className="pb-3 ps-6 text-foreground/[calc(90%+var(--appearance-contrast-boost)/10)]"
57 data-markdown-details-content=""
58 >
59 {content}
apps/web/src/components/chat/MessagesTimeline.tsx
+1 -3
@@ -1118,9 +1118,7 @@ const ConversationTimeline = memo(function ConversationTimeline({
1118 className="flex h-full items-center justify-center ps-(--chat-lane-inset-start) pe-(--chat-lane-inset-end)"
1119 style={{ paddingBottom: emptyPlaceholderInset }}
1120 >
1121 - <p className="text-sm text-muted-foreground/30">
1122 - Send a message to start the conversation.
1123 - </p>
1121 + <p className="text-sm text-muted-foreground">Send a message to start the conversation.</p>
1122 </div>
1123 </>
1124 );
apps/web/src/components/chat/OpenInPicker.tsx
+7
@@ -410,6 +410,13 @@ export const OpenInPicker = memo(function OpenInPicker({
410 className={cn(
411 isPanel ? THREAD_DETAILS_PANEL_ICON_CLASS : "size-3.5",
412 getOpenInIconClass(primaryOption.kind),
413 + // Full-color app icons outshout the panel's line icons until the row is in use.
414 + isPanel &&
415 + "redesign:grayscale redesign:dark:opacity-70 redesign:group-hover/details-split:grayscale-0 redesign:dark:group-hover/details-split:opacity-100 redesign:group-has-[[data-popup-open]]/details-split:grayscale-0 redesign:dark:group-has-[[data-popup-open]]/details-split:opacity-100",
416 + // A hairline keeps pale app icons from dissolving into the card.
417 + isPanel &&
418 + primaryOption.kind === "brand" &&
419 + "redesign:rounded-sm redesign:ring-1 redesign:ring-black/10 redesign:dark:ring-white/15",
420 )}
421 />
422 ) : isPanel ? (
apps/web/src/components/chat/ProposedPlanCard.tsx
+1 -1
@@ -158,7 +158,7 @@ export const ProposedPlanCard = memo(function ProposedPlanCard({
158 };
159
160 return (
161 - <div className="rounded-3xl border border-border/80 bg-card/70 p-4 sm:p-5">
161 + <div className="rounded-2xl border border-border/80 bg-card/70 p-4 sm:p-5">
162 <div className="flex flex-wrap items-center justify-between gap-3">
163 <div className="flex min-w-0 items-center gap-2">
164 <Badge variant="secondary">Plan</Badge>
apps/web/src/components/chat/ProviderSubagentBar.tsx
+1 -1
@@ -45,7 +45,7 @@ export function ProviderSubagentBar(props: {
45 // chat column on a wide window, and one row there squeezes out the model
46 // and status, so the status drops to its own line instead.
47 return (
48 - <div className="flex min-h-12 items-center gap-3 rounded-3xl py-2 ps-5 pe-2 text-sm">
48 + <div className="flex min-h-12 items-center gap-3 rounded-2xl py-2 ps-5 pe-2 text-sm">
49 <div className="flex min-w-0 flex-1 items-center gap-3 @max-[560px]/composer-surface:flex-col @max-[560px]/composer-surface:items-start @max-[560px]/composer-surface:gap-0.5">
50 <span className="flex min-w-0 max-w-full items-center gap-2">
51 {props.provider ? (
apps/web/src/components/chat/ThreadDetailsCard.tsx
+1 -1
@@ -123,7 +123,7 @@ export function ThreadDetailsCard({
123 const card = (
124 <div
125 className={cn(
126 - "dropdown-glass isolate contain-paint grid max-h-full grid-rows-[minmax(0,1fr)] overflow-hidden rounded-3xl",
126 + "dropdown-glass isolate contain-paint grid max-h-full grid-rows-[minmax(0,1fr)] overflow-hidden rounded-2xl",
127 mode === "popover" &&
128 "max-h-[min(calc(100dvh-6.5rem),calc(var(--available-height,100dvh)-1rem))]",
129 )}
apps/web/src/components/chat/ThreadDetailsPrRow.tsx
+15 -5
@@ -398,7 +398,8 @@ export function ThreadDetailsPrRow({
398 </Tooltip>
399 ) : null;
400
401 - const openRow = (text: string, part: "row" | "primary") => (
401 + // The title row wraps to two lines; a conventional-commit prefix eats most of one line.
402 + const openRow = (text: string, part: "row" | "primary", wrap = false) => (
403 <Tooltip>
404 <TooltipTrigger
405 render={
@@ -407,6 +408,8 @@ export function ThreadDetailsPrRow({
408 variant="ghost"
409 size="sm"
410 part={part}
411 + multiline={wrap}
412 + className={wrap ? "items-start [&>svg]:mt-0.5" : undefined}
413 aria-label={openAriaLabel}
414 onClick={onOpen}
415 onAuxClick={onOpen}
@@ -414,7 +417,14 @@ export function ThreadDetailsPrRow({
417 }
418 >
419 {icon}
417 - <span className={cn("min-w-0 flex-1 truncate text-left", THREAD_DETAILS_PANEL_LABEL_CLASS)}>
420 + <span
421 + className={cn(
422 + "min-w-0 flex-1 text-left",
423 + wrap
424 + ? "line-clamp-2 whitespace-normal leading-4.5"
425 + : cn("truncate", THREAD_DETAILS_PANEL_LABEL_CLASS),
426 + )}
427 + >
428 {text}
429 </span>
430 </TooltipTrigger>
@@ -427,9 +437,9 @@ export function ThreadDetailsPrRow({
437 return (
438 <>
439 {detail !== null && (showChecks || trailingAction !== null || watching) ? (
430 - <div className="pb-2">
431 - {openRow(detail.title, "row")}
432 - <div className="flex h-6 min-w-0 items-center gap-0.5 ps-9 pe-1 text-xs text-muted-foreground">
440 + <div className="pb-1.5">
441 + {openRow(detail.title, "row", true)}
442 + <div className="flex h-5 min-w-0 items-center gap-0.5 ps-9 pe-1 text-xs text-muted-foreground">
443 <span className="me-1 shrink-0 tabular-nums">#{number}</span>
444 {showChecks && checksRollup !== null ? (
445 <PullRequestChecksPopover
apps/web/src/components/chat/ThreadDetailsSection.tsx
+1 -1
@@ -26,7 +26,7 @@ export function ThreadDetailsSection({
26 >
27 <div
28 className={cn(
29 - "mb-1 flex min-h-8 min-w-0 items-center justify-between gap-2 px-1.5",
29 + "mb-1 flex min-h-8 min-w-0 items-center justify-between gap-2 px-2.5",
30 !showHeading && "hidden",
31 )}
32 >
apps/web/src/components/chat/ThreadRelationshipsControl.tsx
+27 -12
@@ -2,7 +2,7 @@ import { useAtomValue } from "@effect/atom-react";
2 import { ThreadDetailsControl } from "./ThreadDetailsControl";
3 import { ThreadHoverCardPopup } from "../ThreadHoverCard";
4 import { ThreadDetailsSection } from "./ThreadDetailsSection";
5 -import { CollapsibleSectionHeader, SectionHeaderStatus } from "../ui/collapsible-section-header";
5 +import { SectionHeaderStatus } from "../ui/collapsible-section-header";
6 import { SubagentTooltipContent } from "./SubagentTooltipContent";
7 import { PullRequestGlyph } from "../pullRequest/pullRequestIcons";
8 import { scopedThreadKey, scopeThreadRef } from "@t3tools/client-runtime/environment";
@@ -43,6 +43,7 @@ import { useNavigate } from "@tanstack/react-router";
43 import {
44 ArrowRightIcon,
45 BotIcon,
46 + ChevronDownIcon,
47 CornerLeftUpIcon,
48 GitForkIcon,
49 LoaderCircleIcon,
@@ -71,7 +72,11 @@ import { ThreadLineageWorkflowRow } from "./ThreadLineageWorkflowRow";
72 import { Menu, MenuItem, MenuPopup, MenuTrigger } from "../ui/menu";
73 import { Tooltip, TooltipPopup, TooltipTrigger } from "../ui/tooltip";
74 import { toastManager } from "../ui/toast";
75 +import { cn } from "~/lib/utils";
76 import {
77 + THREAD_DETAILS_PANEL_CHEVRON_CLASS,
78 + THREAD_DETAILS_PANEL_ICON_CLASS,
79 + THREAD_DETAILS_PANEL_LABEL_CLASS,
80 THREAD_DETAILS_PANEL_SPLIT_GROUP_CLASS,
81 THREAD_DETAILS_PANEL_ROW_CONTENT_CLASS,
82 THREAD_DETAILS_PANEL_SPLIT_SEPARATOR_CLASS,
@@ -132,17 +137,25 @@ function ThreadLineageGroup(props: {
137 return (
138 <div>
139 {props.label ? (
135 - <CollapsibleSectionHeader
136 - variant="panel"
137 - expanded={expanded}
138 - onClick={() => setExpanded(!expanded)}
139 - accessory={
140 - failedCount > 0 ? <SectionHeaderStatus>{failedCount} failed</SectionHeaderStatus> : null
141 - }
142 - >
143 - {props.label}
144 - {!expanded && ` (${props.rows.length})`}
145 - </CollapsibleSectionHeader>
140 + <ThreadDetailsControl aria-expanded={expanded} onClick={() => setExpanded(!expanded)}>
141 + <BotIcon aria-hidden className={THREAD_DETAILS_PANEL_ICON_CLASS} />
142 + <span className={THREAD_DETAILS_PANEL_LABEL_CLASS}>{props.label}</span>
143 + <span aria-hidden className="min-w-2 flex-1" />
144 + {failedCount > 0 ? <SectionHeaderStatus>{failedCount} failed</SectionHeaderStatus> : null}
145 + {expanded ? null : (
146 + <span className="text-xs font-normal tabular-nums text-muted-foreground">
147 + {props.rows.length}
148 + </span>
149 + )}
150 + <ChevronDownIcon
151 + aria-hidden
152 + className={cn(
153 + THREAD_DETAILS_PANEL_CHEVRON_CLASS,
154 + "transition-transform",
155 + !expanded && "rotate-180 redesign:-rotate-90",
156 + )}
157 + />
158 + </ThreadDetailsControl>
159 ) : null}
160 {expanded ? (
161 <ThreadLineageRowList
@@ -397,6 +410,8 @@ export function ThreadRelationshipsPanel(props: {
410 <ThreadDetailsSection
411 headingId="thread-details-lineage-heading"
412 title={runningCount > 0 ? `Lineage · ${runningCount} running` : "Lineage"}
413 + // A lone "Previous agents" row names itself; the heading returns for status or actions.
414 + showHeading={runningCount > 0 || canDetach || related.length > 0 || active.length > 0}
415 data-thread-relationships-panel
416 actions={
417 canDetach ? (
apps/web/src/components/chat/TimelineMinimap.tsx
+2 -2
@@ -221,7 +221,7 @@ export function TimelineMinimap({
221 aria-hidden="true"
222 className={cn(
223 "group/strip pointer-events-none absolute left-0 h-0.5 w-6 origin-left -translate-y-1/2 rounded-full transition-transform duration-150",
224 - activeDistance === 0 ? "bg-muted-foreground/75" : "bg-muted-foreground/35",
224 + activeDistance === 0 ? "bg-muted-foreground/60" : "bg-muted-foreground/25",
225 activeDistance === 0
226 ? "scale-x-100"
227 : activeDistance === 1
@@ -242,7 +242,7 @@ export function TimelineMinimap({
242 }}
243 style={{ top }}
244 >
245 - <span className="absolute inset-0 rounded-full bg-foreground/90 opacity-0 transition-opacity duration-150 group-data-[in-view=true]/strip:opacity-100" />
245 + <span className="absolute inset-0 rounded-full bg-foreground/55 opacity-0 transition-opacity duration-150 group-data-[in-view=true]/strip:opacity-100" />
246 </span>
247 );
248 })}
apps/web/src/components/chat/TraitsPicker.tsx
+5 -3
@@ -24,7 +24,7 @@ import {
24 normalizeModelSlug,
25 } from "@t3tools/shared/model";
26 import { memo } from "react";
27 -import { BrainIcon } from "lucide-react";
27 +import { BrainIcon, GaugeIcon } from "lucide-react";
28 import {
29 Menu,
30 MenuGroup,
@@ -600,7 +600,8 @@ export const TraitsPicker = memo(function TraitsPicker({
600 size === "xs" ? "gap-1" : "gap-1.5",
601 )}
602 >
603 - <ComposerControlIcon icon={BrainIcon} size={size} />
603 + <ComposerControlIcon icon={BrainIcon} size={size} className="redesign:hidden" />
604 + <ComposerControlIcon icon={GaugeIcon} size={size} className="hidden redesign:block" />
605 <span data-composer-control-label className="min-w-0 truncate">
606 {triggerLabel}
607 </span>
@@ -608,7 +609,8 @@ export const TraitsPicker = memo(function TraitsPicker({
609 </span>
610 ) : (
611 <>
611 - <ComposerControlIcon icon={BrainIcon} size={size} />
612 + <ComposerControlIcon icon={BrainIcon} size={size} className="redesign:hidden" />
613 + <ComposerControlIcon icon={GaugeIcon} size={size} className="hidden redesign:block" />
614 <span data-composer-control-label>{triggerLabel}</span>
615 <ComposerControlChevron size={size} />
616 </>
apps/web/src/components/chat/threadDetailsPanelStyles.ts
+5 -3
@@ -19,7 +19,7 @@ const THREAD_DETAILS_PANEL_CONTROL_CLASS = `h-8 min-w-0 rounded-lg border-transp
19
20 export const THREAD_DETAILS_PANEL_ROW_CLASS = `${THREAD_DETAILS_PANEL_CONTROL_CLASS} w-full justify-start ${THREAD_DETAILS_PANEL_ROW_SURFACE_CLASS}`;
21
22 -export const THREAD_DETAILS_PANEL_SELECT_ROW_CLASS = `${THREAD_DETAILS_PANEL_ROW_CLASS} gap-0 px-0 [&_[data-slot=select-icon]]:-me-px [&_[data-slot=select-icon]]:relative [&_[data-slot=select-icon]]:flex [&_[data-slot=select-icon]]:h-full [&_[data-slot=select-icon]]:w-8 [&_[data-slot=select-icon]]:shrink-0 [&_[data-slot=select-icon]]:items-center [&_[data-slot=select-icon]]:justify-center [&_[data-slot=select-icon]]:before:absolute [&_[data-slot=select-icon]]:before:-left-px [&_[data-slot=select-icon]]:before:top-1/2 [&_[data-slot=select-icon]]:before:h-4 [&_[data-slot=select-icon]]:before:w-px [&_[data-slot=select-icon]]:before:-translate-y-1/2 [&_[data-slot=select-icon]]:before:bg-border/65 [&_[data-slot=select-icon]>svg]:me-0 [&_[data-slot=select-icon]>svg]:size-4 [&_[data-slot=select-icon]>svg]:text-muted-foreground [&_[data-slot=select-icon]>svg]:opacity-100`;
22 +export const THREAD_DETAILS_PANEL_SELECT_ROW_CLASS = `${THREAD_DETAILS_PANEL_ROW_CLASS} gap-0 px-0 [&_[data-slot=select-icon]]:-me-px [&_[data-slot=select-icon]]:relative [&_[data-slot=select-icon]]:flex [&_[data-slot=select-icon]]:h-full [&_[data-slot=select-icon]]:w-8 [&_[data-slot=select-icon]]:shrink-0 [&_[data-slot=select-icon]]:items-center [&_[data-slot=select-icon]]:justify-center [&_[data-slot=select-icon]]:before:absolute [&_[data-slot=select-icon]]:before:-left-px [&_[data-slot=select-icon]]:before:top-1/2 [&_[data-slot=select-icon]]:before:h-4 [&_[data-slot=select-icon]]:before:w-px [&_[data-slot=select-icon]]:before:-translate-y-1/2 [&_[data-slot=select-icon]]:before:bg-transparent hover:[&_[data-slot=select-icon]]:before:bg-border/65 data-popup-open:[&_[data-slot=select-icon]]:before:bg-border/65 [&_[data-slot=select-icon]>svg]:me-0 [&_[data-slot=select-icon]>svg]:size-4 [&_[data-slot=select-icon]>svg]:text-muted-foreground [&_[data-slot=select-icon]>svg]:opacity-100`;
23
24 // The row keeps its soft fill while each half stacks a second one, like the split controls nearby.
25 export const THREAD_DETAILS_PANEL_SELECT_LABEL_CLASS = `flex h-full min-w-0 flex-1 items-center rounded-s-lg ${THREAD_DETAILS_PANEL_ROW_CONTENT_CLASS} ${THREAD_DETAILS_PANEL_HALF_HOVER_SURFACE_CLASS}`;
@@ -36,10 +36,12 @@ export const THREAD_DETAILS_PANEL_ICON_ACTION_CLASS = `size-6 justify-center rou
36
37 export const THREAD_DETAILS_PANEL_META_ACTION_CLASS = `h-6 gap-1 rounded-md border-transparent px-1.5 text-xs font-medium text-muted-foreground ${THREAD_DETAILS_PANEL_ROW_SURFACE_CLASS}`;
38
39 -export const THREAD_DETAILS_PANEL_SPLIT_GROUP_CLASS = `flex w-full items-center rounded-lg ${THREAD_DETAILS_PANEL_SPLIT_GROUP_SURFACE_CLASS}`;
39 +export const THREAD_DETAILS_PANEL_SPLIT_GROUP_CLASS = `group/details-split flex w-full items-center rounded-lg ${THREAD_DETAILS_PANEL_SPLIT_GROUP_SURFACE_CLASS}`;
40
41 export const THREAD_DETAILS_PANEL_SPLIT_PRIMARY_CLASS = `${THREAD_DETAILS_PANEL_CONTROL_CLASS} flex-1 justify-start rounded-e-none ${THREAD_DETAILS_PANEL_SPLIT_BUTTON_SURFACE_CLASS}`;
42
43 export const THREAD_DETAILS_PANEL_SPLIT_SECONDARY_CLASS = `${THREAD_DETAILS_PANEL_CONTROL_CLASS} w-8 justify-center rounded-s-none px-0 ${THREAD_DETAILS_PANEL_SPLIT_BUTTON_SURFACE_CLASS}`;
44
45 -export const THREAD_DETAILS_PANEL_SPLIT_SEPARATOR_CLASS = "h-4 w-px shrink-0 bg-border/65";
45 +// The split hairline shows only while the pair is in use, so resting rows read as plain rows.
46 +export const THREAD_DETAILS_PANEL_SPLIT_SEPARATOR_CLASS =
47 + "h-4 w-px shrink-0 bg-transparent group-hover/details-split:bg-border/65 group-has-[[data-popup-open]]/details-split:bg-border/65";
apps/web/src/components/preview/AgentBrowserCursor.tsx
+1 -4
@@ -87,10 +87,7 @@ export function AgentCursorMark(props: {
87 className="absolute left-0.5 top-0.5 size-4 animate-status-ping rounded-full bg-primary/25 motion-reduce:animate-none"
88 />
89 ) : null}
90 - <MousePointer2
91 - className="relative size-5 -translate-x-0.5 -translate-y-0.5 fill-background text-primary drop-shadow-sm"
92 - strokeWidth={2}
93 - />
90 + <MousePointer2 className="relative size-5 -translate-x-0.5 -translate-y-0.5 fill-background stroke-2 text-primary drop-shadow-sm" />
91 </div>
92 );
93 }
apps/web/src/components/pullRequest/PullRequestChecksPopover.tsx
+1 -1
@@ -181,7 +181,7 @@ export function PullRequestChecksPopover({
181 <>
182 {checks !== undefined && incompleteCount > 0 ? (
183 <span className="tabular-nums">
184 - {checks.length - incompleteCount}/{checks.length}
184 + {checks.length - incompleteCount}/{checks.length} checks
185 </span>
186 ) : failedCount > 0 ? (
187 <span className="tabular-nums">{failedCount} failed</span>
apps/web/src/components/settings/AppearanceSettingsPanel.tsx
+29
@@ -351,6 +351,35 @@ export function AppearanceSettingsPanel() {
351 </div>
352 }
353 />
354 + {/* Only the new design grays project icons, so the option only exists there. */}
355 + {settings.redesignEnabled ? (
356 + <SettingsRow
357 + {...searchableSetting("sidebar-project-icon-colors")}
358 + description="Show project icons in the sidebar in full color instead of gray."
359 + resetAction={
360 + settings.sidebarProjectIconColors !==
361 + DEFAULT_UNIFIED_SETTINGS.sidebarProjectIconColors ? (
362 + <SettingResetButton
363 + label="colored project icons"
364 + onClick={() =>
365 + updateSettings({
366 + sidebarProjectIconColors: DEFAULT_UNIFIED_SETTINGS.sidebarProjectIconColors,
367 + })
368 + }
369 + />
370 + ) : null
371 + }
372 + control={
373 + <Switch
374 + checked={settings.sidebarProjectIconColors}
375 + onCheckedChange={(checked) =>
376 + updateSettings({ sidebarProjectIconColors: Boolean(checked) })
377 + }
378 + aria-label="Colored project icons"
379 + />
380 + }
381 + />
382 + ) : null}
383 <SettingsRow
384 {...searchableSetting("math-rendering")}
385 description="Typeset LaTeX math, such as $x^2$ or \[x^2\], in messages and Markdown previews. The composer keeps TeX source editable."
apps/web/src/components/settings/BetaSettingsPanel.tsx
+21
@@ -23,6 +23,27 @@ export function BetaSettingsPanel() {
23 return (
24 <SettingsPageContainer>
25 <SettingsSection id="beta" title="Beta">
26 + <SettingsRow
27 + {...searchableSetting("new-design")}
28 + description="Try the quieter design: gray sidebar icons, dimmer read threads, and simpler composer controls."
29 + resetAction={
30 + settings.redesignEnabled !== DEFAULT_UNIFIED_SETTINGS.redesignEnabled ? (
31 + <SettingResetButton
32 + label="new design"
33 + onClick={() =>
34 + updateSettings({ redesignEnabled: DEFAULT_UNIFIED_SETTINGS.redesignEnabled })
35 + }
36 + />
37 + ) : null
38 + }
39 + control={
40 + <Switch
41 + checked={settings.redesignEnabled}
42 + onCheckedChange={(checked) => updateSettings({ redesignEnabled: Boolean(checked) })}
43 + aria-label="New design"
44 + />
45 + }
46 + />
47 <SettingsRow
48 {...searchableSetting("working-shelf")}
49 description="Fold working and monitoring threads into a Working section. They return to the top of the inbox when they need you."
apps/web/src/components/settings/ProjectDefaultsSettings.tsx
+6 -8
@@ -148,14 +148,12 @@ export function ProjectDefaultsSettings({ category }: { category: ProjectSetting
148 description={
149 isProjectScope
150 ? "Model for new threads in this project."
151 - : "Default model for new threads. Projects can override it."
152 - }
153 - status={
154 - unavailable || mixedModel || modelSource === "project"
155 - ? undefined
156 - : settings.defaultModelSelection === null
157 - ? "Automatic"
158 - : undefined
151 + : !unavailable &&
152 + !mixedModel &&
153 + modelSource !== "project" &&
154 + settings.defaultModelSelection === null
155 + ? "Default model for new threads, selected automatically. Projects can override it."
156 + : "Default model for new threads. Projects can override it."
157 }
158 resetAction={
159 settings.defaultModelSelection !== null ? (
apps/web/src/components/settings/SettingsFontPreviews.tsx
+2 -2
@@ -5,7 +5,7 @@ import { ComposerPromptEditor, type ComposerPromptEditorHandle } from "../Compos
5 import { EMPTY_COMPOSER_CONTEXT_RECORDS } from "../composerContextPresentation";
6 import { terminalThemeFromApp } from "../ThreadTerminalDrawer";
7 import { useRenderedAppearance, useTheme } from "../../hooks/useTheme";
8 -import { DISCONNECTED_COMPOSER_PLACEHOLDER } from "../../composerPlaceholder";
8 +import { DEFAULT_COMPOSER_PLACEHOLDER } from "../../composerPlaceholder";
9 import { resolveDiffThemeName, type DiffThemeName } from "../../lib/diffRendering";
10 import { PREFERRED_HIGHLIGHTER } from "../../lib/syntaxHighlighting";
11 import { GhosttyTerminalSurface } from "~/terminal/ghostty/surface";
@@ -39,7 +39,7 @@ export function PromptFontPreview() {
39 contextRecords={EMPTY_COMPOSER_CONTEXT_RECORDS}
40 skills={PREVIEW_SKILLS}
41 disabled={false}
42 - placeholder={DISCONNECTED_COMPOSER_PLACEHOLDER}
42 + placeholder={DEFAULT_COMPOSER_PLACEHOLDER}
43 className="max-h-42 min-h-14"
44 onChange={onChange}
45 onPaste={noop}
apps/web/src/components/settings/SettingsPanels.tsx
+13 -5
@@ -409,6 +409,12 @@ export function useSettingsRestore(onRestored?: () => void) {
409 ...(settings.mathRenderingEnabled !== DEFAULT_UNIFIED_SETTINGS.mathRenderingEnabled
410 ? ["Render math"]
411 : []),
412 + ...(settings.sidebarProjectIconColors !== DEFAULT_UNIFIED_SETTINGS.sidebarProjectIconColors
413 + ? ["Colored project icons"]
414 + : []),
415 + ...(settings.redesignEnabled !== DEFAULT_UNIFIED_SETTINGS.redesignEnabled
416 + ? ["New design"]
417 + : []),
418 ...(settings.panelAnimationDurationMs !== DEFAULT_UNIFIED_SETTINGS.panelAnimationDurationMs
419 ? ["Panel animations"]
420 : []),
@@ -448,10 +454,10 @@ export function useSettingsRestore(onRestored?: () => void) {
454 ? ["Auto-settle merged threads"]
455 : []),
456 ...(settings.autoResumeLimitedThreads !== DEFAULT_UNIFIED_SETTINGS.autoResumeLimitedThreads
451 - ? ["Auto-resume limited threads"]
457 + ? ["Resume after usage limits"]
458 : []),
459 ...(settings.snoozeLimitedThreads !== DEFAULT_UNIFIED_SETTINGS.snoozeLimitedThreads
454 - ? ["Snooze limited threads"]
460 + ? ["Snooze until limits reset"]
461 : []),
462 ...(settings.wordWrap !== DEFAULT_UNIFIED_SETTINGS.wordWrap ? ["Word wrap"] : []),
463 ...(settings.persistComposerContextStrip !==
@@ -582,6 +588,8 @@ export function useSettingsRestore(onRestored?: () => void) {
588 diffColorScheme: DEFAULT_UNIFIED_SETTINGS.diffColorScheme,
589 chatWidth: DEFAULT_UNIFIED_SETTINGS.chatWidth,
590 mathRenderingEnabled: DEFAULT_UNIFIED_SETTINGS.mathRenderingEnabled,
591 + sidebarProjectIconColors: DEFAULT_UNIFIED_SETTINGS.sidebarProjectIconColors,
592 + redesignEnabled: DEFAULT_UNIFIED_SETTINGS.redesignEnabled,
593 timestampFormat: DEFAULT_UNIFIED_SETTINGS.timestampFormat,
594 notificationMode: DEFAULT_UNIFIED_SETTINGS.notificationMode,
595 inAppNotificationsEnabled: DEFAULT_UNIFIED_SETTINGS.inAppNotificationsEnabled,
@@ -949,14 +957,14 @@ export function GeneralSettingsPanel() {
957 onCheckedChange={(checked) =>
958 updateSettings({ autoResumeLimitedThreads: Boolean(checked) })
959 }
952 - aria-label="Auto-resume limited threads"
960 + aria-label="Resume after usage limits"
961 />
962 }
963 />
964 <SettingsRow
965 serverScoped
966 {...searchableSetting("snooze-limited-threads")}
959 - description="Snooze usage-limit stops until the reported reset time. Combine with auto-resume to continue when they wake."
967 + description="Snooze usage-limit stops until reset. Pair with resume to continue on wake."
968 settingKeys={["snoozeLimitedThreads"]}
969 control={
970 <ScopedSwitch
@@ -965,7 +973,7 @@ export function GeneralSettingsPanel() {
973 onCheckedChange={(checked) =>
974 updateSettings({ snoozeLimitedThreads: Boolean(checked) })
975 }
968 - aria-label="Snooze limited threads"
976 + aria-label="Snooze until limits reset"
977 />
978 }
979 />
apps/web/src/components/settings/SettingsScopeSentence.tsx
+8 -4
@@ -7,7 +7,7 @@ import type { SidebarProjectSnapshot } from "../../sidebarProjectGrouping";
7 import { useEnvironments, type EnvironmentPresentation } from "../../state/environments";
8 import { EnvironmentMachineIcon } from "../EnvironmentMachineIcon";
9 import { ProjectFavicon } from "../ProjectFavicon";
10 -import { InlineButton } from "../ui/button";
10 +import { Button } from "../ui/button";
11 import {
12 Combobox,
13 ComboboxEmpty,
@@ -69,7 +69,7 @@ export function SettingsScopeSentence() {
69 onChange: scope.selectScope,
70 };
71 return (
72 - <p className="flex min-w-0 flex-wrap items-center gap-x-1.5 gap-y-1 px-3 text-base text-muted-foreground sm:px-4">
72 + <p className="flex min-w-0 flex-wrap items-center gap-x-1.5 gap-y-1 px-3 text-sm text-muted-foreground sm:px-4">
73 <span className="flex min-w-0 items-center gap-1.5">
74 <span className="shrink-0">Applying settings for</span>
75 <ProjectScopeMenu {...props} />
@@ -133,12 +133,16 @@ function ScopeMenu({
133 const trigger = (
134 <Trigger
135 aria-label={`${ariaLabel}: ${label}`}
136 - render={<InlineButton tone="picker" />}
136 + render={<Button variant="outline" size="sm" />}
137 className="min-w-0 max-w-72"
138 >
139 {icon}
140 <span className="min-w-0 truncate">{label}</span>
141 - <ChevronDownIcon aria-hidden className="size-3.5 shrink-0 text-muted-foreground" />
141 + <ChevronDownIcon
142 + aria-hidden
143 + strokeWidth={1.75}
144 + className="-me-0.5 size-3.5 shrink-0 text-muted-foreground opacity-70"
145 + />
146 </Trigger>
147 );
148 const choices = allOption ? [allOption, ...options] : options;
apps/web/src/components/settings/SettingsSidebarNav.tsx
+1 -1
@@ -105,7 +105,7 @@ const SETTINGS_NAV_ITEMS: ReadonlyArray<{
105
106 function SettingsSectionIcon({ to }: { to: SettingsPath }) {
107 const Icon = SETTINGS_SECTION_ICONS[to];
108 - return <Icon className="size-3.5 h-5 shrink-0 text-sidebar-muted-foreground/60" />;
108 + return <Icon className="size-4 shrink-0 text-(--sidebar-icon-color)" />;
109 }
110
111 export function SettingsSidebarNav({ pathname }: { pathname: string }) {
apps/web/src/components/settings/settingsLayout.tsx
+15 -5
@@ -183,7 +183,9 @@ export function SettingsSearchTarget({
183 );
184 }
185
186 -export const SETTINGS_PICKER_TRIGGER_CLASSNAME = "min-w-0 max-w-none shrink-0";
186 +// Settings pickers reuse composer controls but match the bordered selects beside them.
187 +export const SETTINGS_PICKER_TRIGGER_CLASSNAME =
188 + "min-w-0 max-w-none shrink-0 border-input bg-background font-normal text-foreground shadow-xs/5 hover:bg-accent/50 dark:bg-input/32 [&_svg[data-composer-control-chevron]]:stroke-[1.75] [&_svg[data-composer-control-chevron]]:opacity-70";
189
190 export function PolicyTooltip({ children }: { readonly children: string }) {
191 return (
@@ -246,7 +248,7 @@ export function SettingsSection({
248 className="flex min-h-7 items-start justify-between gap-4 px-3 sm:px-4"
249 >
250 <div className="flex min-w-0 items-center gap-1">
249 - <h2 className="flex min-h-7 items-center gap-2 text-sm font-normal text-foreground/70">
251 + <h2 className="flex min-h-7 items-center gap-2 text-base font-semibold text-foreground">
252 {icon}
253 {title}
254 </h2>
@@ -473,7 +475,7 @@ export function SettingsRow({
475 tabIndex={rowProps.id ? -1 : rowProps.tabIndex}
476 data-slot="settings-row"
477 className={cn(
476 - "@container/settings-row rounded-xl px-3 sm:px-4 aria-disabled:opacity-64 aria-disabled:[&_*]:text-muted-foreground",
478 + "group/settings-row @container/settings-row rounded-xl px-3 sm:px-4 aria-disabled:opacity-64 aria-disabled:[&_*]:text-muted-foreground",
479 children ? "pt-3 pb-1" : "py-3",
480 className,
481 )}
@@ -483,7 +485,15 @@ export function SettingsRow({
485 <div className="flex min-h-5 items-center gap-1.5">
486 <h3 className="text-sm font-medium text-foreground">{title}</h3>
487 {renderedInheritance ? (
486 - <span className="inline-flex h-5 w-5 shrink-0 items-center justify-center">
488 + <span
489 + className={cn(
490 + "inline-flex h-5 w-5 shrink-0 items-center justify-center",
491 + // Values set right here explain nothing new, so their marker waits for hover or focus.
492 + (inheritance.state === "default" || inheritance.state === "environment") &&
493 + overridingProjects.length === 0 &&
494 + "opacity-0 group-hover/settings-row:opacity-100 has-focus-visible:opacity-100 has-data-popup-open:opacity-100",
495 + )}
496 + >
497 {renderedInheritance}
498 </span>
499 ) : null}
@@ -492,7 +502,7 @@ export function SettingsRow({
502 </span>
503 </div>
504 {description ? (
495 - <p className="max-w-xl text-xs leading-normal text-muted-foreground/80">
505 + <p className="max-w-2xl text-balance text-xs leading-normal text-muted-foreground">
506 {description}
507 </p>
508 ) : null}
apps/web/src/components/settings/settingsSearch.test.ts
+1
@@ -121,6 +121,7 @@ describe("searchSettings", () => {
121 "auto-settle-inactive-threads",
122 "auto-settle-merged-threads",
123 "days-before-auto-settle",
124 + "sidebar-project-icon-colors",
125 ]);
126 expect(available.map((item) => item.id).filter((id) => gatedIds.has(id))).toEqual([]);
127 });
apps/web/src/components/settings/settingsSearch.ts
+19 -3
@@ -59,6 +59,7 @@ export interface SettingsSearchItem {
59 readonly localEnvironmentOnly?: boolean;
60 readonly wslAvailableOnly?: boolean;
61 readonly managedTunnelOnly?: boolean;
62 + readonly redesignOnly?: boolean;
63 readonly secondary?: boolean;
64 readonly requiresThreadAutoSettlement?: boolean;
65 }
@@ -73,6 +74,7 @@ export interface SettingsSearchAvailability {
74 readonly isWslSettingsRowVisible: boolean;
75 readonly hasThreadAutoSettlement: boolean;
76 readonly managedTunnelActive?: boolean;
77 + readonly redesignEnabled?: boolean;
78 }
79
80 export const SETTINGS_SECTION_LABELS: Readonly<Record<SettingsPath, string>> = {
@@ -263,6 +265,13 @@ export const SETTINGS_SEARCH_ITEMS = [
265 to: "/settings/appearance",
266 searchTerms: ["wide full width column layout messages composer monitor"],
267 },
268 + {
269 + id: "sidebar-project-icon-colors",
270 + title: "Colored project icons",
271 + to: "/settings/appearance",
272 + searchTerms: ["sidebar favicon logo grayscale gray color"],
273 + redesignOnly: true,
274 + },
275 {
276 id: "math-rendering",
277 title: "Render math",
@@ -337,16 +346,22 @@ export const SETTINGS_SEARCH_ITEMS = [
346 },
347 {
348 id: "snooze-limited-threads",
340 - title: "Snooze limited threads",
349 + title: "Snooze until limits reset",
350 to: "/settings/general",
351 searchTerms: ["usage quota rate limit reset wake recover continue"],
352 },
353 {
354 id: "auto-resume-limited-threads",
346 - title: "Auto-resume limited threads",
355 + title: "Resume after usage limits",
356 to: "/settings/general",
357 searchTerms: ["usage quota rate limit reset recover continue"],
358 },
359 + {
360 + id: "new-design",
361 + title: "New design",
362 + to: "/settings/beta",
363 + searchTerms: ["beta redesign look style sidebar composer gray quieter classic"],
364 + },
365 {
366 id: "working-shelf",
367 title: "Working section",
@@ -1168,7 +1183,8 @@ export function filterAvailableSettingsSearchItems(
1183 (!item.localEnvironmentOnly || !availability.localEnvironmentDisabled) &&
1184 (!item.wslAvailableOnly || availability.isWslSettingsRowVisible) &&
1185 (!item.requiresThreadAutoSettlement || availability.hasThreadAutoSettlement) &&
1171 - (!item.managedTunnelOnly || availability.managedTunnelActive === true),
1186 + (!item.managedTunnelOnly || availability.managedTunnelActive === true) &&
1187 + (!item.redesignOnly || availability.redesignEnabled === true),
1188 );
1189 }
1190
apps/web/src/components/settings/useAvailableSettingsSearchItems.ts
+3
@@ -3,6 +3,7 @@ import { AuthEnvironmentMaintainScope } from "@t3tools/contracts";
3 import { usePrimaryCloudLinkState } from "~/cloud/primaryCloudLinkState";
4 import { hasCloudPublicConfig } from "~/cloud/publicConfig";
5 import { isElectron } from "~/env";
6 +import { useClientSettings } from "~/hooks/useSettings";
7 import { isLocalEnvironmentDisabled } from "~/localEnvironment";
8 import { desktopWslStateAtom } from "~/state/desktopWslState";
9 import { useEnvironments, usePrimaryEnvironmentId } from "~/state/environments";
@@ -53,6 +54,7 @@ export function useAvailableSettingsSearchItems(scopeSearch: SettingsScopeSearch
54 isElectron && canManageLocalBackend ? desktopWslStateAtom : null,
55 );
56 const cloudPublicConfig = hasCloudPublicConfig() === true;
57 + const redesignEnabled = useClientSettings((settings) => settings.redesignEnabled);
58 const wslSettingsRowVisible =
59 isWslSettingsRowVisible({ state: desktopWsl.data, error: desktopWsl.error }) === true;
60
@@ -66,5 +68,6 @@ export function useAvailableSettingsSearchItems(scopeSearch: SettingsScopeSearch
68 isWslSettingsRowVisible: wslSettingsRowVisible,
69 hasThreadAutoSettlement,
70 managedTunnelActive,
71 + redesignEnabled,
72 });
73 }
apps/web/src/components/sidebar/SidebarListMarkers.tsx
+12 -4
@@ -3,6 +3,7 @@ import { useSortable } from "@dnd-kit/sortable";
3 import { CSS } from "@dnd-kit/utilities";
4 import { type ReactNode } from "react";
5 import { cn } from "~/lib/utils";
6 +import { useClientSettings } from "../../hooks/useSettings";
7 import {
8 animateSidebarLayoutChanges,
9 sidebarMarkerId,
@@ -102,6 +103,8 @@ export function SidebarDragBoundary(props: {
103 export function SidebarSectionHeader(props: {
104 marker: "working-header" | "snoozed-header" | "settled-header";
105 label: string;
106 + /** Shown as a muted trailing count while the shelf is collapsed. */
107 + count: number;
108 className?: string;
109 dragging?: boolean;
110 isDropTarget?: boolean;
@@ -113,7 +116,8 @@ export function SidebarSectionHeader(props: {
116 : props.marker === "snoozed-header"
117 ? "snoozed"
118 : "settled";
116 - const snoozed = shelf === "snoozed";
119 + const redesign = useClientSettings((s) => s.redesignEnabled);
120 + const collapsedCount = props.toggle.expanded ? null : props.count;
121 return (
122 <SortableSidebarMarker
123 marker={props.marker}
@@ -123,12 +127,16 @@ export function SidebarSectionHeader(props: {
127 <CollapsibleSectionHeader
128 onClick={props.toggle.onToggle}
129 expanded={props.toggle.expanded}
126 - tone={
127 - props.isDropTarget ? "accent" : props.dragging ? "emphasized" : snoozed ? "info" : "muted"
128 - }
130 + tone={props.isDropTarget ? "accent" : props.dragging ? "emphasized" : "muted"}
131 data-testid={`sidebar-${shelf}-shelf-toggle`}
132 + accessory={
133 + redesign && collapsedCount !== null ? (
134 + <span className="font-normal tabular-nums">{collapsedCount}</span>
135 + ) : null
136 + }
137 >
138 {props.label}
139 + {!redesign && collapsedCount !== null ? ` (${collapsedCount})` : null}
140 </CollapsibleSectionHeader>
141 </SortableSidebarMarker>
142 );
apps/web/src/components/sidebar/SidebarThreadRow.tsx
+31 -18
@@ -111,6 +111,7 @@ import { Menu, MenuItem, MenuPopup, MenuSeparator, MenuShortcut, MenuTrigger } f
111 import { Tooltip, TooltipPopup, TooltipTrigger } from "../ui/tooltip";
112 import { MiddleTruncate } from "../ui/middle-truncate";
113 import { useThreadHasUnsentDraft } from "../../composerDraftStore";
114 +import { useClientSettings } from "../../hooks/useSettings";
115
116 // The fields thread rows show. Provider status pushes refresh `checkedAt`,
117 // status and auth on every provider; leaving those out keeps each
@@ -197,7 +198,7 @@ function SidebarProviderStack(props: {
198 acpRegistryIconUrl={currentEntry.acpRegistryIconUrl}
199 showBadge={showInstanceBadge}
200 size="compact"
200 - iconClassName="opacity-60"
201 + iconClassName="opacity-60 redesign:opacity-50 redesign:grayscale"
202 />
203 );
204 if (stack.length === 1) {
@@ -642,6 +643,7 @@ const SidebarThreadRow = memo(function SidebarThreadRow(props: SidebarThreadRowP
643 wokeAtDate !== null &&
644 (lastVisitedDate === null || lastVisitedDate < wokeAtDate) &&
645 thread.settledOverride !== "settled";
646 + const projectIconColors = useClientSettings((s) => s.sidebarProjectIconColors);
647 const shouldRecede = shouldRecedeSidebarThread({
648 status,
649 isUnread,
@@ -654,7 +656,7 @@ const SidebarThreadRow = memo(function SidebarThreadRow(props: SidebarThreadRowP
656 ? {
657 label: thread.goal?.status === "active" ? "Goal" : "Working",
658 icon: "working" as const,
657 - className: "text-info",
659 + className: "text-info-foreground",
660 }
661 : status === "waiting"
662 ? {
@@ -684,25 +686,25 @@ const SidebarThreadRow = memo(function SidebarThreadRow(props: SidebarThreadRowP
686 ? {
687 label: "Limited",
688 icon: "failed" as const,
687 - className: "text-warning",
689 + className: "text-warning-foreground",
690 }
691 : status === "failed"
692 ? {
693 label: "Failed",
694 icon: "failed" as const,
693 - className: "text-error",
695 + className: "text-error-foreground",
696 }
697 : isWoke
698 ? {
699 label: "Woke",
700 icon: "woke" as const,
699 - className: "text-warning",
701 + className: "text-warning-foreground",
702 }
703 : isUnread
704 ? {
705 label: "Done",
706 icon: "done" as const,
705 - className: "text-success",
707 + className: "text-success-foreground",
708 }
709 : null;
710 const isWokeStatus = topStatus?.icon === "woke";
@@ -892,11 +894,13 @@ const SidebarThreadRow = memo(function SidebarThreadRow(props: SidebarThreadRowP
894
895 const rowSurfaceClassName = cn(
896 "group/sidebar-row relative w-full cursor-pointer overflow-hidden rounded-md text-left outline-none select-none focus-visible:ring-2 focus-visible:ring-inset focus-visible:ring-ring",
895 - variantAction === "unsettle" && "[&:not(:hover):not(:focus-within)_*]:text-secondary-label/70",
897 + variantAction === "unsettle" &&
898 + !props.isActive &&
899 + "[&:not(:hover):not(:focus-within)_*]:text-secondary-label/70",
900 props.isActive
897 - ? "bg-sidebar-row-active text-sidebar-foreground"
901 + ? "bg-sidebar-row-active text-sidebar-foreground light:shadow-xs light:ring-1 light:ring-inset light:ring-sidebar-border/70"
902 : isSelected || props.sweepAction !== null
899 - ? "bg-sidebar-row-selected text-sidebar-foreground"
903 + ? "bg-sidebar-row-selected text-sidebar-foreground light:ring-1 light:ring-inset light:ring-sidebar-border/70"
904 : hasUnsentDraft
905 ? cn(draftSurfaceClassName, "text-sidebar-foreground")
906 : shouldRecede
@@ -974,12 +978,12 @@ const SidebarThreadRow = memo(function SidebarThreadRow(props: SidebarThreadRowP
978 ? cn(
979 "truncate",
980 shouldRecede
977 - ? "text-secondary-label"
981 + ? "text-secondary-label redesign:text-foreground/75 redesign:group-hover/sidebar-row:text-foreground redesign:group-focus-visible/sidebar-row:text-foreground"
982 : isUnread || isWoke || status === "input" || status === "request"
983 ? "text-foreground"
984 : status === "failed"
985 ? "text-foreground/95"
982 - : "text-foreground/90",
986 + : "text-foreground/90 redesign:text-foreground",
987 )
988 : cn(
989 "truncate group-focus-within/sidebar-row:text-foreground group-hover/sidebar-row:text-foreground",
@@ -1273,7 +1277,16 @@ const SidebarThreadRow = memo(function SidebarThreadRow(props: SidebarThreadRowP
1277 <div className="flex h-5 min-w-0 items-center gap-1.5">
1278 {draftIndicator}
1279 {props.project ? (
1276 - <ProjectFavicon project={props.project} className="size-4 shrink-0" />
1280 + <ProjectFavicon
1281 + project={props.project}
1282 + className={cn(
1283 + "size-4 shrink-0",
1284 + // Repeated brand colors outshout titles; color returns on the row in focus.
1285 + !props.isActive &&
1286 + !projectIconColors &&
1287 + "redesign:opacity-60 redesign:grayscale redesign:group-focus-visible/sidebar-row:opacity-100 redesign:group-focus-visible/sidebar-row:grayscale-0 redesign:group-any-hover/sidebar-row:opacity-100 redesign:group-any-hover/sidebar-row:grayscale-0",
1288 + )}
1289 + />
1290 ) : null}
1291 {/* Left of the status slot, the pin would slide when hover swaps the
1292 label for the wider row controls. */}
@@ -1282,7 +1295,7 @@ const SidebarThreadRow = memo(function SidebarThreadRow(props: SidebarThreadRowP
1295 <span
1296 className={cn(
1297 "min-w-0 flex-1 truncate text-secondary-label text-xs",
1285 - shouldRecede ? "font-normal" : "font-medium",
1298 + shouldRecede ? "font-normal" : "font-medium redesign:font-normal",
1299 )}
1300 >
1301 {props.projectDisplayName}
@@ -1304,7 +1317,7 @@ const SidebarThreadRow = memo(function SidebarThreadRow(props: SidebarThreadRowP
1317 isWokeStatus
1318 ? "pointer-events-auto"
1319 : "pointer-events-none group-has-[:focus-visible]/sidebar-status-slot:absolute group-has-[:focus-visible]/sidebar-status-slot:right-0 group-has-[:focus-visible]/sidebar-status-slot:opacity-0 group-any-hover/sidebar-row:absolute group-any-hover/sidebar-row:right-0 group-any-hover/sidebar-row:opacity-0",
1307 - "flex items-center self-center justify-self-end tabular-nums text-secondary-label transition-opacity",
1320 + "flex items-center self-center justify-self-end tabular-nums text-secondary-label",
1321 snoozeMenuOpen && "pointer-events-none absolute right-0 opacity-0",
1322 )}
1323 >
@@ -1375,7 +1388,7 @@ const SidebarThreadRow = memo(function SidebarThreadRow(props: SidebarThreadRowP
1388 className={cn(
1389 // Mouse clicks leave Settle focused; focus-within would pin controls over
1390 // the status label after the pointer leaves. Use focus-visible instead.
1378 - "pointer-events-none absolute inset-y-0 right-0 flex items-stretch opacity-0 transition-opacity has-[:focus-visible]:pointer-events-auto has-[:focus-visible]:static has-[:focus-visible]:opacity-100 group-any-hover/sidebar-row:pointer-events-auto group-any-hover/sidebar-row:static group-any-hover/sidebar-row:opacity-100",
1391 + "pointer-events-none absolute inset-y-0 right-0 flex items-stretch opacity-0 has-[:focus-visible]:pointer-events-auto has-[:focus-visible]:static has-[:focus-visible]:opacity-100 group-any-hover/sidebar-row:pointer-events-auto group-any-hover/sidebar-row:static group-any-hover/sidebar-row:opacity-100",
1392 snoozeMenuOpen && "pointer-events-auto static opacity-100",
1393 )}
1394 >
@@ -1441,7 +1454,7 @@ const SidebarThreadRow = memo(function SidebarThreadRow(props: SidebarThreadRowP
1454 {thread.branch ? (
1455 <>
1456 <ThreadWorktreeIndicator thread={thread} />
1444 - <span className="flex min-w-0 flex-1 text-muted-foreground/40">
1457 + <span className="flex min-w-0 flex-1 text-muted-foreground/40 redesign:text-inherit">
1458 <MiddleTruncate value={thread.branch} showTitle={false} />
1459 </span>
1460 </>
@@ -1450,9 +1463,9 @@ const SidebarThreadRow = memo(function SidebarThreadRow(props: SidebarThreadRowP
1463 <EnvironmentMachineIcon
1464 aria-hidden
1465 kind={props.environmentMachine}
1453 - className="size-3 shrink-0 text-muted-foreground/40"
1466 + className="size-3 shrink-0 text-muted-foreground/40 redesign:text-inherit"
1467 />
1455 - <span className="min-w-0 flex-1 truncate text-muted-foreground/40">
1468 + <span className="min-w-0 flex-1 truncate text-muted-foreground/40 redesign:text-inherit">
1469 {props.scratchMachineLabel}
1470 </span>
1471 </>
apps/web/src/components/ui/button.tsx
+1 -1
@@ -106,7 +106,7 @@ const inlineButtonVariants = cva(
106 muted: "text-muted-foreground hover:text-foreground",
107 destructive: "text-destructive/80 hover:text-destructive",
108 picker:
109 - "gap-1.5 text-foreground underline decoration-foreground/30 decoration-dotted decoration-from-font underline-offset-4 hover:decoration-foreground hover:decoration-solid data-popup-open:decoration-foreground data-popup-open:decoration-solid",
109 + "gap-1 text-foreground underline decoration-foreground/30 decoration-dotted decoration-from-font underline-offset-4 hover:decoration-foreground hover:decoration-solid data-popup-open:decoration-foreground data-popup-open:decoration-solid redesign:no-underline redesign:hover:underline redesign:data-popup-open:underline",
110 },
111 },
112 },
apps/web/src/components/ui/collapsible-section-header.tsx
+14 -4
@@ -3,8 +3,7 @@ import { ChevronDownIcon } from "lucide-react";
3 import { cn } from "../../lib/utils";
4
5 const tones = {
6 - muted: { label: "text-sidebar-muted-foreground/60", line: "bg-sidebar-border/60" },
7 - info: { label: "text-blue-600 dark:text-blue-400", line: "bg-blue-500/20 dark:bg-blue-400/15" },
6 + muted: { label: "text-sidebar-muted-foreground", line: "bg-sidebar-border/50" },
7 emphasized: { label: "text-sidebar-foreground/80", line: "bg-sidebar-foreground/25" },
8 accent: { label: "text-primary", line: "bg-primary/50" },
9 } as const;
@@ -34,11 +33,22 @@ export function CollapsibleSectionHeader({
33 )}
34 >
35 <span className="shrink-0">{children}</span>
37 - <span aria-hidden className={cn("h-px min-w-2 flex-1", tones[tone].line)} />
36 + <span
37 + aria-hidden
38 + // A collapsed header with a trailing count drops its rule so it doesn't read as a leader.
39 + className={cn(
40 + "h-px min-w-2 flex-1",
41 + tones[tone].line,
42 + !expanded && accessory && "invisible",
43 + )}
44 + />
45 {accessory}
46 <ChevronDownIcon
47 aria-hidden
41 - className={cn("size-3 shrink-0 transition-transform", !expanded && "rotate-180")}
48 + className={cn(
49 + "size-3 shrink-0 transition-transform",
50 + !expanded && "rotate-180 redesign:-rotate-90",
51 + )}
52 />
53 </button>
54 );
apps/web/src/components/ui/menu.tsx
+1 -1
@@ -197,7 +197,7 @@ function MenuCheckboxItem({
197 stroke="currentColor"
198 strokeLinecap="round"
199 strokeLinejoin="round"
200 - strokeWidth="2"
200 + strokeWidth="1.75"
201 viewBox="0 0 24 24"
202 width="24"
203 xmlns="http://www.w3.org/2000/svg"
apps/web/src/components/ui/middle-truncate.test.ts new
+29
@@ -0,0 +1,29 @@
1 +import { describe, expect, it } from "vite-plus/test";
2 +
3 +import { splitForMiddleTruncate } from "./middle-truncate";
4 +
5 +describe("splitForMiddleTruncate", () => {
6 + it("keeps a short last path segment whole", () => {
7 + expect(splitForMiddleTruncate("feature/ui-polish")).toEqual({
8 + head: "feature/",
9 + tail: "ui-polish",
10 + });
11 + });
12 +
13 + it("starts a long segment's tail on a word, not mid-word", () => {
14 + expect(splitForMiddleTruncate("t3/clone-repo-to-other-machine")?.tail).toBe("machine");
15 + expect(splitForMiddleTruncate("t3/investigate-release-build-times")?.tail).toBe("times");
16 + });
17 +
18 + it("falls back to an earlier word when the last one is too short", () => {
19 + expect(splitForMiddleTruncate("t3/compare-long-featurenames-ab")?.tail).toBe("featurenames-ab");
20 + });
21 +
22 + it("keeps the fixed tail when no word break is near", () => {
23 + expect(splitForMiddleTruncate("t3/abcdefghijklmnopqrstuvwxyz")?.tail).toBe("qrstuvwxyz");
24 + });
25 +
26 + it("respects an explicit tail length", () => {
27 + expect(splitForMiddleTruncate("t3/clone-repo-to-other-machine", 6)?.tail).toBe("achine");
28 + });
29 +});
apps/web/src/components/ui/middle-truncate.tsx
+73 -5
@@ -1,5 +1,6 @@
1 -import type { ComponentProps } from "react";
1 +import { type ComponentProps, useLayoutEffect, useRef } from "react";
2
3 +import { observeResize } from "~/lib/observeResize";
4 import { cn } from "~/lib/utils";
5
6 export function MiddleTruncate({
@@ -16,21 +17,34 @@ export function MiddleTruncate({
17 variant?: "default" | "cap-aligned";
18 }) {
19 const split = splitForMiddleTruncate(value, tail);
20 + const headRef = useRef<HTMLSpanElement>(null);
21 + const head = split?.head;
22 + useLayoutEffect(() => {
23 + const element = headRef.current;
24 + // A new head can keep the same box size, so refit here, not only on resize.
25 + if (!element || head === undefined) return;
26 + fitHead(element);
27 + return observeResize(element, () => fitHead(element));
28 + }, [head]);
29 return (
30 <span
31 {...(showTitle ? { title: value } : {})}
32 className={cn(
33 "inline-flex min-w-0 max-w-full overflow-hidden whitespace-nowrap",
34 variant === "cap-aligned" &&
25 - "overflow-x-clip overflow-y-visible [&>span]:[text-box:trim-both_cap_alphabetic] [&>span]:overflow-x-clip [&>span]:overflow-y-visible",
35 + // Padding keeps descenders inside the box, so the cut does not clip them.
36 + "overflow-x-clip overflow-y-visible [&>span]:[text-box:trim-both_cap_alphabetic] [&>span]:-mb-1 [&>span]:pb-1 [&>span]:overflow-x-clip [&>span]:overflow-y-visible",
37 className,
38 )}
39 {...props}
40 >
41 {split ? (
42 <>
32 - <span className="min-w-0 truncate">{split.head}</span>
33 - <span className="shrink-0">{split.tail}</span>
43 + {/* The tail carries the ellipsis so it sits flush; a CSS ellipsis leaves a ragged gap. */}
44 + <span ref={headRef} className="peer min-w-0 overflow-hidden">
45 + {split.head}
46 + </span>
47 + <span className="shrink-0 peer-data-overflow:before:content-['…']">{split.tail}</span>
48 </>
49 ) : (
50 <span className="min-w-0 truncate">{value}</span>
@@ -39,8 +53,42 @@ export function MiddleTruncate({
53 );
54 }
55
56 +// An overflowing head is cut after its last whole character: clip the partial glyph
57 +// and slide the tail left over the slack. Neither changes layout, so the observed
58 +// size stays the true available width.
59 +
60 +function fitHead(head: HTMLElement) {
61 + const text = head.firstChild;
62 + const overflowing = head.scrollWidth > head.clientWidth && text instanceof Text;
63 + head.toggleAttribute("data-overflow", overflowing);
64 + let slack = 0;
65 + if (overflowing) {
66 + const range = document.createRange();
67 + const left = head.getBoundingClientRect().left;
68 + const widthTo = (end: number) => {
69 + range.setStart(text, 0);
70 + range.setEnd(text, end);
71 + return range.getBoundingClientRect().right - left;
72 + };
73 + let fits = 0;
74 + let over = text.length;
75 + while (over - fits > 1) {
76 + const mid = (fits + over) >> 1;
77 + if (widthTo(mid) <= head.clientWidth) fits = mid;
78 + else over = mid;
79 + }
80 + if (/[\uD800-\uDBFF]/.test(text.data[fits - 1] ?? "")) fits -= 1;
81 + slack = Math.max(0, head.clientWidth - widthTo(fits));
82 + }
83 + head.style.clipPath = slack > 0 ? `inset(-0.25em ${slack}px -0.25em 0)` : "";
84 + const tail = head.nextElementSibling;
85 + if (tail instanceof HTMLElement) tail.style.translate = slack > 0 ? `-${slack}px 0` : "";
86 +}
87 +
88 const DEFAULT_TAIL = 10;
89 const MAX_SEGMENT_TAIL = 16;
90 +const MIN_WORD_TAIL = 4;
91 +const WORD_BREAK = /[-_./]/;
92
93 export function splitForMiddleTruncate(
94 value: string,
@@ -57,6 +105,26 @@ export function splitForMiddleTruncate(
105 }
106 }
107 if (keep <= 0 || chars.length <= keep + 4) return null;
60 - const cut = chars.length - keep;
108 + let cut = chars.length - keep;
109 + // Start an automatic tail on a word ("machine", not "er-machine"). A shorter tail is
110 + // preferred so the head stays readable; a longer one is the fallback.
111 + if (tail === undefined && !WORD_BREAK.test(chars[cut - 1]!)) {
112 + const startsWord = (index: number) => WORD_BREAK.test(chars[index - 1]!);
113 + let snapped = -1;
114 + for (let index = cut + 1; index <= chars.length - MIN_WORD_TAIL; index++) {
115 + if (startsWord(index)) {
116 + snapped = index;
117 + break;
118 + }
119 + }
120 + for (
121 + let index = cut - 1;
122 + snapped < 0 && index >= chars.length - MAX_SEGMENT_TAIL && index > 4;
123 + index--
124 + ) {
125 + if (startsWord(index)) snapped = index;
126 + }
127 + if (snapped > 0) cut = snapped;
128 + }
129 return { head: chars.slice(0, cut).join(""), tail: chars.slice(cut).join("") };
130 }
apps/web/src/components/ui/select.tsx
+2 -2
@@ -52,7 +52,7 @@ function SelectTrigger({
52 >
53 {children}
54 <SelectPrimitive.Icon data-slot="select-icon">
55 - {icon ?? <ChevronDownIcon className="-me-1 size-3 opacity-50" />}
55 + {icon ?? <ChevronDownIcon className="-me-1 size-3.5 opacity-70" />}
56 </SelectPrimitive.Icon>
57 </SelectPrimitive.Trigger>
58 );
@@ -77,7 +77,7 @@ function SelectButton({
77 children: (
78 <>
79 <span className="min-w-0 flex-1 truncate text-left">{children}</span>
80 - <ChevronDownIcon aria-hidden className="-me-1 size-3 shrink-0 opacity-50" />
80 + <ChevronDownIcon aria-hidden className="-me-1 size-3.5 shrink-0 opacity-70" />
81 </>
82 ),
83 },
apps/web/src/composerPlaceholder.ts
+1 -2
@@ -1,2 +1 @@
1 -export const DISCONNECTED_COMPOSER_PLACEHOLDER =
2 - "Ask for changes, send follow-ups, or attach images";
1 +export const DEFAULT_COMPOSER_PLACEHOLDER = "Ask anything. @ files, $ skills, / commands";
apps/web/src/index.css
+47 -22
@@ -4,6 +4,9 @@
4 @custom-variant light (&:not(.dark, .dark *));
5 /* Window Controls Overlay: active when Electron exposes native titlebar control geometry. */
6 @custom-variant wco (&:is(.wco, .wco *));
7 +/* Beta "New design" (Settings -> Beta) sets data-redesign on <html>. The variant adds no
8 + specificity, so it loses to dark:, hover: and other variants on the same property. */
9 +@custom-variant redesign (&:where([data-redesign] *));
10
11 /* Secondary hovering pointers reveal sidebar actions on touch-primary devices. */
12 @custom-variant any-hover {
@@ -103,7 +106,7 @@ html[data-mobile-composer-route-transition="true"]::view-transition-old(t3-mobil
106 --sidebar-control-gap: 0.5rem;
107 --sidebar-icon-color: color-mix(
108 in srgb,
106 - var(--contrast-sidebar-muted-foreground) 60%,
109 + var(--contrast-sidebar-muted-foreground) 85%,
110 var(--sidebar)
111 );
112 --sidebar-row-content-inset: 0.625rem;
@@ -166,7 +169,8 @@ html[data-mobile-composer-route-transition="true"]::view-transition-old(t3-mobil
169 the variables and Settings -> Appearance can override them at runtime. The
170 default stacks are mirrored in `appearanceFonts.ts`. */
171 @theme {
169 - --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui, sans-serif;
172 + --font-sans:
173 + -apple-system, BlinkMacSystemFont, "Inter Variable", "Segoe UI", system-ui, sans-serif;
174 --font-mono:
175 ui-monospace, "SF Mono", "SFMono-Regular", Menlo, Consolas, "Liberation Mono", monospace;
176 }
@@ -192,7 +196,7 @@ html[data-mobile-composer-route-transition="true"]::view-transition-old(t3-mobil
196 --ease-drawer: cubic-bezier(0.32, 0.72, 0, 1);
197 /* The composer's elevation: a soft drop pulled in under the surface, shared
198 by the composer, its context strip and attached banners. */
195 - --shadow-composer: 0 12px 28px -18px rgb(0 0 0 / 40%);
199 + --shadow-composer: 0 1px 2px rgb(0 0 0 / 5%);
200 --shadow-composer-dark: 0 14px 32px -18px rgb(0 0 0 / 75%);
201 /* Overlap the lower toolbar backdrop by one pixel to cover the composer seam. */
202 --spacing-composer-seam: calc(var(--spacing) * 4 - 1px);
@@ -1093,7 +1097,7 @@ html[data-mobile-composer-route-transition="true"]::view-transition-old(t3-mobil
1097
1098 :root {
1099 color-scheme: light;
1096 - --radius: 0.625rem;
1100 + --radius: 0.5rem;
1101 --background: var(--color-zinc-25);
1102 --app-chrome-background: var(--background);
1103 --toolbar-background: var(--app-chrome-background);
@@ -1103,11 +1107,11 @@ html[data-mobile-composer-route-transition="true"]::view-transition-old(t3-mobil
1107 --toolbar-control-foreground: var(--foreground);
1108 --toolbar-control-hover: var(--accent);
1109 --surface-raised: color-mix(in srgb, var(--card) 20%, transparent);
1106 - --foreground: var(--color-zinc-800);
1110 + --foreground: var(--color-zinc-900);
1111 --card: var(--color-white);
1108 - --card-foreground: var(--color-zinc-800);
1112 + --card-foreground: var(--color-zinc-900);
1113 --popover: var(--color-white);
1110 - --popover-foreground: var(--color-zinc-800);
1114 + --popover-foreground: var(--color-zinc-900);
1115 --primary: oklch(0.488 0.217 264);
1116 --primary-foreground: var(--color-white);
1117 --secondary: var(--color-zinc-50);
@@ -1117,7 +1121,8 @@ html[data-mobile-composer-route-transition="true"]::view-transition-old(t3-mobil
1121 --placeholder: var(--muted-foreground);
1122 --secondary-label: var(--muted-foreground);
1123 --icon-muted: var(--muted-foreground);
1120 - --message-surface: var(--accent);
1124 + /* One step past the accent, so a user turn stands off the near-white canvas. */
1125 + --message-surface: color-mix(in srgb, var(--color-zinc-200) 55%, var(--color-zinc-100));
1126 --message-foreground: var(--foreground);
1127 --message-action: var(--primary);
1128 --message-action-foreground: var(--primary-foreground);
@@ -1180,15 +1185,16 @@ html[data-mobile-composer-route-transition="true"]::view-transition-old(t3-mobil
1185 --secondary: --alpha(var(--color-white) / 3%);
1186 --secondary-foreground: var(--color-neutral-100);
1187 --muted: --alpha(var(--color-white) / 3%);
1183 - --muted-foreground: color-mix(in srgb, var(--color-neutral-500) 90%, var(--color-white));
1188 + --muted-foreground: var(--color-neutral-400);
1189 --accent: --alpha(var(--color-white) / 4%);
1190 --accent-foreground: var(--color-neutral-100);
1191 + --message-surface: var(--accent);
1192 --error: color-mix(in srgb, var(--color-red-500) 90%, var(--color-white));
1193 --error-foreground: var(--color-red-400);
1194 --tool-error-icon: #fca5a5;
1195 --error-surface: color-mix(in srgb, var(--error) 16%, transparent);
1190 - --border: --alpha(var(--color-white) / 6%);
1191 - --input: --alpha(var(--color-white) / 8%);
1196 + --border: --alpha(var(--color-white) / 8%);
1197 + --input: --alpha(var(--color-white) / 11%);
1198 --info-foreground: var(--color-blue-400);
1199 --guest-foreground: var(--color-fuchsia-300);
1200 --success-foreground: var(--color-emerald-400);
@@ -1212,9 +1218,9 @@ html[data-mobile-composer-route-transition="true"]::view-transition-old(t3-mobil
1218 surfaces. */
1219 [data-app-sidebar] {
1220 --background: var(--color-zinc-25);
1215 - --foreground: var(--color-zinc-800);
1221 + --foreground: var(--color-zinc-900);
1222 --card: var(--color-white);
1217 - --card-foreground: var(--color-zinc-800);
1223 + --card-foreground: var(--color-zinc-900);
1224 --accent: var(--color-zinc-100);
1225 --accent-foreground: var(--color-zinc-900);
1226 --muted: var(--color-zinc-50);
@@ -1222,7 +1228,7 @@ html[data-mobile-composer-route-transition="true"]::view-transition-old(t3-mobil
1228 --border: var(--color-zinc-200);
1229 --input: var(--color-zinc-300);
1230 --sidebar: var(--color-zinc-50);
1225 - --sidebar-foreground: var(--color-zinc-800);
1231 + --sidebar-foreground: var(--color-zinc-900);
1232 --sidebar-muted-foreground: var(--color-zinc-500);
1233 --sidebar-control-surface: var(--color-zinc-100);
1234 --sidebar-row-hover: var(--color-zinc-25);
@@ -1658,6 +1664,21 @@ body {
1664 padding: 0;
1665 }
1666
1667 +/* New design: sidebar row metadata sits a step below read titles (75% white). */
1668 +[data-redesign] [data-app-sidebar] {
1669 + @variant dark {
1670 + --secondary-label: #8f8f8f;
1671 + }
1672 +}
1673 +
1674 +/* Lighter default icon stroke. In the base layer so stroke-* utilities still win; any
1675 + CSS beats lucide's stroke-width="2" attribute. */
1676 +@layer base {
1677 + :where(svg.lucide[stroke-width="2"]) {
1678 + stroke-width: 1.75;
1679 + }
1680 +}
1681 +
1682 html,
1683 body {
1684 min-height: calc(100svh + env(safe-area-inset-top));
@@ -2048,21 +2069,25 @@ code {
2069 }
2070
2071 .chat-markdown :not(pre) > code {
2051 - border: 1px solid var(--contrast-border);
2052 - border-radius: 0.375rem;
2072 + border: 1px solid transparent;
2073 + border-radius: 0.25rem;
2074 box-decoration-break: clone;
2075 -webkit-box-decoration-break: clone;
2055 - background: var(--muted);
2056 - padding: 0.1rem 0.35rem;
2076 + background: color-mix(in srgb, var(--contrast-foreground) 10%, transparent);
2077 + padding: 0.1em 0.35em;
2078 color: var(--contrast-foreground);
2058 - font-size: 0.75rem;
2079 + font-size: 0.85em;
2080 +}
2081 +
2082 +.chat-markdown strong {
2083 + font-weight: 600;
2084 }
2085
2086 .chat-markdown pre {
2087 max-width: 100%;
2088 overflow-x: auto;
2089 border: 1px solid var(--contrast-border);
2065 - border-radius: 0.75rem;
2090 + border-radius: 0.5rem;
2091 background: var(--muted);
2092 padding: 0.8rem 0.9rem;
2093 scrollbar-width: thin;
@@ -2203,8 +2228,8 @@ code {
2228 :root {
2229 --diff-addition: var(--success);
2230 --diff-deletion: var(--destructive);
2206 - --diff-addition-foreground: light-dark(var(--color-emerald-600), var(--color-emerald-400));
2207 - --diff-deletion-foreground: light-dark(var(--color-red-600), var(--color-red-400));
2231 + --diff-addition-foreground: light-dark(var(--color-emerald-700), var(--color-emerald-400));
2232 + --diff-deletion-foreground: light-dark(var(--color-red-700), var(--color-red-400));
2233 }
2234
2235 /* Chat width setting. Comfortable keeps the default --chat-content-max-width,
apps/web/src/main.tsx
+1
@@ -2,6 +2,7 @@ import React from "react";
2 import ReactDOM from "react-dom/client";
3 import { createHashHistory, createBrowserHistory } from "@tanstack/react-router";
4
5 +import "@fontsource-variable/inter";
6 import "./index.css";
7
8 import { prepareProviderAuthDelivery } from "./providerAuthDelivery";
apps/web/src/routes/__root.tsx
+4
@@ -294,6 +294,10 @@ function ContrastAppearanceSync() {
294 }, [diffColorScheme]);
295
296 const chatWidth = useClientSettings((settings) => settings.chatWidth);
297 + const redesignEnabled = useClientSettings((settings) => settings.redesignEnabled);
298 + useEffect(() => {
299 + document.documentElement.toggleAttribute("data-redesign", redesignEnabled);
300 + }, [redesignEnabled]);
301 useEffect(() => {
302 document.documentElement.dataset.chatWidth = chatWidth;
303 }, [chatWidth]);
docs/user/thread-sidebar.md
+3 -3
@@ -215,8 +215,8 @@ Queued messages stay saved while the limit blocks the thread. They run after
215 the continuation finishes. If the queue was held by a restart, resume it then.
216
217 When the provider reports a reset time, choose **Resume at reset** to schedule a
218 -continuation. You can cancel it from the thread. Enable **Auto-resume limited
219 -threads** in **Settings → General** on web and desktop, or **Settings → Thread
218 +continuation. You can cancel it from the thread. Enable **Resume after
219 +usage limits** in **Settings → General** on web and desktop, or **Settings → Thread
220 behavior** on mobile, to schedule limit stops by default.
221 The environment must be running when the reset arrives; it resumes overdue
222 continuations after a restart. Stopping the thread, sending a new message,
@@ -225,7 +225,7 @@ archiving, or settling it prevents a pending continuation from starting.
225 Choose **Snooze until reset** to hide the thread until its allowance returns.
226 Snooze and auto-resume are independent: snooze alone wakes the thread without
227 sending a message; enabling both wakes and continues it. **Wake now** cancels
228 -the snooze. Enable **Snooze limited threads** in thread behavior settings to
228 +the snooze. Enable **Snooze until limits reset** in thread behavior settings to
229 snooze limit stops by default. Providers without a reset time offer manual
230 retry and the normal snooze choices.
231
packages/contracts/src/settings.ts
+6
@@ -475,6 +475,10 @@ export const ClientSettingsSchema = Schema.Struct({
475 // Opt-in TeX typesetting in rendered Markdown. Off keeps math parsing and
476 // KaTeX out of the render path entirely.
477 mathRenderingEnabled: Schema.Boolean.pipe(Schema.withDecodingDefault(Effect.succeed(false))),
478 + // Sidebar project icons rest in grayscale so titles lead; this keeps their colors.
479 + sidebarProjectIconColors: Schema.Boolean.pipe(Schema.withDecodingDefault(Effect.succeed(false))),
480 + // Beta: the quieter sidebar, composer and panel design. Off keeps the current look.
481 + redesignEnabled: Schema.Boolean.pipe(Schema.withDecodingDefault(Effect.succeed(false))),
482 });
483 export type ClientSettings = typeof ClientSettingsSchema.Type;
484
@@ -1680,5 +1684,7 @@ export const ClientSettingsPatch = Schema.Struct({
1684 snapShotAnimations: Schema.optionalKey(Schema.Boolean),
1685 wordWrap: Schema.optionalKey(Schema.Boolean),
1686 mathRenderingEnabled: Schema.optionalKey(Schema.Boolean),
1687 + sidebarProjectIconColors: Schema.optionalKey(Schema.Boolean),
1688 + redesignEnabled: Schema.optionalKey(Schema.Boolean),
1689 });
1690 export type ClientSettingsPatch = typeof ClientSettingsPatch.Type;
pnpm-lock.yaml
+8
@@ -1013,6 +1013,9 @@ importers:
1013 '@effect/atom-react':
1014 specifier: 4.0.5
1015 version: 4.0.5(effect@4.0.5)(react@19.3.0)(scheduler@0.28.0)
1016 + '@fontsource-variable/inter':
1017 + specifier: ^5.3.0
1018 + version: 5.3.0
1019 '@formkit/auto-animate':
1020 specifier: ^0.9.0
1021 version: 0.9.0
@@ -4184,6 +4187,9 @@ packages:
4187 '@floating-ui/utils@0.2.11':
4188 resolution: {integrity: sha512-RiB/yIh78pcIxl6lLMG0CgBXAZ2Y0eVHqMPYugu+9U0AeT6YBeiJpf7lbdJNIugFP5SIjwNRgo4DhR1Qxi26Gg==}
4189
4190 + '@fontsource-variable/inter@5.3.0':
4191 + resolution: {integrity: sha512-OupL48va4JNofb97w6NYeF9S7W/kHNKM0Er8Dem5nqi4jeOLrVJDoE8tZEpnMJmtkvNbB1EIPPwHcdkF6b1oUA==}
4192 +
4193 '@formkit/auto-animate@0.9.0':
4194 resolution: {integrity: sha512-VhP4zEAacXS3dfTpJpJ88QdLqMTcabMg0jwpOSxZ/VzfQVfl3GkZSCZThhGC5uhq/TxPHPzW0dzr4H9Bb1OgKA==}
4195
@@ -14474,6 +14480,8 @@ snapshots:
14480
14481 '@floating-ui/utils@0.2.11': {}
14482
14483 + '@fontsource-variable/inter@5.3.0': {}
14484 +
14485 '@formkit/auto-animate@0.9.0': {}
14486
14487 '@hono/node-server@1.19.17(hono@4.13.7)':