diff --git a/src/address-list/index.ts b/src/address-list/index.ts index 67c15a349..5167b65fe 100644 --- a/src/address-list/index.ts +++ b/src/address-list/index.ts @@ -5,3 +5,4 @@ const AddressList = withInstall(_AddressList); export default AddressList; export { AddressList }; +export type { AddressListAddress } from './AddressListItem'; diff --git a/src/cascader/Cascader.tsx b/src/cascader/Cascader.tsx index 7deb79ff1..5319cae7f 100644 --- a/src/cascader/Cascader.tsx +++ b/src/cascader/Cascader.tsx @@ -21,7 +21,7 @@ type CascaderTab = { selectedOption: CascaderOption | null; }; -type CascaderFieldNames = { +export type CascaderFieldNames = { text?: string; value?: string; children?: string; diff --git a/src/cascader/index.ts b/src/cascader/index.ts index e55e0e44b..3b0c72cf2 100644 --- a/src/cascader/index.ts +++ b/src/cascader/index.ts @@ -5,4 +5,4 @@ const Cascader = withInstall(_Cascader); export default Cascader; export { Cascader }; -export type { CascaderOption } from './Cascader'; +export type { CascaderOption, CascaderFieldNames } from './Cascader'; diff --git a/src/list/List.tsx b/src/list/List.tsx index 0055ee318..cf941801a 100644 --- a/src/list/List.tsx +++ b/src/list/List.tsx @@ -20,6 +20,8 @@ import { Loading } from '../loading'; const [name, bem, t] = createNamespace('list'); +export type ListDirection = 'up' | 'down'; + export default defineComponent({ name, @@ -36,7 +38,7 @@ export default defineComponent({ default: 300, }, direction: { - type: String as PropType<'up' | 'down'>, + type: String as PropType, default: 'down', }, }, diff --git a/src/list/index.ts b/src/list/index.ts index 3e19f402f..461728b17 100644 --- a/src/list/index.ts +++ b/src/list/index.ts @@ -5,3 +5,4 @@ const List = withInstall(_List); export default List; export { List }; +export type { ListDirection } from './List'; diff --git a/src/number-keyboard/index.ts b/src/number-keyboard/index.ts index 5e952d2e1..4130adeda 100644 --- a/src/number-keyboard/index.ts +++ b/src/number-keyboard/index.ts @@ -5,3 +5,4 @@ const NumberKeyboard = withInstall(_NumberKeyboard); export default NumberKeyboard; export { NumberKeyboard }; +export type { NumberKeyboardTheme } from './NumberKeyboard'; diff --git a/src/pagination/Pagination.tsx b/src/pagination/Pagination.tsx index 79ea06206..6e953d894 100644 --- a/src/pagination/Pagination.tsx +++ b/src/pagination/Pagination.tsx @@ -1,6 +1,6 @@ +import { computed, watch, PropType, defineComponent } from 'vue'; import { createNamespace } from '../utils'; import { BORDER } from '../utils/constant'; -import { computed, watch, defineComponent } from 'vue'; const [name, bem, t] = createNamespace('pagination'); @@ -18,6 +18,8 @@ function makePage( return { number, text, active }; } +export type PaginationMode = 'simple' | 'multi'; + export default defineComponent({ name, @@ -26,7 +28,7 @@ export default defineComponent({ nextText: String, forceEllipses: Boolean, mode: { - type: String, + type: String as PropType, default: 'multi', }, modelValue: { diff --git a/src/pagination/index.ts b/src/pagination/index.ts index 5ce3213c6..a45056a67 100644 --- a/src/pagination/index.ts +++ b/src/pagination/index.ts @@ -5,3 +5,4 @@ const Pagination = withInstall(_Pagination); export default Pagination; export { Pagination }; +export type { PaginationMode } from './Pagination'; diff --git a/src/picker/index.ts b/src/picker/index.ts index cfc1ee1d2..2e75b82be 100644 --- a/src/picker/index.ts +++ b/src/picker/index.ts @@ -8,6 +8,7 @@ export { Picker }; export type { PickerColumn, PickerOption, + PickerFieldNames, PickerObjectColumn, PickerObjectOption, PickerToolbarPosition,