fix: improve numbered list alignment for multi-digit numbers#12478
Open
Vi-Ku wants to merge 2 commits intologseq:masterfrom
Open
fix: improve numbered list alignment for multi-digit numbers#12478Vi-Ku wants to merge 2 commits intologseq:masterfrom
Vi-Ku wants to merge 2 commits intologseq:masterfrom
Conversation
…9515) The bullet container for ordered lists used a fixed width of 1.4em, which is too narrow for numbers with 2+ digits (10, 100, etc.), causing the number to overlap with the block content. Changes: - Set width to auto so it grows with number length - Keep min-width: 1.4em for single-digit numbers - Right-align numbers (justify-end) for consistent dot alignment - Add small right padding for spacing between number and content
Author
|
recheck |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #9515
Problem
Numbered list items with 2+ digit numbers (10, 100, etc.) have their numbers overlapping with the block content. This happens because the
.bullet-container.as-order-listuses a fixed width of1.4em, which is only wide enough for single-digit numbers.Fix
In
src/main/frontend/components/block.css:width: 1.4em→width: autoso the container grows with the number lengthmin-width: 1.4emto maintain consistent sizing for single-digit numbersjustify-center→justify-endto right-align numbers (so the dots align vertically)pr-[2px]for spacing between the number and block contentBefore
After