The best way to control Claude Code, Codex and more from any computer or phone
Mirrored from https://github.com/Camo67/t3code.git
Synced Nov 22, 08:15 UTC
fix(shared): /Model with a query still opens the model picker (#27837)
samkelly880 committed
Nov 1, 2026 at 15:42 UTC
6dddccb244c2496f1fb800af5e68319063e4fe2f
2 files changed
+11
-1
packages/shared/src/composerTrigger.test.ts
+10
@@ -18,6 +18,16 @@ describe("detectComposerTrigger", () => {
18
});
19
});
20
21
+ it.each(["/Model opus", "/MODEL opus"])(
22
+ "opens the model picker for capitalized %j the same as /model",
23
+ (text) => {
24
+ expect(detectComposerTrigger(text, text.length)).toMatchObject({
25
+ kind: "slash-model",
26
+ query: "opus",
27
+ });
28
+ },
29
+ );
30
+
31
it.each(["Use /", "Use /review"])("detects the inline slash token in %j", (text) => {
32
expect(detectComposerTrigger(text, text.length)).toEqual({
33
kind: "slash-command",
packages/shared/src/composerTrigger.ts
+1
-1
@@ -100,7 +100,7 @@ export function detectComposerTrigger(
100
};
101
}
102
103
- const modelMatch = /^\/model(?:\s+(.*))?$/.exec(linePrefix);
103
+ const modelMatch = /^\/model(?:\s+(.*))?$/i.exec(linePrefix);
104
if (modelMatch) {
105
return {
106
kind: "slash-model",