Compare commits

...

5 Commits

5 changed files with 14 additions and 8 deletions

View File

@ -1,5 +1,5 @@
<template>
<div>
<div ref="vChartRef">
<n-countdown
ref="countdownRef"
:duration="totalDuration"
@ -79,6 +79,8 @@ import { CreateComponentType } from '@/packages/index.d'
import { Flipper } from '@/components/Pages/Flipper'
import { OptionType } from './config'
import { CountdownInst, CountdownProps } from 'naive-ui/es/countdown/src/Countdown'
import { useChartDataFetch } from '@/hooks'
import { useChartEditStore } from '@/store/modules/chartEditStore/chartEditStore'
const props = defineProps({
chartConfig: {
@ -174,6 +176,10 @@ watch(
onMounted(() => {
updateTotalDuration()
})
const { vChartRef } = useChartDataFetch(props.chartConfig, useChartEditStore, (newData: any) => {
props.chartConfig.option.dataset = newData
})
</script>
<style lang="scss" scoped>

View File

@ -27,9 +27,9 @@ export type ConfigType = {
// 标题
title: string
// 分类
category: ChatCategoryEnum
category: string
// 分类名称
categoryName: ChatCategoryEnumName
categoryName: string
// 所属包
package: PackagesCategoryEnum
// 归类

View File

@ -286,8 +286,7 @@ export const JSONStringify = <T>(data: T) => {
return null
}
return val
},
2
}
)
}

View File

@ -166,7 +166,7 @@ const btnList = [
},
{
key: 'preview',
title: () => '预览',
title: () => '本地预览',
type: () => 'default',
icon: renderIcon(BrowsersOutlineIcon),
event: previewHandle

View File

@ -122,7 +122,8 @@ const selectOptions = ref([
{
label: renderLang('global.r_preview'),
key: 'preview',
icon: renderIcon(BrowsersOutlineIcon)
icon: renderIcon(BrowsersOutlineIcon),
show: props.cardData?.release
},
{
label: props.cardData?.release
@ -136,7 +137,7 @@ const selectOptions = ref([
key: 'delete',
icon: renderIcon(TrashIcon)
}
])
].filter(item => item.show !== false))
const handleSelect = (key: string) => {
switch (key) {