mirror of
https://gitee.com/dromara/go-view.git
synced 2026-04-23 00:00:12 +08:00
fix: 新增全局滤镜
This commit is contained in:
@@ -16,7 +16,7 @@
|
||||
<script setup lang="ts">
|
||||
import { computed } from 'vue'
|
||||
import { PreviewRenderList } from './components/PreviewRenderList'
|
||||
import { getEditCanvasConfigStyle, getSessionStorageInfo } from './utils'
|
||||
import { getEditCanvasConfigStyle, getStyle, getSessionStorageInfo } from './utils'
|
||||
import { useComInstall } from './hooks/useComInstall.hook'
|
||||
import { useScale } from './hooks/useScale.hook'
|
||||
import { useStore } from './hooks/useStore.hook'
|
||||
@@ -25,7 +25,7 @@ import type { ChartEditStorageType } from './index.d'
|
||||
const localStorageInfo: ChartEditStorageType = getSessionStorageInfo() as ChartEditStorageType
|
||||
|
||||
const previewRefStyle: any = computed(() => {
|
||||
return getEditCanvasConfigStyle(localStorageInfo.editCanvasConfig)
|
||||
return { ...getEditCanvasConfigStyle(localStorageInfo.editCanvasConfig), ...getStyle(localStorageInfo.editCanvasConfig) }
|
||||
})
|
||||
|
||||
useStore(localStorageInfo)
|
||||
|
||||
@@ -45,7 +45,7 @@ export const animationsClass = (animations: string[]) => {
|
||||
}
|
||||
|
||||
// 样式
|
||||
export const getStyle = (styles: StylesType) => {
|
||||
export const getStyle = (styles: StylesType | EditCanvasConfigType) => {
|
||||
const { opacity, saturate, contrast, hueRotate, brightness } = styles
|
||||
return {
|
||||
// 透明度
|
||||
|
||||
Reference in New Issue
Block a user