TypeScript
fix(mobile): use selected theme across input forms and controls (#10239)
Julius Marmingeb438447f67b6
diff --git a/apps/mobile/generated-uniwind-default-theme-variables.json b/apps/mobile/generated-uniwind-default-theme-variables.jsonindex 427d370acb5..1953880fa94 100644--- a/apps/mobile/generated-uniwind-default-theme-variables.json+++ b/apps/mobile/generated-uniwind-default-theme-variables.json@@ -28,6 +28,9 @@"--color-switch-active-thumb": "#ffffff","--color-switch-inactive-track": "rgba(0, 0, 0, 0.08)","--color-switch-inactive-thumb": "#8e8e93",+ "--color-warning": "#fffbeb",+ "--color-warning-border": "#fde68a",+ "--color-warning-foreground": "#b45309","--color-danger": "#fef2f2","--color-danger-border": "rgba(239, 68, 68, 0.12)","--color-danger-foreground": "#dc2626",@@ -95,6 +98,9 @@"--color-switch-active-thumb": "#ffffff","--color-switch-inactive-track": "rgba(255, 255, 255, 0.06)","--color-switch-inactive-thumb": "#8e8e93",+ "--color-warning": "rgba(69, 26, 3, 0.4)",+ "--color-warning-border": "rgba(120, 53, 15, 0.6)",+ "--color-warning-foreground": "#fcd34d","--color-danger": "rgba(239, 68, 68, 0.14)","--color-danger-border": "rgba(248, 113, 113, 0.18)","--color-danger-foreground": "#fca5a5",diff --git a/apps/mobile/generated-uniwind-themes.css b/apps/mobile/generated-uniwind-themes.cssindex 8ba542165f1..e9352e1b38b 100644--- a/apps/mobile/generated-uniwind-themes.css+++ b/apps/mobile/generated-uniwind-themes.css@@ -150,6 +150,9 @@--color-switch-active-thumb: #ffffff;--color-switch-inactive-track: #f1c4e6;--color-switch-inactive-thumb: #8d1255;+ --color-warning: #fcf0ea;+ --color-warning-border: rgba(245, 158, 11, 0.32);+ --color-warning-foreground: #b05109;--color-danger: #fde4f1;--color-danger-border: rgba(247, 8, 108, 0.32);--color-danger-foreground: #9d174d;@@ -275,6 +278,9 @@--color-switch-active-thumb: #fbd0e8;--color-switch-inactive-track: #362d3d;--color-switch-inactive-thumb: #e7d0dd;+ --color-warning: #412f20;+ --color-warning-border: rgba(245, 158, 11, 0.32);+ --color-warning-foreground: #fbbf24;--color-danger: #331a2b;--color-danger-border: rgba(157, 23, 77, 0.32);--color-danger-foreground: #fbd0e8;@@ -400,6 +406,9 @@--color-switch-active-thumb: #fffaff;--color-switch-inactive-track: #e2ede7;--color-switch-inactive-thumb: #6e696f;+ --color-warning: #f4f0e1;+ --color-warning-border: rgba(254, 154, 0, 0.32);+ --color-warning-foreground: #b64a00;--color-danger: #f4e7e5;--color-danger-border: rgba(251, 44, 54, 0.32);--color-danger-foreground: #c10007;@@ -525,6 +534,9 @@--color-switch-active-thumb: #241523;--color-switch-inactive-track: #2a4b39;--color-switch-inactive-thumb: #9da5a2;+ --color-warning: #3f3a1c;+ --color-warning-border: rgba(254, 154, 0, 0.32);+ --color-warning-foreground: #ffb900;--color-danger: #3f2c28;--color-danger-border: rgba(251, 65, 74, 0.32);--color-danger-foreground: #ff6668;@@ -650,6 +662,9 @@--color-switch-active-thumb: #fffaff;--color-switch-inactive-track: #e4ecf2;--color-switch-inactive-thumb: #6f6873;+ --color-warning: #f6efe4;+ --color-warning-border: rgba(254, 154, 0, 0.32);+ --color-warning-foreground: #b74b00;--color-danger: #f5e6e9;--color-danger-border: rgba(251, 44, 54, 0.32);--color-danger-foreground: #c10007;@@ -775,6 +790,9 @@--color-switch-active-thumb: #241523;--color-switch-inactive-track: #293f52;--color-switch-inactive-thumb: #969ca6;+ --color-warning: #3c3424;+ --color-warning-border: rgba(254, 154, 0, 0.32);+ --color-warning-foreground: #ffb900;--color-danger: #3c2630;--color-danger-border: rgba(251, 65, 74, 0.32);--color-danger-foreground: #ff6467;@@ -900,6 +918,9 @@--color-switch-active-thumb: #fffaff;--color-switch-inactive-track: #f3eae5;--color-switch-inactive-thumb: #74686f;+ --color-warning: #f9efe2;+ --color-warning-border: rgba(254, 154, 0, 0.32);+ --color-warning-foreground: #b84b00;--color-danger: #f9e7e6;--color-danger-border: rgba(251, 44, 54, 0.32);--color-danger-foreground: #c10007;@@ -1025,6 +1046,9 @@--color-switch-active-thumb: #241523;--color-switch-inactive-track: #513728;--color-switch-inactive-thumb: #a59996;+ --color-warning: #4b3215;+ --color-warning-border: rgba(254, 154, 0, 0.32);+ --color-warning-foreground: #ffb900;--color-danger: #4a2321;--color-danger-border: rgba(251, 65, 74, 0.32);--color-danger-foreground: #ff6467;@@ -1150,6 +1174,9 @@--color-switch-active-thumb: #fffaff;--color-switch-inactive-track: #edeaf4;--color-switch-inactive-thumb: #726874;+ --color-warning: #f8efe5;+ --color-warning-border: rgba(254, 154, 0, 0.32);+ --color-warning-foreground: #b84b00;--color-danger: #f8e6ea;--color-danger-border: rgba(251, 44, 54, 0.32);--color-danger-foreground: #c10007;@@ -1275,6 +1302,9 @@--color-switch-active-thumb: #241523;--color-switch-inactive-track: #362d51;--color-switch-inactive-thumb: #9690a1;+ --color-warning: #412e23;+ --color-warning-border: rgba(254, 154, 0, 0.32);+ --color-warning-foreground: #ffb900;--color-danger: #40202e;--color-danger-border: rgba(251, 65, 74, 0.32);--color-danger-foreground: #ff6467;diff --git a/apps/mobile/global.css b/apps/mobile/global.cssindex e6961eac4ee..e153107b181 100644--- a/apps/mobile/global.css+++ b/apps/mobile/global.css@@ -52,6 +52,11 @@--color-switch-inactive-track: rgba(0, 0, 0, 0.08);--color-switch-inactive-thumb: #8e8e93;+ /* Warning */+ --color-warning: #fffbeb;+ --color-warning-border: #fde68a;+ --color-warning-foreground: #b45309;+/* Danger */--color-danger: #fef2f2;--color-danger-border: rgba(239, 68, 68, 0.12);@@ -151,6 +156,11 @@--color-switch-inactive-track: rgba(255, 255, 255, 0.06);--color-switch-inactive-thumb: #8e8e93;+ /* Warning */+ --color-warning: rgba(69, 26, 3, 0.4);+ --color-warning-border: rgba(120, 53, 15, 0.6);+ --color-warning-foreground: #fcd34d;+/* Danger */--color-danger: rgba(239, 68, 68, 0.14);--color-danger-border: rgba(248, 113, 113, 0.18);diff --git a/apps/mobile/src/components/AppText.tsx b/apps/mobile/src/components/AppText.tsxindex 39517f0e62e..6501d204408 100644--- a/apps/mobile/src/components/AppText.tsx+++ b/apps/mobile/src/components/AppText.tsx@@ -35,6 +35,8 @@ export function AppTextInput({ className, ref, ...props }: AppTextInputProps) {className,)}placeholderTextColorClassName="accent-placeholder"+ selectionColorClassName="accent-foreground-secondary"+ cursorColorClassName="accent-foreground-secondary"{...props}/>);diff --git a/apps/mobile/src/components/ComposerAttachmentStrip.tsx b/apps/mobile/src/components/ComposerAttachmentStrip.tsxindex 40465012e5d..8c86fcc38e6 100644--- a/apps/mobile/src/components/ComposerAttachmentStrip.tsx+++ b/apps/mobile/src/components/ComposerAttachmentStrip.tsx@@ -195,7 +195,7 @@ function ComposerAttachmentContent(props: ComposerAttachmentThumbnailProps) {<SymbolViewname="doc.text"size={props.compact ? 15 : 22}- tintColor="#a3a3a3"+ tintColorClassName="accent-icon-subtle"type="monochrome"/>{!props.compact ? (diff --git a/apps/mobile/src/components/ErrorBanner.tsx b/apps/mobile/src/components/ErrorBanner.tsxindex 6c12c9bdd82..38f85de195b 100644--- a/apps/mobile/src/components/ErrorBanner.tsx+++ b/apps/mobile/src/components/ErrorBanner.tsx@@ -3,8 +3,8 @@ import { View } from "react-native";import { AppText as Text } from "./AppText";export function ErrorBanner(props: { readonly message: string }) {return (- <View className="rounded-2xl border border-adaptive-rose-300-a70-400-a28 bg-adaptive-rose-100-a80-500-a12 px-3.5 py-3">- <Text className="font-t3-medium text-sm text-adaptive-rose-700-300">{props.message}</Text>+ <View className="rounded-2xl border border-danger-border bg-danger px-3.5 py-3">+ <Text className="font-t3-medium text-sm text-danger-foreground">{props.message}</Text></View>);}diff --git a/apps/mobile/src/features/connection/CloudEnvironmentRows.tsx b/apps/mobile/src/features/connection/CloudEnvironmentRows.tsxindex 44888954901..806499c2273 100644--- a/apps/mobile/src/features/connection/CloudEnvironmentRows.tsx+++ b/apps/mobile/src/features/connection/CloudEnvironmentRows.tsx@@ -299,7 +299,7 @@ function CloudEnvironmentRowShell(props: {traceId: props.connectionErrorTraceId,});const statusClassName = props.connectionError- ? "text-adaptive-rose-500-400"+ ? "text-danger-foreground": "text-foreground-muted";const [errorMeasurement, setErrorMeasurement] = useState<{readonly text: string;diff --git a/apps/mobile/src/features/connection/ConnectionEnvironmentRow.tsx b/apps/mobile/src/features/connection/ConnectionEnvironmentRow.tsxindex 75d3e8ce7a3..5555548ff79 100644--- a/apps/mobile/src/features/connection/ConnectionEnvironmentRow.tsx+++ b/apps/mobile/src/features/connection/ConnectionEnvironmentRow.tsx@@ -96,7 +96,7 @@ export function ConnectionEnvironmentRow(props: {<TextclassName={cn("text-xs",- hasConnectionFailure ? "text-adaptive-rose-500-400" : "text-foreground-muted",+ hasConnectionFailure ? "text-danger-foreground" : "text-foreground-muted",)}numberOfLines={props.expanded ? undefined : 1}selectable={props.expanded}diff --git a/apps/mobile/src/features/connection/connectionTone.ts b/apps/mobile/src/features/connection/connectionTone.tsindex 51ee592c2ca..40b9b96bb21 100644--- a/apps/mobile/src/features/connection/connectionTone.ts+++ b/apps/mobile/src/features/connection/connectionTone.ts@@ -12,32 +12,32 @@ export function connectionTone(state: RemoteClientConnectionState): StatusTone {case "reconnecting":return {label: "Reconnecting",- pillClassName: "bg-adaptive-amber-500-a12-a16",- textClassName: "text-adaptive-amber-700-300",+ pillClassName: "bg-warning",+ textClassName: "text-warning-foreground",};case "connecting":return {label: "Connecting",- pillClassName: "bg-adaptive-sky-500-a12-a16",- textClassName: "text-adaptive-sky-700-300",+ pillClassName: "bg-primary/10",+ textClassName: "text-foreground-secondary",};case "error":return {label: "Connection failed",- pillClassName: "bg-adaptive-rose-500-a12-a16",- textClassName: "text-adaptive-rose-700-300",+ pillClassName: "bg-danger",+ textClassName: "text-danger-foreground",};case "offline":return {label: "Offline",- pillClassName: "bg-adaptive-rose-500-a12-a16",- textClassName: "text-adaptive-rose-700-300",+ pillClassName: "bg-danger",+ textClassName: "text-danger-foreground",};case "available":return {label: "Available",- pillClassName: "bg-adaptive-neutral-500-a10-a16",- textClassName: "text-adaptive-neutral-600-300",+ pillClassName: "bg-subtle",+ textClassName: "text-foreground-secondary",};}}diff --git a/apps/mobile/src/features/files/ThreadFilesRouteScreen.tsx b/apps/mobile/src/features/files/ThreadFilesRouteScreen.tsxindex ca8fd9c6141..29bbdb49c89 100644--- a/apps/mobile/src/features/files/ThreadFilesRouteScreen.tsx+++ b/apps/mobile/src/features/files/ThreadFilesRouteScreen.tsx@@ -190,11 +190,11 @@ function FileContent(props: {return (<View className="flex-1 bg-sheet">{props.truncated ? (- <View className="border-b border-adaptive-amber-200-900-a60 bg-adaptive-amber-50-950-a40 px-4 py-2">- <Text className="text-2xs font-t3-bold uppercase text-adaptive-amber-700-300">+ <View className="border-b border-warning-border bg-warning px-4 py-2">+ <Text className="text-2xs font-t3-bold uppercase text-warning-foreground">Partial file</Text>- <Text className="text-xs leading-snug text-adaptive-amber-800-200">+ <Text className="text-xs leading-snug text-warning-foreground">Preview limited to the first 1 MB of a truncated file.</Text></View>diff --git a/apps/mobile/src/features/home/thread-swipe-actions.tsx b/apps/mobile/src/features/home/thread-swipe-actions.tsxindex 052ac969c10..c5f6768c55d 100644--- a/apps/mobile/src/features/home/thread-swipe-actions.tsx+++ b/apps/mobile/src/features/home/thread-swipe-actions.tsx@@ -62,7 +62,7 @@ interface ThreadSwipeAction {}interface ThreadSwipeSecondaryAction extends ThreadSwipeAction {- readonly backgroundColor: string;+ readonly tone: "primary" | "secondary" | "danger";}function swipeActionsWidth(hasSecondaryAction: boolean) {@@ -80,7 +80,7 @@ function resolveSecondaryAction(input: {if (input.secondaryAction === undefined) {return {accessibilityLabel: `Delete ${input.threadTitle}`,- backgroundColor: "#ff2d55",+ tone: "danger",icon: "trash",label: "Delete",onPress: () => {@@ -92,7 +92,7 @@ function resolveSecondaryAction(input: {const action = input.secondaryAction;return {...action,- backgroundColor: "#5856d6",+ tone: "secondary",menu:action.menu === undefined? undefined@@ -359,7 +359,7 @@ export function ThreadSwipeable(props: {function SwipeActionButton(props: {readonly accessibilityLabel: string;readonly actionsWidth: number;- readonly backgroundColor: string;+ readonly tone: "primary" | "secondary" | "danger";readonly compact: boolean;readonly entryRange: readonly [number, number];readonly fullSwipeThreshold: number;@@ -462,9 +462,15 @@ function SwipeActionButton(props: {><View style={{ height: circleSize, width: circleSize }}><Animated.View+ className={+ props.tone === "danger"+ ? "bg-danger"+ : props.tone === "secondary"+ ? "bg-secondary"+ : "bg-primary"+ }style={[{- backgroundColor: props.backgroundColor,borderRadius: 999,height: circleSize,left: 0,@@ -488,7 +494,18 @@ function SwipeActionButton(props: {iconStyle,]}>- <SymbolView name={props.icon} size={iconSize} tintColor="#ffffff" type="monochrome" />+ <SymbolView+ name={props.icon}+ size={iconSize}+ tintColorClassName={+ props.tone === "danger"+ ? "accent-danger-foreground"+ : props.tone === "secondary"+ ? "accent-secondary-foreground"+ : "accent-primary-foreground"+ }+ type="monochrome"+ /></Animated.View></View><Animated.View@@ -568,7 +585,7 @@ export function ThreadSwipeActions(props: {<SwipeActionButtonaccessibilityLabel={props.primaryAction.accessibilityLabel}actionsWidth={actionsWidth}- backgroundColor="#007aff"+ tone="primary"compact={props.compact}entryRange={secondaryAction === null@@ -586,7 +603,7 @@ export function ThreadSwipeActions(props: {<SwipeActionButtonaccessibilityLabel={secondaryAction.accessibilityLabel}actionsWidth={actionsWidth}- backgroundColor={secondaryAction.backgroundColor}+ tone={secondaryAction.tone}compact={props.compact}entryRange={[8, ACTION_ITEM_WIDTH * 0.72]}fullSwipeThreshold={props.fullSwipeThreshold}diff --git a/apps/mobile/src/features/review/ReviewSheet.tsx b/apps/mobile/src/features/review/ReviewSheet.tsxindex 80ebe1157d9..9e768112fb4 100644--- a/apps/mobile/src/features/review/ReviewSheet.tsx+++ b/apps/mobile/src/features/review/ReviewSheet.tsx@@ -80,11 +80,9 @@ const SHOWCASE_ENABLED = process.env.EXPO_PUBLIC_SHOWCASE === "1";const ReviewNotice = memo(function ReviewNotice(props: { readonly notice: string }) {return (- <View className="border-b border-adaptive-amber-200-900-a60 bg-adaptive-amber-50-950-a40 px-4 py-3">- <Text className="text-xs font-t3-bold uppercase text-adaptive-amber-700-300">- Partial diff- </Text>- <Text className="text-xs leading-normal text-adaptive-amber-800-200">{props.notice}</Text>+ <View className="border-b border-warning-border bg-warning px-4 py-3">+ <Text className="text-xs font-t3-bold uppercase text-warning-foreground">Partial diff</Text>+ <Text className="text-xs leading-normal text-warning-foreground">{props.notice}</Text></View>);});diff --git a/apps/mobile/src/features/settings/appearance/components/FontSizeSliderRow.tsx b/apps/mobile/src/features/settings/appearance/components/FontSizeSliderRow.tsxindex 9b5d8e113f8..bc8ddfc84ba 100644--- a/apps/mobile/src/features/settings/appearance/components/FontSizeSliderRow.tsx+++ b/apps/mobile/src/features/settings/appearance/components/FontSizeSliderRow.tsx@@ -176,10 +176,9 @@ export function FontSizeSliderRow(props: {/></View><Animated.View- className="absolute left-0 rounded-full bg-white"+ className="absolute left-0 rounded-full border-border bg-primary-foreground"style={[{- borderColor: "rgba(0, 0, 0, 0.06)",borderWidth: 1,height: THUMB_SIZE,marginTop: -THUMB_SIZE / 2,diff --git a/apps/mobile/src/features/threads/GitActionProgressOverlay.tsx b/apps/mobile/src/features/threads/GitActionProgressOverlay.tsxindex fb12a35d6c2..802759b5a2c 100644--- a/apps/mobile/src/features/threads/GitActionProgressOverlay.tsx+++ b/apps/mobile/src/features/threads/GitActionProgressOverlay.tsx@@ -143,9 +143,7 @@ function OverlayContent(props: { readonly progress: GitActionProgress }) {}const bgClass =- progress.phase === "error"- ? "border-adaptive-red-200-800 bg-adaptive-red-50-950-a80"- : "bg-card border-border";+ progress.phase === "error" ? "border-danger-border bg-danger" : "bg-card border-border";return (<Animated.View@@ -169,11 +167,11 @@ function OverlayIcon(props: { readonly phase: GitActionProgress["phase"] }) {);case "error":return (- <View className="h-6 w-6 items-center justify-center rounded-full bg-red-500">+ <View className="h-6 w-6 items-center justify-center rounded-full bg-danger"><SymbolViewname="exclamationmark.triangle"size={12}- tintColor="white"+ tintColorClassName="accent-danger-foreground"type="monochrome"/></View>diff --git a/apps/mobile/src/features/threads/PendingApprovalCard.tsx b/apps/mobile/src/features/threads/PendingApprovalCard.tsxindex a94f321a4ad..4be6ff61184 100644--- a/apps/mobile/src/features/threads/PendingApprovalCard.tsx+++ b/apps/mobile/src/features/threads/PendingApprovalCard.tsx@@ -30,22 +30,20 @@ export function PendingApprovalCard(props: PendingApprovalCardProps) {// Opaque for the same reason as PendingUserInputCard: nothing blurs the feed// behind this card, so a translucent surface bleeds messages through it.return (- <View className="gap-2.5 rounded-[20px] border border-adaptive-neutral-200-white-a6 bg-adaptive-neutral-100-900 p-4">- <Text className="font-t3-bold text-2xs uppercase tracking-[1.1px] text-adaptive-sky-700-300">+ <View className="gap-2.5 rounded-[20px] border border-border bg-card-alt p-4">+ <Text className="font-t3-bold text-2xs uppercase tracking-[1.1px] text-foreground-secondary">Approval needed</Text>- <Text className="font-t3-bold text-lg text-adaptive-neutral-950-50">+ <Text className="font-t3-bold text-lg text-foreground">{props.approval.appName ?? props.approval.requestKind}</Text>{props.approval.detail ? (- <Text className="font-sans text-sm leading-normal text-adaptive-neutral-600-400">+ <Text className="font-sans text-sm leading-normal text-foreground-secondary">{props.approval.detail}</Text>) : null}{warning ? (- <Text className="font-sans text-xs leading-normal text-adaptive-amber-700-300">- {warning}- </Text>+ <Text className="font-sans text-xs leading-normal text-warning-foreground">{warning}</Text>) : null}<View className="flex-row flex-wrap gap-2.5">{options.map((option) => (@@ -53,10 +51,10 @@ export function PendingApprovalCard(props: PendingApprovalCardProps) {key={option.decision}className={`items-center justify-center rounded-[14px] px-3.5 py-3 ${option.decision === "accept"- ? "bg-blue-500"+ ? "bg-primary": option.decision === "decline"- ? "bg-adaptive-rose-100-500-a18"- : "bg-adaptive-neutral-200-800"+ ? "bg-danger"+ : "bg-subtle-strong"}`}disabled={props.respondingApprovalId === props.approval.requestId}onPress={() => void props.onRespond(props.approval.requestId, option.decision)}@@ -64,10 +62,10 @@ export function PendingApprovalCard(props: PendingApprovalCardProps) {<TextclassName={`text-sm ${option.decision === "accept"- ? "font-t3-extrabold text-white"+ ? "font-t3-extrabold text-primary-foreground": option.decision === "decline"- ? "font-t3-bold text-adaptive-rose-700-300"- : "font-t3-bold text-adaptive-neutral-950-50"+ ? "font-t3-bold text-danger-foreground"+ : "font-t3-bold text-foreground"}`}>{option.label}diff --git a/apps/mobile/src/features/threads/PendingUserInputCard.tsx b/apps/mobile/src/features/threads/PendingUserInputCard.tsxindex f821c571495..8fe7fc186ad 100644--- a/apps/mobile/src/features/threads/PendingUserInputCard.tsx+++ b/apps/mobile/src/features/threads/PendingUserInputCard.tsx@@ -161,7 +161,7 @@ export function PendingUserInputCard(props: PendingUserInputCardProps) {pointerEvents={props.collapsed ? "auto" : "none"}accessibilityElementsHidden={!props.collapsed}importantForAccessibility={props.collapsed ? "auto" : "no-hide-descendants"}- className="flex-row items-center gap-2 rounded-full border border-adaptive-neutral-200-white-a6 bg-adaptive-neutral-100-900 py-1.5 pl-4 pr-1.5"+ className="flex-row items-center gap-2 rounded-full border border-border bg-card-alt py-1.5 pl-4 pr-1.5"><PressableaccessibilityRole="button"@@ -171,10 +171,10 @@ export function PendingUserInputCard(props: PendingUserInputCardProps) {onPress={props.onToggleCollapsed}className="min-h-10 flex-1 flex-row items-center gap-2 active:opacity-70">- <Text className="font-t3-bold text-2xs uppercase tracking-[1.1px] text-adaptive-sky-700-300">+ <Text className="font-t3-bold text-2xs uppercase tracking-[1.1px] text-foreground-secondary">User input needed</Text>- <Text className="font-sans text-xs text-adaptive-neutral-500-400">+ <Text className="font-sans text-xs text-foreground-muted">{questionCount} question{questionCount === 1 ? "" : "s"}</Text><View className="flex-1" />@@ -216,7 +216,7 @@ export function PendingUserInputCard(props: PendingUserInputCardProps) {: FadeOutDown.duration(USER_INPUT_TOGGLE_DURATION_MS).easing(Easing.out(Easing.cubic))}layout={CARD_LAYOUT_TRANSITION}- className="overflow-hidden gap-2.5 rounded-[20px] border border-adaptive-neutral-200-white-a6 bg-adaptive-neutral-100-900 p-4"+ className="overflow-hidden gap-2.5 rounded-[20px] border border-border bg-card-alt p-4"style={EXPANDED_CARD_IS_OVERLAY? [{ maxHeight: props.maxHeight }, cardAnimatedStyle]@@ -230,14 +230,12 @@ export function PendingUserInputCard(props: PendingUserInputCardProps) {className="flex-row items-start gap-2"><View className="flex-1 gap-2.5">- <Text className="font-t3-bold text-2xs uppercase tracking-[1.1px] text-adaptive-sky-700-300">+ <Text className="font-t3-bold text-2xs uppercase tracking-[1.1px] text-foreground-secondary">User input needed</Text>- <Text className="font-t3-bold text-lg text-adaptive-neutral-950-50">- Fill in the pending answers- </Text>+ <Text className="font-t3-bold text-lg text-foreground">Fill in the pending answers</Text></View>- <View className="h-8 w-8 items-center justify-center rounded-full bg-adaptive-neutral-200-a70-white-a8">+ <View className="h-8 w-8 items-center justify-center rounded-full bg-subtle-strong"><SymbolViewname="chevron.down"size={13}@@ -259,10 +257,10 @@ export function PendingUserInputCard(props: PendingUserInputCardProps) {const draft = props.drafts[question.id];return (<View key={question.id} className="gap-2 pt-1">- <Text className="font-t3-bold text-xs uppercase tracking-[1px] text-neutral-500">+ <Text className="font-t3-bold text-xs uppercase tracking-[1px] text-foreground-muted">{question.header}</Text>- <Text className="font-sans text-base leading-snug text-adaptive-neutral-950-50">+ <Text className="font-sans text-base leading-snug text-foreground">{question.question}</Text><View className="gap-2">@@ -276,9 +274,7 @@ export function PendingUserInputCard(props: PendingUserInputCardProps) {key={optionValue}className={cn("min-h-12 w-full rounded-2xl border px-3.5 py-3",- selected- ? "border-adaptive-blue-300-a50-blue-400-a28 bg-adaptive-blue-50-blue-400-a14"- : "border-adaptive-neutral-200-white-a6 bg-adaptive-white-neutral-950-a70",+ selected ? "border-primary bg-primary/10" : "border-border bg-input",)}onPress={() =>props.onSelectOption(@@ -292,15 +288,13 @@ export function PendingUserInputCard(props: PendingUserInputCardProps) {<TextclassName={cn("font-t3-bold text-sm",- selected- ? "text-adaptive-sky-700-300"- : "text-adaptive-neutral-600-300",+ selected ? "text-foreground" : "text-foreground-secondary",)}>{option.label}</Text>{description ? (- <Text className="font-sans text-sm leading-5 text-adaptive-neutral-500-400">+ <Text className="font-sans text-sm leading-5 text-foreground-muted">{description}</Text>) : null}@@ -318,7 +312,7 @@ export function PendingUserInputCard(props: PendingUserInputCardProps) {onFocus={() => props.onInputFocusChange?.(true)}onBlur={() => props.onInputFocusChange?.(false)}placeholder="Or type a custom answer"- className="min-h-[54px] rounded-2xl border border-adaptive-neutral-200-white-a8 bg-adaptive-white-neutral-950-a70 px-3.5 py-3 font-sans text-base text-adaptive-neutral-950-50"+ className="min-h-[54px] rounded-2xl border border-input-border bg-input px-3.5 py-3 font-sans text-base text-foreground"/>) : null}</View>@@ -328,14 +322,21 @@ export function PendingUserInputCard(props: PendingUserInputCardProps) {<PressableclassName={cn("items-center justify-center rounded-2xl px-4 py-3.5",- props.answers ? "bg-blue-500" : "bg-adaptive-neutral-200-700-a60",+ props.answers ? "bg-primary" : "bg-subtle-strong",)}disabled={props.answers === null || props.respondingUserInputId === props.pendingUserInput.requestId}onPress={() => void props.onSubmit()}>- <Text className="font-t3-extrabold text-sm text-white">Submit answers</Text>+ <Text+ className={cn(+ "font-t3-extrabold text-sm",+ props.answers ? "text-primary-foreground" : "text-foreground-muted",+ )}+ >+ Submit answers+ </Text></Pressable></Animated.View>) : null;diff --git a/apps/mobile/src/features/threads/ThreadFeed.tsx b/apps/mobile/src/features/threads/ThreadFeed.tsxindex d53ae65be06..b57758b50c1 100644--- a/apps/mobile/src/features/threads/ThreadFeed.tsx+++ b/apps/mobile/src/features/threads/ThreadFeed.tsx@@ -504,7 +504,12 @@ function MessageAttachmentFile(props: {function MessageAttachmentUnknown(props: { readonly name: string }) {return (<View className="flex-row items-center gap-2 py-1">- <SymbolView name="doc.text" size={16} tintColor="#a3a3a3" type="monochrome" />+ <SymbolView+ name="doc.text"+ size={16}+ tintColorClassName="accent-icon-subtle"+ type="monochrome"+ /><Text className="min-w-0 flex-1 text-sm text-foreground" numberOfLines={1}>{props.name}</Text>@@ -1352,7 +1357,7 @@ function renderFeedEntry(accessibilityState={{ expanded: entry.expanded }}onPress={() => props.onToggleTurnFold(entry.turnId)}hitSlop={4}- className="mb-1 min-h-11 flex-row items-center gap-2 border-b border-adaptive-neutral-200-a80-white-a8 px-2"+ className="mb-1 min-h-11 flex-row items-center gap-2 border-b border-border px-2"style={{minHeight: Math.max(TURN_FOLD_HEIGHT - 3.5, props.workRowSizing.estimatedRowHeight),}}@@ -1406,7 +1411,7 @@ function renderFeedEntry(accessibilityLabel={label}className="mb-3 flex-row items-center gap-3 px-1 py-1">- <View className="h-px flex-1 bg-adaptive-neutral-200-a80-white-a8" />+ <View className="h-px flex-1 bg-border" /><View className="shrink-0 flex-row items-center gap-1.5"><SymbolViewname="arrow.down.right.and.arrow.up.left"@@ -1416,7 +1421,7 @@ function renderFeedEntry(/><Text className="font-t3-medium text-xs text-foreground-muted">{label}</Text></View>- <View className="h-px flex-1 bg-adaptive-neutral-200-a80-white-a8" />+ <View className="h-px flex-1 bg-border" /></View>);}@@ -1503,7 +1508,7 @@ function renderFeedEntry(})}</View><View className="mt-1 flex-row items-center justify-end gap-1 pr-0.5">- <Text className="font-t3-medium text-xs tabular-nums text-adaptive-neutral-600-400">+ <Text className="font-t3-medium text-xs tabular-nums text-foreground-secondary">{timestampLabel}</Text>{message.text.trim().length > 0 ? (@@ -1552,7 +1557,7 @@ function renderFeedEntry(attachmentId={attachment.id}name={attachment.name}mimeType={attachment.mimeType}- className="mt-1.5 aspect-[1.3] w-full rounded-[18px] bg-adaptive-neutral-200-800"+ className="mt-1.5 aspect-[1.3] w-full rounded-[18px] bg-subtle-strong"onPressPreview={props.onPressPreview}/>) : isFileAttachment(attachment) ? (@@ -1576,7 +1581,7 @@ function renderFeedEntry(buttonSize={28}iconSize={13}/>- <Text className="font-t3-medium text-xs tabular-nums text-adaptive-neutral-600-400">+ <Text className="font-t3-medium text-xs tabular-nums text-foreground-secondary">{timestampLabel}</Text></View>diff --git a/apps/mobile/src/features/threads/git/GitCommitSheet.tsx b/apps/mobile/src/features/threads/git/GitCommitSheet.tsxindex f263372bad2..e76672de20f 100644--- a/apps/mobile/src/features/threads/git/GitCommitSheet.tsx+++ b/apps/mobile/src/features/threads/git/GitCommitSheet.tsx@@ -85,7 +85,7 @@ export function GitCommitSheet(_props: GitCommitSheetProps) {</Text></View>{isDefaultRef ? (- <Text className="text-xs leading-normal text-adaptive-amber-700-400">+ <Text className="text-xs leading-normal text-warning-foreground">Warning: this is the default branch.</Text>) : null}diff --git a/apps/mobile/src/features/threads/thread-list-items.tsx b/apps/mobile/src/features/threads/thread-list-items.tsxindex fcba4626be2..fc3898279e3 100644--- a/apps/mobile/src/features/threads/thread-list-items.tsx+++ b/apps/mobile/src/features/threads/thread-list-items.tsx@@ -297,8 +297,8 @@ export const PendingTaskListRow = memo(function PendingTaskListRow(props: {);const statusPill = (- <View className="rounded-full bg-adaptive-zinc-500-a12-a16 px-1.5 py-0.5">- <Text className="text-3xs font-t3-bold text-adaptive-zinc-600-300">Pending</Text>+ <View className="rounded-full bg-subtle px-1.5 py-0.5">+ <Text className="text-3xs font-t3-bold text-foreground-muted">Pending</Text></View>);diff --git a/apps/mobile/src/features/threads/thread-list-v2-items.tsx b/apps/mobile/src/features/threads/thread-list-v2-items.tsxindex 97c13de56aa..e34dce05901 100644--- a/apps/mobile/src/features/threads/thread-list-v2-items.tsx+++ b/apps/mobile/src/features/threads/thread-list-v2-items.tsx@@ -23,7 +23,6 @@ import { useUniwindTheme } from "../../lib/useUniwindTheme";import type { PendingNewTask } from "../../state/use-pending-new-tasks";import { useThreadPr } from "../../state/use-thread-pr";import { ThreadSwipeable } from "../home/thread-swipe-actions";-import { useAppearancePreferences } from "../settings/appearance/AppearancePreferencesProvider";import { buildThreadTitleRegenerationMenuItems } from "./thread-title-regeneration-menu";import {resolveThreadListV2SnoozeMenuSelection,@@ -53,10 +52,10 @@ const MONO_FONT = Platform.select({const STATUS_LABEL_BY_STATUS: Partial<Record<ThreadListV2Status, { label: string; className: string }>> = {- approval: { label: "Approval", className: "text-adaptive-amber-700-300" },- input: { label: "Input", className: "text-adaptive-indigo-600-300" },- working: { label: "Working", className: "text-adaptive-sky-600-400" },- failed: { label: "Failed", className: "text-adaptive-red-700-300" },+ approval: { label: "Approval", className: "text-warning-foreground" },+ input: { label: "Input", className: "text-foreground-secondary" },+ working: { label: "Working", className: "text-foreground-secondary" },+ failed: { label: "Failed", className: "text-danger-foreground" },};function threadTimeLabel(thread: EnvironmentThreadShell): string {@@ -107,9 +106,6 @@ export const ThreadListV2SectionDivider = memo(function ThreadListV2SectionDivid);});-const SNOOZE_ACCENT_LIGHT = "#2563eb";-const SNOOZE_ACCENT_DARK = "#60a5fa";-export const ThreadListV2SnoozedShelfHeader = memo(function ThreadListV2SnoozedShelfHeader(props: {readonly count: number;readonly disabled?: boolean;@@ -117,7 +113,6 @@ export const ThreadListV2SnoozedShelfHeader = memo(function ThreadListV2SnoozedSreadonly onToggle: () => void;readonly pane?: "screen" | "sidebar";}) {- const { themeAppearance: colorScheme } = useAppearancePreferences();return (<PressableaccessibilityHint={@@ -134,14 +129,14 @@ export const ThreadListV2SnoozedShelfHeader = memo(function ThreadListV2SnoozedSonPress={props.onToggle}style={({ pressed }) => ({ opacity: pressed ? 0.6 : 1 })}>- <Text className="text-xs font-t3-medium text-adaptive-blue-600-400">+ <Text className="text-xs font-t3-medium text-foreground-secondary">{props.expanded ? "Snoozed" : `Snoozed (${props.count})`}</Text>- <View className="h-px flex-1 bg-adaptive-blue-500-a20-blue-400-a15" />+ <View className="h-px flex-1 bg-primary/20" /><SymbolViewname="chevron.down"size={10}- tintColor={colorScheme === "dark" ? SNOOZE_ACCENT_DARK : SNOOZE_ACCENT_LIGHT}+ tintColorClassName="accent-icon-muted"type="monochrome"style={{ transform: [{ rotate: props.expanded ? "180deg" : "0deg" }] }}/>@@ -737,7 +732,7 @@ export const ThreadListV2Row = memo(function ThreadListV2Row(props: {<TextclassName={cn("flex-1 text-xs",- selected ? "text-user-bubble-foreground-muted" : "text-adaptive-red-600-a80-400-a80",+ selected ? "text-user-bubble-foreground-muted" : "text-danger-foreground",)}numberOfLines={1}>@@ -919,7 +914,7 @@ export const ThreadListV2Row = memo(function ThreadListV2Row(props: {selected? "text-user-bubble-foreground-muted": snoozedRow- ? "text-adaptive-blue-600-400"+ ? "text-foreground-secondary": "text-foreground-tertiary",)}style={{ fontFamily: MONO_FONT }}diff --git a/apps/mobile/src/features/threads/thread-search-match.tsx b/apps/mobile/src/features/threads/thread-search-match.tsxindex 48aaf80249d..9c478f3c450 100644--- a/apps/mobile/src/features/threads/thread-search-match.tsx+++ b/apps/mobile/src/features/threads/thread-search-match.tsx@@ -65,7 +65,7 @@ export function ThreadSearchMatchExcerpt(props: {props.selected? "text-user-bubble-foreground": isUser- ? "text-adaptive-blue-500-400"+ ? "text-foreground-secondary": "text-adaptive-emerald-600-400",)}>diff --git a/apps/mobile/src/features/threads/thread-work-log.tsx b/apps/mobile/src/features/threads/thread-work-log.tsxindex 13a78b8f145..9d5b40fce6d 100644--- a/apps/mobile/src/features/threads/thread-work-log.tsx+++ b/apps/mobile/src/features/threads/thread-work-log.tsx@@ -773,7 +773,7 @@ const ThreadWorkLogRow = memo(function ThreadWorkLogRow(color={props.iconSubtleColor}colorClassName={iconIsDestructive- ? "accent-adaptive-rose-600-400"+ ? "accent-danger-foreground": failed? "accent-danger-foreground/40": undefined@@ -784,7 +784,7 @@ const ThreadWorkLogRow = memo(function ThreadWorkLogRow(<TextclassName={cn("min-w-0 flex-1 text-sm text-foreground-muted",- iconIsDestructive && "font-t3-medium text-adaptive-rose-600-400",+ iconIsDestructive && "font-t3-medium text-danger-foreground",)}numberOfLines={1}>@@ -832,7 +832,7 @@ const ThreadWorkLogRow = memo(function ThreadWorkLogRow(entering={WORK_LOG_DETAIL_ENTER_TRANSITION}exiting={WORK_LOG_DETAIL_EXIT_TRANSITION}layout={WORK_LOG_LAYOUT_TRANSITION}- className="ml-7 border-l border-adaptive-neutral-300-a60-white-a12 pb-1 pl-3 pt-0.5"+ className="ml-7 border-l border-border pb-1 pl-3 pt-0.5">{viewedImagePath ? (<View className="pb-1.5">diff --git a/apps/mobile/src/features/threads/threadPresentation.ts b/apps/mobile/src/features/threads/threadPresentation.tsindex 59cf108a01d..bfc72d2ac9b 100644--- a/apps/mobile/src/features/threads/threadPresentation.ts+++ b/apps/mobile/src/features/threads/threadPresentation.ts@@ -42,8 +42,8 @@ export function resolveThreadStatus(return {kind: "pending-approval",label: "Needs Approval",- pillClassName: "bg-adaptive-amber-500-a12-a16",- textClassName: "text-adaptive-amber-700-300",+ pillClassName: "bg-warning",+ textClassName: "text-warning-foreground",iconColor: "#ff9f0a",iconBackground: "rgba(255,159,10,0.22)",pulse: false,@@ -54,8 +54,8 @@ export function resolveThreadStatus(return {kind: "awaiting-input",label: "Awaiting Input",- pillClassName: "bg-adaptive-indigo-500-a12-a16",- textClassName: "text-adaptive-indigo-700-300",+ pillClassName: "bg-primary/10",+ textClassName: "text-foreground-secondary",iconColor: "#5e5ce6",iconBackground: "rgba(94,92,230,0.22)",pulse: false,@@ -66,8 +66,8 @@ export function resolveThreadStatus(return {kind: "working",label: "Working",- pillClassName: "bg-adaptive-sky-500-a12-a16",- textClassName: "text-adaptive-sky-700-300",+ pillClassName: "bg-primary/10",+ textClassName: "text-foreground-secondary",iconColor: "#0a84ff",iconBackground: "rgba(10,132,255,0.22)",pulse: true,@@ -78,8 +78,8 @@ export function resolveThreadStatus(return {kind: "connecting",label: "Connecting",- pillClassName: "bg-adaptive-sky-500-a12-a16",- textClassName: "text-adaptive-sky-700-300",+ pillClassName: "bg-primary/10",+ textClassName: "text-foreground-secondary",iconColor: "#0a84ff",iconBackground: "rgba(10,132,255,0.22)",pulse: true,@@ -90,8 +90,8 @@ export function resolveThreadStatus(return {kind: "error",label: "Error",- pillClassName: "bg-adaptive-rose-500-a12-a16",- textClassName: "text-adaptive-rose-700-300",+ pillClassName: "bg-danger",+ textClassName: "text-danger-foreground",iconColor: "#ff453a",iconBackground: "rgba(255,69,58,0.22)",pulse: false,@@ -106,8 +106,8 @@ export function resolveThreadStatus(return {kind: "plan-ready",label: "Plan Ready",- pillClassName: "bg-adaptive-violet-500-a12-a16",- textClassName: "text-adaptive-violet-700-300",+ pillClassName: "bg-primary/10",+ textClassName: "text-foreground-secondary",iconColor: "#bf5af2",iconBackground: "rgba(191,90,242,0.22)",pulse: false,diff --git a/apps/mobile/src/lib/mobileTheme.test.ts b/apps/mobile/src/lib/mobileTheme.test.tsindex a3c6712abae..652de9296f1 100644--- a/apps/mobile/src/lib/mobileTheme.test.ts+++ b/apps/mobile/src/lib/mobileTheme.test.ts@@ -153,10 +153,16 @@ describe("mobile themes", () => {it("maps semantic palette roles onto every mobile color variable", () => {const variables = createMobileThemeVariables(BUILT_IN_THEMES[0].colors, "light");- expect(Object.keys(variables)).toHaveLength(65);+ expect(Object.keys(variables)).toHaveLength(68);expect(variables["--color-sheet-solid"]).toBe(themeColorToNativeColor(BUILT_IN_THEMES[0].colors.chrome),);+ expect(variables["--color-warning"]).toBe(+ themeColorToNativeColor(BUILT_IN_THEMES[0].colors.warningSurface),+ );+ expect(variables["--color-warning-foreground"]).toBe(+ themeColorToNativeColor(BUILT_IN_THEMES[0].colors.warningForeground),+ );expect(variables["--color-primary"]).not.toBe(variables["--color-screen"]);expect(variables["--color-primary-shadow"]).toBe("#000000");expect(variables["--color-backdrop"]).toBe("rgba(0, 0, 0, 0.22)");diff --git a/apps/mobile/src/lib/mobileTheme.ts b/apps/mobile/src/lib/mobileTheme.tsindex 23034511287..10ef1b58ede 100644--- a/apps/mobile/src/lib/mobileTheme.ts+++ b/apps/mobile/src/lib/mobileTheme.ts@@ -239,6 +239,9 @@ export function createMobileThemeVariables("--color-switch-active-thumb": c.accentForeground,"--color-switch-inactive-track": c.secondary,"--color-switch-inactive-thumb": c.mutedForeground,+ "--color-warning": c.warningSurface,+ "--color-warning-border": withAlpha(c.warning, 0.32),+ "--color-warning-foreground": c.warningForeground,"--color-danger": c.errorSurface,"--color-danger-border": withAlpha(c.error, 0.32),"--color-danger-foreground": c.errorForeground,diff --git a/apps/mobile/src/state/thread-pr-presentation.ts b/apps/mobile/src/state/thread-pr-presentation.tsindex 53d19abd95a..fd7a171810e 100644--- a/apps/mobile/src/state/thread-pr-presentation.ts+++ b/apps/mobile/src/state/thread-pr-presentation.ts@@ -20,7 +20,7 @@ export interface ThreadPrPresentation {const PR_STATE_TEXT_CLASS: Record<ThreadPr["state"], string> = {open: "text-adaptive-emerald-600-400",merged: "text-adaptive-violet-600-400",- closed: "text-adaptive-zinc-500-400",+ closed: "text-foreground-muted",};export function presentThreadPr(@@ -37,6 +37,6 @@ export function presentThreadPr(url: pr.url,label: String(pr.number),accessibilityLabel: `#${pr.number} ${presentation.longName} ${isDraft ? "draft" : pr.state}`,- textClassName: isDraft ? "text-adaptive-zinc-500-400" : PR_STATE_TEXT_CLASS[pr.state],+ textClassName: isDraft ? "text-foreground-muted" : PR_STATE_TEXT_CLASS[pr.state],};}diff --git a/apps/mobile/src/state/use-thread-pr.test.ts b/apps/mobile/src/state/use-thread-pr.test.tsindex ddda3b1acd9..f6fddfdc557 100644--- a/apps/mobile/src/state/use-thread-pr.test.ts+++ b/apps/mobile/src/state/use-thread-pr.test.ts@@ -39,7 +39,7 @@ describe("presentThreadPr", () => {presentThreadPr({ ...pullRequest, state: "open", isDraft: true }, undefined),).toMatchObject({accessibilityLabel: "#3774 pull request draft",- textClassName: "text-adaptive-zinc-500-400",+ textClassName: "text-foreground-muted",});});});