diff --git a/src/modules/energy/ElectricView.tsx b/src/modules/energy/ElectricView.tsx index e3732c0..1592243 100644 --- a/src/modules/energy/ElectricView.tsx +++ b/src/modules/energy/ElectricView.tsx @@ -1,40 +1,14 @@ -import { useState } from 'react'; -import { LayoutDashboard, CalendarDays } from 'lucide-react'; import ElectricOverview from './ElectricOverview'; import ElectricDaily from './ElectricDaily'; -type SubTab = 'daily' | 'overview'; - -const SUB_TABS: Array<{ id: SubTab; label: string; icon: typeof LayoutDashboard }> = [ - { id: 'daily', label: '每日', icon: CalendarDays }, - { id: 'overview', label: '总览', icon: LayoutDashboard }, -]; - export default function ElectricView() { - const [sub, setSub] = useState('daily'); return ( <> -
- {SUB_TABS.map(({ id, label, icon: Icon }) => { - const active = sub === id; - return ( - - ); - })} -
龙王路停车场充电站,期初 2025-01-01,手工导入每日更新
- {sub === 'overview' ? : } + + ); }