feat: 新增复制粘贴功能

This commit is contained in:
MTrun
2022-02-03 22:54:31 +08:00
parent 41711b174f
commit 47a7ce9d6e
22 changed files with 519 additions and 129 deletions
@@ -5,9 +5,9 @@ import { ConfigType, CreateComponentType } from '@/packages/index.d'
import omit from 'lodash/omit'
export default class Config implements CreateComponentType {
public id: string = getUUID()
public key: string = BarCommonConfig.key
public id = getUUID()
public key = BarCommonConfig.key
public rename = undefined
public chartData: Exclude<ConfigType, ['node']> = omit(BarCommonConfig, ['node'])
public attr = { x: 0, y: 0, w: 500, h: 300 }
+1
View File
@@ -16,6 +16,7 @@ export type ConfigType = {
export interface CreateComponentType {
id: string
key: string
rename?: string
attr: { x: number; y: number; w: number; h: number }
chartData: ConfigType
option: object