diff --git a/apps/marketing/src/app/(marketing)/open/cap-table.tsx b/apps/marketing/src/app/(marketing)/open/cap-table.tsx index 5bdea46c4..b9a27235c 100644 --- a/apps/marketing/src/app/(marketing)/open/cap-table.tsx +++ b/apps/marketing/src/app/(marketing)/open/cap-table.tsx @@ -1,6 +1,6 @@ 'use client'; -import { HTMLAttributes } from 'react'; +import { HTMLAttributes, useEffect, useState } from 'react'; import { Cell, Pie, PieChart, Tooltip } from 'recharts'; @@ -41,33 +41,40 @@ const renderCustomizedLabel = ({ export type CapTableProps = HTMLAttributes; export const CapTable = ({ className, ...props }: CapTableProps) => { + const [isSSR, setIsSSR] = useState(true); + + useEffect(() => { + setIsSSR(false); + }, []); return (

Cap Table

- - - {CAP_TABLE.map((entry, index) => ( - - ))} - - { - return [`${percent}%`, name || props['name'] || props['payload']['name']]; - }} - /> - + {!isSSR && ( + + + {CAP_TABLE.map((entry, index) => ( + + ))} + + { + return [`${percent}%`, name || props['name'] || props['payload']['name']]; + }} + /> + + )}
); diff --git a/apps/marketing/src/app/(marketing)/open/gh-metrics.tsx b/apps/marketing/src/app/(marketing)/open/gh-metrics.tsx index 1e2fa453d..5c0c79716 100644 --- a/apps/marketing/src/app/(marketing)/open/gh-metrics.tsx +++ b/apps/marketing/src/app/(marketing)/open/gh-metrics.tsx @@ -9,6 +9,7 @@ import { cn } from '@documenso/ui/lib/utils'; import { StargazersType } from './page'; +export type MetricsDataKey = 'stars' | 'forks' | 'mergedPRs' | 'openIssues'; export type GithubMetricProps = HTMLAttributes & { data: StargazersType; metricKey: MetricsDataKey; @@ -17,8 +18,6 @@ export type GithubMetricProps = HTMLAttributes & { chartHeight?: number; }; -export type MetricsDataKey = 'stars' | 'forks' | 'mergedPRs' | 'openIssues'; - export const GithubMetric = ({ className, data, @@ -39,9 +38,9 @@ export const GithubMetric = ({

{title}

-
+
- +