auq-mcp-server 3.2.7 → 3.2.9
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
|
@@ -369,11 +369,24 @@ export const StepperView = ({ onComplete, onProgress, hasMultipleSessions, initi
|
|
|
369
369
|
};
|
|
370
370
|
// Handle elaborate text change
|
|
371
371
|
const handleElaborateTextChange = (text) => {
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
372
|
+
if (!text.trim()) {
|
|
373
|
+
// Auto-remove elaborate mark when text is cleared
|
|
374
|
+
setElaborateMarks((prev) => {
|
|
375
|
+
if (prev.has(currentQuestionIndex)) {
|
|
376
|
+
const newMarks = new Map(prev);
|
|
377
|
+
newMarks.delete(currentQuestionIndex);
|
|
378
|
+
return newMarks;
|
|
379
|
+
}
|
|
380
|
+
return prev;
|
|
381
|
+
});
|
|
382
|
+
}
|
|
383
|
+
else {
|
|
384
|
+
setElaborateMarks((prev) => {
|
|
385
|
+
const newMarks = new Map(prev);
|
|
386
|
+
newMarks.set(currentQuestionIndex, text);
|
|
387
|
+
return newMarks;
|
|
388
|
+
});
|
|
389
|
+
}
|
|
377
390
|
};
|
|
378
391
|
// Keyboard handling for abandoned confirmation dialog
|
|
379
392
|
useInput((input, key) => {
|
|
@@ -82,7 +82,8 @@ export const OptionsList = ({ isFocused, onSelect, options, selectedOption, show
|
|
|
82
82
|
setFocusedIndex(newIndex);
|
|
83
83
|
return;
|
|
84
84
|
}
|
|
85
|
-
// When custom input is focused,
|
|
85
|
+
// When custom input is focused, only intercept navigation keys
|
|
86
|
+
// Let native <input> handle character input (IME, clipboard, etc.)
|
|
86
87
|
if (isCustomInputFocused) {
|
|
87
88
|
if (key.name === "escape") {
|
|
88
89
|
setFocusedIndex(Math.max(0, options.length - 1));
|
|
@@ -91,6 +92,7 @@ export const OptionsList = ({ isFocused, onSelect, options, selectedOption, show
|
|
|
91
92
|
onAdvance?.();
|
|
92
93
|
}
|
|
93
94
|
else if (key.name === "return") {
|
|
95
|
+
key.preventDefault(); // prevent <input> onChange from overwriting state
|
|
94
96
|
if (key.shift) {
|
|
95
97
|
// Shift+Enter: insert newline
|
|
96
98
|
onCustomChange?.(customValue + "\n");
|
|
@@ -100,22 +102,10 @@ export const OptionsList = ({ isFocused, onSelect, options, selectedOption, show
|
|
|
100
102
|
onAdvance?.();
|
|
101
103
|
}
|
|
102
104
|
}
|
|
103
|
-
else if (key.name === "backspace" || key.name === "delete") {
|
|
104
|
-
if (customValue.length > 0) {
|
|
105
|
-
onCustomChange?.(customValue.slice(0, -1));
|
|
106
|
-
}
|
|
107
|
-
}
|
|
108
|
-
else if (key.sequence && !key.ctrl && !key.meta && key.name !== "up" && key.name !== "down") {
|
|
109
|
-
const sanitized = key.sequence
|
|
110
|
-
.replace(/\x1b?\[<[\d;]*[Mm]/g, '')
|
|
111
|
-
.replace(/\[?[OI]/g, '');
|
|
112
|
-
if (sanitized.length > 0) {
|
|
113
|
-
onCustomChange?.(customValue + sanitized);
|
|
114
|
-
}
|
|
115
|
-
}
|
|
116
105
|
return;
|
|
117
106
|
}
|
|
118
|
-
// When elaborate input is focused,
|
|
107
|
+
// When elaborate input is focused, only intercept navigation keys
|
|
108
|
+
// Let native <input> handle character input (IME, clipboard, etc.)
|
|
119
109
|
if (isElaborateFocused) {
|
|
120
110
|
if (key.name === "escape") {
|
|
121
111
|
setFocusedIndex(customInputIndex);
|
|
@@ -124,6 +114,7 @@ export const OptionsList = ({ isFocused, onSelect, options, selectedOption, show
|
|
|
124
114
|
onAdvance?.();
|
|
125
115
|
}
|
|
126
116
|
else if (key.name === "return") {
|
|
117
|
+
key.preventDefault(); // prevent <input> onChange from overwriting state
|
|
127
118
|
if (key.shift) {
|
|
128
119
|
// Shift+Enter: insert newline
|
|
129
120
|
onElaborateTextChange?.(elaborateText + "\n");
|
|
@@ -136,19 +127,6 @@ export const OptionsList = ({ isFocused, onSelect, options, selectedOption, show
|
|
|
136
127
|
onAdvance?.();
|
|
137
128
|
}
|
|
138
129
|
}
|
|
139
|
-
else if (key.name === "backspace" || key.name === "delete") {
|
|
140
|
-
if (elaborateText.length > 0) {
|
|
141
|
-
onElaborateTextChange?.(elaborateText.slice(0, -1));
|
|
142
|
-
}
|
|
143
|
-
}
|
|
144
|
-
else if (key.sequence && !key.ctrl && !key.meta && key.name !== "up" && key.name !== "down") {
|
|
145
|
-
const sanitized = key.sequence
|
|
146
|
-
.replace(/\x1b?\[<[\d;]*[Mm]/g, '')
|
|
147
|
-
.replace(/\[?[OI]/g, '');
|
|
148
|
-
if (sanitized.length > 0) {
|
|
149
|
-
onElaborateTextChange?.(elaborateText + sanitized);
|
|
150
|
-
}
|
|
151
|
-
}
|
|
152
130
|
return;
|
|
153
131
|
}
|
|
154
132
|
// Spacebar: Select/toggle WITHOUT advancing (works for both modes)
|
|
@@ -257,7 +235,7 @@ export const OptionsList = ({ isFocused, onSelect, options, selectedOption, show
|
|
|
257
235
|
marginTop: 0,
|
|
258
236
|
paddingX: 1,
|
|
259
237
|
paddingY: 0,
|
|
260
|
-
}, children:
|
|
238
|
+
}, children: _jsx("input", { value: customValue, onChange: (val) => onCustomChange?.(val), onSubmit: () => { }, placeholder: t("input.placeholder"), focused: true }) })), !isCustomInputFocused && customValue && (_jsx("box", { style: { marginLeft: 2, marginTop: 0 }, children: _jsxs("text", { style: { fg: theme.components.options.hint, attributes: TextAttributes.DIM }, children: [" ", customLines.slice(0, 3).join("\n "), customLines.length > 3 ? "\n \u2026" : ""] }) }))] }) })), showCustomInput && (_jsx("box", { style: { marginTop: 0 }, children: _jsxs("box", { style: { flexDirection: "column" }, children: [(() => {
|
|
261
239
|
const rowBg = isElaborateFocused
|
|
262
240
|
? theme.components.options.focusedBg
|
|
263
241
|
: isElaborateMarked
|
|
@@ -286,5 +264,5 @@ export const OptionsList = ({ isFocused, onSelect, options, selectedOption, show
|
|
|
286
264
|
marginTop: 0,
|
|
287
265
|
paddingX: 1,
|
|
288
266
|
paddingY: 0,
|
|
289
|
-
}, children:
|
|
267
|
+
}, children: _jsx("input", { value: elaborateText, onChange: (val) => onElaborateTextChange?.(val), onSubmit: () => { }, placeholder: t("input.elaboratePlaceholder"), focused: true }) })), !isElaborateFocused && elaborateText && (_jsx("box", { style: { marginLeft: 2, marginTop: 0 }, children: _jsxs("text", { style: { fg: theme.components.options.hint, attributes: TextAttributes.DIM }, children: [" ", elaborateLines.slice(0, 3).join("\n "), elaborateLines.length > 3 ? "\n \u2026" : ""] }) }))] }) }))] }));
|
|
290
268
|
};
|
|
@@ -358,11 +358,24 @@ export const StepperView = ({ onComplete, onProgress, hasMultipleSessions, initi
|
|
|
358
358
|
};
|
|
359
359
|
// Handle elaborate text change
|
|
360
360
|
const handleElaborateTextChange = (text) => {
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
361
|
+
if (!text.trim()) {
|
|
362
|
+
// Auto-remove elaborate mark when text is cleared
|
|
363
|
+
setElaborateMarks((prev) => {
|
|
364
|
+
if (prev.has(currentQuestionIndex)) {
|
|
365
|
+
const newMarks = new Map(prev);
|
|
366
|
+
newMarks.delete(currentQuestionIndex);
|
|
367
|
+
return newMarks;
|
|
368
|
+
}
|
|
369
|
+
return prev;
|
|
370
|
+
});
|
|
371
|
+
}
|
|
372
|
+
else {
|
|
373
|
+
setElaborateMarks((prev) => {
|
|
374
|
+
const newMarks = new Map(prev);
|
|
375
|
+
newMarks.set(currentQuestionIndex, text);
|
|
376
|
+
return newMarks;
|
|
377
|
+
});
|
|
378
|
+
}
|
|
366
379
|
};
|
|
367
380
|
// Keyboard handling for abandoned confirmation dialog
|
|
368
381
|
useKeyboard((key) => {
|