From a52e6892ccc4dae9156b6e51f3e277fd46be66dc Mon Sep 17 00:00:00 2001 From: WardPearce Date: Tue, 3 Mar 2026 22:53:29 +1300 Subject: [PATCH] Progress on watch party logic using trystero --- .../src/lib/components/WatchParty.svelte | 141 ++++++++++++++++++ .../lib/components/watch/WatchParty.svelte | 1 - materialious/src/lib/i18n/locales/en.json | 5 +- materialious/src/routes/(app)/+layout.svelte | 10 ++ .../routes/(app)/watch/[slug]/+page.svelte | 6 - 5 files changed, 155 insertions(+), 8 deletions(-) create mode 100644 materialious/src/lib/components/WatchParty.svelte delete mode 100644 materialious/src/lib/components/watch/WatchParty.svelte diff --git a/materialious/src/lib/components/WatchParty.svelte b/materialious/src/lib/components/WatchParty.svelte new file mode 100644 index 00000000..5728511a --- /dev/null +++ b/materialious/src/lib/components/WatchParty.svelte @@ -0,0 +1,141 @@ + + +
+

{$_('watchParty.header')}

+
+ + {#if !room} + + + {/if} +
diff --git a/materialious/src/lib/components/watch/WatchParty.svelte b/materialious/src/lib/components/watch/WatchParty.svelte deleted file mode 100644 index 5bf03f4a..00000000 --- a/materialious/src/lib/components/watch/WatchParty.svelte +++ /dev/null @@ -1 +0,0 @@ - diff --git a/materialious/src/lib/i18n/locales/en.json b/materialious/src/lib/i18n/locales/en.json index 00663fe0..63002191 100644 --- a/materialious/src/lib/i18n/locales/en.json +++ b/materialious/src/lib/i18n/locales/en.json @@ -86,7 +86,10 @@ "streams": "Streams" }, "watchParty": { - "start": "Start a watch party" + "start": "Start a watch party", + "header": "Watch party", + "createRoom": "Create room", + "joinRoom": "Join room" }, "subscriptions": { "manageSubscriptions": "Manage subscriptions" diff --git a/materialious/src/routes/(app)/+layout.svelte b/materialious/src/routes/(app)/+layout.svelte index 5fba828d..7782412d 100644 --- a/materialious/src/routes/(app)/+layout.svelte +++ b/materialious/src/routes/(app)/+layout.svelte @@ -33,6 +33,7 @@ import Author from '$lib/components/Author.svelte'; import Toast from '$lib/components/Toast.svelte'; import { isOwnBackend } from '$lib/shared'; + import WatchParty from '$lib/components/WatchParty.svelte'; let { children } = $props(); @@ -41,6 +42,7 @@ let mobileSearchShow = $state(false); let notifications: Notification[] = $state([]); let playerIsPip: boolean = $state(false); + let showWatchParty = $state(false); let pages = $state(getPages()); invidiousAuthStore.subscribe(() => { @@ -245,6 +247,10 @@ (mobileSearchShow = false)} /> {:else} + {#if $invidiousAuthStore && !isYTBackend()} -