diff --git a/apps/web/src/components/callPopout.tsx b/apps/web/src/components/callPopout.tsx index bbe0f91..79d5fb7 100644 --- a/apps/web/src/components/callPopout.tsx +++ b/apps/web/src/components/callPopout.tsx @@ -1,8 +1,15 @@ +import { lazy, Suspense } from "react"; + import { useCall } from "@tensamin/call/state"; -import Popout from "@tensamin/call/popout"; + +const Popout = lazy(() => import("@tensamin/call/popout")); export default function CallPopout() { const active = useCall((state) => state.state !== "closed"); - return active ? : null; + return active ? ( + + + + ) : null; } diff --git a/apps/web/src/components/callSidebarBox.tsx b/apps/web/src/components/callSidebarBox.tsx index 89d7905..5480af2 100644 --- a/apps/web/src/components/callSidebarBox.tsx +++ b/apps/web/src/components/callSidebarBox.tsx @@ -1,8 +1,15 @@ +import { lazy, Suspense } from "react"; + import { useCall } from "@tensamin/call/state"; -import SidebarBox from "@tensamin/call/sidebarBox"; + +const SidebarBox = lazy(() => import("@tensamin/call/sidebarBox")); export default function CallSidebarBox() { const active = useCall((state) => state.state !== "closed"); - return active ? : null; + return active ? ( + + + + ) : null; } diff --git a/apps/web/src/components/navbar.tsx b/apps/web/src/components/navbar.tsx index e980a0d..19c367f 100644 --- a/apps/web/src/components/navbar.tsx +++ b/apps/web/src/components/navbar.tsx @@ -28,7 +28,6 @@ import { useState } from "react"; import { SidebarTrigger, useSidebar } from "@methanium/ui"; import { WindowControls as Controls } from "@methanium/ui"; import { useSession } from "@tensamin/identity/session"; -import { joinCall } from "@tensamin/call/store"; import Profile from "./modals/profile"; export default function Navbar({ forMobile }: { forMobile: boolean }) { @@ -140,7 +139,11 @@ export default function Navbar({ forMobile }: { forMobile: boolean }) { {currentCalls.length === 0 ? (