Skip to content

feat: redesign header to be compact with ASCII icon#18713

Merged
jacob314 merged 12 commits intomainfrom
feat/redesign-header-compact
Mar 2, 2026
Merged

feat: redesign header to be compact with ASCII icon#18713
jacob314 merged 12 commits intomainfrom
feat/redesign-header-compact

Conversation

@keithguerin
Copy link
Contributor

@keithguerin keithguerin commented Feb 10, 2026

Summary

Redesigns the Gemini CLI header into a compact layout with an ASCII icon and primary/secondary identity text.

image

Details

  • Compact Header: Replaces large ASCII logo with a 4-line icon and side-by-side text block.
  • Identity Display: Shows version, authentication email, and user tier (e.g., Gemini Code Assist for individuals).
  • Component Updates:
    • AppHeader.tsx: Implements the new compact structure.
    • Tips.tsx: Simplified tips content and formatting.
    • HorizontalLine.tsx: Added position prop ("top", "center", "bottom") supporting (overline) and _ (underline) styles.
  • Cleanup: Commented out HorizontalLine and removed sandbox warning for now as requested.

Related Issues

Fixes #18715

How to Validate

  1. Run the CLI: npm start
  2. Verify the new compact header layout:
    • Icon on the left.
    • 4 lines of text on the right (Version, Email, Tier).
  3. Verify simplified tips appear below.
  4. Run npm run build to confirm compilation.

Pre-Merge Checklist

  • Updated relevant documentation and README (if needed)
  • Added/updated tests (if needed)
  • Noted breaking changes (if any)
  • Validated on required platforms/methods:
    • MacOS
      • npm run
      • npx
      • Docker
      • Podman
      • Seatbelt
    • Windows
      • npm run
      • npx
      • Docker
    • Linux
      • npm run
      • npx
      • Docker

@keithguerin keithguerin requested a review from a team as a code owner February 10, 2026 07:11
@gemini-cli
Copy link
Contributor

gemini-cli bot commented Feb 10, 2026

Hi @keithguerin, thank you so much for your contribution to Gemini CLI! We really appreciate the time and effort you've put into this.

We're making some updates to our contribution process to improve how we track and review changes. Please take a moment to review our recent discussion post: Improving Our Contribution Process & Introducing New Guidelines.

Key Update: Starting January 26, 2026, the Gemini CLI project will require all pull requests to be associated with an existing issue. Any pull requests not linked to an issue by that date will be automatically closed.

Thank you for your understanding and for being a part of our community!

@gemini-cli
Copy link
Contributor

gemini-cli bot commented Feb 10, 2026

Hi there! Thank you for your contribution to Gemini CLI.

To improve our contribution process and better track changes, we now require all pull requests to be associated with an existing issue, as announced in our recent discussion and as detailed in our CONTRIBUTING.md.

This pull request is being closed because it is not currently linked to an issue. Once you have updated the description of this PR to link an issue (e.g., by adding Fixes #123 or Related to #123), it will be automatically reopened.

How to link an issue:
Add a keyword followed by the issue number (e.g., Fixes #123) in the description of your pull request. For more details on supported keywords and how linking works, please refer to the GitHub Documentation on linking pull requests to issues.

Thank you for your understanding and for being a part of our community!

@gemini-cli gemini-cli bot closed this Feb 10, 2026
@gemini-code-assist
Copy link
Contributor

Summary of Changes

Hello @keithguerin, 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 significantly refactors the Gemini CLI's user interface by introducing a more compact and informative header. The changes aim to provide users with essential application and account details at a glance, improving the overall clarity and user experience of the command-line interface. Additionally, the update streamlines the display of initial usage tips and enhances a shared UI component for greater flexibility.

Highlights

  • Compact Header Redesign: The Gemini CLI header has been redesigned into a compact, 4-line layout, replacing the previous large ASCII logo with a smaller ASCII icon and side-by-side text.
  • Enhanced Identity Display: The new header now prominently displays key identity information including the CLI version, user authentication email, and the user's tier (e.g., 'Gemini Code Assist for individuals').
  • Simplified Tips Component: The Tips.tsx component has been updated to provide a more concise and simplified list of getting started tips, removing some conditional content.
  • Flexible Horizontal Line Component: The HorizontalLine.tsx component now includes a position prop, allowing it to render different border styles ('top' for overline, 'bottom' for underline, or 'center' for single line).
  • Cleanup and Refinements: Minor cleanup was performed, including commenting out the HorizontalLine usage in AppHeader.tsx and removing a sandbox warning as requested.
Changelog
  • packages/cli/src/ui/components/AppHeader.tsx
    • Replaced the previous Header and UserIdentity components with a new compact header structure.
    • Integrated a new ASCII icon and dynamic text display for version, update status, user email, and tier name.
    • Added imports for Text, useMemo, UserAccountManager, AuthType, theme, ThemedGradient, and CliSpinner.
    • Removed the nightly prop from useUIState destructuring.
    • Implemented logic to fetch and display user authentication details and tier information.
    • Commented out the usage of HorizontalLine within the component.
  • packages/cli/src/ui/components/Tips.tsx
    • Simplified the list of displayed tips, removing the conditional tip related to GEMINI.md files.
    • Adjusted the formatting and content of the remaining tips for conciseness.
    • Removed the config prop from the component's interface and usage.
  • packages/cli/src/ui/components/shared/HorizontalLine.tsx
    • Added width and position props to control the line's dimensions and style.
    • Introduced LinePosition type for specifying line placement ('top', 'center', 'bottom').
    • Defined overlineStyle and underlineStyle objects to support different border characters.
    • Modified the borderStyle logic to dynamically apply overlineStyle, underlineStyle, or 'single' based on the position prop.
Activity
  • No specific activity (comments, reviews, progress) has been recorded for this pull request yet.
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.

Copy link
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 introduces a well-designed compact header for the CLI, improving the user interface by making it less cluttered. The changes are mostly well-implemented, with a nice enhancement to the HorizontalLine component and simplification of the Tips component. However, I've identified a critical compilation error related to prop handling in the Tips component that needs to be addressed in both Tips.tsx and AppHeader.tsx. Additionally, there's a high-severity performance concern in AppHeader.tsx due to synchronous file I/O during the render cycle, which could negatively impact UI responsiveness.

)}

{!(settings.merged.ui.hideTips || config.getScreenReader()) &&
showTips && <Tips config={config} />}
Copy link
Contributor

Choose a reason for hiding this comment

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

critical

The config prop has been removed from the Tips component, but it is still being passed here. This should be removed to fix the compilation error.

Suggested change
showTips && <Tips config={config} />}
showTips && <Tips />}

Comment on lines +40 to +49
const { email, tierName } = useMemo(() => {
if (!authType) {
return { email: undefined, tierName: undefined };
}
const userAccountManager = new UserAccountManager();
return {
email: userAccountManager.getCachedGoogleAccount(),
tierName: config.getUserTierName(),
};
}, [config, authType]);
Copy link
Contributor

Choose a reason for hiding this comment

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

high

The useMemo hook executes userAccountManager.getCachedGoogleAccount(), which performs synchronous file I/O. This blocks the render thread and can lead to UI unresponsiveness. This data should be fetched asynchronously, for example, within a useEffect hook that updates component state.

@gemini-cli gemini-cli bot reopened this Feb 10, 2026
@gemini-cli
Copy link
Contributor

gemini-cli bot commented Feb 10, 2026

Thank you for linking an issue! This pull request has been automatically reopened.

@github-actions
Copy link

github-actions bot commented Feb 10, 2026

Size Change: -9.32 kB (-0.04%)

Total Size: 25.8 MB

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

compressed-size-action

@gemini-cli gemini-cli bot added the area/core Issues related to User Interface, OS Support, Core Functionality label Feb 10, 2026
@keithguerin keithguerin changed the title feat(ui): redesign header to be compact with ASCII icon Redesign header to be compact with ASCII icon Feb 10, 2026
@gemini-cli gemini-cli bot added priority/p1 Important and should be addressed in the near term. 🔒 maintainer only ⛔ Do not contribute. Internal roadmap item. labels Feb 10, 2026
@jacob314 jacob314 self-requested a review February 10, 2026 17:30
@jacob314
Copy link
Contributor

Ask gemini to truncate the lines (either with overflow:hidden or ellipses your UX call). Right now this looks bad when the terminal is very narrow

image

const { email, tierName } = useMemo(() => {
if (!authType) {
return { email: undefined, tierName: undefined };
useEffect(() => {
Copy link
Contributor

Choose a reason for hiding this comment

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

revert this change. this change. it has no benefit as moving inside a useEffect is just as blocking and the real fix would be harder.

@jacob314
Copy link
Contributor

Pull Request Review - PR 18713

Thanks for the contribution! Here are some points to address:

1. Conventional Commits

The PR title "Redesign header to be compact with ASCII icon" is missing a prefix. Please update it to follow Conventional Commits (e.g., feat: redesign header to be compact with ASCII icon).

2. Regression: "Authenticated with undefined"

In AppHeader.tsx, if authType is not defined, the header now renders Authenticated with undefined /auth. The previous implementation in UserIdentity.tsx would return null if authType was missing. We should maintain that behavior to avoid displaying broken identity information.

3. Regression: Onboarding Tips

The dynamic tip about GEMINI.md files was removed from Tips.tsx. This tip is an important way for users to discover project-specific customization. Please restore the check for config.getGeminiMdFileCount().

4. Test Quality (Tips.test.tsx)

  • Standards: Please use toMatchSnapshot() instead of raw toContain assertions for verifying the rendered output. This is our project standard for Ink components.
  • Coverage: The parameterized tests (it.each) that covered different file counts were removed. These should be restored along with the dynamic tip logic.

5. Narrow Terminal Support

The layout currently breaks in narrow terminals. Using the wrap="truncate-end" prop on the Text components in the identity section of AppHeader.tsx would handle this more gracefully.

6. Synchronous File I/O

While moving getCachedGoogleAccount() to useEffect prevents it from blocking the initial React frame, it still uses readFileSync under the hood. This blocks the single-threaded Node.js event loop. We should avoid synchronous I/O in the UI layer.

7. Unused Code Cleanup

The changes to HorizontalLine.tsx are currently commented out in AppHeader.tsx. If they aren't ready for use, they should be removed or moved to a separate PR to keep this one focused.

@keithguerin
Copy link
Contributor Author

I have addressed feedback item #6 by deleting the custom authentication logic I had previously added to AppHeader.tsx. Instead, I am now correctly reusing the <UserIdentity /> component (which already handles the authentication display logic).

I'll follow up with addresses for the remaining feedback items momentarily.

@keithguerin keithguerin force-pushed the feat/redesign-header-compact branch 4 times, most recently from 1fb5d59 to 3e03fab Compare February 27, 2026 23:46
@keithguerin keithguerin changed the title Redesign header to be compact with ASCII icon feat: redesign header to be compact with ASCII icon Feb 28, 2026
@jacob314
Copy link
Contributor

jacob314 commented Mar 2, 2026

I've pushed cleanup to remove slop in render.tsx and remove the png. I'll fast follow with a change to fix the regression in UserIdentity.tsx

Copy link
Contributor

@jacob314 jacob314 left a comment

Choose a reason for hiding this comment

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

lgtm

@jacob314 jacob314 enabled auto-merge March 2, 2026 20:44
@jacob314 jacob314 added this pull request to the merge queue Mar 2, 2026
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Mar 2, 2026
@jacob314 jacob314 added this pull request to the merge queue Mar 2, 2026
Merged via the queue into main with commit 31ca57e Mar 2, 2026
27 checks passed
@jacob314 jacob314 deleted the feat/redesign-header-compact branch March 2, 2026 21:27
BryanBradfo pushed a commit to BryanBradfo/gemini-cli that referenced this pull request Mar 5, 2026
)

Co-authored-by: Jacob Richman <jacob314@gmail.com>
struckoff pushed a commit to struckoff/gemini-cli that referenced this pull request Mar 6, 2026
)

Co-authored-by: Jacob Richman <jacob314@gmail.com>
liamhelmer pushed a commit to badal-io/gemini-cli that referenced this pull request Mar 12, 2026
)

Co-authored-by: Jacob Richman <jacob314@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/core Issues related to User Interface, OS Support, Core Functionality 🔒 maintainer only ⛔ Do not contribute. Internal roadmap item. priority/p1 Important and should be addressed in the near term.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Redesign CLI header to be compact and informative

2 participants