Files
cinny/docs/handoff/features/join-before-navigate/HANDOFF.md
Max Litruv Boonzaayer e058165830 feat: upgrade toolchain and soften sync recovery after network blips
Bump Vite 8, matrix-js-sdk, and related deps; fix immer/vanilla-extract imports for new majors. Replace blocking sync error dialog with background recovery on wake/offline, and disable Vite auto-open in dev. Add feature handoff documentation index.
2026-07-09 01:55:09 +10:00

79 lines
1.9 KiB
Markdown

# Join before navigate — handoff
## Summary
When a user opens a room link for a room they have not joined, this preview page shows room info (name, topic, member count) and offers join before entering the timeline.
## User-facing behavior
- matrix.to / internal join links land here if not member
- Room card preview with topic
- Join button → membership then navigate to room/space
- Back navigation on mobile
## Architecture
```
JoinBeforeNavigate.tsx
→ RoomSummaryLoader for preview data
→ useRoomNavigate after join
Route: _JOIN_PATH in Router.tsx
```
## Key files
| Path | Role |
|------|------|
| `cinny/src/app/features/join-before-navigate/JoinBeforeNavigate.tsx` | Preview + join UI |
| `cinny/src/app/components/RoomSummaryLoader.tsx` | Fetch room preview |
| `cinny/src/app/hooks/useRoomNavigate.ts` | Post-join navigation |
| `cinny/src/app/state/joiningProgress.ts` | Join in progress UX |
## Data model
Preview from `/summary` API or peek room state. No local persistence.
## Dependencies
- matrix-js-sdk `joinRoom`
- `via` servers param for federated joins
## Integration points
- **routing-and-navigation**: join route with `roomIdOrAlias`, `viaServers`
- **explore**: similar preview patterns
- **electron-shell**: `paarrot://` deep links may target join flow
## Testing
### Manual
1. Open link to unjoined public room.
2. Preview shows name/topic.
3. Join succeeds; lands in timeline.
4. Space link navigates to space not room.
### Automated
- None
## Known issues & gotchas
- Private rooms without peek show limited preview
- `viaServers` required for some federated aliases
- `isSpace` check routes to space navigation after join
## Future work
- Knock rooms support
- Invite-only room messaging
## Related docs
- [routing-and-navigation HANDOFF](../routing-and-navigation/HANDOFF.md)
- [electron-shell HANDOFF](../electron-shell/HANDOFF.md)
## Add your extra things here
- Props: `roomIdOrAlias`, optional `eventId`, `viaServers[]`