rspace-online/shared/components
Jeff Emmett e34eec649f feat(canvas): unified rApp canvas interaction — keyboard + space-to-grab
Phase A.5: bring rApp mini-canvases to parity with the main rSpace canvas
on keyboard shortcuts and Space-to-grab behavior, plus ship reusable
primitives for fit-view and zoom chrome.

shared/canvas-interaction.ts — extend CanvasInteractionController:
  • enableSpaceToGrab — Space sets grab cursor and flips isSpaceHeld()
  • enableKeyboardShortcuts — 0 fit, +/- zoom, arrows pan, Ctrl+Z/Y
    undo/redo, Delete/Backspace delete (with shadow-DOM-aware text
    input detection so inline editors still work)
  • zoomByFactor() helper for chrome +/- buttons

shared/canvas-viewport.ts (new):
  • fitViewToRects / fitViewToNodes — standard fit algorithm matching
    the main canvas (40px padding, 0.1–1.5 clamp default)
  • persistViewport / restoreViewport — localStorage under
    rspace_viewport:<key> with finite-value validation

shared/components/rspace-canvas-chrome.ts (new):
  • <rspace-canvas-chrome> web component — zoom out/in/fit buttons +
    percent indicator + optional grid toggle. Emits canvas-zoom-*
    events. Available as drop-in for new/future canvases.

Migrate 8 rApp canvases to opt into space-to-grab + keyboard fit:
rsocials planner (keeps existing isEnabled gate), rsocials workflow,
rminders automation, rflows, rgov circuit, rnetwork CRM graph,
applet-circuit-canvas. rTime skips enableSpaceToGrab because it has
its own Space tracking integrated with node-drag state.

Bump asset cache versions so browsers pick up the new JS.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-04-17 18:18:49 -04:00
..
folk-app-canvas.ts wip(rschedule): schemas + folk-app-canvas/folk-widget shared components 2026-04-16 17:26:45 -04:00
folk-widget.ts wip(rschedule): schemas + folk-app-canvas/folk-widget shared components 2026-04-16 17:26:45 -04:00
rspace-canvas-chrome.ts feat(canvas): unified rApp canvas interaction — keyboard + space-to-grab 2026-04-17 18:18:49 -04:00
rstack-app-switcher.ts fix: invite UX — hide disabled modules, resolve usernames, show invites list, require userId on claim 2026-04-17 09:53:53 -04:00
rstack-chat-widget.ts feat(rchats): add global chat widget + unread count endpoint 2026-04-15 11:15:33 -04:00
rstack-collab-overlay.ts fix(presence): keep peers online across rApp navigation in same space 2026-04-17 11:23:50 -04:00
rstack-comment-bell.ts feat(comments): spatial comment pins on all rApp module pages 2026-04-10 11:15:05 -04:00
rstack-history-panel.ts fix(shell): header button reliability — history, settings, comments 2026-03-24 16:04:11 -07:00
rstack-identity.ts feat(auth): cross-subdomain username hint for passkey SSO 2026-04-17 12:05:07 -04:00
rstack-markwhen-view.ts feat(rpast): chronicle-of-self timeline + markwhen projection 2026-04-16 16:13:11 -04:00
rstack-mi.ts feat(mi-voice): quieter+smoother voice, caveman terseness in voice mode 2026-04-16 15:44:11 -04:00
rstack-module-comments.ts feat(comments): spatial comment pins on all rApp module pages 2026-04-10 11:15:05 -04:00
rstack-module-setup.ts feat: per-rApp inline config + module-aware settings panel 2026-03-10 16:45:48 -07:00
rstack-notification-bell.ts feat(rtime): commitment notifications + email delivery channel 2026-04-01 14:59:10 -07:00
rstack-offline-indicator.ts feat: wire offline-first Automerge sync to all 13 rSpace modules 2026-03-04 19:07:59 -08:00
rstack-share-panel.ts feat: add Mermaid diagram generator canvas tool + share panel role selector 2026-04-01 14:01:52 -07:00
rstack-space-switcher.ts ui(space-settings): Invite label + breathing room under username search 2026-04-16 16:36:52 -04:00
rstack-tab-bar.ts rename: finish rschedule → rminders migration 2026-04-16 17:18:17 -04:00
rstack-user-dashboard.ts feat: customizable dashboard with persistent home icon and widget system 2026-04-10 23:10:27 -04:00