commit | author | age
|
9bcb19
|
1 |
<template> |
I |
2 |
<div :class="prefixCls"> |
|
3 |
<div class="chart-wrapper" :style="{ height: 46 }"> |
|
4 |
<v-chart :force-fit="true" :height="100" :data="dataSource" :scale="scale" :padding="[36, 0, 18, 0]"> |
|
5 |
<v-tooltip /> |
|
6 |
<v-smooth-line position="x*y" :size="2" /> |
|
7 |
<v-smooth-area position="x*y" /> |
|
8 |
</v-chart> |
|
9 |
</div> |
|
10 |
</div> |
|
11 |
</template> |
|
12 |
|
|
13 |
<script> |
|
14 |
export default { |
|
15 |
name: 'MiniSmoothArea', |
|
16 |
props: { |
|
17 |
prefixCls: { |
|
18 |
type: String, |
|
19 |
default: 'ant-pro-smooth-area' |
|
20 |
}, |
|
21 |
scale: { |
|
22 |
type: [Object, Array], |
|
23 |
required: true |
|
24 |
}, |
|
25 |
dataSource: { |
|
26 |
type: Array, |
|
27 |
required: true |
|
28 |
} |
|
29 |
}, |
|
30 |
data () { |
|
31 |
return { |
|
32 |
height: 100 |
|
33 |
} |
|
34 |
} |
|
35 |
} |
|
36 |
</script> |
|
37 |
|
|
38 |
<style lang="less" scoped> |
|
39 |
@import "smooth.area.less"; |
|
40 |
</style> |