Commit Graph

1544 Commits

Author SHA1 Message Date
Jeff Emmett 8f9aa98995 Merge branch 'dev'
CI/CD / deploy (push) Successful in 2m15s Details
2026-04-01 14:38:51 -07:00
Jeff Emmett 5b8b638661 feat: add commitment pool + task request canvas shapes for rTime
Two new FolkShape subclasses enable drag-from-pool-to-task interactions on
the canvas. Orbs dragged from the commitment pool highlight matching skill
slots on task request cards and POST connections via the rTime API. Adds
commitment_requested notification type so commitment owners are notified
when their time is requested.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-01 14:38:41 -07:00
Jeff Emmett 71f2bc8fa3 Merge branch 'dev'
CI/CD / deploy (push) Successful in 2m11s Details
2026-04-01 14:14:28 -07:00
Jeff Emmett b54d75d161 ci: re-trigger pipeline after server compose fix
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-01 14:14:17 -07:00
Jeff Emmett ba5f3bfe3d Merge branch 'dev'
CI/CD / deploy (push) Waiting to run Details
2026-04-01 14:13:34 -07:00
Jeff Emmett ddf5772025 Fix space navigation redirects: server-side auth redirect + subdomain enforcement
Authenticated users visiting {space}.rspace.online/ now get a server-side
302 to /rspace instead of rendering the full dashboard then JS-redirecting
(eliminates flash of wrong header + 2-3 redirect chain → single redirect).

Bare domain rspace.online/{space} now 301-redirects to {space}.rspace.online/
so /{space}/ never appears in the URL bar.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-01 14:13:24 -07:00
Jeff Emmett 09ac17b332 fix(ci): use SSH-based smoke test and deploy only rspace service
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-01 14:12:49 -07:00
Jeff Emmett 77095c4c18 Merge branch 'dev'
CI/CD / deploy (push) Failing after 1m46s Details
2026-04-01 14:02:27 -07:00
Jeff Emmett 7420228ce9 feat: add Mermaid diagram generator canvas tool + share panel role selector
- Add folk-mermaid-gen web component: AI-powered diagram generation via
  Ollama, client-side SVG preview via mermaid.js, animated GIF export via
  mermaid.rspace.online API
- Register in canvas tools, toolbar, and shape registry
- Add role selector dropdown to share panel invite form (backend already
  supports role parameter)
- Fix pre-existing TS errors: SankeyNode missing address field,
  SpaceMember type mismatch in WebSocket auth fallback

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-01 14:01:52 -07:00
Jeff Emmett b84b1b41e3 ci: use REPO_READ_TOKEN for cross-repo encryptid-sdk clone
CI/CD / deploy (push) Successful in 1m54s Details
REGISTRY_TOKEN lacks read:repository scope.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-01 13:05:13 -07:00
Jeff Emmett 6018a88d26 Code-split shell.js: lazy-load Automerge/WASM offline chunk
CI/CD / deploy (push) Failing after 7s Details
Move RSpaceOfflineRuntime, CommunitySync, OfflineStore, and
RStackHistoryPanel into a new shell-offline.ts chunk loaded via
dynamic import(). This removes ~2.5MB of Automerge WASM from the
critical path, reducing blocking JS from ~960KB to ~150KB brotli.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-01 12:40:32 -07:00
Jeff Emmett 9fd3ca931c Harden rinbox agent mailbox pipeline: loop detection, rate limits, envelope fix
CI/CD / deploy (push) Waiting to run Details
- Fix executeApproval SMTP envelope to authenticate as SMTP_USER (Mailcow sender mismatch)
- Add reply loop detection: skip auto-replies, noreply, mailer-daemon, postmaster senders
- Per-sender rate limit: 3 replies/hr per sender per agent mailbox
- Daily send cap: 50 replies/day per agent mailbox
- Reply length cap: truncate agent replies at 2000 chars
- Bootstrap existing spaces on init: provision missing team inbox + agent mailbox docs

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-01 12:36:23 -07:00
Jeff Emmett adb1c7cb87 Merge branch 'main' into dev 2026-04-01 12:33:19 -07:00
Jeff Emmett e045ba1058 ci: clone encryptid-sdk with PAT for Docker build context
CI/CD / deploy (push) Waiting to run Details
Build needs named build context for encryptid-sdk dependency.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-01 12:32:55 -07:00
Jeff Emmett 45372c6681 Fix sidebar showing all modules: hide Manage panel when none disabled
- App switcher: only show "Manage rApps" when there are actually
  disabled modules or active restrictions. Move "Available to Add"
  above "Remove" to prioritize adding. Eliminates duplicate module
  listing when all modules are enabled.
- Shell: update app switcher on modules-changed event (was only
  updating tab bar and folk-rapp, not the sidebar itself).
- SMTP: use space-agent@rspace.online as From for invite/approval
  emails with proper envelope sender for DKIM alignment.
- Shell CSS: fix banner z-index, smooth header transition on banner.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-01 12:32:53 -07:00
Jeff Emmett 44f562d531 ci: clone encryptid-sdk with PAT for Docker build context
Build needs named build context for encryptid-sdk dependency.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-01 12:32:24 -07:00
Jeff Emmett b54ad4b36c Fix multi-user cursor positions: use page-relative coordinates
CI/CD / deploy (push) Failing after 8s Details
Remote cursors were broadcast as viewport-relative (clientX/Y), causing
them to appear at wrong positions when users had different scroll offsets.
Now sends page-relative coords and converts back on the receiver side.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-01 12:32:01 -07:00
Jeff Emmett d2fa533519 Improve rTasks drag-drop UX + sync space members on invite claim
CI/CD / deploy (push) Failing after 9s Details
rTasks: port backlog-md ordinal algorithm (bisection + rebalance),
fix column detection via bounding-box hit test, add empty-column
drop zones, source column dimming, no-op detection, and optimistic
DOM updates (no flash). New bulk-sort-order rebalance endpoint.

EncryptID: sync claimed invite members to Automerge doc immediately,
redirect to space subdomain after identity claim.

Server: add /api/internal/sync-space-member endpoint, fallback
member check in WebSocket auth for not-yet-synced invites.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-01 12:19:37 -07:00
Jeff Emmett fef217798e Fix PWA install banner: persist dismiss, prevent duplicates
- Add appinstalled event listener so browser-initiated installs also
  permanently dismiss the banner
- Ensure only one banner shows at a time (update hides install first)
- Refactor dismiss logic into single helper function

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-01 12:07:17 -07:00
Jeff Emmett a4cd977d17 Remove unreliable Ollama models from AI prompt, fix message overflow
- Remove Ollama model options (cold start timeouts via CF tunnel)
- Keep only Gemini Flash/Pro which are reliable cloud APIs
- Fix messages overflowing shape: min-height:0 on flex scroll container,
  word-break on messages, max-width on pre blocks

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-01 12:02:16 -07:00
Jeff Emmett 7dc4e9b3e9 Enforce module disabling on canvas folk-rapp shapes
CI/CD / deploy (push) Failing after 9s Details
Disabled rApp modules now show a grayed lock overlay on the canvas
instead of loading their iframe/widget. Uses a static instance registry
so setEnabledModules() broadcasts to all live shapes immediately.
Re-enabling a module reloads its content.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-01 11:55:13 -07:00
Jeff Emmett 29cd6168f9 Fix mobile popup/modal issues across shell components
CI/CD / deploy (push) Failing after 9s Details
- Space switcher: clamp menu left to prevent right-edge overflow,
  add max-width: calc(100vw - 8px), scrollable tabs with smaller
  padding on mobile
- Auth/edit modals: add max-height: 90dvh + overflow-y: auto so
  virtual keyboard doesn't push modal off-screen, reduce padding
  on small screens
- Identity dropdown: raise z-index from 100 to 10002 so it renders
  above the app-switcher sidebar (10001)
- Device nudge toast: constrain max-width to viewport width
- App switcher: add translucent backdrop overlay on mobile (<640px)
  with tap-to-dismiss
- Add :active pseudo-class alongside :hover on interactive elements
  for touch tap feedback

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-01 11:35:14 -07:00
Jeff Emmett 94964dfe88 ci: use internal registry (bypass Cloudflare upload limit)
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-01 10:46:14 -07:00
Jeff Emmett f0fc60e6d5 ci: add Gitea Actions CI/CD pipeline
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-04-01 10:32:14 -07:00
Jeff Emmett 1dcc3ff0a1 Fix SVG dataset crash and 403 on intent API
- Remove `dataset = {}` assignment on SVG circle element (read-only
  property on SVGElement, causes TypeError crash on every render)
- Add authHeaders() helper using encryptid-token from localStorage
- Include Authorization header on all mutating intent API calls
  (create, solver/run, accept, reject)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-31 23:17:14 -07:00
Jeff Emmett 2907935c50 fix(rtime): use getApiBase() for subdomain-compatible URL routing
Replace all hardcoded /${space}/rtime paths with getApiBase() which
derives the correct API base from window.location.pathname. This
supports both subdomain routing (demo.rspace.online/rtime) and
path-based fallback (/demo/rtime).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-31 22:46:33 -07:00
Jeff Emmett 08cae267fe feat(rtime): add intent-routed resource-backed commitments
Integrate Anoma-style intent routing into rTime so that commitments
become resource-backed intents that a solver can compose into multi-party
collaboration recommendations.

New modules:
- schemas-intent.ts: Intent, SolverResult, SkillCurve, Reputation types + 4 CRDT doc schemas
- solver.ts: Mycelium Clustering algorithm (bipartite graph matching, VP filtering, scoring)
- settlement.ts: Atomic settlement via saga pattern with escrow confirm/rollback
- skill-curve.ts: Per-skill bonding curve (demand/supply pricing)
- reputation.ts: Per-skill reputation scoring with time-based decay
- intent-routes.ts: 10 Hono API routes (intent CRUD, solver, settlement, curves, reputation)

Modified:
- schemas.ts: Added intentId/status fields to Commitment
- mod.ts: Registered 4 new docSchemas, mounted intent routes, added Collaborate output path
- folk-timebank-app.ts: Added Collaborate tab with intent cards, solver results panel,
  accept/reject buttons, create intent modal, skill price display, and status rings on pool orbs

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-31 22:36:06 -07:00
Jeff Emmett 16fe8f7626 Fix rSheet: remove space slug from URL paths
Space context comes from subdomain routing, not URL path segments.
Fix appUrl, externalApp.url, and onboardingActions.href to use
subdomain-compatible paths without {space} prefix.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-31 20:19:17 -07:00
Jeff Emmett 9a45b19435 Add rSheet module — collaborative spreadsheets via dSheet
- New module at modules/rsheet/mod.ts using externalApp pattern
- Embedded Y.js-backed spreadsheet grid with real-time sync
- Connects to shared y-websocket server for collaboration
- Registered in server/index.ts

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-31 19:25:36 -07:00
Jeff Emmett 0a4ee86976 fix(rpubs): move format selector from toolbar to write step bottom bar
Remove "Digest" format dropdown from the editor toolbar header. Move format
selector into the write step bottom bar as a clickable badge with dropdown.
Fix CSS bug where dropdown panels with display:flex overrode the HTML hidden
attribute, causing a visible rectangle artifact.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-31 18:44:09 -07:00
Jeff Emmett 1ee14b7520 fix(rcal): consistent viewport sizing + touch pinch-zoom fix
Make calendar views fill a consistent ~60vh area across all zoom levels
(month/season/year/multi-year) using flex stretching. Fix touch pinch-zoom
by removing pinch-zoom from touch-action so our pointer handler fires
instead of native page zoom.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-31 18:26:52 -07:00
Jeff Emmett 1ad721a579 chore(backlog): add TASK-MEDIUM.6 connections dashboard task
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-31 15:56:35 -07:00
Jeff Emmett 32093a0fc3 refactor(connections): move from space settings to user account
Connections are per-user, not per-space. Move the platform connections
dashboard from the space settings modal (5th tab) to the My Account
modal as a collapsible section. Add selective sharing: users connect
platforms to their personal data store, then choose which community
spaces to share data into via per-provider space checkboxes.

New endpoints: GET/POST /api/oauth/sharing for per-user sharing config.
Sharing config stored as Automerge doc {userSpace}:oauth:sharing.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-31 15:52:15 -07:00
Jeff Emmett bed124f869 feat(infra): add ollama to on-demand sidecar lifecycle
Ollama now starts on API request and stops after 5min idle, saving
~5-6GB RAM when not in use. Part of server-wide resource caps rollout.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-31 14:26:23 -07:00
Jeff Emmett dbfddb2fb5 feat(infra): on-demand sidecar lifecycle + resource caps
KiCad, FreeCAD, and Blender sidecars now start on API request and stop
after 5min idle, saving ~8GB RAM when not in use. Docker socket mounted
into rspace container for container lifecycle control. Memory/CPU limits
added to all services to prevent runaway resource consumption.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-31 13:29:42 -07:00
Jeff Emmett 26aa6433be feat(connections): add platform connections dashboard in space settings
New "Connections" tab in space settings with n8n-style visual dashboard
showing platform cards (Google, Notion, ClickUp live + 7 coming soon)
connected via SVG bezier lines to central rSpace hub node. Includes
OAuth connect/disconnect flows and GET /api/oauth/status endpoint.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-31 13:04:02 -07:00
Jeff Emmett eec88ac661 fix(flipbook): use <img> elements instead of background-image for page rendering
background-image data URLs on divs can fail silently in StPageFlip's
shadow DOM context, producing white pages. Switch to <img> elements
with explicit pixel dimensions and object-fit:cover for reliable
rendering. Add white background to .stf__item as a safety net.
Applies to both folk-pubs-flipbook and folk-book-reader.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-31 13:02:28 -07:00
Jeff Emmett 6ce8ede568 fix(rmeets): bump JS cache version to bypass stale CF 301 redirect
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-31 12:48:05 -07:00
Jeff Emmett bb31bd33c2 fix(routing): prevent /modules/ path from being redirected as a space slug
The subdomain canonicalization logic treated "modules" as a space slug,
redirecting /modules/rmeets/... to modules.rspace.online/rmeets/... (503).
Add "modules" to the serverPaths exclusion set so module JS assets
served from /modules/ are handled by Hono instead of redirected.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-31 12:26:23 -07:00
Jeff Emmett 0a6dcef4b9 feat(blender): pan/zoom viewer for rendered images
Rendered 3D images now center-fit on load and support:
- Mouse wheel zoom (toward cursor)
- Click-drag pan (mouse, pen, touch)
- Pinch-to-zoom (multi-touch)
- Double-click to reset view
- Reset button on hover

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-31 12:22:20 -07:00
Jeff Emmett bb19b4bc89 fix: consolidate PWA banners — install in browser, update in PWA only
Remove duplicate purple update banner from website/shell.ts that overlapped
with the server/shell.ts banner. Now a single banner system:
- Browser: "Install rSpace app" prompt (via beforeinstallprompt)
- Installed PWA: "New version available" prompt (via SW update detection)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-31 12:09:59 -07:00
Jeff Emmett 26c07a7672 fix(layout): restore flex chain for tab panes after TabCache.init()
TabCache.init() wraps all #app children into a .rspace-tab-pane div,
breaking the flex layout introduced in 2cbff89. Make active panes flex
columns so subnav/tabbar/rapp-content flex properties are respected.
Wrap fragment-loaded content in .rapp-content for consistent scrolling.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-31 11:57:47 -07:00
Jeff Emmett 0519e113b6 refactor(rmeets): remove /room/ prefix from meeting URLs
/rmeets/jeff now opens a room directly instead of requiring /rmeets/room/jeff.
Catch-all /:room route registered last so /meet, /recordings, /search still work.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-31 11:17:42 -07:00
Jeff Emmett 7faaa5c977 chore(backlog): add phase-0 milestone and tasks 126–139
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-31 11:12:05 -07:00
Jeff Emmett 5bc64a5b4e fix(touch): pointer event parity for slash commands, collab overlay, canvas, and wallet charts
Convert remaining mouse-only event listeners to Pointer Events so touch
and pen inputs work identically to mouse across rApps and canvas:

- rnotes slash-command: mousedown/mouseenter → pointerdown/pointerenter
- collab overlay: mousemove → pointermove for cursor broadcast, click → pointerdown for collab-id tracking
- canvas.html: toolbar label reveal gated behind @media (hover: hover), :active fallbacks on 12 button selectors, JS mouseenter/mouseleave → pointerenter/pointerleave
- wallet-viz D3 charts: all mouseover/mousemove/mouseout → pointerenter/pointermove/pointerleave on transaction paths, balance area, Sankey links, and reset button

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-31 11:06:44 -07:00
Jeff Emmett 690e4dedb4 refactor: consolidate space settings — both gear icons open same tabbed modal
Remove rstack-space-settings slide-out panel. Enhance the existing tabbed
modal in rstack-space-switcher with add-member (username search + email
invite) and pending email invites (with revoke). Header gear now calls
openSettingsModal() on the space switcher instead of toggling the old panel.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-31 10:58:30 -07:00
Jeff Emmett 2cbff8925d fix(layout): viewport-filling rApp layout — eliminate body scroll
Make #app a flex column with height:100vh so all rApps fill the viewport
exactly. Wrap module body in .rapp-content flex child. Replace all
hardcoded calc(100vh - Npx) with height:100% across 20+ components.
Remove sticky positioning from subnav/tabbar (now flex items).
Generalize mobile body-flex to all pages (not just canvas-layout).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-31 10:57:09 -07:00
Jeff Emmett 0a21caa5e5 feat(pwa): install banner + update notification for service worker
- Install banner appears above header when beforeinstallprompt fires
  (dismissed state persisted in localStorage, never shows again)
- Update banner appears when a new SW version is detected waiting
  (click "Update" → SKIP_WAITING message → SW activates → page reloads)
- SW no longer auto-skipWaiting on install; waits for client message
- Bumped SW cache version to v5 and registration to ?v=5
- Banner CSS: fixed at top, z-index above all chrome, slide-in animation
- Header/tab-row/app offsets adjust when banner visible

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-31 10:40:07 -07:00
Jeff Emmett 7d5209021a feat(rnotes): web clipper download, URL/file note creation from sidebar
- Copy browser extension into repo so /extension/download works in Docker
- Add "Web Clipper" button to sidebar footer
- Replace simple "+" with context menu: New Note / From URL / Upload File
- BOOKMARK notes from URL, IMAGE/AUDIO/FILE notes from uploaded files

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-31 10:37:13 -07:00
Jeff Emmett 24c1598e60 fix: contain MI bar z-index within header stacking context on mobile
On desktop the header is position:fixed which creates a stacking
context, containing the MI bar's z-index:10001. On mobile the header
switches to position:sticky without z-index, so no stacking context
is created and the MI bar's z-index leaks out above the tab row
(z-index:9998). Fix by adding z-index:9999 to the header on mobile.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-31 10:32:36 -07:00