Fix post-rebase mobile typecheck issues
Co-authored-by: codex <[email protected]>
This commit is contained in:
1 parent
034a8bcab3
commit
932ec190ed
26 files changed
+45
-34
No files matched your search
@@ -9,7 +9,6 @@ import { useSafeAreaInsets } from "react-native-safe-area-context";
|
||||
import { useThemeColor } from "../../lib/useThemeColor";
|
||||
|
||||
import { EnvironmentId, type ModelSelection } from "@t3tools/contracts";
|
||||
import { CLAUDE_CODE_EFFORT_OPTIONS } from "@t3tools/contracts";
|
||||
|
||||
import { AppText as Text, AppTextInput as TextInput } from "../../components/AppText";
|
||||
import { ComposerAttachmentStrip } from "../../components/ComposerAttachmentStrip";
|
||||
@@ -20,6 +19,7 @@ import { convertPastedImagesToAttachments, pickComposerImages } from "../../lib/
|
||||
import { buildThreadRoutePath } from "../../lib/routes";
|
||||
import { useRemoteCatalog } from "../../state/use-remote-catalog";
|
||||
import { useNativePaste } from "../../hooks/useNativePaste";
|
||||
import { CLAUDE_AGENT_EFFORT_OPTIONS } from "./claudeEffortOptions";
|
||||
import { branchBadgeLabel, useNewTaskFlow } from "./new-task-flow-provider";
|
||||
import { useProjectActions } from "./use-project-actions";
|
||||
|
||||
@@ -131,7 +131,7 @@ export function NewTaskDraftScreen(props: {
|
||||
id: "options-effort",
|
||||
title: "Effort",
|
||||
subtitle: `${flow.effort.charAt(0).toUpperCase()}${flow.effort.slice(1)}`,
|
||||
subactions: CLAUDE_CODE_EFFORT_OPTIONS.map((level) => ({
|
||||
subactions: CLAUDE_AGENT_EFFORT_OPTIONS.map((level) => ({
|
||||
id: `options:effort:${level}`,
|
||||
title: `${level}${level === "high" ? " (default)" : ""}`,
|
||||
state: flow.effort === level ? ("on" as const) : undefined,
|
||||
|
||||
@@ -7,7 +7,6 @@ import type {
|
||||
RuntimeMode,
|
||||
ServerConfig as T3ServerConfig,
|
||||
} from "@t3tools/contracts";
|
||||
import { CLAUDE_CODE_EFFORT_OPTIONS } from "@t3tools/contracts";
|
||||
import {
|
||||
detectComposerTrigger,
|
||||
replaceTextRange,
|
||||
@@ -43,6 +42,7 @@ import {
|
||||
scoreQueryMatch,
|
||||
} from "@t3tools/shared/searchRanking";
|
||||
import { getEnvironmentClient } from "../../state/use-remote-environment-registry";
|
||||
import { CLAUDE_AGENT_EFFORT_OPTIONS } from "./claudeEffortOptions";
|
||||
import { ComposerCommandPopover, type ComposerCommandItem } from "./ComposerCommandPopover";
|
||||
|
||||
/**
|
||||
@@ -494,7 +494,7 @@ export const ThreadComposer = memo(function ThreadComposer(props: ThreadComposer
|
||||
id: "options-effort",
|
||||
title: "Effort",
|
||||
subtitle: `${currentEffort.charAt(0).toUpperCase()}${currentEffort.slice(1)}`,
|
||||
subactions: CLAUDE_CODE_EFFORT_OPTIONS.map((level) => ({
|
||||
subactions: CLAUDE_AGENT_EFFORT_OPTIONS.map((level) => ({
|
||||
id: `options:effort:${level}`,
|
||||
title: `${level}${level === "high" ? " (default)" : ""}`,
|
||||
state: currentEffort === level ? ("on" as const) : undefined,
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
import type { ClaudeAgentEffort } from "@t3tools/contracts";
|
||||
|
||||
export const CLAUDE_AGENT_EFFORT_OPTIONS = [
|
||||
"low",
|
||||
"medium",
|
||||
"high",
|
||||
"xhigh",
|
||||
"max",
|
||||
"ultrathink",
|
||||
] as const satisfies readonly ClaudeAgentEffort[];
|
||||
@@ -1,7 +1,7 @@
|
||||
import React, { useCallback, useEffect, useMemo, useState } from "react";
|
||||
|
||||
import type {
|
||||
ClaudeCodeEffort,
|
||||
ClaudeAgentEffort,
|
||||
EnvironmentId,
|
||||
GitBranch,
|
||||
ModelSelection,
|
||||
@@ -76,7 +76,7 @@ type NewTaskFlowContextValue = {
|
||||
readonly availableBranches: ReadonlyArray<GitBranch>;
|
||||
readonly runtimeMode: RuntimeMode;
|
||||
readonly interactionMode: ProviderInteractionMode;
|
||||
readonly effort: ClaudeCodeEffort;
|
||||
readonly effort: ClaudeAgentEffort;
|
||||
readonly fastMode: boolean;
|
||||
readonly contextWindow: string;
|
||||
readonly expandedProvider: string | null;
|
||||
@@ -106,7 +106,7 @@ type NewTaskFlowContextValue = {
|
||||
readonly loadBranches: () => Promise<void>;
|
||||
readonly setRuntimeMode: (value: RuntimeMode) => void;
|
||||
readonly setInteractionMode: (value: ProviderInteractionMode) => void;
|
||||
readonly setEffort: (value: ClaudeCodeEffort) => void;
|
||||
readonly setEffort: (value: ClaudeAgentEffort) => void;
|
||||
readonly setFastMode: (value: boolean) => void;
|
||||
readonly setContextWindow: (value: string) => void;
|
||||
readonly setExpandedProvider: (value: string | null) => void;
|
||||
@@ -161,7 +161,7 @@ export function NewTaskFlowProvider(props: React.PropsWithChildren) {
|
||||
const [interactionMode, setInteractionMode] = useState<ProviderInteractionMode>(
|
||||
DEFAULT_PROVIDER_INTERACTION_MODE,
|
||||
);
|
||||
const [effort, setEffort] = useState<ClaudeCodeEffort>("high");
|
||||
const [effort, setEffort] = useState<ClaudeAgentEffort>("high");
|
||||
const [fastMode, setFastMode] = useState(false);
|
||||
const [contextWindow, setContextWindow] = useState("1M");
|
||||
const [expandedProvider, setExpandedProvider] = useState<string | null>(null);
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
{
|
||||
"extends": "expo/tsconfig.base",
|
||||
"compilerOptions": {
|
||||
"allowImportingTsExtensions": true,
|
||||
"strict": true
|
||||
}
|
||||
}
|
||||
@@ -7,8 +7,8 @@ import type {
|
||||
TerminalEvent,
|
||||
} from "@t3tools/contracts";
|
||||
|
||||
import type { KnownEnvironment } from "./knownEnvironment";
|
||||
import type { WsRpcClient } from "./wsRpcClient";
|
||||
import type { KnownEnvironment } from "./knownEnvironment.ts";
|
||||
import type { WsRpcClient } from "./wsRpcClient.ts";
|
||||
|
||||
export interface EnvironmentConnection {
|
||||
readonly kind: "primary" | "saved";
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { AtomRegistry } from "effect/unstable/reactivity";
|
||||
import { afterEach, describe, expect, it } from "vitest";
|
||||
|
||||
import { createEnvironmentRuntimeManager } from "./environmentRuntimeState";
|
||||
import { createEnvironmentRuntimeManager } from "./environmentRuntimeState.ts";
|
||||
|
||||
let atomRegistry = AtomRegistry.make();
|
||||
|
||||
|
||||
@@ -14,7 +14,7 @@ import {
|
||||
type GitActionClient,
|
||||
createGitActionManager,
|
||||
EMPTY_GIT_ACTION_STATE,
|
||||
} from "./gitActionState";
|
||||
} from "./gitActionState.ts";
|
||||
|
||||
let atomRegistry = AtomRegistry.make();
|
||||
|
||||
|
||||
@@ -15,8 +15,8 @@ import type {
|
||||
} from "@t3tools/contracts";
|
||||
import { Atom, type AtomRegistry } from "effect/unstable/reactivity";
|
||||
|
||||
import { buildGitActionProgressStages } from "./gitActions";
|
||||
import type { WsRpcClient } from "./wsRpcClient";
|
||||
import { buildGitActionProgressStages } from "./gitActions.ts";
|
||||
import type { WsRpcClient } from "./wsRpcClient.ts";
|
||||
|
||||
export type GitActionOperation =
|
||||
| "refresh_status"
|
||||
|
||||
@@ -7,7 +7,7 @@ import {
|
||||
EMPTY_GIT_BRANCH_STATE,
|
||||
gitBranchStateAtom,
|
||||
type GitBranchClient,
|
||||
} from "./gitBranchState";
|
||||
} from "./gitBranchState.ts";
|
||||
|
||||
let atomRegistry = AtomRegistry.make();
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import type { GitBranch, GitListBranchesInput, GitListBranchesResult } from "@t3tools/contracts";
|
||||
import { Atom, type AtomRegistry } from "effect/unstable/reactivity";
|
||||
|
||||
import type { WsRpcClient } from "./wsRpcClient";
|
||||
import type { WsRpcClient } from "./wsRpcClient.ts";
|
||||
|
||||
export interface GitBranchTarget {
|
||||
readonly environmentId: string | null;
|
||||
|
||||
@@ -2,7 +2,7 @@ import type { GitStatusResult } from "@t3tools/contracts";
|
||||
import { AtomRegistry } from "effect/unstable/reactivity";
|
||||
import { afterEach, describe, expect, it, vi } from "vitest";
|
||||
|
||||
import { type GitStatusClient, createGitStatusManager } from "./gitStatusState";
|
||||
import { type GitStatusClient, createGitStatusManager } from "./gitStatusState.ts";
|
||||
|
||||
/* ─── Test helpers ──────────────────────────────────────────────────── */
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import type { GitManagerServiceError, GitStatusResult } from "@t3tools/contracts";
|
||||
import type { Cause } from "effect";
|
||||
import { Atom, type AtomRegistry } from "effect/unstable/reactivity";
|
||||
import type { WsRpcClient } from "./wsRpcClient";
|
||||
import type { WsRpcClient } from "./wsRpcClient.ts";
|
||||
|
||||
/* ─── Types ─────────────────────────────────────────────────────────── */
|
||||
|
||||
|
||||
@@ -4,7 +4,7 @@ import {
|
||||
DEFAULT_RECONNECT_BACKOFF,
|
||||
getReconnectDelayMs,
|
||||
type ReconnectBackoffConfig,
|
||||
} from "./reconnectBackoff";
|
||||
} from "./reconnectBackoff.ts";
|
||||
|
||||
describe("getReconnectDelayMs", () => {
|
||||
it("returns exponential delays with default config", () => {
|
||||
|
||||
@@ -3,7 +3,7 @@ import { describe, expect, it } from "vitest";
|
||||
import { ProjectId, ThreadId } from "@t3tools/contracts";
|
||||
import type { OrchestrationShellSnapshot, OrchestrationShellStreamEvent } from "@t3tools/contracts";
|
||||
|
||||
import { applyShellStreamEvent } from "./shellSnapshotReducer";
|
||||
import { applyShellStreamEvent } from "./shellSnapshotReducer.ts";
|
||||
|
||||
const baseSnapshot: OrchestrationShellSnapshot = {
|
||||
snapshotSequence: 0,
|
||||
|
||||
@@ -3,7 +3,7 @@ import { afterEach, describe, expect, it } from "vitest";
|
||||
|
||||
import { ProjectId, ThreadId, type OrchestrationShellSnapshot } from "@t3tools/contracts";
|
||||
|
||||
import { createShellSnapshotManager } from "./shellSnapshotState";
|
||||
import { createShellSnapshotManager } from "./shellSnapshotState.ts";
|
||||
|
||||
let atomRegistry = AtomRegistry.make();
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import type { OrchestrationShellSnapshot, OrchestrationShellStreamEvent } from "@t3tools/contracts";
|
||||
import { Atom, type AtomRegistry } from "effect/unstable/reactivity";
|
||||
|
||||
import { applyShellStreamEvent } from "./shellSnapshotReducer";
|
||||
import { applyShellStreamEvent } from "./shellSnapshotReducer.ts";
|
||||
|
||||
export interface ShellSnapshotState {
|
||||
readonly data: OrchestrationShellSnapshot | null;
|
||||
|
||||
@@ -3,7 +3,7 @@ import { afterEach, describe, expect, it } from "vitest";
|
||||
|
||||
import type { TerminalSessionSnapshot } from "@t3tools/contracts";
|
||||
|
||||
import { createTerminalSessionManager } from "./terminalSessionState";
|
||||
import { createTerminalSessionManager } from "./terminalSessionState.ts";
|
||||
|
||||
let atomRegistry = AtomRegistry.make();
|
||||
|
||||
|
||||
@@ -11,7 +11,7 @@ import {
|
||||
} from "@t3tools/contracts";
|
||||
import type { OrchestrationEvent, OrchestrationThread } from "@t3tools/contracts";
|
||||
|
||||
import { applyThreadDetailEvent } from "./threadDetailReducer";
|
||||
import { applyThreadDetailEvent } from "./threadDetailReducer.ts";
|
||||
|
||||
const baseEventFields = {
|
||||
eventId: EventId.make("event-1"),
|
||||
|
||||
@@ -11,7 +11,7 @@ import {
|
||||
type OrchestrationThreadStreamItem,
|
||||
} from "@t3tools/contracts";
|
||||
|
||||
import { createThreadDetailManager, type ThreadDetailClient } from "./threadDetailState";
|
||||
import { createThreadDetailManager, type ThreadDetailClient } from "./threadDetailState.ts";
|
||||
|
||||
let atomRegistry = AtomRegistry.make();
|
||||
|
||||
|
||||
@@ -13,8 +13,8 @@ import {
|
||||
DEFAULT_THREAD_DETAIL_LIMITS,
|
||||
applyThreadDetailEvent,
|
||||
type ThreadDetailRetentionLimits,
|
||||
} from "./threadDetailReducer";
|
||||
import type { WsRpcClient } from "./wsRpcClient";
|
||||
} from "./threadDetailReducer.ts";
|
||||
import type { WsRpcClient } from "./wsRpcClient.ts";
|
||||
|
||||
export interface ThreadDetailState {
|
||||
readonly data: OrchestrationThread | null;
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { describe, expect, it } from "vitest";
|
||||
|
||||
import { isTransportConnectionErrorMessage, sanitizeThreadErrorMessage } from "./transportError";
|
||||
import { isTransportConnectionErrorMessage, sanitizeThreadErrorMessage } from "./transportError.ts";
|
||||
|
||||
describe("isTransportConnectionErrorMessage", () => {
|
||||
it("returns true for SocketCloseError", () => {
|
||||
|
||||
@@ -12,8 +12,8 @@ import {
|
||||
import { applyGitStatusStreamEvent } from "@t3tools/shared/git";
|
||||
import { Effect, Stream } from "effect";
|
||||
|
||||
import { type WsRpcProtocolClient } from "./wsRpcProtocol";
|
||||
import { WsTransport } from "./wsTransport";
|
||||
import { type WsRpcProtocolClient } from "./wsRpcProtocol.ts";
|
||||
import { WsTransport } from "./wsTransport.ts";
|
||||
|
||||
type RpcTag = keyof WsRpcProtocolClient & string;
|
||||
type RpcMethod<TTag extends RpcTag> = WsRpcProtocolClient[TTag];
|
||||
|
||||
@@ -7,7 +7,7 @@ import {
|
||||
DEFAULT_RECONNECT_BACKOFF,
|
||||
getReconnectDelayMs,
|
||||
type ReconnectBackoffConfig,
|
||||
} from "./reconnectBackoff";
|
||||
} from "./reconnectBackoff.ts";
|
||||
|
||||
export interface WsProtocolLifecycleHandlers {
|
||||
readonly onAttempt?: (socketUrl: string) => void;
|
||||
|
||||
@@ -1,14 +1,14 @@
|
||||
import { Cause, Duration, Effect, Exit, ManagedRuntime, Scope, Stream } from "effect";
|
||||
import { RpcClient } from "effect/unstable/rpc";
|
||||
|
||||
import { isTransportConnectionErrorMessage } from "./transportError";
|
||||
import { isTransportConnectionErrorMessage } from "./transportError.ts";
|
||||
import {
|
||||
createWsRpcProtocolLayer,
|
||||
makeWsRpcProtocolClient,
|
||||
type WsProtocolLifecycleHandlers,
|
||||
type WsRpcProtocolClient,
|
||||
type WsRpcProtocolSocketUrlProvider,
|
||||
} from "./wsRpcProtocol";
|
||||
} from "./wsRpcProtocol.ts";
|
||||
|
||||
interface SubscribeOptions {
|
||||
readonly retryDelay?: Duration.Input;
|
||||
|
||||
@@ -7,7 +7,7 @@ import {
|
||||
issueRemoteWebSocketToken,
|
||||
resolveRemotePairingTarget,
|
||||
resolveRemoteWebSocketConnectionUrl,
|
||||
} from "./remote";
|
||||
} from "./remote.ts";
|
||||
|
||||
const originalFetch = globalThis.fetch;
|
||||
|
||||
|
||||
Reference in new issue
Block a user