Skip to content
Source
Sign inSign up
pingdotgg/t3code

fix(composer): persist model picks before the next message #31739

Mergedshivamhwp(GitHub profile, opens in a new tab)merged 11 commits intomain fromrefs/pull/31739/headmerged by shivamhwp(GitHub profile, opens in a new tab) View on GitHub

Showing 19 changed files with 58 additions and 2 deletions (loading 16).

x
0 of 19 viewed, 19 left
2 additions and 2 deletionsapps/mobile/src/features/threads/ThreadSettingsSheet.tsxModified
View file
@@ -88,7 +88,7 @@
} from "../../state/use-composer-drafts";
import { useQuietThreadStructure } from "../../state/use-thread-detail";
import { activeComposerDraftKey, useQueuedRunEdit } from "../../state/queued-run-edit";
-import { updateThreadDraftModelSelection } from "../../state/use-thread-composer-state";
+import { selectThreadModel } from "../../state/thread-model-selection";
import { useThreadSelection } from "../../state/use-thread-selection";
import { threadAllowsProviderSwitch } from "../../state/thread-provider-switching";
import { environmentServerConfigsAtom, serverEnvironment } from "../../state/server";
@@ -1338,7 +1338,7 @@
option.selection.model === modelSelection.model,
) ?? null;
const updateModelSelection = (selection: ModelSelection) =>
- updateThreadDraftModelSelection(threadKey, selection);
+ selectThreadModel(route.params, selection);
return (
<ThreadSettingsPickerScreen
54 additions and 0 deletionsapps/mobile/src/state/thread-model-selection.tsAdded
View file
@@ -0,0 +1,54 @@
+import { runAtomCommand, squashAtomCommandFailure } from "@t3tools/client-runtime/state/runtime";
+import {
+ AuthOrchestrationOperateScope,
+ type EnvironmentId,
+ type ModelSelection,
+ type ThreadId,
+} from "@t3tools/contracts";