diff --git a/apps/web/pages/availability/troubleshoot.tsx b/apps/web/pages/availability/troubleshoot.tsx index e37b598d68..9a0817755a 100644 --- a/apps/web/pages/availability/troubleshoot.tsx +++ b/apps/web/pages/availability/troubleshoot.tsx @@ -1,16 +1,32 @@ -import { Troubleshooter } from "@calcom/features/troubleshooter/Troubleshooter"; +import dynamic from "next/dynamic"; +import { Suspense } from "react"; + import { getLayout } from "@calcom/features/troubleshooter/layout"; import { useLocale } from "@calcom/lib/hooks/useLocale"; -import { HeadSeo } from "@calcom/ui"; +import { HeadSeo, Loader } from "@calcom/ui"; import PageWrapper from "@components/PageWrapper"; +const TroubleshooterClientOnly = dynamic( + () => import("@calcom/features/troubleshooter/Troubleshooter").then((mod) => mod.Troubleshooter), + { + ssr: false, + } +); + function TroubleshooterPage() { const { t } = useLocale(); return ( <> - + + + + }> + + ); } diff --git a/packages/features/troubleshooter/components/CalendarToggleContainer.tsx b/packages/features/troubleshooter/components/CalendarToggleContainer.tsx index ad706a8ce2..ea24a81f33 100644 --- a/packages/features/troubleshooter/components/CalendarToggleContainer.tsx +++ b/packages/features/troubleshooter/components/CalendarToggleContainer.tsx @@ -79,14 +79,14 @@ function EmptyCalendarToggleItem() { export function CalendarToggleContainer() { const { t } = useLocale(); - const { data, isPending } = trpc.viewer.connectedCalendars.useQuery(); + const { data, isLoading } = trpc.viewer.connectedCalendars.useQuery(); const hasConnectedCalendars = data && data?.connectedCalendars.length > 0; return (

{t("calendars_were_checking_for_conflicts")}

- {hasConnectedCalendars && !isPending ? ( + {hasConnectedCalendars && !isLoading ? ( <> {data.connectedCalendars.map((calendar) => { const foundPrimary = calendar.calendars?.find((item) => item.primary);