37 lines
829 B
Vue
Raw Normal View History

2022-01-06 13:45:51 +08:00
<template>
2022-01-08 21:01:52 +08:00
<ContentBox
class="go-content-charts"
:class="{ scoped: !getCharts }"
title="图表"
:depth="2"
:backIcon="getCharts"
>
<template #icon>
<n-icon size="14" :depth="2">
<component :is="BarChartIcon" />
</n-icon>
</template>
2022-01-06 13:45:51 +08:00
</ContentBox>
</template>
<script setup lang="ts">
2022-01-08 21:01:52 +08:00
import { toRefs } from 'vue'
2022-01-06 13:45:51 +08:00
import { icon } from '@/plugins'
2022-01-08 21:01:52 +08:00
const { BarChartIcon } = icon.ionicons5
2022-01-06 13:45:51 +08:00
import { ContentBox } from '../ContentBox/index'
2022-01-08 21:01:52 +08:00
import { useChartLayoutStore } from '@/store/modules/chartLayoutStore/chartLayoutStore'
const { getCharts } = toRefs(useChartLayoutStore())
2022-01-06 13:45:51 +08:00
</script>
<style lang="scss" scoped>
2022-01-08 21:01:52 +08:00
$wight: 300px;
$wightScoped: 80px;
2022-01-06 13:45:51 +08:00
@include go(content-charts) {
width: $wight;
2022-01-08 21:01:52 +08:00
@extend .go-transition;
&.scoped {
width: $wightScoped;
}
2022-01-06 13:45:51 +08:00
}
</style>