Signed-off-by: Kenneth Obsequio <k80308392@gmail.com>
This commit is contained in:
2026-09-26 12:57:21 +08:00
parent 9255533215
commit 8bf4c04f0b
9 changed files with 197 additions and 52 deletions
@@ -38,6 +38,7 @@ export function DashboardSection({
iconMap = {},
linkMap = {},
chartLinkMap = {},
chartHeight = 240,
className = "",
}) {
return (
@@ -57,6 +58,8 @@ export function DashboardSection({
label={b.label}
data={b.data}
onBarClick={chartLinkMap[b.key]}
height={b.height ?? chartHeight}
yAxisWidth={b.yAxisWidth}
/>
) : (
<PieBreakdown
@@ -64,6 +67,7 @@ export function DashboardSection({
label={b.label}
data={b.data}
onSliceClick={chartLinkMap[b.key]}
height={b.height ?? chartHeight}
/>
)
)}
@@ -41,6 +41,7 @@ export function TableDashboard({
breakdowns = [],
statMap = {},
tableRefsRef, // ← remove activeFilters prop entirely
chartHeight = 240,
className = "",
}) {
// ─── Always read live from ref ────────────────────────────────────────────
@@ -124,6 +125,7 @@ export function TableDashboard({
label={b.label}
data={b.data}
onBarClick={b.filterId ? (entry) => handleChartClick(b, entry) : undefined}
height={b.height ?? chartHeight}
/>
) : (
<PieBreakdown
@@ -131,6 +133,7 @@ export function TableDashboard({
label={b.label}
data={b.data}
onSliceClick={b.filterId ? (entry) => handleChartClick(b, entry) : undefined}
height={b.height ?? chartHeight}
/>
)
)}