Skip to content
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
10d85dd
spec(AST-094, AST-057): gestures work on the web for every pointer (F…
cixzhang Oct 27, 2026
c037c2f
spec(AST-094): the fine-pointer press paints through the press contro…
cixzhang Oct 27, 2026
ff18a21
Merge remote-tracking branch 'origin/main' into spec/gestures-on-web
cixzhang Oct 27, 2026
0329096
spec: gestures on web — useMenuPress, user-states, buttons follow eve…
cixzhang Oct 27, 2026
91bc491
spec(AST-057, AST-094): a trackpad's horizontal scroll swipes a row; …
cixzhang Oct 27, 2026
874ee55
Merge main (AST-094 FR19 scroll-edge exception) into spec/gestures-on…
cixzhang Oct 27, 2026
848021a
Merge main into spec/gestures-on-web
cixzhang Oct 27, 2026
1bb6eb7
Merge main into spec/gestures-on-web
cixzhang Oct 27, 2026
06fa181
Merge remote-tracking branch 'origin/main' into spec/gestures-on-web
cixzhang Oct 27, 2026
a3f189c
Merge main into spec/gestures-on-web
cixzhang Oct 27, 2026
c46ace4
spec(AST-057): DEC-4 names horizontal wheel input
cixzhang Oct 27, 2026
c7c4091
Merge main into spec/gestures-on-web
cixzhang Oct 27, 2026
8e6c9ef
Merge main into spec/gestures-on-web
cixzhang Oct 27, 2026
459c961
Merge main into spec/gestures-on-web
cixzhang Oct 27, 2026
7270894
Merge remote-tracking branch 'origin/main' into spec/gestures-on-web
cixzhang Oct 27, 2026
d5aee72
Merge main into spec/gestures-on-web
cixzhang Oct 27, 2026
7a823e3
Merge remote-tracking branch 'origin/main' into spec/gestures-on-web
cixzhang Oct 27, 2026
da36283
Merge main into spec/gestures-on-web
cixzhang Oct 27, 2026
4fb6ea2
spec(AST-057): intent names the pen
cixzhang Oct 27, 2026
4084b67
Merge main into spec/gestures-on-web
cixzhang Oct 27, 2026
4e3f644
Merge remote-tracking branch 'origin/main' into spec/gestures-on-web
cixzhang Oct 27, 2026
18da5ed
Merge main into spec/gestures-on-web
cixzhang Oct 27, 2026
b61be38
Merge main into spec/gestures-on-web
cixzhang Oct 27, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions docs/architecture/react-component-runtime.md
Original file line number Diff line number Diff line change
Expand Up @@ -183,9 +183,10 @@ those contracts.
keeps one copy per page however many components use them. There is no
install call, no public entry, and no public installed check; tests reset
the modules through an internal hook only. A component's own touch logic is
small glue in its own build over these modules. Where the primary pointer
is fine, no recognizer attaches and no touch listener is registered
(`spec:AST-094` FR19, FR24). The modules are not public exports and are not
small glue in its own build over these modules. The gesture host attaches for
every pointer, with no touch-only query, and pointer and hover queries live
with the environment queries; under a fine pointer only a component that

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.

The INV13 verification row (line 342) still fails "a touch listener under a fine primary pointer"; it needs the new budget this paragraph states.

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.

“the environment queries” is not defined in any record or in packages/core/src. Name the module or record that owns pointer and hover queries, or drop the clause.

uses a gesture listens (`spec:AST-094` FR19, FR24, FR43). The modules are not public exports and are not
documented for consumers; Core and Lab components reach them through
`@astryxdesign/core/internal/touch`, a subpath reserved for Astryx's own
packages: undocumented, outside the compatibility promise, versioned in
Expand Down
8 changes: 5 additions & 3 deletions docs/specs/AST-057-row-actions/spec.md
Original file line number Diff line number Diff line change
Expand Up @@ -247,9 +247,11 @@ constants.
activate it; while closed the panel MUST be out of the accessibility tree
and the tab order. Under `commit` the panel MUST be presentational
(`aria-hidden`) at all times, because nothing in it is ever tappable.
- **AR2 — The gesture touches nothing on a pointer that can hover.**
`swipeActions` MUST have no effect on the tab order, the accessible tree,
or the row's paint on such a pointer. Hover MUST NOT uncover the panel.
- **AR2 — A mouse never swipes a row.** On a pointer that can hover,
`swipeActions` MUST have no effect on the tab order or the accessible tree,
a mouse drag MUST NOT reveal the panel, and hover MUST NOT uncover it. A
trackpad's horizontal scroll swipe MAY reveal the panel, as a pan that takes

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.

This MAY contradicts the rest of the record, which is unchanged: DEC-4 ("On a pointer that can hover, swipeActions does nothing"), the non-goal "two-finger trackpad swipes", the intent ("touch-only … changes nothing on any other input"), the platform line and the AR1–AR3 verification row ("any effect on a fine pointer fails"). AR1 also makes a resting-open panel's entries focusable buttons while this line keeps the gesture out of the tab order on a hovering pointer.

trackpad scrolling (`spec:AST-094` FR43).
- **AR3 — The row's primary stays one tab stop.** `swipeActions` MUST NOT
change the primary element's role, name, or activation, and MUST add no
stop while closed.
Expand Down
63 changes: 46 additions & 17 deletions docs/specs/AST-094-touch-presentations/spec.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,9 @@ a measured, sourced difference exists.

## Non-goals

- Pointer (desktop) presentations. Their timing and easing stay with the
theme's duration and easing tokens (`architecture:theme-tokens`).
- Pointer (desktop) presentations' timing and easing, which stay with the
theme's duration and easing tokens (`architecture:theme-tokens`). Gestures
and press tracking themselves apply to every pointer (FR43).
- Platform-matched look and feel: glass versus material surfaces, glyphs and
chrome. This record governs behavior only.
- WebKit embedded in a native app and the native Swift package. This record
Expand Down Expand Up @@ -186,6 +187,10 @@ a measured, sourced difference exists.
views and activates by the browser's click on a lift inside. On the web a
control's press ends when the browser takes the touch (FR20), and its
activation stays the browser's click.
Under a fine pointer a control uses a third profile with no delay: its

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.

This adds a third profile, but FR11 is still titled "Two press profiles" and says "Press feedback MUST follow one of two native profiles" (line 185). The records that own the press look, the user-states design (DR1, DR3) and the buttons family's visual-state row, still hand FR11 their timing only under a finger, so they need the fine-pointer profile too.

press paint starts at once on `pointerdown`, through the same press
controller and release fade as a finger's, in place of CSS `:active`; the
scroll brake stays touch-only (DEC-21).
A cell (a table or collection cell) highlights 150 ms after touch-down inside
a scroll view, drops the highlight when the scroll wins (FR20), and activates on a
lift inside it with no scroll taking the touch (FR20). A control is inside a scroll view when it sits in a scrollable container,
Expand Down Expand Up @@ -257,11 +262,8 @@ a measured, sourced difference exists.
decides at 15 px of travel (UIKit's screen-edge hysteresis); outside the
band the author's scrolling is untouched, and FR19's 10 px governs every
other claim (DEC-13).
- **FR19 — Claims are made in time and only by an owner.** Recognizers attach only where the primary pointer
is coarse (FR13, DEC-6). Where the primary pointer is fine, no recognizer
attaches and no touch listener is registered (FR24), so a finger on a
touchscreen whose primary pointer is fine gets the browser's defaults for
this record's behaviors (`spec:AST-017` FR59, DEC-25). This rule governs
- **FR19 — Claims are made in time and only by an owner.** Recognizers attach for every pointer, with FR43's
exceptions. This rule governs
this record's behaviors only; `spec:AST-057` keeps its per-event pointer
read for the row swipe, as its record states. A recognizer that begins MUST claim its touches by cancelling
`touchmove` through a non-passive listener on its element; a watcher,
Expand Down Expand Up @@ -307,13 +309,11 @@ a measured, sourced difference exists.

FR26–FR28 and FR30 apply to every surface that carries the press model of
`module:DropdownMenu/useMenuPress` (DropdownMenu, ContextMenu, their sub-menus,
and Selector's listbox, whose options count as rows) when a finger or pen
drives it and the primary pointer is coarse (FR19); where the primary pointer
is fine, a finger in a menu keeps today's behavior (`spec:AST-017` FR59,
DEC-25), and menus make no per-gesture pointer read; FR29 applies to DropdownMenu's trigger under the same
and Selector's listbox, whose options count as rows) under every pointer
(FR43); FR29 applies to DropdownMenu's trigger under the same
Comment on lines +323 to +324

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.

With FR26–FR30 under every pointer, packages/core/src/DropdownMenu/modules/useMenuPress.spec.md now contradicts this: its FR1, FR2, FR7 and FR9 keep a fine-pointer finger on the module's rules "(spec:AST-094 FR19)", and its delay row says "500 ms where it is fine", while FR29 opens on press. Dropping "A mouse keeps today's behavior" also leaves open whether a mouse follows FR28 and FR29 or keeps the module's FR3 and DEC-3 (a mouse release outside closes the menu).

condition; FR34 applies to menus;
FR31 and FR35 apply to anchored menus and to Popover under a finger; FR32 and
FR33 apply to menus only. A mouse keeps today's behavior.
FR33 apply to menus only.

- **FR26 — The lift decides.** A menu row MUST act when the finger lifts over
it, never because the press began on it; a press that never left its row is
Expand Down Expand Up @@ -442,11 +442,11 @@ FR33 apply to menus only. A mouse keeps today's behavior.

### Resources and compatibility

- **FR24 — Touch work costs nothing where it is not used.** Where the
primary pointer is fine (FR19), and while a touch presentation is
disabled, no touch-only listener, observer or timer is active, except the
released `module:DropdownMenu/useMenuPress` behavior a finger keeps there
(its FR9). The number of `document`- or `window`-level
- **FR24 — Gesture work costs nothing where it is not used.** A component
that uses no gesture registers no gesture listener, observer or timer, and
while a touch presentation is disabled none is active. Under a fine pointer
a component that uses a gesture keeps one listener on its element and adds

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.

The FR24 verification row (line 559) still fails "a touch listener on a fine pointer", but FR43 gives a finger gestures under every primary pointer and FR19 claims a finger through a non-passive touchmove listener on the element, so a conforming touchscreen-laptop implementation fails that row. Please also say whether the shared document-level press controller, which components install on mount, counts as gesture work under this budget.

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.

On a touchscreen laptop (a fine primary pointer) FR43 gives a finger gestures, and FR19 makes a claiming recognizer cancel touchmove through a non-passive listener on its element, noting that one "added at touchstart, would hand diagonal drags to the scroll" (lines 297–298). A pan that competes with scrolling then needs that touch listener before the press, beside the pointer listener a mouse needs: two element listeners against this budget, or a press-time touch listener that loses FR19's diagonal claim. Please count FR19's touch listener outside the one-listener budget, or say which path a finger under a fine primary pointer takes.

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.

"keeps one listener on its element" cannot hold for a pan FR43 also drives by the wheel: a drag needs pointerdown and a wheel pan needs wheel on the element at rest, and the context request adds contextmenu, while this rule keeps idle document listeners out. "Listens only on its own element" says what the FR24 and INV13 rows test.

document listeners only during a press, removing them at the release (FR43). The number of `document`- or `window`-level
touch listeners MUST NOT grow with the number of component instances, a
repeated row or cell adds no touch observer of its own, and nothing
touch-related remains after the last instance unmounts
Expand All @@ -464,6 +464,19 @@ FR33 apply to menus only. A mouse keeps today's behavior.
This replaces `component:Selector` DEC-1's width-and-pointer query with the
FR13 rule for `adaptive`.

- **FR43 — Gestures work on the web.** Gestures attach for every pointer, a
mouse, a pen, and a finger, not only a coarse primary pointer. These stay
off: swipe actions under a mouse, which would take the browser's text
selection and native drag (`spec:AST-057` AR2); a pinch under a pen; the
screen-edge pan on every web input; and the 44 px touch target, which stays

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.

"the screen-edge pan on every web input" reads as covering a finger in a browser too, which would switch off FR18's screen-edge pan; "under a mouse, a trackpad or a pen" says what DEC-21 means. "the 44 px touch target" is also not defined by any current record yet.

coarse-only and never overlaps a neighbor's target. On the web, a pan also
takes wheel and trackpad scrolling; a pinch takes a ctrl-wheel; one shared
context request answers a long press, a right click, and Shift+F10; the

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.

This long press answers the context request under every pointer, a mouse included, but FR41 (lines 448–449), which this change leaves as it is, still says “a mouse keeps its released behavior”, and its verification row fails a change to mouse selection. Today's ContextMenu long press listens to touch only. Say whether a mouse long press makes the request (for example “a long press under a finger or a pen”) and amend FR41 and its row to match.

press model has a fine-pointer profile with no delay (FR11); and a reorder
starts on a drag from its handle without a hold. Under a fine pointer only a

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.

This names no pointer, so with "Gestures attach for every pointer" it covers a finger too, which contradicts spec:AST-103 FR3 ("under a finger, a hold on the handle picks the row up … and a flick still scrolls"), not amended here. Scope it to a mouse, a trackpad or a pen, or amend AST-103 FR3.

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.

This names no pointer, and FR43 opens with "Gestures attach for every pointer, a mouse, a pen, and a finger", so it also covers a finger on a phone. spec:AST-103 FR3 (not amended here) says "under a finger, a hold on the handle picks the row up at spec:AST-094's values, and a flick still scrolls". Suggest scoping it: "… and under a mouse, a trackpad or a pen a reorder starts on a drag from its handle without a hold", or amend AST-103 FR3 in this pull request.

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.

This clause names no pointer, and FR43 opens with "Gestures attach for every pointer, a mouse, a pen, and a finger", so it also covers a finger on a phone. spec:AST-103 FR3 (current, not amended here) says "under a finger, a hold on the handle picks the row up at spec:AST-094's values, and a flick still scrolls". Suggest: "… and under a mouse, a trackpad or a pen a reorder starts on a drag from its handle without a hold", or amend AST-103 FR3 in this pull request.

component that uses a gesture listens (FR24), and the change adds no
stylesheet bytes (`spec:AST-080` FR8) (DEC-21).

### Platform support

- Supported engines: Astryx's supported browsers (`spec:AST-013`) with touch

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.

With FR43 bringing gestures to desktop mouse, trackpad and pen browsers, this still names only browsers "with touch input, on iOS and Android", and the browser evidence below names phone emulation and devices only. Suggest adding the desktop engines and the desktop evidence FR43's verification row asks for.

Expand Down Expand Up @@ -551,6 +564,7 @@ FR33 apply to menus only. A mouse keeps today's behavior.
| FR34, FR35 | Browser tests and storyboards under a finger | a sub-menu drilling in and its Back row returning; a tap and a drag during a popover's and a menu's growth; a pinch during growth; a mouse | a drill-in that leaves the parent's rows in place, a change between levels that does not play on its roles, a tap during growth that closes, scrolls or moves focus, a pinch blocked other than by the author's `touch-action`, or a changed mouse path fails |
| FR36–FR40 | Release tests on synthetic touch streams with explicit timestamps, per use | below and past each commit point; a flick that projects past it; a slow drag past it; a release moving back; Reduce Motion; keyboard and mouse paths | a decision that changes mid-settle, a release moving back that commits, a settle that does not start at the release velocity, or an action with no keyboard or mouse path fails |
| FR41 | Browser tests with real touch input (`spec:AST-013` FR10) | a tap; a long press on a ContextMenu trigger, a DropdownMenu trigger the caller renders, a row with a context menu, and a slider thumb; a long press on a checkbox row's label and on plain text; a cancelled press; mouse and keyboard selection | a tap that selects, a hold with an action that starts a selection or callout, a label or plain text whose long press does not select natively, a suppression that outlives the press, or a change to native selection elsewhere or to mouse, keyboard, or assistive-technology selection fails |
| FR43 | Browser tests with a mouse, a trackpad, a pen, a finger, and the keyboard, and resource counts | a pan by drag and by wheel; a ctrl-wheel pinch; a long press, a right click, and Shift+F10; a mouse press; a handle drag; a row swipe with a mouse and a trackpad; a component with no gesture | a gesture missing under a mouse or pen, a mouse swipe action, a pen pinch, a web edge pan, a press delay under a fine pointer, an idle listener in a component with no gesture, or added stylesheet bytes, fails |

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.

This row's inputs include a finger, so "a web edge pan … fails" reads as failing FR18's finger edge pan. FR43 now says "under a mouse, a trackpad, or a pen"; say the same here.

| all | iOS simulator: the UIKit reference capture and the same gesture in Safari; real iOS Safari and Android Chrome devices | per component | an unmatched curve or timing is a parity defect |

## Decision log
Expand Down Expand Up @@ -702,6 +716,21 @@ iOS 26.2 simulator measures it.

Rejected: the 150 ms delay on every menu row.

### DEC-21 — Gestures work on the web, not only under a finger

**Reference:** `spec:AST-094/DEC-21`
**Decider:** `cixzhang`, `2026-10-26`

Most of these gestures work as well with a mouse, a trackpad, or a pen, so
they stay on for every pointer, with web inputs mapped in: wheel and trackpad
scrolling for a pan, a ctrl-wheel for a pinch, and right click or Shift+F10
for a long press. What would fight the browser stays off: a mouse's swipe
actions, a pen's pinch, and the screen-edge pan. The 44 px target stays
touch-only. This supersedes the coarse-only press controller: a mouse press
now uses the press model with no delay instead of the browser's `:active`.

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.

"a mouse press now uses the press model ... instead of the browser's :active" narrates the change, which R1 scans for. Suggest stating the rule: "A mouse press uses the press model with no delay, in place of the browser's :active."


Rejected: keeping gestures and press tracking touch-only.

## Open questions

- **OQ1 — Scroll view bounce-back curve.** What curve brings a scroll view
Expand Down
Loading