diff --git a/src/components/Form/src/props.ts b/src/components/Form/src/props.ts index bfdaee7e..a9eee16b 100644 --- a/src/components/Form/src/props.ts +++ b/src/components/Form/src/props.ts @@ -9,7 +9,7 @@ import { propTypes } from '/@/utils/propTypes'; export const basicProps = { model: { type: Object as PropType, - default: {}, + default: () => ({}), }, // 标签宽度 固定宽度 labelWidth: { diff --git a/src/components/Menu/src/props.ts b/src/components/Menu/src/props.ts index ed3f010d..5ad0dc03 100644 --- a/src/components/Menu/src/props.ts +++ b/src/components/Menu/src/props.ts @@ -41,7 +41,7 @@ export const basicProps = { export const itemProps = { item: { type: Object as PropType, - default: {}, + default: () => ({}), }, level: propTypes.number, theme: propTypes.oneOf(['dark', 'light']), diff --git a/src/components/Tinymce/src/Editor.vue b/src/components/Tinymce/src/Editor.vue index b84c5fbb..0ebc8a89 100644 --- a/src/components/Tinymce/src/Editor.vue +++ b/src/components/Tinymce/src/Editor.vue @@ -76,7 +76,7 @@ const tinymceProps = { options: { type: Object as PropType>, - default: {}, + default: () => ({}), }, value: { type: String, diff --git a/src/components/Upload/src/props.ts b/src/components/Upload/src/props.ts index 413b95d7..c10b7f40 100644 --- a/src/components/Upload/src/props.ts +++ b/src/components/Upload/src/props.ts @@ -27,7 +27,7 @@ export const basicProps = { }, uploadParams: { type: Object as PropType, - default: {}, + default: () => ({}), }, api: { type: Function as PropType, diff --git a/src/components/Verify/src/props.ts b/src/components/Verify/src/props.ts index 1e149703..d09a57ab 100644 --- a/src/components/Verify/src/props.ts +++ b/src/components/Verify/src/props.ts @@ -38,19 +38,19 @@ export const basicProps = { wrapStyle: { type: Object as PropType, - default: {}, + default: () => ({}), }, contentStyle: { type: Object as PropType, - default: {}, + default: () => ({}), }, barStyle: { type: Object as PropType, - default: {}, + default: () => ({}), }, actionStyle: { type: Object as PropType, - default: {}, + default: () => ({}), }, }; @@ -67,7 +67,7 @@ export const rotateProps = { imgWrapStyle: { type: Object as PropType, - default: {}, + default: () => ({}), }, minDegree: {