Skip to content

Commit db1e76b

Browse files
committed
Overlay branch overlay/web-import-window on top of origin/main via Merge
* apps/web/src/components/onboarding/WelcomeWizard.tsx • a960d1e38b Overlay branch overlay/web-import-window on top of origin/main via Merge |\ | • f654914 Overlay branch overlay/web-import-window on top of origin/main via Merge | |\ | | • 64bd229 Overlay branch overlay/web-import-window on top of origin/main via Merge | | |\ | | | • 8070a0e fix(web): explain the 30-day import window on /welcome | | |/ • | | 7873f53 fix(web): the Add ChatGPT account dialog animates closed once the account connects (pingdotgg#25868) • | | 1152e91 fix(desktop): run the packaged bundle self-check on macOS artifacts (pingdotgg#25900) • | | 58c31f2 refactor(mobile): settings permission and update checks without sync effects (pingdotgg#25895) • | | 79f6cd3 refactor(mobile): workspace tabs, home filters and connection status derive instead of syncing (pingdotgg#25813)
2 parents 7873f53 + f654914 commit db1e76b

3 files changed

Lines changed: 29 additions & 0 deletions

File tree

‎apps/web/src/components/onboarding/WelcomeWizard.tsx‎

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@ import { useT3ConnectAuthPrompt } from "../clerk/useT3ConnectAuthPrompt";
4242
import { completeOnboarding } from "../../onboarding/firstRun";
4343
import {
4444
groupOnboardingProjects,
45+
isOutsideImportWindow,
4546
partitionOnboardingProjects,
4647
onboardingProjectKey,
4748
resolveOnboardingLandingProject,
@@ -1414,6 +1415,9 @@ function ImportStep({
14141415
title="Import your projects"
14151416
description="Import projects and conversations from Claude Code and Codex on your selected computers."
14161417
>
1418+
<p className="mt-1 text-sm leading-relaxed text-muted-foreground">
1419+
Only conversations from the last 30 days are imported.
1420+
</p>
14171421
{candidates.length > 0 ? (
14181422
<div className="mt-5 flex items-center justify-between gap-3 text-xs text-muted-foreground">
14191423
<span role="status">
@@ -1700,6 +1704,9 @@ function ImportCandidateRow({
17001704
</TooltipTrigger>
17011705
<TooltipPopup variant="code">{candidate.path}</TooltipPopup>
17021706
</Tooltip>
1707+
{isOutsideImportWindow(candidate.lastActiveAt) ? (
1708+
<span className="shrink-0 text-2xs text-muted-foreground">No recent conversations</span>
1709+
) : null}
17031710
<ImportRowMeta
17041711
sources={nested ? null : candidate.sources}
17051712
threadCount={candidate.threadCount}

‎apps/web/src/onboarding/projectImport.logic.test.ts‎

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ import { describe, expect, it } from "vite-plus/test";
33

44
import {
55
groupOnboardingProjects,
6+
isOutsideImportWindow,
67
partitionOnboardingProjects,
78
onboardingProjectKey,
89
resolveOnboardingLandingProject,
@@ -70,6 +71,19 @@ describe("partitionOnboardingProjects", () => {
7071
});
7172
});
7273

74+
describe("isOutsideImportWindow", () => {
75+
it("flags folders whose newest conversation is older than 30 days", () => {
76+
expect(isOutsideImportWindow("2026-07-01T12:00:00.000Z", now)).toBe(true);
77+
expect(isOutsideImportWindow("2026-07-23T12:00:00.000Z", now)).toBe(false);
78+
expect(isOutsideImportWindow("2026-08-20T12:00:00.000Z", now)).toBe(false);
79+
});
80+
81+
it("does not flag unknown or future activity", () => {
82+
expect(isOutsideImportWindow(null, now)).toBe(false);
83+
expect(isOutsideImportWindow("2026-09-01T12:00:00.000Z", now)).toBe(false);
84+
});
85+
});
86+
7387
describe("groupOnboardingProjects", () => {
7488
it("groups clones by origin, keeps local repos separate, and folds non-git folders away", () => {
7589
const main = candidate("/code/t3code", {

‎apps/web/src/onboarding/projectImport.logic.ts‎

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,14 @@ export function partitionOnboardingProjects<T extends AgentSessionProjectCandida
2323
};
2424
}
2525

26+
/**
27+
* The server imports only conversations from the same 30-day window, so importing such a folder
28+
* adds an empty project. An unknown or future time is not treated as stale.
29+
*/
30+
export function isOutsideImportWindow(lastActiveAt: string | null, now = Date.now()): boolean {
31+
return lastActiveAt !== null && Date.parse(lastActiveAt) < now - RECENT_PROJECT_WINDOW_MS;
32+
}
33+
2634
export interface OnboardingProjectGroup<T> {
2735
readonly key: string;
2836
readonly label: string;

0 commit comments

Comments
 (0)