fix: Fix video using in route pages

This commit is contained in:
2025-07-10 06:17:43 +03:00
parent 2d4a1e169b
commit 717031cd7a
7 changed files with 268 additions and 484 deletions

View File

@ -54,7 +54,7 @@ export function InfiniteCanvas({
const lastOriginalRotation = useRef<number | undefined>(undefined);
useEffect(() => {
const canvas = applicationRef?.app.canvas;
const canvas = applicationRef?.app?.canvas;
if (!canvas) return;
const canvasRect = canvas.getBoundingClientRect();
@ -63,7 +63,7 @@ export function InfiniteCanvas({
const centerX = window.innerWidth / 2 - canvasLeft;
const centerY = window.innerHeight / 2 - canvasTop;
setScreenCenter({ x: centerX, y: centerY });
}, [applicationRef?.app.canvas, setScreenCenter]);
}, [applicationRef?.app?.canvas, setScreenCenter]);
const handlePointerDown = (e: FederatedMouseEvent) => {
setIsPointerDown(true);