some fonts
This commit is contained in:
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -2,6 +2,7 @@
|
||||
import { useSpacetimeDB, useTable, useReducer } from "spacetimedb/svelte";
|
||||
import { tables, reducers } from "$lib/st-bindings";
|
||||
import JASSUB from "jassub";
|
||||
import font1 from "$lib/assets/fonts/trebuc_0.ttf";
|
||||
|
||||
const conn = useSpacetimeDB();
|
||||
|
||||
@@ -23,10 +24,12 @@
|
||||
let jassubInstance: any | undefined;
|
||||
|
||||
$effect(() => {
|
||||
console.log("effect-1");
|
||||
if (videoElement && videoState?.subtitleUrl && videoState.subtitleUrl.endsWith(".ass")) {
|
||||
jassubInstance = new JASSUB({
|
||||
video: videoElement,
|
||||
subUrl: videoState.subtitleUrl,
|
||||
fonts: [font1],
|
||||
});
|
||||
|
||||
return () => {
|
||||
@@ -46,6 +49,7 @@
|
||||
}
|
||||
|
||||
$effect(() => {
|
||||
console.log("effect-2");
|
||||
if (!videoElement || !videoState) return;
|
||||
const el = videoElement;
|
||||
const state = videoState;
|
||||
|
||||
Reference in New Issue
Block a user