diff --git a/app/components/dashboard/dashboard-custom-bar-chart.tsx b/app/components/dashboard/dashboard-custom-bar-chart.tsx new file mode 100644 index 0000000..516cffb --- /dev/null +++ b/app/components/dashboard/dashboard-custom-bar-chart.tsx @@ -0,0 +1,74 @@ +import React from "react"; +import { formatNumber } from "~/lib/utils"; + +interface DataItem { + label: string; + value: number; + color: string; +} + +interface DashboardCustomBarChartProps { + title: string; + data: DataItem[]; + loading?: boolean; +} + +export function DashboardCustomBarChart({ + title, + data, + loading = false, +}: DashboardCustomBarChartProps) { + if (loading) { + return ( +
- {error || 'خطای نامشخص در بارگذاری دادههای داشبورد رخ داده است'} + {error || + "خطای نامشخص در بارگذاری دادههای داشبورد رخ داده است"}
-