feat: add config and create querys to get metric data

This commit is contained in:
Qiuxia Fan
2022-01-06 15:55:25 +08:00
parent e234361853
commit c282655369
15 changed files with 294 additions and 36 deletions

View File

@@ -88,7 +88,7 @@ function getOption() {
},
showBackground: props.config.showBackground,
backgroundStyle: {
color: "rgba(180, 180, 180, 0.2)",
color: "rgba(180, 180, 180, 0.1)",
},
markArea:
index === 0

View File

@@ -33,9 +33,6 @@ const props = defineProps({
/*global Nullable */
const chart = ref<Nullable<HTMLElement>>(null);
const option = computed(() => getOption());
// function resize() {
// chart.value.myChart.resize();
// }
function getOption() {
const keys = Object.keys(props.data || {}).filter(
(i: any) => Array.isArray(props.data[i]) && props.data[i].length