tiny-vue/examples/sites/demos/pc/app/chart/liquidfill/demo2-composition-api.vue

30 lines
551 B
Vue

<template>
<div>
<tiny-chart-liquidfill :data="chartData" :settings="chartSettings"></tiny-chart-liquidfill>
</div>
</template>
<script setup lang="jsx">
import { ref } from 'vue'
import { ChartLiquidfill as TinyChartLiquidfill } from '@opentiny/vue'
// 水球图分层
const chartData = ref({
columns: ['city', 'percent'],
rows: [
{
city: '上海',
percent: 0.7
}
]
})
const chartSettings = ref({
wave: [0.5, 0.3, 0.1],
seriesMap: {
上海: {
color: ['red', 'green', 'yellow']
}
}
})
</script>