diff --git a/packages/nutui/components/textarea/index.ts b/packages/nutui/components/textarea/index.ts index 78f0f959..b73e08b3 100644 --- a/packages/nutui/components/textarea/index.ts +++ b/packages/nutui/components/textarea/index.ts @@ -1 +1,2 @@ export * from './textarea' +export * from './type' diff --git a/packages/nutui/components/textarea/textarea.ts b/packages/nutui/components/textarea/textarea.ts index 25c6cd27..a366bc02 100644 --- a/packages/nutui/components/textarea/textarea.ts +++ b/packages/nutui/components/textarea/textarea.ts @@ -2,7 +2,7 @@ import type { ExtractPropTypes, PropType } from 'vue' import { commonProps, isString, makeNumberProp, makeStringProp, truthProp } from '../_utils' import { BLUR_EVENT, CHANGE_EVENT, CONFIRM_EVENT, FOCUS_EVENT, UPDATE_MODEL_EVENT } from '../_constants' import type { InputAlignType } from '../input' -import type { TextareaAdjustKeyboardTo, TextareaConfirmType } from './type' +import type { TextareaAdjustKeyboardTo, TextareaAutosizeObject, TextareaConfirmType } from './type' export const textareaProps = { ...commonProps, @@ -50,7 +50,7 @@ export const textareaProps = { * @description 是否自适应内容高度,也可传入对象 */ autosize: { - type: [Boolean, Object], + type: [Boolean, Object as PropType], default: false, }, /** diff --git a/packages/nutui/components/textarea/textarea.vue b/packages/nutui/components/textarea/textarea.vue index 86597115..b14eca39 100644 --- a/packages/nutui/components/textarea/textarea.vue +++ b/packages/nutui/components/textarea/textarea.vue @@ -1,4 +1,3 @@ -