fix(ui): clamped table column widths#26991
Conversation
|
Size Change: +26 B (0%) Total Size: 34.1 MB
ℹ️ View Unchanged
|
Summary of ChangesHello, 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 addresses a critical UI rendering bug within the CLI's table display mechanism. By clamping column widths to a minimum of zero, it prevents crashes that previously occurred when the terminal window was too narrow, significantly improving the robustness of the UI under constrained conditions. Highlights
Using Gemini Code AssistThe 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
Customization To customize the 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 Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counterproductive. 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. Footnotes
|
There was a problem hiding this comment.
Code Review
This pull request adds a test case to verify that the TableRenderer handles extremely small terminal widths without crashing. It also updates the borderParts calculation to prevent negative values when repeating characters. The reviewer provided feedback suggesting the use of the Largest Remainder Method for better layout distribution and requested additional comments to explain complex layout logic.
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
Summary
Clamped table column widths
Details
Related Issues
Fixes #25665
How to Validate
Render a table with a very small terminal width. The CLI should not crash.
Pre-Merge Checklist