-
Notifications
You must be signed in to change notification settings - Fork 30
[BUG] [v1.1.0] Git Settings "Browse" Button Icon Not Vertically Centered #23428
Description
Project
ide
Description
In the Settings panel, under the Git section, there's a "Browse" button used to pick a folder path for cloning repositories. The folder icon inside that button is not vertically centered — it sits slightly off from the text label, making the button look visually inconsistent.
The root cause is the same as the previously documented icon misalignment in the JSON view toggle button. The Browse button is rendered using the legacy Button component (GitSettingsPanel.tsx:159-166), which accepts icon as a JSX.Element. That element gets passed down to CortexButton as a child node, not through CortexButton's own icon: string prop. Inside CortexButton, all children — icon JSX and text alike — land in a single (CortexButton.tsx:250-251) that has no flex alignment, so the icon floats relative to the text baseline rather than centering against it.
Error Message
Debug Logs
System Information
Bounty Challenge: v1.1.0
OS: Ubuntu 25.10 (Questing Quokka), 64-bit (x86_64)
CPU: Intel Core i7-13650HX
RAM: 15GBScreenshots
Steps to Reproduce
- Launch Cortex IDE.
- Click the Settings gear icon in the top navbar to open the Settings dialog.
- In the left sidebar of the Settings panel, scroll down to Git.
- Locate the Default Clone Directory row.
- Observe the Browse button to the right of the path input field.
Expected Behavior
The folder icon and the "Browse" label should be vertically centered with each other, sitting flush on the same visual midline as expected for a standard inline button.
Actual Behavior
The folder icon is not vertically aligned with the "Browse" text label. It appears shifted — either riding higher or lower than the text — producing a noticeably off-center layout that is inconsistent with other buttons in the interface.
Additional Context
The span never sets display: inline-flex; align-items: center, so the icon and label are not co-aligned on a shared axis.