Skip to content

docs(spec): useMenuPress states its boundary with core's group tracker - #8572

Draft
cixzhang wants to merge 2 commits into
mainfrom
record/menu-press-tracker-boundary
Draft

cixzhang wants to merge 2 commits into
mainfrom
record/menu-press-tracker-boundary

Conversation

@cixzhang

@cixzhang cixzhang commented Oct 26, 2026 •

Copy link
Copy Markdown
Contributor

Maintainer impact

Core has two trackers of a held finger moving across a group of targets: useMenuPress, which runs menus and pickers, and an internal group tracker that control groups such as SegmentedControl's segments use. Their core loop is the same job: highlight the target under the pointer, act on the target under the release, and swallow the browser's stray click. The record now says where that boundary sits, so no third copy appears. The convergence of the two is separate, later work.

Change

module:DropdownMenu/useMenuPress's ownership boundary gains one "Does not own" item: tracking a held finger across a control group's targets outside a menu or picker (a segmented control's segments, a page control's dots) is core's internal group tracker's. Its loop is the same job as this module's tracking, so no third copy is added.

There is no behavior, API or code change, and the module's Owns list is unchanged.

Writing rubric results

  • R1 narration: the first version described a pending change ("recorded 2026-10-26", "once it lands"). It's rewritten as one present-tense boundary item, and the internal file name is dropped (INV18).
  • R2 research in the record: none.
  • R3 evidence naming a change: none.
  • R4 rejected alternatives over one line or outside a decision: none added.
  • R5 pull request or issue references remaining: none.
  • R6 ruled open questions still listing options: none touched; OQ1 is unchanged.

Testing

  • pnpm check:knowledge: records aligned.
  • Prettier: clean.

…ion-group tracker

The track-across-items loop useMenuPress owns is the same job as core's
internal action-group tracker. The record now says the loop moves into the
tracker in the change after the in-flight menu press work, that useMenuPress
then keeps only its menu-only parts, and that no third copy is added
meanwhile.
@vercel

vercel Bot commented Oct 26, 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 Oct 26, 2026 8:02pm UTC

Request Review

@astracat-bot

astracat-bot Bot commented Oct 26, 2026 •

Copy link
Copy Markdown

AI review status for this pull request.

Review status Updated
❓ Needs maintainer input (for maintainers only) Nov 1, 2026, 3:42 AM UTC

@github-actions github-actions Bot added the needs:spec-owner-review Current knowledge records await owner approval label Oct 26, 2026
@github-actions

github-actions Bot commented Oct 26, 2026 •

Copy link
Copy Markdown
Contributor

PR Analysis Report

Current run: The current change has no visual or preview-producing scope. Visual checks are not applicable; preview links are not shown.

The exact-head preview is not available yet.


Generated by PR Enrichment workflow | View current CI run

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

@astracat-bot astracat-bot Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Approval waits on an engineering owner deciding whether useMenuPress's track-across-items loop should move into core's internal action-group tracker, with no third copy meanwhile: no current record establishes that direction, and an engineering owner (the author may, as one) records the decision by commenting /approve-spec <full head SHA> on the head they approve. If the direction is approved, the paragraph still needs these changes, so approving the reworked head avoids a second approval:

  • It narrates a planned change ("recorded 2026-10-26", "the change after the in-flight menu press work", "once it lands"), which architecture:knowledge-contracts INV10 keeps out of current records, so state only durable facts there and keep the plan in the pull request.
  • It names the internal hooks/actionGroupTracker.ts, which is not on main, while INV18 places internal seams in an architecture record rather than a module contract.
  • The description needs the ## Writing rubric results section that knowledge-contracts asks of every pull request that changes a record.

[Automated review]

Comment on lines +118 to +126
**Planned convergence (recorded 2026-10-26).** The track-across-items loop
above (document-level pointer tracking, the highlight under the pointer, the
row under the release acting, the stray click swallowed) is the same job as
core's internal action-group tracker (`hooks/actionGroupTracker.ts`), which
control groups such as a segmented control's segments track through once it
lands. The change after the in-flight menu press work moves that loop into the
action-group tracker; this module then keeps only its menu-only parts: opening
from a trigger press or a held finger, the settle rule, edge autoscroll, and
the highlight as DOM focus. Until then both exist, and no third copy is added.

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

This paragraph describes a pending change: it is dated, speaks of "the change after the in-flight menu press work", and relies on a tracker in use "once it lands". architecture:knowledge-contracts INV10 asks a current record to state durable facts independently of any one change, so consider keeping the plan in the pull request or an issue and rewriting the Owns list in the change that moves the loop.

**Planned convergence (recorded 2026-10-26).** The track-across-items loop
above (document-level pointer tracking, the highlight under the pointer, the
row under the release acting, the stray click swallowed) is the same job as
core's internal action-group tracker (`hooks/actionGroupTracker.ts`), which

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

hooks/actionGroupTracker.ts is not on main (only #8127 adds it), and INV18 keeps internal files and seams out of module contracts, so please drop the file name here.

…ithout an internal file name

The ownership boundary now says, as a durable fact, that tracking a held
finger across a control group's targets outside a menu or picker is core's
internal group tracker's, that its loop is the same job as this module's
tracking, and that no third copy is added (knowledge-contracts INV10, INV18).
@cixzhang cixzhang changed the title docs(spec): useMenuPress records its planned convergence with the action-group tracker docs(spec): useMenuPress states its boundary with core's group tracker Oct 26, 2026

@astracat-bot astracat-bot Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Approval waits on an engineering owner providing the governing spec for this addition, which no current spec establishes: whether useMenuPress's non-goals should assign held-finger tracking across control groups outside menus and pickers to core's internal group tracker, with no third copy of that loop, a decision an engineering owner (the author may, as one) records by commenting /approve-spec <full head SHA> on the head they approve. If the direction is approved, the bullet still needs two changes, so approving the reworked head avoids a second approval:

  • The tracker it names is not on main (only #8127 adds it, and nothing tracks page-control dots), so the current record would point readers at an owner that does not exist yet; land the bullet with or after the tracker.
  • An internal owner and a one-loop rule belong in an architecture record under architecture:knowledge-contracts INV18, as architecture:interaction-modality INV10 does for the velocity tracker, with this module keeping only the caller-visible boundary.

[Automated review]

Comment on lines +135 to +139
- Tracking a held finger across a control group's targets outside a menu or
picker, such as a segmented control's segments or a page control's dots —
owned by core's internal group tracker. Its loop is the same job as this
module's tracking (the highlight under the pointer, the target under the
release acting, the stray click swallowed), so no third copy is added.

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

This names core's internal group tracker as the owner, but no such tracker is on main or at this head: only #8127 adds one, and nothing tracks page-control dots, so a current record would point readers at an owner that does not exist yet (architecture:knowledge-contracts INV10). The no-third-copy rule is also internal ownership, which INV18 places in an architecture record, as architecture:interaction-modality INV10 does for the velocity tracker. Consider landing this with the tracker, moving the rule to that record, and keeping only the caller-visible non-goal here.

This branch was successfully deployed

1 active deployment
Preview — fe3fc47a Deployed Oct 26, 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. needs:spec-owner-review Current knowledge records await owner approval

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant