mirror of
https://github.com/google-gemini/gemini-cli.git
synced 2026-04-26 13:04:49 -07:00
feat: multi-line text answers in ask-user tool (#18741)
This commit is contained in:
@@ -207,7 +207,11 @@ export class AskUserInvocation extends BaseToolInvocation<
|
||||
.map(([index, answer]) => {
|
||||
const question = this.params.questions[parseInt(index, 10)];
|
||||
const category = question?.header ?? `Q${index}`;
|
||||
return ` ${category} → ${answer}`;
|
||||
const prefix = ` ${category} → `;
|
||||
const indent = ' '.repeat(prefix.length);
|
||||
|
||||
const lines = answer.split('\n');
|
||||
return prefix + lines.join('\n' + indent);
|
||||
})
|
||||
.join('\n')}`
|
||||
: 'User submitted without answering questions.';
|
||||
|
||||
Reference in New Issue
Block a user