refactor period (rolling/calender) to periodType
This commit is contained in:
@@ -25,7 +25,7 @@ export default function DashboardView({
|
||||
}: ViewProps) {
|
||||
const theme = useTheme();
|
||||
const themeMode = theme.palette.mode;
|
||||
const { mode, period, comparison } = state;
|
||||
const { mode, periodType, comparison } = state;
|
||||
|
||||
// Resolve colors with fallbacks
|
||||
const colors = React.useMemo(() => {
|
||||
@@ -139,8 +139,8 @@ export default function DashboardView({
|
||||
title={section.title}
|
||||
accentColor={colors.primary}
|
||||
colorScheme={colors}
|
||||
periodType={period}
|
||||
onPeriodTypeChange={(p: any) => setState(prev => ({ ...prev, period: p }))}
|
||||
periodType={periodType}
|
||||
onPeriodTypeChange={(p: any) => setState(prev => ({ ...prev, periodType: p }))}
|
||||
comparison={comparison}
|
||||
setComparison={(c: any) => setState(prev => ({ ...prev, comparison: c }))}
|
||||
/>
|
||||
|
||||
Reference in New Issue
Block a user