# Files changed · PR \#10226 · pingdotgg/t3code

[View on GitCafe](https://git.cafe/pingdotgg/t3code/pull/10226/diffs)

Repository: [pingdotgg/t3code](https://git.cafe/pingdotgg/t3code)

Visibility: public

[refactor\(web\): keep feature component helpers private](https://git.cafe/pingdotgg/t3code/pull/10226.md)

Version: 3

Head commit: dec7d74ac579e2a16c6d3efcff698aff256d3ed7

Base commit: fba39bb8718bbce6c08c66d7647616b4fe93127f

Comparison base: fba39bb8718bbce6c08c66d7647616b4fe93127f

Showing up to 20 entries from this revision. If the pull request changes, reopen the first page before continuing.

## apps/web/src/components/BranchToolbarEnvModeSelector.tsx

Status: modified; +1; −1

```diff
@@ -18,7 +18,7 @@
   SelectValue,
 } from "./ui/select";
 
-export const PREVIOUS_WORKTREE_SELECT_VALUE = "previous-worktree";
+const PREVIOUS_WORKTREE_SELECT_VALUE = "previous-worktree";
 
 interface BranchToolbarEnvModeSelectorProps {
   envLocked: boolean;
```

## apps/web/src/components/ConfirmDialogHost.tsx

Status: modified; +1; −1

```diff
@@ -23,7 +23,7 @@
   readonly description: string | null;
 };
 
-export function resolveConfirmDialogCopy(message: string): ConfirmationCopy {
+function resolveConfirmDialogCopy(message: string): ConfirmationCopy {
   const normalizedMessage = message.trim();
   const lines = normalizedMessage.split("\n");
   const questionLineIndex = lines.findIndex((line) => line.trim().endsWith("?"));
```

## apps/web/src/components/DiffPanel.tsx

Status: modified; +0; −2

```diff
@@ -104,8 +104,6 @@
   workspaceMutationId: string | null;
 }
 
-export { DiffWorkerPoolProvider } from "./DiffWorkerPoolProvider";
-
 export default function DiffPanel({
   mode = "inline",
   composerDraftTarget,
```

## apps/web/src/components/EnvironmentMachineIcon.tsx

Status: modified; +2; −2

```diff
@@ -23,7 +23,7 @@
 }
 
 /** A Mac mini: squat rounded slab with a front-edge LED. */
-export function MacMiniIcon(props: SVGProps<SVGSVGElement>) {
+function MacMiniIcon(props: SVGProps<SVGSVGElement>) {
   return (
     <LucideLike {...props}>
       <rect width="20" height="8" x="2" y="8" rx="2" />
@@ -33,7 +33,7 @@
 }
 
 /** A Mac Studio: the same slab twice as tall, ports along the front foot. */
-export function MacStudioIcon(props: SVGProps<SVGSVGElement>) {
+function MacStudioIcon(props: SVGProps<SVGSVGElement>) {
   return (
     <LucideLike {...props}>
       <rect width="18" height="14" x="3" y="5" rx="2" />
```

## apps/web/src/components/LegacySidebar.tsx

Status: modified; +1; −1

```diff
@@ -354,7 +354,7 @@
   ) => boolean;
 }
 
-export const SidebarThreadRow = memo(function SidebarThreadRow(props: SidebarThreadRowProps) {
+const SidebarThreadRow = memo(function SidebarThreadRow(props: SidebarThreadRowProps) {
   const {
     orderedProjectThreadKeys,
     isActive,
```

## apps/web/src/components/ProviderUpdateLaunchNotification.logic.ts

Status: modified; +2; −2

```diff
@@ -220,7 +220,7 @@
   return parts.length > 0 ? parts.join("|") : null;
 }
 
-export function formatProviderList(providers: ReadonlyArray<Pick<ServerProvider, "driver">>) {
+function formatProviderList(providers: ReadonlyArray<Pick<ServerProvider, "driver">>) {
   const names = providers.map(
     (provider) => PROVIDER_DISPLAY_NAMES[provider.driver] ?? provider.driver,
   );
@@ -249,7 +249,7 @@
   return view.phase !== "running";
 }
 
-export function getProviderUpdateRunningToastView(providerCount: number): ProviderUpdateToastView {
+function getProviderUpdateRunningToastView(providerCount: number): ProviderUpdateToastView {
   return {
     phase: "running",
     type: "loading",
```

## apps/web/src/components/Sidebar.logic.ts

Status: modified; +4; −11

```diff
@@ -15,7 +15,7 @@
 import { cn } from "../lib/utils";
 import { isLatestTurnSettled } from "../session-logic";
 
-export const THREAD_SELECTION_SAFE_SELECTOR = "[data-thread-item], [data-thread-selection-safe]";
+const THREAD_SELECTION_SAFE_SELECTOR = "[data-thread-item], [data-thread-selection-safe]";
 export const THREAD_JUMP_HINT_SHOW_DELAY_MS = 200;
 // Visible sidebar rows are prewarmed into the thread-detail cache so opening a
 // nearby thread usually reuses an already-hot subscription. Each prewarmed
@@ -23,10 +23,10 @@
 // activities, growing as agents work) for as long as the row stays visible,
 // so this limit is a direct renderer-heap and server-load multiplier — keep
 // it small; cold opens still render instantly from the cached snapshot.
-export const SIDEBAR_THREAD_PREWARM_LIMIT = 3;
+const SIDEBAR_THREAD_PREWARM_LIMIT = 3;
 // A small buffer keeps the next few rows warm without leasing every row that
 // content-visibility leaves mounted below the scroll viewport.
-export const SIDEBAR_ROW_SUBSCRIPTION_OVERSCAN_PX = 160;
+const SIDEBAR_ROW_SUBSCRIPTION_OVERSCAN_PX = 160;
 
 export function useSidebarRowSubscriptionLease(isActive: boolean): {
   readonly leaseLiveStatus: boolean;
@@ -544,13 +544,6 @@
   return "ready";
 }
 
-/** NaN-safe Date.parse for sort comparators: a malformed timestamp must not
-    poison the whole ordering, so it sinks to the epoch instead. */
-export function parseTimestampMs(isoDate: string): number {
-  const parsed = Date.parse(isoDate);
-  return Number.isNaN(parsed) ? 0 : parsed;
-}
-
 /** First VALID timestamp wins: `a ?? b` falls through on null, but a present-
     yet-malformed string must also fall through to the next candidate rather
     than sink the row to the epoch. */
@@ -567,7 +560,7 @@
 
 /** String twin of firstValidTimestampMs for callers that need the ISO string
     (display labels, tick anchors) rather than epoch ms. */
+function firstValidTimestamp(
-export function firstValidTimestamp(
   ...candidates: ReadonlyArray<string | null | undefined>
 ): string | null {
   for (const candidate of candidates) {
```

## apps/web/src/components/ThreadCommandSubtitle.tsx

Status: modified; +1; −2

```diff
@@ -15,8 +15,7 @@
   | "favicon-workspace"
   | "favicon-branch-harness";
 
-export const THREAD_COMMAND_SUBTITLE_VARIANT: ThreadCommandSubtitleVariant =
+const THREAD_COMMAND_SUBTITLE_VARIANT: ThreadCommandSubtitleVariant = "favicon-workspace-harness";
-  "favicon-workspace-harness";
 
 export const COMMAND_PALETTE_META_ICON_CLASS = "size-3 shrink-0 text-muted-foreground/70";
 
```

## apps/web/src/components/chat/ComposerPendingElementContexts.tsx

Status: modified; +1; −1

```diff
@@ -39,7 +39,7 @@
   return lines.join("\n");
 }
 
-export function ComposerPendingElementContextChip({
+function ComposerPendingElementContextChip({
   context,
   onRemove,
 }: ComposerPendingElementContextChipProps) {
```

## apps/web/src/components/chat/ComposerPendingTerminalContexts.tsx

Status: modified; +0; −22

```diff
@@ -1,4 +1,3 @@
-import { cn } from "~/lib/utils";
 import {
   type TerminalContextDraft,
   formatTerminalContextLabel,
@@ -6,11 +5,6 @@
 } from "~/lib/terminalContext";
 import { TerminalContextInlineChip } from "./TerminalContextInlineChip";
 
-interface ComposerPendingTerminalContextsProps {
-  contexts: ReadonlyArray<TerminalContextDraft>;
-  className?: string;
-}
-
 interface ComposerPendingTerminalContextChipProps {
   context: TerminalContextDraft;
 }
@@ -26,19 +20,3 @@
 
   return <TerminalContextInlineChip label={label} tooltipText={tooltipText} expired={expired} />;
 }
-
-export function ComposerPendingTerminalContexts(props: ComposerPendingTerminalContextsProps) {
-  const { contexts, className } = props;
-
-  if (contexts.length === 0) {
-    return null;
-  }
-
-  return (
-    <div className={cn("flex flex-wrap gap-1.5", className)}>
-      {contexts.map((context) => (
-        <ComposerPendingTerminalContextChip key={context.id} context={context} />
-      ))}
-    </div>
-  );
-}
```

## apps/web/src/components/chat/ContextWindowMeter.logic.ts

Status: modified; +2; −2

```diff
@@ -9,8 +9,8 @@
 } from "../../providerInstances";
 import { getTriggerDisplayModelName, type ModelEsque } from "./providerIconUtils";
 
-export const CLAUDE_RESUME_COMPACTION_MINUTES = 70;
-export const CLAUDE_RESUME_COMPACTION_TOKENS = 100_000;
+const CLAUDE_RESUME_COMPACTION_MINUTES = 70;
+const CLAUDE_RESUME_COMPACTION_TOKENS = 100_000;
 
 export function providerSupportsManualCompaction(
   provider: ProviderInstanceEntry | null | undefined,
```

## apps/web/src/components/chat/MessagesTimeline.logic.ts

Status: modified; +8; −9

```diff
@@ -14,7 +14,6 @@
 } from "@t3tools/client-runtime/work-log/presentation";
 export {
   normalizeCompactToolLabel,
-  summarizeToolGroup,
   toolGroupAction,
 } from "@t3tools/client-runtime/work-log/presentation";
 import {
@@ -31,11 +30,11 @@
 import { type MessageId, type OrchestrationLatestTurn, type TurnId } from "@t3tools/contracts";
 import { formatWorkspaceRelativePath } from "../../filePathDisplay";
 
+const TIMELINE_MINIMAP_ITEM_SPACING = 8;
-export const TIMELINE_MINIMAP_ITEM_SPACING = 8;
 export const TIMELINE_MINIMAP_MIN_ITEMS = 2;
+const TIMELINE_MINIMAP_MAX_HEIGHT_CSS = "calc(100vh - 18rem)";
+const TIMELINE_CONTENT_MAX_WIDTH = 768;
-export const TIMELINE_MINIMAP_MAX_HEIGHT_CSS = "calc(100vh - 18rem)";
-export const TIMELINE_CONTENT_MAX_WIDTH = 768;
-export const TIMELINE_MINIMAP_PERSISTENT_GUTTER = 48;
+const TIMELINE_MINIMAP_PERSISTENT_GUTTER = 48;
 
 function singleToolCallLabel(entry: WorkLogEntry): string {
   const toolPresentation = resolveWorkEntryToolPresentation(entry, "completed");
@@ -145,7 +144,7 @@
  * A small pixel band (instead of the 1px isAtEnd epsilon alone) keeps re-arming
  * reliable while streaming content is still growing under the viewport.
  */
-export const TIMELINE_FOLLOW_REARM_THRESHOLD_PX = 40;
+const TIMELINE_FOLLOW_REARM_THRESHOLD_PX = 40;
 
 export function resolveTimelineIsAtEnd(state: TimelineEndState | undefined): boolean | undefined {
   if (!state) {
@@ -207,9 +206,9 @@
   return sideGutter >= TIMELINE_MINIMAP_PERSISTENT_GUTTER;
 }
 
-export const TIMELINE_MINIMAP_HIT_STRIP_LEFT = 12;
-export const TIMELINE_MINIMAP_HIT_STRIP_MAX_WIDTH = 40;
-export const TIMELINE_MINIMAP_EXPANDED_HIT_STRIP_WIDTH = "22rem";
+const TIMELINE_MINIMAP_HIT_STRIP_LEFT = 12;
+const TIMELINE_MINIMAP_HIT_STRIP_MAX_WIDTH = 40;
+const TIMELINE_MINIMAP_EXPANDED_HIT_STRIP_WIDTH = "22rem";
 
 /**
  * The minimap overlays the viewport's left edge while the content column is
```

## apps/web/src/components/chat/externalLinkContextMenu.ts

Status: modified; +1; −1

```diff
@@ -35,7 +35,7 @@
  * whole menu with the one item that cannot be honoured is what left a right-click on a link
  * showing the platform's cut-and-paste menu instead of a way to copy the link.
  */
-export function externalLinkContextMenuItems(options: {
+function externalLinkContextMenuItems(options: {
   readonly canOpenInPreview: boolean;
   readonly threadLinkAction?: "link-to-thread" | "unlink-from-thread" | undefined;
 }): readonly ContextMenuItem<ExternalLinkContextMenuAction>[] {
```

## apps/web/src/components/cloud/CloudEnvironmentConnectList.tsx

Status: modified; +1; −1

```diff
@@ -32,7 +32,7 @@
   readonly connection: EnvironmentConnectionPresentation;
 }
 
-export function RemoteEnvironmentRowsSkeleton() {
+function RemoteEnvironmentRowsSkeleton() {
   return (
     <div className={ITEM_ROW_CLASSNAME}>
       <div className={ITEM_ROW_INNER_CLASSNAME}>
```

## apps/web/src/components/composerFooterLayout.ts

Status: modified; +1; −1

```diff
@@ -1,6 +1,6 @@
 export const COMPOSER_FOOTER_COMPACT_BREAKPOINT_PX = 620;
 export const COMPOSER_FOOTER_WIDE_ACTIONS_COMPACT_BREAKPOINT_PX = 780;
-export const RESTING_COMPOSER_IMAGE_THUMBNAIL_LIMIT = 3;
+const RESTING_COMPOSER_IMAGE_THUMBNAIL_LIMIT = 3;
 
 export function getRestingComposerImagePreviewCounts(imageCount: number): {
   visibleCount: number;
```

## apps/web/src/components/files/projectFilesQueryState.ts

Status: modified; +1; −1

```diff
@@ -33,7 +33,7 @@
   readonly refresh: () => void;
 }
 
-export function getProjectEntriesQueryAtom(environmentId: EnvironmentId, cwd: string) {
+function getProjectEntriesQueryAtom(environmentId: EnvironmentId, cwd: string) {
   return projectEnvironment.listEntries({ environmentId, input: { cwd } });
 }
 
```

## apps/web/src/components/media/MediaActions.tsx

Status: modified; +1; −1

```diff
@@ -33,7 +33,7 @@
 }
 
 /** Explicit byte operations get fresh capabilities without replacing a player's active source. */
-export function useMediaActions(source: MediaActionSource) {
+function useMediaActions(source: MediaActionSource) {
   const createAssetUrl = useAtomQueryRunner(assetEnvironment.createUrl, {
     reportFailure: false,
     refresh: true,
```

## apps/web/src/components/preview/previewAutomationErrors.ts

Status: modified; +1; −1

```diff
@@ -216,7 +216,7 @@
 ]);
 export type PreviewAutomationHostError = typeof PreviewAutomationHostError.Type;
 
-export const isPreviewAutomationHostError = Schema.is(PreviewAutomationHostError);
+const isPreviewAutomationHostError = Schema.is(PreviewAutomationHostError);
 
 export function serializePreviewAutomationHostError(
   error: PreviewAutomationHostError,
```

## apps/web/src/components/preview/previewMiniPlayerLayout.ts

Status: modified; +1; −1

```diff
@@ -4,7 +4,7 @@
 // The mini-player shell straddles this webview at 47 and 49; dialogs begin at 50.
 export const PREVIEW_MINI_PLAYER_WEBVIEW_Z_INDEX = 48;
 export const PREVIEW_MINI_PLAYER_DEFAULT_SIZE = { width: 320, height: 200 } as const;
-export const PREVIEW_MINI_PLAYER_MIN_SIZE = { width: 240, height: 150 } as const;
+const PREVIEW_MINI_PLAYER_MIN_SIZE = { width: 240, height: 150 } as const;
 
 export function clampPreviewMiniPlayerSize(
   size: PreviewMiniPlayerSize,
```

## apps/web/src/components/projectScriptEditor.tsx

Status: modified; +1; −1

```diff
@@ -49,7 +49,7 @@
 import { Switch } from "./ui/switch";
 import { Textarea } from "./ui/textarea";
 
-export const SCRIPT_ICONS: Array<{ id: ProjectScriptIcon; label: string }> = [
+const SCRIPT_ICONS: Array<{ id: ProjectScriptIcon; label: string }> = [
   { id: "play", label: "Play" },
   { id: "test", label: "Test" },
   { id: "lint", label: "Lint" },
```

[Next page](https://git.cafe/pingdotgg/t3code/pull/10226/diffs?after=ImFwcHMvd2ViL3NyYy9jb21wb25lbnRzL3Byb2plY3RTY3JpcHRFZGl0b3IudHN4Ig&expectedVersion=3&format=markdown)
