TypeScript
chore(lint): keep mobile theme escape-hatch allowlist honest (#13146)
Julius Marminge2eaff08241a5
diff --git a/apps/mobile/src/features/files/ThreadFilesRouteScreen.tsx b/apps/mobile/src/features/files/ThreadFilesRouteScreen.tsxindex 06ef8f6ba4d..06b6664431b 100644--- a/apps/mobile/src/features/files/ThreadFilesRouteScreen.tsx+++ b/apps/mobile/src/features/files/ThreadFilesRouteScreen.tsx@@ -417,7 +417,6 @@ export function ThreadFilesTreeScreen(props: ThreadFilesRouteScreenProps) {const { fileInspector, layout, showAuxiliaryPane } = useAdaptiveWorkspaceLayout();const [searchQuery, setSearchQuery] = useState("");const { themeAppearance: highlightTheme } = useAppearancePreferences();- const headerColor = useUniwindTheme()["--color-header"];const { cwd, environmentId, projectName, selectedThread, threadId } = useThreadFilesWorkspace(props.route.params,);@@ -554,13 +553,7 @@ export function ThreadFilesTreeScreen(props: ThreadFilesRouteScreenProps) {</>);- return Platform.OS === "android" ? (- <View className="flex-1" style={{ backgroundColor: headerColor }}>- {content}- </View>- ) : (- content- );+ return Platform.OS === "android" ? <View className="flex-1 bg-header">{content}</View> : content;}export function ThreadFileScreen(props: ThreadFileRouteScreenProps) {diff --git a/apps/mobile/src/features/settings/appearance/components/AppearancePreviews.tsx b/apps/mobile/src/features/settings/appearance/components/AppearancePreviews.tsxindex 55bd661a64e..386ac3e2c39 100644--- a/apps/mobile/src/features/settings/appearance/components/AppearancePreviews.tsx+++ b/apps/mobile/src/features/settings/appearance/components/AppearancePreviews.tsx@@ -5,7 +5,6 @@ import {resolveMarkdownFontSizes,resolveMobileCodeSurface,} from "../../../../lib/appearancePreferences";-import { useUniwindTheme } from "../../../../lib/useUniwindTheme";import { getMobileTerminalTheme } from "../../../terminal/terminalTheme";import { useAppearancePreferences } from "../AppearancePreferencesProvider";@@ -138,16 +137,12 @@ export function CodeAppearancePreview(props: {readonly wordBreak: boolean;}) {const surface = resolveMobileCodeSurface(props.fontSize);- const theme = useUniwindTheme();- const lineNumberColor = theme["--color-icon-subtle"];- const keywordColor = theme["--color-md-link"];const lineNumber = (line: CodePreviewLine, index: number) => (<Text- className="text-right"+ className="text-right text-icon-subtle"key={line.id}style={{- color: lineNumberColor,fontFamily: CODE_FONT_FAMILY,fontSize: surface.lineNumberFontSize,lineHeight: surface.rowHeight,@@ -172,8 +167,8 @@ export function CodeAppearancePreview(props: {{line.tokens.map((token) => (<Textkey={token.text}+ className={token.keyword ? "text-md-link" : undefined}style={{- color: token.keyword ? keywordColor : undefined,fontFamily: CODE_FONT_FAMILY,fontSize: surface.fontSize,lineHeight: surface.rowHeight,diff --git a/vite.config.ts b/vite.config.tsindex 6119c6f38bc..65b4a989fd2 100644--- a/vite.config.ts+++ b/vite.config.ts@@ -215,7 +215,6 @@ export default defineConfig({"apps/mobile/src/features/connection/ConnectionsNewRouteScreen.tsx","apps/mobile/src/features/files/FileMarkdownPreview.tsx","apps/mobile/src/features/files/SourceFileSurface.tsx",- "apps/mobile/src/features/terminal/ThreadTerminalRouteScreen.tsx","apps/mobile/src/features/files/AttachmentFileScreen.tsx","apps/mobile/src/features/files/ThreadFilesRouteScreen.tsx","apps/mobile/src/features/files/thread-file-navigator-pane.tsx",@@ -223,7 +222,6 @@ export default defineConfig({"apps/mobile/src/features/review/ReviewSheet.tsx","apps/mobile/src/features/review/useNativeReviewDiffBridge.ts","apps/mobile/src/features/settings/SettingsEnvironmentsRouteScreen.tsx",- "apps/mobile/src/features/settings/appearance/components/AppearancePreviews.tsx","apps/mobile/src/features/threads/GitActionProgressOverlay.tsx","apps/mobile/src/features/threads/NewTaskDraftScreen.tsx","apps/mobile/src/features/threads/ThreadComposer.tsx",