auq-mcp-server 3.3.1 → 3.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "auq-mcp-server",
3
- "version": "3.3.1",
3
+ "version": "3.4.0",
4
4
  "main": "dist/index.js",
5
5
  "bin": {
6
6
  "auq": "bin/auq"
@@ -244,7 +244,10 @@ export const OptionsList = ({ isFocused, onSelect, options, selectedOption, show
244
244
  return (React.createElement(Text, { backgroundColor: rowBg, bold: isCustomInputFocused || isSelected, color: rowColor }, fitRow(mainLine)));
245
245
  })(),
246
246
  isCustomInputFocused && onCustomChange && (React.createElement(Box, { borderColor: theme.components.input.borderFocused, borderStyle: "round", marginBottom: 1, marginLeft: 2, marginTop: 0, paddingX: 1, paddingY: 0 },
247
- React.createElement(MultiLineTextInput, { isFocused: true, onChange: onCustomChange, onSubmit: onAdvance, placeholder: t("input.placeholder"), value: customValue }))),
247
+ React.createElement(MultiLineTextInput, { isFocused: true, onChange: onCustomChange, onSubmit: () => {
248
+ onCustomChange?.(customValue);
249
+ onAdvance?.();
250
+ }, placeholder: t("input.placeholder"), value: customValue }))),
248
251
  !isCustomInputFocused && customValue && (React.createElement(Box, { marginLeft: 2, marginTop: 0 },
249
252
  React.createElement(Text, { color: theme.components.options.hint, dimColor: true },
250
253
  customLines.slice(0, 3).map((line, idx) => (React.createElement(React.Fragment, { key: idx },
@@ -275,6 +278,7 @@ export const OptionsList = ({ isFocused, onSelect, options, selectedOption, show
275
278
  })(),
276
279
  isElaborateFocused && onElaborateTextChange && (React.createElement(Box, { borderColor: theme.components.input.borderFocused, borderStyle: "round", marginBottom: 1, marginLeft: 2, marginTop: 0, paddingX: 1, paddingY: 0 },
277
280
  React.createElement(MultiLineTextInput, { enterSubmits: true, isFocused: true, onChange: onElaborateTextChange, onSubmit: () => {
281
+ onElaborateTextChange?.(elaborateText);
278
282
  // Enter/Tab submits and advance
279
283
  // Only call onElaborateSelect if no text (to toggle mark on)
280
284
  // If text exists, mark is already set via onElaborateTextChange
@@ -174,4 +174,24 @@ describe("StepperView SessionUIState boundary", () => {
174
174
  expect(snapshotState.answers.get(0)?.selectedOption).toBe("Python");
175
175
  expect(snapshotState.answers.get(0)?.selectedOption).not.toBe("TypeScript");
176
176
  });
177
+ it("custom text is preserved in answers when advancing via Tab", async () => {
178
+ const onStateSnapshot = vi.fn();
179
+ const initialState = {
180
+ currentQuestionIndex: 0,
181
+ answers: new Map([[0, { customText: "my custom answer" }]]),
182
+ elaborateMarks: new Map(),
183
+ focusContext: "option",
184
+ focusedOptionIndex: 0,
185
+ showReview: false,
186
+ };
187
+ const instance = renderStepper({ onStateSnapshot, initialState });
188
+ instance.stdin.write("\t");
189
+ await vi.waitFor(() => {
190
+ expect(onStateSnapshot).toHaveBeenCalled();
191
+ const lastCall = onStateSnapshot.mock.calls[onStateSnapshot.mock.calls.length - 1];
192
+ const [, snapshotState] = lastCall;
193
+ expect(snapshotState.answers.get(0)?.customText).toBe("my custom answer");
194
+ expect(snapshotState.currentQuestionIndex).toBe(1);
195
+ });
196
+ });
177
197
  });
@@ -65,7 +65,7 @@ export const Footer = ({ focusContext, multiSelect, isReviewScreen = false, show
65
65
  }
66
66
  if (showMultiToggleHint) {
67
67
  bindings.push({
68
- key: "M",
68
+ key: "Ctrl+M",
69
69
  action: isForceMultiActive ? "Disable Multi-select" : "Toggle Multi-select",
70
70
  });
71
71
  }
@@ -89,6 +89,7 @@ export const OptionsList = ({ isFocused, onSelect, options, selectedOption, show
89
89
  setFocusedIndex(Math.max(0, options.length - 1));
90
90
  }
91
91
  else if (key.name === "tab" && !key.shift) {
92
+ onCustomChange?.(customValue);
92
93
  onAdvance?.();
93
94
  }
94
95
  else if (key.name === "return") {
@@ -99,6 +100,7 @@ export const OptionsList = ({ isFocused, onSelect, options, selectedOption, show
99
100
  }
100
101
  else {
101
102
  // Enter: advance to next question
103
+ onCustomChange?.(customValue);
102
104
  onAdvance?.();
103
105
  }
104
106
  }
@@ -116,6 +118,10 @@ export const OptionsList = ({ isFocused, onSelect, options, selectedOption, show
116
118
  setFocusedIndex(customInputIndex);
117
119
  }
118
120
  else if (key.name === "tab" && !key.shift) {
121
+ onElaborateTextChange?.(elaborateText);
122
+ if (!elaborateText.trim()) {
123
+ onElaborateSelect?.();
124
+ }
119
125
  onAdvance?.();
120
126
  }
121
127
  else if (key.name === "return") {
@@ -126,6 +132,7 @@ export const OptionsList = ({ isFocused, onSelect, options, selectedOption, show
126
132
  }
127
133
  else {
128
134
  // Enter: advance to next question
135
+ onElaborateTextChange?.(elaborateText);
129
136
  if (!elaborateText.trim()) {
130
137
  onElaborateSelect?.();
131
138
  }
@@ -545,7 +545,7 @@ export const StepperView = ({ onComplete, onProgress, hasMultipleSessions, initi
545
545
  return;
546
546
  }
547
547
  if (key.name?.toLowerCase() === "m" &&
548
- !key.ctrl &&
548
+ key.ctrl &&
549
549
  !isInTextInput &&
550
550
  !currentQuestion.multiSelect) {
551
551
  handleToggleForceMulti();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "auq-mcp-server",
3
- "version": "3.3.1",
3
+ "version": "3.4.0",
4
4
  "main": "dist/index.js",
5
5
  "bin": {
6
6
  "auq": "bin/auq"