Skip to content

fix(NavigationStack): screen content stays under the bar - #12001

Merged
cixzhang merged 4 commits into
mainfrom
fix/navigationstack-card-stacking
Nov 17, 2026
Merged

cixzhang merged 4 commits into
mainfrom
fix/navigationstack-card-stacking

Conversation

@cixzhang

@cixzhang cixzhang commented Nov 16, 2026 •

Copy link
Copy Markdown
Contributor

User impact

In an app built on Lab NavigationStack, screen content with a z-index of 2 or more (a raised banner, a sticky header, a floating panel) painted over the navigation bar and covered its title and Back button. A person could not read the title or tap Back. After this change, screen content always stays under the bar, whatever its z-index.

Problem and solution fit

  • Why it fails: the bar is isolation: isolate; z-index: 1. The cards that hold each screen set no z-index and created no stacking context at rest, so a screen child's own z-index competed with the bar's in the stack's parent stacking context, and 2 beat 1. During a push or pop each card moves by transform, which does create a stacking context, so the defect showed only at rest.
  • The fix: each card sets isolation: isolate, so at rest it is the same stacking context a transform makes it during a transition. Screen content's z-index then stays inside its card, and the bar (z-index 1) paints above every card. Every negative z-index in the component is inside the bar, so isolating the card moves nothing else.

Expected behavior and authority

spec:AST-020 FR1 holds Core and Lab to WCAG 2.2 AA, which includes SC 2.4.11 Focus Not Obscured (Minimum): when the bar's Back button or title has keyboard focus, author content must not hide it entirely. A screen child with a higher z-index covered both completely. The specification owner confirmed this is a records-decided repair with no new API. When the NavigationStack component record is written, it states this as a rule: screen content never paints over the bar.

Smallest restoration

  • NavigationStack.tsx: one style property on the card, with a comment.
  • A new story, Raised content under the bar, and tests.
  • No public API change. No changeset, because @astryxdesign/lab is private.

Evidence

  • Red first (jsdom): gives every card isolation: 'isolate' at rest fails before the change (no isolation) and passes after, for the root and a pushed card.
  • Browser: a new case in NavigationStack.interaction.browser.spec.ts, under a finger and under a mouse. On the new story, where a screen child with z-index: 2 covers the top 160 px, elementFromPoint at the bar title's center and at Back's center hits them, and a click on Back pops. It runs in CI's interaction leg; this machine's sandbox cannot launch Chromium.
  • Device: before (the parent with only the new story added), on desktop WebKit with an iPhone 14 profile, 2 takes: the title and Back sat under the raised band, the topmost element at Back's center was the band, and a tap on Back did nothing. After, at this head, on the same profile (2 takes) and on a physical iPhone 14 in iOS 26.2 Safari (2 takes): Back sits above the band, and a tap pops to Settings.
  • Unchanged paths: the NavigationStack unit suites pass (41 tests in 2 files).

Scope

Components: NavigationStack (lab)

  • One defect is restored.
  • Separable contradictory or unsettled tagalongs were removed or split.
  • No new public API, visual representation, default, or interaction model is hidden under the bug-fix label.
  • Public text and artifacts contain no internal Meta context.

Testing

  • vitest run packages/lab/src/NavigationStack: 41 passed, red first as above.
  • eslint (strict) on the changed files: no errors.

Owner and land path

Owner: Cindy's Astryx gaps lane 3 (agent). Land path: Specs stamp as a defect repair, then CodeBunny review on the exact head, then ready, CI, and merge through the drain queue. No release (@astryxdesign/lab is private).

A card was not a stacking context at rest, so a screen child with a z-index of 2 or more painted over the bar, whose z-index is 1, and covered its title and Back. Each card now isolates its content, as a transform already does during a transition, so transitions are unchanged. A jsdom check, a story with raised content under the bar and a browser case (title and Back hit by elementFromPoint, Back pops) cover it.
@vercel

vercel Bot commented Nov 16, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
astryx Ready Ready Preview Nov 17, 2026 7:24pm UTC

Request Review

@meta-cla meta-cla Bot added the CLA Signed This label is managed by the Meta Open Source bot. label Nov 16, 2026
@astracat-bot

astracat-bot Bot commented Nov 16, 2026 •

Copy link
Copy Markdown
Contributor

AI review status for this pull request.

Review status Updated
🟢 Reviewed (for maintainers only) Nov 17, 2026, 8:48 PM UTC

@cixzhang

Copy link
Copy Markdown
Contributor Author

/approve-spec 3b3c2a5

@github-actions

github-actions Bot commented Nov 16, 2026 •

Copy link
Copy Markdown
Contributor

PR Analysis Report

🔎 Preview · f1a7470

Storybook · Sandbox · built from this PR's head

Modified components

Component Size LoC Visual · A11y · RTL
lab/NavigationScreen 85.2 kB (+5 B) · 1.5 kB CSS (0) — — · ✓ · ✗
lab/NavigationStack 85.2 kB (+6 B) · 1.5 kB CSS (0) — — · ✓ · ✓

Package size: no published package changed; no new dependencies.

Touched components checked; for the full suites, add ci:run-visual for Visual, ci:run-a11y for Accessibility, ci:run-rtl for RTL.


Generated by PR Enrichment workflow | View full report

@astracat-bot astracat-bot Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changes requested: the fix works, since each card is now a stacking context at rest and the bar's title and Back stay above raised screen content, but one description claim needs correcting.

  • The "Expected behavior and authority" section attributes the quoted lines about the bar overlaying the screens and the back button staying put to spec:AST-094, but no current record contains them (they are source comments at NavigationStack.tsx lines 166-167 and 236), so please say that no record states this rule yet and that the engineering owner's /approve-spec on this head records the decision.

In Chromium on the new story, the base's title and Back sit under the raised layer, while on this head both receive the hit and Back pops under a mouse and under a finger. CI has not run on this draft yet.

Claims and files checked

Review mode: full; reason: no-earlier-review

  • Claim: raised content (z-index 2 or more) covered the bar's title and Back on the base. Verified by a Chromium probe on the new story.
  • Claim: screen content now stays under the bar whatever its z-index. Verified by the probe; isolation: isolate at NavigationStack.tsx:316 contains every z-index.
  • Claim: the bar is isolated at z-index 1, and cards formed no stacking context at rest. Verified at NavigationStack.tsx:168-175 and :313-319.
  • Claim: cards form a stacking context only while they move. Verified: the animator drives translate.
  • Claim: every negative z-index in the component is inside the bar. Verified at NavigationStack.tsx:184, :206 and :230.
  • Claim: spec:AST-094 contains the quoted bar and back-button lines. False: they are source comments at NavigationStack.tsx:166-167 and :236.
  • Claim: UIKit keeps its bar above content. Not checkable in the repository.
  • Claim: the spec owner approved the repair with no new API. Verified in part: an engineering owner commented /approve-spec at this head and no API changes, but no record decides it.
  • Claim: one style property, a new story and tests; no public API; no changeset because Lab is private. Verified.
  • Claim: the jsdom check fails before the fix and passes after it. Verified: one failure on the base, 40 passed on the head.
  • Claim: a browser case runs under a finger and a mouse. Present in the spec file; not yet run in CI.
  • Claim: iOS device stills follow in a comment. Not posted yet.
  • Claim: the unit suites pass (40 tests in 2 files) and eslint is clean. Verified.
  • File packages/lab/src/NavigationStack/NavigationStack.tsx: clear.
  • File packages/lab/src/NavigationStack/NavigationStack.test.tsx: non-blocking. The check reads a private style; name it after what it asserts.
  • File packages/lab/src/NavigationStack/__tests__/NavigationStack.interaction.browser.spec.ts: clear.
  • File apps/storybook/stories/NavigationStack.stories.tsx: clear.

Automated review (maintainer link)

@astracat-bot astracat-bot Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved pending CI: CI has not run on this draft head yet; it runs once the pull request is marked ready. Each card is now a stacking context at rest, so raised screen content no longer covers the bar's title and Back, and the description's authority section now matches the records.

  • Non-blocking: consider naming the jsdom check in NavigationStack.test.tsx after what it asserts (the card's isolation), since the browser case is what shows that screen content stays under the bar.

In Chromium on the new story, the base's title and Back sit under the raised layer and Back does not pop; on this head both receive the hit and Back pops under a mouse and under a finger.

Claims and files checked

Review mode: same-head; reason: none

  • Claim: raised screen content (z-index 2 or more) covered the bar's title and Back on the base, so the title could not be read and Back could not be pressed. Verified by a Chromium probe on the new story: both hits land on the raised layer and Back does not pop.
  • Claim: screen content now stays under the bar whatever its z-index. Verified: isolation: isolate at NavigationStack.tsx:316; the probe hits the title and Back, and Back pops.
  • Claim: the bar is isolated at z-index 1, and the cards set no z-index and formed no stacking context at rest. Verified at NavigationStack.tsx:168-175 and the base card style.
  • Claim: cards move by a transform during a push or pop, so the defect showed only at rest. Verified: the stack moves each card through the animator's translate (NavigationStack.tsx:1085).
  • Claim: every negative z-index in the component is inside the bar. Verified at NavigationStack.tsx:184, :206 and :230.
  • Claim: the repository's accessibility baseline is WCAG 2.2 AA, which includes Focus Not Obscured (Minimum) for a focused Back or bar title. Verified: the accessibility record makes WCAG 2.2 A and AA the global baseline and lists that criterion, and the bar title takes focus after a push (NavigationStack.tsx:1359-1371).
  • Claim: raised content with a higher z-index covered both completely. Verified for the story: the layer spans the whole bar and takes both hits.
  • Claim: the spec owner confirmed a records-decided repair with no new API. Verified: an engineering owner approved the spec for this head, no API changes, and the stacking and accessibility records support the repair.
  • Claim: a NavigationStack record, once written, will state the rule. Not checkable: no such record exists yet.
  • Claim: one style property with a comment, a new story and tests; no public API; no changeset because Lab is private. Verified.
  • Claim: the jsdom check fails before the fix and passes after it, for the root and a pushed card. Verified: one failure on the base, 40 passed on the head.
  • Claim: a browser case under a finger and a mouse checks both hits and the pop, in CI's interaction leg. Verified present (NavigationStack.interaction.browser.spec.ts:1510-1548); not yet run in CI.
  • Claim: iOS device stills follow in a comment. Not posted yet.
  • Claim: the unit suites pass (40 tests in 2 files) and eslint is clean on the changed files. Verified.
  • File packages/lab/src/NavigationStack/NavigationStack.tsx: clear.
  • File packages/lab/src/NavigationStack/NavigationStack.test.tsx: non-blocking naming note.
  • File packages/lab/src/NavigationStack/__tests__/NavigationStack.interaction.browser.spec.ts: clear.
  • File apps/storybook/stories/NavigationStack.stories.tsx: clear.

Automated review (maintainer link)

@cixzhang
cixzhang marked this pull request as ready for review November 17, 2026 16:17
@cixzhang cixzhang added the release-critical Admitted to CI at once (AST-030 DEC-30). Counts only when a writer applies it. label Nov 17, 2026
Main moved past #12297 (CI planner budget); a clean merge, no conflicts.
@cixzhang
cixzhang marked this pull request as draft November 17, 2026 16:37

@astracat-bot astracat-bot Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changes requested: the fix works, since each card is now a stacking context at rest and raised screen content no longer covers the bar's title and Back, but the new browser case cannot catch a regression of it.

  • Miss: the browser case "screen content with z-index 2 stays under the bar's title and Back" passes on the base without the fix, because it reads its hits while the card's animator still holds will-change (for 500 ms after the card's last motion), so wait for the card's will-change to read auto before reading them; with that wait it fails on the base and passes on this head.
  • Non-blocking: consider naming the jsdom check in NavigationStack.test.tsx after what it asserts (the card's isolation), since only the browser case observes that screen content stays under the bar.

Once the screen settles, the base's title and Back sit under the raised layer and Back does not pop in Chromium, while on this head both receive the hit and Back pops under a mouse and under a finger.

Claims and files checked

Review mode: same-head; reason: none

  • Claim: raised screen content (z-index 2 or more) covered the bar's title and Back on the base, so the title could not be read and Back could not be pressed. Verified by a Chromium probe on the new story once the card settles: both hits land on the raised layer and a click or tap on Back does not pop.
  • Claim: screen content now stays under the bar whatever its z-index. Verified: isolation: isolate at NavigationStack.tsx:316; the probe hits the title and Back, and Back pops.
  • Claim: the bar is isolated at z-index 1, and the cards set no z-index and formed no stacking context at rest. Verified at NavigationStack.tsx:168-175 and the base card style.
  • Claim: cards move by a transform during a push or pop, so the defect showed only at rest. Verified: the stack moves each card through the animator's translate (NavigationStack.tsx:1085); the animator also keeps will-change on the card for 500 ms after it moves.
  • Claim: every negative z-index in the component is inside the bar. Verified at NavigationStack.tsx:184, :206 and :230.
  • Claim: the accessibility baseline is WCAG 2.2 AA, which includes Focus Not Obscured (Minimum) for a focused Back or bar title. Verified: the accessibility record makes WCAG 2.2 A and AA the baseline and lists that criterion, and the bar title takes focus after a push (NavigationStack.tsx:1359-1371).
  • Claim: raised content with a higher z-index covered both completely. Verified for the story: the layer spans the whole bar and takes both hits.
  • Claim: the spec owner confirmed a records-decided repair with no new API. Verified: an engineering owner approved the spec for this head, and no API changes.
  • Claim: a NavigationStack record, once written, will state the rule. Not checkable: no such record exists yet.
  • Claim: one style property with a comment, a new story and tests; no public API; no changeset because Lab is private. Verified.
  • Claim: the jsdom check fails before the fix and passes after it, for the root and a pushed card. Verified: one failure on the base, 40 passed on the head.
  • Claim: a browser case under a finger and a mouse checks both hits and the pop, in CI's interaction leg. Present as described, but it also passes on the base (the finding above), and CI has not run it yet.
  • Claim: before and after results on a WebKit iPhone profile and on a physical iPhone. Stated in text; consistent with the settled-state probe.
  • Claim: the unit suites pass (40 tests in 2 files) and eslint is clean on the changed files. Verified.
  • File packages/lab/src/NavigationStack/NavigationStack.tsx: clear.
  • File packages/lab/src/NavigationStack/NavigationStack.test.tsx: non-blocking naming note.
  • File packages/lab/src/NavigationStack/__tests__/NavigationStack.interaction.browser.spec.ts: blocking, the new case passes without the fix.
  • File apps/storybook/stories/NavigationStack.stories.tsx: clear.

Automated review (maintainer link)

@cixzhang

Copy link
Copy Markdown
Contributor Author

/approve-spec d06b1f6

@astracat-bot astracat-bot Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changes requested: the fix works, since each card is now a stacking context at rest and raised screen content no longer covers the bar's title and Back, but the new browser case cannot catch a regression of it.

  • Miss: the browser case "screen content with z-index 2 stays under the bar's title and Back" passes on the base without the fix, because it reads its hits while the card's animator still holds will-change (for 500 ms after the card's last motion), so wait for the card's will-change to read auto before reading them; with that wait it fails on the base and passes on this head.
  • Non-blocking: consider naming the jsdom check in NavigationStack.test.tsx after what it asserts (the card's isolation), since only the browser case observes that screen content stays under the bar.

Once the screen settles, the base's title and Back sit under the raised layer and Back does not pop in Chromium, while on this head both receive the hit and Back pops under a mouse and under a finger.

Claims and files checked

Review mode: carry-forward; reason: none

  • Claim: raised screen content (z-index 2 or more) covered the bar's title and Back on the base, so the title could not be read and Back could not be pressed. Verified by a Chromium probe on the new story once the card settles: both hits land on the raised layer and a click or tap on Back does not pop.
  • Claim: screen content now stays under the bar whatever its z-index. Verified: isolation: isolate at NavigationStack.tsx:316; the probe hits the title and Back, and Back pops.
  • Claim: the bar is isolated at z-index 1, and the cards set no z-index and formed no stacking context at rest. Verified at NavigationStack.tsx:168-175 and the base card style.
  • Claim: cards move by a transform during a push or pop, so the defect showed only at rest. Verified: the stack moves each card through the animator's translate (NavigationStack.tsx:1085); the animator also keeps will-change on the card for 500 ms after it moves.
  • Claim: every negative z-index in the component is inside the bar. Verified at NavigationStack.tsx:184, :206 and :230.
  • Claim: the accessibility baseline is WCAG 2.2 AA, which includes Focus Not Obscured (Minimum) for a focused Back or bar title. Verified: the accessibility record makes WCAG 2.2 A and AA the baseline and lists that criterion, and the bar title takes focus after a push (NavigationStack.tsx:1359-1371).
  • Claim: raised content with a higher z-index covered both completely. Verified for the story: the layer spans the whole bar and takes both hits.
  • Claim: the spec owner confirmed a records-decided repair with no new API. Verified: an engineering owner approved the spec for this head, and no API changes.
  • Claim: a NavigationStack record, once written, will state the rule. Not checkable: no such record exists yet.
  • Claim: one style property with a comment, a new story and tests; no public API; no changeset because Lab is private. Verified.
  • Claim: the jsdom check fails before the fix and passes after it, for the root and a pushed card. Verified: one failure on the base, 40 passed on the head.
  • Claim: a browser case under a finger and a mouse checks both hits and the pop, in CI's interaction leg. Present as described, but it also passes on the base (the finding above), and CI has not run it yet.
  • Claim: before and after results on a WebKit iPhone profile and on a physical iPhone. Stated in text; consistent with the settled-state probe.
  • Claim: the unit suites pass (40 tests in 2 files) and eslint is clean on the changed files. Verified.
  • File packages/lab/src/NavigationStack/NavigationStack.tsx: clear.
  • File packages/lab/src/NavigationStack/NavigationStack.test.tsx: non-blocking naming note.
  • File packages/lab/src/NavigationStack/__tests__/NavigationStack.interaction.browser.spec.ts: blocking, the new case passes without the fix.
  • File apps/storybook/stories/NavigationStack.stories.tsx: clear.

Automated review (maintainer link)

…ter will-change lets go

The animator holds will-change on a card briefly after its last motion, and that alone makes a stacking context, so the browser case passed on the base too. It now waits until every card reads will-change: auto. The jsdom case is named after what it asserts.
@cixzhang

Copy link
Copy Markdown
Contributor Author

/approve-spec 87e9fe9

@astracat-bot astracat-bot Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved pending CI: required checks are still running on this head. Each card is now a stacking context at rest, so raised screen content stays under the bar's title and Back, and the new browser case passes in CI in Chromium and WebKit, under a finger and under a mouse.

  • The accessibility dependent-audit plan timed out while checking out the repository, so it and Dependent audits (1/1) failed before reaching this change; re-run those jobs.
  • Non-blocking: the description's red-first line still names the jsdom check keeps every card a stacking context at rest; it is now gives every card isolation: 'isolate' at rest.
Claims and files checked

Review mode: same-head; reason: none

  • Changed rules since the last review: none.
  • Claim: screen content with a z-index of 2 or more painted over the bar and covered its title and Back, so the title could not be read and Back could not be tapped. Verified: with the new story on the base code, hits at the title's and Back's centres land on the raised layer and a click on Back does not pop (Chromium, mouse and finger).
  • Claim: after the change, screen content stays under the bar whatever its z-index. Verified: isolation: isolate on each card (NavigationStack.tsx:316) keeps every descendant z-index inside the card; on this head both hits land on the title and Back, and Back pops.
  • Claim: the bar is isolated at z-index 1, the cards set no z-index and formed no stacking context at rest, and a screen child's z-index competed with the bar in the stack's parent stacking context. Verified at NavigationStack.tsx:159-175 and the base card style.
  • Claim: during a push or pop each card moves by a transform, so the defect showed only at rest. Verified: the animator moves each card with translate and holds will-change briefly after its last motion.
  • Claim: every negative z-index in the component is inside the bar, so isolating the card moves nothing else. Verified at NavigationStack.tsx:184, :206 and :230, all parts of the bar.
  • Claim: the accessibility record's first requirement holds the components to WCAG 2.2 AA, which includes 2.4.11 Focus Not Obscured. Verified: it sets WCAG 2.2 A and AA as the conformance baseline with no package exception, and its source map lists 2.4.11.
  • Claim: a screen child with a higher z-index covered the title and Back completely. Verified by the hit test above.
  • Claim: the specification owner confirmed a records-decided repair with no new API. Verified: an engineering owner commented /approve-spec for this head.
  • Claim: the NavigationStack record will state the rule when it is written. Not checkable: a future intent.
  • Claim: one style property with a comment, a new story and tests, no public API change, and no changeset because the Lab package is private. Verified: the diff, and packages/lab/package.json is private.
  • Claim: the jsdom check fails before the change and passes after it, for the root and a pushed card. Verified in substance: it fails on the base with expected '' to be 'isolate' and passes on this head; the description names it by its old title.
  • Claim: the browser case, under a finger and under a mouse, hit-tests the title and Back on the new story, where a z-index 2 layer covers the top 160 px, and pops with a click on Back. Verified: it passes on this head and fails on the base code under both pointers.
  • Claim: the browser case runs in CI's interaction leg. Verified: it passed there on this head in Chromium and WebKit, under both pointers.
  • Claim: the author's environment could not launch Chromium. Not checkable; the case was run in Chromium for this review and in CI.
  • Claim: device before and after results on an emulated and a physical iPhone. Accepted as stated maintainer evidence.
  • Claim: the NavigationStack unit suites pass, 40 tests in 2 files. Verified: 40 passed in 2 files.
  • Claim: strict eslint reports no errors on the changed files. Verified: eslint exits clean on the four files, and CI lint passed on this head.
  • Claim: one defect, no tagalongs, no hidden API or interaction change, and no internal context in public text. Verified over the diff, the commits, the title and the description.
  • Claim: the planned land path, with no release. Not checkable as a plan; no release follows because the Lab package is private.
  • File packages/lab/src/NavigationStack/NavigationStack.tsx: clear.
  • File packages/lab/src/NavigationStack/NavigationStack.test.tsx: clear.
  • File packages/lab/src/NavigationStack/__tests__/NavigationStack.interaction.browser.spec.ts: clear.
  • File apps/storybook/stories/NavigationStack.stories.tsx: clear.

Automated review (maintainer link)

@cixzhang
cixzhang marked this pull request as ready for review November 17, 2026 18:13
Main brought in #12009, which touches NavigationStack.tsx and its test on other lines; a clean merge.
@cixzhang
cixzhang marked this pull request as draft November 17, 2026 19:11
@cixzhang

Copy link
Copy Markdown
Contributor Author

/approve-spec f1a7470

@astracat-bot astracat-bot Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved pending CI: some required checks are still running on this head. Each card is now a stacking context at rest, so raised screen content stays under the bar's title and Back; the new browser case fails without the fix and passes with it, and it passed in CI's Chromium and WebKit interaction legs on this head. The description's red-first test name and unit-test count now match the code.

Claims and files checked

Review mode: same-head; reason: none

  • Claim: screen content with a z-index of 2 or more painted over the bar and covered its title and Back, so the title could not be read and Back could not be tapped. Verified: with the new story on the base code, the hits at the title's and Back's centres land on the raised layer, and a click or a tap on Back leaves the pushed screen on top (Chromium).
  • Claim: after the change, screen content stays under the bar whatever its z-index. Verified: isolation: isolate on each card (NavigationStack.tsx:316) keeps every descendant z-index inside the card; on this head both hits land on the title and Back, and Back pops.
  • Claim: the bar is isolated at z-index 1, the cards set no z-index and formed no stacking context at rest, and a screen child's z-index competed with the bar's. Verified at NavigationStack.tsx:168-175 and the base card style.
  • Claim: during a push or pop each card moves by a transform, so the defect showed only at rest. Verified: the animator moves each card with translate and holds will-change briefly after its last motion.
  • Claim: every negative z-index in the component is inside the bar, so isolating the card moves nothing else. Verified at NavigationStack.tsx:184, :206 and :230, all rendered inside the bar.
  • Claim: the accessibility record's first requirement holds the components to WCAG 2.2 AA, which includes 2.4.11 Focus Not Obscured. Verified: it sets WCAG 2.2 A and AA as the conformance baseline, and its source map lists 2.4.11.
  • Claim: a screen child with a higher z-index covered the title and Back completely. Verified by the hit test above.
  • Claim: the specification owner confirmed a records-decided repair with no new API. Verified: an engineering owner commented /approve-spec for this head, and the fix matches the current local-stacking record.
  • Claim: the NavigationStack record will state the rule when it is written. Not checkable: a future intent.
  • Claim: one style property with a comment, a new story and tests, no public API change, and no changeset because the Lab package is private. Verified: the diff, and the Lab package is private.
  • Claim: the jsdom check gives every card isolation: 'isolate' at rest fails before the change and passes after it, for the root and a pushed card. Verified: it fails on the base code with expected '' to be 'isolate' and passes on this head.
  • Claim: the browser case, under a finger and under a mouse, hit-tests the title and Back on the new story, where a z-index 2 layer covers the top 160 px, and pops with a click on Back. Verified: it passes on this head and fails on the base code under both pointers in Chromium.
  • Claim: the browser case runs in CI's interaction leg. Verified: it passed in CI's Chromium interaction leg and its WebKit leg on this head, under a finger and under a mouse.
  • Claim: the author's environment could not launch Chromium. Not checkable; the case was run in Chromium for this review.
  • Claim: device before and after results on an emulated and a physical iPhone. Accepted as stated maintainer evidence.
  • Claim: the NavigationStack unit suites pass, 41 tests in 2 files. Verified: 41 tests in 2 files pass on this head.
  • Claim: strict eslint reports no errors on the changed files. Verified: strict eslint exits clean on the four files.
  • Claim: one defect, no tagalongs, no hidden API or interaction change, and no internal context in public text. Verified over the diff, the commits, the title and the description.
  • Claim: the planned land path, with no release. Not checkable as a plan; no release follows because the Lab package is private.
  • File packages/lab/src/NavigationStack/NavigationStack.tsx: clear.
  • File packages/lab/src/NavigationStack/NavigationStack.test.tsx: clear.
  • File packages/lab/src/NavigationStack/__tests__/NavigationStack.interaction.browser.spec.ts: clear.
  • File apps/storybook/stories/NavigationStack.stories.tsx: clear.

Automated review (maintainer link)

@cixzhang
cixzhang marked this pull request as ready for review November 17, 2026 20:29
@cixzhang
cixzhang merged commit 4f2ebbd into main Nov 17, 2026
151 checks passed
@cixzhang cixzhang removed the release-critical Admitted to CI at once (AST-030 DEC-30). Counts only when a writer applies it. label Nov 17, 2026
cixzhang added a commit that referenced this pull request Nov 18, 2026
Main brought in the merged NavigationStack fixes (#12009, #12010, #12001) on other lines of NavigationStack.tsx and its test; a clean merge.
@github-actions
github-actions Bot deleted the fix/navigationstack-card-stacking branch November 18, 2026 06:04
cixzhang added a commit that referenced this pull request Nov 21, 2026
…ys no second animation (#12004)

* test(sandbox): a raw page that logs whether the platform animated a history back

On a real phone, the page pushes two history entries and logs each popstate and Navigation API navigate event with its hasUAVisualTransition, and the display mode it runs in. It is the evidence page for NavigationStack skipping its own pop or push animation after a platform-animated traversal.

* fix(NavigationStack): a platform-animated history back or forward plays no second animation

When the platform has just animated a history traversal (Safari's edge swipe back or forward, an iOS Home Screen app's back gesture), the browser sets hasUAVisualTransition on the Navigation API navigate event and on popstate. The stack marks it for two frames, and the path change that traversal causes is applied at once: a pop drops the leaving screen with no slide, a push puts the new screen on top with no slide. Focus moves as after any settled push or pop. A traversal the platform did not animate still slides.

* fix(NavigationStack): the traversal listeners attach with the container

The popstate and navigate listeners now attach in the container ref callback on the element window, beside the modality tracker, and detach with it, so a stack moved to another document listens to its new window. The probe page keys screens by position and name, sets the path when the stack pops before it moves the history, and leaves its own two entries out of the stack path.

* test(sandbox): the probe stack follows a back to the page's first entry

The router marks the first history entry, so its state is neither null nor a stack path. The probe now skips only its own two step entries and treats any other entry without a path as the root. The component JSDoc names the exception to its animation.

* Merge main into PR #12004's branch

Main moved past #12297 (CI planner budget); a clean merge, no conflicts.

* Merge main into PR #12004's branch

Main brought in the merged NavigationStack fixes (#12009, #12010, #12001) on other lines of NavigationStack.tsx and its test; a clean merge.

* Merge main into fix/navigationstack-ios-platform-back

* chore(sandbox): drop the history-back probe page from this change

The probe page served only the device takes. Without it this pull request
changes the Lab NavigationStack and its test alone.

* test(NavigationStack): a traversal that hides the stack before the mark clears leaves no mark

* fix(NavigationStack): detaching the traversal listener clears the platform mark

A container that detached within two frames of a browser-marked traversal
kept the mark, so the next tap push or Back pop played no slide.

* Merge main into fix/navigationstack-ios-platform-back

This branch was successfully deployed

1 active deployment
Preview — f1a74703 Deployed Nov 17, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Meta Open Source bot.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant