Repository navigation
docs(spec): promote component:BottomSheet and component:BottomSheetSwitcher to current - #7822
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
AI review status for this pull request.
|
PR Analysis Report
The exact-head preview is not available yet. Generated by PR Enrichment workflow | View current CI run |
There was a problem hiding this comment.
Approval waits on an engineering owner approving component:BottomSheet and component:BottomSheetSwitcher as current at this exact head: spec-owner-approval is still pending, and the approval on #7744 covered the switcher's decisions as draft content on another head. Before that, please drop packages/core/src/BottomSheet/__tests__/BottomSheetNativeModal.a11y.browser.spec.ts from the verified_by list of both records (BottomSheet.spec.md line 18, BottomSheetSwitcher.spec.md line 16), because the file is not in the tree yet and only the switcher's verification map says so. A new commit resets exact-head approval, so making that edit first saves a second approval. The rewritten Compatibility section, the DEP-0009/CLN-0018 removal and the implementation-gap notes match the shipped code.
[Automated review]
| kind: component | ||
| id: component:BottomSheet | ||
| authority: draft | ||
| authority: current |
There was a problem hiding this comment.
Promoting this record keeps packages/core/src/BottomSheet/__tests__/BottomSheetNativeModal.a11y.browser.spec.ts in verified_by (line 18), but that file is not in the tree yet and nothing in this record says so. Please drop it from the list until the browser spec lands.
| | Contract | Verification | Representative states | Mutation or failure expectation | Audit section | | ||
| | ---------------- | ----------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------- | | ||
| | FR1–FR4, FR8 | `BottomSheetSwitcher.test.tsx` | closed, first open, handoffs in either completion order, rapid replacement, unmount, close | A child becomes interactive at the wrong time, a retained child disappears early, a second backdrop paints, or a sheet dialog's lifecycle breaks. | `audit:BottomSheetSwitcher/behavior` | | ||
| | FR5–FR7, AR1–AR3 | `BottomSheetSwitcher.test.tsx`; `BottomSheetNativeModal.a11y.browser.spec.ts` (implementation gap: not yet in the tree) | modal/non-modal, info/form/required, nested layer, IME, focus return, scroll lock in engines, non-modal local ordering | Modality, dismissal order, naming, inertness, scroll lock, or focus behavior diverges, or a sheet dialog takes a page-level z-index. | `audit:BottomSheetSwitcher/accessibility` | |
There was a problem hiding this comment.
This row now marks the browser spec as not yet in the tree, yet verified_by (line 16) still lists it. Dropping it there too keeps the front matter consistent until the spec is added.
…itcher to current Both records become current, approved by the owner on the per-step dialog decision (BottomSheetSwitcher DEC-1 and DEC-2). Every row is checked against the shipped source: where the switcher's one shared dialog does not yet meet a per-step requirement, the row carries a present-tense implementation gap note. The draft-only constructs go: the candidate-invariant and review-state columns, the owner-decision markers, the draft intent wording, and the completed padded-default transition (its deprecation and cleanup entries), whose Compatibility section now states the shipped default. No requirement text changes.
a6280af to
4152c07
Compare
|
/approve-spec 4152c07 |
Exact decision needed
Promote
component:BottomSheetandcomponent:BottomSheetSwitcherfromdrafttocurrent, so the per-step dialog contract the owner approved in #7744 (BottomSheetSwitcher DEC-1 and DEC-2, FR2, FR5, FR8, FR9, PR1, the representative states; BottomSheet's ownership and anatomy notes) governs implementation and review of #7720 and #7757.Existing authority searched
component:BottomSheetSwitcheron main (draft): FR1–FR9, AV1–AV2, ORD1–ORD2, PR1–PR2, AR1–AR3, DEC-1, DEC-2, OQ1–OQ3. Records are promoted whole, so this PR checked every existing row against current source before promoting; the switcher on main still renders one shared dialog and hosts every step as a panel inside it.component:BottomSheeton main (draft): FR1–FR4, AR1–AR2, DEC-1, DEP-0009, CLN-0018, OQ1. Checked the same way.spec:AST-017(current) FR7 and DEC-18: lifecycle ids (DEP-*/CLN-*) are optional descriptive cross-references, andCLN-*items are superseded; nothing else in the repo referencesDEP-0009orCLN-0018(searched main), andcheck:knowledgehas no DEP rule.452f7ae316(spec(core): each BottomSheetSwitcher step owns its native dialog #7744 (comment)), including the nonbreaking ruling DEC-2 records;imdreamrunneris listed in.github/ENGOWNERS, socheck:knowledgeaccepts the approval.spec:AST-002(current) DEC-5 requires current authority for public API and behavior changes; that is what holds feat(core): BottomSheetSwitcher presents each sheet in its own native dialog #7720.spec:AST-027(current) FR2/FR4/FR8: the non-modal path's page-level value stays recorded as a conformance gap, not an exception, in both the draft and the promoted record.BottomSheetSwitcherand is the alternative direction for the component; this PR promotes the decision the owner approved and does not settle that choice.Decision
Both records:
authority: current,approved_by: imdreamrunner,approved_at: 2026-10-21.ownersis unchanged. Following the shape of other current component records, each behavioral table drops its draft-only "Draft review state" column and is headed "Invariant". No requirement text changes. Every other non-front-matter edit:verified_byin both records no longer lists__tests__/BottomSheetNativeModal.a11y.browser.spec.ts: that browser spec is not in the tree on main yet. test(core): browser evidence for per-sheet switcher dialogs #7757 adds the file and lists it again in both records.component:BottomSheetSwitcherref,id, anddata-testidreaches the switcher's one shared dialog.useScrollLock(isModal)once per flow.)ref,id, anddata-testidreaches the one shared dialog, which never changes on a handoff.BottomSheetNativeModal.a11y.browser.spec.tscarries "(implementation gap: not yet in the tree)".component:BottomSheetspec:AST-025, and the tests stay.component:Dialog): "Released default preserved:yes; with nopaddingprop and no theme padding, the Content area insets by--spacing-4on every logical edge, andpadding={0}keeps an unpadded Content area"; "Compatibility class: records the shipped anatomy, padded Content area, and native dialog; no public prop, default, or export changes"; controlled/uncontrolled unchanged; "Migration decision: none; the precedence rule under Transformation and precedence order is the whole contract". The precedence rule itself (prop, then themepaddingonbottom-sheet, then--spacing-4) is unchanged.currentrecord cannot carry DEP-0009's "open decision: This record is draft and needs approval" row.Rejected alternatives
None on authority: row-level authority is not a convention for these records;
authorityis a record-level field. Promoting only the switcher record was considered and rejected: the owner asked for both, and the BottomSheet record's ownership and anatomy notes are the half of DEC-1 that the switcher record's rows refer to. Keeping DEP-0009/CLN-0018 with a completed state was considered and rejected:spec:AST-017FR26's lifecycle vocabulary has no state for a finished cleanup, the ids are optional cross-references (FR7, DEC-18), and the record would then carry history.Claim scope and non-goals
Promotes the records' existing claims only, and retires the completed padded-default transition's lifecycle entries. It adds no requirement and fixes no implementation; every per-step gap is recorded, not fixed here. It does not choose between DEC-1 and #7648's deprecation of the switcher. It does not clear the
spec:AST-027non-modal gap.Evidence and implementation relationship
Each existing claim, checked against source on main (
BottomSheetSwitcher.tsx,BottomSheet.tsx, their tests):aria-hidden), FR3 (entering above retained; alignment; fade after transform), FR4 (retained through exit; focus to the captured opener), FR6 (purposegates Escape, scrim click, swipe;alertdialog), FR7 (oneuseLayerDismissalregistration;LayerDepthProvideraround step content), ORD1, ORD2 (consumeraria-label, thenaria-labelledby, then the active child's label), PR2, AR1–AR3: hold on main.useScrollLock(isModal)once per flow;isModalstays true through a handoff and the exit). ModalshowModal()and non-modalshow(): hold. Native-containment and flow-wrapper clauses: gaps (the JS focus trap; the shared dialog carrieszIndex: 1000itself).id/data-testid, movingref), Dialog-surface concept, Owns bullet, PR1, the First open/Handoff states, the "Shared dialog" design row: gaps — one shared dialog.bottom-sheettarget only), FR3 (useScrollableArea,keyboardAccess.owner="contentOrViewport"), FR4 (Content area inset--spacing-4by default, published as a container publisher), AR1–AR2: hold on main. The switcher-managed dialog in the Owns bullet and the state row: gap.paddingprop and no theme padding, the content box now pads by--spacing-4…" (feat(core)!: BottomSheet pads its content by default, like Dialog #6884) names thepadding={0}migration and thepreserve-bottom-sheet-content-paddingcodemodastryx upgraderuns;BottomSheetPanel.tsxresolves the prop, then the theme'sbottom-sheetpadding, then--spacing-4. DEP-0009 (proposed) and CLN-0018 (pending) described that transition before it landed.What #7720 deletes when it lands (it merges after this PR, stacked on it): the switcher record's Owns-bullet gap, Dialog-surface gap, FR2, FR5, FR8, FR9 and PR1 gap sentences, the Modal-state gap, the representative-states lead-in, the "Shared dialog" row's gap (together with the anatomy rename it already carries), and the BottomSheet record's Owns-bullet and state-row gaps — exactly those sentences, and nothing else in either record. #7757 deletes the verification-map "(implementation gap: not yet in the tree)" note when it adds the engine spec. The
spec:AST-027non-modal gap remains.Writing rubric results
verified_byand the verification maps name test layers.issue #5207(FR3 basis) is removed (searched#+ digits,/pull/,/issues/).Scope
showModal()) is named, because the family and layer contracts depend on it.Validation
pnpm check:knowledge: alignedgit diff --check: clean