address bot comment

This commit is contained in:
A.K.M. Adib
2026-03-04 11:16:03 -05:00
parent 128dc99927
commit 36b06f7333
3 changed files with 23 additions and 6 deletions

View File

@@ -791,7 +791,11 @@ const ChoiceQuestionView: React.FC<ChoiceQuestionViewProps> = ({
: undefined;
const maxQuestionHeight =
question.unconstrainedHeight && listHeight
? Math.max(1, listHeight - DIALOG_PADDING - selectionItems.length * 2)
? // When unconstrained, give the question a majority of the vertical space (e.g., 70%).
// The options list will take the remaining space and scroll if necessary.
// This is more robust than calculating based on `selectionItems.length`,
// which can incorrectly shrink the question if there are many options.
Math.max(1, Math.floor(listHeight * 0.7))
: 15;
const questionHeight =
listHeight && !isAlternateBuffer

View File

@@ -282,7 +282,8 @@ describe('ToolConfirmationQueue', () => {
// hideToolIdentity is true for ask_user -> subtracts 4 instead of 6
// availableContentHeight = 19 - 4 = 15
// ToolConfirmationMessage handlesOwnUI=true -> returns full 15
// AskUserDialog uses 15 lines to render its multi-line question and options.
// AskUserDialog allocates maxQuestionHeight = floor(15 * 0.7) = 10.
// 10 lines is enough for the 6-line question + padding.
await waitFor(() => {
expect(lastFrame()).toContain('Line 6');
expect(lastFrame()).not.toContain('lines hidden');

View File

@@ -11,7 +11,10 @@ Implementation Steps
2. Add session storage in src/storage/SessionStore.ts
3. Update src/commands/index.ts to check auth status
4. Add tests in src/auth/__tests__/
... last 5 lines hidden (Ctrl+O to show) ...
Files to Modify
... last 2 lines hidden (Ctrl+O to show) ...
1. Yes, automatically accept edits
Approves plan and allows tools to run automatically
@@ -34,7 +37,10 @@ Implementation Steps
2. Add session storage in src/storage/SessionStore.ts
3. Update src/commands/index.ts to check auth status
4. Add tests in src/auth/__tests__/
... last 5 lines hidden (Ctrl+O to show) ...
Files to Modify
... last 2 lines hidden (Ctrl+O to show) ...
● 1. Yes, automatically accept edits
Approves plan and allows tools to run automatically
@@ -62,7 +68,10 @@ Implementation Steps
2. Add session storage in src/storage/SessionStore.ts
3. Update src/commands/index.ts to check auth status
4. Add OAuth2 provider support in src/auth/providers/OAuth2Provider.ts
... last 26 lines hidden (Ctrl+O to show) ...
5. Add SAML provider support in src/auth/providers/SAMLProvider.ts
6. Add LDAP provider support in src/auth/providers/LDAPProvider.ts
7. Create token refresh mechanism in src/auth/TokenManager.ts
... last 23 lines hidden (Ctrl+O to show) ...
● 1. Yes, automatically accept edits
Approves plan and allows tools to run automatically
@@ -85,7 +94,10 @@ Implementation Steps
2. Add session storage in src/storage/SessionStore.ts
3. Update src/commands/index.ts to check auth status
4. Add tests in src/auth/__tests__/
... last 5 lines hidden (Ctrl+O to show) ...
Files to Modify
... last 2 lines hidden (Ctrl+O to show) ...
● 1. Yes, automatically accept edits
Approves plan and allows tools to run automatically