diff --git a/apps/web/app/(app)/[emailAccountId]/stats/ResponseTimeAnalytics.tsx b/apps/web/app/(app)/[emailAccountId]/stats/ResponseTimeAnalytics.tsx index a508e59558..5d28ca7cdc 100644 --- a/apps/web/app/(app)/[emailAccountId]/stats/ResponseTimeAnalytics.tsx +++ b/apps/web/app/(app)/[emailAccountId]/stats/ResponseTimeAnalytics.tsx @@ -75,7 +75,7 @@ export function ResponseTimeAnalytics({ error={error} loadingComponent={} > - {data && ( + {data?.summary && (
{data.emailsAnalyzed > 0 && (

diff --git a/apps/web/app/(app)/[emailAccountId]/stats/Stats.tsx b/apps/web/app/(app)/[emailAccountId]/stats/Stats.tsx index 6f1308c726..bf29ccc86b 100644 --- a/apps/web/app/(app)/[emailAccountId]/stats/Stats.tsx +++ b/apps/web/app/(app)/[emailAccountId]/stats/Stats.tsx @@ -18,6 +18,8 @@ import { ActionBar } from "@/app/(app)/[emailAccountId]/stats/ActionBar"; import { DetailedStatsFilter } from "@/app/(app)/[emailAccountId]/stats/DetailedStatsFilter"; import { LayoutGrid } from "lucide-react"; import { DatePickerWithRange } from "@/components/DatePickerWithRange"; +import { ErrorBoundary } from "@/components/ErrorBoundary"; +import { CardBasic } from "@/components/ui/card"; const selectOptions = [ { label: "Last week", value: "7" }, @@ -114,26 +116,48 @@ export function Stats() { />

- - - - - {isAccountOwner && } + }> + + + }> + + + }> + + + }> + + + {isAccountOwner && ( + }> + + + )}
); } + +function SectionError({ title }: { title: string }) { + return ( + +

+ Unable to load {title}. Please try refreshing the page. +

+
+ ); +} diff --git a/version.txt b/version.txt index ef6575d704..42f907fbe9 100644 --- a/version.txt +++ b/version.txt @@ -1 +1 @@ -v2.21.56 +v2.21.57