Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

10 — Interaction Specification (RBAC Module)

Module-specific interaction & motion, layered on 00-shared/08. Focus: the permission matrix (dense, high-interaction) and destructive governance flows. Tokens: Mo = 00-shared/02 §6.


1. Permission matrix interactions

Gesture / inputBehaviour
Tap chipToggle perm; selected = primaryContainer, unselected = surfaceVariant; count badge AnimatedSwitcher update Mo.m-instant; HapticFeedback.selectionClick() on mobile
Tap group checkboxToggle all perms in group; tri-state renders none/some/all
Tap group header labelCollapse/expand section (AnimatedSize, Mo.m-base, no layout pop)
Search typingDebounce 300 ms (00-shared/03 B); filters chips + collapses 0-match sections; result count announced (liveRegion)
Long-press chipTooltip with humanized name (proposed) + raw string (07 §3)
Hover (desktop)Chip lifts Mo.m-fast; cursor pointer; tooltip after 500 ms
Ctrl+F / / (desktop)Focus matrix search
TabField order: name → slug → description → priority → matrix groups (chips are focusable toggles, not tab stops — arrow keys move within a FocusTraversalGroup)
Space / Enter on focused chipToggle (native M3 checkbox/chip behaviour)
Drag-select(proposed) — drag across chips to mass-toggle (batched on release; no per-cell writes — server has none)

Density: chips visualDensity: compact, Sp-8 gaps, min touch target 44 dp on phone (dense inline exemption, 02 §9), 48 dp on desktop for mouse precision.

2. Screen transitions

TransitionToken
Roles list → detail / editorforward slide Mo.m-base; hero: role avatar flies to detail header Mo.m-slow
List → sheet (S5)showModalBottomSheet default Mo.m-base, r-xl top corners
Section collapse in matrixAnimatedSize Mo.m-base easeInOutCubic
Count badge changescale pop Mo.m-entrance (value-only, no shimmer)
Skeleton → contentcross-fade Mo.m-slow
Reduced motionall → Mo.m-instant fades (system setting; no stagger, no parallax)

3. Feedback & haptics

EventFeedback
Toggle perm / select-allselectionClick haptic; chip ripple Mo.m-fast
Save successsnackbar "Role created/updated" (< 3 s) + lightImpact
Save errorsnackbar error (≥ 4 s) + mediumImpact; 409 inline under slug
Delete confirmheavyImpact on destructive confirm tap
Remove memberoptimistic row removal after 200 + snackbar; lightImpact
Pull-to-refresh completelightImpact

4. Frustration controls

  • Save button: loading spinner replaces label; disabled while pending (anti-double-submit, 00-shared/08 §6).
  • Every tap responds ≤ 100 ms (press state visible — chips darken 2% on press).
  • Matrix save is one request; no per-cell pending states.
  • Back with dirty form → AppDialog "Discard changes?" (ESC / barrier = keep editing).

5. Desktop keyboard map

KeyAction
Ctrl+F, /matrix search focus
NRoles/Members list → create flow
↑/↓list selection (master-detail), matrix group navigation
Enteropen selected row / submit form
Escclose dialog/sheet/menu/search; cancel selection
Ctrl+Entersave from matrix search field

6. Swipe / long-press (phone)

  • Row swipe: not used for roles/members (destructive; 00-shared/08 §1 keeps swipe for safe ops only).
  • Long-press RoleRow/MemberTileAppMenu (same as trailing ⋮).
  • Long-press chip (matrix) → tooltip only.

7. Modal hierarchy (RBAC)

  1. Snackbar (save/remove feedback)
  2. Bottom sheet (S5 add member)
  3. Dialog (delete confirm, typed self-removal confirm, discard-changes)
  4. Full page (editor S3 — >3 fields rule, 05 §5)

8. Motion budget notes

  • Matrix scroll: no parallax, no sticky-header animation beyond Mo.m-instant elevation shift (El-2 sticky group header on desktop).
  • Audit list infinite-scroll: bottom spinner fade Mo.m-instant.