From f1717973c44be7e2a4cdbee0833529ac1cd92dc9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=89=8D=E7=AB=AF=E7=88=B1=E7=A0=81=E5=A3=AB?= Date: Wed, 18 Jan 2023 11:16:43 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BF=AE=E5=A4=8Dprops=E4=B8=ADArray?= =?UTF-8?q?=E7=B1=BB=E5=9E=8B=E5=AE=9A=E4=B9=89=E9=97=AE=E9=A2=98=20(#2491?= =?UTF-8?q?)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/Dropdown/src/Dropdown.vue | 2 +- src/components/Form/src/props.ts | 2 +- src/components/Preview/src/Functional.vue | 2 +- src/components/Table/src/props.ts | 2 +- src/components/Upload/src/props.ts | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/components/Dropdown/src/Dropdown.vue b/src/components/Dropdown/src/Dropdown.vue index c70a99ef..afc2b794 100644 --- a/src/components/Dropdown/src/Dropdown.vue +++ b/src/components/Dropdown/src/Dropdown.vue @@ -57,7 +57,7 @@ * @type string[] */ trigger: { - type: [Array] as PropType<('contextmenu' | 'click' | 'hover')[]>, + type: Array as PropType<('contextmenu' | 'click' | 'hover')[]>, default: () => { return ['contextmenu']; }, diff --git a/src/components/Form/src/props.ts b/src/components/Form/src/props.ts index ae1b9219..f3f6a2e4 100644 --- a/src/components/Form/src/props.ts +++ b/src/components/Form/src/props.ts @@ -23,7 +23,7 @@ export const basicProps = { compact: propTypes.bool, // 表单配置规则 schemas: { - type: [Array] as PropType, + type: Array as PropType, default: () => [], }, mergeDynamicData: { diff --git a/src/components/Preview/src/Functional.vue b/src/components/Preview/src/Functional.vue index 2fcf7e39..1894209c 100644 --- a/src/components/Preview/src/Functional.vue +++ b/src/components/Preview/src/Functional.vue @@ -30,7 +30,7 @@ default: false, }, imageList: { - type: [Array] as PropType, + type: Array as PropType, default: null, }, index: { diff --git a/src/components/Table/src/props.ts b/src/components/Table/src/props.ts index 20e02098..a37541bf 100644 --- a/src/components/Table/src/props.ts +++ b/src/components/Table/src/props.ts @@ -84,7 +84,7 @@ export const basicProps = { default: null, }, columns: { - type: [Array] as PropType, + type: Array as PropType, default: () => [], }, showIndexColumn: { type: Boolean, default: true }, diff --git a/src/components/Upload/src/props.ts b/src/components/Upload/src/props.ts index c10b7f40..d37f68bd 100644 --- a/src/components/Upload/src/props.ts +++ b/src/components/Upload/src/props.ts @@ -69,7 +69,7 @@ export const previewProps = { export const fileListProps = { columns: { - type: [Array] as PropType, + type: Array as PropType, default: null, }, actionColumn: {