feat(web): first run is one Welcome page instead of a 3-step wizard #33209
Mergedt3dotgg(GitHub profile, opens in a new tab)merged 23 commits into
main fromrefs/pull/33209/headmerged by t3dotgg(GitHub profile, opens in a new tab) View on GitHubgithub-actions[bot](GitHub profile, opens in a new tab) added labelsvouch:trusted
github-actions[bot](GitHub profile, opens in a new tab) added labelssize:XXL
- apps/web/src/components/onboarding/WelcomePage.tsx line 507Resolvedby macroscopeapp[bot](GitHub profile, opens in a new tab)@@ -0,0 +488,21 @@488+ serverConfig.environment.platform.os,489+ ),490+ keybindings: serverConfig.keybindings,491+ });492+ };493+494+ // "Use existing CLI" opens the CLI's terminal once Codex has checked the CLI.495+ const cliProvider =496+ cliTerminalFor === null497+ ? undefined498+ : providers?.find((provider) => provider.instanceId === cliTerminalFor);499+ const cliStep =500+ cliProvider === undefined ? "done" : cliTerminalStep(cliProvider, serverConfig?.settings);501+ if (cliProvider !== undefined && cliStep !== "wait") {502+ setCliTerminalFor(null);503+ if (cliStep === "open") openTerminal(cliProvider);504+ }505+506+ const turnOn = async (provider: ServerProvider) => {507+ if (serverConfig === null) return;508+ const instance = serverConfig.settings.providerInstances[provider.instanceId] ?? {
- apps/web/src/components/settings/AddCodexAccountDialog.browser.test.tsx line 119OutdatedResolvedby macroscopeapp[bot](GitHub profile, opens in a new tab)@@ -102,9 +110,10 @@102110 using _style = { [Symbol.dispose]: () => style.remove() };103111 await using _screen = await render(104112 <AppAtomRegistryProvider>105- <Owner onClose={onClose} />113+ <Owner onClose={onClose} onAccountCreated={onAccountCreated} />106114 </AppAtomRegistryProvider>,107115 );108116109117 await userEvent.click(page.getByRole("button", { name: "Continue" }));110118 const instanceId = createdInstanceId();119+ expect(onAccountCreated).toHaveBeenCalledWith(instanceId, expect.any(String));
- apps/web/src/components/onboarding/WelcomePage.tsx line 1517OutdatedResolvedby macroscopeapp[bot](GitHub profile, opens in a new tab)@@ -0,0 +1497,21 @@1497+ importedThreadCountRef.current,1498+ );1499+ if (!completed) setIsImporting(false);1500+ });1501+ };1502+1503+ const runImport = async (selection: typeof candidates) => {1504+ if (isImporting) return;1505+ const hasAccess = () =>1506+ selection.every((candidate) =>1507+ readEnvironmentScope(candidate.environmentId, AuthOrchestrationOperateScope),1508+ );1509+ // The permission message shows from the session's scopes.1510+ const stopForDeniedAccess = () => setIsImporting(false);1511+ if (!hasAccess()) {1512+ stopForDeniedAccess();1513+ return;1514+ }1515+ setIsImporting(true);1516+ importWarningRef.current = "";1517+ importedThreadCountRef.current = 0;
- apps/web/src/components/onboarding/WelcomePage.tsx lines 1355 to 1617Resolvedby t3dotgg(GitHub profile, opens in a new tab)@@ -0,0 +1617,21 @@1617+ importWarningRef.current = `Imported ${importedThreadCount} ${importedThreadCount === 1 ? "thread" : "threads"}. Some thread history could not be imported.`;1618+ } else {1619+ importWarningRef.current = "Could not import thread history.";1620+ }1621+ }1622+ finishAfterImport();1623+ };1624+1625+ return {1626+ canWrite,1627+ candidates,1628+ isNew,1629+ recent,1630+ selected,1631+ selectedKeys,1632+ setSelectedKeys,1633+ visibleImportError,1634+ runImport,1635+ finishAfterImport,1636+ };1637+}
- apps/web/src/components/onboarding/WelcomePage.tsx lines 1448 to 1448Resolvedby macroscopeapp[bot](GitHub profile, opens in a new tab)@@ -0,0 +1428,21 @@1428+ const selectedKeys = new Set(selected.map((candidate) => candidate.key));1429+ const setSelectedKeys = (keys: ReadonlySet<string>, { optedOut = false } = {}) =>1430+ onImportSelectionChange({1431+ knownKeys: candidates.map((candidate) => candidate.key),1432+ keys: [...keys],1433+ optedOut,1434+ });1435+1436+ const canWrite = scans.every((scan) => writableEnvironments.has(scan.environmentId));1437+ const canImport = selected.every((candidate) =>1438+ writableEnvironments.has(candidate.environmentId),1439+ );1440+ const visibleImportError = canWrite && canImport ? "" : IMPORT_PERMISSION_MESSAGE;1441+1442+ const importedThreadTotal = () =>1443+ lastImportSelectionRef.current.reduce(1444+ (total, key) => total + (importedThreadsRef.current.get(key) ?? 0),1445+ 0,1446+ );1447+1448+ const finishAfterImport = () => {
- @@ -0,0 +84,21 @@84+Imported projects include Claude, Codex and Pi conversations active within the last85+30 days. You can continue those conversations in T3 Code. Pi is off by default:86+open **Add more agents** and select **Turn on** next to Pi, and the page looks for87+its sessions too. Pi sessions88+are read from each enabled Pi provider's session directory, which follows89+`PI_CODING_AGENT_SESSION_DIR` and `PI_CODING_AGENT_DIR` in its environment. A90+Pi conversation imports its active branch, the one Pi reopens.91+92+Conversation import is best effort. T3 Code keeps the first user prompt and the93+newest remaining visible user and assistant messages, with 200 messages total.94+It omits tool activity and attachments. For Codex, it omits generated setup95+context only when a canonical user event and a valid shared turn ID identify the96+same user turn. Ambiguous legacy or response-only context stays in the imported97+conversation so T3 Code does not remove user text. It reads one conversation at98+a time and skips files larger than 4 GiB. It also skips a conversation when the99+message text and metadata it keeps need more than 32 MiB of memory. Tool output100+does not count toward that limit. It ignores malformed records and skips101+unreadable or unparseable conversations.102+103+Each import attempt reads up to 100 conversation files and 4 GiB per project,104+with up to 100,000 input records. To continue a large batch, open the Welcome page again
t3dotgg(GitHub profile, opens in a new tab) closed this
Sign in to join this conversation.






macroscopeapp[bot](GitHub profile, opens in a new tab) reviewed