Fix: Watch Together Raum-Erstellung + Download-Button

- Server/Frontend Protokoll-Mismatch behoben (create_room, join_room, room_created, room_joined, playback_state)
- togglePlay sendet jetzt korrekt pause/resume statt toggle_play
- Download-Button: SPA-Fallback fuer /downloads/ verhindert, 404 statt Reload
- download-Attribut am Link hinzugefuegt

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Daniel 2026-03-07 02:48:43 +01:00
parent 73f247ada3
commit e748fc97e9
6 changed files with 74 additions and 61 deletions

View file

@ -75,8 +75,7 @@ function getPlaybackState(room: Room): Record<string, any> {
const currentTime = room.currentTime + (room.playing ? (Date.now() - room.lastSyncAt) / 1000 : 0);
return {
type: 'playback_state',
videoUrl: room.currentVideo?.url ?? null,
videoTitle: room.currentVideo?.title ?? null,
currentVideo: room.currentVideo ? { url: room.currentVideo.url, title: room.currentVideo.title } : null,
playing: room.playing,
currentTime,
updatedAt: Date.now(),