Skip to content

feat: live collaboration rooms, SidePanel, sharing self-hosting#88

Merged
andrewchumchal merged 3 commits into
devfrom
feat/live-collab
May 25, 2026
Merged

feat: live collaboration rooms, SidePanel, sharing self-hosting#88
andrewchumchal merged 3 commits into
devfrom
feat/live-collab

Conversation

@andrewchumchal

Copy link
Copy Markdown
Contributor

Summary

Adds live collaboration rooms, a reusable SidePanel overlay, and a restructured Sharing settings tab with self-hosting support.


New components

  • CollaborationBar — room status bar with invite copy, participant avatars, AI mode toggle, and gear button
  • JoinRoomModal — modal to join a room via invite URL or room ID
  • SidePanel — reusable right-side overlay panel (used for conversation settings and room settings)

New stores / hooks

  • collaborationStore — room state: roomId, participants, lockHolder, aiMode, hostId, isLocalHost, myId
  • useCollaboration — WebSocket lifecycle: connect, reconnect, event dispatch, IPC bridge

ChatArea

  • Migrated conversation settings and room settings into SidePanel overlays
  • Fixed infinite render loop caused by Zustand v5 object selector ((s) => ({...}) creates new reference on every call → use one selector per scalar)
  • isLocalHost flag for immediate gear icon visibility before server confirms hostId
  • Optimistic setAiMode update on click

StatusBar

  • Context-aware live indicator: bright pulse when on the live chat, dim clickable when on a different chat

SettingsPanel — Sharing tab

Restructured as multi-section tab (same pill-nav pattern as AI tab):

  • Shared Links — existing snapshot list
  • Live — active room status, navigate back button
  • Self-Hosting — URL input saved to settings.selfHosting.shareServerUrl

Types

  • AppSettings.selfHosting?: { shareServerUrl?: string } — custom relay server URL
  • Extended IPC collab API types in env.d.ts

Other

  • lib/export.ts — conversation export utilities
  • uiStore: showRoomSettings toggle

- Add CollaborationBar, JoinRoomModal, SidePanel components
- Add collaborationStore (room state, participants, lock, aiMode, isLocalHost)
- Add useCollaboration hook for WebSocket room management
- Migrate conversation/room settings to SidePanel overlay
- Fix infinite render loop: replace object selectors with scalar selectors
- Add optimistic setAiMode with server echo
- StatusBar: context-aware live indicator (active vs other chat)
- SettingsPanel Sharing tab: multi-section (Shared Links / Live / Self-Hosting)
- Add AppSettings.selfHosting.shareServerUrl for custom relay server URL
- ChatArea: isLocalHost flag for immediate gear icon visibility
- uiStore: add showRoomSettings toggle
- types: AppSettings.selfHosting, extend IPC collab API
- lib/export: conversation export utilities
@andrewchumchal
andrewchumchal merged commit d818391 into dev May 25, 2026
2 checks passed
@andrewchumchal
andrewchumchal deleted the feat/live-collab branch May 25, 2026 03:15
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