feat: Implement video player & playback

This commit is contained in:
Aleksi Lassila
2024-04-01 14:53:59 +03:00
parent 243ee258c1
commit 5dbcff0271
4 changed files with 17 additions and 8 deletions

View File

@@ -1,7 +1,7 @@
import { writable } from 'svelte/store';
import { modalStack } from '../Modal/modal.store';
import VideoPlayer from './VideoPlayer.svelte';
import { jellyfinItemsStore } from '../../stores/data.store';
import VideoPlayerModal from './VideoPlayerModal.svelte';
const initialValue = { visible: false, jellyfinId: '' };
export type PlayerStateValue = typeof initialValue;
@@ -13,7 +13,7 @@ function createPlayerState() {
...store,
streamJellyfinId: (id: string) => {
store.set({ visible: true, jellyfinId: id });
modalStack.create(VideoPlayer, {}); // FIXME
modalStack.create(VideoPlayerModal, { id });
},
close: () => {
store.set({ visible: false, jellyfinId: '' });