Thinner close button stroke and deduplicate shared resources#47
Thinner close button stroke and deduplicate shared resources#47
Conversation
Co-authored-by: cyanzhong <6745066+cyanzhong@users.noreply.github.com>
|
@copilot Why you are not reusing resources here? Can you do a full scan of the codebase to find out wasted duplicates? |
There was a problem hiding this comment.
Pull request overview
This PR adjusts the visual weight of the “close” (X) icon used on suggestion cards to better match the intended UI styling across both the tooltip card and the sidebar problems panel.
Changes:
- Reduced the close button SVG
stroke-widthfrom1.5to1.2in the tooltip suggestion card. - Reduced the close button SVG
stroke-widthfrom1.5to1.2in the sidebar pane header close button.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
src/tooltip.ts |
Updates the tooltip card close-button SVG stroke width to 1.2. |
src/panel.ts |
Updates the sidebar pane close-button SVG stroke width to 1.2. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
You can also share your feedback on Copilot code review. Take the survey.
Co-authored-by: cyanzhong <6745066+cyanzhong@users.noreply.github.com>
Extracted the duplicated close button SVG and system font-family stack into shared constants ( |
There was a problem hiding this comment.
Pull request overview
This PR refines UI consistency by lightening the close (“X”) icon stroke and centralizing repeated UI resources into src/const.ts, reducing duplication across the tooltip and sidebar panel components.
Changes:
- Reduced the close button SVG
stroke-widthfrom1.5to1.2. - Added shared
closeSvgandsystemFontconstants insrc/const.ts. - Updated tooltip and panel implementations to reference these shared constants instead of inline values.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
src/const.ts |
Introduces shared closeSvg and systemFont constants (and keeps repoUrl). |
src/tooltip.ts |
Uses systemFont in tooltip CSS and closeSvg for the close button markup. |
src/panel.ts |
Uses systemFont in pane CSS and closeSvg for the pane close button markup. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
You can also share your feedback on Copilot code review. Take the survey.
Reduce close button SVG
stroke-widthfrom1.5to1.2for a lighter visual weight, and extract duplicated resources into shared constants insrc/const.ts.src/const.ts— new sharedcloseSvgandsystemFontconstantssrc/tooltip.ts— use shared constants instead of inline duplicatessrc/panel.ts— use shared constants instead of inline duplicates💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.