Uh oh!
There was an error while loading. Please reload this page.
fix(desktop): preserve selected model during session promotion - #34466
Conversation
Thanks for your contribution! This PR doesn't have a linked issue. All PRs must reference an existing issue. Please:
See CONTRIBUTING.md for details. |
Thanks for updating your PR! It now meets our contributing guidelines. 👍 |
The following comment was made by an LLM, it may be inaccurate: Potential duplicate found:
This PR appears to address the same issue—preserving the model selection in the composer/prompt input. The current PR (#34466) specifically targets the desktop context during session promotion, while #33858 may cover a related or overlapping scenario with draft model selection. You should check if #33858 already resolves this issue or if the fixes are complementary. |
Uh oh!
There was an error while loading. Please reload this page.
Issue for this PR
Closes#34466
Type of change
What does this PR do?
Fixes a composer model picker flicker when submitting a new session with a non-default model selected.
During new-session promotion, the local draft model selection was cleared before the routed session state became available. That left the picker with no scoped selection for a moment, so it fell back to the configured default model, then switched back once the promoted session selection was restored.
This keeps the promoted model selection in an in-memory handoff state until the session route consumes it, so the picker continues showing the selected model throughout the transition.
How did you verify your code works?
bun run typecheckfrompackages/appbun test src/components/prompt-input/submit.test.tsfrompackages/appScreenshots / recordings
Before
Screenshot.2026-06-29.at.16.03.49.mp4
After
Screenshot.2026-06-29.at.19.06.55.mp4
Checklist