Repository navigation
Conversation
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.
Stacked on #8226. Review only this PR's change: vjeux/astryx@4707533...3161c95
User need
On a phone, tapping a SelectableCard changes its selection mark in two steps. The inset ring appears or vanishes at once, while the border fades over the theme's fast duration (125 ms), so for several frames the card that lost the selection still shows a gray outline. UIKit changes a selection mark in the frame the selection lands; under a finger the card now does too.
Evidence
A tap moving the selection from Basic to Pro, ¼ speed, recorded on this PR's earlier code: iOS 26.2 Mobile Safari (the magenta ring is the finger; before is #8226) and Android 15 Chrome (before is main). Before, Basic's border fades after Pro's ring appears; after, both cards change in one frame. The engine runs in Testing prove this head:
With a mouse under Reduce Motion, Chromium storyboards of a click moving the selection to Pro. Before (main), the borders fade; after, both cards change in one frame:
Problem and solution fit
selection.mark.changeMs(0), through the mirror that feat(core): under a finger a selection mark changes in one frame #8226 adds, so the ring and the border change together.Current specification
spec:AST-094FR1, FR13, FR24.design:reduced-motionDR2, DR3.design:reduced-motionDR2. This stays a draft until it is answered. It follows fix(core): no press scale or card color fade under reduced motion #8326's option (A): under Reduce Motion a fine pointer gets no transition. With (B), this drops its Reduce Motion arm.Public delta and caller burden
Under a finger only, the card's ring and border change in one frame. No API changes; the press overlay, colours and elevation are unchanged.
Design and alternatives
The card's touch press paint is separate press-layer work (#8057, #8118).
Scope
Testing
Local gates at 1d2f527c7f, which differs from this head (3161c95) only in the
isSelecteddoc sentence, on #8226's 4707533:pnpm build,pnpm api:report --check,pnpm typecheckandpnpm review:pre: clean.SelectableCard.doc.mjs, which main also leaves unformatted.check:repo,check:changesets,check:knowledgeandcheck:i18n-runtime: clean.SelectableCardMark.test.tsxfails on feat(core): under a finger a selection mark changes in one frame #8226's SelectableCard.