Skip to content

Commit ef57069

Browse files
committed
feat(platform): use latest options of echarts
1 parent 92ad49d commit ef57069

File tree

4 files changed

+279
-3841
lines changed

4 files changed

+279
-3841
lines changed

packages/platform/src/app/components/chart/theme.json

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,9 @@
2020
},
2121
"symbolSize": "8",
2222
"symbol": "emptyCircle",
23+
"label": {
24+
"color": "var(--d-text-color-sub)"
25+
},
2326
"smooth": false
2427
},
2528
"radar": {
@@ -37,6 +40,9 @@
3740
"itemStyle": {
3841
"barBorderWidth": 0,
3942
"barBorderColor": "#ccc"
43+
},
44+
"label": {
45+
"color": "var(--d-text-color-sub)"
4046
}
4147
},
4248
"pie": {
@@ -298,6 +304,7 @@
298304
}
299305
},
300306
"tooltip": {
307+
"borderWidth": 0,
301308
"axisPointer": {
302309
"lineStyle": {
303310
"color": "#cccccc",

packages/platform/src/app/routes/dashboard/echarts/ECharts.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,13 @@ import { DCard } from '@react-devui/ui';
55

66
import { AppChart, AppRouteHeader } from '../../../components';
77
import styles from './ECharts.module.scss';
8-
import { getOptions } from './options';
8+
import { barOptions, lineOptions, nightingaleOptions, pieOptions, scatterOptions, stackedBarOptions, stackedLineOptions } from './options';
99

1010
export default function ECharts(): JSX.Element | null {
1111
const [options, setOptions] = useState<echarts.EChartsOption[]>([]);
1212

1313
useMount(() => {
14-
setOptions(getOptions() as echarts.EChartsOption[]);
14+
setOptions([lineOptions, stackedLineOptions, barOptions, stackedBarOptions, pieOptions, nightingaleOptions, scatterOptions]);
1515
});
1616

1717
return (

0 commit comments

Comments
 (0)