fix(theme): Fixed step counter text alignment#2981
fix(theme): Fixed step counter text alignment#2981SoonIter merged 1 commit intoweb-infra-dev:mainfrom
Conversation
The text in the stepper counter was not quite centered because of how text renders. I've set the line height to match the height of the `:before` such that the alignment should now be more centered vertically.
There was a problem hiding this comment.
Pull request overview
This PR fixes a minor vertical alignment issue in the stepper counter component by adding a line-height property to match the height of the counter's :before pseudo-element.
- Sets
line-height: 30pxto improve vertical centering of text within the step counter
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
✅ Deploy Preview for rspress-v2 ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
|
By the way, are you developing any products with Rspress V2? 🫰🏻 Welcome to showcase your Rspress website here 🍻 |
I'm currently trying to migrate my app's main website from nextra to rspress (https://monetr.app) but I'm not done quite yet. I've been using rsbuild/rspack for a long time now and its been such a better experience across the board so I want to keep things consistent. |
Summary
The text in the stepper counter was not quite centered because of how text renders. I've set the line height to match the height of the
:beforesuch that the alignment should now be more centered vertically.Sorry for more small PRs for these tiny things I'm noticing as I tinker.
This essentially amounts to like a 1 pixel difference.
Before
After
Diff
Related Issue
N/A
Checklist