Repository navigation
spec(SegmentedControl): React Native platform record - #12831
imdreamrunner wants to merge 4 commits into
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
AI review status for this pull request.
|
There was a problem hiding this comment.
Approval waits on a spec decision: this record adds draft requirements that no current record states yet, so an engineering owner records the decision by commenting /approve-spec <full head SHA> on this pull request, and the author may do so as an engineering owner. The owners need to settle FR2's choice of control, which relies on spec:AST-112 FR21 and spec:AST-126 (neither is on main yet), and the wrapping in FR6 and DEC-1, which departs from the truncation in component:SegmentedControl FR5 and component:SegmentedControlItem FR3.
One fix is needed whatever the owners decide:
- On Android the record draws Astryx's control without naming the platform control it looked for (Material 3's segmented button) or why it does not fit, as
spec:AST-093FR2 requires, so name that control and the reason, or list Android's drawn control as a departure fromspec:AST-082FR11 under Current-state impact (lines 190-191).
Two smaller points are in the inline comments.
Claims and files checked
Review mode: full; reason: no-earlier-review
- Claim: stacked on the change that accepts React Native platform records, and merges after it. Verified: the base branch holds that change, which is still an open draft.
- Claim: the record cites the controls, icons and foundation-amendment drafts, and the amendment defines
renderand the theme default. Verified: the amendment adds FR21; all three are open drafts and absent frommain. - Claim: no React Native SegmentedControl record exists, and no other open pull request carries one. Verified: none exists on
mainor the base, and a search of open pull requests found none. - Claim: the pull request holds specification records only and no implementation. Verified: one Markdown file.
- Claim: the record was read against the React Native package's SegmentedControl, its generated contracts and the platform host. Not verifiable here: no such package or component is in this repository.
- Claim: the decision bullets for FR1 to FR8, AR1 to AR4 and the gap lines. Verified against the record, except that the FR2 bullet leaves out the hidden-label-without-symbol shape.
- Claim: FR6 departs from core FR5's truncation, for the reason DEC-1 gives. Verified; it also departs from SegmentedControlItem FR3.
- Claim: writing rubric R1 to R7 show no issues. Verified; "not yet released" appears only in the template's readiness cell and lifecycle line.
- Claim: the knowledge check reports no finding in this record, Prettier is clean, and the whitespace check is clean. Verified at this head.
- Claim: public text has no internal context. Verified.
- File:
docs/specs/components/SegmentedControl/SegmentedControl.react-native.spec.md: one blocking finding (the Android platform control, lines 190-191) and two non-blocking notes (line 31, and basis cells that cite records not yet onmain).
There was a problem hiding this comment.
Approval waits on a spec decision: this record adds draft requirements that no current record states yet, so an engineering owner records the decision by commenting /approve-spec <full head SHA> on this pull request, and the author may do so as an engineering owner. The owners need to settle three things:
- FR2's choice of control relies on
spec:AST-112FR21 andspec:AST-126, neither of which is onmainyet. - On Android, FR2 draws Astryx's control where Material 3's segmented button exists, which the record now lists as a departure from
spec:AST-082FR11 with OQ1 open; if that departure stands,spec:AST-082FR11 is the claim to update for it. - FR6 and DEC-1 wrap labels where
component:SegmentedControlFR5 andcomponent:SegmentedControlItemFR3 truncate them.
No blocking defect remains: the earlier Android point is fixed, since the record now names Material 3's segmented button and records the departure. Two small citation points are in the inline comments.
Claims and files checked
Review mode: full; reason: spec-record
- Claim: stacked on the change that accepts React Native platform records, and merges after it. Verified: the base branch holds that change, which is still an open draft.
- Claim: merges after the controls, icons and foundation-amendment drafts it cites, and the amendment defines
renderand the theme default. Verified: the amendment adds FR21; all three are open drafts and absent frommain. - Claim: core FR5 truncates a narrow segment's label, core FR9 to FR14 state the selection motion, and Tooltip FR5 opens a disabled control's reason on a tap. Verified.
- Claim: the controls draft owns the system control's native contract, the rule for when SegmentedControl uses it including the shapes that stay drawn, and DEC-2. Partly: its FR2 lists four of the seven shapes this record's FR2 lists (inline comment).
- Claim: the amendment's FR21 records the package's
presentationspelling as a gap. Verified; this record's first FR2 gap line describes that gap differently (inline comment). - Claim: no React Native SegmentedControl record exists, and no other open pull request carries one. Verified: none on
mainor the base, and a search of open pull requests found none. - Claim: the decision bullets for FR1 to FR8 and AR1 to AR4. Verified against the record, except that the FR2 bullet leaves out the hidden-label-without-symbol shape.
- Claim: Android's platform control is Material 3's segmented button, which the package has no host for; the drawn control is an FR11 gap line; OQ1, held by the controls draft's OQ2, asks whether Android gets that host. Verified.
- Claim: FR6 departs from core FR5's truncation, for the reason DEC-1 gives. Verified; it also departs from SegmentedControlItem FR3.
- Claim: no rejected alternatives are recorded. Verified.
- Claim: the pull request holds specification records only and no implementation. Verified: one Markdown file.
- Claim: the record was read against the React Native package's SegmentedControl, its generated contracts and the platform host. Not verifiable here: no such package is in this repository.
- Claim: writing rubric R1 to R7 show no issues, and OQ1 lists no options. Verified.
- Claim: the knowledge check reports no finding in this record, Prettier is clean, and the whitespace check is clean. Verified at this head.
- Claim: public text has no internal context. Verified.
- File:
docs/specs/components/SegmentedControl/SegmentedControl.react-native.spec.md: no blocking finding; two non-blocking citation notes (lines 63-66 and 116) and one carried note (basis cells cite records not yet onmain).
There was a problem hiding this comment.
Approval waits on a spec decision, and one fix is needed either way. This record adds draft requirements that no current record states yet, so an engineering owner records the decision by commenting /approve-spec <full head SHA> on this pull request; the author may do so as an engineering owner. The owners need to settle three things: FR2's iOS render, which relies on spec:AST-112 FR21 and spec:AST-126, neither yet on main; Android's drawn control in place of Material 3's segmented button, a recorded departure from spec:AST-082 FR11 (OQ1); and FR6's wrapping, where core truncates labels.
Blocking:
- FR2 removes
renderfrom the Android contract because "a prop no value of which Android honors is not offered", but its owndrawnandautobehave as defined on Android, so it does not meetspec:AST-082FR3's rule that a prop is limited to one platform only when no honest behavior exists on the others; keeprenderon Android asspec:AST-126FR2 does (systemdraws Astryx's control and warns once), or record an iOS-onlyrenderas a departure fromspec:AST-082FR3 under Current-state impact and amendspec:AST-126FR2 to match.
The earlier points on naming Android's platform control, the glance row's shape list and the first FR2 gap line are fixed; a new inline note covers the glance row's screen-reader wording, and the earlier inline note on the shape list that spec:AST-126 FR2 gives still applies.
Claims and files checked
Review mode: full; reason: spec-record
- Claim: stacked on the change that accepts React Native platform records, and merges after it. Verified: the base branch is that change, which is still an open draft.
- Claim: also merges after the controls, icons and foundation-amendment drafts, whose FR21 defines
renderand the theme default. Verified: all three are open drafts and absent frommain; FR21 exists only in the amendment. - Claim: core FR5 truncates a narrow segment's label, core FR9 to FR14 state the selection motion, and Tooltip FR5 opens a disabled control's reason on a tap. Verified.
- Claim: the controls draft owns the system control's contract, the rule for when SegmentedControl uses it including the shapes that stay drawn, and DEC-2. Partly false: its FR2 gives SegmentedControl
renderon both platforms and lists four of this record's seven shapes. - Claim: the amendment's FR21 defines
renderand records the package'spresentationspelling as a gap. Verified. - Claim: the cited core-and-platform, icon, base-prop, native-first and theme-only rules of the native-first system spec. Verified.
- Claim: no React Native SegmentedControl record exists, and no other open pull request carries one. Verified: none on
mainor the base, and a search of open pull requests found none. - Claim: the iOS contract adds
render, and Android, with no host for Material 3's segmented button, has none. Describes the record accurately; the stated reason conflicts with the native-first spec's FR3 (blocking finding above). - Claim: the decision bullets for FR1 and FR3 to FR8 and AR1 to AR4. Verified against the record; "each segment a radio" holds for Astryx's control only.
- Claim: Android's drawn control is an FR11 gap line, and OQ1 asks whether Android gets a host. Verified.
- Claim: FR6 departs from core FR5's truncation for the reason DEC-1 gives. Verified; it also departs from SegmentedControlItem FR3.
- Claim: the gap lines state where the package differs. Verified as written; the package is not in this repository, so its behavior could not be checked.
- Claim: no rejected alternatives are recorded, and the pull request holds a specification only, with no implementation. Verified: one Markdown file.
- Claim: the record was read against the React Native package and its generated contracts. Not verifiable here: no such package is in this repository.
- Claim: writing rubric R1 to R7 show no issues. Verified; "not yet released" appears only in the template's compatibility field and readiness cell.
- Claim: public text has no internal context. Verified.
- Claim: the knowledge check, Prettier and the whitespace check pass. Verified at this head.
- File:
docs/specs/components/SegmentedControl/SegmentedControl.react-native.spec.md: one blocking finding (FR2's Androidrender, line 115) and two non-blocking notes (the glance row on line 32, and FR2's shape list against the controls draft).
There was a problem hiding this comment.
Approval waits on an owner decision on this record's draft requirements, which no current record states yet; nothing else needs fixing. An engineering owner records that decision by commenting /approve-spec <full head SHA> on this pull request, and the author may do so as an engineering owner. The owners need to settle:
- FR2's iOS
render, the theme'srender.defaultand the seven shapes that force Astryx's control, which rely onspec:AST-112FR21 andspec:AST-126; neither is onmainyet. - Three departures from current records, each now stated in the record: the iOS-only
renderagainstspec:AST-082FR3 (DEC-2), Android's drawn control againstspec:AST-082FR11 (OQ1), and FR6's wrapping against core's truncation; each either stands as a recorded gap or the current record is amended first.
The earlier blocking point on Android's render and the glance row's screen-reader wording are fixed; the earlier inline note on aligning FR2 with spec:AST-126 FR2's platforms and shapes still applies.
Claims and files checked
Review mode: full; reason: spec-record
- Claim: stacked on the change that accepts React Native platform records, and merges after it. Verified: the base branch is that change, which is still an open draft.
- Claim: also merges after the controls, icons and foundation-amendment drafts, whose FR21 defines
renderand the theme default. Verified: all three are open drafts and absent frommain; FR21 exists only in the amendment. - Claim: core FR5 truncates a label in a narrow segment, core FR9 to FR14 state the selection motion, and Tooltip FR5 opens a disabled control's reason on a tap. Verified.
- Claim: the controls draft owns the system control's contract, the rule for when SegmentedControl uses it including the shapes that stay drawn, and DEC-2. Verified as a statement about that draft; this record lists three shapes that the draft's FR2 does not (non-blocking note).
- Claim: the amendment's FR21 defines
renderand records the package'spresentationspelling as a gap. Verified. - Claim: the native-first spec's FR3, FR4, FR7, FR11, FR17 and DEC-2 are the core and platform, icon, base-prop, native-first and theme-only rules. Verified.
- Claim: no React Native SegmentedControl record exists, and no other open pull request carries one. Verified: there is none on
mainor the base, and a search of open pull requests found none. - Claim: the iOS contract adds
render, Android has none, and the record lists the departure from the native-first spec's FR3 and the controls draft's FR2 under Current-state impact. Verified (lines 77–80 and DEC-2). - Claim: on iOS, Astryx's control draws for a disabled reason, an icon with a label, large text, a word break, too little room and wrapped items. Verified; FR2 also lists a hidden label whose icon has no SF Symbol.
- Claim: the system control uses UIKit's motion and feedback with no library haptic, and Astryx's control draws the theme's track, with a capsule when
render.defaultissystem. Verified (FR3, FR4). - Claim: Astryx's control never cuts a label, which departs from core FR5's truncation for the reason DEC-1 gives. Verified; it also departs from SegmentedControlItem FR3.
- Claim: selection, the keyboard and the disabled state follow core, and a disabled reason is each segment's hint and opens on a tap. Verified (FR5, FR7, FR8).
- Claim: accessibility is a radio group named by a hidden label read first, with no announcement on a change. Verified for Astryx's control (AR1–AR4); the system control gives its segments the system's selected state.
- Claim: Android's platform control is Material 3's segmented button, its drawn control is an FR11 gap line, and OQ1 asks whether Android gets a host. Verified.
- Claim: the gap lines state where the package differs. Verified as written; the package is not in this repository, so its behavior could not be checked.
- Claim: no rejected alternatives are recorded, and the pull request holds a specification only, with no implementation. Verified: one Markdown file.
- Claim: the record was read against the React Native package and its generated contracts. Not verifiable here: no such package is in this repository.
- Claim: writing rubric R1 to R7 show no issues. Verified; "not yet released" appears only in the template's compatibility field and readiness cell.
- Claim: the public text has no internal context. Verified.
- Claim: the knowledge check, Prettier and the whitespace check pass. Verified at this head.
- File:
docs/specs/components/SegmentedControl/SegmentedControl.react-native.spec.md: no blocking finding; one carried non-blocking note (FR2 against the controls draft'srenderplatforms and shape list).
Stacked on #12592; merges after it.
Merge order: this record also cites
spec:AST-126(#12556, the system segmented control and when a host exists),spec:AST-127(#12555, icons) and the AST-112 amendment (#12563), whose FR21 definesrenderand the theme'srender.default. It merges after those too.Exact decision needed
How React Native presents SegmentedControl: which control draws the segments (UISegmentedControl or Astryx's control) and for which shapes, what Astryx's control draws, how labels behave at every text size, and how selection, the keyboard, the disabled state and accessibility work on iOS and Android.
Existing authority searched
component:SegmentedControlandcomponent:SegmentedControlItem(docs/specs/components/SegmentedControl/): the props, states and words this record keeps; core FR5 truncates a label in a narrow segment, and core FR9–FR14 state the selection motion.component:TooltipFR5: a disabled control's reason opens on a tap under touch.spec:AST-126(open draft): owns UISegmentedControl's native contract (FR6), FR2's rule for when SegmentedControl uses it, including the shapes that stay drawn, and DEC-2 (a shape the system control cannot show draws the Astryx control).spec:AST-112amendment (open draft): FR21 definesrenderand records the package'spresentationspelling as a gap.spec:AST-082FR3, FR4, FR7, FR11, FR17 and DEC-2: the core and platform contracts, icon slots, base props, native-first and theme-only visuals.Decision
docs/specs/components/SegmentedControl/SegmentedControl.react-native.spec.md(component:react-native/SegmentedControl,platform_of: component:SegmentedControl):SegmentedControlandSegmentedControlItemwith core's props and meanings; an item'siconis a shared icon name;xstylestays in the web contract, and neither takes aref(FR1).render:autois UISegmentedControl wherever its host exists; Android has no host for Material 3's segmented button, so its contract has norenderand the control is always Astryx's there (DEC-2: a prop a platform does not honor is not offered there). This departs fromspec:AST-082FR3 and fromspec:AST-126FR2, which offersrenderon both platforms; the record lists the departure under Current-state impact. On iOS, Astryx's control draws for a disabled reason, a segment with both an icon and a label, large text, a word break, a control wider than its room, and items in an app's wrapper component (FR2, markedhuman decisionsince its bases are open drafts).render.defaultissystem(FR4).spec:AST-082FR11 gap line, and OQ1 (held byspec:AST-126OQ2) asks whether Android gets that host.FRn gaplines state where the package differs: norenderprop, an icon the system control drops, no slide, drag or lift, one Tab stop per segment, and a long press for the disabled reason.Rejected alternatives
None recorded in the record.
Claim scope and non-goals
The record covers only what React Native adds to
component:SegmentedControlandcomponent:SegmentedControlItemor does differently. The system control's native contract,renderand icons stay with their owners, which the ownership lines name.Evidence and implementation relationship
The record is a specification only and has no implementation in this pull request. It was read against the React Native package's SegmentedControl and SegmentedControlItem, their generated contracts, and the platform segmented control's host. The gap lines state where the package differs from the requirements.
Writing rubric results
Rejected:lines.FRn gaplines; "not yet released" appears only in the template's lifecycle field and readiness cell.Scope
Components: SegmentedControl, SegmentedControlItem (React Native)
Validation
node scripts/check-knowledge.mjs: knowledge templates and records are aligned; no finding in this record.--checkclean on the record.git diff --check: clean.