"use client"; import { observer } from "mobx-react-lite"; import Image from "next/image"; import useSWR from "swr"; // components import { LogoSpinner } from "@/components/common"; import { IssuesNavbarRoot } from "@/components/issues"; // hooks import { usePublish, usePublishList } from "@/hooks/store"; // assets import planeLogo from "@/public/plane-logo.svg"; type Props = { children: React.ReactNode; params: { anchor: string; }; }; const IssuesLayout = observer((props: Props) => { const { children, params } = props; // params const { anchor } = params; // store hooks const { fetchPublishSettings } = usePublishList(); const publishSettings = usePublish(anchor); // fetch publish settings useSWR(anchor ? `PUBLISH_SETTINGS_${anchor}` : null, anchor ? () => fetchPublishSettings(anchor) : null); if (!publishSettings) return ; return (
{children}
Plane logo
Powered by Plane Deploy
); }); export default IssuesLayout;