Repository navigation
fix: keep code and document widget boxes stable during upgrade - #5015
Merged
Merged
Conversation
Remove the duplicate code scrollbar inset: the native pre already owns its clearance float before and after upgrade. Give the text-document caption and its pre-upgrade pseudo-element the same named small font, instead of inheriting different code and page line heights. Closes #4948
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.
The default widget-quality check reproduces both first-presentation regressions on main.
lf-codeadds scrollbar clearance in its pre-upgrade padding even though the nativepre::afteralready supplies it; removing that duplicate inset keeps the authored and numbered boxes equal.lf-text-documentgives its caption and pre-upgrade caption pseudo-element the same--font-small, so changing the host from source typography to page typography no longer changes the caption's leading.This preserves the scrollbar room intended by #3752 and the authored Markdown preview introduced in #4861. On screen, code loses 8 px of excess room before upgrade; completed code stays the same. Document captions use the interface's small-font leading before and after upgrade; the preview and source viewports keep their existing bounds.
The existing default-package quality test failed before and passes after in column and workspace layouts, without changing its findings allowance. Focused wrapping, Markdown/source switching, viewport/scroll retention, and interface-font checks pass. All 737 runtime tests and pre-commit pass. A feature-gallery startup comparison reaches presentation with the same 75 code requests and 71 JavaScript requests; JavaScript bytes are unchanged and CSS is 142 bytes smaller.
Visual comparison
The Markdown preview caption changes from inherited 18.4 px leading to the shared 16.675 px small-font leading. Source-capture captions take the same rule; completed code has no pixel difference in the native-code state.
Before:
After:
Closes #4948 — automated triage