Repository navigation
fix(webkit): [ENG-48120] keep a chrome block's padding when it opens the prose - #981
Merged
isaque-bock-azion merged 7 commits intoSep 22, 2026
Merged
Conversation
…the prose DocProse opens the page flush by zeroing the first block's margin and padding at two levels, so the reset reaches through a renderer wrapper (Astro's astro-slot, a prose div). That reset carried no data-doc-chrome guard, unlike every other prose rule, so when the first thing in the document is a DocCallout the pt-0! landed on the component itself and erased the py-1.5 it inherits from Message. The margin reset is right — a block carries its outer space as margin-top, the block rung — but the padding is the component's own, not a rung of the ladder. The padding half of the reset now stops at data-doc-chrome at both levels; the margin half is unchanged. A unit test pins the contract in the class list, since the ladder itself belongs to the visual gate.
guilherme-santana-azion
approved these changes
Sep 18, 2026
gabriel-lisboa-azion
added a commit
that referenced
this pull request
Sep 21, 2026
demo/vue-sample had drifted 540 ahead / 31 behind main while most of its webkit work was reviewed and landed upstream (#941 command-menu, #942 GlobalHeader placements, #943 NavigationMenu, #952 Menu, #960 sidebar collapse, #973 floating-panel placement, #975 paginator, #977 templates exports, #921 amount ladder), after which main swept comments (#951) and reworked the CLI onto a derived bundle (#968/#970). Main is the source for everything the two share. Of the 28 conflicted source files, 17 differed from main only in comments — their code was byte-identical — and 6 more were genuinely newer on main, so all 23 take main verbatim, including the use-placement TypeScript rewrite that replaces the old index.js. Three carve-outs keep demo work main does not have yet: - sidebar: main's CSS-driven collapse is the base; the `side` axis is re-applied on top of it as data-[side=end] variants rather than the JS edge map it used to be, and the drag sign moves into the rail composable. The one test that asserted the removed inline transform now asserts the panel's published edge, since the direction is CSS the unstyled test env cannot see. - theme: texts.data.js keeps demo's 13 extra text-wrap and 10 extra tracking declarations (PR #982, in flight). Both sides carry the same 34 entries, so an entry count would not have caught the loss. - doc-prose keeps its chrome-padding fix (PR #981, in flight). catalog.json, authoring-baseline.json, the theme dist and the lockfile are regenerated rather than hand-resolved; the 13 conflicted visual baselines take main's and are regenerated from CI next. Verified: every file main touched is byte-identical to main except the 22 accounted for above; 2364 browser tests, 179 toolkit tests, lint, vue-tsc, 99.98% type coverage, both ratchets, the Storybook build and the webkit-sample build all pass.
guilherme-santana-azion
previously approved these changes
Sep 22, 2026
lucas-langeloh-azion
previously approved these changes
Sep 22, 2026
…opup The positioner is a block container and the slot leaves empty text nodes around the popup, so an anonymous line box opened after it and its strut added ~16px to the positioner's height. The overhang paints nothing, but it is still a box that takes the pointer: on a panel flipped above its trigger it reached back over the very trigger the flip had just cleared. `display: flex` drops whitespace-only text nodes, so the positioner box is exactly the popup. It goes inline next to `min-width` instead of into the class preset because browser-mode tests load no stylesheet, and this is geometry the placement assertions depend on. This is what made `flips above the trigger when there is no room below` red: it asserts on the positioner's box, so it failed whenever the viewport left the overhang unclamped — first try on every branch, all three tries on some.
isaque-bock-azion
dismissed stale reviews from lucas-langeloh-azion and guilherme-santana-azion
via
September 22, 2026 16:50
360bcdd
lucas-langeloh-azion
approved these changes
Sep 22, 2026
guilherme-santana-azion
approved these changes
Sep 22, 2026
isaque-bock-azion
deleted the
fix/doc-prose-first-child-chrome-padding
branch
September 22, 2026 17:45
Merged
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.
Summary
DocProse's first-block reset ([&>*:first-child]and[&>*:first-child>*:first-child],mt-0!+pt-0!) had nodata-doc-chromeguard, so aDocCalloutsitting first in the document lost its ownpy-1.5(inherited fromMessage) and rendered with no top padding. Seen on docs pages that open with the API v4 rollout callout.data-doc-chromeat both levels. The margin half is unchanged: a block carries its outer space asmargin-top(the block rung), so zeroing it is what opens the page flush.How to test
pnpm --filter @aziontech/webkit test -- src/components/documentation/doc-prose— 16 tests pass, including the two new ones under "the first-block reset stops at chrome".DocProsewith aDocCalloutas the first child inside a wrapperdiv(mirrors Astro'sastro-slot): the callout keeps its6pxtop padding. Before this change the computedpadding-topwas0px; a second callout further down the page still read6px./en/documentation/platform/applications/) and compare the first callout'spadding-topagainst the next one.Notes
Chrome boundarystory is untouched, so no visual baseline changes. A variant that opens with a chrome block is worth adding when the linux baselines are next regenerated.