Skip to content

Pairing screen: first-use UX, wave 4 — fallback and conflict dialog - #66

Merged
gdoumen merged 7 commits into
mainfrom
feat/pairing-screen-first-use-ux-wave4
Nov 10, 2026
Merged

gdoumen merged 7 commits into
mainfrom
feat/pairing-screen-first-use-ux-wave4

Conversation

@gdoumen

@gdoumen gdoumen commented Nov 10, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Renders the Pairing screen's new fallback and device-selection-conflict display props from services
  • A new ConflictStepDialog handles both a manual Resistance-list pick's conflict and a conflict raised by a device the search finds mid-ride, in the same modal dialog
  • Consumes services' {full, short} queued-count copy for the dialog's footer badge

Test plan

  • npm test — 76/76 suites, 747/747 tests passing

A tile marked dimmed by the page service keeps its device name and role line but uses the muted look of a switched-off tile, shows no value and no toggle, and shows the service's footer copy as written. A click on the tile still calls its own onClick, which the service binds to taking the trainer back into use.
Adds the conflict rows (keep or replace per slot, keep picked until the rider chooses otherwise), a non-modal conflict card for devices found by the search, and a second step in the device list after a Resistance pick that would take slots held by another device. In that step Done applies the choices, and Esc or a click outside applies the choices made so far instead of discarding the pick.

The device list no longer offers the "for all capabilities" checkbox: a pick always calls the item's onClick() without an argument, and the page service decides which slots the device fills.
The screen passes each tile's dimmed flag through and shows the page service's pending conflict as a card in the panel beside the tiles, in place of the helper and exactly whenever it is handed over. The rows give up their label column for the card as they do for the helper, and the card never blocks the buttons.

Tests cover the dimmed tiles, that switching Resistance off always calls the tile's own onUnselect, the helper's pinned action with its note, and that no button on the screen or in the device list's second step offers to try again.
…nflict

A device found by the search that wants slots already held by another device is no longer shown as a card in the panel beside the tiles. It now opens in the same modal dialog the device list already uses for the second step of a pick in the Resistance list, so both ways of reaching the question look and behave the same. The panel beside the tiles goes back to holding only the helper.

The dialog shell (title, queued count, subline, rows, pinned Done) moves into a shared ConflictStepDialog that both paths render. It has no close button: Esc or a click outside calls the conflict's onDismiss(), and because the dialog covers the whole page, OK can't be reached while it is open.

Since a found device's dialog can appear without the rider asking for it, its Keep/Use/Done buttons ignore clicks for 500ms after it appears (and again when the next queued conflict takes its place), so a click aimed at whatever was on screen before doesn't answer it. Esc and a click outside are never held back. The device list's own step opens in direct answer to a click and keeps answering right away.

The conflict card component, its tests and stories are removed; its story/test data moves next to the dialog.
The conflict dialog's queued-count badge still assumed queuedText was
a plain string; services now sends {full, short} so the wording can
differ by context.
@gdoumen
gdoumen marked this pull request as ready for review November 10, 2026 21:07
@gdoumen
gdoumen merged commit b401f5a into main Nov 10, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant