diff --git a/src/app/member/[id]/_components/role-kpi-pair.tsx b/src/app/member/[id]/_components/role-kpi-pair.tsx index 4d54772..34f8391 100644 --- a/src/app/member/[id]/_components/role-kpi-pair.tsx +++ b/src/app/member/[id]/_components/role-kpi-pair.tsx @@ -1,6 +1,6 @@ "use client"; -import { KpiCard } from "@/components/metric/kpi-card"; +import { ReadOnlyMetricCard } from "@/app/dashboard/[teamId]/_components/dashboard-metric-card"; import { RoleCard, type RoleCardData } from "@/components/role/role-card"; import { cn } from "@/lib/utils"; import { type RouterOutputs } from "@/trpc/react"; @@ -11,14 +11,9 @@ type DashboardChart = RouterOutputs["dashboard"]["getDashboardCharts"][number]; interface RoleKpiPairProps { role: Role; dashboardChart?: DashboardChart; - teamId: string; } -export function RoleKpiPair({ - role, - dashboardChart, - teamId, -}: RoleKpiPairProps) { +export function RoleKpiPair({ role, dashboardChart }: RoleKpiPairProps) { const roleCardData: RoleCardData = { id: role.id, title: role.title, @@ -41,7 +36,7 @@ export function RoleKpiPair({ return (
- {hasKpi && ( - - )} + {hasKpi && } {hasMetricButNoChart && ( -
+
KPI data loading...
)} diff --git a/src/app/member/[id]/_components/team-section.tsx b/src/app/member/[id]/_components/team-section.tsx index 3d761f9..8bef1d8 100644 --- a/src/app/member/[id]/_components/team-section.tsx +++ b/src/app/member/[id]/_components/team-section.tsx @@ -84,7 +84,6 @@ export function TeamSection({ ? chartsByMetricId.get(role.metricId) : undefined } - teamId={team.id} /> ))}
diff --git a/src/components/role/role-card.tsx b/src/components/role/role-card.tsx index c3a606b..a5b5be9 100644 --- a/src/components/role/role-card.tsx +++ b/src/components/role/role-card.tsx @@ -181,7 +181,8 @@ function RoleCardComponent({ return (