import React from 'react'; import { EnvironmentOutlined, RocketOutlined, PieChartOutlined } from '@ant-design/icons'; import './maritime-card.less'; // 无人船图标组件 const USVIcon = () => ( ); interface MaritimeKpiStripProps { deviceTotal: number; seaAreaCount: number; todayNew: number; successRate: number; taskNewLabel?: string; } const MaritimeKpiStrip: React.FC = ({ deviceTotal, seaAreaCount, todayNew, successRate, taskNewLabel = '当日任务', }) => { const kpis = [ { key: 'ship', label: '设备总数', value: deviceTotal, icon: , accent: 'ship', }, { key: 'area', label: '海域总数', value: seaAreaCount, icon: , accent: 'anchor', }, { key: 'task', label: taskNewLabel, value: todayNew, icon: , accent: 'alert', }, { key: 'rate', label: '执行成功率', value: successRate, unit: '%', icon: , accent: 'route', }, ]; return (
{kpis.map((kpi) => (
{kpi.icon}
{kpi.label}
{kpi.value} {kpi.unit && {kpi.unit}}
))}
); }; export default MaritimeKpiStrip;