Skip to content

fix(patch): cherry-pick e5615f4 to release/v0.33.0-preview.12-pr-21037 to patch version v0.33.0-preview.12 and create version 0.33.0-preview.13#21922

Merged
Adib234 merged 1 commit intorelease/v0.33.0-preview.12-pr-21037from
hotfix/v0.33.0-preview.12/0.33.0-preview.13/preview/cherry-pick-e5615f4/pr-21037
Mar 10, 2026
Merged

fix(patch): cherry-pick e5615f4 to release/v0.33.0-preview.12-pr-21037 to patch version v0.33.0-preview.12 and create version 0.33.0-preview.13#21922
Adib234 merged 1 commit intorelease/v0.33.0-preview.12-pr-21037from
hotfix/v0.33.0-preview.12/0.33.0-preview.13/preview/cherry-pick-e5615f4/pr-21037

Conversation

@gemini-cli-robot
Copy link
Copy Markdown
Collaborator

This PR automatically cherry-picks commit e5615f4 to patch version v0.33.0-preview.12 in the preview release to create version 0.33.0-preview.13.

…nconstrained heights (#21037)

Co-authored-by: jacob314 <jacob314@gmail.com>
@gemini-code-assist
Copy link
Copy Markdown
Contributor

Summary of Changes

Hello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request cherry-picks a commit to patch a preview release, primarily focusing on enhancing the flexibility of UI layout within the CLI. The key change involves introducing an unconstrainedHeight option for questions in dialogs, allowing them to adapt their vertical space more dynamically. This improves the rendering of multi-line questions and overall user experience by providing better control over component sizing.

Highlights

  • New unconstrainedHeight property: Introduced a new unconstrainedHeight property to the Question interface, allowing questions to consume more vertical space in the UI.
  • Dynamic Question Height Adjustment: Updated the AskUserDialog component to incorporate the unconstrainedHeight property, dynamically adjusting question height limits based on this setting.
  • Simplified Terminal Height Calculation: Simplified the calculation of available terminal height in AppContainer.tsx by removing staticExtraHeight and adjusting the constant offset.
  • Explicit Height Constraint Configuration: Explicitly set unconstrainedHeight to false for a question in ExitPlanModeDialog to maintain its constrained height behavior.
  • Updated Test Comments: Updated test comments in ToolConfirmationQueue.test.tsx to reflect the revised logic for question height calculation.
Changelog
  • packages/cli/src/ui/AppContainer.tsx
    • Simplified the calculation of availableTerminalHeight by removing staticExtraHeight and reducing a constant offset.
  • packages/cli/src/ui/components/AskUserDialog.tsx
    • Renamed questionHeight to questionHeightLimit.
    • Modified the logic for questionHeightLimit to conditionally allow unconstrained height based on the new question.unconstrainedHeight property.
    • Adjusted maxItemsToShow calculation to use questionHeightLimit.
    • Updated MaxSizedBox to use questionHeightLimit.
  • packages/cli/src/ui/components/ExitPlanModeDialog.tsx
    • Added unconstrainedHeight: false to the configuration of a question.
  • packages/cli/src/ui/components/ToolConfirmationQueue.test.tsx
    • Updated comments to reflect the new calculation for questionHeight and listHeight in the AskUserDialog context.
  • packages/core/src/confirmation-bus/types.ts
    • Added an optional boolean property unconstrainedHeight to the Question interface, with a JSDoc description.
Activity
  • No human activity has been recorded for this pull request.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

@Adib234 Adib234 enabled auto-merge (squash) March 10, 2026 19:52
@github-actions
Copy link
Copy Markdown

Size Change: +121 B (0%)

Total Size: 25.9 MB

ℹ️ View Unchanged
Filename Size Change
./bundle/gemini.js 25.4 MB +121 B (0%)
./bundle/node_modules/@google/gemini-cli-devtools/dist/client/main.js 221 kB 0 B
./bundle/node_modules/@google/gemini-cli-devtools/dist/src/_client-assets.js 227 kB 0 B
./bundle/node_modules/@google/gemini-cli-devtools/dist/src/index.js 11.5 kB 0 B
./bundle/node_modules/@google/gemini-cli-devtools/dist/src/types.js 132 B 0 B
./bundle/sandbox-macos-permissive-open.sb 890 B 0 B
./bundle/sandbox-macos-permissive-proxied.sb 1.31 kB 0 B
./bundle/sandbox-macos-restrictive-open.sb 3.36 kB 0 B
./bundle/sandbox-macos-restrictive-proxied.sb 3.56 kB 0 B
./bundle/sandbox-macos-strict-open.sb 4.82 kB 0 B
./bundle/sandbox-macos-strict-proxied.sb 5.02 kB 0 B

compressed-size-action

Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request includes important fixes and improvements related to UI layout and dynamic content display. The correction in packages/cli/src/ui/AppContainer.tsx addresses an issue where the available terminal height was miscalculated, leading to unnecessary content truncation. Additionally, the introduction of unconstrainedHeight in the Question interface and its implementation in packages/cli/src/ui/components/AskUserDialog.tsx provides greater flexibility for rendering questions that require more vertical space, enhancing the user experience for interactive dialogs.

staticExtraHeight -
2 -
backgroundShellHeight,
terminalHeight - controlsHeight - backgroundShellHeight - 1,
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

high

The previous calculation for availableTerminalHeight was incorrectly subtracting staticExtraHeight (which is 3) and an additional 2 lines, resulting in a total of 5 lines being subtracted from the available height for static elements. This led to an overly constrained UI, potentially truncating content unnecessarily. The revised calculation, which now subtracts only 1 line for static elements, correctly frees up 4 additional lines of vertical space, resolving a significant layout bug and improving content visibility.

References
  1. The fix improves UI layout consistency by preventing content truncation, aligning with the principle of ensuring consistent and readable layouts.
  2. The calculation involves specific numerical values (1, 2, 3, 5) used for layout adjustments. While this comment describes a fix, it's a good practice to replace such 'magic numbers' with named constants for improved readability and maintainability, as per repository guidelines.

@Adib234 Adib234 merged commit ca0db7e into release/v0.33.0-preview.12-pr-21037 Mar 10, 2026
28 checks passed
@Adib234 Adib234 deleted the hotfix/v0.33.0-preview.12/0.33.0-preview.13/preview/cherry-pick-e5615f4/pr-21037 branch March 10, 2026 20:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants