Repository navigation
fix(core): a block-edge reveal slides its parts on the glide's frames - #10296
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
AI review status for this pull request.
|
PR Analysis Report🔎 Preview ·
|
| Component | Size | LoC | Visual · A11y · RTL |
|---|---|---|---|
| TableBody | 3.5 kB (0) · 3.3 kB CSS (0) | — | ✓ · ✓ · ✗ |
| TableFooter | 3.5 kB (0) · 3.3 kB CSS (0) | — | ✓ · ✓ · ✗ |
| TableHeader | 3.5 kB (0) · 3.3 kB CSS (0) | — | ✓ · ✓ · ✗ |
14 more components
| Component | Size | LoC | Visual · A11y · RTL |
|---|---|---|---|
| TableRow | 6.7 kB (−1 B) · 3.9 kB CSS (0) | — | ✓ · ✓ · ✗ |
| PowerSearch | 272.5 kB (+1.4 kB) · 23.1 kB CSS (0) | — | — · — · — |
| TreeList | 42.5 kB (+1.4 kB) · 5.4 kB CSS (0) | — | — · — · — |
| Collapsible | 26.1 kB (+1.3 kB) · 4.5 kB CSS (0) | — | ✓ · ✓ · ✓ |
| AppShell | 81.5 kB (+3 B) · 12.8 kB CSS (0) | — | — · — · — |
| CollapsibleGroup | 6.6 kB (0) · 3.3 kB CSS (0) | — | ✓ · ✓ · ✓ |
| Markdown | 162.2 kB (0) · 19.5 kB CSS (0) | — | — · — · — |
| SideNav | 81.2 kB (0) · 10.7 kB CSS (0) | — | — · — · — |
| Table | 99.9 kB (0) · 17.3 kB CSS (0) | — | ✓ · ✓ · — |
| TableCell | 91.7 kB (0) · 17.0 kB CSS (0) | — | ✓ · ✓ · ✓ |
| TableHeaderCell | 91.3 kB (0) · 16.8 kB CSS (0) | — | ✓ · ✓ · ✓ |
| TableSelectionToolbar | 61.3 kB (0) · 12.4 kB CSS (0) | — | ✓ · ✓ · ✓ |
| lab/Comments | 306.5 kB (0) · 2.5 kB CSS (0) | — | — · — · — |
| lab/CommentThread | 301.4 kB (0) · 2.4 kB CSS (0) | — | — · — · — |
Package size: @astryxdesign/core 6.79 MB packed (+6.3 kB); no new dependencies.
API changes: none in this pull request
Committed API report behind this build: cli 19 rows, core 24 rows; run pnpm api:report.
Touched components checked; add ci:run-visual or ci:run-rtl to run the full suites.
Generated by PR Enrichment workflow | View full report
There was a problem hiding this comment.
Approval waits on an engineering owner's spec decision and three fixes.
Spec decision. This pull request changes current spec text: spec:AST-105 FR4 moves the glide to --duration-medium (with a new DEC-3), FR9 says a block-edge reveal slides its children under a still clip, architecture:react-component-runtime INV12 lets the walk descend into the changed element's children and adds two verification failures, and component:Collapsible gains AV5. An engineering owner records the decision by commenting /approve-spec 362167ec0ae8b34859c44840fbb498b4ccfd3520 on this pull request; the author may do so as an engineering owner.
Blocking:
docs/specs/components/Table/Table.spec.mdsays expanded panel rows keep the moving clip, but in the "Gliding rows" story the default (transparent) panel's cell slides and onlypanelVariant="muted"keeps the clip, so the bullet should name the filled panel.- The Table test in
animatedLayoutRevealPaint.interaction.browser.spec.tsreads[data-expansion-panel] > *after the panel has closed and unmounted, socells.every(...)passes on an empty list; read the cells while the panel is open and assert a slide for the default panel and none for the muted one. - The description says desktop looks as before, but on every pointer the revealed content now slides in from the moving edge instead of being uncovered in place; please say so and show a mouse before and after.
This branch also carries #10261's duration change; adding Stack: #10261 → #10296 to both descriptions, or rebasing once #10261 lands, lets each be reviewed on its own change.
[Automated review]
There was a problem hiding this comment.
Approval waits on an engineering owner's spec decision and two fixes.
Spec decision. This pull request changes current spec text: spec:AST-105 FR4 moves the glide to --duration-medium (with a new DEC-3), FR9 says a block-edge reveal slides its children under a still clip, architecture:react-component-runtime INV12 lets the walk descend into the changed element's children and adds two verification failures, component:Collapsible gains AV5, and component:Table records the muted panel's gap. An engineering owner records the decision by commenting /approve-spec a852fefc8bab996b27b8db0df5435ae4c775258a on this pull request; the author may do so as an engineering owner.
Blocking:
- Miss: when a Table row's detail panel opens, the divider under it is missing for the whole glide, because
markGlidingRowsinpackages/core/src/Table/glidingDivider.tsmeasures the panel cell after its slide has moved it up (offset-109pxin the "Gliding rows" story), so read that offset before the entrance starts and cover the panel's divider mid-open inTableRowGlide.a11y.browser.spec.ts. - The description says desktop looks as before, but on every pointer the revealed content now slides in from the moving edge instead of being uncovered in place, so please say so and give mouse before-and-after results.
This branch also carries #10261's duration change; adding Stack: #10261 → #10296 to both descriptions, or rebasing once #10261 lands, lets each be reviewed on its own change.
[Automated review]
A block edge's reveal or conceal clipped the element with a moving clip-path. WebKit paints that clip on the main thread while the content beside it glides on the compositor, so on iOS the two parted for a few frames. The element's child elements that the band can show now slide on the glide's frames under a still clip on its box, and the two share one clock. An element with text of its own keeps the clip. Collapsible's region wraps its children in one element so they slide. The glide's timing and curve are unchanged.
The default panel row slides its cell, and one that paints its own box keeps the moving clip. Table's record scopes its gap to the muted panel.
a852fef to
38a3f87
Compare
The panel's divider offset was read after its entrance had started, when its cell had already slid up by the panel's height, so the line hung above the panel's clip for the whole glide. The offset is now read with the panel's other borders, before its entrance moves its cell.
There was a problem hiding this comment.
Approval waits on an engineering owner's spec decision and two fixes.
Spec decision: an engineering owner approves or amends the proposed changes by commenting /approve-spec dbe99e3d6366c9cb25575331ee97f7d951c2844d on this pull request; the author may do so as an engineering owner. The changes are the spec:AST-105 FR9 slide sentence, the architecture:react-component-runtime INV12 descent and its two verification failures, component:Collapsible AV5, and the component:Table muted-panel gap, and the approval also covers the slide mouse users now see.
Blocking:
- Miss: while a default Collapsible with
animatedLayoutopens or closes, the sliding lines run into the trigger label's descenders, because the still clip sits at the region's border box and the trigger's trimmed label hangs below the button, so the clip should start at the region's content box, with a paint case that checks it mid-open. - Miss: the changeset says Table's row expansion now slides and stays with the content on iOS, but a
panelVariant="muted"panel keeps the moving clip and its drift, so please name that exception there.
[Automated review]
The still clip sat on the element's border box, so the sliding parts passed through its padding, where the content before it can draw: a Collapsible trigger's label descenders hang there. The clip now starts at the content box on the side the parts come from. The changeset names the muted Table panel, which keeps the moving clip.
|
/approve-spec 17c9f15 |
There was a problem hiding this comment.
Changes requested: two fixes before this can land.
- Miss: expanding a nested row while its parent's reveal is still sliding (for example "Trips" within 120 ms of "Photos" in the Animated layout story) makes the rows after it jump to their final places and opens a 45 px gap, with Party.jpg drawn over Documents, because the follower pass counts a part's running slide as motion the app owns (
animatedLayout.ts:637,:1501); carry the slide into that part's glide and add a paint case for a nested change mid-slide. - Miss: the title says every edge reveal slides, but only block edges do (
animatedLayout.ts:1745), so please retitle it "fix(core): a block-edge reveal slides its parts on the glide's frames".
The spec changes are approved for this head, the earlier trigger-label collision, changeset wording and Table divider findings stay fixed, and three optional comment suggestions are inline.
[Automated review]
A second change in the area, such as a nested row expanding while its parent's group still slides, read a part's running slide as the app's own move. The part then landed at once, and the rows after it jumped. A part's slide is now its glide, so the next change carries its rest into the part's new glide. A ride reads each glide on its own clock, so a nested reveal rides a neighbour that an earlier change set moving.
A ride retimes a slide, so the part's glide reads the slide's length off the slide. It records the part's ancestors' scale, read with the part's box. A part that an earlier change still glides keeps that glide, and the element keeps the moving clip.
There was a problem hiding this comment.
Approved pending CI: CI has not run on this head because the pull request is still a draft, and it runs once the pull request is marked ready for review.
Both earlier findings are fixed: a nested row expanded while its parent's group still slides now glides with the rows after it, and the title now says block-edge. The spec changes carry an engineering owner's approval for this head. A few optional suggestions are inline: name the still-gliding-part fallback in FR9 at its next edit, forget a cancelled slide's glide in the two fallback branches, and five comment rewordings.
[Automated review]
| if (box.bottom >= band.start) { | ||
| // A part an earlier change still glides keeps that glide, which a slide | ||
| // would hide and then show again. The element keeps the moving clip. | ||
| if (glides.has(node as Element)) { |
There was a problem hiding this comment.
Non-blocking: FR9's approved sentence lists the elements that keep a moving clip (text of its own, a child a translation cannot move, a box or generated box it paints), but not an element whose part still glides from an earlier change, which this check adds. The behaviour here is the base's and serves FR3, so naming the case at FR9's next edit keeps the record exact.
| if (animation != null) { | ||
| if (animation == null) { | ||
| for (const part of partMotions) { | ||
| part.cancel(); |
There was a problem hiding this comment.
Non-blocking: now that a slide is registered as the part's glide, part.cancel() leaves it in glides, so a later reveal of this element finds a gliding part and keeps the moving clip. stopGlideOf(part) cancels it and forgets it; the same applies to holdLayoutExit's fallback at line 2664.
| // An exit's slide then holds its end until the release. The element is | ||
| // inert and has given up its space by then. |
There was a problem hiding this comment.
Non-blocking (INV29): this sits above the code that forgets a finished slide but does not say so. Suggested: "A finished slide is no glide. An exit's slide holds its end until the release, but the element is inert and has given up its space, so no later change carries it."
| return duration > 0 ? duration : fallback; | ||
| } | ||
|
|
||
| /** Each part's slide, by its motion: a stopped slide is no glide. */ |
There was a problem hiding this comment.
Non-blocking (INV29): "Each part's slide, by its motion" reads as the reverse of this map, which goes from a slide to its part. Suggested: "The part each slide moves, so stopping the slide also forgets it as that part's glide."
| readonly animation: Animation; | ||
| /** The fraction of the element it shows `t` ms in (1: all of it). */ | ||
| shownAt: (t: number) => number; | ||
| /** The parts that slide under the element's clip, and their motions. */ |
There was a problem hiding this comment.
Non-blocking (INV29): this holds only the slide animations, not the parts. Suggested: "The parts' slide animations."
| } | ||
|
|
||
| /** Stops `motion`'s sliding parts and puts back the element's clip, once. */ | ||
| function stopSlides(motion: EdgeMotion): void { |
There was a problem hiding this comment.
Non-blocking (INV29): stopSlides only calls motion.release(); calling release() at its two callers lets this wrapper and its comment go.
| // The parts come in from one side. The clip holds them inside the content | ||
| // box there, off what the content before the element draws into its padding. |
There was a problem hiding this comment.
Non-blocking (INV29): for a block-start edge the clip sits at the bottom, where no content before the element draws. Suggested: "The clip holds them inside the content box on that side, off what a neighbour draws into the padding."
|
/approve-spec dbe8bcf |
User impact
On an iPhone, a Collapsible, TreeList row or Table panel with an
animatedLayouthandle shows a band, then an overlap, beside its revealed content for a few frames.Problem and solution fit
The reveal moved a
clip-path, which WebKit paints on the main thread, while the content after it glides by a composited translate: same start and keyframes, different clocks.Now the element's child elements in the band slide on the glide's frames under a still clip at its content box, and the element fades: one clock for both edges. Text of its own, a child a translation cannot move, or a box it paints (Table's muted panel) keeps the moving clip.
Expected behavior and authority
spec:AST-105FR9: the moving edge and the content on that side move on one motion, "so the content beside the edge glides with it and no gap opens". FR9 now states the slide and fallbacks,architecture:react-component-runtimeINV12 bounds its descent, andcomponent:Tablerecords the panel row's gap: Specs decision, Nov 6 2026 (consistency amendment; rationale: "the clip-only reveal drifts 3–5 frames on iOS WebKit; moving the band's own children keeps INV12's cost bound").component:CollapsibleAV5 marks its region's new inner element internal.Smallest restoration
Only block-edge reveals and conceals change, on every engine: content slides in from its edge instead of a wipe. Inline edges follow separately.
Evidence
Writing rubric results
R1 narration: none. R2 research: none. R3 evidence: INV12's verification row names the new failures; the boundary and paint tests cover them. R4 rejected alternatives: none. R5 change references: none. R6 open questions: none.
Scope
Testing
What was run at dbe8bcf (WebKit in the Linux CI image):
check:repo,check:knowledge, changeset coverage andreview:prepass.CI=true pnpm lint: 0 errors. Coretsc: 0 errors.TableRowExpandSlot: 1 passed in each engine.test:ui: 896 files, 21,934 tests.test:node: 936 files, 16,938 tests. No unhandled errors.