@aifuxi/semi-ui-vue 0.1.0-alpha.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +22 -0
- package/dist/Button-RCaDTqHh.js +249 -0
- package/dist/Collapsible-DeV0aJ4n.js +199 -0
- package/dist/Cropper-Dy1LPBDN.js +587 -0
- package/dist/Divider-BQmwhGfH.js +57 -0
- package/dist/Input-BYWFIgNn.js +593 -0
- package/dist/InputNumber-BaeViVtG.js +856 -0
- package/dist/Modal-BhmFYVFw.js +975 -0
- package/dist/Pagination-4JvS-gHR.js +572 -0
- package/dist/Progress-BulSV_JR.js +523 -0
- package/dist/SBOM.spdx.json +165 -0
- package/dist/SelectOption-Ce-Lst-e.js +1473 -0
- package/dist/Slider-w9sbxzBw.js +707 -0
- package/dist/Spin-CuFLkqev.js +222 -0
- package/dist/THIRD_PARTY_LICENSES/Semi-Design.txt +83 -0
- package/dist/THIRD_PARTY_LICENSES/async-validator.txt +9 -0
- package/dist/THIRD_PARTY_LICENSES/bezier-easing.txt +22 -0
- package/dist/THIRD_PARTY_LICENSES/date-fns-tz.txt +21 -0
- package/dist/THIRD_PARTY_LICENSES/date-fns.txt +21 -0
- package/dist/THIRD_PARTY_LICENSES/lodash.txt +47 -0
- package/dist/THIRD_PARTY_LICENSES/scroll-into-view-if-needed.txt +21 -0
- package/dist/THIRD_PARTY_NOTICES.md +23 -0
- package/dist/Tooltip-Bq7HZwnS.js +1321 -0
- package/dist/Tree-tqy5xBYJ.js +1275 -0
- package/dist/_plugin-vue_export-helper-B3ysoDQm.js +8 -0
- package/dist/anchor/Anchor.vue.d.ts +29 -0
- package/dist/anchor/AnchorLink.vue.d.ts +16 -0
- package/dist/anchor/AnchorNodeRenderer.d.ts +15 -0
- package/dist/anchor/anchor-context.d.ts +18 -0
- package/dist/anchor/index.d.ts +11 -0
- package/dist/anchor/index.js +2 -0
- package/dist/anchor/types.d.ts +43 -0
- package/dist/anchor-DW0p2t-I.js +503 -0
- package/dist/arrayMove-ByVCXfhS.js +7 -0
- package/dist/auto-complete/AutoComplete.vue.d.ts +33 -0
- package/dist/auto-complete/AutoCompleteNodeRenderer.d.ts +15 -0
- package/dist/auto-complete/AutoCompleteOption.vue.d.ts +19 -0
- package/dist/auto-complete/index.d.ts +10 -0
- package/dist/auto-complete/index.js +2 -0
- package/dist/auto-complete/types.d.ts +117 -0
- package/dist/auto-complete/use-auto-complete-foundation.d.ts +40 -0
- package/dist/auto-complete-BeahBlt9.js +765 -0
- package/dist/avatar/Avatar.vue.d.ts +26 -0
- package/dist/avatar/AvatarGroup.d.ts +54 -0
- package/dist/avatar/AvatarNodeRenderer.d.ts +15 -0
- package/dist/avatar/TopSlotSvg.vue.d.ts +7 -0
- package/dist/avatar/index.d.ts +10 -0
- package/dist/avatar/index.js +2 -0
- package/dist/avatar/types.d.ts +86 -0
- package/dist/avatar-B00xjEzD.js +551 -0
- package/dist/back-top/BackTop.vue.d.ts +19 -0
- package/dist/back-top/index.d.ts +3 -0
- package/dist/back-top/index.js +2 -0
- package/dist/back-top/types.d.ts +15 -0
- package/dist/back-top-C2XqUzoN.js +123 -0
- package/dist/badge/Badge.vue.d.ts +23 -0
- package/dist/badge/BadgeNodeRenderer.d.ts +15 -0
- package/dist/badge/index.d.ts +6 -0
- package/dist/badge/index.js +2 -0
- package/dist/badge/types.d.ts +29 -0
- package/dist/badge-gWsDkzyt.js +120 -0
- package/dist/banner/Banner.vue.d.ts +19 -0
- package/dist/banner/BannerNodeRenderer.d.ts +15 -0
- package/dist/banner/index.d.ts +6 -0
- package/dist/banner/index.js +2 -0
- package/dist/banner/types.d.ts +25 -0
- package/dist/banner-B3O4uDoR.js +220 -0
- package/dist/breadcrumb/Breadcrumb.d.ts +129 -0
- package/dist/breadcrumb/BreadcrumbIconRenderer.d.ts +23 -0
- package/dist/breadcrumb/BreadcrumbItem.vue.d.ts +19 -0
- package/dist/breadcrumb/BreadcrumbNodeRenderer.d.ts +15 -0
- package/dist/breadcrumb/BreadcrumbPopover.vue.d.ts +17 -0
- package/dist/breadcrumb/BreadcrumbPopoverArrow.vue.d.ts +3 -0
- package/dist/breadcrumb/breadcrumb-context.d.ts +9 -0
- package/dist/breadcrumb/index.d.ts +11 -0
- package/dist/breadcrumb/index.js +2 -0
- package/dist/breadcrumb/types.d.ts +72 -0
- package/dist/breadcrumb-BmBbFmGK.js +451 -0
- package/dist/button/Button.vue.d.ts +34 -0
- package/dist/button/ButtonAiLoadingIcon.vue.d.ts +3 -0
- package/dist/button/ButtonGroup.d.ts +69 -0
- package/dist/button/ButtonIconRenderer.d.ts +28 -0
- package/dist/button/ButtonLoadingIcon.vue.d.ts +3 -0
- package/dist/button/SplitButtonGroup.vue.d.ts +16 -0
- package/dist/button/index.d.ts +5 -0
- package/dist/button/index.js +3 -0
- package/dist/button/types.d.ts +57 -0
- package/dist/button-Rcn5pYGh.js +134 -0
- package/dist/calendar/Calendar.vue.d.ts +29 -0
- package/dist/calendar/CalendarDay.vue.d.ts +3 -0
- package/dist/calendar/CalendarMonth.vue.d.ts +3 -0
- package/dist/calendar/CalendarNodeRenderer.d.ts +15 -0
- package/dist/calendar/CalendarTimeColumn.vue.d.ts +6 -0
- package/dist/calendar/CalendarWeek.vue.d.ts +8 -0
- package/dist/calendar/index.d.ts +6 -0
- package/dist/calendar/index.js +2 -0
- package/dist/calendar/types.d.ts +67 -0
- package/dist/calendar-CJTrr4y5.js +1172 -0
- package/dist/card/Card.vue.d.ts +16 -0
- package/dist/card/CardGroup.vue.d.ts +13 -0
- package/dist/card/CardMeta.vue.d.ts +11 -0
- package/dist/card/CardNodeRenderer.d.ts +15 -0
- package/dist/card/CardSkeleton.vue.d.ts +3 -0
- package/dist/card/card-content.d.ts +2 -0
- package/dist/card/index.d.ts +11 -0
- package/dist/card/index.js +2 -0
- package/dist/card/types.d.ts +56 -0
- package/dist/card-DwMOFi6_.js +348 -0
- package/dist/carousel/Carousel.vue.d.ts +29 -0
- package/dist/carousel/CarouselArrow.vue.d.ts +15 -0
- package/dist/carousel/CarouselIndicator.vue.d.ts +17 -0
- package/dist/carousel/CarouselItemRenderer.d.ts +34 -0
- package/dist/carousel/CarouselNodeRenderer.d.ts +15 -0
- package/dist/carousel/index.d.ts +6 -0
- package/dist/carousel/index.js +2 -0
- package/dist/carousel/types.d.ts +70 -0
- package/dist/carousel/use-carousel-foundation.d.ts +19 -0
- package/dist/carousel-B4WlIRJH.js +458 -0
- package/dist/cascader/Cascader.vue.d.ts +71 -0
- package/dist/cascader/CascaderNodeRenderer.d.ts +15 -0
- package/dist/cascader/CascaderPanel.vue.d.ts +36 -0
- package/dist/cascader/index.d.ts +6 -0
- package/dist/cascader/index.js +2 -0
- package/dist/cascader/types.d.ts +192 -0
- package/dist/cascader-Ch6clCeh.js +1525 -0
- package/dist/checkbox/Checkbox.vue.d.ts +19 -0
- package/dist/checkbox/CheckboxGroup.d.ts +161 -0
- package/dist/checkbox/CheckboxNodeRenderer.d.ts +15 -0
- package/dist/checkbox/checkbox-context.d.ts +11 -0
- package/dist/checkbox/index.d.ts +10 -0
- package/dist/checkbox/index.js +2 -0
- package/dist/checkbox/types.d.ts +92 -0
- package/dist/checkbox-mJD1ou6k.js +479 -0
- package/dist/collapse/Collapse.vue.d.ts +140 -0
- package/dist/collapse/CollapseNodeRenderer.d.ts +15 -0
- package/dist/collapse/CollapsePanel.vue.d.ts +99 -0
- package/dist/collapse/collapse-context.d.ts +14 -0
- package/dist/collapse/index.d.ts +10 -0
- package/dist/collapse/index.js +2 -0
- package/dist/collapse/types.d.ts +50 -0
- package/dist/collapse-7YtQLWqt.js +278 -0
- package/dist/collapsible/Collapsible.vue.d.ts +136 -0
- package/dist/collapsible/index.d.ts +5 -0
- package/dist/collapsible/index.js +5 -0
- package/dist/collapsible/types.d.ts +28 -0
- package/dist/color-picker/AlphaSlider.vue.d.ts +14 -0
- package/dist/color-picker/ColorChooseArea.vue.d.ts +20 -0
- package/dist/color-picker/ColorDataPart.vue.d.ts +15 -0
- package/dist/color-picker/ColorPicker.vue.d.ts +28 -0
- package/dist/color-picker/ColorPickerNodeRenderer.d.ts +17 -0
- package/dist/color-picker/ColorPickerPanel.vue.d.ts +37 -0
- package/dist/color-picker/ColorSlider.vue.d.ts +13 -0
- package/dist/color-picker/index.d.ts +10 -0
- package/dist/color-picker/index.js +2 -0
- package/dist/color-picker/types.d.ts +67 -0
- package/dist/color-picker-ChC7qsx0.js +885 -0
- package/dist/config-context-CyynTtDb.js +4 -0
- package/dist/config-provider/ConfigConsumer.vue.d.ts +11 -0
- package/dist/config-provider/ConfigProvider.vue.d.ts +16 -0
- package/dist/config-provider/config-context.d.ts +3 -0
- package/dist/config-provider/constants.d.ts +4 -0
- package/dist/config-provider/index.d.ts +13 -0
- package/dist/config-provider/index.js +3 -0
- package/dist/config-provider/semi-global.d.ts +6 -0
- package/dist/config-provider/types.d.ts +74 -0
- package/dist/config-provider/use-responsive-observe.d.ts +6 -0
- package/dist/config-provider-VMfNNSF1.js +188 -0
- package/dist/constants-BF9bZJyc.js +45 -0
- package/dist/constants-BNwzO87W.js +9 -0
- package/dist/cropper/Cropper.vue.d.ts +18 -0
- package/dist/cropper/index.d.ts +4 -0
- package/dist/cropper/index.js +5 -0
- package/dist/cropper/types.d.ts +51 -0
- package/dist/date-picker/DatePicker.vue.d.ts +41 -0
- package/dist/date-picker/DatePickerMonth.vue.d.ts +25 -0
- package/dist/date-picker/DatePickerNodeRenderer.d.ts +17 -0
- package/dist/date-picker/DatePickerPanel.vue.d.ts +33 -0
- package/dist/date-picker/index.d.ts +5 -0
- package/dist/date-picker/index.js +2 -0
- package/dist/date-picker/types.d.ts +211 -0
- package/dist/date-picker-B2lhlKHD.js +2207 -0
- package/dist/descriptions/Descriptions.vue.d.ts +96 -0
- package/dist/descriptions/DescriptionsItem.vue.d.ts +96 -0
- package/dist/descriptions/DescriptionsNodeRenderer.d.ts +15 -0
- package/dist/descriptions/descriptions-context.d.ts +7 -0
- package/dist/descriptions/index.d.ts +10 -0
- package/dist/descriptions/index.js +2 -0
- package/dist/descriptions/types.d.ts +45 -0
- package/dist/descriptions-BU6ahbge.js +272 -0
- package/dist/divider/Divider.vue.d.ts +15 -0
- package/dist/divider/DividerContentRenderer.d.ts +17 -0
- package/dist/divider/index.d.ts +3 -0
- package/dist/divider/index.js +3 -0
- package/dist/divider/types.d.ts +13 -0
- package/dist/divider-DA9U4uOl.js +8 -0
- package/dist/dropdown/Dropdown.vue.d.ts +23 -0
- package/dist/dropdown/DropdownDivider.vue.d.ts +4 -0
- package/dist/dropdown/DropdownItem.vue.d.ts +28 -0
- package/dist/dropdown/DropdownMenu.vue.d.ts +11 -0
- package/dist/dropdown/DropdownNodeRenderer.d.ts +15 -0
- package/dist/dropdown/DropdownTitle.vue.d.ts +11 -0
- package/dist/dropdown/DropdownTriggerRenderer.d.ts +45 -0
- package/dist/dropdown/dropdown-context.d.ts +8 -0
- package/dist/dropdown/index.d.ts +17 -0
- package/dist/dropdown/index.js +2 -0
- package/dist/dropdown/types.d.ts +98 -0
- package/dist/dropdown-D0-UWd65.js +665 -0
- package/dist/empty/Empty.vue.d.ts +13 -0
- package/dist/empty/EmptyNodeRenderer.d.ts +15 -0
- package/dist/empty/index.d.ts +6 -0
- package/dist/empty/index.js +2 -0
- package/dist/empty/types.d.ts +27 -0
- package/dist/empty-Bpms8Z5w.js +152 -0
- package/dist/env-BeIzjQx7.js +4 -0
- package/dist/es-CAWQuPuV.js +93 -0
- package/dist/float-button/FloatButton.vue.d.ts +20 -0
- package/dist/float-button/FloatButtonBadge.vue.d.ts +18 -0
- package/dist/float-button/FloatButtonGroup.vue.d.ts +17 -0
- package/dist/float-button/FloatButtonNodeRenderer.d.ts +17 -0
- package/dist/float-button/index.d.ts +4 -0
- package/dist/float-button/index.js +2 -0
- package/dist/float-button/types.d.ts +59 -0
- package/dist/float-button-qU3b0WBX.js +190 -0
- package/dist/form/ArrayField.d.ts +24 -0
- package/dist/form/Form.vue.d.ts +38 -0
- package/dist/form/FormErrorMessage.vue.d.ts +4 -0
- package/dist/form/FormField.d.ts +9 -0
- package/dist/form/FormInputGroup.d.ts +62 -0
- package/dist/form/FormLabel.vue.d.ts +18 -0
- package/dist/form/FormNodeRenderer.d.ts +15 -0
- package/dist/form/FormSection.vue.d.ts +16 -0
- package/dist/form/FormSlot.d.ts +3 -0
- package/dist/form/form-context.d.ts +4 -0
- package/dist/form/index.d.ts +68 -0
- package/dist/form/index.js +3 -0
- package/dist/form/internal-types.d.ts +67 -0
- package/dist/form/types.d.ts +273 -0
- package/dist/form/use-form.d.ts +11 -0
- package/dist/form/with-form.d.ts +3 -0
- package/dist/form-CLhGuORQ.js +2030 -0
- package/dist/foundation-Cawx37mp.js +1819 -0
- package/dist/grid/Col.vue.d.ts +13 -0
- package/dist/grid/Row.vue.d.ts +14 -0
- package/dist/grid/grid-context.d.ts +6 -0
- package/dist/grid/index.d.ts +5 -0
- package/dist/grid/index.js +2 -0
- package/dist/grid/media-query.d.ts +2 -0
- package/dist/grid/types.d.ts +44 -0
- package/dist/grid-Cn2uBhRd.js +161 -0
- package/dist/highlight/Highlight.vue.d.ts +10 -0
- package/dist/highlight/HighlightNodeRenderer.d.ts +49 -0
- package/dist/highlight/index.d.ts +4 -0
- package/dist/highlight/index.js +2 -0
- package/dist/highlight/internal-types.d.ts +8 -0
- package/dist/highlight/types.d.ts +17 -0
- package/dist/highlight-DHX3RV0C.js +158 -0
- package/dist/icon/index.d.ts +2 -0
- package/dist/icon/index.js +2 -0
- package/dist/image/Image.vue.d.ts +21 -0
- package/dist/image/ImageNodeRenderer.d.ts +15 -0
- package/dist/image/ImagePreview.vue.d.ts +56 -0
- package/dist/image/ImagePreviewFooter.vue.d.ts +38 -0
- package/dist/image/ImagePreviewHeader.vue.d.ts +17 -0
- package/dist/image/ImagePreviewImage.vue.d.ts +27 -0
- package/dist/image/ImagePreviewInner.vue.d.ts +54 -0
- package/dist/image/image-context.d.ts +14 -0
- package/dist/image/index.d.ts +6 -0
- package/dist/image/index.js +2 -0
- package/dist/image/types.d.ts +183 -0
- package/dist/image-C-ifCh_9.js +1615 -0
- package/dist/index.d.ts +68 -0
- package/dist/index.js +75 -0
- package/dist/input/Input.vue.d.ts +58 -0
- package/dist/input/InputGroup.d.ts +69 -0
- package/dist/input/InputNodeRenderer.d.ts +15 -0
- package/dist/input/TextArea.vue.d.ts +50 -0
- package/dist/input/index.d.ts +11 -0
- package/dist/input/index.js +2 -0
- package/dist/input/types.d.ts +168 -0
- package/dist/input-number/InputNumber.vue.d.ts +52 -0
- package/dist/input-number/index.d.ts +10 -0
- package/dist/input-number/index.js +5 -0
- package/dist/input-number/types.d.ts +56 -0
- package/dist/input-wf0nZCRS.js +747 -0
- package/dist/isBefore-BG1hiM9f.js +37 -0
- package/dist/isElement-Cx0AsIov.js +11 -0
- package/dist/isEnterPress-HTy0eCBp.js +8 -0
- package/dist/isNullOrUndefined-Cg6MZ8r3.js +6 -0
- package/dist/isPromise-D2v3Ejff.js +11 -0
- package/dist/keyCode-DMNg63wX.js +110 -0
- package/dist/layout/Layout.vue.d.ts +14 -0
- package/dist/layout/LayoutContent.vue.d.ts +14 -0
- package/dist/layout/LayoutFooter.vue.d.ts +14 -0
- package/dist/layout/LayoutHeader.vue.d.ts +14 -0
- package/dist/layout/LayoutSection.vue.d.ts +17 -0
- package/dist/layout/LayoutSider.vue.d.ts +18 -0
- package/dist/layout/index.d.ts +17 -0
- package/dist/layout/index.js +2 -0
- package/dist/layout/layout-context.d.ts +6 -0
- package/dist/layout/media-query.d.ts +4 -0
- package/dist/layout/types.d.ts +31 -0
- package/dist/layout-tq-_l_O3.js +171 -0
- package/dist/list/List.vue.d.ts +22 -0
- package/dist/list/ListItem.vue.d.ts +88 -0
- package/dist/list/ListNodeRenderer.d.ts +15 -0
- package/dist/list/ListSpin.vue.d.ts +16 -0
- package/dist/list/index.d.ts +10 -0
- package/dist/list/index.js +2 -0
- package/dist/list/list-context.d.ts +8 -0
- package/dist/list/types.d.ts +66 -0
- package/dist/list-DHIOE2Y-.js +387 -0
- package/dist/modal/ConfirmModal.vue.d.ts +14 -0
- package/dist/modal/Modal.vue.d.ts +15 -0
- package/dist/modal/ModalDefaultFooter.vue.d.ts +22 -0
- package/dist/modal/ModalDialog.vue.d.ts +53 -0
- package/dist/modal/ModalInnerContent.vue.d.ts +38 -0
- package/dist/modal/ModalNodeRenderer.d.ts +15 -0
- package/dist/modal/imperative.d.ts +9 -0
- package/dist/modal/index.d.ts +8 -0
- package/dist/modal/index.js +2 -0
- package/dist/modal/types.d.ts +92 -0
- package/dist/modal/use-modal.d.ts +2 -0
- package/dist/modal-YVolL7Hz.js +221 -0
- package/dist/navigation/CollapseButton.vue.d.ts +12 -0
- package/dist/navigation/NavFooter.vue.d.ts +15 -0
- package/dist/navigation/NavHeader.vue.d.ts +13 -0
- package/dist/navigation/NavItem.d.ts +177 -0
- package/dist/navigation/Navigation.vue.d.ts +29 -0
- package/dist/navigation/NavigationContextProvider.d.ts +16 -0
- package/dist/navigation/NavigationIconRenderer.d.ts +45 -0
- package/dist/navigation/NavigationItemTree.vue.d.ts +8 -0
- package/dist/navigation/NavigationNodeRenderer.d.ts +18 -0
- package/dist/navigation/SubNav.vue.d.ts +18 -0
- package/dist/navigation/index.d.ts +14 -0
- package/dist/navigation/index.js +2 -0
- package/dist/navigation/navigation-context.d.ts +35 -0
- package/dist/navigation/types.d.ts +177 -0
- package/dist/navigation-DF8R5jFK.js +1479 -0
- package/dist/notification/NotificationHost.vue.d.ts +7 -0
- package/dist/notification/NotificationNodeRenderer.d.ts +15 -0
- package/dist/notification/NotificationNotice.vue.d.ts +16 -0
- package/dist/notification/imperative.d.ts +12 -0
- package/dist/notification/index.d.ts +6 -0
- package/dist/notification/index.js +2 -0
- package/dist/notification/notification-store.d.ts +24 -0
- package/dist/notification/types.d.ts +63 -0
- package/dist/notification/use-notification.d.ts +2 -0
- package/dist/notification-DIsvgiIO.js +445 -0
- package/dist/overflow-list/OverflowList.vue.d.ts +131 -0
- package/dist/overflow-list/OverflowListNodeRenderer.d.ts +35 -0
- package/dist/overflow-list/index.d.ts +5 -0
- package/dist/overflow-list/index.js +2 -0
- package/dist/overflow-list/types.d.ts +35 -0
- package/dist/overflow-list-Df6ixrtB.js +413 -0
- package/dist/pagination/Pagination.vue.d.ts +25 -0
- package/dist/pagination/PaginationNodeRenderer.d.ts +15 -0
- package/dist/pagination/PaginationPopover.vue.d.ts +25 -0
- package/dist/pagination/PaginationRestList.vue.d.ts +11 -0
- package/dist/pagination/index.d.ts +3 -0
- package/dist/pagination/index.js +2 -0
- package/dist/pagination/types.d.ts +46 -0
- package/dist/pin-code/PinCode.vue.d.ts +20 -0
- package/dist/pin-code/index.d.ts +10 -0
- package/dist/pin-code/index.js +2 -0
- package/dist/pin-code/types.d.ts +25 -0
- package/dist/pin-code-wY5g0KLD.js +193 -0
- package/dist/popconfirm/Popconfirm.vue.d.ts +25 -0
- package/dist/popconfirm/PopconfirmNodeRenderer.d.ts +15 -0
- package/dist/popconfirm/index.d.ts +4 -0
- package/dist/popconfirm/index.js +2 -0
- package/dist/popconfirm/types.d.ts +57 -0
- package/dist/popconfirm-DQUtvI0A.js +389 -0
- package/dist/popover/Popover.vue.d.ts +23 -0
- package/dist/popover/PopoverArrow.vue.d.ts +10 -0
- package/dist/popover/index.d.ts +4 -0
- package/dist/popover/index.js +2 -0
- package/dist/popover/types.d.ts +35 -0
- package/dist/popover-hD77YpUM.js +292 -0
- package/dist/progress/Progress.vue.d.ts +24 -0
- package/dist/progress/ProgressCircle.vue.d.ts +26 -0
- package/dist/progress/ProgressLine.vue.d.ts +23 -0
- package/dist/progress/ProgressNodeRenderer.d.ts +15 -0
- package/dist/progress/index.d.ts +6 -0
- package/dist/progress/index.js +2 -0
- package/dist/progress/types.d.ts +44 -0
- package/dist/progress-DIIyWKKD.js +9 -0
- package/dist/radio/Radio.vue.d.ts +30 -0
- package/dist/radio/RadioGroup.d.ts +201 -0
- package/dist/radio/RadioNodeRenderer.d.ts +15 -0
- package/dist/radio/index.d.ts +10 -0
- package/dist/radio/index.js +2 -0
- package/dist/radio/radio-context.d.ts +15 -0
- package/dist/radio/types.d.ts +100 -0
- package/dist/radio-y9iAI359.js +565 -0
- package/dist/rating/Rating.vue.d.ts +39 -0
- package/dist/rating/RatingItem.vue.d.ts +33 -0
- package/dist/rating/RatingNodeRenderer.d.ts +17 -0
- package/dist/rating/index.d.ts +6 -0
- package/dist/rating/index.js +2 -0
- package/dist/rating/types.d.ts +57 -0
- package/dist/rating-CJkb4pkD.js +542 -0
- package/dist/resizable/Resizable.vue.d.ts +31 -0
- package/dist/resizable/ResizableNodeRenderer.d.ts +17 -0
- package/dist/resizable/ResizeGroup.vue.d.ts +13 -0
- package/dist/resizable/ResizeHandler.vue.d.ts +11 -0
- package/dist/resizable/ResizeItem.vue.d.ts +19 -0
- package/dist/resizable/SingleResizeHandle.vue.d.ts +21 -0
- package/dist/resizable/index.d.ts +6 -0
- package/dist/resizable/index.js +2 -0
- package/dist/resizable/resizable-context.d.ts +27 -0
- package/dist/resizable/types.d.ts +87 -0
- package/dist/resizable/use-resize-group.d.ts +21 -0
- package/dist/resizable/use-single-resize.d.ts +30 -0
- package/dist/resizable-CEB0ZdGT.js +814 -0
- package/dist/scroll-list/ScrollItem.vue.d.ts +21 -0
- package/dist/scroll-list/ScrollList.vue.d.ts +11 -0
- package/dist/scroll-list/ScrollListNodeRenderer.d.ts +15 -0
- package/dist/scroll-list/index.d.ts +10 -0
- package/dist/scroll-list/index.js +2 -0
- package/dist/scroll-list/types.d.ts +54 -0
- package/dist/scroll-list-BSXksNOR.js +466 -0
- package/dist/select/Select.vue.d.ts +39 -0
- package/dist/select/SelectFragment.d.ts +4 -0
- package/dist/select/SelectNodeRenderer.d.ts +15 -0
- package/dist/select/SelectOption.vue.d.ts +13 -0
- package/dist/select/SelectOptionCollector.d.ts +13 -0
- package/dist/select/SelectOptionGroup.vue.d.ts +14 -0
- package/dist/select/index.d.ts +12 -0
- package/dist/select/index.js +3 -0
- package/dist/select/types.d.ts +165 -0
- package/dist/select/use-select-foundation.d.ts +64 -0
- package/dist/select-BeM6gxAU.js +40 -0
- package/dist/side-sheet/SideSheet.vue.d.ts +19 -0
- package/dist/side-sheet/SideSheetContent.vue.d.ts +37 -0
- package/dist/side-sheet/SideSheetNodeRenderer.d.ts +15 -0
- package/dist/side-sheet/index.d.ts +4 -0
- package/dist/side-sheet/index.js +2 -0
- package/dist/side-sheet/types.d.ts +46 -0
- package/dist/side-sheet-9CBTk23r.js +542 -0
- package/dist/skeleton/Skeleton.vue.d.ts +15 -0
- package/dist/skeleton/SkeletonAvatar.vue.d.ts +9 -0
- package/dist/skeleton/SkeletonButton.vue.d.ts +7 -0
- package/dist/skeleton/SkeletonImage.vue.d.ts +7 -0
- package/dist/skeleton/SkeletonNodeRenderer.d.ts +15 -0
- package/dist/skeleton/SkeletonParagraph.vue.d.ts +8 -0
- package/dist/skeleton/SkeletonTitle.vue.d.ts +7 -0
- package/dist/skeleton/index.d.ts +18 -0
- package/dist/skeleton/index.js +2 -0
- package/dist/skeleton/types.d.ts +36 -0
- package/dist/skeleton-p61lfhoz.js +302 -0
- package/dist/slider/Slider.vue.d.ts +32 -0
- package/dist/slider/SliderFragment.d.ts +4 -0
- package/dist/slider/index.d.ts +5 -0
- package/dist/slider/index.js +5 -0
- package/dist/slider/types.d.ts +57 -0
- package/dist/slider/use-slider-foundation.d.ts +47 -0
- package/dist/space/Space.vue.d.ts +16 -0
- package/dist/space/index.d.ts +3 -0
- package/dist/space/index.js +2 -0
- package/dist/space/types.d.ts +15 -0
- package/dist/space-DVnFbkCz.js +63 -0
- package/dist/spin/Spin.vue.d.ts +105 -0
- package/dist/spin/SpinNodeRenderer.d.ts +15 -0
- package/dist/spin/index.d.ts +6 -0
- package/dist/spin/index.js +2 -0
- package/dist/spin/types.d.ts +20 -0
- package/dist/spin-D-1P0WMW.js +9 -0
- package/dist/src-DNBBthjO.js +490 -0
- package/dist/steps/Step.vue.d.ts +22 -0
- package/dist/steps/Steps.vue.d.ts +24 -0
- package/dist/steps/StepsNodeRenderer.d.ts +17 -0
- package/dist/steps/index.d.ts +9 -0
- package/dist/steps/index.js +2 -0
- package/dist/steps/steps-context.d.ts +6 -0
- package/dist/steps/types.d.ts +54 -0
- package/dist/steps-6p04q-Lz.js +303 -0
- package/dist/switch/Switch.vue.d.ts +27 -0
- package/dist/switch/SwitchNodeRenderer.d.ts +15 -0
- package/dist/switch/SwitchSpin.vue.d.ts +7 -0
- package/dist/switch/index.d.ts +7 -0
- package/dist/switch/index.js +2 -0
- package/dist/switch/types.d.ts +28 -0
- package/dist/switch-Dte2Fl3l.js +284 -0
- package/dist/table/Table.vue.d.ts +29 -0
- package/dist/table/TableBody.vue.d.ts +70 -0
- package/dist/table/TableCell.vue.d.ts +37 -0
- package/dist/table/TableColumn.d.ts +81 -0
- package/dist/table/TableFilterMenu.vue.d.ts +18 -0
- package/dist/table/TableHeader.vue.d.ts +46 -0
- package/dist/table/TableNativeElement.d.ts +9 -0
- package/dist/table/TableNodeRenderer.d.ts +13 -0
- package/dist/table/TableSpin.vue.d.ts +16 -0
- package/dist/table/index.d.ts +13 -0
- package/dist/table/index.js +2 -0
- package/dist/table/table-utils.d.ts +43 -0
- package/dist/table/types.d.ts +323 -0
- package/dist/table-jZkHjf-W.js +2097 -0
- package/dist/tabs/TabBar.vue.d.ts +38 -0
- package/dist/tabs/TabItem.vue.d.ts +26 -0
- package/dist/tabs/TabPane.vue.d.ts +13 -0
- package/dist/tabs/Tabs.vue.d.ts +36 -0
- package/dist/tabs/TabsDropdown.vue.d.ts +27 -0
- package/dist/tabs/TabsNodeRenderer.d.ts +15 -0
- package/dist/tabs/index.d.ts +6 -0
- package/dist/tabs/index.js +2 -0
- package/dist/tabs/tabs-context.d.ts +12 -0
- package/dist/tabs/types.d.ts +110 -0
- package/dist/tabs-CezuYzIu.js +874 -0
- package/dist/tag/SplitTagGroup.d.ts +36 -0
- package/dist/tag/Tag.vue.d.ts +33 -0
- package/dist/tag/TagGroup.d.ts +115 -0
- package/dist/tag/TagNodeRenderer.d.ts +15 -0
- package/dist/tag/index.d.ts +8 -0
- package/dist/tag/index.js +2 -0
- package/dist/tag/types.d.ts +82 -0
- package/dist/tag-BPD0bELU.js +348 -0
- package/dist/tag-input/TagInput.vue.d.ts +51 -0
- package/dist/tag-input/TagInputNodeRenderer.d.ts +17 -0
- package/dist/tag-input/TagInputRestPopover.vue.d.ts +19 -0
- package/dist/tag-input/TagInputTag.vue.d.ts +27 -0
- package/dist/tag-input/index.d.ts +5 -0
- package/dist/tag-input/index.js +2 -0
- package/dist/tag-input/types.d.ts +95 -0
- package/dist/tag-input/use-tag-input-foundation.d.ts +47 -0
- package/dist/tag-input-SxUfNqF0.js +784 -0
- package/dist/time-picker/TimePicker.vue.d.ts +27 -0
- package/dist/time-picker/TimePickerColumn.vue.d.ts +29 -0
- package/dist/time-picker/TimePickerNodeRenderer.d.ts +17 -0
- package/dist/time-picker/TimePickerPanel.vue.d.ts +32 -0
- package/dist/time-picker/index.d.ts +5 -0
- package/dist/time-picker/index.js +2 -0
- package/dist/time-picker/types.d.ts +146 -0
- package/dist/time-picker/use-time-picker-foundation.d.ts +36 -0
- package/dist/time-picker-D6p36ea8.js +3587 -0
- package/dist/timeline/Timeline.vue.d.ts +69 -0
- package/dist/timeline/TimelineItem.vue.d.ts +100 -0
- package/dist/timeline/TimelineNodeRenderer.d.ts +15 -0
- package/dist/timeline/index.d.ts +10 -0
- package/dist/timeline/index.js +2 -0
- package/dist/timeline/types.d.ts +43 -0
- package/dist/timeline-2D5xCZsU.js +191 -0
- package/dist/toast/ToastHost.vue.d.ts +7 -0
- package/dist/toast/ToastIconRenderer.d.ts +17 -0
- package/dist/toast/ToastNodeRenderer.d.ts +15 -0
- package/dist/toast/ToastNotice.vue.d.ts +20 -0
- package/dist/toast/imperative.d.ts +3 -0
- package/dist/toast/index.d.ts +6 -0
- package/dist/toast/index.js +2 -0
- package/dist/toast/toast-store.d.ts +30 -0
- package/dist/toast/types.d.ts +65 -0
- package/dist/toast/use-toast.d.ts +2 -0
- package/dist/toast-s8nFLf8t.js +523 -0
- package/dist/tooltip/Tooltip.vue.d.ts +23 -0
- package/dist/tooltip/TooltipArrow.vue.d.ts +8 -0
- package/dist/tooltip/TooltipNodeRenderer.d.ts +15 -0
- package/dist/tooltip/TooltipPortal.vue.d.ts +44 -0
- package/dist/tooltip/TooltipTriggerRenderer.d.ts +66 -0
- package/dist/tooltip/index.d.ts +5 -0
- package/dist/tooltip/index.js +3 -0
- package/dist/tooltip/types.d.ts +117 -0
- package/dist/tooltip/use-tooltip-foundation.d.ts +25 -0
- package/dist/tooltip-en9bvXRp.js +28 -0
- package/dist/transfer/Transfer.vue.d.ts +35 -0
- package/dist/transfer/TransferNodeRenderer.d.ts +15 -0
- package/dist/transfer/index.d.ts +5 -0
- package/dist/transfer/index.js +2 -0
- package/dist/transfer/types.d.ts +159 -0
- package/dist/transfer-Doq1sI9z.js +695 -0
- package/dist/tree/Tree.vue.d.ts +73 -0
- package/dist/tree/TreeNode.vue.d.ts +77 -0
- package/dist/tree/TreeNodeMotion.vue.d.ts +20 -0
- package/dist/tree/TreeNodeRenderer.d.ts +15 -0
- package/dist/tree/index.d.ts +9 -0
- package/dist/tree/index.js +5 -0
- package/dist/tree/types.d.ts +180 -0
- package/dist/tree-select/TreeSelect.vue.d.ts +76 -0
- package/dist/tree-select/TreeSelectNodeRenderer.d.ts +15 -0
- package/dist/tree-select/index.d.ts +6 -0
- package/dist/tree-select/index.js +2 -0
- package/dist/tree-select/types.d.ts +156 -0
- package/dist/tree-select-BIu6Owuq.js +1237 -0
- package/dist/treeUtil-IUdRJ6Ws.js +277 -0
- package/dist/typography/Numeral.vue.d.ts +32 -0
- package/dist/typography/Paragraph.vue.d.ts +30 -0
- package/dist/typography/Text.vue.d.ts +30 -0
- package/dist/typography/Title.vue.d.ts +28 -0
- package/dist/typography/Typography.vue.d.ts +13 -0
- package/dist/typography/TypographyBase.vue.d.ts +40 -0
- package/dist/typography/TypographyCopyable.vue.d.ts +29 -0
- package/dist/typography/TypographyDecorations.d.ts +34 -0
- package/dist/typography/TypographyNodeRenderer.d.ts +17 -0
- package/dist/typography/index.d.ts +17 -0
- package/dist/typography/index.js +2 -0
- package/dist/typography/types.d.ts +108 -0
- package/dist/typography/typography-locale.d.ts +5 -0
- package/dist/typography/typography-utils.d.ts +4 -0
- package/dist/typography-DF8KwKuL.js +914 -0
- package/dist/upload/Upload.vue.d.ts +69 -0
- package/dist/upload/UploadFileCard.vue.d.ts +4 -0
- package/dist/upload/UploadNodeRenderer.d.ts +15 -0
- package/dist/upload/index.d.ts +10 -0
- package/dist/upload/index.js +2 -0
- package/dist/upload/types.d.ts +250 -0
- package/dist/upload-BzdpoGJX.js +1777 -0
- package/dist/uuid-BUHV1G8U.js +21 -0
- package/dist/warning-naSiE8G7.js +6 -0
- package/dist/zh-CN-CCu7YvUA.js +1623 -0
- package/package.json +336 -0
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { FormErrorMessageProps } from './types';
|
|
2
|
+
declare const __VLS_export: import('vue').DefineComponent<FormErrorMessageProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<FormErrorMessageProps> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
3
|
+
declare const _default: typeof __VLS_export;
|
|
4
|
+
export default _default;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { Component, VNode } from 'vue';
|
|
2
|
+
import { CommonFieldProps, FormFieldComponent, WithFieldOptions } from './types';
|
|
3
|
+
interface InternalWithFieldOptions extends WithFieldOptions {
|
|
4
|
+
shouldInjectByDefault?: boolean;
|
|
5
|
+
}
|
|
6
|
+
export declare function createFormField<Props extends object>(control: Component, options?: InternalWithFieldOptions): FormFieldComponent<Props & CommonFieldProps>;
|
|
7
|
+
export declare function isFormFieldVNode(value: unknown): value is VNode;
|
|
8
|
+
export declare const withField: typeof createFormField;
|
|
9
|
+
export {};
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
import { FormInputGroupProps } from './types';
|
|
2
|
+
declare const _default: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
|
|
3
|
+
disabled: {
|
|
4
|
+
type: BooleanConstructor;
|
|
5
|
+
default: undefined;
|
|
6
|
+
};
|
|
7
|
+
extraText: {
|
|
8
|
+
type: null;
|
|
9
|
+
default: undefined;
|
|
10
|
+
};
|
|
11
|
+
extraTextPosition: {
|
|
12
|
+
type: () => "bottom" | "middle";
|
|
13
|
+
default: string;
|
|
14
|
+
};
|
|
15
|
+
label: {
|
|
16
|
+
type: null;
|
|
17
|
+
default: undefined;
|
|
18
|
+
};
|
|
19
|
+
labelPosition: {
|
|
20
|
+
type: () => "left" | "top";
|
|
21
|
+
default: undefined;
|
|
22
|
+
};
|
|
23
|
+
size: {
|
|
24
|
+
type: () => FormInputGroupProps["size"];
|
|
25
|
+
default: string;
|
|
26
|
+
};
|
|
27
|
+
}>, (() => null) | (() => import('vue').VNode<import('vue').RendererNode, import('vue').RendererElement, {
|
|
28
|
+
[key: string]: any;
|
|
29
|
+
}>), {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
|
|
30
|
+
disabled: {
|
|
31
|
+
type: BooleanConstructor;
|
|
32
|
+
default: undefined;
|
|
33
|
+
};
|
|
34
|
+
extraText: {
|
|
35
|
+
type: null;
|
|
36
|
+
default: undefined;
|
|
37
|
+
};
|
|
38
|
+
extraTextPosition: {
|
|
39
|
+
type: () => "bottom" | "middle";
|
|
40
|
+
default: string;
|
|
41
|
+
};
|
|
42
|
+
label: {
|
|
43
|
+
type: null;
|
|
44
|
+
default: undefined;
|
|
45
|
+
};
|
|
46
|
+
labelPosition: {
|
|
47
|
+
type: () => "left" | "top";
|
|
48
|
+
default: undefined;
|
|
49
|
+
};
|
|
50
|
+
size: {
|
|
51
|
+
type: () => FormInputGroupProps["size"];
|
|
52
|
+
default: string;
|
|
53
|
+
};
|
|
54
|
+
}>> & Readonly<{}>, {
|
|
55
|
+
disabled: boolean;
|
|
56
|
+
size: import('..').InputSize | undefined;
|
|
57
|
+
label: any;
|
|
58
|
+
labelPosition: "left" | "top";
|
|
59
|
+
extraText: any;
|
|
60
|
+
extraTextPosition: "middle" | "bottom";
|
|
61
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
|
|
62
|
+
export default _default;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { FormLabelProps } from './types';
|
|
2
|
+
declare var __VLS_1: {};
|
|
3
|
+
type __VLS_Slots = {} & {
|
|
4
|
+
default?: (props: typeof __VLS_1) => any;
|
|
5
|
+
};
|
|
6
|
+
declare const __VLS_base: import('vue').DefineComponent<FormLabelProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<FormLabelProps> & Readonly<{}>, {
|
|
7
|
+
optional: boolean;
|
|
8
|
+
required: boolean;
|
|
9
|
+
align: import('./types').FormLabelAlign;
|
|
10
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
11
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
12
|
+
declare const _default: typeof __VLS_export;
|
|
13
|
+
export default _default;
|
|
14
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
15
|
+
new (): {
|
|
16
|
+
$slots: S;
|
|
17
|
+
};
|
|
18
|
+
};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { PropType, VNodeChild } from 'vue';
|
|
2
|
+
declare const _default: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
|
|
3
|
+
content: {
|
|
4
|
+
type: PropType<VNodeChild>;
|
|
5
|
+
default: undefined;
|
|
6
|
+
};
|
|
7
|
+
}>, () => VNodeChild, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
|
|
8
|
+
content: {
|
|
9
|
+
type: PropType<VNodeChild>;
|
|
10
|
+
default: undefined;
|
|
11
|
+
};
|
|
12
|
+
}>> & Readonly<{}>, {
|
|
13
|
+
content: VNodeChild;
|
|
14
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
|
|
15
|
+
export default _default;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { FormSectionProps } from './types';
|
|
2
|
+
declare var __VLS_1: {}, __VLS_8: {};
|
|
3
|
+
type __VLS_Slots = {} & {
|
|
4
|
+
text?: (props: typeof __VLS_1) => any;
|
|
5
|
+
} & {
|
|
6
|
+
default?: (props: typeof __VLS_8) => any;
|
|
7
|
+
};
|
|
8
|
+
declare const __VLS_base: import('vue').DefineComponent<FormSectionProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<FormSectionProps> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, any>;
|
|
9
|
+
declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
|
|
10
|
+
declare const _default: typeof __VLS_export;
|
|
11
|
+
export default _default;
|
|
12
|
+
type __VLS_WithSlots<T, S> = T & {
|
|
13
|
+
new (): {
|
|
14
|
+
$slots: S;
|
|
15
|
+
};
|
|
16
|
+
};
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
import { Component, DefineComponent } from 'vue';
|
|
2
|
+
import { default as FormErrorMessage } from './FormErrorMessage.vue';
|
|
3
|
+
import { createFormField, withField } from './FormField';
|
|
4
|
+
import { default as FormLabel } from './FormLabel.vue';
|
|
5
|
+
import { default as FormSection } from './FormSection.vue';
|
|
6
|
+
import { default as FormSlot } from './FormSlot';
|
|
7
|
+
import { ArrayFieldProps, FormAutoCompleteProps, FormCheckboxProps, FormFieldComponent, FormInputGroupProps, FormProps, FormRadioProps, FormSelectProps } from './types';
|
|
8
|
+
import { useFieldApi, useFieldState, useForm, useFormApi, useFormState } from './use-form';
|
|
9
|
+
import { withFormApi, withFormState } from './with-form';
|
|
10
|
+
export declare const FormInput: FormFieldComponent<Omit<import('..').InputProps, "value" | "defaultValue" | "modelValue"> & import('./types').CommonFieldProps>;
|
|
11
|
+
export declare const FormInputNumber: FormFieldComponent<Omit<import('..').InputNumberProps, "value" | "defaultValue" | "modelValue"> & import('./types').CommonFieldProps>;
|
|
12
|
+
export declare const FormTextArea: FormFieldComponent<Omit<import('..').TextAreaProps, "value" | "defaultValue" | "modelValue"> & import('./types').CommonFieldProps>;
|
|
13
|
+
export interface FormSelectComponent extends FormFieldComponent<FormSelectProps> {
|
|
14
|
+
Option: Component;
|
|
15
|
+
OptGroup: Component;
|
|
16
|
+
}
|
|
17
|
+
export declare const FormSelect: FormSelectComponent;
|
|
18
|
+
export declare const FormCheckboxGroup: FormFieldComponent<Omit<import('..').CheckboxGroupProps, "value" | "defaultValue" | "modelValue"> & import('./types').CommonFieldProps>;
|
|
19
|
+
export declare const FormCheckbox: FormFieldComponent<FormCheckboxProps>;
|
|
20
|
+
export declare const FormRadioGroup: FormFieldComponent<Omit<import('..').RadioGroupProps, "value" | "defaultValue" | "modelValue"> & import('./types').CommonFieldProps>;
|
|
21
|
+
export declare const FormRadio: FormFieldComponent<FormRadioProps>;
|
|
22
|
+
export declare const FormDatePicker: FormFieldComponent<Omit<import('..').DatePickerProps, "value" | "defaultValue" | "modelValue"> & import('./types').CommonFieldProps>;
|
|
23
|
+
export declare const FormSwitch: FormFieldComponent<Omit<import('..').SwitchProps, "modelValue" | "checked" | "defaultChecked"> & import('./types').CommonFieldProps>;
|
|
24
|
+
export declare const FormSlider: FormFieldComponent<Omit<import('..').SliderProps, "value" | "defaultValue" | "modelValue"> & import('./types').CommonFieldProps>;
|
|
25
|
+
export declare const FormTimePicker: FormFieldComponent<Omit<import('..').TimePickerProps, "value" | "defaultValue" | "modelValue"> & import('./types').CommonFieldProps>;
|
|
26
|
+
export declare const FormTreeSelect: FormFieldComponent<Omit<import('..').TreeSelectProps, "value" | "defaultValue" | "modelValue"> & import('./types').CommonFieldProps>;
|
|
27
|
+
export declare const FormCascader: FormFieldComponent<Omit<import('..').CascaderProps, "value" | "defaultValue" | "modelValue"> & import('./types').CommonFieldProps>;
|
|
28
|
+
export declare const FormRating: FormFieldComponent<Omit<import('..').RatingProps, "value" | "defaultValue" | "modelValue"> & import('./types').CommonFieldProps>;
|
|
29
|
+
export interface FormAutoCompleteComponent extends FormFieldComponent<FormAutoCompleteProps> {
|
|
30
|
+
Option: Component;
|
|
31
|
+
}
|
|
32
|
+
export declare const FormAutoComplete: FormAutoCompleteComponent;
|
|
33
|
+
export declare const FormUpload: FormFieldComponent<Omit<import('..').UploadProps, "modelValue" | "defaultFileList" | "fileList"> & import('./types').CommonFieldProps>;
|
|
34
|
+
export declare const FormTagInput: FormFieldComponent<Omit<import('..').TagInputProps, "value" | "defaultValue" | "modelValue"> & import('./types').CommonFieldProps>;
|
|
35
|
+
export declare const FormPinCode: FormFieldComponent<Omit<import('..').PinCodeProps, "value" | "defaultValue" | "modelValue"> & import('./types').CommonFieldProps>;
|
|
36
|
+
export declare const ArrayField: DefineComponent<ArrayFieldProps>;
|
|
37
|
+
export interface FormCompoundComponent extends DefineComponent<FormProps> {
|
|
38
|
+
AutoComplete: typeof FormAutoComplete;
|
|
39
|
+
Cascader: typeof FormCascader;
|
|
40
|
+
Checkbox: typeof FormCheckbox;
|
|
41
|
+
CheckboxGroup: typeof FormCheckboxGroup;
|
|
42
|
+
DatePicker: typeof FormDatePicker;
|
|
43
|
+
ErrorMessage: typeof FormErrorMessage;
|
|
44
|
+
Input: typeof FormInput;
|
|
45
|
+
InputGroup: DefineComponent<FormInputGroupProps>;
|
|
46
|
+
InputNumber: typeof FormInputNumber;
|
|
47
|
+
Label: typeof FormLabel;
|
|
48
|
+
PinCode: typeof FormPinCode;
|
|
49
|
+
Radio: typeof FormRadio;
|
|
50
|
+
RadioGroup: typeof FormRadioGroup;
|
|
51
|
+
Rating: typeof FormRating;
|
|
52
|
+
Section: typeof FormSection;
|
|
53
|
+
Select: typeof FormSelect;
|
|
54
|
+
Slider: typeof FormSlider;
|
|
55
|
+
Slot: typeof FormSlot;
|
|
56
|
+
Switch: typeof FormSwitch;
|
|
57
|
+
TagInput: typeof FormTagInput;
|
|
58
|
+
TextArea: typeof FormTextArea;
|
|
59
|
+
TimePicker: typeof FormTimePicker;
|
|
60
|
+
TreeSelect: typeof FormTreeSelect;
|
|
61
|
+
Upload: typeof FormUpload;
|
|
62
|
+
useForm: typeof useForm;
|
|
63
|
+
}
|
|
64
|
+
export declare const Form: FormCompoundComponent;
|
|
65
|
+
export declare const Field: typeof createFormField;
|
|
66
|
+
export { createFormField, useFieldApi, useFieldState, useForm, useFormApi, useFormState, withField, withFormApi, withFormState, };
|
|
67
|
+
export type { ArrayFieldItem, ArrayFieldProps, ArrayFieldSlotProps, ArrayFieldSlots, CommonFieldProps, FieldApi, FieldValidator, FormApi, FormAutoCompleteProps, FormCascaderProps, FormCheckboxGroupProps, FormCheckboxProps, FormComponentPublicInstance, FormDatePickerProps, FormEmits, FormErrorMessageProps, FormFieldComponent, FormFieldError, FormInputGroupProps, FormInputNumberProps, FormInputProps, FormLabelAlign, FormLabelPosition, FormLabelProps, FormLayout, FormPinCodeProps, FormProps, FormRadioGroupProps, FormRadioProps, FormRatingProps, FormRule, FormRuleType, FormScrollToErrorOptions, FormSectionProps, FormSelectProps, FormSliderProps, FormSlotComponentProps, FormSlotProps, FormSlots, FormState, FormSwitchProps, FormTagInputProps, FormTextAreaProps, FormTimePickerProps, FormTreeSelectProps, FormTrigger, FormUploadProps, FormValidateOptions, FormValidateStatus, FormValidator, ScrollIntoViewOptions, WithField, WithFieldOptions, } from './types';
|
|
68
|
+
export default Form;
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import { A as e, C as t, D as n, E as r, O as i, S as a, T as o, _ as s, a as c, b as l, c as u, d, f, g as p, h as m, i as h, j as g, k as _, l as v, m as y, n as b, o as x, p as S, r as C, s as w, t as T, u as E, v as D, w as O, x as k, y as A } from "../form-CLhGuORQ.js";
|
|
2
|
+
import "../slider/index.js";
|
|
3
|
+
export { T as ArrayField, b as Field, C as Form, C as default, h as FormAutoComplete, c as FormCascader, x as FormCheckbox, w as FormCheckboxGroup, u as FormDatePicker, v as FormInput, E as FormInputNumber, d as FormPinCode, f as FormRadio, S as FormRadioGroup, y as FormRating, m as FormSelect, p as FormSlider, s as FormSwitch, D as FormTagInput, A as FormTextArea, l as FormTimePicker, k as FormTreeSelect, a as FormUpload, e as createFormField, o as useFieldApi, r as useFieldState, n as useForm, i as useFormApi, _ as useFormState, g as withField, t as withFormApi, O as withFormState };
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
import { Ref } from 'vue';
|
|
2
|
+
import { FormApi, FormProps, FormState } from './types';
|
|
3
|
+
interface InternalCallOptions {
|
|
4
|
+
allowEmpty?: boolean;
|
|
5
|
+
fieldAllowEmpty?: boolean;
|
|
6
|
+
needClone?: boolean;
|
|
7
|
+
notNotify?: boolean;
|
|
8
|
+
notUpdate?: boolean;
|
|
9
|
+
silent?: boolean;
|
|
10
|
+
}
|
|
11
|
+
interface InternalFieldApi {
|
|
12
|
+
reset(): void;
|
|
13
|
+
setError(error: unknown, options?: InternalCallOptions): void;
|
|
14
|
+
setTouched(touched: boolean | undefined, options?: InternalCallOptions): void;
|
|
15
|
+
setValue(value: unknown, options?: InternalCallOptions): void;
|
|
16
|
+
validate(value: unknown, options?: InternalCallOptions): Promise<unknown>;
|
|
17
|
+
}
|
|
18
|
+
export interface InternalFormUpdater {
|
|
19
|
+
getArrayField(field: string): {
|
|
20
|
+
initValue?: unknown;
|
|
21
|
+
updateKey?: string | number;
|
|
22
|
+
} | undefined;
|
|
23
|
+
getError(field?: string): unknown;
|
|
24
|
+
getField(field: string): unknown;
|
|
25
|
+
getFormProps(fields?: string[]): Record<string, unknown>;
|
|
26
|
+
getInitValue(field: string): unknown;
|
|
27
|
+
getInitValues(): Record<string, unknown>;
|
|
28
|
+
getTouched(field?: string): unknown;
|
|
29
|
+
getValue(field?: string, options?: InternalCallOptions): unknown;
|
|
30
|
+
register(field: string, state: {
|
|
31
|
+
error?: unknown | undefined;
|
|
32
|
+
status?: string | undefined;
|
|
33
|
+
touched?: boolean | undefined;
|
|
34
|
+
value?: unknown | undefined;
|
|
35
|
+
}, staff: {
|
|
36
|
+
allowEmpty?: boolean;
|
|
37
|
+
field: string;
|
|
38
|
+
fieldApi: InternalFieldApi;
|
|
39
|
+
keepState?: boolean;
|
|
40
|
+
}): void;
|
|
41
|
+
registerArrayField(field: string, value: unknown): void;
|
|
42
|
+
unRegister(field: string): void;
|
|
43
|
+
unRegisterArrayField(field: string): void;
|
|
44
|
+
updateArrayField(field: string, value: {
|
|
45
|
+
initValue?: unknown;
|
|
46
|
+
updateKey?: string | number;
|
|
47
|
+
}): void;
|
|
48
|
+
updateStateError(field: string, error: unknown, options?: InternalCallOptions, callback?: () => void): void;
|
|
49
|
+
updateStateTouched(field: string, touched: boolean | undefined, options?: InternalCallOptions, callback?: () => void): void;
|
|
50
|
+
updateStateValue(field: string, value: unknown, options?: InternalCallOptions, callback?: () => void): void;
|
|
51
|
+
}
|
|
52
|
+
export interface ExternalFormController<Values extends Record<string, unknown> = Record<string, unknown>> extends FormApi<Values> {
|
|
53
|
+
__bind?: (api: FormApi<Values>) => void;
|
|
54
|
+
__unbind?: () => void;
|
|
55
|
+
__updateState?: (state: FormState<Values>) => void;
|
|
56
|
+
}
|
|
57
|
+
export interface FormContextValue {
|
|
58
|
+
api: FormApi;
|
|
59
|
+
props: Readonly<FormProps>;
|
|
60
|
+
state: Ref<FormState>;
|
|
61
|
+
updater: InternalFormUpdater;
|
|
62
|
+
}
|
|
63
|
+
export interface ArrayFieldContextValue {
|
|
64
|
+
inArrayField: boolean;
|
|
65
|
+
shouldUseInitValue: boolean;
|
|
66
|
+
}
|
|
67
|
+
export {};
|
|
@@ -0,0 +1,273 @@
|
|
|
1
|
+
import { Component, ComponentPublicInstance, ComputedRef, CSSProperties, DefineComponent, HTMLAttributes, Ref, VNodeChild } from 'vue';
|
|
2
|
+
import { AutoCompleteProps } from '../auto-complete';
|
|
3
|
+
import { CascaderProps } from '../cascader';
|
|
4
|
+
import { CheckboxGroupProps, CheckboxProps } from '../checkbox';
|
|
5
|
+
import { DatePickerProps } from '../date-picker';
|
|
6
|
+
import { ColProps } from '../grid';
|
|
7
|
+
import { InputGroupProps, InputProps, TextAreaProps } from '../input';
|
|
8
|
+
import { InputNumberProps } from '../input-number';
|
|
9
|
+
import { PinCodeProps } from '../pin-code';
|
|
10
|
+
import { RadioGroupProps, RadioProps } from '../radio';
|
|
11
|
+
import { RatingProps } from '../rating';
|
|
12
|
+
import { SelectProps } from '../select';
|
|
13
|
+
import { SliderProps } from '../slider';
|
|
14
|
+
import { SwitchProps } from '../switch';
|
|
15
|
+
import { TagInputProps } from '../tag-input';
|
|
16
|
+
import { TimePickerProps } from '../time-picker';
|
|
17
|
+
import { TreeSelectProps } from '../tree-select';
|
|
18
|
+
import { UploadProps } from '../upload';
|
|
19
|
+
export type FormLayout = 'vertical' | 'horizontal';
|
|
20
|
+
export type FormLabelPosition = 'top' | 'left' | 'inset';
|
|
21
|
+
export type FormLabelAlign = 'left' | 'right';
|
|
22
|
+
export type FormValidateStatus = 'default' | 'error' | 'warning' | 'success';
|
|
23
|
+
export type FormTrigger = 'blur' | 'change' | 'custom' | 'mount';
|
|
24
|
+
export type FormFieldError = boolean | string | unknown[] | VNodeChild | undefined;
|
|
25
|
+
export type FormRuleType = 'any' | 'array' | 'boolean' | 'date' | 'email' | 'enum' | 'float' | 'hex' | 'integer' | 'method' | 'number' | 'object' | 'regexp' | 'string' | 'url';
|
|
26
|
+
export interface FormRule {
|
|
27
|
+
asyncValidator?: (...args: unknown[]) => void | Promise<void>;
|
|
28
|
+
defaultField?: FormRule;
|
|
29
|
+
enum?: Array<boolean | null | number | string | undefined>;
|
|
30
|
+
fields?: Record<string, FormRule | FormRule[]>;
|
|
31
|
+
len?: number;
|
|
32
|
+
max?: number;
|
|
33
|
+
message?: string | (() => string);
|
|
34
|
+
min?: number;
|
|
35
|
+
options?: Record<string, unknown>;
|
|
36
|
+
pattern?: RegExp | string;
|
|
37
|
+
required?: boolean;
|
|
38
|
+
transform?: (value: unknown) => unknown;
|
|
39
|
+
type?: FormRuleType;
|
|
40
|
+
validator?: (...args: unknown[]) => boolean | Error | Error[];
|
|
41
|
+
whitespace?: boolean;
|
|
42
|
+
}
|
|
43
|
+
export interface FormState<Values extends Record<string, unknown> = Record<string, unknown>> {
|
|
44
|
+
values: Values;
|
|
45
|
+
errors: Record<string, FormFieldError>;
|
|
46
|
+
touched: Record<string, unknown>;
|
|
47
|
+
}
|
|
48
|
+
export interface FormValidateOptions<Field extends string = string> {
|
|
49
|
+
fields?: Field[];
|
|
50
|
+
silent?: boolean;
|
|
51
|
+
}
|
|
52
|
+
export interface FormScrollToErrorOptions {
|
|
53
|
+
field?: string;
|
|
54
|
+
index?: number;
|
|
55
|
+
scrollOpts?: ScrollIntoViewOptions;
|
|
56
|
+
}
|
|
57
|
+
export interface ScrollIntoViewOptions {
|
|
58
|
+
behavior?: 'auto' | 'smooth' | ((actions: unknown[]) => unknown[]);
|
|
59
|
+
block?: 'start' | 'center' | 'end' | 'nearest';
|
|
60
|
+
inline?: 'start' | 'center' | 'end' | 'nearest';
|
|
61
|
+
scrollMode?: 'always' | 'if-needed';
|
|
62
|
+
boundary?: Element | ((parent: Element) => boolean) | null;
|
|
63
|
+
}
|
|
64
|
+
export interface FormApi<Values extends Record<string, unknown> = Record<string, unknown>> {
|
|
65
|
+
getValue(field?: string): unknown;
|
|
66
|
+
setValue(field: string, value: unknown): void;
|
|
67
|
+
getValues(): Values;
|
|
68
|
+
setValues(values: Partial<Values>, options?: {
|
|
69
|
+
isOverride?: boolean;
|
|
70
|
+
}): void;
|
|
71
|
+
getError(field?: string): FormFieldError | Record<string, FormFieldError>;
|
|
72
|
+
setError(field: string, error: FormFieldError): void;
|
|
73
|
+
getTouched(field?: string): unknown;
|
|
74
|
+
setTouched(field: string, touched: boolean): void;
|
|
75
|
+
getFormState(): FormState<Values>;
|
|
76
|
+
getFormProps(fields?: string[]): Partial<FormProps<Values>>;
|
|
77
|
+
getInitValue(field: string): unknown;
|
|
78
|
+
getInitValues(): Values;
|
|
79
|
+
getFieldExist(field: string): boolean;
|
|
80
|
+
reset(fields?: string[]): void;
|
|
81
|
+
validate(fields?: string[] | FormValidateOptions): Promise<Values>;
|
|
82
|
+
submitForm(): void;
|
|
83
|
+
scrollToField(field: string, options?: ScrollIntoViewOptions): void;
|
|
84
|
+
scrollToError(options?: FormScrollToErrorOptions): void;
|
|
85
|
+
}
|
|
86
|
+
export interface FieldApi {
|
|
87
|
+
getError(): FormFieldError;
|
|
88
|
+
setError(error: FormFieldError): void;
|
|
89
|
+
getTouched(): unknown;
|
|
90
|
+
setTouched(touched: boolean): void;
|
|
91
|
+
getValue(): unknown;
|
|
92
|
+
setValue(value: unknown): void;
|
|
93
|
+
}
|
|
94
|
+
export interface FormSlotProps<Values extends Record<string, unknown> = Record<string, unknown>> {
|
|
95
|
+
formState: FormState<Values>;
|
|
96
|
+
formApi: FormApi<Values>;
|
|
97
|
+
values: Values;
|
|
98
|
+
}
|
|
99
|
+
export interface FormProps<Values extends Record<string, unknown> = Record<string, unknown>> {
|
|
100
|
+
allowEmpty?: boolean;
|
|
101
|
+
ariaLabel?: string;
|
|
102
|
+
autoScrollToError?: boolean | ScrollIntoViewOptions;
|
|
103
|
+
className?: HTMLAttributes['class'];
|
|
104
|
+
component?: Component;
|
|
105
|
+
disabled?: boolean;
|
|
106
|
+
extraTextPosition?: 'middle' | 'bottom';
|
|
107
|
+
form?: FormApi<Values>;
|
|
108
|
+
getFormApi?: (formApi: FormApi<Values>) => void;
|
|
109
|
+
id?: string;
|
|
110
|
+
initValues?: Partial<Values>;
|
|
111
|
+
labelAlign?: FormLabelAlign;
|
|
112
|
+
labelCol?: ColProps;
|
|
113
|
+
labelPosition?: FormLabelPosition;
|
|
114
|
+
labelWidth?: number | string;
|
|
115
|
+
layout?: FormLayout;
|
|
116
|
+
render?: (props: FormSlotProps<Values>) => VNodeChild;
|
|
117
|
+
showValidateIcon?: boolean;
|
|
118
|
+
stopPropagation?: {
|
|
119
|
+
submit?: boolean;
|
|
120
|
+
reset?: boolean;
|
|
121
|
+
};
|
|
122
|
+
stopValidateWithError?: boolean;
|
|
123
|
+
style?: CSSProperties;
|
|
124
|
+
trigger?: FormTrigger | FormTrigger[];
|
|
125
|
+
validateFields?: FormValidator<Values>;
|
|
126
|
+
validator?: FormValidator<Values>;
|
|
127
|
+
wrapperCol?: ColProps;
|
|
128
|
+
}
|
|
129
|
+
export type FormValidator<Values extends Record<string, unknown>> = (values: Values) => string | Partial<Record<keyof Values, FormFieldError>> | Promise<string | Partial<Record<keyof Values, FormFieldError>>>;
|
|
130
|
+
export interface FormEmits<Values extends Record<string, unknown> = Record<string, unknown>> {
|
|
131
|
+
change: [formState: FormState<Values>];
|
|
132
|
+
errorChange: [
|
|
133
|
+
errors: Record<string, FormFieldError>,
|
|
134
|
+
changedErrors: Record<string, FormFieldError>
|
|
135
|
+
];
|
|
136
|
+
reset: [];
|
|
137
|
+
submit: [values: Values, event?: Event];
|
|
138
|
+
submitFail: [errors: unknown, values: Values, event?: Event];
|
|
139
|
+
valueChange: [values: Values, changedValues: Partial<Values>];
|
|
140
|
+
}
|
|
141
|
+
export interface FormSlots<Values extends Record<string, unknown> = Record<string, unknown>> {
|
|
142
|
+
default?: (props: FormSlotProps<Values>) => VNodeChild;
|
|
143
|
+
}
|
|
144
|
+
export interface FormLabelProps {
|
|
145
|
+
align?: FormLabelAlign;
|
|
146
|
+
className?: HTMLAttributes['class'];
|
|
147
|
+
disabled?: boolean;
|
|
148
|
+
extra?: VNodeChild;
|
|
149
|
+
id?: string;
|
|
150
|
+
name?: string;
|
|
151
|
+
optional?: boolean;
|
|
152
|
+
required?: boolean;
|
|
153
|
+
style?: CSSProperties;
|
|
154
|
+
text?: VNodeChild;
|
|
155
|
+
width?: number | string;
|
|
156
|
+
}
|
|
157
|
+
export interface FormErrorMessageProps {
|
|
158
|
+
className?: HTMLAttributes['class'];
|
|
159
|
+
error?: FormFieldError;
|
|
160
|
+
errorMessageId?: string;
|
|
161
|
+
helpText?: VNodeChild;
|
|
162
|
+
helpTextId?: string;
|
|
163
|
+
isInInputGroup?: boolean;
|
|
164
|
+
showValidateIcon?: boolean;
|
|
165
|
+
style?: CSSProperties;
|
|
166
|
+
validateStatus?: FormValidateStatus;
|
|
167
|
+
}
|
|
168
|
+
export interface CommonFieldProps {
|
|
169
|
+
allowEmptyString?: boolean;
|
|
170
|
+
convert?: (value: unknown) => unknown;
|
|
171
|
+
emptyValue?: unknown;
|
|
172
|
+
extraText?: VNodeChild;
|
|
173
|
+
extraTextPosition?: 'middle' | 'bottom';
|
|
174
|
+
field: string;
|
|
175
|
+
fieldClassName?: HTMLAttributes['class'];
|
|
176
|
+
fieldStyle?: CSSProperties;
|
|
177
|
+
helpText?: VNodeChild;
|
|
178
|
+
initValue?: unknown;
|
|
179
|
+
keepState?: boolean;
|
|
180
|
+
label?: FormLabelProps | VNodeChild;
|
|
181
|
+
labelAlign?: FormLabelAlign;
|
|
182
|
+
labelCol?: ColProps;
|
|
183
|
+
labelPosition?: FormLabelPosition;
|
|
184
|
+
labelWidth?: number | string;
|
|
185
|
+
name?: string;
|
|
186
|
+
noErrorMessage?: boolean;
|
|
187
|
+
noLabel?: boolean;
|
|
188
|
+
pure?: boolean;
|
|
189
|
+
required?: boolean;
|
|
190
|
+
rules?: FormRule[];
|
|
191
|
+
stopValidateWithError?: boolean;
|
|
192
|
+
transform?: (value: unknown) => unknown;
|
|
193
|
+
trigger?: FormTrigger | FormTrigger[];
|
|
194
|
+
validate?: FieldValidator;
|
|
195
|
+
validator?: FieldValidator;
|
|
196
|
+
validateStatus?: FormValidateStatus;
|
|
197
|
+
wrapperCol?: ColProps;
|
|
198
|
+
}
|
|
199
|
+
export type FieldValidator = (fieldValue: unknown, values: Record<string, unknown>) => string | undefined | Promise<string | undefined>;
|
|
200
|
+
type StandardFieldProps<Props> = Omit<Props, 'defaultValue' | 'modelValue' | 'value'> & CommonFieldProps;
|
|
201
|
+
type CheckedFieldProps<Props> = Omit<Props, 'checked' | 'defaultChecked' | 'modelValue'> & CommonFieldProps;
|
|
202
|
+
type UploadFieldProps<Props> = Omit<Props, 'defaultFileList' | 'fileList' | 'modelValue'> & CommonFieldProps;
|
|
203
|
+
type OptionalField<Props> = Omit<Props, 'field'> & {
|
|
204
|
+
field?: string;
|
|
205
|
+
};
|
|
206
|
+
export type FormInputProps = StandardFieldProps<InputProps>;
|
|
207
|
+
export type FormTextAreaProps = StandardFieldProps<TextAreaProps>;
|
|
208
|
+
export type FormInputNumberProps = StandardFieldProps<InputNumberProps>;
|
|
209
|
+
export type FormSelectProps = StandardFieldProps<SelectProps>;
|
|
210
|
+
export type FormCheckboxProps = OptionalField<CheckedFieldProps<CheckboxProps>>;
|
|
211
|
+
export type FormCheckboxGroupProps = StandardFieldProps<CheckboxGroupProps>;
|
|
212
|
+
export type FormRadioProps = OptionalField<CheckedFieldProps<RadioProps>>;
|
|
213
|
+
export type FormRadioGroupProps = StandardFieldProps<RadioGroupProps>;
|
|
214
|
+
export type FormDatePickerProps = StandardFieldProps<DatePickerProps>;
|
|
215
|
+
export type FormSwitchProps = CheckedFieldProps<SwitchProps>;
|
|
216
|
+
export type FormSliderProps = StandardFieldProps<SliderProps>;
|
|
217
|
+
export type FormTimePickerProps = StandardFieldProps<TimePickerProps>;
|
|
218
|
+
export type FormTreeSelectProps = StandardFieldProps<TreeSelectProps>;
|
|
219
|
+
export type FormCascaderProps = StandardFieldProps<CascaderProps>;
|
|
220
|
+
export type FormRatingProps = StandardFieldProps<RatingProps>;
|
|
221
|
+
export type FormAutoCompleteProps = StandardFieldProps<AutoCompleteProps>;
|
|
222
|
+
export type FormUploadProps = UploadFieldProps<UploadProps>;
|
|
223
|
+
export type FormTagInputProps = StandardFieldProps<TagInputProps>;
|
|
224
|
+
export type FormPinCodeProps = StandardFieldProps<PinCodeProps>;
|
|
225
|
+
export interface FormSectionProps {
|
|
226
|
+
className?: HTMLAttributes['class'];
|
|
227
|
+
style?: CSSProperties;
|
|
228
|
+
text?: VNodeChild;
|
|
229
|
+
}
|
|
230
|
+
export interface FormSlotComponentProps {
|
|
231
|
+
className?: HTMLAttributes['class'];
|
|
232
|
+
label?: FormLabelProps | VNodeChild;
|
|
233
|
+
style?: CSSProperties;
|
|
234
|
+
}
|
|
235
|
+
export interface FormInputGroupProps extends Omit<InputGroupProps, 'label'> {
|
|
236
|
+
extraText?: VNodeChild;
|
|
237
|
+
extraTextPosition?: 'bottom' | 'middle';
|
|
238
|
+
label?: FormLabelProps | VNodeChild;
|
|
239
|
+
labelPosition?: 'left' | 'top';
|
|
240
|
+
}
|
|
241
|
+
export interface ArrayFieldItem {
|
|
242
|
+
key: string;
|
|
243
|
+
field: string;
|
|
244
|
+
remove(): void;
|
|
245
|
+
}
|
|
246
|
+
export interface ArrayFieldSlotProps {
|
|
247
|
+
add(index?: number): string;
|
|
248
|
+
addWithInitValue(value: unknown, index?: number): void;
|
|
249
|
+
arrayFields: ArrayFieldItem[];
|
|
250
|
+
}
|
|
251
|
+
export interface ArrayFieldProps {
|
|
252
|
+
field: string;
|
|
253
|
+
initValue?: unknown[];
|
|
254
|
+
}
|
|
255
|
+
export interface ArrayFieldSlots {
|
|
256
|
+
default?: (props: ArrayFieldSlotProps) => VNodeChild;
|
|
257
|
+
}
|
|
258
|
+
export interface FormUseResult<Values extends Record<string, unknown>> {
|
|
259
|
+
0: FormApi<Values>;
|
|
260
|
+
1: Ref<FormState<Values>>;
|
|
261
|
+
2: ComputedRef<Values>;
|
|
262
|
+
length: 3;
|
|
263
|
+
}
|
|
264
|
+
export type FormFieldComponent<Props> = DefineComponent<Props>;
|
|
265
|
+
export interface WithFieldOptions {
|
|
266
|
+
maintainCursor?: boolean;
|
|
267
|
+
onUpdateEvent?: string;
|
|
268
|
+
valueProp?: string;
|
|
269
|
+
valuePath?: string;
|
|
270
|
+
}
|
|
271
|
+
export type WithField = <Props extends Record<string, unknown>>(component: Component, options?: WithFieldOptions) => FormFieldComponent<Props & CommonFieldProps>;
|
|
272
|
+
export type FormComponentPublicInstance = ComponentPublicInstance<FormProps>;
|
|
273
|
+
export {};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { ComputedRef, Ref } from 'vue';
|
|
2
|
+
import { FieldApi, FormApi, FormState } from './types';
|
|
3
|
+
export declare function useForm<Values extends Record<string, unknown> = Record<string, unknown>>(): readonly [FormApi<Values>, Ref<FormState<Values>>, ComputedRef<Values>];
|
|
4
|
+
export declare function useFormApi<Values extends Record<string, unknown> = Record<string, unknown>>(): FormApi<Values>;
|
|
5
|
+
export declare function useFormState<Values extends Record<string, unknown> = Record<string, unknown>>(): Readonly<Ref<FormState<Values>>>;
|
|
6
|
+
export declare function useFieldApi(field: string): FieldApi;
|
|
7
|
+
export declare function useFieldState(field: string): ComputedRef<{
|
|
8
|
+
value: unknown;
|
|
9
|
+
error: unknown;
|
|
10
|
+
touched: unknown;
|
|
11
|
+
}>;
|