diff --git a/.vscode/settings.json b/.vscode/settings.json index 4bf4637b..994bdcfd 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -7,5 +7,6 @@ "materialious/src/lib/i18n", "materialious/src/lib/i18n/locales" ], - "i18n-ally.extract.autoDetect": true + "i18n-ally.extract.autoDetect": true, + "i18n-ally.keystyle": "nested" } \ No newline at end of file diff --git a/materialious/src/lib/Thumbnail.svelte b/materialious/src/lib/Thumbnail.svelte index c8ee4874..5c97fbca 100644 --- a/materialious/src/lib/Thumbnail.svelte +++ b/materialious/src/lib/Thumbnail.svelte @@ -16,11 +16,15 @@ export let video: VideoBase | Video | Notification | PlaylistPageVideo; export let playlistId: string = ''; - let watchUrl = `/watch/${video.videoId}` + (playlistId ? `?playlist=${playlistId}` : ''); + let watchUrl = new URL(`${import.meta.env.VITE_DEFAULT_FRONTEND_URL}/watch/${video.videoId}`); + + if (playlistId !== '') { + watchUrl.searchParams.set('playlist', playlistId); + } syncPartyPeer.subscribe((peer) => { if (peer) { - watchUrl += (playlistId ? '&' : '?') + `sync=${peer.id}`; + watchUrl.searchParams.set('sync', peer.id); } }); @@ -140,7 +144,7 @@ @@ -179,7 +183,7 @@