Skip to content

armgit / cindy

Public Imported from GitHub
0

Consider it done. The open-source AI agent that works out of the box · 想到,就能做到。开源、开箱即用的 AI Agent。

perf(mobile): 减少大量任务下的安卓启动和详情渲染停顿 (#5269)

DavidShenXDd341ce56092d
diff --git a/apps/mobile/app/devices/[deviceId].tsx b/apps/mobile/app/devices/[deviceId].tsx
index 105d174181..9dc9fa8711 100644
--- a/apps/mobile/app/devices/[deviceId].tsx
+++ b/apps/mobile/app/devices/[deviceId].tsx
@@ -1,5 +1,6 @@
import { useIsFocused, useLocalSearchParams, useRouter } from 'expo-router';
-import { useCallback, useEffect, useMemo, useRef, useState } from 'react';
+import { useCallback, useContext, useEffect, useMemo, useRef, useState } from 'react';
+import { useSharedValue } from 'react-native-reanimated';
import {
ActivityIndicator,
AppState,
@@ -73,7 +74,7 @@ import {
} from '@/session/conversationSearch';
import { useConversationSearch } from '@/session/useConversationSearch';
import { selectVisibleDeviceSessions, sessionMatchesProjectDir } from '@/session/mobileHome';
-import { HomeSessionRow } from '@/session/HomeSurface';
+import { HomeListViewportContext, HomeSessionRow } from '@/session/HomeSurface';
import { createDisclosureListCell, ListDisclosureScope, useListDisclosureTransition } from '@/session/listDisclosureTransition';
import { RenameSessionModal } from '@/session/RenameSessionModal';
import { SessionOptionsPresenter } from '@/session/SessionOptionsExpoSheet';
@@ -117,9 +118,14 @@ type RemoteListStatusFilter = Extract<RemoteSessionStatusFilter, 'active' | 'arc
export default function DeviceDetailScreen() {
const screenFocused = useIsFocused();
+ const scrollY = useSharedValue(0);
+ const { height: viewportHeight } = useWindowDimensions();
+ const viewport = useMemo(() => ({ scrollY, viewportHeight }), [scrollY, viewportHeight]);
return (
<RemoteSessionStoreSubscriptionGate enabled={screenFocused}>
- <DeviceDetailScreenContent />
+ <HomeListViewportContext.Provider value={viewport}>
+ <DeviceDetailScreenContent />
+ </HomeListViewportContext.Provider>
</RemoteSessionStoreSubscriptionGate>
);
}
@@ -128,6 +134,7 @@ export default function DeviceDetailScreen() {
const DeviceListCell = createDisclosureListCell();
function DeviceDetailScreenContent() {
+ const viewport = useContext(HomeListViewportContext);
const screenFocused = useIsFocused();
const screenFocusedRef = useRef(screenFocused);
screenFocusedRef.current = screenFocused;
@@ -823,6 +830,8 @@ function DeviceDetailScreenContent() {
<ListDisclosureScope controller={disclosure.controller}>
<SectionList
CellRendererComponent={DeviceListCell}
+ onScroll={(event) => { if (viewport) viewport.scrollY.value = event.nativeEvent.contentOffset.y; }}
+ scrollEventThrottle={16}
{...simpleScrollInsetProps}
sections={displaySections}
keyExtractor={(item) => item.automationGroup?.key ?? item.session.id}
@@ -1168,6 +1177,8 @@ function DeviceDetailScreenContent() {
<ListDisclosureScope controller={disclosure.controller}>
<SectionList
CellRendererComponent={DeviceListCell}
+ onScroll={(event) => { if (viewport) viewport.scrollY.value = event.nativeEvent.contentOffset.y; }}
+ scrollEventThrottle={16}
{...simpleScrollInsetProps}
sections={displaySections}
keyExtractor={(item) => item.automationGroup?.key ?? item.session.id}
diff --git a/apps/mobile/app/sessions/[sessionId].tsx b/apps/mobile/app/sessions/[sessionId].tsx
index 1dedb9715e..35173c569e 100644
--- a/apps/mobile/app/sessions/[sessionId].tsx
+++ b/apps/mobile/app/sessions/[sessionId].tsx
@@ -1,3 +1,4 @@
+import { MountOnFirstOpen } from '@/session/MountOnFirstOpen';
import { RunningTokenRatePopover } from '@/session/RunningTokenRatePopover';
import { companionConversationItems } from '@/session/companionConversationPresentation';
import { useRunningTokenRateHistory } from '@/session/useRunningTokenRateHistory';
@@ -9023,7 +9024,8 @@ export default function SessionScreen() {
</View>
</SessionChromeLayer>
{sharedTaskExit.dialog}
- {currentSession ? (
+ <MountOnFirstOpen open={settingsOpen}>{() => (
+ currentSession ? (
<SessionMenuSheet
tagDeviceId={deviceId}
onLeaveSharing={() => void sharedTaskExit.leave()}
@@ -9082,7 +9084,8 @@ export default function SessionScreen() {
session={currentSession}
visible={settingsOpen}
/>
- ) : null}
+ ) : null
+ )}</MountOnFirstOpen>
<SessionSearchSheet
activeIndex={activeSearchIndex}
hasOlderMessages={hasOlderMessages && !isScheduleDetail}
@@ -9104,7 +9107,8 @@ export default function SessionScreen() {
shareBusy={chipShareBusy}
target={chipMenuTarget}
/>
- <ContextSheet
+ <MountOnFirstOpen open={contextSheetOpen}>{() => (
+ <ContextSheet
media={contextSheetView === 'main' && contextSheetMediaLibraryEnabled ? (
<RecentPhotosStrip
busyAssetIds={uploadingMediaAssetIds}
@@ -9278,7 +9282,9 @@ export default function SessionScreen() {
/>
)}
</ContextSheet>
- {currentSession && !sessionManagedByHost && runtimeOptions && modelSheetSelection && modelSheetRuntimeOptions ? (
+ )}</MountOnFirstOpen>
+ <MountOnFirstOpen open={modelSheetOpen && canUseRemoteSessionControls}>{() => (
+ currentSession && !sessionManagedByHost && runtimeOptions && modelSheetSelection && modelSheetRuntimeOptions ? (
<ModelPickerSheet
unified={{
currentSelection: { agentKind: sessionAgentKind, activeModelId: currentSession.model, selectedProviderId: currentSession.providerId ?? null, selectedEffort: currentSession.effort ?? '', selectedFastMode: !!currentSession.fastMode },
@@ -9335,8 +9341,9 @@ export default function SessionScreen() {
testID="session.modelSheet"
visible={modelSheetOpen && canUseRemoteSessionControls}
/>
- ) : null}
- {currentSession && collab.eligible ? (
+ ) : null
+ )}</MountOnFirstOpen>
+ <MountOnFirstOpen open={collab.workerForm.modelPicker.open}>{() => currentSession && collab.eligible ? (
// 协同 Worker 的模型选择:与会话模型浮窗同一套统一模型目录,但只回写 Worker 表单,
// 不触碰当前任务的模型。iOS 原生 sheet 不能叠开:打开前先收起 + 面板,关闭后再展开。
<ModelPickerSheet
@@ -9386,7 +9393,7 @@ export default function SessionScreen() {
testID="session.collabModelSheet"
visible={collab.workerForm.modelPicker.open}
/>
- ) : null}
+ ) : null}</MountOnFirstOpen>
{/* 权限模式独立浮窗(composer 权限图标钮点开)。两端同一语义:点选先关浮窗,关闭完成后
再走 confirmFullAccessChange + maker:set-permission-mode。 */}
{currentSession && runtimeOptions ? (
diff --git a/apps/mobile/src/__tests__/HomeUnreadContext.test.tsx b/apps/mobile/src/__tests__/HomeUnreadContext.test.tsx
index 3bb517522c..c4c45abdcd 100644
--- a/apps/mobile/src/__tests__/HomeUnreadContext.test.tsx
+++ b/apps/mobile/src/__tests__/HomeUnreadContext.test.tsx
@@ -1,30 +1,39 @@
// @vitest-environment jsdom
-import { act, createElement } from 'react';
+import { act, createElement, memo, StrictMode } from 'react';
import { createRoot } from 'react-dom/client';
-import { afterEach, expect, it, vi } from 'vitest';
-const h = vi.hoisted(() => ({ sessions: [] as any[], private: [] as any[], groups: [] as any[], unread: new Set<string>() }));
-vi.mock('expo-router', () => ({ useIsFocused: () => true }));
+import { afterEach, beforeEach, expect, it, vi } from 'vitest';
+import { RemoteSessionStoreSubscriptionGate, remoteSessionStore, useRemoteSessionMessagePreview } from '@/session/remoteSessionStore';
+import { SESSION_ACTIVITY_CHANNEL } from '@cindy/device-link';
+import type { RemoteSession } from '@/session/types';
+const h = vi.hoisted(() => ({ focused: true, private: [] as any[], groups: [] as any[], unread: new Set<string>() }));
+vi.mock('expo-router', () => ({ useIsFocused: () => h.focused }));
vi.mock('@/auth/AuthContext', () => ({ useAuth: () => ({ user: { id: 'owner' } }) }));
vi.mock('@/session/useTeammateRoster', () => ({ useTeammateRoster: () => ({ items: h.private, groupTargets: [] }) }));
vi.mock('@/session/useBotGroupRoster', () => ({ useBotGroupRoster: () => ({ items: h.groups }) }));
vi.mock('@/device-link/remoteResourceCache', () => ({ subscribeRemoteResourceCache: () => () => {}, remoteResourceCacheRevision: () => 0,
isRemoteResourceUnread: (_owner: string, _host: string, id: string) => h.unread.has(id) }));
-vi.mock('@/session/remoteSessionStore', () => ({ remoteSessionStore: {
- subscribe: () => () => {}, getSessions: () => h.sessions,
- getSessionLiveActivity: (id: string) => h.sessions.find(row => row.id === id)?.activity,
- getPendingInteractions: () => [], isSessionRunning: () => false,
-} }));
import { HomeUnreadProvider, useHomeUnreadCounts, usePublishHomeScheduleUnread } from '@/session/HomeUnreadContext';
Object.assign(globalThis, { IS_REACT_ACT_ENVIRONMENT: true });
const container = document.createElement('div'); let root: ReturnType<typeof createRoot>;
-afterEach(() => { act(() => root?.unmount()); });
+beforeEach(() => { remoteSessionStore.clear(); h.focused = true; h.private = []; h.groups = []; h.unread.clear(); });
+afterEach(() => { act(() => root?.unmount()); vi.restoreAllMocks(); remoteSessionStore.clear(); });
+function seed(rows: Array<Partial<RemoteSession> & { id: string }>) {
+ remoteSessionStore.setDeviceSessions('mac', 'Mac', rows.map(row => ({
+ userId: 'owner', title: row.id, status: 'active', workingDir: null, workspaceKind: 'dialogue', model: 'model',
+ agentKind: 'codex', effort: '', permissionMode: 'default', fastMode: false,
+ userSendAt: null, createdAt: '2026-01-01T00:00:00Z', updatedAt: '2026-01-01T00:00:00Z', ...row,
+ })));
+}
+function activity(id: string, phase = 'completed') {
+ remoteSessionStore.applyRemotePush('mac', SESSION_ACTIVITY_CHANNEL, { sessionId: id, phase, attention: true });
+}
let publishSchedules: (ids: ReadonlySet<string>) => void;
function Counts() { publishSchedules = usePublishHomeScheduleUnread(); const counts = useHomeUnreadCounts(); return `${counts.tasks}/${counts.teammates}`; }
it('maps ordinary task attention and unread private/group chats into mutually exclusive destinations', () => {
- h.sessions = ['desktop', 'bot', 'scheduler', 'learn'].map((source, i) => ({ id: `${i}`, source, status: 'active', activity: { phase: 'completed', attention: true } }));
- h.sessions.push({ id: 'archived', status: 'archived', activity: { phase: 'error', attention: true } },
- { id: 'worker', status: 'active', orcaRole: 'worker', activity: { phase: 'completed', attention: true } },
- { id: 'running', status: 'active', activity: { phase: 'running' } });
+ seed([...['desktop', 'bot', 'scheduler', 'learn'].map((source, i) => ({ id: `${i}`, source })),
+ { id: 'archived', status: 'archived' }, { id: 'worker', orcaRole: 'worker' }, { id: 'running' }]);
+ for (const id of ['0', '1', '2', '3', 'worker']) activity(id);
+ activity('archived', 'error'); activity('running', 'running');
const row = (id: string) => ({ host: { deviceId: 'mac' }, item: { ref: { id }, display: { lastReplyAt: 20 } } });
h.private = [row('p1'), row('p2')]; h.groups = [row('g1')]; h.unread = new Set(['p1', 'g1']);
root = createRoot(container);
@@ -35,5 +44,59 @@ it('maps ordinary task attention and unread private/group chats into mutually ex
// Rendering/entering a section cannot acknowledge any rows.
render(); expect(container.textContent).toBe('1/2');
h.unread.delete('g1'); render(); expect(container.textContent).toBe('1/1');
- h.sessions = []; h.private = []; h.groups = []; render(); expect(container.textContent).toBe('0/0');
+ act(() => remoteSessionStore.clear()); h.private = []; h.groups = []; render(); expect(container.textContent).toBe('0/0');
+});
+
+it('does no task scans for message/usage pushes or while covered, then catches up on focus', () => {
+ seed(Array.from({ length: 1000 }, (_, i) => ({ id: `s${i}` })));
+ root = createRoot(container);
+ const render = () => act(() => root.render(createElement(HomeUnreadProvider, { children: createElement(Counts) })));
+ render();
+ const readActivity = vi.spyOn(remoteSessionStore, 'getSessionLiveActivity');
+ act(() => {
+ for (let i = 0; i < 100; i++) {
+ remoteSessionStore.setMessages('s0', [{ id: 'm', clientId: 'm', sessionId: 's0', role: 'assistant',
+ content: `token ${i}`, toolUseId: null, agentMeta: null, createdAt: '2026-01-01T00:00:00Z' }]);
+ remoteSessionStore.applySessionPatch('mac', 's0', { totalTokenUsage: i });
+ }
+ });
+ expect(readActivity).not.toHaveBeenCalled();
+ h.focused = false; render(); readActivity.mockClear();
+ act(() => { activity('s10'); remoteSessionStore.applySessionPatch('mac', 's20', { title: 'renamed' }); });
+ expect(readActivity).not.toHaveBeenCalled();
+ expect(container.textContent).toBe('0/0');
+ h.focused = true; render();
+ expect(container.textContent).toBe('1/0');
+ expect(readActivity).toHaveBeenCalled();
+});
+
+it('covers 1,000 memoized rows without rendering them, then updates only changed previews on return', () => {
+ seed(Array.from({ length: 1000 }, (_, i) => ({ id: `s${i}` })));
+ const renders = new Map<string, number>();
+ const Row = memo(function Row({ id }: { id: string }) {
+ renders.set(id, (renders.get(id) ?? 0) + 1);
+ return <span>{useRemoteSessionMessagePreview(id)}</span>;
+ });
+ root = createRoot(container);
+ const render = (enabled: boolean, count = 1000) => act(() => root.render(
+ <StrictMode><RemoteSessionStoreSubscriptionGate enabled={enabled}>
+ {Array.from({ length: count }, (_, i) => <Row key={i} id={`s${i}`} />)}
+ </RemoteSessionStoreSubscriptionGate></StrictMode>,
+ ));
+ render(true); renders.clear();
+ render(false);
+ expect(renders.size).toBe(0);
+ act(() => remoteSessionStore.setMessages('s10', [{ id: 'm', clientId: 'm', sessionId: 's10', role: 'assistant',
+ content: 'Updated while covered', toolUseId: null, agentMeta: null, createdAt: '2026-01-01T00:00:00Z' }]));
+ expect(renders.size).toBe(0);
+ expect(container.textContent).not.toContain('Updated while covered');
+ render(true);
+ expect([...renders.keys()]).toEqual(['s10']);
+ expect(container.textContent).toContain('Updated while covered');
+ renders.clear(); render(false); render(true);
+ expect(renders.size).toBe(0);
+ // Removed subscribers must not be reattached by a later resume.
+ render(false); render(false, 0); render(true, 0);
+ act(() => remoteSessionStore.setMessages('s10', []));
+ expect(renders.size).toBe(0);
});
diff --git a/apps/mobile/src/__tests__/MountOnFirstOpen.test.tsx b/apps/mobile/src/__tests__/MountOnFirstOpen.test.tsx
new file mode 100644
index 0000000000..261d61215a
--- /dev/null
+++ b/apps/mobile/src/__tests__/MountOnFirstOpen.test.tsx
@@ -0,0 +1,38 @@
+// @vitest-environment jsdom
+import { act, useEffect, useState } from 'react';
+import { createRoot } from 'react-dom/client';
+import { expect, it, vi } from 'vitest';
+import { MountOnFirstOpen } from '@/session/MountOnFirstOpen';
+
+Object.assign(globalThis, { IS_REACT_ACT_ENVIRONMENT: true });
+
+it('skips closed content, then preserves the sheet instance and draft through close/reopen', () => {
+ const container = document.createElement('div');
+ const root = createRoot(container);
+ const mounted = vi.fn(), unmounted = vi.fn();
+ let edit: (value: string) => void = () => {};
+ function Sheet({ open }: { open: boolean }) {
+ const [draft, setDraft] = useState('initial');
+ edit = setDraft;
+ useEffect(() => { mounted(); return () => { unmounted(); }; }, []);
+ return <span data-open={open}>{draft}</span>;
+ }
+ const content = vi.fn((open: boolean) => <Sheet open={open} />);
+ const render = (open: boolean) => act(() => root.render(
+ <MountOnFirstOpen open={open}>{() => content(open)}</MountOnFirstOpen>,
+ ));
+ try {
+ render(false);
+ expect(content).not.toHaveBeenCalled();
+ render(true);
+ act(() => edit('draft'));
+ render(false);
+ expect(container.querySelector('span')?.dataset.open).toBe('false');
+ expect(container.textContent).toBe('draft');
+ expect(unmounted).not.toHaveBeenCalled();
+ render(true);
+ expect(container.textContent).toBe('draft');
+ expect(mounted).toHaveBeenCalledOnce();
+ } finally { act(() => root.unmount()); }
+ expect(unmounted).toHaveBeenCalledOnce();
+});
diff --git a/apps/mobile/src/__tests__/TeammateHomeScreen.test.tsx b/apps/mobile/src/__tests__/TeammateHomeScreen.test.tsx
index 5f1be1e259..6bcfccc599 100644
--- a/apps/mobile/src/__tests__/TeammateHomeScreen.test.tsx
+++ b/apps/mobile/src/__tests__/TeammateHomeScreen.test.tsx
@@ -45,7 +45,11 @@ vi.mock('@react-native-async-storage/async-storage', () => ({ default: {
getItem: async () => h.stored, setItem: async (_key: string, value: string) => { h.stored = value; },
} }));
vi.mock('@/session/HomeSurface', () => ({ MobileHome: (props: unknown) => { h.tasks = props; return null; } }));
-vi.mock('@/session/remoteSessionStore', () => ({ remoteSessionStore: { subscribe: () => () => {}, getSessions: () => [] } }));
+vi.mock('@/session/remoteSessionStore', () => ({
+ remoteSessionStore: { subscribe: () => () => {}, getSessions: () => [] },
+ RemoteSessionStoreSubscriptionGate: ({ children }: { children: React.ReactNode }) => children,
+ useRemoteHomeSessions: () => [], useRemoteHomeStatusVersion: () => 0,
+}));
import HomeScreen from '../../app/devices/index';
import { TeammateHomeScreen } from '@/session/TeammateHomeScreen';
import { teammateIdentity } from '@/session/teammateNavigation';
diff --git a/apps/mobile/src/__tests__/dateFormatters.test.ts b/apps/mobile/src/__tests__/dateFormatters.test.ts
new file mode 100644
index 0000000000..f84d1d81fd
--- /dev/null
+++ b/apps/mobile/src/__tests__/dateFormatters.test.ts
@@ -0,0 +1,22 @@
+import { afterEach, expect, it, vi } from 'vitest';
+import { clearPresentationDateFormatters, formatPresentationDate, formatPresentationTime } from '@/i18n/dateFormatters';
+
+afterEach(() => { vi.restoreAllMocks(); clearPresentationDateFormatters(); });
+
+it('reuses date/time formatters across large histories without caching their output', () => {
+ const NativeFormatter = Intl.DateTimeFormat;
+ const dates = Array.from({ length: 200 }, (_, i) => new Date(Date.UTC(2026, 0, 1, 0, i)));
+ const date = new NativeFormatter('zh-CN');
+ const time = new NativeFormatter('zh-CN', { hour: '2-digit', minute: '2-digit' });
+ const constructor = vi.spyOn(Intl, 'DateTimeFormat');
+ for (const value of dates) {
+ expect(formatPresentationDate(value, 'zh-CN')).toBe(date.format(value));
+ expect(formatPresentationTime(value, 'zh-CN')).toBe(time.format(value));
+ }
+ expect(constructor).toHaveBeenCalledTimes(2);
+ expect(formatPresentationDate(dates[0], 'en')).toBe(new NativeFormatter('en').format(dates[0]));
+ expect(constructor).toHaveBeenCalledTimes(3);
+ clearPresentationDateFormatters(); // foreground return after a timezone change
+ formatPresentationDate(dates[0], 'en');
+ expect(constructor).toHaveBeenCalledTimes(4);
+});
diff --git a/apps/mobile/src/__tests__/historyViewProvider.test.tsx b/apps/mobile/src/__tests__/historyViewProvider.test.tsx
index cd68257d75..86738f6be4 100644
--- a/apps/mobile/src/__tests__/historyViewProvider.test.tsx
+++ b/apps/mobile/src/__tests__/historyViewProvider.test.tsx
@@ -50,7 +50,7 @@ vi.mock('@react-native-async-storage/async-storage', () => ({ default: {
} }));
vi.mock('@/device-link/rnWebSocket', () => ({ createRnWebSocket: vi.fn() }));
vi.mock('@/debug/mobileDebugLog', () => ({ mobileDebugLog: vi.fn() }));
-vi.mock('@/debug/visualMock', () => ({ createVisualMockDeviceLinkContext: vi.fn(), seedVisualMockStore: vi.fn() }));
+vi.mock('@/debug/visualMock', () => ({ prepareVisualMockDeviceLinkContext: vi.fn() }));
vi.mock('@cindy/maker-shared/device-responsiveness', async (importOriginal) => {
const actual = await importOriginal<typeof import('@cindy/maker-shared/device-responsiveness')>();
return { ...actual, createDeviceResponsivenessBreaker: (options: Parameters<typeof actual.createDeviceResponsivenessBreaker>[0]) =>
diff --git a/apps/mobile/src/__tests__/homeAutomationWindow.test.tsx b/apps/mobile/src/__tests__/homeAutomationWindow.test.tsx
new file mode 100644
index 0000000000..b06cd8bf00
--- /dev/null
+++ b/apps/mobile/src/__tests__/homeAutomationWindow.test.tsx
@@ -0,0 +1,180 @@
+// @vitest-environment jsdom
+import { readFileSync } from 'node:fs';
+import { resolve } from 'node:path';
+import * as jsxRuntime from 'react/jsx-runtime';
+import { act, Children, createContext, forwardRef, Fragment, isValidElement, useContext, useRef, useState, type ReactElement, type ReactNode } from 'react';
+import { createRoot } from 'react-dom/client';
+import ts from 'typescript';
+import { expect, it, vi } from 'vitest';
+import { getRemoteSessionPreviewCollapse, toRemoteSessionListItem } from '@cindy/maker-shared/session-list';
+import { buildHomeProjectChildOffsets, resolveHomeProjectChildAnchor, resolveHomeProjectChildWindow, shouldWindowHomeProjectChildren } from '@/session/homeProjectChildWindow';
+
+// Exercise the production child renderer without importing the entire native
+// navigation stack. Anchor math is covered separately; native measurement needs
+// an on-device scroll check.
+const source = ts.createSourceFile('HomeSurface.tsx', readFileSync(resolve(process.cwd(), 'src/session/HomeSurface.tsx'), 'utf8'),
+ ts.ScriptTarget.Latest, true, ts.ScriptKind.TSX);
+const declaration = source.statements.find((node): node is ts.FunctionDeclaration => ts.isFunctionDeclaration(node)
+ && node.name?.text === 'AutomationGroupChildren')!;
+const compiled = ts.transpileModule(declaration.getText(source), {
+ compilerOptions: { target: ts.ScriptTarget.ES2022, module: ts.ModuleKind.CommonJS, jsx: ts.JsxEmit.ReactJSX },
+}).outputText;
+
+function renderChildren(count: number, anchor: number, old = false) {
+ const now = Date.now();
+ const items = Array.from({ length: count }, (_, i) => toRemoteSessionListItem({
+ id: `s${i}`, title: `Run ${i}`, status: 'active', agentKind: 'codex', model: 'model', workingDir: '/repo',
+ createdAt: new Date(now - (old ? 30 * 86400000 : 1000)).toISOString(),
+ updatedAt: new Date(now - (old ? 30 * 86400000 : 1000)).toISOString(),
+ }, now));
+ const onOpenSession = vi.fn();
+ const dependencies = {
+ exports: {},
+ require: () => jsxRuntime,
+ useThemedStyles: () => ({}), makeStyles: () => ({}), useTheme: () => ({ colors: {} }),
+ useTranslation: () => ({ t: () => '' }), useRemoteHomeStatusVersion: () => 0,
+ getRemoteSessionPreviewCollapse, PROJECT_PREVIEW_LIMIT: 5,
+ remoteSessionStore: { isSessionRunning: () => false },
+ useContext: () => ({ scrollY: { value: 0 }, viewportHeight: 800 }), HomeListViewportContext: {},
+ useAnimatedRef: () => ({}), useSharedValue: (value: number) => ({ value }), useState: () => [anchor, () => {}],
+ buildHomeProjectChildOffsets, estimateHomeSessionRowHeight: () => 60,
+ shouldWindowHomeProjectChildren, resolveHomeProjectChildWindow,
+ PROJECT_CHILD_WINDOW_THRESHOLD: 20, PROJECT_CHILD_WINDOW_OVERSCAN: 4, PROJECT_CHILD_WINDOW_SIZE: 15,
+ Reanimated: { View: 'animated-view' }, View: 'view', HomeProjectWindowAnchorTracker: 'tracker',
+ HomeSessionRow: 'row', SwipeableSessionRow: 'swipe', Fragment,
+ Pressable: 'button', Text: 'text', ChevronRight: 'chevron', iconSize: {}, iconStroke: {},
+ };
+ const render = new Function(...Object.keys(dependencies), `${compiled}; return AutomationGroupChildren;`)(...Object.values(dependencies));
+ const tree = render({ group: { key: 'group', items, sessionCount: count }, testID: 'fixture',
+ onOpenSession, onOpenGroup: () => {}, inBlock: true, swipe: { registry: {}, onArchive: vi.fn() } });
+ const elements: ReactElement<Record<string, any>>[] = [];
+ function visit(node: ReactNode) {
+ Children.forEach(node, child => {
+ if (!isValidElement(child)) return;
+ const element = child as ReactElement<Record<string, any>>;
+ elements.push(element); visit(element.props.children);
+ });
+ }
+ visit(tree);
+ return { elements, onOpenSession };
+}
+
+it('bounds 200 recent runs before layout, while scrolling, and when reversing to the beginning', () => {
+ for (const anchor of [-1, 0, 4, 96, 196, 96, 0]) {
+ const { elements, onOpenSession } = renderChildren(200, anchor);
+ const rows = elements.filter(node => node.type === 'row');
+ expect(rows.length).toBeLessThanOrEqual(23);
+ expect(rows.length).toBe(anchor < 0 ? 0 : anchor === 196 ? 15 : 23);
+ const spacerHeight = elements.filter(node => node.type === 'view').reduce((sum, node) => sum + (node.props.style?.height ?? 0), 0);
+ expect(spacerHeight + rows.length * 60).toBe(200 * 60);
+ if (anchor < 0) continue;
+ const first = rows[0];
+ first.props.onOpenSession(first.props.item);
+ expect(onOpenSession).toHaveBeenCalledWith(first.props.item);
+ if (anchor === 0) expect(first.props.item.session.id).toBe('s0');
+ if (anchor === 196) {
+ expect(rows.at(-1)!.props.item.session.id).toBe('s199');
+ expect(rows.at(-1)!.props.hideDivider).toBe(true);
+ }
+ }
+});
+
+it('preserves small previews and the view-all action for old runs', () => {
+ expect(renderChildren(5, -1).elements.filter(node => node.type === 'row')).toHaveLength(5);
+ const { elements } = renderChildren(200, -1, true);
+ expect(elements.filter(node => node.type === 'row')).toHaveLength(5);
+ expect(elements.filter(node => node.type === 'button')).toHaveLength(1);
+});
+
+it('connects native layout and scroll measurements through the real tracker to rendered rows', () => {
+ Object.assign(globalThis, { IS_REACT_ACT_ENVIRONMENT: true });
+ const tracker = source.statements.find((node): node is ts.FunctionDeclaration => ts.isFunctionDeclaration(node)
+ && node.name?.text === 'HomeProjectWindowAnchorTracker')!;
+ const trackerCode = ts.transpileModule(tracker.getText(source), {
+ compilerOptions: { target: ts.ScriptTarget.ES2022 },
+ }).outputText;
+ let prepare!: () => number | null;
+ let react!: (next: number | null, previous: number | null) => void;
+ let onLayout!: () => void;
+ let pageY: number | null = 200;
+ let scrollOffset = 0;
+ const readScroll = vi.fn(() => scrollOffset);
+ const scrollY = { get value() { return readScroll(); } };
+ const Viewport = createContext<{ scrollY: { readonly value: number }; viewportHeight: number } | null>(null);
+ const container = document.createElement('div');
+ const NativeView = forwardRef<HTMLDivElement, { children?: ReactNode; onLayout(): void; testID: string }>(
+ function NativeView({ children, onLayout: callback, testID }, ref) {
+ onLayout = callback;
+ return <div ref={ref} data-testid={testID}>{children}</div>;
+ },
+ );
+ const measure = vi.fn((ref: { current: HTMLElement | null }) => {
+ expect(ref.current).toBe(container.querySelector('[data-testid="fixture.automationGroupChildren"]'));
+ return pageY === null ? null : { pageY };
+ });
+ const dependencies = {
+ exports: {}, require: () => jsxRuntime,
+ useThemedStyles: () => ({}), makeStyles: () => ({}), useTheme: () => ({ colors: {} }),
+ useTranslation: () => ({ t: () => '' }), useRemoteHomeStatusVersion: () => 0,
+ getRemoteSessionPreviewCollapse, PROJECT_PREVIEW_LIMIT: 5,
+ remoteSessionStore: { isSessionRunning: () => false },
+ useContext, HomeListViewportContext: Viewport, useState,
+ useAnimatedRef: () => useRef(null), useSharedValue: (value: number) => useRef({ value }).current,
+ useAnimatedReaction: (p: typeof prepare, r: typeof react) => { prepare = p; react = r; },
+ measure, runOnJS: (callback: unknown) => callback,
+ buildHomeProjectChildOffsets, estimateHomeSessionRowHeight: () => 60,
+ shouldWindowHomeProjectChildren, resolveHomeProjectChildWindow, resolveHomeProjectChildAnchor,
+ PROJECT_CHILD_WINDOW_THRESHOLD: 20, PROJECT_CHILD_WINDOW_OVERSCAN: 4,
+ PROJECT_CHILD_WINDOW_SIZE: 15, PROJECT_CHILD_WINDOW_SHIFT: 4,
+ Reanimated: { View: NativeView }, View: ({ style }: { style: { height: number } }) => <div data-spacer={style.height} />,
+ HomeSessionRow: ({ item, onOpenSession }: { item: ReturnType<typeof toRemoteSessionListItem>; onOpenSession(item: unknown): void }) =>
+ <button data-row={item.session.id} onClick={() => onOpenSession(item)}>{item.title}</button>,
+ Fragment,
+ };
+ // Both production functions execute; only the native measurement/worklet bridge is simulated.
+ const Group = new Function(...Object.keys(dependencies), `${compiled}\n${trackerCode}\nreturn AutomationGroupChildren;`)(...Object.values(dependencies));
+ const now = Date.now();
+ const items = Array.from({ length: 200 }, (_, i) => toRemoteSessionListItem({
+ id: `s${i}`, title: `Run ${i}`, status: 'active', agentKind: 'codex', model: 'model', workingDir: '/repo',
+ createdAt: new Date(now).toISOString(), updatedAt: new Date(now).toISOString(),
+ }, now));
+ const open = vi.fn();
+ const root = createRoot(container);
+ const rows = () => [...container.querySelectorAll<HTMLButtonElement>('[data-row]')];
+ let previous: number | null = null;
+ function frame(nextPageY: number | null, offset: number) {
+ pageY = nextPageY; scrollOffset = offset; readScroll.mockClear();
+ act(() => { const next = prepare(); react(next, previous); previous = next; });
+ expect(readScroll).toHaveBeenCalled();
+ expect(rows().length).toBeLessThanOrEqual(23);
+ }
+ try {
+ act(() => root.render(<Viewport.Provider value={{ scrollY, viewportHeight: 800 }}>
+ <Group group={{ key: 'group', items, sessionCount: 200 }} testID="fixture" onOpenSession={open} />
+ </Viewport.Provider>));
+ frame(200, 0);
+ expect(measure).not.toHaveBeenCalled();
+ expect(rows()).toHaveLength(0);
+ act(() => onLayout());
+ frame(200, 0);
+ expect(rows()).toHaveLength(23);
+ expect(rows()[0].dataset.row).toBe('s0');
+ frame(-6000, 6200);
+ expect(rows()[0].dataset.row).toBe('s96');
+ act(() => rows()[0].click());
+ expect(open).toHaveBeenLastCalledWith(items[96]);
+ frame(null, 6500); // A transient native measurement failure must not blank the list.
+ expect(rows()[0].dataset.row).toBe('s96');
+ frame(-11800, 12000);
+ expect(rows().at(-1)?.dataset.row).toBe('s199');
+ frame(-12000, 12200);
+ expect(rows()).toHaveLength(0); // Fully outside the viewport.
+ frame(-11800, 12000);
+ expect(rows().at(-1)?.dataset.row).toBe('s199');
+ frame(200, 0);
+ expect(rows()[0].dataset.row).toBe('s0');
+ const spacers = [...container.querySelectorAll<HTMLElement>('[data-spacer]')]
+ .reduce((sum, node) => sum + Number(node.dataset.spacer), 0);
+ expect(spacers + rows().length * 60).toBe(12000);
+ } finally { act(() => root.unmount()); }
+});
diff --git a/apps/mobile/src/__tests__/homeProjectChildWindow.test.ts b/apps/mobile/src/__tests__/homeProjectChildWindow.test.ts
index 999f0bd0b3..87217f4bdd 100644
--- a/apps/mobile/src/__tests__/homeProjectChildWindow.test.ts
+++ b/apps/mobile/src/__tests__/homeProjectChildWindow.test.ts
@@ -141,8 +141,18 @@ describe('home project child window', () => {
it('bounds the outer home list window instead of retaining every flat row', () => {
const source = readFileSync(resolve(process.cwd(), 'src/session/HomeSurface.tsx'), 'utf8');
- expect(source).toContain('initialNumToRender={HOME_LIST_INITIAL_RENDER_COUNT}');
- expect(source).toContain('maxToRenderPerBatch={HOME_LIST_RENDER_BATCH_SIZE}');
+ const readBatch = (attribute: string, platform: string, grouped: boolean) => {
+ const expression = source.match(new RegExp(`${attribute}=\\{([^}]+)\\}`))?.[1];
+ expect(expression).toBeDefined();
+ return new Function('Platform', 'groupByProject', 'HOME_LIST_INITIAL_RENDER_COUNT', 'HOME_LIST_RENDER_BATCH_SIZE',
+ `return (${expression});`)({ OS: platform }, grouped, 12, 12);
+ };
+ for (const platform of ['android', 'ios']) {
+ for (const grouped of [false, true]) {
+ expect(readBatch('initialNumToRender', platform, grouped)).toBe(platform === 'android' && grouped ? 4 : 12);
+ expect(readBatch('maxToRenderPerBatch', platform, grouped)).toBe(platform === 'android' && grouped ? 2 : 12);
+ }
+ }
expect(source).toContain('updateCellsBatchingPeriod={32}');
expect(source).toContain('windowSize={HOME_LIST_WINDOW_SIZE}');
});
diff --git a/apps/mobile/src/__tests__/homeSessionProjection.test.ts b/apps/mobile/src/__tests__/homeSessionProjection.test.ts
new file mode 100644
index 0000000000..99ccc0adbf
--- /dev/null
+++ b/apps/mobile/src/__tests__/homeSessionProjection.test.ts
@@ -0,0 +1,56 @@
+import { beforeEach, expect, it, vi } from 'vitest';
+import { remoteSessionStore } from '@/session/remoteSessionStore';
+import type { RemoteSession } from '@/session/types';
+
+function session(id: string): RemoteSession {
+ return { id, userId: 'owner', title: id, workingDir: '/repo', workspaceKind: 'project', model: 'model', effort: '',
+ permissionMode: 'default', fastMode: false, status: 'active', agentKind: 'codex',
+ userSendAt: null, createdAt: '2026-01-01T00:00:00Z', updatedAt: '2026-01-01T00:00:00Z' };
+}
+beforeEach(() => remoteSessionStore.clear());
+
+it('keeps Home stable through 100 usage pushes while details receive every update', () => {
+ remoteSessionStore.setDeviceSessions('host', 'Host', Array.from({ length: 1000 }, (_, i) => session(`s${i}`)));
+ const home = remoteSessionStore.getHomeSessions();
+ const notifyHome = vi.fn(), notifyDetail = vi.fn();
+ const stopHome = remoteSessionStore.subscribeHomeStatus(notifyHome);
+ const stopDetail = remoteSessionStore.subscribe(notifyDetail);
+ try {
+ for (let i = 1; i <= 100; i++) {
+ remoteSessionStore.applyRemotePush('host', 'usage:session-tokens-changed', { sessionId: 's0', totalTokens: i });
+ expect(remoteSessionStore.getSessions()[0].totalTokenUsage).toBe(i);
+ expect(remoteSessionStore.getHomeSessions()).toBe(home);
+ }
+ expect(notifyHome).not.toHaveBeenCalled();
+ expect(notifyDetail).toHaveBeenCalledTimes(100);
+ remoteSessionStore.applySessionPatch('host', 's0', { title: 'renamed', totalCostUsd: 2 });
+ expect(remoteSessionStore.getHomeSessions()[0].title).toBe('renamed');
+ expect(remoteSessionStore.getSessions()[0].totalTokenUsage).toBe(100);
+ expect(remoteSessionStore.getHomeSessions()[1]).toBe(home[1]);
+ expect(notifyHome).toHaveBeenCalledOnce();
+ } finally { stopHome(); stopDetail(); }
+});
+
+it('reconciles usage-only full snapshots and still publishes reorder, archive and clear', () => {
+ remoteSessionStore.setDeviceSessions('host', 'Host', [session('a'), session('b')]);
+ const home = remoteSessionStore.getHomeSessions();
+ remoteSessionStore.setDeviceSessions('host', 'Host', [{ ...session('a'), totalCostUsd: 5 }, session('b')]);
+ expect(remoteSessionStore.getHomeSessions()).toBe(home);
+ expect(remoteSessionStore.getSessions()[0].totalCostUsd).toBe(5);
+ remoteSessionStore.setDeviceSessions('host', 'Host', [session('b'), session('a')]);
+ expect(remoteSessionStore.getHomeSessions()).toEqual([home[1], home[0]]);
+ remoteSessionStore.applySessionPatch('host', 'a', { status: 'archived' });
+ expect(remoteSessionStore.getHomeSessions().map(row => row.id)).toEqual(['b']);
+ remoteSessionStore.clear();
+ expect(remoteSessionStore.getHomeSessions()).toEqual([]);
+});
+
+it('does not let a stale shard usage patch replace the canonical device winner', () => {
+ remoteSessionStore.setDeviceIdentity([{ deviceId: 'new', name: 'Host' }]);
+ remoteSessionStore.setDeviceSessions('old', 'Host', [session('a')]);
+ remoteSessionStore.setDeviceSessions('new', 'Host', [{ ...session('a'), totalCostUsd: 4 }]);
+ const current = remoteSessionStore.getSessions()[0];
+ remoteSessionStore.applySessionPatch('old', 'a', { totalCostUsd: 99 });
+ expect(remoteSessionStore.getSessions()[0]).toBe(current);
+ expect(current.deviceLinkDeviceId).toBe('new');
+});
diff --git a/apps/mobile/src/__tests__/inactiveSessionListSubscriptions.test.ts b/apps/mobile/src/__tests__/inactiveSessionListSubscriptions.test.ts
index 794fa526b7..41582ec3e7 100644
--- a/apps/mobile/src/__tests__/inactiveSessionListSubscriptions.test.ts
+++ b/apps/mobile/src/__tests__/inactiveSessionListSubscriptions.test.ts
@@ -20,7 +20,7 @@ describe('inactive session list subscriptions', () => {
it('pauses list and row subscriptions while their route is covered', () => {
const store = source('src/session/remoteSessionStore.ts');
expect(store).toContain(
- 'enabled ? subscribe : INACTIVE_REMOTE_SESSION_STORE_SUBSCRIBE',
+ 'gate ? gate.subscribe(subscribe, notify) : subscribe(notify)',
);
expect(store).toContain(
"usePausableRemoteSessionStoreSnapshot('sessions', remoteSessionStore.getSessions)",
diff --git a/apps/mobile/src/__tests__/localeFormatterResume.test.tsx b/apps/mobile/src/__tests__/localeFormatterResume.test.tsx
new file mode 100644
index 0000000000..6abb05d143
--- /dev/null
+++ b/apps/mobile/src/__tests__/localeFormatterResume.test.tsx
@@ -0,0 +1,43 @@
+// @vitest-environment jsdom
+import { act } from 'react';
+import { createRoot } from 'react-dom/client';
+import { expect, it, vi } from 'vitest';
+import { clearSessionListCollator, compareSessionListStrings } from '@cindy/maker-shared/session-list';
+
+const native = vi.hoisted(() => ({ listener: null as null | ((state: string) => void), remove: vi.fn() }));
+vi.mock('react-native', () => ({ AppState: { addEventListener: (_event: string, listener: typeof native.listener) => {
+ native.listener = listener;
+ return { remove: native.remove };
+} } }));
+vi.mock('@/i18n/appLanguage', () => ({ setManualLocaleOverride: vi.fn() }));
+vi.mock('@/i18n/index', () => ({ detectSystemLocale: () => 'en', i18n: { changeLanguage: vi.fn() } }));
+vi.mock('@/i18n/languagePreferenceStore', () => ({ readLanguagePreference: async () => 'system', saveLanguagePreference: vi.fn() }));
+import { LocaleProvider } from '@/i18n/useLocale';
+
+Object.assign(globalThis, { IS_REACT_ACT_ENVIRONMENT: true });
+
+it('reuses the system collator until foreground return, then picks up the new region', async () => {
+ clearSessionListCollator();
+ const OriginalCollator = Intl.Collator;
+ let systemLocale = 'en';
+ const constructor = vi.spyOn(Intl, 'Collator').mockImplementation(() => new OriginalCollator(systemLocale));
+ const root = createRoot(document.createElement('div'));
+ try {
+ await act(async () => root.render(<LocaleProvider><span /></LocaleProvider>));
+ expect(compareSessionListStrings('ä', 'z')).toBeLessThan(0);
+ for (let i = 0; i < 1000; i++) compareSessionListStrings('a', 'b');
+ expect(constructor).toHaveBeenCalledTimes(1);
+ act(() => native.listener?.('background'));
+ systemLocale = 'sv';
+ expect(compareSessionListStrings('ä', 'z')).toBeLessThan(0);
+ act(() => native.listener?.('active'));
+ expect(compareSessionListStrings('ä', 'z')).toBeGreaterThan(0);
+ compareSessionListStrings('a', 'b');
+ expect(constructor).toHaveBeenCalledTimes(2);
+ } finally {
+ act(() => root.unmount());
+ constructor.mockRestore();
+ clearSessionListCollator();
+ }
+ expect(native.remove).toHaveBeenCalledOnce();
+});
diff --git a/apps/mobile/src/__tests__/remoteSessionStore.test.ts b/apps/mobile/src/__tests__/remoteSessionStore.test.ts
index db7865e3d6..274ba8250c 100644
--- a/apps/mobile/src/__tests__/remoteSessionStore.test.ts
+++ b/apps/mobile/src/__tests__/remoteSessionStore.test.ts
@@ -5300,6 +5300,23 @@ describe('任务消息内存治理', () => {
expect(remoteSessionStore.getSessionRetention('bound')).toBe('regular');
});
+ it('keeps retention lookup current across patch, shard replacement, removal and ID reuse', () => {
+ remoteSessionStore.setDeviceSessions('dev-1', 'Mac', [session('s1')]);
+ remoteSessionStore.applySessionPatch('dev-1', 's1', { source: 'scheduler' });
+ remoteSessionStore.applySessionPatch('dev-1', 's1', { totalCostUsd: 5 });
+ expect(remoteSessionStore.getSessionRetention('s1')).toBe('schedule');
+ remoteSessionStore.setDeviceSessions('dev-1', 'Mac', [session('s1')]);
+ expect(remoteSessionStore.getSessionRetention('s1')).toBe('regular');
+ remoteSessionStore.applySessionPatch('dev-1', 's1', { source: 'scheduler' });
+ remoteSessionStore.removeDevice('dev-1');
+ expect(remoteSessionStore.getSessionRetention('s1')).toBe('regular');
+ remoteSessionStore.setDeviceSessions('dev-2', 'PC', [session('s1', { source: 'scheduler' })]);
+ remoteSessionStore.clear();
+ expect(remoteSessionStore.getSessionRetention('s1')).toBe('regular');
+ remoteSessionStore.setDeviceSessions('dev-2', 'PC', [session('s1')]);
+ expect(remoteSessionStore.getSessionRetention('s1')).toBe('regular');
+ });
+
it('旧详情代际的读取在 blur→refocus 后不能覆盖新窗口', () => {
remoteSessionStore.setDeviceSessions('dev-1', 'Mac', [session('s1', { source: 'scheduler' })]);
const first = remoteSessionStore.enterSessionMessageDetail('s1');
diff --git a/apps/mobile/src/__tests__/sessionList.test.ts b/apps/mobile/src/__tests__/sessionList.test.ts
index de3309a4e9..44cc3b5fec 100644
--- a/apps/mobile/src/__tests__/sessionList.test.ts
+++ b/apps/mobile/src/__tests__/sessionList.test.ts
@@ -1,5 +1,5 @@
import { performance } from 'node:perf_hooks';
-import { beforeAll, describe, expect, it } from 'vitest';
+import { beforeAll, describe, expect, it, vi } from 'vitest';
import { resolveMobileSessionRowStatus } from '@/session/sessionRightStatus';
import { i18n } from '@/i18n';
import {
@@ -7,6 +7,7 @@ import {
buildRemoteSessionListContext,
buildRemoteSessionCardPreview,
buildRemoteSessionSections,
+ createSessionListTranslator,
buildSessionScheduleIndex,
deviceSessionEmptyState,
formatRemoteSessionSidebarTime,
@@ -24,6 +25,25 @@ beforeAll(async () => {
await i18n.changeLanguage('zh-CN');
});
+it('translates repeated list labels once per build and refreshes on language changes', async () => {
+ const spy = vi.spyOn(i18n, 't');
+ try {
+ const translate = createSessionListTranslator();
+ const first = translate('devices.detail.filter.active');
+ for (let i = 0; i < 1000; i++) expect(translate('devices.detail.filter.active')).toBe(first);
+ expect(spy).toHaveBeenCalledTimes(1);
+ expect(translate('devices.presentation.sessionList.sessionCount', { count: 1 }))
+ .not.toBe(translate('devices.presentation.sessionList.sessionCount', { count: 2 }));
+ await i18n.changeLanguage('en');
+ const next = createSessionListTranslator();
+ expect(next('devices.detail.filter.active')).toBe(i18n.t('devices.detail.filter.active'));
+ expect(next('devices.detail.filter.active')).not.toBe(first);
+ } finally {
+ spy.mockRestore();
+ await i18n.changeLanguage('zh-CN');
+ }
+});
+
function session(id: string, patch: Partial<RemoteSession> = {}): RemoteSession {
return {
id,
diff --git a/apps/mobile/src/__tests__/visualMock.test.ts b/apps/mobile/src/__tests__/visualMock.test.ts
index 2b653522ab..d4dba2ae00 100644
--- a/apps/mobile/src/__tests__/visualMock.test.ts
+++ b/apps/mobile/src/__tests__/visualMock.test.ts
@@ -10,7 +10,91 @@ vi.mock('@/session/remoteSessionStore', () => ({ remoteSessionStore: {
setInputProjection: vi.fn(), setPendingInteractions: vi.fn(), setActiveSessionSnapshots: vi.fn(),
} }));
beforeEach(() => { vi.resetModules(); config.MOBILE_VISUAL_MOCK_REALDATA_URL = ''; });
-afterEach(() => vi.unstubAllGlobals());
+afterEach(() => { vi.useRealTimers(); vi.unstubAllGlobals(); vi.restoreAllMocks(); vi.clearAllMocks(); });
+
+it('waits for all 1,000 imported tasks before seeding and publishing their device identity', async () => {
+ vi.useFakeTimers();
+ config.MOBILE_VISUAL_MOCK_REALDATA_URL = 'https://fixture.invalid/snapshot.json';
+ let resolveFetch!: (value: unknown) => void;
+ vi.stubGlobal('fetch', vi.fn(() => new Promise(resolve => { resolveFetch = resolve; })));
+ const mock = await import('@/debug/visualMock');
+ const { remoteSessionStore: store } = await import('@/session/remoteSessionStore');
+ const ready = mock.prepareVisualMockDeviceLinkContext();
+ expect(mock.prepareVisualMockDeviceLinkContext()).toBe(ready);
+ expect(store.setDeviceSessions).not.toHaveBeenCalled();
+ const sessions = Array.from({ length: 1000 }, (_, i) => ({ id: `imported-${i}` }));
+ resolveFetch({ ok: true, json: async () => ({ schema: 'cindy-mobile-visual-realdata-v1',
+ device: { deviceId: 'real-device', name: 'Imported 1000' }, sessions, messagesBySession: {} }) });
+ const link = await ready;
+ expect(store.setDeviceSessions).toHaveBeenCalledExactlyOnceWith('real-device', 'Imported 1000', sessions);
+ expect(store.setMessages).toHaveBeenCalledTimes(1000);
+ expect(link.lastPresenceSnapshot).toMatchObject({ deviceId: 'real-device', deviceName: 'Imported 1000' });
+ expect((await link.readDeviceList()).devices.find(device => device.deviceId === 'real-device')?.name).toBe('Imported 1000');
+ expect(vi.getTimerCount()).toBe(0);
+});
+
+it.each(['fetch', 'body'])('falls back when snapshot %s stalls and ignores a late response', async (phase) => {
+ vi.useFakeTimers();
+ config.MOBILE_VISUAL_MOCK_REALDATA_URL = 'https://fixture.invalid/snapshot.json';
+ const warn = vi.spyOn(console, 'warn').mockImplementation(() => {});
+ let resolveStalled!: (value: unknown) => void;
+ const stalled = new Promise(resolve => { resolveStalled = resolve; });
+ const fetchMock = vi.fn(() => phase === 'fetch' ? stalled : Promise.resolve({ ok: true, json: () => stalled }));
+ vi.stubGlobal('fetch', fetchMock);
+ const mock = await import('@/debug/visualMock');
+ const { remoteSessionStore: store } = await import('@/session/remoteSessionStore');
+ const ready = mock.prepareVisualMockDeviceLinkContext();
+ await vi.advanceTimersByTimeAsync(mock.VISUAL_REALDATA_TIMEOUT_MS - 1);
+ expect(store.setDeviceSessions).not.toHaveBeenCalled();
+ await vi.advanceTimersByTimeAsync(1);
+ const link = await ready;
+ expect(fetchMock).toHaveBeenCalledTimes(1);
+ expect(vi.mocked(fetch).mock.calls[0][1]?.signal?.aborted).toBe(true);
+ expect(link.lastPresenceSnapshot?.deviceId).toBe(mock.VISUAL_MOCK_DEVICE_ID);
+ expect((await link.readDeviceList()).devices.some(device => device.deviceId === mock.VISUAL_MOCK_DEVICE_ID)).toBe(true);
+ expect(store.setDeviceSessions).toHaveBeenCalledExactlyOnceWith(
+ mock.VISUAL_MOCK_DEVICE_ID, mock.VISUAL_MOCK_DEVICE_NAME, expect.any(Array),
+ );
+ const sessions = await link.invoke<unknown[]>(mock.VISUAL_MOCK_DEVICE_ID, 'local-db:sessions:list');
+ expect(sessions.length).toBeGreaterThan(0);
+ const snapshot = { schema: 'cindy-mobile-visual-realdata-v1',
+ device: { deviceId: 'late-device', name: 'Late import' }, sessions: [{ id: 'late-session' }], messagesBySession: {} };
+ resolveStalled(phase === 'fetch' ? { ok: true, json: async () => snapshot } : snapshot);
+ await vi.advanceTimersByTimeAsync(0);
+ expect(await link.invoke(mock.VISUAL_MOCK_DEVICE_ID, 'local-db:sessions:list')).toEqual(sessions);
+ expect(store.setDeviceSessions).toHaveBeenCalledTimes(1);
+ expect(mock.createVisualMockDeviceLinkContext().lastPresenceSnapshot?.deviceId).toBe(mock.VISUAL_MOCK_DEVICE_ID);
+ expect(mock.prepareVisualMockDeviceLinkContext()).toBe(ready);
+ expect(fetchMock).toHaveBeenCalledTimes(1);
+ expect(warn).toHaveBeenCalledTimes(1);
+ expect(vi.getTimerCount()).toBe(0);
+});
+
+it.each(['network', 'http', 'invalid'])('uses a consistent demo device after a %s failure', async (failure) => {
+ vi.useFakeTimers();
+ config.MOBILE_VISUAL_MOCK_REALDATA_URL = 'https://fixture.invalid/snapshot.json';
+ vi.spyOn(console, 'warn').mockImplementation(() => {});
+ vi.stubGlobal('fetch', vi.fn(() => failure === 'network' ? Promise.reject(new Error('offline'))
+ : Promise.resolve({ ok: failure !== 'http', status: 503, json: async () => ({}) })));
+ const mock = await import('@/debug/visualMock');
+ const link = await mock.prepareVisualMockDeviceLinkContext();
+ const { remoteSessionStore: store } = await import('@/session/remoteSessionStore');
+ expect(link.lastPresenceSnapshot?.deviceId).toBe(mock.VISUAL_MOCK_DEVICE_ID);
+ expect(store.setDeviceSessions).toHaveBeenCalledExactlyOnceWith(
+ mock.VISUAL_MOCK_DEVICE_ID, mock.VISUAL_MOCK_DEVICE_NAME, expect.any(Array),
+ );
+ expect(vi.getTimerCount()).toBe(0);
+});
+
+it('supplies the task tag catalog required when opening session options', async () => {
+ const mock = await import('@/debug/visualMock');
+ const link = mock.createVisualMockDeviceLinkContext();
+ expect(await link.invoke(mock.VISUAL_MOCK_DEVICE_ID, 'local-db:task-tags:execute', [{ action: 'list' }]))
+ .toMatchObject({ tags: [], sessions: [] });
+ expect(await link.invoke(mock.VISUAL_MOCK_DEVICE_ID, 'local-db:task-tags:execute',
+ [{ action: 'get', sessionIds: ['session-primary'] }]))
+ .toMatchObject({ tags: [], sessions: [{ sessionId: 'session-primary', tags: [] }] });
+});
it('projects imported history rows without falling back to synthetic messages', async () => {
config.MOBILE_VISUAL_MOCK_REALDATA_URL = 'https://fixture.invalid/snapshot.json';
diff --git a/apps/mobile/src/debug/visualMock.ts b/apps/mobile/src/debug/visualMock.ts
index 37b924c761..7284912b92 100644
--- a/apps/mobile/src/debug/visualMock.ts
+++ b/apps/mobile/src/debug/visualMock.ts
@@ -1,5 +1,6 @@
import { SHARED_REMOTE_CONTROL_FIXTURE } from '@cindy/maker-shared/fixtures';
import { projectHistoryView } from '@cindy/maker-shared/message-window';
+import { TASK_TAG_COLORS, type TaskTagRequest, type TaskTagResult } from '@cindy/maker-shared';
import { ApiError, type ApiFetchOptions } from '@/api/client';
import type { DeviceView, LinkAcceptPayload } from '@cindy/device-link';
import type { MobileUser } from '@/auth/AuthContext';
@@ -27,6 +28,7 @@ export const VISUAL_MOCK_OFFLINE_DEVICE_ID = 'cindy-visual-mock-offline-mac';
const VISUAL_MOCK_REALDATA_DEVICE_ID = 'cindy-realdata-mac';
const VISUAL_MOCK_REALDATA_DEVICE_NAME = 'CINDY Real Data Mac';
export const VISUAL_MOCK_SESSION_ID = 'session-primary';
+export const VISUAL_REALDATA_TIMEOUT_MS = 5_000;
interface VisualRealDataSnapshot {
schema: 'cindy-mobile-visual-realdata-v1';
@@ -65,12 +67,14 @@ export const visualMockUser: MobileUser = {
let realDataSnapshot: VisualRealDataSnapshot | null = null;
let realDataLoadPromise: Promise<VisualRealDataSnapshot | null> | null = null;
+let preparedContextPromise: Promise<DeviceLinkContextValue> | null = null;
let didWarnRealDataLoad = false;
const deletedDeviceIds = new Set<string>();
const renamedDevices = new Map<string, string>();
export function visualMockDevices(): DeviceView[] {
const realData = realDataSnapshot;
+ const awaitingRealData = MOBILE_VISUAL_MOCK_REALDATA_URL && !didWarnRealDataLoad;
const desktopDevice = realData
? {
deviceId: realData.device.deviceId,
@@ -79,10 +83,10 @@ export function visualMockDevices(): DeviceView[] {
appVersion: realData.device.appVersion ?? '0.0.0-realdata-preview',
}
: {
- deviceId: MOBILE_VISUAL_MOCK_REALDATA_URL ? VISUAL_MOCK_REALDATA_DEVICE_ID : VISUAL_MOCK_DEVICE_ID,
- name: MOBILE_VISUAL_MOCK_REALDATA_URL ? VISUAL_MOCK_REALDATA_DEVICE_NAME : VISUAL_MOCK_DEVICE_NAME,
+ deviceId: awaitingRealData ? VISUAL_MOCK_REALDATA_DEVICE_ID : VISUAL_MOCK_DEVICE_ID,
+ name: awaitingRealData ? VISUAL_MOCK_REALDATA_DEVICE_NAME : VISUAL_MOCK_DEVICE_NAME,
platform: 'darwin',
- appVersion: MOBILE_VISUAL_MOCK_REALDATA_URL ? '0.0.0-realdata-preview' : '0.0.0-visual-mock',
+ appVersion: awaitingRealData ? '0.0.0-realdata-preview' : '0.0.0-visual-mock',
};
return [
{
@@ -148,12 +152,24 @@ export function seedVisualMockStore(): void {
});
}
+/** Import before mounting Home: otherwise its cached list races the default
+ * eight demo tasks and a presence snapshot with the placeholder device name.
+ * Sharing the preparation also avoids double seeding under StrictMode. */
+export function prepareVisualMockDeviceLinkContext(): Promise<DeviceLinkContextValue> {
+ preparedContextPromise ??= loadVisualRealDataSnapshot().then(() => {
+ seedVisualMockStore();
+ return createVisualMockDeviceLinkContext();
+ });
+ return preparedContextPromise;
+}
+
export function createVisualMockDeviceLinkContext(): DeviceLinkContextValue {
const realData = realDataSnapshot;
+ const awaitingRealData = MOBILE_VISUAL_MOCK_REALDATA_URL && !didWarnRealDataLoad;
const deviceId = realData?.device.deviceId
- ?? (MOBILE_VISUAL_MOCK_REALDATA_URL ? VISUAL_MOCK_REALDATA_DEVICE_ID : VISUAL_MOCK_DEVICE_ID);
+ ?? (awaitingRealData ? VISUAL_MOCK_REALDATA_DEVICE_ID : VISUAL_MOCK_DEVICE_ID);
const deviceName = realData?.device.name
- ?? (MOBILE_VISUAL_MOCK_REALDATA_URL ? VISUAL_MOCK_REALDATA_DEVICE_NAME : VISUAL_MOCK_DEVICE_NAME);
+ ?? (awaitingRealData ? VISUAL_MOCK_REALDATA_DEVICE_NAME : VISUAL_MOCK_DEVICE_NAME);
return {
status: 'online',
recoveringDeviceIds: new Set(),
@@ -198,6 +214,23 @@ async function visualMockInvoke<T = unknown>(
args: unknown[] = [],
): Promise<T> {
const realData = await loadVisualRealDataSnapshot();
+ if (channel === 'local-db:task-tags:execute') {
+ const request = args[0] as TaskTagRequest;
+ if (request.action !== 'list' && request.action !== 'get') {
+ throw new Error('Task tag mutations are not implemented in visual mock');
+ }
+ const sessions = realData?.sessions ?? visualMockSessions();
+ const tags = [...new Map(sessions.flatMap((session) => session.tags ?? [])
+ .map((tag) => [tag.id, tag])).values()];
+ return {
+ tags,
+ supportedColors: [...TASK_TAG_COLORS],
+ sessions: request.action === 'get'
+ ? sessions.filter((session) => request.sessionIds.includes(session.id))
+ .map((session) => ({ sessionId: session.id, tags: session.tags ?? [] }))
+ : [],
+ } satisfies TaskTagResult as T;
+ }
if (realData) {
switch (channel) {
case 'local-db:sessions:list':
@@ -319,11 +352,24 @@ async function loadVisualRealDataSnapshot(): Promise<VisualRealDataSnapshot | nu
if (!MOBILE_VISUAL_MOCK_REALDATA_URL) return null;
if (realDataSnapshot) return realDataSnapshot;
if (!realDataLoadPromise) {
- realDataLoadPromise = fetch(MOBILE_VISUAL_MOCK_REALDATA_URL, { cache: 'no-store' })
- .then(async (response) => {
- if (!response.ok) throw new Error(`HTTP ${response.status}`);
- return normalizeRealDataSnapshot(await response.json());
- })
+ const controller = new AbortController();
+ let timer: ReturnType<typeof setTimeout>;
+ const timeout = new Promise<never>((_, reject) => {
+ timer = setTimeout(() => {
+ reject(new Error('Visual snapshot load timed out'));
+ controller.abort();
+ }, VISUAL_REALDATA_TIMEOUT_MS);
+ });
+ // Bound both fetch and body reading, even if the transport ignores abort.
+ // Publish only the race winner so late responses cannot replace the fallback.
+ const request = (async () => {
+ const response = await fetch(MOBILE_VISUAL_MOCK_REALDATA_URL, {
+ cache: 'no-store', signal: controller.signal,
+ });
+ if (!response.ok) throw new Error(`HTTP ${response.status}`);
+ return normalizeRealDataSnapshot(await response.json());
+ })();
+ realDataLoadPromise = Promise.race([request, timeout])
.then((snapshot) => {
realDataSnapshot = snapshot;
return snapshot;
@@ -334,7 +380,8 @@ async function loadVisualRealDataSnapshot(): Promise<VisualRealDataSnapshot | nu
console.warn('[visualMock] failed to load real data snapshot', error);
}
return null;
- });
+ })
+ .finally(() => clearTimeout(timer));
}
return realDataLoadPromise;
}
diff --git a/apps/mobile/src/device-link/DeviceLinkContext.tsx b/apps/mobile/src/device-link/DeviceLinkContext.tsx
index 52bedaa4bf..840f377def 100644
--- a/apps/mobile/src/device-link/DeviceLinkContext.tsx
+++ b/apps/mobile/src/device-link/DeviceLinkContext.tsx
@@ -157,7 +157,7 @@ import {
import { createOfflineMirrorWipeQueue } from '@/device-link/offlineMirrorWipeQueue';
import { hasMoreOlderMessages } from '@/session/messagePaging';
import type { InputProjection, PendingInteraction, RemoteMessage } from '@/session/types';
-import { createVisualMockDeviceLinkContext, seedVisualMockStore } from '@/debug/visualMock';
+import { prepareVisualMockDeviceLinkContext } from '@/debug/visualMock';
export interface DeviceLinkContextValue {
status: DeviceLinkStatus;
@@ -1601,10 +1601,15 @@ export function DeviceLinkProvider({ children }: { children: ReactNode }) {
}
function VisualMockDeviceLinkProvider({ children }: { children: ReactNode }) {
+ const [value, setValue] = useState<DeviceLinkContextValue | null>(null);
useEffect(() => {
- seedVisualMockStore();
+ let mounted = true;
+ void prepareVisualMockDeviceLinkContext().then((context) => {
+ if (mounted) setValue(context);
+ });
+ return () => { mounted = false; };
}, []);
- const value = useMemo(() => createVisualMockDeviceLinkContext(), []);
+ if (!value) return null;
return <DeviceLinkContext.Provider value={value}>{children}</DeviceLinkContext.Provider>;
}
diff --git a/apps/mobile/src/i18n/dateFormatters.ts b/apps/mobile/src/i18n/dateFormatters.ts
new file mode 100644
index 0000000000..fa4b7d8a17
--- /dev/null
+++ b/apps/mobile/src/i18n/dateFormatters.ts
@@ -0,0 +1,29 @@
+// DateTimeFormat construction is expensive on large history lists. Retain only
+// the current locale; never cache formatted dates (relative dates keep advancing).
+let locale: string | undefined;
+let dateFormatter: Intl.DateTimeFormat | undefined;
+let timeFormatter: Intl.DateTimeFormat | undefined;
+
+export function clearPresentationDateFormatters(): void {
+ locale = undefined;
+ dateFormatter = undefined;
+ timeFormatter = undefined;
+}
+
+function selectLocale(next: string): void {
+ if (locale === next) return;
+ clearPresentationDateFormatters();
+ locale = next;
+}
+
+export function formatPresentationDate(date: Date, language: string): string {
+ selectLocale(language);
+ dateFormatter ??= new Intl.DateTimeFormat(language);
+ return dateFormatter.format(date);
+}
+
+export function formatPresentationTime(date: Date, language: string): string {
+ selectLocale(language);
+ timeFormatter ??= new Intl.DateTimeFormat(language, { hour: '2-digit', minute: '2-digit' });
+ return timeFormatter.format(date);
+}
diff --git a/apps/mobile/src/i18n/presentationLocalizer.ts b/apps/mobile/src/i18n/presentationLocalizer.ts
index 06d6649c5b..069431ca77 100644
--- a/apps/mobile/src/i18n/presentationLocalizer.ts
+++ b/apps/mobile/src/i18n/presentationLocalizer.ts
@@ -1,4 +1,5 @@
import { i18n } from '@/i18n';
+import { formatPresentationDate, formatPresentationTime } from './dateFormatters';
import type {
PresentationLocalizer,
PresentationTranslator,
@@ -9,9 +10,6 @@ export const mobilePresentationTranslate: PresentationTranslator = (key, fallbac
export const mobilePresentationLocalizer: PresentationLocalizer = {
translate: mobilePresentationTranslate,
- formatDate: (date) => new Intl.DateTimeFormat(i18n.resolvedLanguage || i18n.language).format(date),
- formatTime: (date) => new Intl.DateTimeFormat(i18n.resolvedLanguage || i18n.language, {
- hour: '2-digit',
- minute: '2-digit',
- }).format(date),
+ formatDate: (date) => formatPresentationDate(date, i18n.resolvedLanguage || i18n.language),
+ formatTime: (date) => formatPresentationTime(date, i18n.resolvedLanguage || i18n.language),
};
diff --git a/apps/mobile/src/i18n/useLocale.tsx b/apps/mobile/src/i18n/useLocale.tsx
index 619602d9ea..e32cf5a7c1 100644
--- a/apps/mobile/src/i18n/useLocale.tsx
+++ b/apps/mobile/src/i18n/useLocale.tsx
@@ -21,8 +21,11 @@ import {
useState,
type ReactNode,
} from 'react';
+import { AppState } from 'react-native';
+import { clearSessionListCollator } from '@cindy/maker-shared/session-list';
import { setManualLocaleOverride } from './appLanguage';
+import { clearPresentationDateFormatters } from './dateFormatters';
import { i18n, detectSystemLocale, type LocalePreference, type SupportedLocale } from './index';
import {
readLanguagePreference,
@@ -53,6 +56,16 @@ function applyLocale(pref: LocalePreference): SupportedLocale {
}
export function LocaleProvider({ children }: { children: ReactNode }) {
+ useEffect(() => {
+ // System timezone/preferences may have changed while the app was backgrounded.
+ const subscription = AppState.addEventListener('change', (state) => {
+ if (state === 'active') {
+ clearPresentationDateFormatters();
+ clearSessionListCollator();
+ }
+ });
+ return () => subscription.remove();
+ }, []);
const [locale, setLocaleState] = useState<LocalePreference>('system');
const [effectiveLocale, setEffectiveLocale] = useState<SupportedLocale>(detectSystemLocale);
// 用户已手动选择过语言时置位:挂载期的异步读回不得覆盖更晚的手动选择。
diff --git a/apps/mobile/src/session/HomeSurface.tsx b/apps/mobile/src/session/HomeSurface.tsx
index 9f612a805d..2fa46da401 100644
--- a/apps/mobile/src/session/HomeSurface.tsx
+++ b/apps/mobile/src/session/HomeSurface.tsx
@@ -1,4 +1,5 @@
import { usePublishHomeScheduleUnread } from './HomeUnreadContext';
+import { MountOnFirstOpen } from './MountOnFirstOpen';
import { getMobileAuthOwner, isMobileAuthOwnerCurrent } from '@/auth/authOwnerGeneration';
import type { HomeMode } from './homeViewPreferenceStore';
import { TaskTagDots } from '@/session/TaskTags';
@@ -237,7 +238,7 @@ import {
useRemoteHomeStatusVersion,
useRemoteMessageVersion,
useRemoteSessionMessagePreview,
- useRemoteSessions,
+ useRemoteHomeSessions,
useSessionRunning,
} from '@/session/remoteSessionStore';
import { mapContentEqual } from '@/utils/valueEquality';
@@ -392,6 +393,11 @@ export interface MobileHomeProps {
newSessionActionRef?: MutableRefObject<(() => void) | null>;
}
const ActiveHomeSession = createContext<string | undefined>(undefined);
+/** Nested automation rows share their owning list's scroll invalidation. */
+export const HomeListViewportContext = createContext<{
+ scrollY: SharedValue<number>;
+ viewportHeight: number;
+} | null>(null);
export function MobileHome(props: MobileHomeProps) {
const screenFocused = useIsFocused();
@@ -459,7 +465,7 @@ function HomeScreenContent({ active = true, onModeChange, width, onDismiss, newS
unsubscribe,
} = useDeviceLink();
const revokedDevices = useRevokedDevices();
- const sessions = useRemoteSessions();
+ const sessions = useRemoteHomeSessions();
const syncInFlightRef = useRef<Promise<void> | null>(null);
const syncQueuedRef = useRef<{ visible?: boolean } | null>(null);
const loadHomeRef = useRef<(options?: { visible?: boolean }) => Promise<void>>(async () => undefined);
@@ -593,6 +599,7 @@ function HomeScreenContent({ active = true, onModeChange, width, onDismiss, newS
const listContentHeight = useRef(0);
const listViewportHeight = useRef(0);
const homeScrollY = useSharedValue(initialScrollOffset.current);
+ const childViewport = useMemo(() => ({ scrollY: homeScrollY, viewportHeight: screenHeight }), [homeScrollY, screenHeight]);
const [dialogueShowAll, setDialogueShowAll] = useRetainedHomeState(viewSession, 'dialogueShowAll', false);
const [priorityHoldEpoch, setPriorityHoldEpoch] = useState(0);
// deviceId of the revoked-access device whose explanation tip is open (null = closed).
@@ -1833,6 +1840,9 @@ function HomeScreenContent({ active = true, onModeChange, width, onDismiss, newS
() => collectHomePriorityContext(homePriorityItems, runningSessionIds, homeViewedPriorityHold),
[homePriorityItems, priorityHoldEpoch, runningSessionIds],
);
+ const priorityContextRef = useRef(priorityContext);
+ priorityContextRef.current = priorityContext;
+ const sortPriorityContext = sortBy === 'priority' ? priorityContext : undefined;
useEffect(() => {
if (!leftHomeForSessionRef.current) return;
// 首页留在导航栈中时仍会收到详情页任务的运行 / 等待状态更新。同步推进 hold,
@@ -1843,14 +1853,22 @@ function HomeScreenContent({ active = true, onModeChange, width, onDismiss, newS
setPriorityHoldEpoch((epoch) => epoch + 1);
}, [priorityContext]);
const selectedHostOrder = selectedDeviceId ? hostProjectOrders.get(selectedDeviceId) : undefined;
- const hostManualProjectOrder = selectedDeviceId && selectedHostOrder
- ? controllerKeysFromHost(selectedDeviceId, selectedHostOrder)
- : [];
- const displayed = resolveDisplayedProjectOrder(
- resolveProjectOrderWriteScope(selectedDeviceId ? [selectedDeviceId] : 'all', 'local'),
- selectedHostOrder,
- { manualProjectOrder, projectOrder },
- hostManualProjectOrder,
+ const hostManualProjectOrder = useMemo(
+ () => selectedDeviceId && selectedHostOrder
+ ? controllerKeysFromHost(selectedDeviceId, selectedHostOrder)
+ : [],
+ [selectedDeviceId, selectedHostOrder],
+ );
+ // The resolver copies the order array. Resolve only when its inputs change:
+ // a new array here invalidates every section even on a menu/focus update.
+ const displayed = useMemo(
+ () => resolveDisplayedProjectOrder(
+ resolveProjectOrderWriteScope(selectedDeviceId ? [selectedDeviceId] : 'all', 'local'),
+ selectedHostOrder,
+ { manualProjectOrder, projectOrder },
+ hostManualProjectOrder,
+ ),
+ [selectedDeviceId, selectedHostOrder, manualProjectOrder, projectOrder, hostManualProjectOrder],
);
const displayedProjectOrder = displayed.projectOrder;
const displayedManualProjectOrder = displayed.manualProjectOrder;
@@ -1863,11 +1881,11 @@ function HomeScreenContent({ active = true, onModeChange, width, onDismiss, newS
dialogueTitle: t('devices.list.menu.dialogueFolder'),
groupDialogue,
manualProjectOrder: displayedManualProjectOrder,
- priorityContext,
+ priorityContext: sortPriorityContext,
projectOrder: displayedProjectOrder,
sortBy,
}),
- [displayedManualProjectOrder, displayedProjectOrder, groupByProject, groupDialogue, sharedGroup.home, pinnedCollapsed, priorityContext, sortBy, t],
+ [displayedManualProjectOrder, displayedProjectOrder, groupByProject, groupDialogue, sharedGroup.home, pinnedCollapsed, sortPriorityContext, sortBy, t],
);
const sections = useMemo(() => {
if (!shouldReplaceListWithSearchResults(searchQuery, indexedSearch.status)) return homeSections;
@@ -2044,8 +2062,8 @@ function HomeScreenContent({ active = true, onModeChange, width, onDismiss, newS
const openSession = useCallback((item: RemoteSessionListItem) => {
// 有行处于滑开状态时,点击(本行或他行)只负责收起,不进会话(iOS 列表滑动操作惯例)。
if (swipeRegistry.closeOpenRow()) return;
- holdViewedPriorityRank(homeViewedPriorityHold, item.session.id, priorityContext);
- advanceViewedPriorityHold(homeViewedPriorityHold, item.session.id, priorityContext, Date.now());
+ holdViewedPriorityRank(homeViewedPriorityHold, item.session.id, priorityContextRef.current);
+ advanceViewedPriorityHold(homeViewedPriorityHold, item.session.id, priorityContextRef.current, Date.now());
leftHomeForSessionRef.current = true;
setPriorityHoldEpoch((epoch) => epoch + 1);
if (navigationHost.current.onSelectSession) {
@@ -2074,7 +2092,7 @@ function HomeScreenContent({ active = true, onModeChange, width, onDismiss, newS
} as const;
rememberTask(href);
guardedPush(href);
- }, [guardedPush, priorityContext, rememberTask, swipeRegistry, t]);
+ }, [guardedPush, rememberTask, swipeRegistry, t]);
const openNewSession = useCallback((project?: MobileHomeProjectGroup, suggestion?: RemoteTaskSuggestionId, explicitDeviceId?: string, origin?: ComposerMorphOrigin) => {
const deviceId = project?.deviceId ?? explicitDeviceId ?? home.primaryDevice?.deviceId;
@@ -2607,6 +2625,7 @@ function HomeScreenContent({ active = true, onModeChange, width, onDismiss, newS
? nativeHeaderHeight + (headerHeight ?? 0)
: (headerHeight ?? edgePadding.paddingTop + HOME_HEADER_MIN_HEIGHT);
const homeListNode = (
+ <HomeListViewportContext.Provider value={childViewport}>
<ListDisclosureScope controller={disclosure.controller}>
<SectionList
ref={attachHomeList}
@@ -2684,8 +2703,10 @@ function HomeScreenContent({ active = true, onModeChange, width, onDismiss, newS
</DisclosureItem> : null}
style={styles.homeList}
keyExtractor={(item) => item.key}
- initialNumToRender={HOME_LIST_INITIAL_RENDER_COUNT}
- maxToRenderPerBatch={HOME_LIST_RENDER_BATCH_SIZE}
+ // A grouped row contains its preview children. Twelve such rows can
+ // mount dozens of offscreen tasks in one JS turn on Android.
+ initialNumToRender={Platform.OS === 'android' && groupByProject ? 4 : HOME_LIST_INITIAL_RENDER_COUNT}
+ maxToRenderPerBatch={Platform.OS === 'android' && groupByProject ? 2 : HOME_LIST_RENDER_BATCH_SIZE}
updateCellsBatchingPeriod={32}
windowSize={HOME_LIST_WINDOW_SIZE}
refreshControl={
@@ -2799,6 +2820,7 @@ function HomeScreenContent({ active = true, onModeChange, width, onDismiss, newS
renderItem={renderHomeRow}
/>
</ListDisclosureScope>
+ </HomeListViewportContext.Provider>
);
const homeListOverlays = (<>
@@ -2987,15 +3009,15 @@ function HomeScreenContent({ active = true, onModeChange, width, onDismiss, newS
</ResidentHomeList>
) : <>{homeListNode}{homeListOverlays}</>}
- <RevokedAccessTip
+ <MountOnFirstOpen open={revokedTipDeviceName != null}>{() => <RevokedAccessTip
deviceName={revokedTipDeviceName}
retrying={revokedTipDeviceId !== null && retryingDeviceIds.has(revokedTipDeviceId)}
onClose={() => setRevokedTipDeviceId(null)}
onRetry={() => {
if (revokedTipDeviceId) void retryRevokedDevice(revokedTipDeviceId);
}}
- />
- <DeviceMenuModal
+ />}</MountOnFirstOpen>
+ <MountOnFirstOpen open={deviceMenuOpen}>{() => <DeviceMenuModal
collections={remoteHomeCollections}
filters={home.deviceFilters}
onClose={() => setDeviceMenuOpen(false)}
@@ -3030,8 +3052,8 @@ function HomeScreenContent({ active = true, onModeChange, width, onDismiss, newS
}}
topOffset={chromeHeight}
visible={deviceMenuOpen}
- />
- <HomeChromeDrawer
+ />}</MountOnFirstOpen>
+ <MountOnFirstOpen open={chromeMenuOpen}>{() => <HomeChromeDrawer
mode="tasks"
onModeChange={onModeChange ? (next) => {
pendingMenuActionRef.current = () => onModeChange(next);
@@ -3077,8 +3099,8 @@ function HomeScreenContent({ active = true, onModeChange, width, onDismiss, newS
onLogout={() => void logout()}
open={chromeMenuOpen}
user={user}
- />
- <AccountSwitcherSheet
+ />}</MountOnFirstOpen>
+ <MountOnFirstOpen open={accountSwitcherOpen}>{() => <AccountSwitcherSheet
hasRunningTasks={runningSessionIds.size > 0}
onAddAccount={() => {
pendingAccountSwitcherActionRef.current = () => {
@@ -3094,8 +3116,8 @@ function HomeScreenContent({ active = true, onModeChange, width, onDismiss, newS
action?.();
}}
visible={accountSwitcherOpen}
- />
- <ConversationSearchFilterSheet
+ />}</MountOnFirstOpen>
+ <MountOnFirstOpen open={searchFilterOpen}>{() => <ConversationSearchFilterSheet
activeCount={indexedSearch.activeFilterCount}
agentKind={indexedSearch.agentFilter}
lastActivity={indexedSearch.lastActivityFilter}
@@ -3113,8 +3135,8 @@ function HomeScreenContent({ active = true, onModeChange, width, onDismiss, newS
status={indexedSearch.statusFilter}
topOffset={chromeHeight}
visible={searchFilterOpen}
- />
- <HomeDisplaySettingsModal
+ />}</MountOnFirstOpen>
+ <MountOnFirstOpen open={displaySettingsOpen}>{() => <HomeDisplaySettingsModal
groupByProject={groupByProject}
groupDialogue={groupDialogue}
onChangeView={applyDisplayView}
@@ -3124,8 +3146,8 @@ function HomeScreenContent({ active = true, onModeChange, width, onDismiss, newS
statusFilter={statusFilter}
topOffset={chromeHeight}
visible={displaySettingsOpen}
- />
- <SessionOptionsPresenter
+ />}</MountOnFirstOpen>
+ <MountOnFirstOpen open={actionSheetSession !== null}>{() => <SessionOptionsPresenter
session={actionSheetSession}
onAction={handleSessionSheetAction}
onClose={() => setActionSheetSession(null)}
@@ -3133,8 +3155,8 @@ function HomeScreenContent({ active = true, onModeChange, width, onDismiss, newS
pinnedAt={actionSheetSession?.pinnedAt}
status={actionSheetSession?.status}
visible={actionSheetSession !== null}
- />
- <RenameSessionModal
+ />}</MountOnFirstOpen>
+ <MountOnFirstOpen open={renameSessionTarget !== null}>{() => <RenameSessionModal
draft={renameSessionDraft}
onCancel={closeRenameSession}
onChangeDraft={setRenameSessionDraft}
@@ -3142,7 +3164,7 @@ function HomeScreenContent({ active = true, onModeChange, width, onDismiss, newS
// 乐观提交:确认即关弹窗,不存在挂起中的保存态。
saving={false}
visible={renameSessionTarget !== null}
- />
+ />}</MountOnFirstOpen>
</View>
);
}
@@ -4396,9 +4418,35 @@ function AutomationGroupChildren({
isSessionRunning: (sessionId) => remoteSessionStore.isSessionRunning(sessionId),
});
const hasViewAllRow = hiddenCount > 0 && !!onOpenGroup;
+ const viewport = useContext(HomeListViewportContext);
+ const childrenRef = useAnimatedRef<View>();
+ const layoutRevision = useSharedValue(0);
+ const headerHeight = useSharedValue(0);
+ const [windowAnchor, setWindowAnchor] = useState(-1);
+ const childOffsets = buildHomeProjectChildOffsets(visibleItems.map(estimateHomeSessionRowHeight));
+ const windowingEnabled = shouldWindowHomeProjectChildren({
+ collapsed: false, itemCount: visibleItems.length,
+ scrollTrackingAvailable: viewport !== null, threshold: PROJECT_CHILD_WINDOW_THRESHOLD,
+ });
+ const range = windowingEnabled
+ ? windowAnchor >= 0
+ ? resolveHomeProjectChildWindow({ anchor: windowAnchor, childOffsets,
+ overscan: PROJECT_CHILD_WINDOW_OVERSCAN, windowSize: PROJECT_CHILD_WINDOW_SIZE })
+ : { start: 0, end: 0, leadingSpacerHeight: 0, trailingSpacerHeight: childOffsets.at(-1) ?? 0 }
+ : { start: 0, end: visibleItems.length, leadingSpacerHeight: 0, trailingSpacerHeight: 0 };
return (
- <View style={styles.automationGroupChildren} testID={childrenTestID ?? `${testID}.automationGroupChildren`}>
- {visibleItems.map((child, index) => {
+ <Reanimated.View ref={childrenRef} collapsable={false}
+ onLayout={() => { if (windowingEnabled) layoutRevision.value += 1; }}
+ style={styles.automationGroupChildren} testID={childrenTestID ?? `${testID}.automationGroupChildren`}>
+ {windowingEnabled && viewport ? <HomeProjectWindowAnchorTracker
+ childOffsets={childOffsets} onAnchorChange={setWindowAnchor}
+ projectHeaderHeight={headerHeight} projectLayoutRevision={layoutRevision}
+ projectRef={childrenRef} scrollY={viewport.scrollY} viewportHeight={viewport.viewportHeight}
+ /> : null}
+ {range.leadingSpacerHeight > 0 ? <View pointerEvents="none" style={{ height: range.leadingSpacerHeight }} /> : null}
+ {visibleItems.slice(range.start, range.end).map((child, renderedIndex) => {
+ const index = range.start + renderedIndex;
+ const key = windowingEnabled ? `${group.key}:window:${renderedIndex}` : child.session.id;
const row = (
<HomeSessionRow
deepIndented
@@ -4409,10 +4457,10 @@ function AutomationGroupChildren({
titleTestIDPrefix={titleTestIDPrefix}
/>
);
- if (!swipe) return <Fragment key={child.session.id}>{row}</Fragment>;
+ if (!swipe) return <Fragment key={key}>{row}</Fragment>;
return (
<SwipeableSessionRow
- key={child.session.id}
+ key={key}
onArchive={swipe.onArchive}
onShowOptions={swipe.onShowOptions}
onTogglePin={swipe.onTogglePin}
@@ -4424,6 +4472,7 @@ function AutomationGroupChildren({
</SwipeableSessionRow>
);
})}
+ {range.trailingSpacerHeight > 0 ? <View pointerEvents="none" style={{ height: range.trailingSpacerHeight }} /> : null}
{hasViewAllRow ? (
<Pressable
accessibilityLabel={t('devices.list.viewAllRuns', { count: group.sessionCount })}
@@ -4442,7 +4491,7 @@ function AutomationGroupChildren({
<ChevronRight color={colors.textTertiary} size={iconSize.action} strokeWidth={iconStroke.regular} />
</Pressable>
) : null}
- </View>
+ </Reanimated.View>
);
}
diff --git a/apps/mobile/src/session/HomeUnreadContext.tsx b/apps/mobile/src/session/HomeUnreadContext.tsx
index d371b30f3f..35ca882f84 100644
--- a/apps/mobile/src/session/HomeUnreadContext.tsx
+++ b/apps/mobile/src/session/HomeUnreadContext.tsx
@@ -1,8 +1,8 @@
-import { createContext, useContext, useState, useSyncExternalStore, type ReactNode } from 'react';
+import { createContext, useContext, useMemo, useState, useSyncExternalStore, type ReactNode } from 'react';
import { useIsFocused } from 'expo-router';
import { useAuth } from '@/auth/AuthContext';
import { isRemoteResourceUnread, remoteResourceCacheRevision, subscribeRemoteResourceCache } from '@/device-link/remoteResourceCache';
-import { remoteSessionStore } from './remoteSessionStore';
+import { RemoteSessionStoreSubscriptionGate, remoteSessionStore, useRemoteHomeSessions, useRemoteHomeStatusVersion } from './remoteSessionStore';
import { resolveMobileSessionRightStatus } from './sessionRightStatus';
import { useTeammateRoster } from './useTeammateRoster';
import { useBotGroupRoster } from './useBotGroupRoster';
@@ -17,15 +17,24 @@ const RosterContext = createContext<{
/** The same mirrors as the rows, including while the other home section is active. */
export function HomeUnreadProvider({ children }: { children: ReactNode }) {
+ const focused = useIsFocused();
+ return <RemoteSessionStoreSubscriptionGate enabled={focused}>
+ <HomeUnreadContent>{children}</HomeUnreadContent>
+ </RemoteSessionStoreSubscriptionGate>;
+}
+
+function HomeUnreadContent({ children }: { children: ReactNode }) {
const { user } = useAuth();
const [scheduleUnread, setScheduleUnread] = useState<ReadonlySet<string>>(new Set());
const focused = useIsFocused();
const roster = useTeammateRoster(focused);
const groups = useBotGroupRoster(roster.groupTargets, focused);
useSyncExternalStore(subscribeRemoteResourceCache, remoteResourceCacheRevision);
- const tasks = useSyncExternalStore(remoteSessionStore.subscribe, () => {
+ const sessions = useRemoteHomeSessions();
+ const homeStatusVersion = useRemoteHomeStatusVersion();
+ const tasks = useMemo(() => {
let count = 0;
- for (const session of remoteSessionStore.getSessions()) {
+ for (const session of sessions) {
if (session.status !== 'active' || session.orcaRole === 'worker' || session.source === 'bot' || session.source === 'scheduler' || session.source === 'learn'
|| session.title?.startsWith('[Schedule] ')) continue;
const activity = remoteSessionStore.getSessionLiveActivity(session.id);
@@ -37,7 +46,7 @@ export function HomeUnreadProvider({ children }: { children: ReactNode }) {
if (status === 'done' || status === 'awaiting' || status === 'error') count += 1;
}
return count;
- });
+ }, [sessions, homeStatusVersion, scheduleUnread]);
const teammates = [...roster.items, ...groups.items].filter(row =>
isRemoteResourceUnread(user?.id ?? '', row.host.deviceId, row.item.ref.id, row.item.display.lastReplyAt)).length;
return <ScheduleUnreadContext.Provider value={setScheduleUnread}><RosterContext.Provider value={{ roster, groups }}><CountsContext.Provider value={{ tasks, teammates }}>{children}</CountsContext.Provider></RosterContext.Provider></ScheduleUnreadContext.Provider>;
diff --git a/apps/mobile/src/session/MountOnFirstOpen.tsx b/apps/mobile/src/session/MountOnFirstOpen.tsx
new file mode 100644
index 0000000000..047f7f9f0c
--- /dev/null
+++ b/apps/mobile/src/session/MountOnFirstOpen.tsx
@@ -0,0 +1,10 @@
+import { useState, type ReactNode } from 'react';
+
+/** Closed sheets need neither their hooks nor eagerly constructed JSX on entry.
+ * Once opened, retain them so draft state and the existing dismissal lifecycle
+ * continue to belong to the sheet (including rapid close/reopen). */
+export function MountOnFirstOpen({ open, children }: { open: boolean; children: () => ReactNode }) {
+ const [opened, setOpened] = useState(open);
+ if (open && !opened) setOpened(true);
+ return open || opened ? children() : null;
+}
diff --git a/apps/mobile/src/session/homeSections.ts b/apps/mobile/src/session/homeSections.ts
index f9884cbb51..a25b3a0249 100644
--- a/apps/mobile/src/session/homeSections.ts
+++ b/apps/mobile/src/session/homeSections.ts
@@ -1,4 +1,5 @@
import { i18n } from '@/i18n';
+import { compareSessionListStrings } from '@cindy/maker-shared/session-list';
import type { MobileHomePresentation, MobileHomeProjectGroup } from './mobileHome';
import {
activityMsFromIso,
@@ -263,7 +264,7 @@ function sortSessionItems(
return items.slice().sort((a, b) => compareSessionItemsByPriority(a, b, ctx));
}
return items.slice().sort((a, b) =>
- b.lastActivityAt.localeCompare(a.lastActivityAt) || a.session.id.localeCompare(b.session.id));
+ compareSessionListStrings(b.lastActivityAt, a.lastActivityAt) || compareSessionListStrings(a.session.id, b.session.id));
}
function sortHomeRows(rows: HomeRow[], options: HomeSectionOptions): HomeRow[] {
@@ -278,7 +279,7 @@ function sortHomeRows(rows: HomeRow[], options: HomeSectionOptions): HomeRow[] {
projects.sort((a, b) =>
(rank.get(a.project.key) ?? Number.MAX_SAFE_INTEGER)
- (rank.get(b.project.key) ?? Number.MAX_SAFE_INTEGER)
- || a.key.localeCompare(b.key));
+ || compareSessionListStrings(a.key, b.key));
return [...projects, ...sortHomeRowsByTaskSort(rest, options)];
}
return sortHomeRowsByTaskSort(rows, options);
@@ -290,7 +291,7 @@ function sortHomeRowsByTaskSort(rows: HomeRow[], options: HomeSectionOptions): H
return rows.slice().sort((a, b) =>
homeRowPriorityRank(a, ctx) - homeRowPriorityRank(b, ctx)
|| homeRowPriorityRecencyMs(b, ctx) - homeRowPriorityRecencyMs(a, ctx)
- || a.key.localeCompare(b.key));
+ || compareSessionListStrings(a.key, b.key));
}
return rows.slice().sort(compareHomeRowsByActivityDesc);
}
@@ -303,11 +304,11 @@ function compareSessionItemsByPriority(
return sessionPriorityRank(a.session.id, ctx) - sessionPriorityRank(b.session.id, ctx)
|| sessionPriorityRecencyMs(b.session.id, activityMsFromIso(b.lastActivityAt), ctx)
- sessionPriorityRecencyMs(a.session.id, activityMsFromIso(a.lastActivityAt), ctx)
- || a.session.id.localeCompare(b.session.id);
+ || compareSessionListStrings(a.session.id, b.session.id);
}
function compareHomeRowsByActivityDesc(a: HomeRow, b: HomeRow): number {
- return homeRowActivity(b).localeCompare(homeRowActivity(a)) || a.key.localeCompare(b.key);
+ return compareSessionListStrings(homeRowActivity(b), homeRowActivity(a)) || compareSessionListStrings(a.key, b.key);
}
function homeRowActivity(row: HomeRow): string {
diff --git a/apps/mobile/src/session/mobileHome.ts b/apps/mobile/src/session/mobileHome.ts
index 607c18d2ee..a3bca2f520 100644
--- a/apps/mobile/src/session/mobileHome.ts
+++ b/apps/mobile/src/session/mobileHome.ts
@@ -2,7 +2,7 @@ import type { RemoteSession } from '@/session/types';
import { isSharedTaskPeer } from '@cindy/device-link';
import { i18n } from '@/i18n';
import { mobilePresentationLocalizer } from '@/i18n/presentationLocalizer';
-import { localizeRemoteSessionListItem } from '@/session/sessionList';
+import { createSessionListTranslator, localizeRemoteSessionListItem } from '@/session/sessionList';
import {
buildMobileHomePresentation as buildMobileHomePresentationShared,
sessionMatchesProjectDir,
@@ -16,6 +16,7 @@ export * from '@cindy/maker-shared/mobile-home';
export function buildMobileHomePresentation(options: MobileHomeOptions): MobileHomePresentation {
const now = options.now ?? Date.now();
+ const translate = createSessionListTranslator();
// Shared peers route individual tasks, not device scopes. Retain their task
// rows, but discard legacy selections of these synthetic device entries.
const selectedDeviceId = options.selectedDeviceId && isSharedTaskPeer(options.selectedDeviceId)
@@ -38,11 +39,11 @@ export function buildMobileHomePresentation(options: MobileHomeOptions): MobileH
const empty = localizedHomeEmpty(base.emptyKind, base.emptyNoDevice);
return {
...base,
- chats: base.chats.map((item) => localizeRemoteSessionListItem(item, now)),
+ chats: base.chats.map((item) => localizeRemoteSessionListItem(item, now, translate)),
deviceFilters,
emptyCopy: empty.copy,
emptyTitle: empty.title,
- pinned: base.pinned.map((item) => localizeRemoteSessionListItem(item, now)),
+ pinned: base.pinned.map((item) => localizeRemoteSessionListItem(item, now, translate)),
primaryDevice,
projects: base.projects.map((project) => {
const sourceDeviceName = (project.sessions[0]?.session as MobileHomeSessionLike | undefined)?.deviceLinkDeviceName
@@ -56,7 +57,7 @@ export function buildMobileHomePresentation(options: MobileHomeOptions): MobileH
return {
...project,
deviceName,
- sessions: project.sessions.map((item) => localizeRemoteSessionListItem(item, now)),
+ sessions: project.sessions.map((item) => localizeRemoteSessionListItem(item, now, translate)),
subtitle: [deviceName, workingDir].filter(Boolean).join(' · '),
title: project.kind === 'cindy-make'
? i18n.t('devices.presentation.home.cindyMake')
diff --git a/apps/mobile/src/session/pausableSubscriptions.ts b/apps/mobile/src/session/pausableSubscriptions.ts
new file mode 100644
index 0000000000..61f66fb6b0
--- /dev/null
+++ b/apps/mobile/src/session/pausableSubscriptions.ts
@@ -0,0 +1,33 @@
+type Subscribe = (notify: () => void) => () => void;
+
+/** A stable subscription boundary: covering a route must not itself render all
+ * its rows. Resume asks each subscriber to check its snapshot; React updates
+ * only consumers whose selected value actually changed. */
+export class PausableSubscriptions {
+ private entries = new Set<{ subscribe: Subscribe; notify: () => void; stop?: () => void }>();
+
+ constructor(public enabled: boolean) {}
+
+ setEnabled(enabled: boolean): void {
+ if (this.enabled === enabled) return;
+ this.enabled = enabled;
+ for (const entry of this.entries) {
+ if (enabled) {
+ entry.stop = entry.subscribe(entry.notify);
+ entry.notify();
+ } else {
+ entry.stop?.();
+ entry.stop = undefined;
+ }
+ }
+ }
+
+ subscribe(subscribe: Subscribe, notify: () => void): () => void {
+ const entry = { subscribe, notify, stop: this.enabled ? subscribe(notify) : undefined };
+ this.entries.add(entry);
+ return () => {
+ this.entries.delete(entry);
+ entry.stop?.();
+ };
+ }
+}
diff --git a/apps/mobile/src/session/remoteSessionStore.ts b/apps/mobile/src/session/remoteSessionStore.ts
index ece865d361..f3e8bfc78c 100644
--- a/apps/mobile/src/session/remoteSessionStore.ts
+++ b/apps/mobile/src/session/remoteSessionStore.ts
@@ -5,10 +5,12 @@ import {
useCallback,
useContext,
useEffect,
+ useLayoutEffect,
useRef,
useSyncExternalStore,
type ReactNode,
} from 'react';
+import { PausableSubscriptions } from './pausableSubscriptions';
import {
MAKER_EVENT_BATCH_CHANNEL,
SESSION_ACTIVITY_CHANNEL,
@@ -816,7 +818,7 @@ function deleteSessionLiveActivity(sessionId: string): boolean {
}
function sessionById(sessionId: string): RemoteSession | undefined {
- return mergedSessions.find((session) => session.id === sessionId);
+ return mergedSessionById.get(sessionId);
}
function retentionForSession(sessionId: string): SessionRetentionKind {
@@ -1241,6 +1243,28 @@ function applyMessageWriteRetention(sessionId: string): void {
}
let mergedSessions: RemoteSession[] = [];
+// Retention and live-row anchoring run for every message write. Looking up each
+// cached window in the full list makes bulk hydration approach cubic work.
+const mergedSessionById = new Map<string, RemoteSession>();
+// List-only projection. Detail consumers keep reading mergedSessions, including
+// live usage. Usage pushes must not rebuild Home's grouping/localization tree.
+let homeSessions: RemoteSession[] = [];
+const SESSION_USAGE_FIELDS = new Set(['totalMoney', 'totalCostUsd', 'totalTokenUsage']);
+
+function reconcileHomeSessions(): void {
+ const previous = new Map(homeSessions.map((session) => [session.id, session]));
+ const next = mergedSessions.map((session) => {
+ const projected = { ...session };
+ delete projected.totalMoney;
+ delete projected.totalCostUsd;
+ delete projected.totalTokenUsage;
+ const old = previous.get(session.id);
+ return old && remoteSessionEqual(old, projected) ? old : projected;
+ });
+ if (sameElementRefs(homeSessions, next)) return;
+ homeSessions = next;
+ bumpHomeStatusVersion();
+}
let messageVersion = 0;
let storeVersion = 0;
// A single remote snapshot often updates both the session shard and its
@@ -1258,7 +1282,7 @@ type LiveRowCreatedAtAnchor = {
function liveRowCreatedAtAnchor(sessionId: string): LiveRowCreatedAtAnchor {
const pendingHostAnchorIds = pendingHostAnchorLiveAssistantClientIds.get(sessionId);
- const session = mergedSessions.find((item) => item.id === sessionId);
+ const session = sessionById(sessionId);
const authoritativeMessages = (messages.get(sessionId) ?? []).filter((message) => {
const isPendingHostAnchor = pendingHostAnchorIds?.has(message.id) === true
|| pendingHostAnchorIds?.has(message.clientId) === true;
@@ -1287,12 +1311,12 @@ function liveRowCreatedAtAnchor(sessionId: string): LiveRowCreatedAtAnchor {
}
function latestUserSendAt(sessionId: string): string | undefined {
- return mergedSessions.find((item) => item.id === sessionId)?.userSendAt ?? undefined;
+ return sessionById(sessionId)?.userSendAt ?? undefined;
}
function authoritativeSessionDeviceId(sessionId: string): string | undefined {
if (!deviceList) return undefined;
- const session = mergedSessions.find((item) => item.id === sessionId);
+ const session = sessionById(sessionId);
const canonicalDeviceId = session?.canonicalDeviceId;
if (canonicalDeviceId && deviceList.some((device) => device.deviceId === canonicalDeviceId)) {
return canonicalDeviceId;
@@ -1501,6 +1525,9 @@ function recomputeSessions(): void {
// 数组级同样调和:全部元素引用与序都未变时保留旧数组引用——useRemoteSessions 的
// useSyncExternalStore 快照经 Object.is 即可短路,消费屏对无关 emit 零重渲染。
mergedSessions = sameElementRefs(mergedSessions, next) ? mergedSessions : next;
+ mergedSessionById.clear();
+ for (const session of mergedSessions) mergedSessionById.set(session.id, session);
+ reconcileHomeSessions();
let liveRowsReanchored = false;
for (const session of mergedSessions) {
bindPendingHostAnchorSendAt(session.id, session.userSendAt);
@@ -3339,6 +3366,20 @@ export const remoteSessionStore = {
);
if (remoteSessionEqual(shard.sessions[idx], patched)) return;
shard.sessions = shard.sessions.map((s) => (s.id === sessionId ? patched : s));
+ if (Object.keys(patch).every((key) => SESSION_USAGE_FIELDS.has(key))) {
+ // Usage cannot change routing, retention, previews, grouping or unread.
+ // Preserve the canonical shard winner and notify detail selectors only.
+ if (sessionDeviceIndex.get(sessionId) === deviceId) {
+ mergedSessions = mergedSessions.map((session) => {
+ if (session.id !== sessionId) return session;
+ const updated = { ...session, ...patch };
+ mergedSessionById.set(sessionId, updated);
+ return updated;
+ });
+ }
+ emit();
+ return;
+ }
shouldReseedAfterPatch = wasPinned && unpinned;
}
recomputeSessions();
@@ -5083,6 +5124,11 @@ export const remoteSessionStore = {
reseedHandlers.clear();
pendingTitlePreview.clear();
mergedSessions = [];
+ mergedSessionById.clear();
+ if (homeSessions.length > 0) {
+ homeSessions = [];
+ bumpHomeStatusVersion();
+ }
deviceList = null;
bumpMessageVersion();
emit();
@@ -5118,6 +5164,10 @@ export const remoteSessionStore = {
return mergedSessions;
},
+ getHomeSessions(): RemoteSession[] {
+ return homeSessions;
+ },
+
getMessages(sessionId: string): RemoteMessage[] {
return messages.get(sessionId) ?? emptyMessages;
},
@@ -5677,8 +5727,7 @@ function readNumber(value: unknown, key: string): number | null {
return typeof raw === 'number' && Number.isFinite(raw) ? raw : null;
}
-const RemoteSessionStoreSubscriptionEnabledContext = createContext(true);
-const INACTIVE_REMOTE_SESSION_STORE_SUBSCRIBE = () => () => undefined;
+const RemoteSessionStoreSubscriptionContext = createContext<PausableSubscriptions | null>(null);
/**
* Keep a mounted route's remote-session projection stable while it is covered by another screen.
@@ -5693,9 +5742,16 @@ export function RemoteSessionStoreSubscriptionGate({
children: ReactNode;
enabled: boolean;
}) {
+ const gateRef = useRef<PausableSubscriptions | null>(null);
+ if (!gateRef.current) gateRef.current = new PausableSubscriptions(enabled);
+ const gate = gateRef.current;
+ useLayoutEffect(() => {
+ gate.setEnabled(enabled);
+ return () => gate.setEnabled(false);
+ }, [gate, enabled]);
return createElement(
- RemoteSessionStoreSubscriptionEnabledContext.Provider,
- { value: enabled },
+ RemoteSessionStoreSubscriptionContext.Provider,
+ { value: gate },
children,
);
}
@@ -5705,19 +5761,23 @@ function usePausableRemoteSessionStoreSnapshot<T>(
getSnapshot: () => T,
subscribe: (cb: () => void) => () => void = remoteSessionStore.subscribe,
): T {
- const enabled = useContext(RemoteSessionStoreSubscriptionEnabledContext);
+ const gate = useContext(RemoteSessionStoreSubscriptionContext);
const frozenSnapshotRef = useRef<{ identity: unknown; value: T } | null>(null);
const readSnapshot = useCallback(() => {
const frozen = frozenSnapshotRef.current;
- if (enabled || frozen === null || !Object.is(frozen.identity, identity)) {
+ if (!gate || gate.enabled || frozen === null || !Object.is(frozen.identity, identity)) {
const next = { identity, value: getSnapshot() };
frozenSnapshotRef.current = next;
return next.value;
}
return frozen.value;
- }, [enabled, getSnapshot, identity]);
+ }, [gate, getSnapshot, identity]);
+ const subscribeWhileActive = useCallback(
+ (notify: () => void) => gate ? gate.subscribe(subscribe, notify) : subscribe(notify),
+ [gate, subscribe],
+ );
return useSyncExternalStore(
- enabled ? subscribe : INACTIVE_REMOTE_SESSION_STORE_SUBSCRIBE,
+ subscribeWhileActive,
readSnapshot,
);
}
@@ -5726,6 +5786,13 @@ export function useRemoteSessions(): RemoteSession[] {
return usePausableRemoteSessionStoreSnapshot('sessions', remoteSessionStore.getSessions);
}
+/** Home rows/actions do not consume usage; session details must use useRemoteSessions. */
+export function useRemoteHomeSessions(): RemoteSession[] {
+ return usePausableRemoteSessionStoreSnapshot(
+ 'home-sessions', remoteSessionStore.getHomeSessions, remoteSessionStore.subscribeHomeStatus,
+ );
+}
+
/** Device identity can change without changing any session's reconciled reference. */
export function useRemoteDeviceIdentity() {
return usePausableRemoteSessionStoreSnapshot('device-identity', remoteSessionStore.getDeviceIdentity);
diff --git a/apps/mobile/src/session/sessionList.ts b/apps/mobile/src/session/sessionList.ts
index b6b15574d3..b3f6b4e7b3 100644
--- a/apps/mobile/src/session/sessionList.ts
+++ b/apps/mobile/src/session/sessionList.ts
@@ -1,4 +1,5 @@
import { i18n } from '@/i18n';
+import { formatPresentationDate } from '@/i18n/dateFormatters';
import { mobilePresentationLocalizer } from '@/i18n/presentationLocalizer';
import {
buildRemoteSessionCardPreview as buildRemoteSessionCardPreviewShared,
@@ -15,11 +16,28 @@ import {
export * from '@cindy/maker-shared/session-list';
+type ListTranslator = (key: string, values?: Record<string, string | number>) => string;
+
+/** Scoped to one synchronous list build: repeated status/count labels only run
+ * through i18next once, with no stale strings after locale/resource changes. */
+export function createSessionListTranslator(): ListTranslator {
+ const labels = new Map<string, string>();
+ return (key, values) => {
+ const cacheKey = JSON.stringify([key, values]);
+ const previous = labels.get(cacheKey);
+ if (previous !== undefined) return previous;
+ const label = i18n.t(key, values);
+ labels.set(cacheKey, label);
+ return label;
+ };
+}
+
export function buildRemoteSessionSections(
sessions: Parameters<typeof buildRemoteSessionSectionsShared>[0],
now = Date.now(),
options: RemoteSessionListOptions = {},
): RemoteSessionSection[] {
+ const translate = createSessionListTranslator();
return buildRemoteSessionSectionsShared(sessions, now, {
...options,
localizer: mobilePresentationLocalizer,
@@ -30,7 +48,7 @@ export function buildRemoteSessionSections(
: section.key === 'dialogue'
? i18n.t('devices.presentation.sessionList.section.dialogue')
: section.title,
- data: section.data.map((item) => localizeRemoteSessionListItem(item, now)),
+ data: section.data.map((item) => localizeRemoteSessionListItem(item, now, translate)),
}));
}
@@ -139,14 +157,15 @@ export function formatRemoteSessionSidebarTime(iso: string | undefined, now = Da
export function localizeRemoteSessionListItem(
item: RemoteSessionListItem,
now = Date.now(),
+ translate: ListTranslator = createSessionListTranslator(),
): RemoteSessionListItem {
- const collaboration = collaborationLabel(item.session.orcaRole);
+ const collaboration = collaborationLabel(item.session.orcaRole, translate);
const agent = item.session.agentKind === 'codex'
? 'Codex'
: item.session.agentKind === 'pi'
? 'Pi'
: 'Claude Code';
- const localizedItems = item.automationGroup?.items.map((member) => localizeRemoteSessionListItem(member, now));
+ const localizedItems = item.automationGroup?.items.map((member) => localizeRemoteSessionListItem(member, now, translate));
const localizedChildren = localizedItems?.map((member) => ({
sessionId: member.session.id,
title: member.title,
@@ -160,8 +179,8 @@ export function localizeRemoteSessionListItem(
const sessionCount = item.automationGroup?.sessionCount ?? 1;
const subtitle = isGroup
? [
- i18n.t('devices.presentation.sessionList.automation'),
- i18n.t('devices.presentation.sessionList.sessionCount', { count: sessionCount }),
+ translate('devices.presentation.sessionList.automation'),
+ translate('devices.presentation.sessionList.sessionCount', { count: sessionCount }),
item.worktreeLabel,
agent,
item.session.model,
@@ -171,22 +190,22 @@ export function localizeRemoteSessionListItem(
item.worktreeLabel,
agent,
item.session.model,
- isDialogue(item.session) ? i18n.t('devices.list.a11y.dialogue') : null,
+ isDialogue(item.session) ? translate('devices.list.a11y.dialogue') : null,
];
const detail = [
...(isGroup
- ? [i18n.t('devices.presentation.sessionList.sessionCount', { count: sessionCount })]
- : [sessionStatusLabel(item.session.status)]),
- relativeActivity(item.lastActivityAt, now),
- item.scheduleInfo?.running ? i18n.t('devices.presentation.sessionList.preview.automationRunning') : null,
+ ? [translate('devices.presentation.sessionList.sessionCount', { count: sessionCount })]
+ : [sessionStatusLabel(item.session.status, translate)]),
+ relativeActivity(item.lastActivityAt, now, translate),
+ item.scheduleInfo?.running ? translate('devices.presentation.sessionList.preview.automationRunning') : null,
item.scheduleInfo && item.scheduleInfo.unreadCount > 0
- ? i18n.t('devices.detail.badge.unread', { count: item.scheduleInfo.unreadCount })
+ ? translate('devices.detail.badge.unread', { count: item.scheduleInfo.unreadCount })
: null,
item.pendingInteractionCount > 0
- ? i18n.t('devices.detail.badge.waiting', { count: item.pendingInteractionCount })
+ ? translate('devices.detail.badge.waiting', { count: item.pendingInteractionCount })
: null,
!isGroup && typeof item.session._count?.messages === 'number'
- ? i18n.t('devices.presentation.sessionList.messageCount', { count: item.session._count.messages })
+ ? translate('devices.presentation.sessionList.messageCount', { count: item.session._count.messages })
: null,
].filter(Boolean).join(' · ');
return {
@@ -203,17 +222,17 @@ export function localizeRemoteSessionListItem(
};
}
-function sessionStatusLabel(status: string): string {
- if (status === 'active') return i18n.t('devices.detail.filter.active');
- if (status === 'archived') return i18n.t('devices.presentation.sessionList.status.archived');
- return i18n.t('devices.presentation.sessionList.status.deleted');
+function sessionStatusLabel(status: string, translate: ListTranslator): string {
+ if (status === 'active') return translate('devices.detail.filter.active');
+ if (status === 'archived') return translate('devices.presentation.sessionList.status.archived');
+ return translate('devices.presentation.sessionList.status.deleted');
}
-function collaborationLabel(role: string | null | undefined): string | null {
- if (role === 'lead') return i18n.t('session.presentation.collaboration.labelLead');
- if (role === 'worker') return i18n.t('session.presentation.collaboration.labelWorker');
+function collaborationLabel(role: string | null | undefined, translate: ListTranslator): string | null {
+ if (role === 'lead') return translate('session.presentation.collaboration.labelLead');
+ if (role === 'worker') return translate('session.presentation.collaboration.labelWorker');
return role?.trim()
- ? i18n.t('session.presentation.collaboration.labelRole', { role: role.trim() })
+ ? translate('session.presentation.collaboration.labelRole', { role: role.trim() })
: null;
}
@@ -221,17 +240,17 @@ function isDialogue(session: RemoteSessionListItem['session']): boolean {
return session.workspaceKind === 'dialogue' || !session.workingDir;
}
-function relativeActivity(iso: string, now: number): string {
+function relativeActivity(iso: string, now: number, translate: ListTranslator): string {
const ts = Date.parse(iso);
- if (!Number.isFinite(ts)) return i18n.t('devices.presentation.sessionList.time.unknown');
+ if (!Number.isFinite(ts)) return translate('devices.presentation.sessionList.time.unknown');
const diffMinutes = Math.max(0, Math.floor((now - ts) / 60_000));
- if (diffMinutes < 1) return i18n.t('devices.presentation.sessionList.time.justNow');
- if (diffMinutes < 60) return i18n.t('devices.presentation.sessionList.time.minutesAgo', { count: diffMinutes });
+ if (diffMinutes < 1) return translate('devices.presentation.sessionList.time.justNow');
+ if (diffMinutes < 60) return translate('devices.presentation.sessionList.time.minutesAgo', { count: diffMinutes });
const diffHours = Math.floor(diffMinutes / 60);
- if (diffHours < 24) return i18n.t('devices.presentation.sessionList.time.hoursAgo', { count: diffHours });
+ if (diffHours < 24) return translate('devices.presentation.sessionList.time.hoursAgo', { count: diffHours });
const diffDays = Math.floor(diffHours / 24);
- if (diffDays < 7) return i18n.t('devices.presentation.sessionList.time.daysAgo', { count: diffDays });
- return new Intl.DateTimeFormat(i18n.resolvedLanguage || i18n.language).format(new Date(ts));
+ if (diffDays < 7) return translate('devices.presentation.sessionList.time.daysAgo', { count: diffDays });
+ return formatPresentationDate(new Date(ts), i18n.resolvedLanguage || i18n.language);
}
function sessionListHint(statusFilter: RemoteSessionStatusFilter, searching: boolean): string {
diff --git a/docs/design-rules/design-inventory.md b/docs/design-rules/design-inventory.md
index fa8c3a36b2..1bc29ad521 100644
--- a/docs/design-rules/design-inventory.md
+++ b/docs/design-rules/design-inventory.md
@@ -54,14 +54,14 @@
| `mobile.account-deletion` | mobile | 账号注销 | app/account-deletion.tsx | AdaptiveWindow, AnchoredPullDownMenu, AndroidUpdateSheet, AppText, AuthContext, BlurBackdrop, CenteredScreen, ClipboardSharedTaskPrompt, ComposerNativeSection, ComposerNativeSection.ios, ComposerSheet, ComposerSheet.ios, ConnectionBanner, ConnectionNoticeOverlay, ContextSheet, ContextSheet.ios, DeviceLinkContext, FoldTouchpad, HomeEntryProvider, HomeHeaderGlassButton, HomeHeaderGlassButton.ios, HomeNativeStackHeader, IncomingShareBridge, MobileLoginHandoffContext, MobileLoginHandoffStage, MobileOutboxBridge, MobilePrimitives, NativeChromeBackButton.ios, NativeChromeButton.ios, NativePullDownMenu, NativeRemoteDesktopView, NativeResidentHistory, NativeSwitch, OutsideTap, PermissionGuide, PermissionGuideView, PermissionGuideView.ios, PushNotificationsBridge, QuietSyncIndicator, RecentMessageHistories, RemoteDesktopActionButton, RemoteDesktopActionButton.ios, RemoteDesktopBackButton, RemoteDesktopBackButton.ios, RemoteDesktopChrome, RemoteDesktopChrome.ios, RemoteDesktopClipboardButton, RemoteDesktopControls, RemoteDesktopDisplaySettings, RemoteDesktopHost, RemoteDesktopIcons, RemoteDesktopMouseControls, RemoteDesktopMouseControls.ios, RemoteDesktopNetworkStatus, RemoteDesktopPanelButton, RemoteDesktopPanelButton.ios, RemoteDesktopScreen, RemoteDesktopSecuritySettings, RemoteDesktopWindows, ResidentHomeList, SharedTaskAdmissionDialog, SharedTaskScreen, SheetModal, SheetSurface, SimpleStackHeader, StartupSplashOverlay, ThemeProvider, _layout, account-deletion, gestureHandler, peerFileTransport, useLocale | apps/mobile/app/_layout.tsx, apps/mobile/app/account-deletion.tsx, apps/mobile/src/auth/AuthContext.tsx, apps/mobile/src/auth/MobileLoginHandoffContext.tsx, apps/mobile/src/components/AppText.tsx, apps/mobile/src/components/CenteredScreen.tsx, apps/mobile/src/components/ConnectionBanner.tsx, apps/mobile/src/components/ConnectionNoticeOverlay.tsx, apps/mobile/src/components/MobileLoginHandoffStage.tsx, apps/mobile/src/components/MobilePrimitives.tsx, apps/mobile/src/components/QuietSyncIndicator.tsx, apps/mobile/src/components/StartupSplashOverlay.tsx, apps/mobile/src/device-link/DeviceLinkContext.tsx, apps/mobile/src/device-link/peerFileTransport.tsx, apps/mobile/src/i18n/useLocale.tsx, apps/mobile/src/notifications/PushNotificationsBridge.tsx, apps/mobile/src/platform/AdaptiveWindow.tsx, apps/mobile/src/platform/OutsideTap.tsx, apps/mobile/src/platform/chrome/AnchoredPullDownMenu.tsx, apps/mobile/src/platform/chrome/HomeNativeStackHeader.tsx, apps/mobile/src/platform/chrome/NativeChromeBackButton.ios.tsx, apps/mobile/src/platform/chrome/NativeChromeButton.ios.tsx, apps/mobile/src/platform/chrome/NativePullDownMenu.tsx, apps/mobile/src/platform/chrome/NativeSwitch.tsx, apps/mobile/src/platform/chrome/SimpleStackHeader.tsx, apps/mobile/src/platform/gestureHandler.tsx, apps/mobile/src/remote-desktop/FoldTouchpad.tsx, apps/mobile/src/remote-desktop/NativeRemoteDesktopView.tsx, apps/mobile/src/remote-desktop/PermissionGuide.tsx, apps/mobile/src/remote-desktop/PermissionGuideView.ios.tsx, apps/mobile/src/remote-desktop/PermissionGuideView.tsx, apps/mobile/src/remote-desktop/RemoteDesktopActionButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopActionButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopBackButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopBackButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopChrome.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopChrome.tsx, apps/mobile/src/remote-desktop/RemoteDesktopClipboardButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopControls.tsx, apps/mobile/src/remote-desktop/RemoteDesktopDisplaySettings.tsx, apps/mobile/src/remote-desktop/RemoteDesktopHost.tsx, apps/mobile/src/remote-desktop/RemoteDesktopIcons.tsx, apps/mobile/src/remote-desktop/RemoteDesktopMouseControls.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopMouseControls.tsx, apps/mobile/src/remote-desktop/RemoteDesktopNetworkStatus.tsx, apps/mobile/src/remote-desktop/RemoteDesktopPanelButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopPanelButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopScreen.tsx, apps/mobile/src/remote-desktop/RemoteDesktopSecuritySettings.tsx, apps/mobile/src/remote-desktop/RemoteDesktopWindows.tsx, apps/mobile/src/remote-desktop/viewerHtml.ts, apps/mobile/src/session/BlurBackdrop.tsx, apps/mobile/src/session/ClipboardSharedTaskPrompt.tsx, apps/mobile/src/session/ComposerNativeSection.ios.tsx, apps/mobile/src/session/ComposerNativeSection.tsx, apps/mobile/src/session/ComposerSheet.ios.tsx, apps/mobile/src/session/ComposerSheet.tsx, apps/mobile/src/session/ContextSheet.ios.tsx, apps/mobile/src/session/ContextSheet.tsx, apps/mobile/src/session/HomeEntryProvider.tsx, apps/mobile/src/session/HomeHeaderGlassButton.ios.tsx, apps/mobile/src/session/HomeHeaderGlassButton.tsx, apps/mobile/src/session/IncomingShareBridge.tsx, apps/mobile/src/session/MobileOutboxBridge.tsx, apps/mobile/src/session/NativeResidentHistory.tsx, apps/mobile/src/session/RecentMessageHistories.tsx, apps/mobile/src/session/ResidentHomeList.tsx, apps/mobile/src/session/SharedTaskAdmissionDialog.tsx, apps/mobile/src/session/SharedTaskScreen.tsx, apps/mobile/src/session/SheetModal.tsx, apps/mobile/src/session/SheetSurface.tsx, apps/mobile/src/theme/ThemeProvider.tsx, apps/mobile/src/theme/navigationTheme.ts, apps/mobile/src/theme/tokens.ts, apps/mobile/src/update/AndroidUpdateSheet.tsx | 0 | 210 | 62 |
| `mobile.auth` | mobile | 登录与添加账号 | app/(auth)/login.tsx / app/add-account.tsx | AccountSwitcherSheet, AdaptiveWindow, AnchoredPullDownMenu, AndroidUpdateSheet, AppText, AuthContext, BlurBackdrop, CenteredScreen, ClipboardSharedTaskPrompt, ComposerNativeSection, ComposerNativeSection.ios, ComposerSheet, ComposerSheet.ios, ConnectionBanner, ConnectionNoticeOverlay, ContextSheet, ContextSheet.ios, DeviceLinkContext, FoldTouchpad, HomeEntryProvider, HomeHeaderGlassButton, HomeHeaderGlassButton.ios, IncomingShareBridge, LoginCaptchaWebView, LoginNativeButton, LoginNativeButton.ios, LoginSkinControls, MobileLoginHandoffContext, MobileLoginHandoffStage, MobileOutboxBridge, MobilePrimitives, MobileUserAvatar, NativeChromeBackButton.ios, NativeChromeButton.ios, NativePullDownMenu, NativeRemoteDesktopView, NativeResidentHistory, NativeSwitch, OutsideTap, PermissionGuide, PermissionGuideView, PermissionGuideView.ios, PushNotificationsBridge, QuietSyncIndicator, RecentMessageHistories, RemoteDesktopActionButton, RemoteDesktopActionButton.ios, RemoteDesktopBackButton, RemoteDesktopBackButton.ios, RemoteDesktopChrome, RemoteDesktopChrome.ios, RemoteDesktopClipboardButton, RemoteDesktopControls, RemoteDesktopDisplaySettings, RemoteDesktopHost, RemoteDesktopIcons, RemoteDesktopMouseControls, RemoteDesktopMouseControls.ios, RemoteDesktopNetworkStatus, RemoteDesktopPanelButton, RemoteDesktopPanelButton.ios, RemoteDesktopScreen, RemoteDesktopSecuritySettings, RemoteDesktopWindows, ResidentHomeList, SharedTaskAdmissionDialog, SharedTaskScreen, SheetModal, SheetSurface, SimpleStackHeader, StartupSplashOverlay, SystemNavigationBack, ThemeProvider, _layout, add-account, gestureHandler, login, peerFileTransport, useLocale | apps/mobile/app/(auth)/login.tsx, apps/mobile/app/_layout.tsx, apps/mobile/app/add-account.tsx, apps/mobile/src/auth/AuthContext.tsx, apps/mobile/src/auth/LoginCaptchaWebView.tsx, apps/mobile/src/auth/MobileLoginHandoffContext.tsx, apps/mobile/src/components/AppText.tsx, apps/mobile/src/components/CenteredScreen.tsx, apps/mobile/src/components/ConnectionBanner.tsx, apps/mobile/src/components/ConnectionNoticeOverlay.tsx, apps/mobile/src/components/LoginNativeButton.ios.tsx, apps/mobile/src/components/LoginNativeButton.tsx, apps/mobile/src/components/LoginSkinControls.tsx, apps/mobile/src/components/MobileLoginHandoffStage.tsx, apps/mobile/src/components/MobilePrimitives.tsx, apps/mobile/src/components/MobileUserAvatar.tsx, apps/mobile/src/components/QuietSyncIndicator.tsx, apps/mobile/src/components/StartupSplashOverlay.tsx, apps/mobile/src/device-link/DeviceLinkContext.tsx, apps/mobile/src/device-link/peerFileTransport.tsx, apps/mobile/src/i18n/useLocale.tsx, apps/mobile/src/notifications/PushNotificationsBridge.tsx, apps/mobile/src/platform/AdaptiveWindow.tsx, apps/mobile/src/platform/OutsideTap.tsx, apps/mobile/src/platform/chrome/AnchoredPullDownMenu.tsx, apps/mobile/src/platform/chrome/NativeChromeBackButton.ios.tsx, apps/mobile/src/platform/chrome/NativeChromeButton.ios.tsx, apps/mobile/src/platform/chrome/NativePullDownMenu.tsx, apps/mobile/src/platform/chrome/NativeSwitch.tsx, apps/mobile/src/platform/chrome/SimpleStackHeader.tsx, apps/mobile/src/platform/chrome/SystemNavigationBack.tsx, apps/mobile/src/platform/gestureHandler.tsx, apps/mobile/src/remote-desktop/FoldTouchpad.tsx, apps/mobile/src/remote-desktop/NativeRemoteDesktopView.tsx, apps/mobile/src/remote-desktop/PermissionGuide.tsx, apps/mobile/src/remote-desktop/PermissionGuideView.ios.tsx, apps/mobile/src/remote-desktop/PermissionGuideView.tsx, apps/mobile/src/remote-desktop/RemoteDesktopActionButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopActionButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopBackButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopBackButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopChrome.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopChrome.tsx, apps/mobile/src/remote-desktop/RemoteDesktopClipboardButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopControls.tsx, apps/mobile/src/remote-desktop/RemoteDesktopDisplaySettings.tsx, apps/mobile/src/remote-desktop/RemoteDesktopHost.tsx, apps/mobile/src/remote-desktop/RemoteDesktopIcons.tsx, apps/mobile/src/remote-desktop/RemoteDesktopMouseControls.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopMouseControls.tsx, apps/mobile/src/remote-desktop/RemoteDesktopNetworkStatus.tsx, apps/mobile/src/remote-desktop/RemoteDesktopPanelButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopPanelButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopScreen.tsx, apps/mobile/src/remote-desktop/RemoteDesktopSecuritySettings.tsx, apps/mobile/src/remote-desktop/RemoteDesktopWindows.tsx, apps/mobile/src/remote-desktop/viewerHtml.ts, apps/mobile/src/session/AccountSwitcherSheet.tsx, apps/mobile/src/session/BlurBackdrop.tsx, apps/mobile/src/session/ClipboardSharedTaskPrompt.tsx, apps/mobile/src/session/ComposerNativeSection.ios.tsx, apps/mobile/src/session/ComposerNativeSection.tsx, apps/mobile/src/session/ComposerSheet.ios.tsx, apps/mobile/src/session/ComposerSheet.tsx, apps/mobile/src/session/ContextSheet.ios.tsx, apps/mobile/src/session/ContextSheet.tsx, apps/mobile/src/session/HomeEntryProvider.tsx, apps/mobile/src/session/HomeHeaderGlassButton.ios.tsx, apps/mobile/src/session/HomeHeaderGlassButton.tsx, apps/mobile/src/session/IncomingShareBridge.tsx, apps/mobile/src/session/MobileOutboxBridge.tsx, apps/mobile/src/session/NativeResidentHistory.tsx, apps/mobile/src/session/RecentMessageHistories.tsx, apps/mobile/src/session/ResidentHomeList.tsx, apps/mobile/src/session/SharedTaskAdmissionDialog.tsx, apps/mobile/src/session/SharedTaskScreen.tsx, apps/mobile/src/session/SheetModal.tsx, apps/mobile/src/session/SheetSurface.tsx, apps/mobile/src/theme/ThemeProvider.tsx, apps/mobile/src/theme/navigationTheme.ts, apps/mobile/src/theme/tokens.ts, apps/mobile/src/update/AndroidUpdateSheet.tsx | 0 | 217 | 84 |
| `mobile.chat.new` | mobile | 新建任务 | app/sessions/new.tsx | AdaptiveWindow, AnchoredPullDownMenu, AndroidUpdateSheet, AnnotationBurnInWebView, AppText, AuthContext, BlurBackdrop, CenteredScreen, ClipboardSharedTaskPrompt, ComposerAttachmentTray, ComposerDockKeyboardFollow, ComposerFrame, ComposerFrame.ios, ComposerKeyboardAvoidingView, ComposerNativeRow, ComposerNativeRow.ios, ComposerNativeSection, ComposerNativeSection.ios, ComposerSheet, ComposerSheet.ios, ConnectionBanner, ConnectionNoticeOverlay, ContextSheet, ContextSheet.ios, ContextSheetCollabView, ContextSheetGoalView, ContextSheetGoalView.ios, ContextSheetMediaViews, DeviceLinkContext, FileTypeIcon, FoldTouchpad, HomeEntryProvider, HomeHeaderGlassButton, HomeHeaderGlassButton.ios, HomeNativeStackHeader, ImageLightbox, IncomingShareBridge, MobileAgentMark, MobileAgentSwitcher, MobileChoicePickerList, MobileComposerInputRow, MobileLoginHandoffContext, MobileLoginHandoffStage, MobileModelPickerList, MobileModelPickerList.ios, MobileOutboxBridge, MobilePermissionPickerList, MobilePermissionPickerList.ios, MobilePrimitives, MobileProviderMark, MobileVendorIcon, ModelOptionsSheetView, ModelOptionsSheetView.ios, ModelPickerNativeHeader, ModelPickerNativeHeader.ios, ModelPickerSheet, NativeChromeBackButton.ios, NativeChromeButton.ios, NativePermissionSheet, NativePermissionSheet.ios, NativePullDownMenu, NativeRemoteDesktopView, NativeResidentHistory, NativeSwitch, NewTaskSelectionSheet, NewTaskSelectionSheet.ios, OutsideTap, PaperPlaneIcon, PermissionGuide, PermissionGuideView, PermissionGuideView.ios, PlanModeChip, PushNotificationsBridge, QuietSyncIndicator, RecentMessageHistories, RemoteDesktopActionButton, RemoteDesktopActionButton.ios, RemoteDesktopBackButton, RemoteDesktopBackButton.ios, RemoteDesktopChrome, RemoteDesktopChrome.ios, RemoteDesktopClipboardButton, RemoteDesktopControls, RemoteDesktopDisplaySettings, RemoteDesktopHost, RemoteDesktopIcons, RemoteDesktopMouseControls, RemoteDesktopMouseControls.ios, RemoteDesktopNetworkStatus, RemoteDesktopPanelButton, RemoteDesktopPanelButton.ios, RemoteDesktopScreen, RemoteDesktopSecuritySettings, RemoteDesktopWindows, ResidentHomeList, SharedTaskAdmissionDialog, SharedTaskScreen, SheetModal, SheetSurface, SimpleStackHeader, SlowSendNotice, StartupSplashOverlay, ThemeProvider, UnifiedModelPickerSheet, UnifiedModelPickerView, UnifiedModelPickerView.ios, VoiceRecordingPill, _layout, gestureHandler, new, peerFileTransport, useLocale, voicePillWidthMotion | apps/mobile/app/_layout.tsx, apps/mobile/app/sessions/new.tsx, apps/mobile/src/auth/AuthContext.tsx, apps/mobile/src/auth/MobileLoginHandoffContext.tsx, apps/mobile/src/components/AppText.tsx, apps/mobile/src/components/CenteredScreen.tsx, apps/mobile/src/components/ConnectionBanner.tsx, apps/mobile/src/components/ConnectionNoticeOverlay.tsx, apps/mobile/src/components/FileTypeIcon.tsx, apps/mobile/src/components/MobileAgentMark.tsx, apps/mobile/src/components/MobileLoginHandoffStage.tsx, apps/mobile/src/components/MobilePrimitives.tsx, apps/mobile/src/components/MobileVendorIcon.tsx, apps/mobile/src/components/PaperPlaneIcon.tsx, apps/mobile/src/components/QuietSyncIndicator.tsx, apps/mobile/src/components/StartupSplashOverlay.tsx, apps/mobile/src/device-link/DeviceLinkContext.tsx, apps/mobile/src/device-link/peerFileTransport.tsx, apps/mobile/src/i18n/useLocale.tsx, apps/mobile/src/notifications/PushNotificationsBridge.tsx, apps/mobile/src/platform/AdaptiveWindow.tsx, apps/mobile/src/platform/OutsideTap.tsx, apps/mobile/src/platform/chrome/AnchoredPullDownMenu.tsx, apps/mobile/src/platform/chrome/HomeNativeStackHeader.tsx, apps/mobile/src/platform/chrome/NativeChromeBackButton.ios.tsx, apps/mobile/src/platform/chrome/NativeChromeButton.ios.tsx, apps/mobile/src/platform/chrome/NativePullDownMenu.tsx, apps/mobile/src/platform/chrome/NativeSwitch.tsx, apps/mobile/src/platform/chrome/SimpleStackHeader.tsx, apps/mobile/src/platform/gestureHandler.tsx, apps/mobile/src/remote-desktop/FoldTouchpad.tsx, apps/mobile/src/remote-desktop/NativeRemoteDesktopView.tsx, apps/mobile/src/remote-desktop/PermissionGuide.tsx, apps/mobile/src/remote-desktop/PermissionGuideView.ios.tsx, apps/mobile/src/remote-desktop/PermissionGuideView.tsx, apps/mobile/src/remote-desktop/RemoteDesktopActionButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopActionButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopBackButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopBackButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopChrome.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopChrome.tsx, apps/mobile/src/remote-desktop/RemoteDesktopClipboardButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopControls.tsx, apps/mobile/src/remote-desktop/RemoteDesktopDisplaySettings.tsx, apps/mobile/src/remote-desktop/RemoteDesktopHost.tsx, apps/mobile/src/remote-desktop/RemoteDesktopIcons.tsx, apps/mobile/src/remote-desktop/RemoteDesktopMouseControls.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopMouseControls.tsx, apps/mobile/src/remote-desktop/RemoteDesktopNetworkStatus.tsx, apps/mobile/src/remote-desktop/RemoteDesktopPanelButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopPanelButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopScreen.tsx, apps/mobile/src/remote-desktop/RemoteDesktopSecuritySettings.tsx, apps/mobile/src/remote-desktop/RemoteDesktopWindows.tsx, apps/mobile/src/remote-desktop/viewerHtml.ts, apps/mobile/src/session/AnnotationBurnInWebView.tsx, apps/mobile/src/session/BlurBackdrop.tsx, apps/mobile/src/session/ClipboardSharedTaskPrompt.tsx, apps/mobile/src/session/ComposerAttachmentTray.tsx, apps/mobile/src/session/ComposerDockKeyboardFollow.tsx, apps/mobile/src/session/ComposerFrame.ios.tsx, apps/mobile/src/session/ComposerFrame.tsx, apps/mobile/src/session/ComposerKeyboardAvoidingView.tsx, apps/mobile/src/session/ComposerNativeRow.ios.tsx, apps/mobile/src/session/ComposerNativeRow.tsx, apps/mobile/src/session/ComposerNativeSection.ios.tsx, apps/mobile/src/session/ComposerNativeSection.tsx, apps/mobile/src/session/ComposerSheet.ios.tsx, apps/mobile/src/session/ComposerSheet.tsx, apps/mobile/src/session/ContextSheet.ios.tsx, apps/mobile/src/session/ContextSheet.tsx, apps/mobile/src/session/ContextSheetCollabView.tsx, apps/mobile/src/session/ContextSheetGoalView.ios.tsx, apps/mobile/src/session/ContextSheetGoalView.tsx, apps/mobile/src/session/ContextSheetMediaViews.tsx, apps/mobile/src/session/HomeEntryProvider.tsx, apps/mobile/src/session/HomeHeaderGlassButton.ios.tsx, apps/mobile/src/session/HomeHeaderGlassButton.tsx, apps/mobile/src/session/ImageLightbox.tsx, apps/mobile/src/session/IncomingShareBridge.tsx, apps/mobile/src/session/MobileAgentSwitcher.tsx, apps/mobile/src/session/MobileChoicePickerList.tsx, apps/mobile/src/session/MobileComposerInputRow.tsx, apps/mobile/src/session/MobileModelPickerList.ios.tsx, apps/mobile/src/session/MobileModelPickerList.tsx, apps/mobile/src/session/MobileOutboxBridge.tsx, apps/mobile/src/session/MobilePermissionPickerList.ios.tsx, apps/mobile/src/session/MobilePermissionPickerList.tsx, apps/mobile/src/session/MobileProviderMark.tsx, apps/mobile/src/session/ModelOptionsSheetView.ios.tsx, apps/mobile/src/session/ModelOptionsSheetView.tsx, apps/mobile/src/session/ModelPickerNativeHeader.ios.tsx, apps/mobile/src/session/ModelPickerNativeHeader.tsx, apps/mobile/src/session/ModelPickerSheet.tsx, apps/mobile/src/session/NativePermissionSheet.ios.tsx, apps/mobile/src/session/NativePermissionSheet.tsx, apps/mobile/src/session/NativeResidentHistory.tsx, apps/mobile/src/session/NewTaskSelectionSheet.ios.tsx, apps/mobile/src/session/NewTaskSelectionSheet.tsx, apps/mobile/src/session/PlanModeChip.tsx, apps/mobile/src/session/RecentMessageHistories.tsx, apps/mobile/src/session/ResidentHomeList.tsx, apps/mobile/src/session/SharedTaskAdmissionDialog.tsx, apps/mobile/src/session/SharedTaskScreen.tsx, apps/mobile/src/session/SheetModal.tsx, apps/mobile/src/session/SheetSurface.tsx, apps/mobile/src/session/SlowSendNotice.tsx, apps/mobile/src/session/UnifiedModelPickerSheet.tsx, apps/mobile/src/session/UnifiedModelPickerView.ios.tsx, apps/mobile/src/session/UnifiedModelPickerView.tsx, apps/mobile/src/session/VoiceRecordingPill.tsx, apps/mobile/src/session/voicePillWidthMotion.tsx, apps/mobile/src/theme/ThemeProvider.tsx, apps/mobile/src/theme/navigationTheme.ts, apps/mobile/src/theme/tokens.ts, apps/mobile/src/update/AndroidUpdateSheet.tsx | 0 | 242 | 109 |
-| `mobile.chat.session` | mobile | 任务内容与输入 | app/sessions/[sessionId].tsx | AccountSwitcherSheet, AdaptiveWindow, AgentErrorDetails, AnchoredPullDownMenu, AndroidUpdateSheet, AnnotationBurnInWebView, AppText, AuthContext, AuthorizationMessageCard, AutomationTimerIcon, BlurBackdrop, CenteredScreen, ChatFileChipMenuSheet, ChatIdentityHeader, ClipboardSharedTaskPrompt, CompanionChoice, CompanionCreateNativeView, CompanionCreateNativeView.ios, CompanionEntering, CompanionHeader, CompanionImportSheet, CompanionLearningFooter, CompanionMemoryPage, CompanionMemoryPage.ios, CompanionMessageActions, CompanionMessageCard, CompanionModelChain, CompanionNativeContent.ios, CompanionPortraitPicker, CompanionPresenceRing, CompanionProfileArtifacts, CompanionProfileNativeView, CompanionProfileNativeView.ios, CompanionProfileSheet, CompanionSettingsRow, CompanionSettingsRow.ios, CompanionSheet, CompanionSheet.ios, CompanionTaskResultCard, CompanionWorkingStatus, ComposerAttachmentTray, ComposerDockKeyboardFollow, ComposerExpandButton, ComposerExpandButton.ios, ComposerFrame, ComposerFrame.ios, ComposerKeyboardAvoidingView, ComposerMorphSource, ComposerMorphSource.ios, ComposerNativeInput, ComposerNativeInput.ios, ComposerNativeRow, ComposerNativeRow.ios, ComposerNativeSection, ComposerNativeSection.ios, ComposerRichInput, ComposerSheet, ComposerSheet.ios, ConnectionBanner, ConnectionNoticeOverlay, ContextSheet, ContextSheet.ios, ContextSheetCollabView, ContextSheetGoalView, ContextSheetGoalView.ios, ContextSheetMediaViews, ConversationSearchFilterSheet, ConversationShareSvg, ConversationShareWebView, DeviceLinkContext, FailedScheduleNotice, FileTypeIcon, FoldTouchpad, HomeChromeDrawer, HomeChromeFrost, HomeEntryProvider, HomeGlassMenuPanel, HomeHeaderGlassButton, HomeHeaderGlassButton.ios, HomeListVisuals, HomeModeSwitch, HomeNativeStackHeader, HomeNewTaskButton, HomeProjectMachineLabel, HomeSearchBar, HomeSurface, HomeUnreadContext, ImageLightbox, IncomingShareBridge, InlineQueueSection, InlineQuoteChip, InlineReferenceChip, InteractionPanel, MarkdownBlockContent, MessageActionSheet, MessageRenderer, MobileAgentMark, MobileAgentSwitcher, MobileBoundaryNotice, MobileComposerInputRow, MobileLoginHandoffContext, MobileLoginHandoffStage, MobileModelPickerList, MobileModelPickerList.ios, MobileOutboxBridge, MobilePermissionPickerList, MobilePermissionPickerList.ios, MobilePrimitives, MobileProviderMark, MobileUserAvatar, MobileVendorIcon, ModalContentArea, ModelOptionsSheetView, ModelOptionsSheetView.ios, ModelPickerNativeHeader, ModelPickerNativeHeader.ios, ModelPickerSheet, NativeChromeBackButton.ios, NativeChromeButton.ios, NativePermissionSheet, NativePermissionSheet.ios, NativePullDownMenu, NativeRemoteDesktopView, NativeResidentHistory, NativeSwitch, OutsideTap, PaperPlaneIcon, PendingSendBubble, PermissionGuide, PermissionGuideView, PermissionGuideView.ios, PlanModeChip, PluginInvocationHeader, PromptRecommendation, PushNotificationsBridge, QuietSyncIndicator, QuoteCapsule, RecentMessageHistories, RemoteAccessGuide, RemoteCompanionAvatar, RemoteDesktopActionButton, RemoteDesktopActionButton.ios, RemoteDesktopBackButton, RemoteDesktopBackButton.ios, RemoteDesktopChrome, RemoteDesktopChrome.ios, RemoteDesktopClipboardButton, RemoteDesktopControls, RemoteDesktopDisplaySettings, RemoteDesktopHost, RemoteDesktopIcons, RemoteDesktopMouseControls, RemoteDesktopMouseControls.ios, RemoteDesktopNetworkStatus, RemoteDesktopPanelButton, RemoteDesktopPanelButton.ios, RemoteDesktopScreen, RemoteDesktopSecuritySettings, RemoteDesktopWindows, RemoteTaskSuggestions, RenameSessionModal, ResidentHomeList, RewindPreviewPanel, RunningTokenRatePopover, SentInlineAtomBody, SessionActionSheet, SessionDetailsNative, SessionDetailsNative.ios, SessionHeaderNativeControls, SessionHeaderNativeControls.ios, SessionListDrawer, SessionMenuSheet, SessionOptionsExpoSheet, SessionResourceCards, SessionRightSpinner, SessionSearchNative, SessionSearchNative.ios, SessionTailBanner, SessionTransientNotice, SessionUsageSummary, ShareImageNativeButton, ShareImageNativeButton.ios, ShareMessageCheckbox, ShareSelectAllButton, ShareSelectionBar, SharedTaskAdmissionDialog, SharedTaskEndedState, SharedTaskScreen, SheetModal, SheetSurface, SimpleStackHeader, SlowSendNotice, StartupSplashOverlay, StreamingStatusText, SwipeableSessionRow, SwipeableSessionRow.ios, SystemNavigationBack, TaskTags, TaskTagsSheet, ThemeProvider, ThinkingDots, UnifiedModelPickerSheet, UnifiedModelPickerView, UnifiedModelPickerView.ios, VoiceRecordingPill, WorkingStatusText, [sessionId], _layout, gestureHandler, listDisclosureTransition, mathWebView, mediaPlayerWebView, mermaidWebView, peerFileTransport, useLocale, useSharedTaskConfirmation, voicePillWidthMotion | apps/mobile/app/_layout.tsx, apps/mobile/app/sessions/[sessionId].tsx, apps/mobile/src/auth/AuthContext.tsx, apps/mobile/src/auth/MobileLoginHandoffContext.tsx, apps/mobile/src/components/AppText.tsx, apps/mobile/src/components/CenteredScreen.tsx, apps/mobile/src/components/ConnectionBanner.tsx, apps/mobile/src/components/ConnectionNoticeOverlay.tsx, apps/mobile/src/components/FileTypeIcon.tsx, apps/mobile/src/components/MobileAgentMark.tsx, apps/mobile/src/components/MobileLoginHandoffStage.tsx, apps/mobile/src/components/MobilePrimitives.tsx, apps/mobile/src/components/MobileUserAvatar.tsx, apps/mobile/src/components/MobileVendorIcon.tsx, apps/mobile/src/components/PaperPlaneIcon.tsx, apps/mobile/src/components/QuietSyncIndicator.tsx, apps/mobile/src/components/RemoteAccessGuide.tsx, apps/mobile/src/components/RemoteCompanionAvatar.tsx, apps/mobile/src/components/StartupSplashOverlay.tsx, apps/mobile/src/device-link/DeviceLinkContext.tsx, apps/mobile/src/device-link/peerFileTransport.tsx, apps/mobile/src/i18n/useLocale.tsx, apps/mobile/src/notifications/PushNotificationsBridge.tsx, apps/mobile/src/platform/AdaptiveWindow.tsx, apps/mobile/src/platform/ModalContentArea.tsx, apps/mobile/src/platform/OutsideTap.tsx, apps/mobile/src/platform/chrome/AnchoredPullDownMenu.tsx, apps/mobile/src/platform/chrome/HomeNativeStackHeader.tsx, apps/mobile/src/platform/chrome/NativeChromeBackButton.ios.tsx, apps/mobile/src/platform/chrome/NativeChromeButton.ios.tsx, apps/mobile/src/platform/chrome/NativePullDownMenu.tsx, apps/mobile/src/platform/chrome/NativeSwitch.tsx, apps/mobile/src/platform/chrome/SimpleStackHeader.tsx, apps/mobile/src/platform/chrome/SystemNavigationBack.tsx, apps/mobile/src/platform/gestureHandler.tsx, apps/mobile/src/remote-desktop/FoldTouchpad.tsx, apps/mobile/src/remote-desktop/NativeRemoteDesktopView.tsx, apps/mobile/src/remote-desktop/PermissionGuide.tsx, apps/mobile/src/remote-desktop/PermissionGuideView.ios.tsx, apps/mobile/src/remote-desktop/PermissionGuideView.tsx, apps/mobile/src/remote-desktop/RemoteDesktopActionButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopActionButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopBackButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopBackButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopChrome.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopChrome.tsx, apps/mobile/src/remote-desktop/RemoteDesktopClipboardButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopControls.tsx, apps/mobile/src/remote-desktop/RemoteDesktopDisplaySettings.tsx, apps/mobile/src/remote-desktop/RemoteDesktopHost.tsx, apps/mobile/src/remote-desktop/RemoteDesktopIcons.tsx, apps/mobile/src/remote-desktop/RemoteDesktopMouseControls.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopMouseControls.tsx, apps/mobile/src/remote-desktop/RemoteDesktopNetworkStatus.tsx, apps/mobile/src/remote-desktop/RemoteDesktopPanelButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopPanelButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopScreen.tsx, apps/mobile/src/remote-desktop/RemoteDesktopSecuritySettings.tsx, apps/mobile/src/remote-desktop/RemoteDesktopWindows.tsx, apps/mobile/src/remote-desktop/viewerHtml.ts, apps/mobile/src/session/AccountSwitcherSheet.tsx, apps/mobile/src/session/AgentErrorDetails.tsx, apps/mobile/src/session/AnnotationBurnInWebView.tsx, apps/mobile/src/session/AuthorizationMessageCard.tsx, apps/mobile/src/session/AutomationTimerIcon.tsx, apps/mobile/src/session/BlurBackdrop.tsx, apps/mobile/src/session/ChatFileChipMenuSheet.tsx, apps/mobile/src/session/ChatIdentityHeader.tsx, apps/mobile/src/session/ClipboardSharedTaskPrompt.tsx, apps/mobile/src/session/CompanionChoice.tsx, apps/mobile/src/session/CompanionCreateNativeView.ios.tsx, apps/mobile/src/session/CompanionCreateNativeView.tsx, apps/mobile/src/session/CompanionEntering.tsx, apps/mobile/src/session/CompanionHeader.tsx, apps/mobile/src/session/CompanionImportSheet.tsx, apps/mobile/src/session/CompanionLearningFooter.tsx, apps/mobile/src/session/CompanionMemoryPage.ios.tsx, apps/mobile/src/session/CompanionMemoryPage.tsx, apps/mobile/src/session/CompanionMessageActions.tsx, apps/mobile/src/session/CompanionMessageCard.tsx, apps/mobile/src/session/CompanionModelChain.tsx, apps/mobile/src/session/CompanionNativeContent.ios.tsx, apps/mobile/src/session/CompanionPortraitPicker.tsx, apps/mobile/src/session/CompanionPresenceRing.tsx, apps/mobile/src/session/CompanionProfileArtifacts.tsx, apps/mobile/src/session/CompanionProfileNativeView.ios.tsx, apps/mobile/src/session/CompanionProfileNativeView.tsx, apps/mobile/src/session/CompanionProfileSheet.tsx, apps/mobile/src/session/CompanionSettingsRow.ios.tsx, apps/mobile/src/session/CompanionSettingsRow.tsx, apps/mobile/src/session/CompanionSheet.ios.tsx, apps/mobile/src/session/CompanionSheet.tsx, apps/mobile/src/session/CompanionTaskResultCard.tsx, apps/mobile/src/session/CompanionWorkingStatus.tsx, apps/mobile/src/session/ComposerAttachmentTray.tsx, apps/mobile/src/session/ComposerDockKeyboardFollow.tsx, apps/mobile/src/session/ComposerExpandButton.ios.tsx, apps/mobile/src/session/ComposerExpandButton.tsx, apps/mobile/src/session/ComposerFrame.ios.tsx, apps/mobile/src/session/ComposerFrame.tsx, apps/mobile/src/session/ComposerKeyboardAvoidingView.tsx, apps/mobile/src/session/ComposerMorphSource.ios.tsx, apps/mobile/src/session/ComposerMorphSource.tsx, apps/mobile/src/session/ComposerNativeInput.ios.tsx, apps/mobile/src/session/ComposerNativeInput.tsx, apps/mobile/src/session/ComposerNativeRow.ios.tsx, apps/mobile/src/session/ComposerNativeRow.tsx, apps/mobile/src/session/ComposerNativeSection.ios.tsx, apps/mobile/src/session/ComposerNativeSection.tsx, apps/mobile/src/session/ComposerRichInput.tsx, apps/mobile/src/session/ComposerSheet.ios.tsx, apps/mobile/src/session/ComposerSheet.tsx, apps/mobile/src/session/ContextSheet.ios.tsx, apps/mobile/src/session/ContextSheet.tsx, apps/mobile/src/session/ContextSheetCollabView.tsx, apps/mobile/src/session/ContextSheetGoalView.ios.tsx, apps/mobile/src/session/ContextSheetGoalView.tsx, apps/mobile/src/session/ContextSheetMediaViews.tsx, apps/mobile/src/session/ConversationSearchFilterSheet.tsx, apps/mobile/src/session/ConversationShareSvg.tsx, apps/mobile/src/session/ConversationShareWebView.tsx, apps/mobile/src/session/FailedScheduleNotice.tsx, apps/mobile/src/session/HomeChromeDrawer.tsx, apps/mobile/src/session/HomeChromeFrost.tsx, apps/mobile/src/session/HomeEntryProvider.tsx, apps/mobile/src/session/HomeGlassMenuPanel.tsx, apps/mobile/src/session/HomeHeaderGlassButton.ios.tsx, apps/mobile/src/session/HomeHeaderGlassButton.tsx, apps/mobile/src/session/HomeListVisuals.tsx, apps/mobile/src/session/HomeModeSwitch.tsx, apps/mobile/src/session/HomeNewTaskButton.tsx, apps/mobile/src/session/HomeProjectMachineLabel.tsx, apps/mobile/src/session/HomeSearchBar.tsx, apps/mobile/src/session/HomeSurface.tsx, apps/mobile/src/session/HomeUnreadContext.tsx, apps/mobile/src/session/ImageLightbox.tsx, apps/mobile/src/session/IncomingShareBridge.tsx, apps/mobile/src/session/InlineQueueSection.tsx, apps/mobile/src/session/InlineQuoteChip.tsx, apps/mobile/src/session/InlineReferenceChip.tsx, apps/mobile/src/session/InteractionPanel.tsx, apps/mobile/src/session/MarkdownBlockContent.tsx, apps/mobile/src/session/MessageActionSheet.tsx, apps/mobile/src/session/MessageRenderer.tsx, apps/mobile/src/session/MobileAgentSwitcher.tsx, apps/mobile/src/session/MobileBoundaryNotice.tsx, apps/mobile/src/session/MobileComposerInputRow.tsx, apps/mobile/src/session/MobileModelPickerList.ios.tsx, apps/mobile/src/session/MobileModelPickerList.tsx, apps/mobile/src/session/MobileOutboxBridge.tsx, apps/mobile/src/session/MobilePermissionPickerList.ios.tsx, apps/mobile/src/session/MobilePermissionPickerList.tsx, apps/mobile/src/session/MobileProviderMark.tsx, apps/mobile/src/session/ModelOptionsSheetView.ios.tsx, apps/mobile/src/session/ModelOptionsSheetView.tsx, apps/mobile/src/session/ModelPickerNativeHeader.ios.tsx, apps/mobile/src/session/ModelPickerNativeHeader.tsx, apps/mobile/src/session/ModelPickerSheet.tsx, apps/mobile/src/session/NativePermissionSheet.ios.tsx, apps/mobile/src/session/NativePermissionSheet.tsx, apps/mobile/src/session/NativeResidentHistory.tsx, apps/mobile/src/session/PendingSendBubble.tsx, apps/mobile/src/session/PlanModeChip.tsx, apps/mobile/src/session/PluginInvocationHeader.tsx, apps/mobile/src/session/PromptRecommendation.tsx, apps/mobile/src/session/QuoteCapsule.tsx, apps/mobile/src/session/RecentMessageHistories.tsx, apps/mobile/src/session/RemoteTaskSuggestions.tsx, apps/mobile/src/session/RenameSessionModal.tsx, apps/mobile/src/session/ResidentHomeList.tsx, apps/mobile/src/session/RewindPreviewPanel.tsx, apps/mobile/src/session/RunningTokenRatePopover.tsx, apps/mobile/src/session/SentInlineAtomBody.tsx, apps/mobile/src/session/SessionActionSheet.tsx, apps/mobile/src/session/SessionDetailsNative.ios.tsx, apps/mobile/src/session/SessionDetailsNative.tsx, apps/mobile/src/session/SessionHeaderNativeControls.ios.tsx, apps/mobile/src/session/SessionHeaderNativeControls.tsx, apps/mobile/src/session/SessionListDrawer.tsx, apps/mobile/src/session/SessionMenuSheet.tsx, apps/mobile/src/session/SessionOptionsExpoSheet.tsx, apps/mobile/src/session/SessionResourceCards.tsx, apps/mobile/src/session/SessionRightSpinner.tsx, apps/mobile/src/session/SessionSearchNative.ios.tsx, apps/mobile/src/session/SessionSearchNative.tsx, apps/mobile/src/session/SessionTailBanner.tsx, apps/mobile/src/session/SessionTransientNotice.tsx, apps/mobile/src/session/SessionUsageSummary.tsx, apps/mobile/src/session/ShareImageNativeButton.ios.tsx, apps/mobile/src/session/ShareImageNativeButton.tsx, apps/mobile/src/session/ShareMessageCheckbox.tsx, apps/mobile/src/session/ShareSelectAllButton.tsx, apps/mobile/src/session/ShareSelectionBar.tsx, apps/mobile/src/session/SharedTaskAdmissionDialog.tsx, apps/mobile/src/session/SharedTaskEndedState.tsx, apps/mobile/src/session/SharedTaskScreen.tsx, apps/mobile/src/session/SheetModal.tsx, apps/mobile/src/session/SheetSurface.tsx, apps/mobile/src/session/SlowSendNotice.tsx, apps/mobile/src/session/StreamingStatusText.tsx, apps/mobile/src/session/SwipeableSessionRow.ios.tsx, apps/mobile/src/session/SwipeableSessionRow.tsx, apps/mobile/src/session/TaskTags.tsx, apps/mobile/src/session/TaskTagsSheet.tsx, apps/mobile/src/session/ThinkingDots.tsx, apps/mobile/src/session/UnifiedModelPickerSheet.tsx, apps/mobile/src/session/UnifiedModelPickerView.ios.tsx, apps/mobile/src/session/UnifiedModelPickerView.tsx, apps/mobile/src/session/VoiceRecordingPill.tsx, apps/mobile/src/session/WorkingStatusText.tsx, apps/mobile/src/session/composerRichInputHtml.ts, apps/mobile/src/session/conversationShareWebViewHtml.ts, apps/mobile/src/session/listDisclosureTransition.tsx, apps/mobile/src/session/mathWebView.tsx, apps/mobile/src/session/mathWebViewHtml.ts, apps/mobile/src/session/mediaPlayerWebView.tsx, apps/mobile/src/session/mediaPlayerWebViewHtml.ts, apps/mobile/src/session/mermaidWebView.tsx, apps/mobile/src/session/mermaidWebViewHtml.ts, apps/mobile/src/session/selectableMarkdownHtml.ts, apps/mobile/src/session/useSharedTaskConfirmation.tsx, apps/mobile/src/session/voicePillWidthMotion.tsx, apps/mobile/src/theme/ThemeProvider.tsx, apps/mobile/src/theme/navigationTheme.ts, apps/mobile/src/theme/tokens.ts, apps/mobile/src/update/AndroidUpdateSheet.tsx | 7 | 243 | 300 |
+| `mobile.chat.session` | mobile | 任务内容与输入 | app/sessions/[sessionId].tsx | AccountSwitcherSheet, AdaptiveWindow, AgentErrorDetails, AnchoredPullDownMenu, AndroidUpdateSheet, AnnotationBurnInWebView, AppText, AuthContext, AuthorizationMessageCard, AutomationTimerIcon, BlurBackdrop, CenteredScreen, ChatFileChipMenuSheet, ChatIdentityHeader, ClipboardSharedTaskPrompt, CompanionChoice, CompanionCreateNativeView, CompanionCreateNativeView.ios, CompanionEntering, CompanionHeader, CompanionImportSheet, CompanionLearningFooter, CompanionMemoryPage, CompanionMemoryPage.ios, CompanionMessageActions, CompanionMessageCard, CompanionModelChain, CompanionNativeContent.ios, CompanionPortraitPicker, CompanionPresenceRing, CompanionProfileArtifacts, CompanionProfileNativeView, CompanionProfileNativeView.ios, CompanionProfileSheet, CompanionSettingsRow, CompanionSettingsRow.ios, CompanionSheet, CompanionSheet.ios, CompanionTaskResultCard, CompanionWorkingStatus, ComposerAttachmentTray, ComposerDockKeyboardFollow, ComposerExpandButton, ComposerExpandButton.ios, ComposerFrame, ComposerFrame.ios, ComposerKeyboardAvoidingView, ComposerMorphSource, ComposerMorphSource.ios, ComposerNativeInput, ComposerNativeInput.ios, ComposerNativeRow, ComposerNativeRow.ios, ComposerNativeSection, ComposerNativeSection.ios, ComposerRichInput, ComposerSheet, ComposerSheet.ios, ConnectionBanner, ConnectionNoticeOverlay, ContextSheet, ContextSheet.ios, ContextSheetCollabView, ContextSheetGoalView, ContextSheetGoalView.ios, ContextSheetMediaViews, ConversationSearchFilterSheet, ConversationShareSvg, ConversationShareWebView, DeviceLinkContext, FailedScheduleNotice, FileTypeIcon, FoldTouchpad, HomeChromeDrawer, HomeChromeFrost, HomeEntryProvider, HomeGlassMenuPanel, HomeHeaderGlassButton, HomeHeaderGlassButton.ios, HomeListVisuals, HomeModeSwitch, HomeNativeStackHeader, HomeNewTaskButton, HomeProjectMachineLabel, HomeSearchBar, HomeSurface, HomeUnreadContext, ImageLightbox, IncomingShareBridge, InlineQueueSection, InlineQuoteChip, InlineReferenceChip, InteractionPanel, MarkdownBlockContent, MessageActionSheet, MessageRenderer, MobileAgentMark, MobileAgentSwitcher, MobileBoundaryNotice, MobileComposerInputRow, MobileLoginHandoffContext, MobileLoginHandoffStage, MobileModelPickerList, MobileModelPickerList.ios, MobileOutboxBridge, MobilePermissionPickerList, MobilePermissionPickerList.ios, MobilePrimitives, MobileProviderMark, MobileUserAvatar, MobileVendorIcon, ModalContentArea, ModelOptionsSheetView, ModelOptionsSheetView.ios, ModelPickerNativeHeader, ModelPickerNativeHeader.ios, ModelPickerSheet, MountOnFirstOpen, NativeChromeBackButton.ios, NativeChromeButton.ios, NativePermissionSheet, NativePermissionSheet.ios, NativePullDownMenu, NativeRemoteDesktopView, NativeResidentHistory, NativeSwitch, OutsideTap, PaperPlaneIcon, PendingSendBubble, PermissionGuide, PermissionGuideView, PermissionGuideView.ios, PlanModeChip, PluginInvocationHeader, PromptRecommendation, PushNotificationsBridge, QuietSyncIndicator, QuoteCapsule, RecentMessageHistories, RemoteAccessGuide, RemoteCompanionAvatar, RemoteDesktopActionButton, RemoteDesktopActionButton.ios, RemoteDesktopBackButton, RemoteDesktopBackButton.ios, RemoteDesktopChrome, RemoteDesktopChrome.ios, RemoteDesktopClipboardButton, RemoteDesktopControls, RemoteDesktopDisplaySettings, RemoteDesktopHost, RemoteDesktopIcons, RemoteDesktopMouseControls, RemoteDesktopMouseControls.ios, RemoteDesktopNetworkStatus, RemoteDesktopPanelButton, RemoteDesktopPanelButton.ios, RemoteDesktopScreen, RemoteDesktopSecuritySettings, RemoteDesktopWindows, RemoteTaskSuggestions, RenameSessionModal, ResidentHomeList, RewindPreviewPanel, RunningTokenRatePopover, SentInlineAtomBody, SessionActionSheet, SessionDetailsNative, SessionDetailsNative.ios, SessionHeaderNativeControls, SessionHeaderNativeControls.ios, SessionListDrawer, SessionMenuSheet, SessionOptionsExpoSheet, SessionResourceCards, SessionRightSpinner, SessionSearchNative, SessionSearchNative.ios, SessionTailBanner, SessionTransientNotice, SessionUsageSummary, ShareImageNativeButton, ShareImageNativeButton.ios, ShareMessageCheckbox, ShareSelectAllButton, ShareSelectionBar, SharedTaskAdmissionDialog, SharedTaskEndedState, SharedTaskScreen, SheetModal, SheetSurface, SimpleStackHeader, SlowSendNotice, StartupSplashOverlay, StreamingStatusText, SwipeableSessionRow, SwipeableSessionRow.ios, SystemNavigationBack, TaskTags, TaskTagsSheet, ThemeProvider, ThinkingDots, UnifiedModelPickerSheet, UnifiedModelPickerView, UnifiedModelPickerView.ios, VoiceRecordingPill, WorkingStatusText, [sessionId], _layout, gestureHandler, listDisclosureTransition, mathWebView, mediaPlayerWebView, mermaidWebView, peerFileTransport, useLocale, useSharedTaskConfirmation, voicePillWidthMotion | apps/mobile/app/_layout.tsx, apps/mobile/app/sessions/[sessionId].tsx, apps/mobile/src/auth/AuthContext.tsx, apps/mobile/src/auth/MobileLoginHandoffContext.tsx, apps/mobile/src/components/AppText.tsx, apps/mobile/src/components/CenteredScreen.tsx, apps/mobile/src/components/ConnectionBanner.tsx, apps/mobile/src/components/ConnectionNoticeOverlay.tsx, apps/mobile/src/components/FileTypeIcon.tsx, apps/mobile/src/components/MobileAgentMark.tsx, apps/mobile/src/components/MobileLoginHandoffStage.tsx, apps/mobile/src/components/MobilePrimitives.tsx, apps/mobile/src/components/MobileUserAvatar.tsx, apps/mobile/src/components/MobileVendorIcon.tsx, apps/mobile/src/components/PaperPlaneIcon.tsx, apps/mobile/src/components/QuietSyncIndicator.tsx, apps/mobile/src/components/RemoteAccessGuide.tsx, apps/mobile/src/components/RemoteCompanionAvatar.tsx, apps/mobile/src/components/StartupSplashOverlay.tsx, apps/mobile/src/device-link/DeviceLinkContext.tsx, apps/mobile/src/device-link/peerFileTransport.tsx, apps/mobile/src/i18n/useLocale.tsx, apps/mobile/src/notifications/PushNotificationsBridge.tsx, apps/mobile/src/platform/AdaptiveWindow.tsx, apps/mobile/src/platform/ModalContentArea.tsx, apps/mobile/src/platform/OutsideTap.tsx, apps/mobile/src/platform/chrome/AnchoredPullDownMenu.tsx, apps/mobile/src/platform/chrome/HomeNativeStackHeader.tsx, apps/mobile/src/platform/chrome/NativeChromeBackButton.ios.tsx, apps/mobile/src/platform/chrome/NativeChromeButton.ios.tsx, apps/mobile/src/platform/chrome/NativePullDownMenu.tsx, apps/mobile/src/platform/chrome/NativeSwitch.tsx, apps/mobile/src/platform/chrome/SimpleStackHeader.tsx, apps/mobile/src/platform/chrome/SystemNavigationBack.tsx, apps/mobile/src/platform/gestureHandler.tsx, apps/mobile/src/remote-desktop/FoldTouchpad.tsx, apps/mobile/src/remote-desktop/NativeRemoteDesktopView.tsx, apps/mobile/src/remote-desktop/PermissionGuide.tsx, apps/mobile/src/remote-desktop/PermissionGuideView.ios.tsx, apps/mobile/src/remote-desktop/PermissionGuideView.tsx, apps/mobile/src/remote-desktop/RemoteDesktopActionButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopActionButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopBackButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopBackButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopChrome.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopChrome.tsx, apps/mobile/src/remote-desktop/RemoteDesktopClipboardButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopControls.tsx, apps/mobile/src/remote-desktop/RemoteDesktopDisplaySettings.tsx, apps/mobile/src/remote-desktop/RemoteDesktopHost.tsx, apps/mobile/src/remote-desktop/RemoteDesktopIcons.tsx, apps/mobile/src/remote-desktop/RemoteDesktopMouseControls.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopMouseControls.tsx, apps/mobile/src/remote-desktop/RemoteDesktopNetworkStatus.tsx, apps/mobile/src/remote-desktop/RemoteDesktopPanelButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopPanelButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopScreen.tsx, apps/mobile/src/remote-desktop/RemoteDesktopSecuritySettings.tsx, apps/mobile/src/remote-desktop/RemoteDesktopWindows.tsx, apps/mobile/src/remote-desktop/viewerHtml.ts, apps/mobile/src/session/AccountSwitcherSheet.tsx, apps/mobile/src/session/AgentErrorDetails.tsx, apps/mobile/src/session/AnnotationBurnInWebView.tsx, apps/mobile/src/session/AuthorizationMessageCard.tsx, apps/mobile/src/session/AutomationTimerIcon.tsx, apps/mobile/src/session/BlurBackdrop.tsx, apps/mobile/src/session/ChatFileChipMenuSheet.tsx, apps/mobile/src/session/ChatIdentityHeader.tsx, apps/mobile/src/session/ClipboardSharedTaskPrompt.tsx, apps/mobile/src/session/CompanionChoice.tsx, apps/mobile/src/session/CompanionCreateNativeView.ios.tsx, apps/mobile/src/session/CompanionCreateNativeView.tsx, apps/mobile/src/session/CompanionEntering.tsx, apps/mobile/src/session/CompanionHeader.tsx, apps/mobile/src/session/CompanionImportSheet.tsx, apps/mobile/src/session/CompanionLearningFooter.tsx, apps/mobile/src/session/CompanionMemoryPage.ios.tsx, apps/mobile/src/session/CompanionMemoryPage.tsx, apps/mobile/src/session/CompanionMessageActions.tsx, apps/mobile/src/session/CompanionMessageCard.tsx, apps/mobile/src/session/CompanionModelChain.tsx, apps/mobile/src/session/CompanionNativeContent.ios.tsx, apps/mobile/src/session/CompanionPortraitPicker.tsx, apps/mobile/src/session/CompanionPresenceRing.tsx, apps/mobile/src/session/CompanionProfileArtifacts.tsx, apps/mobile/src/session/CompanionProfileNativeView.ios.tsx, apps/mobile/src/session/CompanionProfileNativeView.tsx, apps/mobile/src/session/CompanionProfileSheet.tsx, apps/mobile/src/session/CompanionSettingsRow.ios.tsx, apps/mobile/src/session/CompanionSettingsRow.tsx, apps/mobile/src/session/CompanionSheet.ios.tsx, apps/mobile/src/session/CompanionSheet.tsx, apps/mobile/src/session/CompanionTaskResultCard.tsx, apps/mobile/src/session/CompanionWorkingStatus.tsx, apps/mobile/src/session/ComposerAttachmentTray.tsx, apps/mobile/src/session/ComposerDockKeyboardFollow.tsx, apps/mobile/src/session/ComposerExpandButton.ios.tsx, apps/mobile/src/session/ComposerExpandButton.tsx, apps/mobile/src/session/ComposerFrame.ios.tsx, apps/mobile/src/session/ComposerFrame.tsx, apps/mobile/src/session/ComposerKeyboardAvoidingView.tsx, apps/mobile/src/session/ComposerMorphSource.ios.tsx, apps/mobile/src/session/ComposerMorphSource.tsx, apps/mobile/src/session/ComposerNativeInput.ios.tsx, apps/mobile/src/session/ComposerNativeInput.tsx, apps/mobile/src/session/ComposerNativeRow.ios.tsx, apps/mobile/src/session/ComposerNativeRow.tsx, apps/mobile/src/session/ComposerNativeSection.ios.tsx, apps/mobile/src/session/ComposerNativeSection.tsx, apps/mobile/src/session/ComposerRichInput.tsx, apps/mobile/src/session/ComposerSheet.ios.tsx, apps/mobile/src/session/ComposerSheet.tsx, apps/mobile/src/session/ContextSheet.ios.tsx, apps/mobile/src/session/ContextSheet.tsx, apps/mobile/src/session/ContextSheetCollabView.tsx, apps/mobile/src/session/ContextSheetGoalView.ios.tsx, apps/mobile/src/session/ContextSheetGoalView.tsx, apps/mobile/src/session/ContextSheetMediaViews.tsx, apps/mobile/src/session/ConversationSearchFilterSheet.tsx, apps/mobile/src/session/ConversationShareSvg.tsx, apps/mobile/src/session/ConversationShareWebView.tsx, apps/mobile/src/session/FailedScheduleNotice.tsx, apps/mobile/src/session/HomeChromeDrawer.tsx, apps/mobile/src/session/HomeChromeFrost.tsx, apps/mobile/src/session/HomeEntryProvider.tsx, apps/mobile/src/session/HomeGlassMenuPanel.tsx, apps/mobile/src/session/HomeHeaderGlassButton.ios.tsx, apps/mobile/src/session/HomeHeaderGlassButton.tsx, apps/mobile/src/session/HomeListVisuals.tsx, apps/mobile/src/session/HomeModeSwitch.tsx, apps/mobile/src/session/HomeNewTaskButton.tsx, apps/mobile/src/session/HomeProjectMachineLabel.tsx, apps/mobile/src/session/HomeSearchBar.tsx, apps/mobile/src/session/HomeSurface.tsx, apps/mobile/src/session/HomeUnreadContext.tsx, apps/mobile/src/session/ImageLightbox.tsx, apps/mobile/src/session/IncomingShareBridge.tsx, apps/mobile/src/session/InlineQueueSection.tsx, apps/mobile/src/session/InlineQuoteChip.tsx, apps/mobile/src/session/InlineReferenceChip.tsx, apps/mobile/src/session/InteractionPanel.tsx, apps/mobile/src/session/MarkdownBlockContent.tsx, apps/mobile/src/session/MessageActionSheet.tsx, apps/mobile/src/session/MessageRenderer.tsx, apps/mobile/src/session/MobileAgentSwitcher.tsx, apps/mobile/src/session/MobileBoundaryNotice.tsx, apps/mobile/src/session/MobileComposerInputRow.tsx, apps/mobile/src/session/MobileModelPickerList.ios.tsx, apps/mobile/src/session/MobileModelPickerList.tsx, apps/mobile/src/session/MobileOutboxBridge.tsx, apps/mobile/src/session/MobilePermissionPickerList.ios.tsx, apps/mobile/src/session/MobilePermissionPickerList.tsx, apps/mobile/src/session/MobileProviderMark.tsx, apps/mobile/src/session/ModelOptionsSheetView.ios.tsx, apps/mobile/src/session/ModelOptionsSheetView.tsx, apps/mobile/src/session/ModelPickerNativeHeader.ios.tsx, apps/mobile/src/session/ModelPickerNativeHeader.tsx, apps/mobile/src/session/ModelPickerSheet.tsx, apps/mobile/src/session/MountOnFirstOpen.tsx, apps/mobile/src/session/NativePermissionSheet.ios.tsx, apps/mobile/src/session/NativePermissionSheet.tsx, apps/mobile/src/session/NativeResidentHistory.tsx, apps/mobile/src/session/PendingSendBubble.tsx, apps/mobile/src/session/PlanModeChip.tsx, apps/mobile/src/session/PluginInvocationHeader.tsx, apps/mobile/src/session/PromptRecommendation.tsx, apps/mobile/src/session/QuoteCapsule.tsx, apps/mobile/src/session/RecentMessageHistories.tsx, apps/mobile/src/session/RemoteTaskSuggestions.tsx, apps/mobile/src/session/RenameSessionModal.tsx, apps/mobile/src/session/ResidentHomeList.tsx, apps/mobile/src/session/RewindPreviewPanel.tsx, apps/mobile/src/session/RunningTokenRatePopover.tsx, apps/mobile/src/session/SentInlineAtomBody.tsx, apps/mobile/src/session/SessionActionSheet.tsx, apps/mobile/src/session/SessionDetailsNative.ios.tsx, apps/mobile/src/session/SessionDetailsNative.tsx, apps/mobile/src/session/SessionHeaderNativeControls.ios.tsx, apps/mobile/src/session/SessionHeaderNativeControls.tsx, apps/mobile/src/session/SessionListDrawer.tsx, apps/mobile/src/session/SessionMenuSheet.tsx, apps/mobile/src/session/SessionOptionsExpoSheet.tsx, apps/mobile/src/session/SessionResourceCards.tsx, apps/mobile/src/session/SessionRightSpinner.tsx, apps/mobile/src/session/SessionSearchNative.ios.tsx, apps/mobile/src/session/SessionSearchNative.tsx, apps/mobile/src/session/SessionTailBanner.tsx, apps/mobile/src/session/SessionTransientNotice.tsx, apps/mobile/src/session/SessionUsageSummary.tsx, apps/mobile/src/session/ShareImageNativeButton.ios.tsx, apps/mobile/src/session/ShareImageNativeButton.tsx, apps/mobile/src/session/ShareMessageCheckbox.tsx, apps/mobile/src/session/ShareSelectAllButton.tsx, apps/mobile/src/session/ShareSelectionBar.tsx, apps/mobile/src/session/SharedTaskAdmissionDialog.tsx, apps/mobile/src/session/SharedTaskEndedState.tsx, apps/mobile/src/session/SharedTaskScreen.tsx, apps/mobile/src/session/SheetModal.tsx, apps/mobile/src/session/SheetSurface.tsx, apps/mobile/src/session/SlowSendNotice.tsx, apps/mobile/src/session/StreamingStatusText.tsx, apps/mobile/src/session/SwipeableSessionRow.ios.tsx, apps/mobile/src/session/SwipeableSessionRow.tsx, apps/mobile/src/session/TaskTags.tsx, apps/mobile/src/session/TaskTagsSheet.tsx, apps/mobile/src/session/ThinkingDots.tsx, apps/mobile/src/session/UnifiedModelPickerSheet.tsx, apps/mobile/src/session/UnifiedModelPickerView.ios.tsx, apps/mobile/src/session/UnifiedModelPickerView.tsx, apps/mobile/src/session/VoiceRecordingPill.tsx, apps/mobile/src/session/WorkingStatusText.tsx, apps/mobile/src/session/composerRichInputHtml.ts, apps/mobile/src/session/conversationShareWebViewHtml.ts, apps/mobile/src/session/listDisclosureTransition.tsx, apps/mobile/src/session/mathWebView.tsx, apps/mobile/src/session/mathWebViewHtml.ts, apps/mobile/src/session/mediaPlayerWebView.tsx, apps/mobile/src/session/mediaPlayerWebViewHtml.ts, apps/mobile/src/session/mermaidWebView.tsx, apps/mobile/src/session/mermaidWebViewHtml.ts, apps/mobile/src/session/selectableMarkdownHtml.ts, apps/mobile/src/session/useSharedTaskConfirmation.tsx, apps/mobile/src/session/voicePillWidthMotion.tsx, apps/mobile/src/theme/ThemeProvider.tsx, apps/mobile/src/theme/navigationTheme.ts, apps/mobile/src/theme/tokens.ts, apps/mobile/src/update/AndroidUpdateSheet.tsx | 7 | 243 | 300 |
| `mobile.chat.sharing` | mobile | 共享任务邀请与成员 | app/shared-session.tsx | AdaptiveWindow, AnchoredPullDownMenu, AndroidUpdateSheet, AppText, AuthContext, BlurBackdrop, CenteredScreen, ClipboardSharedTaskPrompt, ComposerNativeSection, ComposerNativeSection.ios, ComposerSheet, ComposerSheet.ios, ConnectionBanner, ConnectionNoticeOverlay, ContextSheet, ContextSheet.ios, DeviceLinkContext, FoldTouchpad, HomeEntryProvider, IncomingShareBridge, MobileLoginHandoffContext, MobileLoginHandoffStage, MobileOutboxBridge, MobilePrimitives, NativeChromeBackButton.ios, NativeChromeButton.ios, NativePullDownMenu, NativeRemoteDesktopView, NativeResidentHistory, NativeSwitch, OutsideTap, PermissionGuide, PermissionGuideView, PermissionGuideView.ios, PushNotificationsBridge, QuietSyncIndicator, RecentMessageHistories, RemoteDesktopActionButton, RemoteDesktopActionButton.ios, RemoteDesktopBackButton, RemoteDesktopBackButton.ios, RemoteDesktopChrome, RemoteDesktopChrome.ios, RemoteDesktopClipboardButton, RemoteDesktopControls, RemoteDesktopDisplaySettings, RemoteDesktopHost, RemoteDesktopIcons, RemoteDesktopMouseControls, RemoteDesktopMouseControls.ios, RemoteDesktopNetworkStatus, RemoteDesktopPanelButton, RemoteDesktopPanelButton.ios, RemoteDesktopScreen, RemoteDesktopSecuritySettings, RemoteDesktopWindows, ResidentHomeList, SharedTaskAdmissionDialog, SharedTaskEndedState, SharedTaskScreen, SheetModal, SheetSurface, SimpleStackHeader, StartupSplashOverlay, ThemeProvider, _layout, gestureHandler, peerFileTransport, shared-session, useLocale, useSharedTaskConfirmation | apps/mobile/app/_layout.tsx, apps/mobile/app/shared-session.tsx, apps/mobile/src/auth/AuthContext.tsx, apps/mobile/src/auth/MobileLoginHandoffContext.tsx, apps/mobile/src/components/AppText.tsx, apps/mobile/src/components/CenteredScreen.tsx, apps/mobile/src/components/ConnectionBanner.tsx, apps/mobile/src/components/ConnectionNoticeOverlay.tsx, apps/mobile/src/components/MobileLoginHandoffStage.tsx, apps/mobile/src/components/MobilePrimitives.tsx, apps/mobile/src/components/QuietSyncIndicator.tsx, apps/mobile/src/components/StartupSplashOverlay.tsx, apps/mobile/src/device-link/DeviceLinkContext.tsx, apps/mobile/src/device-link/peerFileTransport.tsx, apps/mobile/src/i18n/useLocale.tsx, apps/mobile/src/notifications/PushNotificationsBridge.tsx, apps/mobile/src/platform/AdaptiveWindow.tsx, apps/mobile/src/platform/OutsideTap.tsx, apps/mobile/src/platform/chrome/AnchoredPullDownMenu.tsx, apps/mobile/src/platform/chrome/NativeChromeBackButton.ios.tsx, apps/mobile/src/platform/chrome/NativeChromeButton.ios.tsx, apps/mobile/src/platform/chrome/NativePullDownMenu.tsx, apps/mobile/src/platform/chrome/NativeSwitch.tsx, apps/mobile/src/platform/chrome/SimpleStackHeader.tsx, apps/mobile/src/platform/gestureHandler.tsx, apps/mobile/src/remote-desktop/FoldTouchpad.tsx, apps/mobile/src/remote-desktop/NativeRemoteDesktopView.tsx, apps/mobile/src/remote-desktop/PermissionGuide.tsx, apps/mobile/src/remote-desktop/PermissionGuideView.ios.tsx, apps/mobile/src/remote-desktop/PermissionGuideView.tsx, apps/mobile/src/remote-desktop/RemoteDesktopActionButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopActionButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopBackButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopBackButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopChrome.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopChrome.tsx, apps/mobile/src/remote-desktop/RemoteDesktopClipboardButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopControls.tsx, apps/mobile/src/remote-desktop/RemoteDesktopDisplaySettings.tsx, apps/mobile/src/remote-desktop/RemoteDesktopHost.tsx, apps/mobile/src/remote-desktop/RemoteDesktopIcons.tsx, apps/mobile/src/remote-desktop/RemoteDesktopMouseControls.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopMouseControls.tsx, apps/mobile/src/remote-desktop/RemoteDesktopNetworkStatus.tsx, apps/mobile/src/remote-desktop/RemoteDesktopPanelButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopPanelButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopScreen.tsx, apps/mobile/src/remote-desktop/RemoteDesktopSecuritySettings.tsx, apps/mobile/src/remote-desktop/RemoteDesktopWindows.tsx, apps/mobile/src/remote-desktop/viewerHtml.ts, apps/mobile/src/session/BlurBackdrop.tsx, apps/mobile/src/session/ClipboardSharedTaskPrompt.tsx, apps/mobile/src/session/ComposerNativeSection.ios.tsx, apps/mobile/src/session/ComposerNativeSection.tsx, apps/mobile/src/session/ComposerSheet.ios.tsx, apps/mobile/src/session/ComposerSheet.tsx, apps/mobile/src/session/ContextSheet.ios.tsx, apps/mobile/src/session/ContextSheet.tsx, apps/mobile/src/session/HomeEntryProvider.tsx, apps/mobile/src/session/IncomingShareBridge.tsx, apps/mobile/src/session/MobileOutboxBridge.tsx, apps/mobile/src/session/NativeResidentHistory.tsx, apps/mobile/src/session/RecentMessageHistories.tsx, apps/mobile/src/session/ResidentHomeList.tsx, apps/mobile/src/session/SharedTaskAdmissionDialog.tsx, apps/mobile/src/session/SharedTaskEndedState.tsx, apps/mobile/src/session/SharedTaskScreen.tsx, apps/mobile/src/session/SheetModal.tsx, apps/mobile/src/session/SheetSurface.tsx, apps/mobile/src/session/useSharedTaskConfirmation.tsx, apps/mobile/src/theme/ThemeProvider.tsx, apps/mobile/src/theme/navigationTheme.ts, apps/mobile/src/theme/tokens.ts, apps/mobile/src/update/AndroidUpdateSheet.tsx | 0 | 210 | 68 |
| `mobile.companions.direct` | mobile | 伙伴私聊回看 | app/companions/direct/[threadId].tsx | AdaptiveWindow, AnchoredPullDownMenu, AndroidUpdateSheet, AppText, AuthContext, BlurBackdrop, CenteredScreen, ClipboardSharedTaskPrompt, ComposerNativeSection, ComposerNativeSection.ios, ComposerSheet, ComposerSheet.ios, ConnectionBanner, ConnectionNoticeOverlay, ContextSheet, ContextSheet.ios, DeviceLinkContext, FoldTouchpad, HomeEntryProvider, HomeHeaderGlassButton, HomeHeaderGlassButton.ios, HomeNativeStackHeader, IncomingShareBridge, MobileLoginHandoffContext, MobileLoginHandoffStage, MobileOutboxBridge, MobilePrimitives, NativeChromeBackButton.ios, NativeChromeButton.ios, NativePullDownMenu, NativeRemoteDesktopView, NativeResidentHistory, NativeSwitch, OutsideTap, PermissionGuide, PermissionGuideView, PermissionGuideView.ios, PushNotificationsBridge, QuietSyncIndicator, RecentMessageHistories, RemoteCompanionAvatar, RemoteDesktopActionButton, RemoteDesktopActionButton.ios, RemoteDesktopBackButton, RemoteDesktopBackButton.ios, RemoteDesktopChrome, RemoteDesktopChrome.ios, RemoteDesktopClipboardButton, RemoteDesktopControls, RemoteDesktopDisplaySettings, RemoteDesktopHost, RemoteDesktopIcons, RemoteDesktopMouseControls, RemoteDesktopMouseControls.ios, RemoteDesktopNetworkStatus, RemoteDesktopPanelButton, RemoteDesktopPanelButton.ios, RemoteDesktopScreen, RemoteDesktopSecuritySettings, RemoteDesktopWindows, ResidentHomeList, SharedTaskAdmissionDialog, SharedTaskScreen, SheetModal, SheetSurface, SimpleStackHeader, StartupSplashOverlay, ThemeProvider, [threadId], _layout, gestureHandler, peerFileTransport, useLocale | apps/mobile/app/_layout.tsx, apps/mobile/app/companions/direct/[threadId].tsx, apps/mobile/src/auth/AuthContext.tsx, apps/mobile/src/auth/MobileLoginHandoffContext.tsx, apps/mobile/src/components/AppText.tsx, apps/mobile/src/components/CenteredScreen.tsx, apps/mobile/src/components/ConnectionBanner.tsx, apps/mobile/src/components/ConnectionNoticeOverlay.tsx, apps/mobile/src/components/MobileLoginHandoffStage.tsx, apps/mobile/src/components/MobilePrimitives.tsx, apps/mobile/src/components/QuietSyncIndicator.tsx, apps/mobile/src/components/RemoteCompanionAvatar.tsx, apps/mobile/src/components/StartupSplashOverlay.tsx, apps/mobile/src/device-link/DeviceLinkContext.tsx, apps/mobile/src/device-link/peerFileTransport.tsx, apps/mobile/src/i18n/useLocale.tsx, apps/mobile/src/notifications/PushNotificationsBridge.tsx, apps/mobile/src/platform/AdaptiveWindow.tsx, apps/mobile/src/platform/OutsideTap.tsx, apps/mobile/src/platform/chrome/AnchoredPullDownMenu.tsx, apps/mobile/src/platform/chrome/HomeNativeStackHeader.tsx, apps/mobile/src/platform/chrome/NativeChromeBackButton.ios.tsx, apps/mobile/src/platform/chrome/NativeChromeButton.ios.tsx, apps/mobile/src/platform/chrome/NativePullDownMenu.tsx, apps/mobile/src/platform/chrome/NativeSwitch.tsx, apps/mobile/src/platform/chrome/SimpleStackHeader.tsx, apps/mobile/src/platform/gestureHandler.tsx, apps/mobile/src/remote-desktop/FoldTouchpad.tsx, apps/mobile/src/remote-desktop/NativeRemoteDesktopView.tsx, apps/mobile/src/remote-desktop/PermissionGuide.tsx, apps/mobile/src/remote-desktop/PermissionGuideView.ios.tsx, apps/mobile/src/remote-desktop/PermissionGuideView.tsx, apps/mobile/src/remote-desktop/RemoteDesktopActionButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopActionButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopBackButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopBackButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopChrome.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopChrome.tsx, apps/mobile/src/remote-desktop/RemoteDesktopClipboardButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopControls.tsx, apps/mobile/src/remote-desktop/RemoteDesktopDisplaySettings.tsx, apps/mobile/src/remote-desktop/RemoteDesktopHost.tsx, apps/mobile/src/remote-desktop/RemoteDesktopIcons.tsx, apps/mobile/src/remote-desktop/RemoteDesktopMouseControls.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopMouseControls.tsx, apps/mobile/src/remote-desktop/RemoteDesktopNetworkStatus.tsx, apps/mobile/src/remote-desktop/RemoteDesktopPanelButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopPanelButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopScreen.tsx, apps/mobile/src/remote-desktop/RemoteDesktopSecuritySettings.tsx, apps/mobile/src/remote-desktop/RemoteDesktopWindows.tsx, apps/mobile/src/remote-desktop/viewerHtml.ts, apps/mobile/src/session/BlurBackdrop.tsx, apps/mobile/src/session/ClipboardSharedTaskPrompt.tsx, apps/mobile/src/session/ComposerNativeSection.ios.tsx, apps/mobile/src/session/ComposerNativeSection.tsx, apps/mobile/src/session/ComposerSheet.ios.tsx, apps/mobile/src/session/ComposerSheet.tsx, apps/mobile/src/session/ContextSheet.ios.tsx, apps/mobile/src/session/ContextSheet.tsx, apps/mobile/src/session/HomeEntryProvider.tsx, apps/mobile/src/session/HomeHeaderGlassButton.ios.tsx, apps/mobile/src/session/HomeHeaderGlassButton.tsx, apps/mobile/src/session/IncomingShareBridge.tsx, apps/mobile/src/session/MobileOutboxBridge.tsx, apps/mobile/src/session/NativeResidentHistory.tsx, apps/mobile/src/session/RecentMessageHistories.tsx, apps/mobile/src/session/ResidentHomeList.tsx, apps/mobile/src/session/SharedTaskAdmissionDialog.tsx, apps/mobile/src/session/SharedTaskScreen.tsx, apps/mobile/src/session/SheetModal.tsx, apps/mobile/src/session/SheetSurface.tsx, apps/mobile/src/theme/ThemeProvider.tsx, apps/mobile/src/theme/navigationTheme.ts, apps/mobile/src/theme/tokens.ts, apps/mobile/src/update/AndroidUpdateSheet.tsx | 0 | 210 | 60 |
| `mobile.companions.groups` | mobile | 伙伴群聊与分工 | app/companions/groups/[groupId].tsx | AdaptiveWindow, AgentErrorDetails, AnchoredPullDownMenu, AndroidUpdateSheet, AppText, AuthContext, AuthorizationMessageCard, BlurBackdrop, BotGroupAvatars, BotGroupChatScreen, BotGroupComposer, BotGroupMenu, BotGroupMessageAttachments, BotGroupMessageText, BotGroupPlan, BotGroupSettingsSheet, BotGroupSpeakerRow, CenteredScreen, ChatIdentityHeader, ClipboardSharedTaskPrompt, CompanionCardButton, CompanionEntering, CompanionLearningFooter, CompanionMessageActions, CompanionMessageCard, CompanionPresenceRing, CompanionSheet, CompanionSheet.ios, CompanionTaskResultCard, ComposerAttachmentTray, ComposerFrame, ComposerFrame.ios, ComposerNativeSection, ComposerNativeSection.ios, ComposerSheet, ComposerSheet.ios, ConnectionBanner, ConnectionNoticeOverlay, ContextSheet, ContextSheet.ios, ContextSheetMediaViews, DeviceLinkContext, FileTypeIcon, FoldTouchpad, HomeEntryProvider, HomeHeaderGlassButton, HomeHeaderGlassButton.ios, HomeNativeStackHeader, ImageLightbox, IncomingShareBridge, InlineQuoteChip, InlineReferenceChip, InteractionPanel, MarkdownBlockContent, MessageActionSheet, MessageRenderer, MobileBoundaryNotice, MobileComposerInputRow, MobileLoginHandoffContext, MobileLoginHandoffStage, MobileOutboxBridge, MobilePrimitives, NativeChromeBackButton.ios, NativeChromeButton.ios, NativePullDownMenu, NativeRemoteDesktopView, NativeResidentHistory, NativeSwitch, OutsideTap, PaperPlaneIcon, PendingSendBubble, PermissionGuide, PermissionGuideView, PermissionGuideView.ios, PluginInvocationHeader, PushNotificationsBridge, QuietSyncIndicator, QuoteCapsule, RecentMessageHistories, RemoteCompanionAvatar, RemoteDesktopActionButton, RemoteDesktopActionButton.ios, RemoteDesktopBackButton, RemoteDesktopBackButton.ios, RemoteDesktopChrome, RemoteDesktopChrome.ios, RemoteDesktopClipboardButton, RemoteDesktopControls, RemoteDesktopDisplaySettings, RemoteDesktopHost, RemoteDesktopIcons, RemoteDesktopMouseControls, RemoteDesktopMouseControls.ios, RemoteDesktopNetworkStatus, RemoteDesktopPanelButton, RemoteDesktopPanelButton.ios, RemoteDesktopScreen, RemoteDesktopSecuritySettings, RemoteDesktopWindows, ResidentHomeList, SentInlineAtomBody, ShareMessageCheckbox, SharedTaskAdmissionDialog, SharedTaskScreen, SheetModal, SheetSurface, SimpleStackHeader, StartupSplashOverlay, StreamingStatusText, ThemeProvider, ThinkingDots, WorkingStatusText, [groupId], _layout, gestureHandler, mathWebView, mediaPlayerWebView, mermaidWebView, peerFileTransport, useLocale, voicePillWidthMotion | apps/mobile/app/_layout.tsx, apps/mobile/app/companions/groups/[groupId].tsx, apps/mobile/src/auth/AuthContext.tsx, apps/mobile/src/auth/MobileLoginHandoffContext.tsx, apps/mobile/src/components/AppText.tsx, apps/mobile/src/components/CenteredScreen.tsx, apps/mobile/src/components/ConnectionBanner.tsx, apps/mobile/src/components/ConnectionNoticeOverlay.tsx, apps/mobile/src/components/FileTypeIcon.tsx, apps/mobile/src/components/MobileLoginHandoffStage.tsx, apps/mobile/src/components/MobilePrimitives.tsx, apps/mobile/src/components/PaperPlaneIcon.tsx, apps/mobile/src/components/QuietSyncIndicator.tsx, apps/mobile/src/components/RemoteCompanionAvatar.tsx, apps/mobile/src/components/StartupSplashOverlay.tsx, apps/mobile/src/device-link/DeviceLinkContext.tsx, apps/mobile/src/device-link/peerFileTransport.tsx, apps/mobile/src/i18n/useLocale.tsx, apps/mobile/src/notifications/PushNotificationsBridge.tsx, apps/mobile/src/platform/AdaptiveWindow.tsx, apps/mobile/src/platform/OutsideTap.tsx, apps/mobile/src/platform/chrome/AnchoredPullDownMenu.tsx, apps/mobile/src/platform/chrome/HomeNativeStackHeader.tsx, apps/mobile/src/platform/chrome/NativeChromeBackButton.ios.tsx, apps/mobile/src/platform/chrome/NativeChromeButton.ios.tsx, apps/mobile/src/platform/chrome/NativePullDownMenu.tsx, apps/mobile/src/platform/chrome/NativeSwitch.tsx, apps/mobile/src/platform/chrome/SimpleStackHeader.tsx, apps/mobile/src/platform/gestureHandler.tsx, apps/mobile/src/remote-desktop/FoldTouchpad.tsx, apps/mobile/src/remote-desktop/NativeRemoteDesktopView.tsx, apps/mobile/src/remote-desktop/PermissionGuide.tsx, apps/mobile/src/remote-desktop/PermissionGuideView.ios.tsx, apps/mobile/src/remote-desktop/PermissionGuideView.tsx, apps/mobile/src/remote-desktop/RemoteDesktopActionButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopActionButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopBackButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopBackButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopChrome.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopChrome.tsx, apps/mobile/src/remote-desktop/RemoteDesktopClipboardButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopControls.tsx, apps/mobile/src/remote-desktop/RemoteDesktopDisplaySettings.tsx, apps/mobile/src/remote-desktop/RemoteDesktopHost.tsx, apps/mobile/src/remote-desktop/RemoteDesktopIcons.tsx, apps/mobile/src/remote-desktop/RemoteDesktopMouseControls.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopMouseControls.tsx, apps/mobile/src/remote-desktop/RemoteDesktopNetworkStatus.tsx, apps/mobile/src/remote-desktop/RemoteDesktopPanelButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopPanelButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopScreen.tsx, apps/mobile/src/remote-desktop/RemoteDesktopSecuritySettings.tsx, apps/mobile/src/remote-desktop/RemoteDesktopWindows.tsx, apps/mobile/src/remote-desktop/viewerHtml.ts, apps/mobile/src/session/AgentErrorDetails.tsx, apps/mobile/src/session/AuthorizationMessageCard.tsx, apps/mobile/src/session/BlurBackdrop.tsx, apps/mobile/src/session/BotGroupAvatars.tsx, apps/mobile/src/session/BotGroupChatScreen.tsx, apps/mobile/src/session/BotGroupComposer.tsx, apps/mobile/src/session/BotGroupMenu.tsx, apps/mobile/src/session/BotGroupMessageAttachments.tsx, apps/mobile/src/session/BotGroupMessageText.tsx, apps/mobile/src/session/BotGroupPlan.tsx, apps/mobile/src/session/BotGroupSettingsSheet.tsx, apps/mobile/src/session/BotGroupSpeakerRow.tsx, apps/mobile/src/session/ChatIdentityHeader.tsx, apps/mobile/src/session/ClipboardSharedTaskPrompt.tsx, apps/mobile/src/session/CompanionCardButton.tsx, apps/mobile/src/session/CompanionEntering.tsx, apps/mobile/src/session/CompanionLearningFooter.tsx, apps/mobile/src/session/CompanionMessageActions.tsx, apps/mobile/src/session/CompanionMessageCard.tsx, apps/mobile/src/session/CompanionPresenceRing.tsx, apps/mobile/src/session/CompanionSheet.ios.tsx, apps/mobile/src/session/CompanionSheet.tsx, apps/mobile/src/session/CompanionTaskResultCard.tsx, apps/mobile/src/session/ComposerAttachmentTray.tsx, apps/mobile/src/session/ComposerFrame.ios.tsx, apps/mobile/src/session/ComposerFrame.tsx, apps/mobile/src/session/ComposerNativeSection.ios.tsx, apps/mobile/src/session/ComposerNativeSection.tsx, apps/mobile/src/session/ComposerSheet.ios.tsx, apps/mobile/src/session/ComposerSheet.tsx, apps/mobile/src/session/ContextSheet.ios.tsx, apps/mobile/src/session/ContextSheet.tsx, apps/mobile/src/session/ContextSheetMediaViews.tsx, apps/mobile/src/session/HomeEntryProvider.tsx, apps/mobile/src/session/HomeHeaderGlassButton.ios.tsx, apps/mobile/src/session/HomeHeaderGlassButton.tsx, apps/mobile/src/session/ImageLightbox.tsx, apps/mobile/src/session/IncomingShareBridge.tsx, apps/mobile/src/session/InlineQuoteChip.tsx, apps/mobile/src/session/InlineReferenceChip.tsx, apps/mobile/src/session/InteractionPanel.tsx, apps/mobile/src/session/MarkdownBlockContent.tsx, apps/mobile/src/session/MessageActionSheet.tsx, apps/mobile/src/session/MessageRenderer.tsx, apps/mobile/src/session/MobileBoundaryNotice.tsx, apps/mobile/src/session/MobileComposerInputRow.tsx, apps/mobile/src/session/MobileOutboxBridge.tsx, apps/mobile/src/session/NativeResidentHistory.tsx, apps/mobile/src/session/PendingSendBubble.tsx, apps/mobile/src/session/PluginInvocationHeader.tsx, apps/mobile/src/session/QuoteCapsule.tsx, apps/mobile/src/session/RecentMessageHistories.tsx, apps/mobile/src/session/ResidentHomeList.tsx, apps/mobile/src/session/SentInlineAtomBody.tsx, apps/mobile/src/session/ShareMessageCheckbox.tsx, apps/mobile/src/session/SharedTaskAdmissionDialog.tsx, apps/mobile/src/session/SharedTaskScreen.tsx, apps/mobile/src/session/SheetModal.tsx, apps/mobile/src/session/SheetSurface.tsx, apps/mobile/src/session/StreamingStatusText.tsx, apps/mobile/src/session/ThinkingDots.tsx, apps/mobile/src/session/WorkingStatusText.tsx, apps/mobile/src/session/mathWebView.tsx, apps/mobile/src/session/mathWebViewHtml.ts, apps/mobile/src/session/mediaPlayerWebView.tsx, apps/mobile/src/session/mediaPlayerWebViewHtml.ts, apps/mobile/src/session/mermaidWebView.tsx, apps/mobile/src/session/mermaidWebViewHtml.ts, apps/mobile/src/session/voicePillWidthMotion.tsx, apps/mobile/src/theme/ThemeProvider.tsx, apps/mobile/src/theme/navigationTheme.ts, apps/mobile/src/theme/tokens.ts, apps/mobile/src/update/AndroidUpdateSheet.tsx | 0 | 242 | 183 |
| `mobile.device-management` | mobile | 设备管理 | app/devices/manage.tsx / app/devices/manage/[deviceId].tsx | AdaptiveWindow, AnchoredPullDownMenu, AndroidUpdateSheet, AppText, AuthContext, BlurBackdrop, CenteredScreen, ClipboardSharedTaskPrompt, ComposerNativeSection, ComposerNativeSection.ios, ComposerSheet, ComposerSheet.ios, ConnectionBanner, ConnectionNoticeOverlay, ContextSheet, ContextSheet.ios, DeviceInformationFields, DeviceInformationFields.ios, DeviceLinkContext, DeviceManagementDialogs, DeviceManagementList, DeviceManagementList.ios, FoldTouchpad, HomeEntryProvider, HomeHeaderGlassButton, HomeHeaderGlassButton.ios, HomeNativeStackHeader, IncomingShareBridge, MobileLoginHandoffContext, MobileLoginHandoffStage, MobileOutboxBridge, MobilePrimitives, ModalContentArea, NativeChromeBackButton.ios, NativeChromeButton.ios, NativePullDownMenu, NativeRemoteDesktopView, NativeResidentHistory, NativeSwitch, OutsideTap, PermissionGuide, PermissionGuideView, PermissionGuideView.ios, PushNotificationsBridge, QuietSyncIndicator, RecentMessageHistories, RemoteDesktopActionButton, RemoteDesktopActionButton.ios, RemoteDesktopBackButton, RemoteDesktopBackButton.ios, RemoteDesktopChrome, RemoteDesktopChrome.ios, RemoteDesktopClipboardButton, RemoteDesktopControls, RemoteDesktopDisplaySettings, RemoteDesktopHost, RemoteDesktopIcons, RemoteDesktopMouseControls, RemoteDesktopMouseControls.ios, RemoteDesktopNetworkStatus, RemoteDesktopPanelButton, RemoteDesktopPanelButton.ios, RemoteDesktopScreen, RemoteDesktopSecuritySettings, RemoteDesktopWindows, RenameDeviceModal, ResidentHomeList, SettingsGroupRows, SharedTaskAdmissionDialog, SharedTaskScreen, SheetModal, SheetSurface, SimpleStackHeader, StartupSplashOverlay, ThemeProvider, [deviceId], _layout, gestureHandler, listDisclosureTransition, manage, peerFileTransport, useLocale | apps/mobile/app/_layout.tsx, apps/mobile/app/devices/manage.tsx, apps/mobile/app/devices/manage/[deviceId].tsx, apps/mobile/src/auth/AuthContext.tsx, apps/mobile/src/auth/MobileLoginHandoffContext.tsx, apps/mobile/src/components/AppText.tsx, apps/mobile/src/components/CenteredScreen.tsx, apps/mobile/src/components/ConnectionBanner.tsx, apps/mobile/src/components/ConnectionNoticeOverlay.tsx, apps/mobile/src/components/MobileLoginHandoffStage.tsx, apps/mobile/src/components/MobilePrimitives.tsx, apps/mobile/src/components/QuietSyncIndicator.tsx, apps/mobile/src/components/StartupSplashOverlay.tsx, apps/mobile/src/device-link/DeviceInformationFields.ios.tsx, apps/mobile/src/device-link/DeviceInformationFields.tsx, apps/mobile/src/device-link/DeviceLinkContext.tsx, apps/mobile/src/device-link/DeviceManagementDialogs.tsx, apps/mobile/src/device-link/DeviceManagementList.ios.tsx, apps/mobile/src/device-link/DeviceManagementList.tsx, apps/mobile/src/device-link/peerFileTransport.tsx, apps/mobile/src/i18n/useLocale.tsx, apps/mobile/src/notifications/PushNotificationsBridge.tsx, apps/mobile/src/platform/AdaptiveWindow.tsx, apps/mobile/src/platform/ModalContentArea.tsx, apps/mobile/src/platform/OutsideTap.tsx, apps/mobile/src/platform/chrome/AnchoredPullDownMenu.tsx, apps/mobile/src/platform/chrome/HomeNativeStackHeader.tsx, apps/mobile/src/platform/chrome/NativeChromeBackButton.ios.tsx, apps/mobile/src/platform/chrome/NativeChromeButton.ios.tsx, apps/mobile/src/platform/chrome/NativePullDownMenu.tsx, apps/mobile/src/platform/chrome/NativeSwitch.tsx, apps/mobile/src/platform/chrome/SimpleStackHeader.tsx, apps/mobile/src/platform/gestureHandler.tsx, apps/mobile/src/remote-desktop/FoldTouchpad.tsx, apps/mobile/src/remote-desktop/NativeRemoteDesktopView.tsx, apps/mobile/src/remote-desktop/PermissionGuide.tsx, apps/mobile/src/remote-desktop/PermissionGuideView.ios.tsx, apps/mobile/src/remote-desktop/PermissionGuideView.tsx, apps/mobile/src/remote-desktop/RemoteDesktopActionButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopActionButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopBackButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopBackButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopChrome.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopChrome.tsx, apps/mobile/src/remote-desktop/RemoteDesktopClipboardButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopControls.tsx, apps/mobile/src/remote-desktop/RemoteDesktopDisplaySettings.tsx, apps/mobile/src/remote-desktop/RemoteDesktopHost.tsx, apps/mobile/src/remote-desktop/RemoteDesktopIcons.tsx, apps/mobile/src/remote-desktop/RemoteDesktopMouseControls.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopMouseControls.tsx, apps/mobile/src/remote-desktop/RemoteDesktopNetworkStatus.tsx, apps/mobile/src/remote-desktop/RemoteDesktopPanelButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopPanelButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopScreen.tsx, apps/mobile/src/remote-desktop/RemoteDesktopSecuritySettings.tsx, apps/mobile/src/remote-desktop/RemoteDesktopWindows.tsx, apps/mobile/src/remote-desktop/viewerHtml.ts, apps/mobile/src/session/BlurBackdrop.tsx, apps/mobile/src/session/ClipboardSharedTaskPrompt.tsx, apps/mobile/src/session/ComposerNativeSection.ios.tsx, apps/mobile/src/session/ComposerNativeSection.tsx, apps/mobile/src/session/ComposerSheet.ios.tsx, apps/mobile/src/session/ComposerSheet.tsx, apps/mobile/src/session/ContextSheet.ios.tsx, apps/mobile/src/session/ContextSheet.tsx, apps/mobile/src/session/HomeEntryProvider.tsx, apps/mobile/src/session/HomeHeaderGlassButton.ios.tsx, apps/mobile/src/session/HomeHeaderGlassButton.tsx, apps/mobile/src/session/IncomingShareBridge.tsx, apps/mobile/src/session/MobileOutboxBridge.tsx, apps/mobile/src/session/NativeResidentHistory.tsx, apps/mobile/src/session/RecentMessageHistories.tsx, apps/mobile/src/session/RenameDeviceModal.tsx, apps/mobile/src/session/ResidentHomeList.tsx, apps/mobile/src/session/SettingsGroupRows.tsx, apps/mobile/src/session/SharedTaskAdmissionDialog.tsx, apps/mobile/src/session/SharedTaskScreen.tsx, apps/mobile/src/session/SheetModal.tsx, apps/mobile/src/session/SheetSurface.tsx, apps/mobile/src/session/listDisclosureTransition.tsx, apps/mobile/src/theme/ThemeProvider.tsx, apps/mobile/src/theme/navigationTheme.ts, apps/mobile/src/theme/tokens.ts, apps/mobile/src/update/AndroidUpdateSheet.tsx | 0 | 210 | 60 |
-| `mobile.devices` | mobile | 主机详情 | app/devices/[deviceId].tsx | AccountSwitcherSheet, AdaptiveWindow, AnchoredPullDownMenu, AndroidUpdateSheet, AppText, AuthContext, AutomationTimerIcon, BlurBackdrop, CenteredScreen, ClipboardSharedTaskPrompt, ComposerMorphSource, ComposerMorphSource.ios, ComposerNativeRow, ComposerNativeRow.ios, ComposerNativeSection, ComposerNativeSection.ios, ComposerSheet, ComposerSheet.ios, ConnectionBanner, ConnectionNoticeOverlay, ContextSheet, ContextSheet.ios, ConversationSearchFilterSheet, DeviceLinkContext, FoldTouchpad, HomeChromeDrawer, HomeChromeFrost, HomeEntryProvider, HomeGlassMenuPanel, HomeHeaderGlassButton, HomeHeaderGlassButton.ios, HomeListVisuals, HomeModeSwitch, HomeNativeStackHeader, HomeNewTaskButton, HomeProjectMachineLabel, HomeSearchBar, HomeSurface, HomeUnreadContext, IncomingShareBridge, MobileAgentMark, MobileLoginHandoffContext, MobileLoginHandoffStage, MobileOutboxBridge, MobilePrimitives, MobileUserAvatar, MobileVendorIcon, ModalContentArea, NativeChromeBackButton.ios, NativeChromeButton.ios, NativePullDownMenu, NativeRemoteDesktopView, NativeResidentHistory, NativeSwitch, OutsideTap, PermissionGuide, PermissionGuideView, PermissionGuideView.ios, PushNotificationsBridge, QuietSyncIndicator, RecentMessageHistories, RemoteAccessGuide, RemoteDesktopActionButton, RemoteDesktopActionButton.ios, RemoteDesktopBackButton, RemoteDesktopBackButton.ios, RemoteDesktopChrome, RemoteDesktopChrome.ios, RemoteDesktopClipboardButton, RemoteDesktopControls, RemoteDesktopDisplaySettings, RemoteDesktopHost, RemoteDesktopIcons, RemoteDesktopMouseControls, RemoteDesktopMouseControls.ios, RemoteDesktopNetworkStatus, RemoteDesktopPanelButton, RemoteDesktopPanelButton.ios, RemoteDesktopScreen, RemoteDesktopSecuritySettings, RemoteDesktopWindows, RemoteTaskSuggestions, RenameSessionModal, ResidentHomeList, SessionActionSheet, SessionDetailsNative, SessionDetailsNative.ios, SessionHeaderNativeControls, SessionHeaderNativeControls.ios, SessionOptionsExpoSheet, SessionRightSpinner, SharedTaskAdmissionDialog, SharedTaskScreen, SheetModal, SheetSurface, SimpleStackHeader, StartupSplashOverlay, SwipeableSessionRow, SwipeableSessionRow.ios, TaskTags, ThemeProvider, [deviceId], _layout, gestureHandler, listDisclosureTransition, peerFileTransport, useLocale | apps/mobile/app/_layout.tsx, apps/mobile/app/devices/[deviceId].tsx, apps/mobile/src/auth/AuthContext.tsx, apps/mobile/src/auth/MobileLoginHandoffContext.tsx, apps/mobile/src/components/AppText.tsx, apps/mobile/src/components/CenteredScreen.tsx, apps/mobile/src/components/ConnectionBanner.tsx, apps/mobile/src/components/ConnectionNoticeOverlay.tsx, apps/mobile/src/components/MobileAgentMark.tsx, apps/mobile/src/components/MobileLoginHandoffStage.tsx, apps/mobile/src/components/MobilePrimitives.tsx, apps/mobile/src/components/MobileUserAvatar.tsx, apps/mobile/src/components/MobileVendorIcon.tsx, apps/mobile/src/components/QuietSyncIndicator.tsx, apps/mobile/src/components/RemoteAccessGuide.tsx, apps/mobile/src/components/StartupSplashOverlay.tsx, apps/mobile/src/device-link/DeviceLinkContext.tsx, apps/mobile/src/device-link/peerFileTransport.tsx, apps/mobile/src/i18n/useLocale.tsx, apps/mobile/src/notifications/PushNotificationsBridge.tsx, apps/mobile/src/platform/AdaptiveWindow.tsx, apps/mobile/src/platform/ModalContentArea.tsx, apps/mobile/src/platform/OutsideTap.tsx, apps/mobile/src/platform/chrome/AnchoredPullDownMenu.tsx, apps/mobile/src/platform/chrome/HomeNativeStackHeader.tsx, apps/mobile/src/platform/chrome/NativeChromeBackButton.ios.tsx, apps/mobile/src/platform/chrome/NativeChromeButton.ios.tsx, apps/mobile/src/platform/chrome/NativePullDownMenu.tsx, apps/mobile/src/platform/chrome/NativeSwitch.tsx, apps/mobile/src/platform/chrome/SimpleStackHeader.tsx, apps/mobile/src/platform/gestureHandler.tsx, apps/mobile/src/remote-desktop/FoldTouchpad.tsx, apps/mobile/src/remote-desktop/NativeRemoteDesktopView.tsx, apps/mobile/src/remote-desktop/PermissionGuide.tsx, apps/mobile/src/remote-desktop/PermissionGuideView.ios.tsx, apps/mobile/src/remote-desktop/PermissionGuideView.tsx, apps/mobile/src/remote-desktop/RemoteDesktopActionButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopActionButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopBackButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopBackButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopChrome.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopChrome.tsx, apps/mobile/src/remote-desktop/RemoteDesktopClipboardButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopControls.tsx, apps/mobile/src/remote-desktop/RemoteDesktopDisplaySettings.tsx, apps/mobile/src/remote-desktop/RemoteDesktopHost.tsx, apps/mobile/src/remote-desktop/RemoteDesktopIcons.tsx, apps/mobile/src/remote-desktop/RemoteDesktopMouseControls.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopMouseControls.tsx, apps/mobile/src/remote-desktop/RemoteDesktopNetworkStatus.tsx, apps/mobile/src/remote-desktop/RemoteDesktopPanelButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopPanelButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopScreen.tsx, apps/mobile/src/remote-desktop/RemoteDesktopSecuritySettings.tsx, apps/mobile/src/remote-desktop/RemoteDesktopWindows.tsx, apps/mobile/src/remote-desktop/viewerHtml.ts, apps/mobile/src/session/AccountSwitcherSheet.tsx, apps/mobile/src/session/AutomationTimerIcon.tsx, apps/mobile/src/session/BlurBackdrop.tsx, apps/mobile/src/session/ClipboardSharedTaskPrompt.tsx, apps/mobile/src/session/ComposerMorphSource.ios.tsx, apps/mobile/src/session/ComposerMorphSource.tsx, apps/mobile/src/session/ComposerNativeRow.ios.tsx, apps/mobile/src/session/ComposerNativeRow.tsx, apps/mobile/src/session/ComposerNativeSection.ios.tsx, apps/mobile/src/session/ComposerNativeSection.tsx, apps/mobile/src/session/ComposerSheet.ios.tsx, apps/mobile/src/session/ComposerSheet.tsx, apps/mobile/src/session/ContextSheet.ios.tsx, apps/mobile/src/session/ContextSheet.tsx, apps/mobile/src/session/ConversationSearchFilterSheet.tsx, apps/mobile/src/session/HomeChromeDrawer.tsx, apps/mobile/src/session/HomeChromeFrost.tsx, apps/mobile/src/session/HomeEntryProvider.tsx, apps/mobile/src/session/HomeGlassMenuPanel.tsx, apps/mobile/src/session/HomeHeaderGlassButton.ios.tsx, apps/mobile/src/session/HomeHeaderGlassButton.tsx, apps/mobile/src/session/HomeListVisuals.tsx, apps/mobile/src/session/HomeModeSwitch.tsx, apps/mobile/src/session/HomeNewTaskButton.tsx, apps/mobile/src/session/HomeProjectMachineLabel.tsx, apps/mobile/src/session/HomeSearchBar.tsx, apps/mobile/src/session/HomeSurface.tsx, apps/mobile/src/session/HomeUnreadContext.tsx, apps/mobile/src/session/IncomingShareBridge.tsx, apps/mobile/src/session/MobileOutboxBridge.tsx, apps/mobile/src/session/NativeResidentHistory.tsx, apps/mobile/src/session/RecentMessageHistories.tsx, apps/mobile/src/session/RemoteTaskSuggestions.tsx, apps/mobile/src/session/RenameSessionModal.tsx, apps/mobile/src/session/ResidentHomeList.tsx, apps/mobile/src/session/SessionActionSheet.tsx, apps/mobile/src/session/SessionDetailsNative.ios.tsx, apps/mobile/src/session/SessionDetailsNative.tsx, apps/mobile/src/session/SessionHeaderNativeControls.ios.tsx, apps/mobile/src/session/SessionHeaderNativeControls.tsx, apps/mobile/src/session/SessionOptionsExpoSheet.tsx, apps/mobile/src/session/SessionRightSpinner.tsx, apps/mobile/src/session/SharedTaskAdmissionDialog.tsx, apps/mobile/src/session/SharedTaskScreen.tsx, apps/mobile/src/session/SheetModal.tsx, apps/mobile/src/session/SheetSurface.tsx, apps/mobile/src/session/SwipeableSessionRow.ios.tsx, apps/mobile/src/session/SwipeableSessionRow.tsx, apps/mobile/src/session/TaskTags.tsx, apps/mobile/src/session/listDisclosureTransition.tsx, apps/mobile/src/theme/ThemeProvider.tsx, apps/mobile/src/theme/navigationTheme.ts, apps/mobile/src/theme/tokens.ts, apps/mobile/src/update/AndroidUpdateSheet.tsx | 0 | 210 | 111 |
+| `mobile.devices` | mobile | 主机详情 | app/devices/[deviceId].tsx | AccountSwitcherSheet, AdaptiveWindow, AnchoredPullDownMenu, AndroidUpdateSheet, AppText, AuthContext, AutomationTimerIcon, BlurBackdrop, CenteredScreen, ClipboardSharedTaskPrompt, ComposerMorphSource, ComposerMorphSource.ios, ComposerNativeRow, ComposerNativeRow.ios, ComposerNativeSection, ComposerNativeSection.ios, ComposerSheet, ComposerSheet.ios, ConnectionBanner, ConnectionNoticeOverlay, ContextSheet, ContextSheet.ios, ConversationSearchFilterSheet, DeviceLinkContext, FoldTouchpad, HomeChromeDrawer, HomeChromeFrost, HomeEntryProvider, HomeGlassMenuPanel, HomeHeaderGlassButton, HomeHeaderGlassButton.ios, HomeListVisuals, HomeModeSwitch, HomeNativeStackHeader, HomeNewTaskButton, HomeProjectMachineLabel, HomeSearchBar, HomeSurface, HomeUnreadContext, IncomingShareBridge, MobileAgentMark, MobileLoginHandoffContext, MobileLoginHandoffStage, MobileOutboxBridge, MobilePrimitives, MobileUserAvatar, MobileVendorIcon, ModalContentArea, MountOnFirstOpen, NativeChromeBackButton.ios, NativeChromeButton.ios, NativePullDownMenu, NativeRemoteDesktopView, NativeResidentHistory, NativeSwitch, OutsideTap, PermissionGuide, PermissionGuideView, PermissionGuideView.ios, PushNotificationsBridge, QuietSyncIndicator, RecentMessageHistories, RemoteAccessGuide, RemoteDesktopActionButton, RemoteDesktopActionButton.ios, RemoteDesktopBackButton, RemoteDesktopBackButton.ios, RemoteDesktopChrome, RemoteDesktopChrome.ios, RemoteDesktopClipboardButton, RemoteDesktopControls, RemoteDesktopDisplaySettings, RemoteDesktopHost, RemoteDesktopIcons, RemoteDesktopMouseControls, RemoteDesktopMouseControls.ios, RemoteDesktopNetworkStatus, RemoteDesktopPanelButton, RemoteDesktopPanelButton.ios, RemoteDesktopScreen, RemoteDesktopSecuritySettings, RemoteDesktopWindows, RemoteTaskSuggestions, RenameSessionModal, ResidentHomeList, SessionActionSheet, SessionDetailsNative, SessionDetailsNative.ios, SessionHeaderNativeControls, SessionHeaderNativeControls.ios, SessionOptionsExpoSheet, SessionRightSpinner, SharedTaskAdmissionDialog, SharedTaskScreen, SheetModal, SheetSurface, SimpleStackHeader, StartupSplashOverlay, SwipeableSessionRow, SwipeableSessionRow.ios, TaskTags, ThemeProvider, [deviceId], _layout, gestureHandler, listDisclosureTransition, peerFileTransport, useLocale | apps/mobile/app/_layout.tsx, apps/mobile/app/devices/[deviceId].tsx, apps/mobile/src/auth/AuthContext.tsx, apps/mobile/src/auth/MobileLoginHandoffContext.tsx, apps/mobile/src/components/AppText.tsx, apps/mobile/src/components/CenteredScreen.tsx, apps/mobile/src/components/ConnectionBanner.tsx, apps/mobile/src/components/ConnectionNoticeOverlay.tsx, apps/mobile/src/components/MobileAgentMark.tsx, apps/mobile/src/components/MobileLoginHandoffStage.tsx, apps/mobile/src/components/MobilePrimitives.tsx, apps/mobile/src/components/MobileUserAvatar.tsx, apps/mobile/src/components/MobileVendorIcon.tsx, apps/mobile/src/components/QuietSyncIndicator.tsx, apps/mobile/src/components/RemoteAccessGuide.tsx, apps/mobile/src/components/StartupSplashOverlay.tsx, apps/mobile/src/device-link/DeviceLinkContext.tsx, apps/mobile/src/device-link/peerFileTransport.tsx, apps/mobile/src/i18n/useLocale.tsx, apps/mobile/src/notifications/PushNotificationsBridge.tsx, apps/mobile/src/platform/AdaptiveWindow.tsx, apps/mobile/src/platform/ModalContentArea.tsx, apps/mobile/src/platform/OutsideTap.tsx, apps/mobile/src/platform/chrome/AnchoredPullDownMenu.tsx, apps/mobile/src/platform/chrome/HomeNativeStackHeader.tsx, apps/mobile/src/platform/chrome/NativeChromeBackButton.ios.tsx, apps/mobile/src/platform/chrome/NativeChromeButton.ios.tsx, apps/mobile/src/platform/chrome/NativePullDownMenu.tsx, apps/mobile/src/platform/chrome/NativeSwitch.tsx, apps/mobile/src/platform/chrome/SimpleStackHeader.tsx, apps/mobile/src/platform/gestureHandler.tsx, apps/mobile/src/remote-desktop/FoldTouchpad.tsx, apps/mobile/src/remote-desktop/NativeRemoteDesktopView.tsx, apps/mobile/src/remote-desktop/PermissionGuide.tsx, apps/mobile/src/remote-desktop/PermissionGuideView.ios.tsx, apps/mobile/src/remote-desktop/PermissionGuideView.tsx, apps/mobile/src/remote-desktop/RemoteDesktopActionButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopActionButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopBackButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopBackButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopChrome.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopChrome.tsx, apps/mobile/src/remote-desktop/RemoteDesktopClipboardButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopControls.tsx, apps/mobile/src/remote-desktop/RemoteDesktopDisplaySettings.tsx, apps/mobile/src/remote-desktop/RemoteDesktopHost.tsx, apps/mobile/src/remote-desktop/RemoteDesktopIcons.tsx, apps/mobile/src/remote-desktop/RemoteDesktopMouseControls.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopMouseControls.tsx, apps/mobile/src/remote-desktop/RemoteDesktopNetworkStatus.tsx, apps/mobile/src/remote-desktop/RemoteDesktopPanelButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopPanelButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopScreen.tsx, apps/mobile/src/remote-desktop/RemoteDesktopSecuritySettings.tsx, apps/mobile/src/remote-desktop/RemoteDesktopWindows.tsx, apps/mobile/src/remote-desktop/viewerHtml.ts, apps/mobile/src/session/AccountSwitcherSheet.tsx, apps/mobile/src/session/AutomationTimerIcon.tsx, apps/mobile/src/session/BlurBackdrop.tsx, apps/mobile/src/session/ClipboardSharedTaskPrompt.tsx, apps/mobile/src/session/ComposerMorphSource.ios.tsx, apps/mobile/src/session/ComposerMorphSource.tsx, apps/mobile/src/session/ComposerNativeRow.ios.tsx, apps/mobile/src/session/ComposerNativeRow.tsx, apps/mobile/src/session/ComposerNativeSection.ios.tsx, apps/mobile/src/session/ComposerNativeSection.tsx, apps/mobile/src/session/ComposerSheet.ios.tsx, apps/mobile/src/session/ComposerSheet.tsx, apps/mobile/src/session/ContextSheet.ios.tsx, apps/mobile/src/session/ContextSheet.tsx, apps/mobile/src/session/ConversationSearchFilterSheet.tsx, apps/mobile/src/session/HomeChromeDrawer.tsx, apps/mobile/src/session/HomeChromeFrost.tsx, apps/mobile/src/session/HomeEntryProvider.tsx, apps/mobile/src/session/HomeGlassMenuPanel.tsx, apps/mobile/src/session/HomeHeaderGlassButton.ios.tsx, apps/mobile/src/session/HomeHeaderGlassButton.tsx, apps/mobile/src/session/HomeListVisuals.tsx, apps/mobile/src/session/HomeModeSwitch.tsx, apps/mobile/src/session/HomeNewTaskButton.tsx, apps/mobile/src/session/HomeProjectMachineLabel.tsx, apps/mobile/src/session/HomeSearchBar.tsx, apps/mobile/src/session/HomeSurface.tsx, apps/mobile/src/session/HomeUnreadContext.tsx, apps/mobile/src/session/IncomingShareBridge.tsx, apps/mobile/src/session/MobileOutboxBridge.tsx, apps/mobile/src/session/MountOnFirstOpen.tsx, apps/mobile/src/session/NativeResidentHistory.tsx, apps/mobile/src/session/RecentMessageHistories.tsx, apps/mobile/src/session/RemoteTaskSuggestions.tsx, apps/mobile/src/session/RenameSessionModal.tsx, apps/mobile/src/session/ResidentHomeList.tsx, apps/mobile/src/session/SessionActionSheet.tsx, apps/mobile/src/session/SessionDetailsNative.ios.tsx, apps/mobile/src/session/SessionDetailsNative.tsx, apps/mobile/src/session/SessionHeaderNativeControls.ios.tsx, apps/mobile/src/session/SessionHeaderNativeControls.tsx, apps/mobile/src/session/SessionOptionsExpoSheet.tsx, apps/mobile/src/session/SessionRightSpinner.tsx, apps/mobile/src/session/SharedTaskAdmissionDialog.tsx, apps/mobile/src/session/SharedTaskScreen.tsx, apps/mobile/src/session/SheetModal.tsx, apps/mobile/src/session/SheetSurface.tsx, apps/mobile/src/session/SwipeableSessionRow.ios.tsx, apps/mobile/src/session/SwipeableSessionRow.tsx, apps/mobile/src/session/TaskTags.tsx, apps/mobile/src/session/listDisclosureTransition.tsx, apps/mobile/src/theme/ThemeProvider.tsx, apps/mobile/src/theme/navigationTheme.ts, apps/mobile/src/theme/tokens.ts, apps/mobile/src/update/AndroidUpdateSheet.tsx | 0 | 210 | 111 |
| `mobile.files` | mobile | 任务文件与预览 | app/files/[sessionId].tsx / app/files/preview/[sessionId].tsx | AdaptiveWindow, AnchoredPullDownMenu, AndroidUpdateSheet, AppText, AuthContext, BlurBackdrop, CenteredScreen, ClipboardSharedTaskPrompt, ComposerNativeSection, ComposerNativeSection.ios, ComposerSheet, ComposerSheet.ios, ConnectionBanner, ConnectionNoticeOverlay, ContextSheet, ContextSheet.ios, DeviceLinkContext, FileBrowserSegmentedControl, FileTypeIcon, FileTypeTile, FoldTouchpad, HomeEntryProvider, HtmlBrowserChrome, HtmlBrowserChrome.ios, HtmlFileReader, HtmlWebsiteBrowser, ImageLightbox, IncomingShareBridge, MarkdownFileReader, MobileLoginHandoffContext, MobileLoginHandoffStage, MobileOutboxBridge, MobilePrimitives, ModalContentArea, NativeChromeBackButton.ios, NativeChromeButton.ios, NativePullDownMenu, NativeRemoteDesktopView, NativeResidentHistory, NativeSwitch, OutsideTap, PermissionGuide, PermissionGuideView, PermissionGuideView.ios, PushNotificationsBridge, QuietSyncIndicator, RecentMessageHistories, RemoteDesktopActionButton, RemoteDesktopActionButton.ios, RemoteDesktopBackButton, RemoteDesktopBackButton.ios, RemoteDesktopChrome, RemoteDesktopChrome.ios, RemoteDesktopClipboardButton, RemoteDesktopControls, RemoteDesktopDisplaySettings, RemoteDesktopHost, RemoteDesktopIcons, RemoteDesktopMouseControls, RemoteDesktopMouseControls.ios, RemoteDesktopNetworkStatus, RemoteDesktopPanelButton, RemoteDesktopPanelButton.ios, RemoteDesktopScreen, RemoteDesktopSecuritySettings, RemoteDesktopWindows, ResidentHomeList, SharedTaskAdmissionDialog, SharedTaskScreen, SheetModal, SheetSurface, SimpleStackHeader, StartupSplashOverlay, SystemNavigationBack, ThemeProvider, [sessionId], _layout, gestureHandler, mediaPlayerWebView, peerFileTransport, useLocale | apps/mobile/app/_layout.tsx, apps/mobile/app/files/[sessionId].tsx, apps/mobile/app/files/preview/[sessionId].tsx, apps/mobile/src/auth/AuthContext.tsx, apps/mobile/src/auth/MobileLoginHandoffContext.tsx, apps/mobile/src/components/AppText.tsx, apps/mobile/src/components/CenteredScreen.tsx, apps/mobile/src/components/ConnectionBanner.tsx, apps/mobile/src/components/ConnectionNoticeOverlay.tsx, apps/mobile/src/components/FileTypeIcon.tsx, apps/mobile/src/components/FileTypeTile.tsx, apps/mobile/src/components/MobileLoginHandoffStage.tsx, apps/mobile/src/components/MobilePrimitives.tsx, apps/mobile/src/components/QuietSyncIndicator.tsx, apps/mobile/src/components/StartupSplashOverlay.tsx, apps/mobile/src/device-link/DeviceLinkContext.tsx, apps/mobile/src/device-link/peerFileTransport.tsx, apps/mobile/src/i18n/useLocale.tsx, apps/mobile/src/notifications/PushNotificationsBridge.tsx, apps/mobile/src/platform/AdaptiveWindow.tsx, apps/mobile/src/platform/ModalContentArea.tsx, apps/mobile/src/platform/OutsideTap.tsx, apps/mobile/src/platform/chrome/AnchoredPullDownMenu.tsx, apps/mobile/src/platform/chrome/NativeChromeBackButton.ios.tsx, apps/mobile/src/platform/chrome/NativeChromeButton.ios.tsx, apps/mobile/src/platform/chrome/NativePullDownMenu.tsx, apps/mobile/src/platform/chrome/NativeSwitch.tsx, apps/mobile/src/platform/chrome/SimpleStackHeader.tsx, apps/mobile/src/platform/chrome/SystemNavigationBack.tsx, apps/mobile/src/platform/gestureHandler.tsx, apps/mobile/src/remote-desktop/FoldTouchpad.tsx, apps/mobile/src/remote-desktop/NativeRemoteDesktopView.tsx, apps/mobile/src/remote-desktop/PermissionGuide.tsx, apps/mobile/src/remote-desktop/PermissionGuideView.ios.tsx, apps/mobile/src/remote-desktop/PermissionGuideView.tsx, apps/mobile/src/remote-desktop/RemoteDesktopActionButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopActionButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopBackButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopBackButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopChrome.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopChrome.tsx, apps/mobile/src/remote-desktop/RemoteDesktopClipboardButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopControls.tsx, apps/mobile/src/remote-desktop/RemoteDesktopDisplaySettings.tsx, apps/mobile/src/remote-desktop/RemoteDesktopHost.tsx, apps/mobile/src/remote-desktop/RemoteDesktopIcons.tsx, apps/mobile/src/remote-desktop/RemoteDesktopMouseControls.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopMouseControls.tsx, apps/mobile/src/remote-desktop/RemoteDesktopNetworkStatus.tsx, apps/mobile/src/remote-desktop/RemoteDesktopPanelButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopPanelButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopScreen.tsx, apps/mobile/src/remote-desktop/RemoteDesktopSecuritySettings.tsx, apps/mobile/src/remote-desktop/RemoteDesktopWindows.tsx, apps/mobile/src/remote-desktop/viewerHtml.ts, apps/mobile/src/session/BlurBackdrop.tsx, apps/mobile/src/session/ClipboardSharedTaskPrompt.tsx, apps/mobile/src/session/ComposerNativeSection.ios.tsx, apps/mobile/src/session/ComposerNativeSection.tsx, apps/mobile/src/session/ComposerSheet.ios.tsx, apps/mobile/src/session/ComposerSheet.tsx, apps/mobile/src/session/ContextSheet.ios.tsx, apps/mobile/src/session/ContextSheet.tsx, apps/mobile/src/session/FileBrowserSegmentedControl.tsx, apps/mobile/src/session/HomeEntryProvider.tsx, apps/mobile/src/session/HtmlBrowserChrome.ios.tsx, apps/mobile/src/session/HtmlBrowserChrome.tsx, apps/mobile/src/session/HtmlFileReader.tsx, apps/mobile/src/session/HtmlWebsiteBrowser.tsx, apps/mobile/src/session/ImageLightbox.tsx, apps/mobile/src/session/IncomingShareBridge.tsx, apps/mobile/src/session/MarkdownFileReader.tsx, apps/mobile/src/session/MobileOutboxBridge.tsx, apps/mobile/src/session/NativeResidentHistory.tsx, apps/mobile/src/session/RecentMessageHistories.tsx, apps/mobile/src/session/ResidentHomeList.tsx, apps/mobile/src/session/SharedTaskAdmissionDialog.tsx, apps/mobile/src/session/SharedTaskScreen.tsx, apps/mobile/src/session/SheetModal.tsx, apps/mobile/src/session/SheetSurface.tsx, apps/mobile/src/session/mathWebViewHtml.ts, apps/mobile/src/session/mediaPlayerWebView.tsx, apps/mobile/src/session/mediaPlayerWebViewHtml.ts, apps/mobile/src/session/selectableMarkdownHtml.ts, apps/mobile/src/theme/ThemeProvider.tsx, apps/mobile/src/theme/navigationTheme.ts, apps/mobile/src/theme/tokens.ts, apps/mobile/src/update/AndroidUpdateSheet.tsx | 0 | 242 | 81 |
-| `mobile.home` | mobile | 主机与资源首页 | app/index.tsx / app/devices/index.tsx | AccountSwitcherSheet, AdaptiveWindow, AnchoredPullDownMenu, AndroidUpdateSheet, AppText, AuthContext, AutomationTimerIcon, BlurBackdrop, BotGroupAvatars, BotGroupCreateSheet, BotGroupList, CenteredScreen, ClipboardSharedTaskPrompt, CompanionChoice, CompanionCreateNativeView, CompanionCreateNativeView.ios, CompanionImportSheet, CompanionListRow, CompanionMemoryPage, CompanionMemoryPage.ios, CompanionModelChain, CompanionNativeContent.ios, CompanionPortraitPicker, CompanionPresenceRing, CompanionProfileArtifacts, CompanionProfileNativeView, CompanionProfileNativeView.ios, CompanionProfileSheet, CompanionSettingsRow, CompanionSettingsRow.ios, CompanionSheet, CompanionSheet.ios, ComposerMorphSource, ComposerMorphSource.ios, ComposerNativeRow, ComposerNativeRow.ios, ComposerNativeSection, ComposerNativeSection.ios, ComposerSheet, ComposerSheet.ios, ConnectionBanner, ConnectionNoticeOverlay, ContextSheet, ContextSheet.ios, ConversationSearchFilterSheet, DeviceLinkContext, FoldTouchpad, HomeChromeDrawer, HomeChromeFrost, HomeEntryProvider, HomeGlassMenuPanel, HomeHeaderGlassButton, HomeHeaderGlassButton.ios, HomeListVisuals, HomeModePanes, HomeModeSwitch, HomeNativeStackHeader, HomeNewTaskButton, HomeProjectMachineLabel, HomeSearchBar, HomeSurface, HomeUnreadContext, IncomingShareBridge, MobileAgentMark, MobileAgentSwitcher, MobileLoginHandoffContext, MobileLoginHandoffStage, MobileModelPickerList, MobileModelPickerList.ios, MobileOutboxBridge, MobilePermissionPickerList, MobilePermissionPickerList.ios, MobilePrimitives, MobileProviderMark, MobileUserAvatar, MobileVendorIcon, ModalContentArea, ModelOptionsSheetView, ModelOptionsSheetView.ios, ModelPickerNativeHeader, ModelPickerNativeHeader.ios, ModelPickerSheet, NativeChromeBackButton.ios, NativeChromeButton.ios, NativePullDownMenu, NativeRemoteDesktopView, NativeResidentHistory, NativeSwitch, OutsideTap, PermissionGuide, PermissionGuideView, PermissionGuideView.ios, PushNotificationsBridge, QuietSyncIndicator, RecentMessageHistories, RemoteAccessGuide, RemoteCompanionAvatar, RemoteDesktopActionButton, RemoteDesktopActionButton.ios, RemoteDesktopBackButton, RemoteDesktopBackButton.ios, RemoteDesktopChrome, RemoteDesktopChrome.ios, RemoteDesktopClipboardButton, RemoteDesktopControls, RemoteDesktopDisplaySettings, RemoteDesktopHost, RemoteDesktopIcons, RemoteDesktopMouseControls, RemoteDesktopMouseControls.ios, RemoteDesktopNetworkStatus, RemoteDesktopPanelButton, RemoteDesktopPanelButton.ios, RemoteDesktopScreen, RemoteDesktopSecuritySettings, RemoteDesktopWindows, RemoteTaskSuggestions, RenameSessionModal, ResidentHomeList, SessionActionSheet, SessionDetailsNative, SessionDetailsNative.ios, SessionHeaderNativeControls, SessionHeaderNativeControls.ios, SessionOptionsExpoSheet, SessionRightSpinner, SharedTaskAdmissionDialog, SharedTaskScreen, SheetModal, SheetSurface, SimpleStackHeader, StartupSplashOverlay, SwipeableSessionRow, SwipeableSessionRow.ios, TaskTags, TeammateCreateButton, TeammateGenerationLabel, TeammateHomeScreen, TeammateList, ThemeProvider, UnifiedModelPickerSheet, UnifiedModelPickerView, UnifiedModelPickerView.ios, WorkingStatusText, _layout, gestureHandler, index, listDisclosureTransition, peerFileTransport, useLocale | apps/mobile/app/_layout.tsx, apps/mobile/app/devices/index.tsx, apps/mobile/app/index.tsx, apps/mobile/src/auth/AuthContext.tsx, apps/mobile/src/auth/MobileLoginHandoffContext.tsx, apps/mobile/src/components/AppText.tsx, apps/mobile/src/components/CenteredScreen.tsx, apps/mobile/src/components/ConnectionBanner.tsx, apps/mobile/src/components/ConnectionNoticeOverlay.tsx, apps/mobile/src/components/MobileAgentMark.tsx, apps/mobile/src/components/MobileLoginHandoffStage.tsx, apps/mobile/src/components/MobilePrimitives.tsx, apps/mobile/src/components/MobileUserAvatar.tsx, apps/mobile/src/components/MobileVendorIcon.tsx, apps/mobile/src/components/QuietSyncIndicator.tsx, apps/mobile/src/components/RemoteAccessGuide.tsx, apps/mobile/src/components/RemoteCompanionAvatar.tsx, apps/mobile/src/components/StartupSplashOverlay.tsx, apps/mobile/src/device-link/DeviceLinkContext.tsx, apps/mobile/src/device-link/peerFileTransport.tsx, apps/mobile/src/i18n/useLocale.tsx, apps/mobile/src/notifications/PushNotificationsBridge.tsx, apps/mobile/src/platform/AdaptiveWindow.tsx, apps/mobile/src/platform/ModalContentArea.tsx, apps/mobile/src/platform/OutsideTap.tsx, apps/mobile/src/platform/chrome/AnchoredPullDownMenu.tsx, apps/mobile/src/platform/chrome/HomeNativeStackHeader.tsx, apps/mobile/src/platform/chrome/NativeChromeBackButton.ios.tsx, apps/mobile/src/platform/chrome/NativeChromeButton.ios.tsx, apps/mobile/src/platform/chrome/NativePullDownMenu.tsx, apps/mobile/src/platform/chrome/NativeSwitch.tsx, apps/mobile/src/platform/chrome/SimpleStackHeader.tsx, apps/mobile/src/platform/gestureHandler.tsx, apps/mobile/src/remote-desktop/FoldTouchpad.tsx, apps/mobile/src/remote-desktop/NativeRemoteDesktopView.tsx, apps/mobile/src/remote-desktop/PermissionGuide.tsx, apps/mobile/src/remote-desktop/PermissionGuideView.ios.tsx, apps/mobile/src/remote-desktop/PermissionGuideView.tsx, apps/mobile/src/remote-desktop/RemoteDesktopActionButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopActionButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopBackButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopBackButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopChrome.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopChrome.tsx, apps/mobile/src/remote-desktop/RemoteDesktopClipboardButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopControls.tsx, apps/mobile/src/remote-desktop/RemoteDesktopDisplaySettings.tsx, apps/mobile/src/remote-desktop/RemoteDesktopHost.tsx, apps/mobile/src/remote-desktop/RemoteDesktopIcons.tsx, apps/mobile/src/remote-desktop/RemoteDesktopMouseControls.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopMouseControls.tsx, apps/mobile/src/remote-desktop/RemoteDesktopNetworkStatus.tsx, apps/mobile/src/remote-desktop/RemoteDesktopPanelButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopPanelButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopScreen.tsx, apps/mobile/src/remote-desktop/RemoteDesktopSecuritySettings.tsx, apps/mobile/src/remote-desktop/RemoteDesktopWindows.tsx, apps/mobile/src/remote-desktop/viewerHtml.ts, apps/mobile/src/session/AccountSwitcherSheet.tsx, apps/mobile/src/session/AutomationTimerIcon.tsx, apps/mobile/src/session/BlurBackdrop.tsx, apps/mobile/src/session/BotGroupAvatars.tsx, apps/mobile/src/session/BotGroupCreateSheet.tsx, apps/mobile/src/session/BotGroupList.tsx, apps/mobile/src/session/ClipboardSharedTaskPrompt.tsx, apps/mobile/src/session/CompanionChoice.tsx, apps/mobile/src/session/CompanionCreateNativeView.ios.tsx, apps/mobile/src/session/CompanionCreateNativeView.tsx, apps/mobile/src/session/CompanionImportSheet.tsx, apps/mobile/src/session/CompanionListRow.tsx, apps/mobile/src/session/CompanionMemoryPage.ios.tsx, apps/mobile/src/session/CompanionMemoryPage.tsx, apps/mobile/src/session/CompanionModelChain.tsx, apps/mobile/src/session/CompanionNativeContent.ios.tsx, apps/mobile/src/session/CompanionPortraitPicker.tsx, apps/mobile/src/session/CompanionPresenceRing.tsx, apps/mobile/src/session/CompanionProfileArtifacts.tsx, apps/mobile/src/session/CompanionProfileNativeView.ios.tsx, apps/mobile/src/session/CompanionProfileNativeView.tsx, apps/mobile/src/session/CompanionProfileSheet.tsx, apps/mobile/src/session/CompanionSettingsRow.ios.tsx, apps/mobile/src/session/CompanionSettingsRow.tsx, apps/mobile/src/session/CompanionSheet.ios.tsx, apps/mobile/src/session/CompanionSheet.tsx, apps/mobile/src/session/ComposerMorphSource.ios.tsx, apps/mobile/src/session/ComposerMorphSource.tsx, apps/mobile/src/session/ComposerNativeRow.ios.tsx, apps/mobile/src/session/ComposerNativeRow.tsx, apps/mobile/src/session/ComposerNativeSection.ios.tsx, apps/mobile/src/session/ComposerNativeSection.tsx, apps/mobile/src/session/ComposerSheet.ios.tsx, apps/mobile/src/session/ComposerSheet.tsx, apps/mobile/src/session/ContextSheet.ios.tsx, apps/mobile/src/session/ContextSheet.tsx, apps/mobile/src/session/ConversationSearchFilterSheet.tsx, apps/mobile/src/session/HomeChromeDrawer.tsx, apps/mobile/src/session/HomeChromeFrost.tsx, apps/mobile/src/session/HomeEntryProvider.tsx, apps/mobile/src/session/HomeGlassMenuPanel.tsx, apps/mobile/src/session/HomeHeaderGlassButton.ios.tsx, apps/mobile/src/session/HomeHeaderGlassButton.tsx, apps/mobile/src/session/HomeListVisuals.tsx, apps/mobile/src/session/HomeModePanes.tsx, apps/mobile/src/session/HomeModeSwitch.tsx, apps/mobile/src/session/HomeNewTaskButton.tsx, apps/mobile/src/session/HomeProjectMachineLabel.tsx, apps/mobile/src/session/HomeSearchBar.tsx, apps/mobile/src/session/HomeSurface.tsx, apps/mobile/src/session/HomeUnreadContext.tsx, apps/mobile/src/session/IncomingShareBridge.tsx, apps/mobile/src/session/MobileAgentSwitcher.tsx, apps/mobile/src/session/MobileModelPickerList.ios.tsx, apps/mobile/src/session/MobileModelPickerList.tsx, apps/mobile/src/session/MobileOutboxBridge.tsx, apps/mobile/src/session/MobilePermissionPickerList.ios.tsx, apps/mobile/src/session/MobilePermissionPickerList.tsx, apps/mobile/src/session/MobileProviderMark.tsx, apps/mobile/src/session/ModelOptionsSheetView.ios.tsx, apps/mobile/src/session/ModelOptionsSheetView.tsx, apps/mobile/src/session/ModelPickerNativeHeader.ios.tsx, apps/mobile/src/session/ModelPickerNativeHeader.tsx, apps/mobile/src/session/ModelPickerSheet.tsx, apps/mobile/src/session/NativeResidentHistory.tsx, apps/mobile/src/session/RecentMessageHistories.tsx, apps/mobile/src/session/RemoteTaskSuggestions.tsx, apps/mobile/src/session/RenameSessionModal.tsx, apps/mobile/src/session/ResidentHomeList.tsx, apps/mobile/src/session/SessionActionSheet.tsx, apps/mobile/src/session/SessionDetailsNative.ios.tsx, apps/mobile/src/session/SessionDetailsNative.tsx, apps/mobile/src/session/SessionHeaderNativeControls.ios.tsx, apps/mobile/src/session/SessionHeaderNativeControls.tsx, apps/mobile/src/session/SessionOptionsExpoSheet.tsx, apps/mobile/src/session/SessionRightSpinner.tsx, apps/mobile/src/session/SharedTaskAdmissionDialog.tsx, apps/mobile/src/session/SharedTaskScreen.tsx, apps/mobile/src/session/SheetModal.tsx, apps/mobile/src/session/SheetSurface.tsx, apps/mobile/src/session/SwipeableSessionRow.ios.tsx, apps/mobile/src/session/SwipeableSessionRow.tsx, apps/mobile/src/session/TaskTags.tsx, apps/mobile/src/session/TeammateCreateButton.tsx, apps/mobile/src/session/TeammateGenerationLabel.tsx, apps/mobile/src/session/TeammateHomeScreen.tsx, apps/mobile/src/session/TeammateList.tsx, apps/mobile/src/session/UnifiedModelPickerSheet.tsx, apps/mobile/src/session/UnifiedModelPickerView.ios.tsx, apps/mobile/src/session/UnifiedModelPickerView.tsx, apps/mobile/src/session/WorkingStatusText.tsx, apps/mobile/src/session/listDisclosureTransition.tsx, apps/mobile/src/theme/ThemeProvider.tsx, apps/mobile/src/theme/navigationTheme.ts, apps/mobile/src/theme/tokens.ts, apps/mobile/src/update/AndroidUpdateSheet.tsx | 0 | 210 | 143 |
+| `mobile.home` | mobile | 主机与资源首页 | app/index.tsx / app/devices/index.tsx | AccountSwitcherSheet, AdaptiveWindow, AnchoredPullDownMenu, AndroidUpdateSheet, AppText, AuthContext, AutomationTimerIcon, BlurBackdrop, BotGroupAvatars, BotGroupCreateSheet, BotGroupList, CenteredScreen, ClipboardSharedTaskPrompt, CompanionChoice, CompanionCreateNativeView, CompanionCreateNativeView.ios, CompanionImportSheet, CompanionListRow, CompanionMemoryPage, CompanionMemoryPage.ios, CompanionModelChain, CompanionNativeContent.ios, CompanionPortraitPicker, CompanionPresenceRing, CompanionProfileArtifacts, CompanionProfileNativeView, CompanionProfileNativeView.ios, CompanionProfileSheet, CompanionSettingsRow, CompanionSettingsRow.ios, CompanionSheet, CompanionSheet.ios, ComposerMorphSource, ComposerMorphSource.ios, ComposerNativeRow, ComposerNativeRow.ios, ComposerNativeSection, ComposerNativeSection.ios, ComposerSheet, ComposerSheet.ios, ConnectionBanner, ConnectionNoticeOverlay, ContextSheet, ContextSheet.ios, ConversationSearchFilterSheet, DeviceLinkContext, FoldTouchpad, HomeChromeDrawer, HomeChromeFrost, HomeEntryProvider, HomeGlassMenuPanel, HomeHeaderGlassButton, HomeHeaderGlassButton.ios, HomeListVisuals, HomeModePanes, HomeModeSwitch, HomeNativeStackHeader, HomeNewTaskButton, HomeProjectMachineLabel, HomeSearchBar, HomeSurface, HomeUnreadContext, IncomingShareBridge, MobileAgentMark, MobileAgentSwitcher, MobileLoginHandoffContext, MobileLoginHandoffStage, MobileModelPickerList, MobileModelPickerList.ios, MobileOutboxBridge, MobilePermissionPickerList, MobilePermissionPickerList.ios, MobilePrimitives, MobileProviderMark, MobileUserAvatar, MobileVendorIcon, ModalContentArea, ModelOptionsSheetView, ModelOptionsSheetView.ios, ModelPickerNativeHeader, ModelPickerNativeHeader.ios, ModelPickerSheet, MountOnFirstOpen, NativeChromeBackButton.ios, NativeChromeButton.ios, NativePullDownMenu, NativeRemoteDesktopView, NativeResidentHistory, NativeSwitch, OutsideTap, PermissionGuide, PermissionGuideView, PermissionGuideView.ios, PushNotificationsBridge, QuietSyncIndicator, RecentMessageHistories, RemoteAccessGuide, RemoteCompanionAvatar, RemoteDesktopActionButton, RemoteDesktopActionButton.ios, RemoteDesktopBackButton, RemoteDesktopBackButton.ios, RemoteDesktopChrome, RemoteDesktopChrome.ios, RemoteDesktopClipboardButton, RemoteDesktopControls, RemoteDesktopDisplaySettings, RemoteDesktopHost, RemoteDesktopIcons, RemoteDesktopMouseControls, RemoteDesktopMouseControls.ios, RemoteDesktopNetworkStatus, RemoteDesktopPanelButton, RemoteDesktopPanelButton.ios, RemoteDesktopScreen, RemoteDesktopSecuritySettings, RemoteDesktopWindows, RemoteTaskSuggestions, RenameSessionModal, ResidentHomeList, SessionActionSheet, SessionDetailsNative, SessionDetailsNative.ios, SessionHeaderNativeControls, SessionHeaderNativeControls.ios, SessionOptionsExpoSheet, SessionRightSpinner, SharedTaskAdmissionDialog, SharedTaskScreen, SheetModal, SheetSurface, SimpleStackHeader, StartupSplashOverlay, SwipeableSessionRow, SwipeableSessionRow.ios, TaskTags, TeammateCreateButton, TeammateGenerationLabel, TeammateHomeScreen, TeammateList, ThemeProvider, UnifiedModelPickerSheet, UnifiedModelPickerView, UnifiedModelPickerView.ios, WorkingStatusText, _layout, gestureHandler, index, listDisclosureTransition, peerFileTransport, useLocale | apps/mobile/app/_layout.tsx, apps/mobile/app/devices/index.tsx, apps/mobile/app/index.tsx, apps/mobile/src/auth/AuthContext.tsx, apps/mobile/src/auth/MobileLoginHandoffContext.tsx, apps/mobile/src/components/AppText.tsx, apps/mobile/src/components/CenteredScreen.tsx, apps/mobile/src/components/ConnectionBanner.tsx, apps/mobile/src/components/ConnectionNoticeOverlay.tsx, apps/mobile/src/components/MobileAgentMark.tsx, apps/mobile/src/components/MobileLoginHandoffStage.tsx, apps/mobile/src/components/MobilePrimitives.tsx, apps/mobile/src/components/MobileUserAvatar.tsx, apps/mobile/src/components/MobileVendorIcon.tsx, apps/mobile/src/components/QuietSyncIndicator.tsx, apps/mobile/src/components/RemoteAccessGuide.tsx, apps/mobile/src/components/RemoteCompanionAvatar.tsx, apps/mobile/src/components/StartupSplashOverlay.tsx, apps/mobile/src/device-link/DeviceLinkContext.tsx, apps/mobile/src/device-link/peerFileTransport.tsx, apps/mobile/src/i18n/useLocale.tsx, apps/mobile/src/notifications/PushNotificationsBridge.tsx, apps/mobile/src/platform/AdaptiveWindow.tsx, apps/mobile/src/platform/ModalContentArea.tsx, apps/mobile/src/platform/OutsideTap.tsx, apps/mobile/src/platform/chrome/AnchoredPullDownMenu.tsx, apps/mobile/src/platform/chrome/HomeNativeStackHeader.tsx, apps/mobile/src/platform/chrome/NativeChromeBackButton.ios.tsx, apps/mobile/src/platform/chrome/NativeChromeButton.ios.tsx, apps/mobile/src/platform/chrome/NativePullDownMenu.tsx, apps/mobile/src/platform/chrome/NativeSwitch.tsx, apps/mobile/src/platform/chrome/SimpleStackHeader.tsx, apps/mobile/src/platform/gestureHandler.tsx, apps/mobile/src/remote-desktop/FoldTouchpad.tsx, apps/mobile/src/remote-desktop/NativeRemoteDesktopView.tsx, apps/mobile/src/remote-desktop/PermissionGuide.tsx, apps/mobile/src/remote-desktop/PermissionGuideView.ios.tsx, apps/mobile/src/remote-desktop/PermissionGuideView.tsx, apps/mobile/src/remote-desktop/RemoteDesktopActionButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopActionButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopBackButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopBackButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopChrome.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopChrome.tsx, apps/mobile/src/remote-desktop/RemoteDesktopClipboardButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopControls.tsx, apps/mobile/src/remote-desktop/RemoteDesktopDisplaySettings.tsx, apps/mobile/src/remote-desktop/RemoteDesktopHost.tsx, apps/mobile/src/remote-desktop/RemoteDesktopIcons.tsx, apps/mobile/src/remote-desktop/RemoteDesktopMouseControls.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopMouseControls.tsx, apps/mobile/src/remote-desktop/RemoteDesktopNetworkStatus.tsx, apps/mobile/src/remote-desktop/RemoteDesktopPanelButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopPanelButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopScreen.tsx, apps/mobile/src/remote-desktop/RemoteDesktopSecuritySettings.tsx, apps/mobile/src/remote-desktop/RemoteDesktopWindows.tsx, apps/mobile/src/remote-desktop/viewerHtml.ts, apps/mobile/src/session/AccountSwitcherSheet.tsx, apps/mobile/src/session/AutomationTimerIcon.tsx, apps/mobile/src/session/BlurBackdrop.tsx, apps/mobile/src/session/BotGroupAvatars.tsx, apps/mobile/src/session/BotGroupCreateSheet.tsx, apps/mobile/src/session/BotGroupList.tsx, apps/mobile/src/session/ClipboardSharedTaskPrompt.tsx, apps/mobile/src/session/CompanionChoice.tsx, apps/mobile/src/session/CompanionCreateNativeView.ios.tsx, apps/mobile/src/session/CompanionCreateNativeView.tsx, apps/mobile/src/session/CompanionImportSheet.tsx, apps/mobile/src/session/CompanionListRow.tsx, apps/mobile/src/session/CompanionMemoryPage.ios.tsx, apps/mobile/src/session/CompanionMemoryPage.tsx, apps/mobile/src/session/CompanionModelChain.tsx, apps/mobile/src/session/CompanionNativeContent.ios.tsx, apps/mobile/src/session/CompanionPortraitPicker.tsx, apps/mobile/src/session/CompanionPresenceRing.tsx, apps/mobile/src/session/CompanionProfileArtifacts.tsx, apps/mobile/src/session/CompanionProfileNativeView.ios.tsx, apps/mobile/src/session/CompanionProfileNativeView.tsx, apps/mobile/src/session/CompanionProfileSheet.tsx, apps/mobile/src/session/CompanionSettingsRow.ios.tsx, apps/mobile/src/session/CompanionSettingsRow.tsx, apps/mobile/src/session/CompanionSheet.ios.tsx, apps/mobile/src/session/CompanionSheet.tsx, apps/mobile/src/session/ComposerMorphSource.ios.tsx, apps/mobile/src/session/ComposerMorphSource.tsx, apps/mobile/src/session/ComposerNativeRow.ios.tsx, apps/mobile/src/session/ComposerNativeRow.tsx, apps/mobile/src/session/ComposerNativeSection.ios.tsx, apps/mobile/src/session/ComposerNativeSection.tsx, apps/mobile/src/session/ComposerSheet.ios.tsx, apps/mobile/src/session/ComposerSheet.tsx, apps/mobile/src/session/ContextSheet.ios.tsx, apps/mobile/src/session/ContextSheet.tsx, apps/mobile/src/session/ConversationSearchFilterSheet.tsx, apps/mobile/src/session/HomeChromeDrawer.tsx, apps/mobile/src/session/HomeChromeFrost.tsx, apps/mobile/src/session/HomeEntryProvider.tsx, apps/mobile/src/session/HomeGlassMenuPanel.tsx, apps/mobile/src/session/HomeHeaderGlassButton.ios.tsx, apps/mobile/src/session/HomeHeaderGlassButton.tsx, apps/mobile/src/session/HomeListVisuals.tsx, apps/mobile/src/session/HomeModePanes.tsx, apps/mobile/src/session/HomeModeSwitch.tsx, apps/mobile/src/session/HomeNewTaskButton.tsx, apps/mobile/src/session/HomeProjectMachineLabel.tsx, apps/mobile/src/session/HomeSearchBar.tsx, apps/mobile/src/session/HomeSurface.tsx, apps/mobile/src/session/HomeUnreadContext.tsx, apps/mobile/src/session/IncomingShareBridge.tsx, apps/mobile/src/session/MobileAgentSwitcher.tsx, apps/mobile/src/session/MobileModelPickerList.ios.tsx, apps/mobile/src/session/MobileModelPickerList.tsx, apps/mobile/src/session/MobileOutboxBridge.tsx, apps/mobile/src/session/MobilePermissionPickerList.ios.tsx, apps/mobile/src/session/MobilePermissionPickerList.tsx, apps/mobile/src/session/MobileProviderMark.tsx, apps/mobile/src/session/ModelOptionsSheetView.ios.tsx, apps/mobile/src/session/ModelOptionsSheetView.tsx, apps/mobile/src/session/ModelPickerNativeHeader.ios.tsx, apps/mobile/src/session/ModelPickerNativeHeader.tsx, apps/mobile/src/session/ModelPickerSheet.tsx, apps/mobile/src/session/MountOnFirstOpen.tsx, apps/mobile/src/session/NativeResidentHistory.tsx, apps/mobile/src/session/RecentMessageHistories.tsx, apps/mobile/src/session/RemoteTaskSuggestions.tsx, apps/mobile/src/session/RenameSessionModal.tsx, apps/mobile/src/session/ResidentHomeList.tsx, apps/mobile/src/session/SessionActionSheet.tsx, apps/mobile/src/session/SessionDetailsNative.ios.tsx, apps/mobile/src/session/SessionDetailsNative.tsx, apps/mobile/src/session/SessionHeaderNativeControls.ios.tsx, apps/mobile/src/session/SessionHeaderNativeControls.tsx, apps/mobile/src/session/SessionOptionsExpoSheet.tsx, apps/mobile/src/session/SessionRightSpinner.tsx, apps/mobile/src/session/SharedTaskAdmissionDialog.tsx, apps/mobile/src/session/SharedTaskScreen.tsx, apps/mobile/src/session/SheetModal.tsx, apps/mobile/src/session/SheetSurface.tsx, apps/mobile/src/session/SwipeableSessionRow.ios.tsx, apps/mobile/src/session/SwipeableSessionRow.tsx, apps/mobile/src/session/TaskTags.tsx, apps/mobile/src/session/TeammateCreateButton.tsx, apps/mobile/src/session/TeammateGenerationLabel.tsx, apps/mobile/src/session/TeammateHomeScreen.tsx, apps/mobile/src/session/TeammateList.tsx, apps/mobile/src/session/UnifiedModelPickerSheet.tsx, apps/mobile/src/session/UnifiedModelPickerView.ios.tsx, apps/mobile/src/session/UnifiedModelPickerView.tsx, apps/mobile/src/session/WorkingStatusText.tsx, apps/mobile/src/session/listDisclosureTransition.tsx, apps/mobile/src/theme/ThemeProvider.tsx, apps/mobile/src/theme/navigationTheme.ts, apps/mobile/src/theme/tokens.ts, apps/mobile/src/update/AndroidUpdateSheet.tsx | 0 | 210 | 143 |
| `mobile.overlay.connection-startup` | mobile | 根布局挂载的启动与连接反馈 | app/_layout.tsx → StartupSplashOverlay / ConnectionNoticeProvider;各页面 ConnectionBanner | AdaptiveWindow, AnchoredPullDownMenu, AndroidUpdateSheet, AppText, AuthContext, BlurBackdrop, CenteredScreen, ClipboardSharedTaskPrompt, ComposerNativeSection, ComposerNativeSection.ios, ComposerSheet, ComposerSheet.ios, ConnectionBanner, ConnectionNoticeOverlay, ConnectionNoticeProvider, ContextSheet, ContextSheet.ios, DeviceLinkContext, FoldTouchpad, HomeEntryProvider, IncomingShareBridge, MobileLoginHandoffContext, MobileLoginHandoffStage, MobileOutboxBridge, MobilePrimitives, NativeChromeBackButton.ios, NativeChromeButton.ios, NativePullDownMenu, NativeRemoteDesktopView, NativeResidentHistory, NativeSwitch, OutsideTap, PermissionGuide, PermissionGuideView, PermissionGuideView.ios, PushNotificationsBridge, QuietSyncIndicator, RecentMessageHistories, RemoteDesktopActionButton, RemoteDesktopActionButton.ios, RemoteDesktopBackButton, RemoteDesktopBackButton.ios, RemoteDesktopChrome, RemoteDesktopChrome.ios, RemoteDesktopClipboardButton, RemoteDesktopControls, RemoteDesktopDisplaySettings, RemoteDesktopHost, RemoteDesktopIcons, RemoteDesktopMouseControls, RemoteDesktopMouseControls.ios, RemoteDesktopNetworkStatus, RemoteDesktopPanelButton, RemoteDesktopPanelButton.ios, RemoteDesktopScreen, RemoteDesktopSecuritySettings, RemoteDesktopWindows, ResidentHomeList, SharedTaskAdmissionDialog, SharedTaskScreen, SheetModal, SheetSurface, SimpleStackHeader, StartupSplashOverlay, ThemeProvider, _layout, gestureHandler, peerFileTransport, useLocale | apps/mobile/app/_layout.tsx, apps/mobile/src/auth/AuthContext.tsx, apps/mobile/src/auth/MobileLoginHandoffContext.tsx, apps/mobile/src/components/AppText.tsx, apps/mobile/src/components/CenteredScreen.tsx, apps/mobile/src/components/ConnectionBanner.tsx, apps/mobile/src/components/ConnectionNoticeOverlay.tsx, apps/mobile/src/components/MobileLoginHandoffStage.tsx, apps/mobile/src/components/MobilePrimitives.tsx, apps/mobile/src/components/QuietSyncIndicator.tsx, apps/mobile/src/components/StartupSplashOverlay.tsx, apps/mobile/src/device-link/DeviceLinkContext.tsx, apps/mobile/src/device-link/peerFileTransport.tsx, apps/mobile/src/i18n/useLocale.tsx, apps/mobile/src/notifications/PushNotificationsBridge.tsx, apps/mobile/src/platform/AdaptiveWindow.tsx, apps/mobile/src/platform/OutsideTap.tsx, apps/mobile/src/platform/chrome/AnchoredPullDownMenu.tsx, apps/mobile/src/platform/chrome/NativeChromeBackButton.ios.tsx, apps/mobile/src/platform/chrome/NativeChromeButton.ios.tsx, apps/mobile/src/platform/chrome/NativePullDownMenu.tsx, apps/mobile/src/platform/chrome/NativeSwitch.tsx, apps/mobile/src/platform/chrome/SimpleStackHeader.tsx, apps/mobile/src/platform/gestureHandler.tsx, apps/mobile/src/remote-desktop/FoldTouchpad.tsx, apps/mobile/src/remote-desktop/NativeRemoteDesktopView.tsx, apps/mobile/src/remote-desktop/PermissionGuide.tsx, apps/mobile/src/remote-desktop/PermissionGuideView.ios.tsx, apps/mobile/src/remote-desktop/PermissionGuideView.tsx, apps/mobile/src/remote-desktop/RemoteDesktopActionButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopActionButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopBackButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopBackButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopChrome.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopChrome.tsx, apps/mobile/src/remote-desktop/RemoteDesktopClipboardButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopControls.tsx, apps/mobile/src/remote-desktop/RemoteDesktopDisplaySettings.tsx, apps/mobile/src/remote-desktop/RemoteDesktopHost.tsx, apps/mobile/src/remote-desktop/RemoteDesktopIcons.tsx, apps/mobile/src/remote-desktop/RemoteDesktopMouseControls.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopMouseControls.tsx, apps/mobile/src/remote-desktop/RemoteDesktopNetworkStatus.tsx, apps/mobile/src/remote-desktop/RemoteDesktopPanelButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopPanelButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopScreen.tsx, apps/mobile/src/remote-desktop/RemoteDesktopSecuritySettings.tsx, apps/mobile/src/remote-desktop/RemoteDesktopWindows.tsx, apps/mobile/src/remote-desktop/viewerHtml.ts, apps/mobile/src/session/BlurBackdrop.tsx, apps/mobile/src/session/ClipboardSharedTaskPrompt.tsx, apps/mobile/src/session/ComposerNativeSection.ios.tsx, apps/mobile/src/session/ComposerNativeSection.tsx, apps/mobile/src/session/ComposerSheet.ios.tsx, apps/mobile/src/session/ComposerSheet.tsx, apps/mobile/src/session/ContextSheet.ios.tsx, apps/mobile/src/session/ContextSheet.tsx, apps/mobile/src/session/HomeEntryProvider.tsx, apps/mobile/src/session/IncomingShareBridge.tsx, apps/mobile/src/session/MobileOutboxBridge.tsx, apps/mobile/src/session/NativeResidentHistory.tsx, apps/mobile/src/session/RecentMessageHistories.tsx, apps/mobile/src/session/ResidentHomeList.tsx, apps/mobile/src/session/SharedTaskAdmissionDialog.tsx, apps/mobile/src/session/SharedTaskScreen.tsx, apps/mobile/src/session/SheetModal.tsx, apps/mobile/src/session/SheetSurface.tsx, apps/mobile/src/theme/ThemeProvider.tsx, apps/mobile/src/theme/navigationTheme.ts, apps/mobile/src/theme/tokens.ts, apps/mobile/src/update/AndroidUpdateSheet.tsx | 0 | 210 | 55 |
| `mobile.remote-desktop` | mobile | 远程桌面 | app/devices/desktop/[deviceId].tsx | AdaptiveWindow, AnchoredPullDownMenu, AndroidUpdateSheet, AppText, AuthContext, BlurBackdrop, CenteredScreen, ClipboardSharedTaskPrompt, ComposerNativeSection, ComposerNativeSection.ios, ComposerSheet, ComposerSheet.ios, ConnectionBanner, ConnectionNoticeOverlay, ContextSheet, ContextSheet.ios, DeviceLinkContext, FoldTouchpad, HomeEntryProvider, IncomingShareBridge, MobileLoginHandoffContext, MobileLoginHandoffStage, MobileOutboxBridge, MobilePrimitives, NativeChromeBackButton.ios, NativeChromeButton.ios, NativePullDownMenu, NativeRemoteDesktopView, NativeResidentHistory, NativeSwitch, OutsideTap, PermissionGuide, PermissionGuideView, PermissionGuideView.ios, PushNotificationsBridge, QuietSyncIndicator, RecentMessageHistories, RemoteDesktopActionButton, RemoteDesktopActionButton.ios, RemoteDesktopBackButton, RemoteDesktopBackButton.ios, RemoteDesktopChrome, RemoteDesktopChrome.ios, RemoteDesktopClipboardButton, RemoteDesktopControls, RemoteDesktopDisplaySettings, RemoteDesktopHost, RemoteDesktopIcons, RemoteDesktopMouseControls, RemoteDesktopMouseControls.ios, RemoteDesktopNetworkStatus, RemoteDesktopPanelButton, RemoteDesktopPanelButton.ios, RemoteDesktopScreen, RemoteDesktopSecuritySettings, RemoteDesktopWindows, ResidentHomeList, SharedTaskAdmissionDialog, SharedTaskScreen, SheetModal, SheetSurface, SimpleStackHeader, StartupSplashOverlay, ThemeProvider, [deviceId], _layout, gestureHandler, peerFileTransport, useLocale | apps/mobile/app/_layout.tsx, apps/mobile/app/devices/desktop/[deviceId].tsx, apps/mobile/src/auth/AuthContext.tsx, apps/mobile/src/auth/MobileLoginHandoffContext.tsx, apps/mobile/src/components/AppText.tsx, apps/mobile/src/components/CenteredScreen.tsx, apps/mobile/src/components/ConnectionBanner.tsx, apps/mobile/src/components/ConnectionNoticeOverlay.tsx, apps/mobile/src/components/MobileLoginHandoffStage.tsx, apps/mobile/src/components/MobilePrimitives.tsx, apps/mobile/src/components/QuietSyncIndicator.tsx, apps/mobile/src/components/StartupSplashOverlay.tsx, apps/mobile/src/device-link/DeviceLinkContext.tsx, apps/mobile/src/device-link/peerFileTransport.tsx, apps/mobile/src/i18n/useLocale.tsx, apps/mobile/src/notifications/PushNotificationsBridge.tsx, apps/mobile/src/platform/AdaptiveWindow.tsx, apps/mobile/src/platform/OutsideTap.tsx, apps/mobile/src/platform/chrome/AnchoredPullDownMenu.tsx, apps/mobile/src/platform/chrome/NativeChromeBackButton.ios.tsx, apps/mobile/src/platform/chrome/NativeChromeButton.ios.tsx, apps/mobile/src/platform/chrome/NativePullDownMenu.tsx, apps/mobile/src/platform/chrome/NativeSwitch.tsx, apps/mobile/src/platform/chrome/SimpleStackHeader.tsx, apps/mobile/src/platform/gestureHandler.tsx, apps/mobile/src/remote-desktop/FoldTouchpad.tsx, apps/mobile/src/remote-desktop/NativeRemoteDesktopView.tsx, apps/mobile/src/remote-desktop/PermissionGuide.tsx, apps/mobile/src/remote-desktop/PermissionGuideView.ios.tsx, apps/mobile/src/remote-desktop/PermissionGuideView.tsx, apps/mobile/src/remote-desktop/RemoteDesktopActionButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopActionButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopBackButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopBackButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopChrome.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopChrome.tsx, apps/mobile/src/remote-desktop/RemoteDesktopClipboardButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopControls.tsx, apps/mobile/src/remote-desktop/RemoteDesktopDisplaySettings.tsx, apps/mobile/src/remote-desktop/RemoteDesktopHost.tsx, apps/mobile/src/remote-desktop/RemoteDesktopIcons.tsx, apps/mobile/src/remote-desktop/RemoteDesktopMouseControls.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopMouseControls.tsx, apps/mobile/src/remote-desktop/RemoteDesktopNetworkStatus.tsx, apps/mobile/src/remote-desktop/RemoteDesktopPanelButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopPanelButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopScreen.tsx, apps/mobile/src/remote-desktop/RemoteDesktopSecuritySettings.tsx, apps/mobile/src/remote-desktop/RemoteDesktopWindows.tsx, apps/mobile/src/remote-desktop/viewerHtml.ts, apps/mobile/src/session/BlurBackdrop.tsx, apps/mobile/src/session/ClipboardSharedTaskPrompt.tsx, apps/mobile/src/session/ComposerNativeSection.ios.tsx, apps/mobile/src/session/ComposerNativeSection.tsx, apps/mobile/src/session/ComposerSheet.ios.tsx, apps/mobile/src/session/ComposerSheet.tsx, apps/mobile/src/session/ContextSheet.ios.tsx, apps/mobile/src/session/ContextSheet.tsx, apps/mobile/src/session/HomeEntryProvider.tsx, apps/mobile/src/session/IncomingShareBridge.tsx, apps/mobile/src/session/MobileOutboxBridge.tsx, apps/mobile/src/session/NativeResidentHistory.tsx, apps/mobile/src/session/RecentMessageHistories.tsx, apps/mobile/src/session/ResidentHomeList.tsx, apps/mobile/src/session/SharedTaskAdmissionDialog.tsx, apps/mobile/src/session/SharedTaskScreen.tsx, apps/mobile/src/session/SheetModal.tsx, apps/mobile/src/session/SheetSurface.tsx, apps/mobile/src/theme/ThemeProvider.tsx, apps/mobile/src/theme/navigationTheme.ts, apps/mobile/src/theme/tokens.ts, apps/mobile/src/update/AndroidUpdateSheet.tsx | 0 | 210 | 55 |
| `mobile.resources` | mobile | 远程资源列表与详情 | app/resources/[collectionId].tsx / app/resources/[collectionId]/[resourceId].tsx | AdaptiveWindow, AnchoredPullDownMenu, AndroidUpdateSheet, AppText, AuthContext, BlurBackdrop, BotGroupAvatars, BotGroupList, CenteredScreen, ClipboardSharedTaskPrompt, CompanionListRow, CompanionPresenceRing, ComposerNativeSection, ComposerNativeSection.ios, ComposerSheet, ComposerSheet.ios, ConnectionBanner, ConnectionNoticeOverlay, ContextSheet, ContextSheet.ios, DeviceLinkContext, FoldTouchpad, HomeEntryProvider, HomeHeaderGlassButton, HomeHeaderGlassButton.ios, HomeNativeStackHeader, IncomingShareBridge, MobileLoginHandoffContext, MobileLoginHandoffStage, MobileOutboxBridge, MobilePrimitives, NativeChromeBackButton.ios, NativeChromeButton.ios, NativePullDownMenu, NativeRemoteDesktopView, NativeResidentHistory, NativeSwitch, OutsideTap, PermissionGuide, PermissionGuideView, PermissionGuideView.ios, PushNotificationsBridge, QuietSyncIndicator, RecentMessageHistories, RemoteCompanionAvatar, RemoteDesktopActionButton, RemoteDesktopActionButton.ios, RemoteDesktopBackButton, RemoteDesktopBackButton.ios, RemoteDesktopChrome, RemoteDesktopChrome.ios, RemoteDesktopClipboardButton, RemoteDesktopControls, RemoteDesktopDisplaySettings, RemoteDesktopHost, RemoteDesktopIcons, RemoteDesktopMouseControls, RemoteDesktopMouseControls.ios, RemoteDesktopNetworkStatus, RemoteDesktopPanelButton, RemoteDesktopPanelButton.ios, RemoteDesktopScreen, RemoteDesktopSecuritySettings, RemoteDesktopWindows, ResidentHomeList, SessionRightSpinner, SharedTaskAdmissionDialog, SharedTaskScreen, SheetModal, SheetSurface, SimpleStackHeader, StartupSplashOverlay, TeammateGenerationLabel, TeammateList, ThemeProvider, WorkingStatusText, [collectionId], [resourceId], _layout, gestureHandler, peerFileTransport, useLocale | apps/mobile/app/_layout.tsx, apps/mobile/app/resources/[collectionId].tsx, apps/mobile/app/resources/[collectionId]/[resourceId].tsx, apps/mobile/src/auth/AuthContext.tsx, apps/mobile/src/auth/MobileLoginHandoffContext.tsx, apps/mobile/src/components/AppText.tsx, apps/mobile/src/components/CenteredScreen.tsx, apps/mobile/src/components/ConnectionBanner.tsx, apps/mobile/src/components/ConnectionNoticeOverlay.tsx, apps/mobile/src/components/MobileLoginHandoffStage.tsx, apps/mobile/src/components/MobilePrimitives.tsx, apps/mobile/src/components/QuietSyncIndicator.tsx, apps/mobile/src/components/RemoteCompanionAvatar.tsx, apps/mobile/src/components/StartupSplashOverlay.tsx, apps/mobile/src/device-link/DeviceLinkContext.tsx, apps/mobile/src/device-link/peerFileTransport.tsx, apps/mobile/src/i18n/useLocale.tsx, apps/mobile/src/notifications/PushNotificationsBridge.tsx, apps/mobile/src/platform/AdaptiveWindow.tsx, apps/mobile/src/platform/OutsideTap.tsx, apps/mobile/src/platform/chrome/AnchoredPullDownMenu.tsx, apps/mobile/src/platform/chrome/HomeNativeStackHeader.tsx, apps/mobile/src/platform/chrome/NativeChromeBackButton.ios.tsx, apps/mobile/src/platform/chrome/NativeChromeButton.ios.tsx, apps/mobile/src/platform/chrome/NativePullDownMenu.tsx, apps/mobile/src/platform/chrome/NativeSwitch.tsx, apps/mobile/src/platform/chrome/SimpleStackHeader.tsx, apps/mobile/src/platform/gestureHandler.tsx, apps/mobile/src/remote-desktop/FoldTouchpad.tsx, apps/mobile/src/remote-desktop/NativeRemoteDesktopView.tsx, apps/mobile/src/remote-desktop/PermissionGuide.tsx, apps/mobile/src/remote-desktop/PermissionGuideView.ios.tsx, apps/mobile/src/remote-desktop/PermissionGuideView.tsx, apps/mobile/src/remote-desktop/RemoteDesktopActionButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopActionButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopBackButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopBackButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopChrome.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopChrome.tsx, apps/mobile/src/remote-desktop/RemoteDesktopClipboardButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopControls.tsx, apps/mobile/src/remote-desktop/RemoteDesktopDisplaySettings.tsx, apps/mobile/src/remote-desktop/RemoteDesktopHost.tsx, apps/mobile/src/remote-desktop/RemoteDesktopIcons.tsx, apps/mobile/src/remote-desktop/RemoteDesktopMouseControls.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopMouseControls.tsx, apps/mobile/src/remote-desktop/RemoteDesktopNetworkStatus.tsx, apps/mobile/src/remote-desktop/RemoteDesktopPanelButton.ios.tsx, apps/mobile/src/remote-desktop/RemoteDesktopPanelButton.tsx, apps/mobile/src/remote-desktop/RemoteDesktopScreen.tsx, apps/mobile/src/remote-desktop/RemoteDesktopSecuritySettings.tsx, apps/mobile/src/remote-desktop/RemoteDesktopWindows.tsx, apps/mobile/src/remote-desktop/viewerHtml.ts, apps/mobile/src/session/BlurBackdrop.tsx, apps/mobile/src/session/BotGroupAvatars.tsx, apps/mobile/src/session/BotGroupList.tsx, apps/mobile/src/session/ClipboardSharedTaskPrompt.tsx, apps/mobile/src/session/CompanionListRow.tsx, apps/mobile/src/session/CompanionPresenceRing.tsx, apps/mobile/src/session/ComposerNativeSection.ios.tsx, apps/mobile/src/session/ComposerNativeSection.tsx, apps/mobile/src/session/ComposerSheet.ios.tsx, apps/mobile/src/session/ComposerSheet.tsx, apps/mobile/src/session/ContextSheet.ios.tsx, apps/mobile/src/session/ContextSheet.tsx, apps/mobile/src/session/HomeEntryProvider.tsx, apps/mobile/src/session/HomeHeaderGlassButton.ios.tsx, apps/mobile/src/session/HomeHeaderGlassButton.tsx, apps/mobile/src/session/IncomingShareBridge.tsx, apps/mobile/src/session/MobileOutboxBridge.tsx, apps/mobile/src/session/NativeResidentHistory.tsx, apps/mobile/src/session/RecentMessageHistories.tsx, apps/mobile/src/session/ResidentHomeList.tsx, apps/mobile/src/session/SessionRightSpinner.tsx, apps/mobile/src/session/SharedTaskAdmissionDialog.tsx, apps/mobile/src/session/SharedTaskScreen.tsx, apps/mobile/src/session/SheetModal.tsx, apps/mobile/src/session/SheetSurface.tsx, apps/mobile/src/session/TeammateGenerationLabel.tsx, apps/mobile/src/session/TeammateList.tsx, apps/mobile/src/session/WorkingStatusText.tsx, apps/mobile/src/theme/ThemeProvider.tsx, apps/mobile/src/theme/navigationTheme.ts, apps/mobile/src/theme/tokens.ts, apps/mobile/src/update/AndroidUpdateSheet.tsx | 0 | 210 | 71 |
diff --git a/packages/maker-shared/src/__tests__/sessionList.test.ts b/packages/maker-shared/src/__tests__/sessionList.test.ts
index f26b1e1711..f16d1ddab0 100644
--- a/packages/maker-shared/src/__tests__/sessionList.test.ts
+++ b/packages/maker-shared/src/__tests__/sessionList.test.ts
@@ -1,6 +1,7 @@
import { performance } from 'node:perf_hooks';
import { describe, expect, it } from 'vitest';
import {
+ compareSessionListStrings,
buildRemoteSessionListContext,
buildRemoteSessionCardPreview,
buildRemoteSessionSections,
@@ -18,6 +19,14 @@ import {
toRemoteSessionListItem,
formatRemoteSessionSidebarTime,
} from '../sessionList.js';
+
+it('preserves default locale ordering for dates, paths, IDs and multilingual titles', () => {
+ const values = ['', '2026-01-01T00:00:00Z', '2026-09-30T10:00:00.000Z',
+ '/test/History-1', '/test/History-10', 'a', 'A', 'é', 'e', '任务', 'タスク'];
+ for (const left of values) for (const right of values) {
+ expect(Math.sign(compareSessionListStrings(left, right))).toBe(Math.sign(left.localeCompare(right)));
+ }
+});
import type { PresentationLocalizer } from '../presentationLocalization.js';
import type { RemoteSchedule, RemoteScheduleRun } from '../scheduleTypes.js';
import { CONTINUE_AFTER_ERROR_PROMPT } from '../syntheticTrigger.js';
diff --git a/packages/maker-shared/src/mobileHome.ts b/packages/maker-shared/src/mobileHome.ts
index a09dbe5c06..4d3461c18b 100644
--- a/packages/maker-shared/src/mobileHome.ts
+++ b/packages/maker-shared/src/mobileHome.ts
@@ -1,4 +1,5 @@
import {
+ compareSessionListStrings,
groupAutomationListItems,
remoteSessionDisplayTitle,
sessionRowMessagePreview,
@@ -358,7 +359,7 @@ function buildProjectGroups(
// 用列表项的 lastActivityAt 而非 item.session 的时间:自动化组行的 session 是
// primary(可能是较旧的未读 run),但其 lastActivityAt 已被共享层修正为组内最新。
latestActivityAt: group.reduce((latest, item) =>
- item.lastActivityAt.localeCompare(latest) > 0 ? item.lastActivityAt : latest,
+ compareSessionListStrings(item.lastActivityAt, latest) > 0 ? item.lastActivityAt : latest,
first.lastActivityAt),
pendingInteractionCount: group.reduce((sum, item) => sum + item.pendingInteractionCount, 0),
sessionCount: group.reduce((sum, item) => sum + (item.automationGroup?.sessionCount ?? 1), 0),
@@ -368,7 +369,7 @@ function buildProjectGroups(
workingDir,
};
})
- .sort((a, b) => b.latestActivityAt.localeCompare(a.latestActivityAt));
+ .sort((a, b) => compareSessionListStrings(b.latestActivityAt, a.latestActivityAt));
}
function projectGroupKey(session: RemoteSessionListSessionLike): string {
@@ -558,7 +559,7 @@ function matchesSearchQuery(
function compareSessionsByStatusThenActivityDesc(a: MobileHomeSessionLike, b: MobileHomeSessionLike): number {
const statusDiff = sessionStatusRank(a.status) - sessionStatusRank(b.status);
if (statusDiff !== 0) return statusDiff;
- return lastActivityTime(b).localeCompare(lastActivityTime(a));
+ return compareSessionListStrings(lastActivityTime(b), lastActivityTime(a));
}
function sessionStatusRank(status: string): number {
diff --git a/packages/maker-shared/src/sessionList.ts b/packages/maker-shared/src/sessionList.ts
index f5d24d2d15..7276d1f7e4 100644
--- a/packages/maker-shared/src/sessionList.ts
+++ b/packages/maker-shared/src/sessionList.ts
@@ -10,6 +10,19 @@ import { isDefaultDraftSessionTitle } from './sessionTitle.js';
import { getSessionListCollapseView } from './sessionListCollapse.js';
import { collapseWorktreeDirForGrouping } from './worktreePaths.js';
+let sessionListCollator: Intl.Collator | undefined;
+/** Call when the host resumes after system locale/region preferences may change. */
+export function clearSessionListCollator(): void {
+ sessionListCollator = undefined;
+}
+
+/** Same default-locale ordering as localeCompare, without constructing an ICU
+ * collator for every comparison on Android/Hermes. */
+export function compareSessionListStrings(left: string, right: string): number {
+ sessionListCollator ??= new Intl.Collator();
+ return sessionListCollator.compare(left, right);
+}
+
export interface RemoteSessionListSessionLike extends SessionInterruptionState {
tags?: import('./taskTags').TaskTag[];
_count?: { messages?: number } | null;
@@ -388,7 +401,7 @@ function buildProjectSections(
list.push(item);
projectGroups.set(key, list);
}
- for (const [workingDir, data] of [...projectGroups].sort(([a], [b]) => a.localeCompare(b))) {
+ for (const [workingDir, data] of [...projectGroups].sort(([a], [b]) => compareSessionListStrings(a, b))) {
sections.push({
key: `project:${workingDir}`,
title: projectTitle(workingDir),
@@ -759,7 +772,7 @@ function normalizeInlinePreview(value: string): string | null {
function compareSessions(a: RemoteSession, b: RemoteSession): number {
const pinnedDiff = Number(!!b.pinnedAt) - Number(!!a.pinnedAt);
if (pinnedDiff !== 0) return pinnedDiff;
- return lastActivity(b).localeCompare(lastActivity(a));
+ return compareSessionListStrings(lastActivity(b), lastActivity(a));
}
function normalizeSearchQuery(value: string | undefined): string {
@@ -885,7 +898,7 @@ function toAutomationGroupListItem(
// 用它的时间会让上游(首页项目卡 latestActivityAt、日期分桶、行右侧时间)把整组排成旧活动。
const latestActivityAt = group.reduce(
(latest, item) =>
- item.lastActivityAt.localeCompare(latest) > 0 ? item.lastActivityAt : latest,
+ compareSessionListStrings(item.lastActivityAt, latest) > 0 ? item.lastActivityAt : latest,
primary.lastActivityAt,
);
return {