@bevelo/vue 0.0.0-stage → 0.1.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/dist/accordion.cjs +89 -0
- package/dist/accordion.d.cts +145 -0
- package/dist/accordion.d.ts +145 -0
- package/dist/accordion.js +88 -0
- package/dist/agent.cjs +74 -0
- package/dist/agent.d.cts +2 -0
- package/dist/agent.d.ts +2 -0
- package/dist/agent.js +1 -0
- package/dist/alert-dialog.cjs +48 -0
- package/dist/alert-dialog.d.cts +142 -0
- package/dist/alert-dialog.d.ts +142 -0
- package/dist/alert-dialog.js +47 -0
- package/dist/alert.cjs +77 -0
- package/dist/alert.d.cts +64 -0
- package/dist/alert.d.ts +64 -0
- package/dist/alert.js +76 -0
- package/dist/aspect-ratio.cjs +21 -0
- package/dist/aspect-ratio.d.cts +13 -0
- package/dist/aspect-ratio.d.ts +13 -0
- package/dist/aspect-ratio.js +21 -0
- package/dist/async-options.cjs +76 -0
- package/dist/async-options.d.cts +49 -0
- package/dist/async-options.d.ts +49 -0
- package/dist/async-options.js +75 -0
- package/dist/autocomplete.cjs +274 -0
- package/dist/autocomplete.d.cts +309 -0
- package/dist/autocomplete.d.ts +309 -0
- package/dist/autocomplete.js +273 -0
- package/dist/avatar.cjs +51 -0
- package/dist/avatar.d.cts +69 -0
- package/dist/avatar.d.ts +69 -0
- package/dist/avatar.js +50 -0
- package/dist/badge.cjs +41 -0
- package/dist/badge.d.cts +39 -0
- package/dist/badge.d.ts +39 -0
- package/dist/badge.js +40 -0
- package/dist/breadcrumb.cjs +59 -0
- package/dist/breadcrumb.d.cts +40 -0
- package/dist/breadcrumb.d.ts +40 -0
- package/dist/breadcrumb.js +58 -0
- package/dist/button.cjs +56 -0
- package/dist/button.d.cts +79 -0
- package/dist/button.d.ts +79 -0
- package/dist/button.js +55 -0
- package/dist/calendar-Bcc6HKc9.js +643 -0
- package/dist/calendar-vHGhj3RI.cjs +720 -0
- package/dist/calendar.cjs +4 -0
- package/dist/calendar.d.cts +316 -0
- package/dist/calendar.d.ts +316 -0
- package/dist/calendar.js +1 -0
- package/dist/card-B_ZoLCvt.d.cts +61 -0
- package/dist/card-B_ZoLCvt.d.ts +61 -0
- package/dist/card-CZHRix0r.js +99 -0
- package/dist/card-CvGfpsiU.cjs +140 -0
- package/dist/card.cjs +9 -0
- package/dist/card.d.cts +2 -0
- package/dist/card.d.ts +2 -0
- package/dist/card.js +1 -0
- package/dist/carousel.cjs +225 -0
- package/dist/carousel.d.cts +214 -0
- package/dist/carousel.d.ts +214 -0
- package/dist/carousel.js +224 -0
- package/dist/checkbox-group.cjs +93 -0
- package/dist/checkbox-group.d.cts +108 -0
- package/dist/checkbox-group.d.ts +108 -0
- package/dist/checkbox-group.js +91 -0
- package/dist/checkbox.cjs +117 -0
- package/dist/checkbox.d.cts +153 -0
- package/dist/checkbox.d.ts +153 -0
- package/dist/checkbox.js +116 -0
- package/dist/collapsible.cjs +70 -0
- package/dist/collapsible.d.cts +141 -0
- package/dist/collapsible.d.ts +141 -0
- package/dist/collapsible.js +69 -0
- package/dist/color-picker.cjs +225 -0
- package/dist/color-picker.d.cts +180 -0
- package/dist/color-picker.d.ts +180 -0
- package/dist/color-picker.js +212 -0
- package/dist/combobox-CDHIXr6J.d.ts +735 -0
- package/dist/combobox-D39Waj6L.d.cts +735 -0
- package/dist/combobox-DlCU0vS1.cjs +945 -0
- package/dist/combobox-wLdV6VA_.js +802 -0
- package/dist/combobox.cjs +26 -0
- package/dist/combobox.d.cts +3 -0
- package/dist/combobox.d.ts +3 -0
- package/dist/combobox.js +1 -0
- package/dist/command-CEJACYpR.d.ts +404 -0
- package/dist/command-CqHZVivR.js +693 -0
- package/dist/command-D54bj6RJ.cjs +836 -0
- package/dist/command-rAVp-wbf.d.cts +404 -0
- package/dist/command.cjs +15 -0
- package/dist/command.d.cts +2 -0
- package/dist/command.d.ts +2 -0
- package/dist/command.js +1 -0
- package/dist/context-menu-BPsgeLQm.cjs +170 -0
- package/dist/context-menu-ByhKzWTm.d.ts +129 -0
- package/dist/context-menu-Co3ABcdp.js +153 -0
- package/dist/context-menu-USbhMQuc.d.cts +129 -0
- package/dist/context-menu.cjs +6 -0
- package/dist/context-menu.d.cts +2 -0
- package/dist/context-menu.d.ts +2 -0
- package/dist/context-menu.js +2 -0
- package/dist/date-input.cjs +374 -0
- package/dist/date-input.d.cts +234 -0
- package/dist/date-input.d.ts +234 -0
- package/dist/date-input.js +371 -0
- package/dist/date-picker-D1mygz_Y.js +891 -0
- package/dist/date-picker-D_hqHHAV.cjs +938 -0
- package/dist/date-picker.cjs +4 -0
- package/dist/date-picker.d.cts +447 -0
- package/dist/date-picker.d.ts +447 -0
- package/dist/date-picker.js +1 -0
- package/dist/describe-BlNg9SbK.js +25 -0
- package/dist/describe-D_dLtwde.cjs +42 -0
- package/dist/dialog-view-CKtpbGq_.js +26 -0
- package/dist/dialog-view-swgEQvlZ.cjs +31 -0
- package/dist/dialog.cjs +66 -0
- package/dist/dialog.d.cts +158 -0
- package/dist/dialog.d.ts +158 -0
- package/dist/dialog.js +63 -0
- package/dist/direction.cjs +21 -0
- package/dist/direction.d.cts +13 -0
- package/dist/direction.d.ts +13 -0
- package/dist/direction.js +21 -0
- package/dist/dnd.cjs +103 -0
- package/dist/dnd.d.cts +54 -0
- package/dist/dnd.d.ts +54 -0
- package/dist/dnd.js +98 -0
- package/dist/drawer.cjs +137 -0
- package/dist/drawer.d.cts +190 -0
- package/dist/drawer.d.ts +190 -0
- package/dist/drawer.js +134 -0
- package/dist/empty-state.cjs +75 -0
- package/dist/empty-state.d.cts +46 -0
- package/dist/empty-state.d.ts +46 -0
- package/dist/empty-state.js +74 -0
- package/dist/engine-refs-8O6mHfYd.d.cts +4 -0
- package/dist/engine-refs-8O6mHfYd.d.ts +4 -0
- package/dist/engine-refs-CPWFFTfA.cjs +32 -0
- package/dist/engine-refs-sojZQs1R.js +21 -0
- package/dist/error-state.cjs +86 -0
- package/dist/error-state.d.cts +54 -0
- package/dist/error-state.d.ts +54 -0
- package/dist/error-state.js +85 -0
- package/dist/field.cjs +123 -0
- package/dist/field.d.cts +100 -0
- package/dist/field.d.ts +100 -0
- package/dist/field.js +122 -0
- package/dist/file-input.cjs +117 -0
- package/dist/file-input.d.cts +168 -0
- package/dist/file-input.d.ts +168 -0
- package/dist/file-input.js +116 -0
- package/dist/form-CKus_NQE.cjs +23 -0
- package/dist/form-y7b0fcqL.js +18 -0
- package/dist/gauge-parts-BVmw61GR.js +64 -0
- package/dist/gauge-parts-DjqBK9pL.d.cts +15 -0
- package/dist/gauge-parts-V31Fma77.cjs +75 -0
- package/dist/gauge-parts-mAgseDD4.d.ts +15 -0
- package/dist/headless-B3zQWaJm.js +225 -0
- package/dist/headless-BQe1X1Vf.d.ts +2 -0
- package/dist/headless-CbQgxdK1.d.cts +2 -0
- package/dist/headless-D88yFw8W.cjs +248 -0
- package/dist/hover-card.cjs +139 -0
- package/dist/hover-card.d.cts +200 -0
- package/dist/hover-card.d.ts +200 -0
- package/dist/hover-card.js +137 -0
- package/dist/icon-button.cjs +75 -0
- package/dist/icon-button.d.cts +104 -0
- package/dist/icon-button.d.ts +104 -0
- package/dist/icon-button.js +74 -0
- package/dist/image-cropper.cjs +106 -0
- package/dist/image-cropper.d.cts +7 -0
- package/dist/image-cropper.d.ts +7 -0
- package/dist/image-cropper.js +105 -0
- package/dist/image.cjs +87 -0
- package/dist/image.d.cts +92 -0
- package/dist/image.d.ts +92 -0
- package/dist/image.js +86 -0
- package/dist/index.cjs +1685 -0
- package/dist/index.d.cts +1195 -0
- package/dist/index.d.ts +1195 -0
- package/dist/index.js +1042 -0
- package/dist/input-group.cjs +91 -0
- package/dist/input-group.d.cts +84 -0
- package/dist/input-group.d.ts +84 -0
- package/dist/input-group.js +90 -0
- package/dist/input.cjs +114 -0
- package/dist/input.d.cts +186 -0
- package/dist/input.d.ts +186 -0
- package/dist/input.js +113 -0
- package/dist/item-B-QdNtAl.cjs +264 -0
- package/dist/item-D6GSb0WD.d.ts +144 -0
- package/dist/item-DPJnk7ED.js +199 -0
- package/dist/item-DyrvCrsL.d.cts +144 -0
- package/dist/item.cjs +10 -0
- package/dist/item.d.cts +2 -0
- package/dist/item.d.ts +2 -0
- package/dist/item.js +1 -0
- package/dist/kbd.cjs +55 -0
- package/dist/kbd.d.cts +38 -0
- package/dist/kbd.d.ts +38 -0
- package/dist/kbd.js +54 -0
- package/dist/label.cjs +41 -0
- package/dist/label.d.cts +40 -0
- package/dist/label.d.ts +40 -0
- package/dist/label.js +40 -0
- package/dist/listbox.cjs +85 -0
- package/dist/listbox.d.cts +200 -0
- package/dist/listbox.d.ts +200 -0
- package/dist/listbox.js +84 -0
- package/dist/loader.cjs +66 -0
- package/dist/loader.d.cts +68 -0
- package/dist/loader.d.ts +68 -0
- package/dist/loader.js +65 -0
- package/dist/mention-menu.cjs +126 -0
- package/dist/mention-menu.d.cts +144 -0
- package/dist/mention-menu.d.ts +144 -0
- package/dist/mention-menu.js +125 -0
- package/dist/menu.cjs +182 -0
- package/dist/menu.d.cts +240 -0
- package/dist/menu.d.ts +240 -0
- package/dist/menu.js +181 -0
- package/dist/menubar.cjs +38 -0
- package/dist/menubar.d.cts +43 -0
- package/dist/menubar.d.ts +43 -0
- package/dist/menubar.js +37 -0
- package/dist/meter.cjs +113 -0
- package/dist/meter.d.cts +124 -0
- package/dist/meter.d.ts +124 -0
- package/dist/meter.js +108 -0
- package/dist/native-select-52jYpA3c.d.cts +136 -0
- package/dist/native-select-BdJojSQt.d.ts +136 -0
- package/dist/native-select-BwptULNE.js +129 -0
- package/dist/native-select-DjBGWFoh.cjs +146 -0
- package/dist/native-select.cjs +5 -0
- package/dist/native-select.d.cts +2 -0
- package/dist/native-select.d.ts +2 -0
- package/dist/native-select.js +1 -0
- package/dist/navigation-menu.cjs +108 -0
- package/dist/navigation-menu.d.cts +245 -0
- package/dist/navigation-menu.d.ts +245 -0
- package/dist/navigation-menu.js +107 -0
- package/dist/number-input.cjs +189 -0
- package/dist/number-input.d.cts +232 -0
- package/dist/number-input.d.ts +232 -0
- package/dist/number-input.js +187 -0
- package/dist/option-row-DFCj-NoL.js +64 -0
- package/dist/option-row-Dlc6brXH.d.cts +30 -0
- package/dist/option-row-hLg6Ye86.cjs +105 -0
- package/dist/option-row-yJqjEx0G.d.ts +30 -0
- package/dist/options-BDn36q6n.cjs +111 -0
- package/dist/options-BlkyK-uO.js +106 -0
- package/dist/options-CGl5jBEY.d.ts +19 -0
- package/dist/options-DUGLoksA.d.cts +19 -0
- package/dist/otp-input.cjs +85 -0
- package/dist/otp-input.d.cts +113 -0
- package/dist/otp-input.d.ts +113 -0
- package/dist/otp-input.js +84 -0
- package/dist/overlay-controller-78GSJGbM.js +76 -0
- package/dist/overlay-controller-BDeITPoR.d.cts +16 -0
- package/dist/overlay-controller-DmaZ8FLl.cjs +93 -0
- package/dist/overlay-controller-HrMdTomI.d.ts +16 -0
- package/dist/pagination.cjs +87 -0
- package/dist/pagination.d.cts +112 -0
- package/dist/pagination.d.ts +112 -0
- package/dist/pagination.js +86 -0
- package/dist/parts-9zrUGbuI.js +84 -0
- package/dist/parts-DcYZV8ug.cjs +95 -0
- package/dist/password-input.cjs +144 -0
- package/dist/password-input.d.cts +151 -0
- package/dist/password-input.d.ts +151 -0
- package/dist/password-input.js +143 -0
- package/dist/placement-C_WRqvZk.js +49 -0
- package/dist/placement-ChEh6uxa.cjs +60 -0
- package/dist/popover.cjs +159 -0
- package/dist/popover.d.cts +185 -0
- package/dist/popover.d.ts +185 -0
- package/dist/popover.js +157 -0
- package/dist/preferences.cjs +96 -0
- package/dist/preferences.d.cts +36 -0
- package/dist/preferences.d.ts +36 -0
- package/dist/preferences.js +94 -0
- package/dist/presence.cjs +85 -0
- package/dist/presence.d.cts +25 -0
- package/dist/presence.d.ts +25 -0
- package/dist/presence.js +83 -0
- package/dist/progress.cjs +111 -0
- package/dist/progress.d.cts +109 -0
- package/dist/progress.d.ts +109 -0
- package/dist/progress.js +106 -0
- package/dist/query.cjs +152 -0
- package/dist/query.d.cts +68 -0
- package/dist/query.d.ts +68 -0
- package/dist/query.js +142 -0
- package/dist/radio.cjs +102 -0
- package/dist/radio.d.cts +136 -0
- package/dist/radio.d.ts +136 -0
- package/dist/radio.js +101 -0
- package/dist/rating.cjs +88 -0
- package/dist/rating.d.cts +100 -0
- package/dist/rating.d.ts +100 -0
- package/dist/rating.js +87 -0
- package/dist/resizable.cjs +57 -0
- package/dist/resizable.d.cts +119 -0
- package/dist/resizable.d.ts +119 -0
- package/dist/resizable.js +56 -0
- package/dist/scroll-area.cjs +59 -0
- package/dist/scroll-area.d.cts +72 -0
- package/dist/scroll-area.d.ts +72 -0
- package/dist/scroll-area.js +58 -0
- package/dist/segmented-control.cjs +88 -0
- package/dist/segmented-control.d.cts +121 -0
- package/dist/segmented-control.d.ts +121 -0
- package/dist/segmented-control.js +86 -0
- package/dist/select.cjs +160 -0
- package/dist/select.d.cts +385 -0
- package/dist/select.d.ts +385 -0
- package/dist/select.js +159 -0
- package/dist/separator.cjs +32 -0
- package/dist/separator.d.cts +31 -0
- package/dist/separator.d.ts +31 -0
- package/dist/separator.js +31 -0
- package/dist/sheet.cjs +294 -0
- package/dist/sheet.d.cts +456 -0
- package/dist/sheet.d.ts +456 -0
- package/dist/sheet.js +292 -0
- package/dist/sidebar-C-OdvGzD.d.cts +96 -0
- package/dist/sidebar-CZ1-p0-V.d.ts +96 -0
- package/dist/sidebar-DC-mpzMR.js +87 -0
- package/dist/sidebar-gSAgHdkn.cjs +110 -0
- package/dist/sidebar.cjs +6 -0
- package/dist/sidebar.d.cts +2 -0
- package/dist/sidebar.d.ts +2 -0
- package/dist/sidebar.js +1 -0
- package/dist/skeleton.cjs +46 -0
- package/dist/skeleton.d.cts +47 -0
- package/dist/skeleton.d.ts +47 -0
- package/dist/skeleton.js +45 -0
- package/dist/slider.cjs +118 -0
- package/dist/slider.d.cts +181 -0
- package/dist/slider.d.ts +181 -0
- package/dist/slider.js +117 -0
- package/dist/sortable-board-strict.cjs +149 -0
- package/dist/sortable-board-strict.d.cts +181 -0
- package/dist/sortable-board-strict.d.ts +181 -0
- package/dist/sortable-board-strict.js +148 -0
- package/dist/sortable-engine.cjs +136 -0
- package/dist/sortable-engine.d.cts +237 -0
- package/dist/sortable-engine.d.ts +237 -0
- package/dist/sortable-engine.js +135 -0
- package/dist/sortable.cjs +67 -0
- package/dist/sortable.d.cts +217 -0
- package/dist/sortable.d.ts +217 -0
- package/dist/sortable.js +66 -0
- package/dist/spinner.cjs +32 -0
- package/dist/spinner.d.cts +31 -0
- package/dist/spinner.d.ts +31 -0
- package/dist/spinner.js +31 -0
- package/dist/steps-C9Jmrt8G.cjs +122 -0
- package/dist/steps-Cs8AfxV7.js +81 -0
- package/dist/steps-DW5NkzVj.d.ts +71 -0
- package/dist/steps-ymRMdju5.d.cts +71 -0
- package/dist/steps.cjs +8 -0
- package/dist/steps.d.cts +2 -0
- package/dist/steps.d.ts +2 -0
- package/dist/steps.js +1 -0
- package/dist/switch.cjs +100 -0
- package/dist/switch.d.cts +144 -0
- package/dist/switch.d.ts +144 -0
- package/dist/switch.js +99 -0
- package/dist/table.cjs +124 -0
- package/dist/table.d.cts +124 -0
- package/dist/table.d.ts +124 -0
- package/dist/table.js +123 -0
- package/dist/tabs.cjs +89 -0
- package/dist/tabs.d.cts +160 -0
- package/dist/tabs.d.ts +160 -0
- package/dist/tabs.js +88 -0
- package/dist/textarea.cjs +140 -0
- package/dist/textarea.d.cts +231 -0
- package/dist/textarea.d.ts +231 -0
- package/dist/textarea.js +139 -0
- package/dist/time-input.cjs +117 -0
- package/dist/time-input.d.cts +140 -0
- package/dist/time-input.d.ts +140 -0
- package/dist/time-input.js +116 -0
- package/dist/timeline.cjs +82 -0
- package/dist/timeline.d.cts +62 -0
- package/dist/timeline.d.ts +62 -0
- package/dist/timeline.js +81 -0
- package/dist/toast-CfkRzdNd.js +354 -0
- package/dist/toast-DyezF7lm.cjs +401 -0
- package/dist/toast.cjs +16 -0
- package/dist/toast.d.cts +275 -0
- package/dist/toast.d.ts +275 -0
- package/dist/toast.js +1 -0
- package/dist/toggle-group.cjs +65 -0
- package/dist/toggle-group.d.cts +128 -0
- package/dist/toggle-group.d.ts +128 -0
- package/dist/toggle-group.js +64 -0
- package/dist/toggle.cjs +64 -0
- package/dist/toggle.d.cts +97 -0
- package/dist/toggle.d.ts +97 -0
- package/dist/toggle.js +63 -0
- package/dist/token-input-BIC9VLMG.d.cts +170 -0
- package/dist/token-input-BTReOHIv.cjs +336 -0
- package/dist/token-input-CQnZ6-pO.d.ts +170 -0
- package/dist/token-input-DtcCZrcC.js +295 -0
- package/dist/token-input.cjs +9 -0
- package/dist/token-input.d.cts +2 -0
- package/dist/token-input.d.ts +2 -0
- package/dist/token-input.js +1 -0
- package/dist/toolbar.cjs +62 -0
- package/dist/toolbar.d.cts +58 -0
- package/dist/toolbar.d.ts +58 -0
- package/dist/toolbar.js +61 -0
- package/dist/tooltip.cjs +149 -0
- package/dist/tooltip.d.cts +208 -0
- package/dist/tooltip.d.ts +208 -0
- package/dist/tooltip.js +147 -0
- package/dist/tree-grid.cjs +127 -0
- package/dist/tree-grid.d.cts +130 -0
- package/dist/tree-grid.d.ts +130 -0
- package/dist/tree-grid.js +126 -0
- package/dist/tree.cjs +227 -0
- package/dist/tree.d.cts +223 -0
- package/dist/tree.d.ts +223 -0
- package/dist/tree.js +226 -0
- package/dist/trigger-menu-8FAwypbs.d.cts +347 -0
- package/dist/trigger-menu-B898rWkz.cjs +502 -0
- package/dist/trigger-menu-C2YHe7es.d.ts +347 -0
- package/dist/trigger-menu-CxzocSWO.js +431 -0
- package/dist/trigger-menu.cjs +22 -0
- package/dist/trigger-menu.d.cts +2 -0
- package/dist/trigger-menu.d.ts +2 -0
- package/dist/trigger-menu.js +2 -0
- package/dist/virtual-list-strict.cjs +126 -0
- package/dist/virtual-list-strict.d.cts +69 -0
- package/dist/virtual-list-strict.d.ts +69 -0
- package/dist/virtual-list-strict.js +125 -0
- package/dist/virtual-list.cjs +65 -0
- package/dist/virtual-list.d.cts +82 -0
- package/dist/virtual-list.d.ts +82 -0
- package/dist/virtual-list.js +64 -0
- package/dist/virtual.cjs +27 -0
- package/dist/virtual.d.cts +30 -0
- package/dist/virtual.d.ts +30 -0
- package/dist/virtual.js +26 -0
- package/dist/vue-helpers-Bh_YF48i.cjs +102 -0
- package/dist/vue-helpers-Z3oOAHYB.js +55 -0
- package/dist/waterfall-chart.cjs +114 -0
- package/dist/waterfall-chart.d.cts +117 -0
- package/dist/waterfall-chart.d.ts +117 -0
- package/dist/waterfall-chart.js +113 -0
- package/dist/waterfall.cjs +296 -0
- package/dist/waterfall.d.cts +219 -0
- package/dist/waterfall.d.ts +219 -0
- package/dist/waterfall.js +284 -0
- package/package.json +518 -3
- package/README.md +0 -3
|
@@ -0,0 +1,232 @@
|
|
|
1
|
+
import { n as OptionEmits, t as ModelEmits } from "./options-DUGLoksA.cjs";
|
|
2
|
+
import { PropType } from "vue";
|
|
3
|
+
export declare const NumberInput: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
4
|
+
value: {
|
|
5
|
+
type: PropType<number | null>;
|
|
6
|
+
default: undefined;
|
|
7
|
+
};
|
|
8
|
+
defaultValue: {
|
|
9
|
+
type: PropType<number | null>;
|
|
10
|
+
default: undefined;
|
|
11
|
+
};
|
|
12
|
+
min: {
|
|
13
|
+
type: NumberConstructor;
|
|
14
|
+
required: false;
|
|
15
|
+
};
|
|
16
|
+
max: {
|
|
17
|
+
type: NumberConstructor;
|
|
18
|
+
required: false;
|
|
19
|
+
};
|
|
20
|
+
step: {
|
|
21
|
+
type: NumberConstructor;
|
|
22
|
+
required: false;
|
|
23
|
+
};
|
|
24
|
+
largeStep: {
|
|
25
|
+
type: NumberConstructor;
|
|
26
|
+
required: false;
|
|
27
|
+
};
|
|
28
|
+
smallStep: {
|
|
29
|
+
type: NumberConstructor;
|
|
30
|
+
required: false;
|
|
31
|
+
};
|
|
32
|
+
precision: {
|
|
33
|
+
type: NumberConstructor;
|
|
34
|
+
required: false;
|
|
35
|
+
};
|
|
36
|
+
format: {
|
|
37
|
+
type: PropType<Intl.NumberFormatOptions | ((value: number) => string)>;
|
|
38
|
+
required: false;
|
|
39
|
+
};
|
|
40
|
+
parse: {
|
|
41
|
+
type: PropType<(text: string) => number | undefined>;
|
|
42
|
+
required: false;
|
|
43
|
+
};
|
|
44
|
+
locale: {
|
|
45
|
+
type: StringConstructor;
|
|
46
|
+
required: false;
|
|
47
|
+
};
|
|
48
|
+
wheel: {
|
|
49
|
+
type: BooleanConstructor;
|
|
50
|
+
default: boolean;
|
|
51
|
+
};
|
|
52
|
+
disabled: {
|
|
53
|
+
type: BooleanConstructor;
|
|
54
|
+
default: undefined;
|
|
55
|
+
};
|
|
56
|
+
readOnly: {
|
|
57
|
+
type: BooleanConstructor;
|
|
58
|
+
default: boolean;
|
|
59
|
+
};
|
|
60
|
+
required: {
|
|
61
|
+
type: BooleanConstructor;
|
|
62
|
+
default: boolean;
|
|
63
|
+
};
|
|
64
|
+
label: {
|
|
65
|
+
type: StringConstructor;
|
|
66
|
+
default: string;
|
|
67
|
+
};
|
|
68
|
+
name: {
|
|
69
|
+
type: StringConstructor;
|
|
70
|
+
default: undefined;
|
|
71
|
+
};
|
|
72
|
+
form: {
|
|
73
|
+
type: StringConstructor;
|
|
74
|
+
required: false;
|
|
75
|
+
};
|
|
76
|
+
controlId: {
|
|
77
|
+
type: PropType<string>;
|
|
78
|
+
default: undefined;
|
|
79
|
+
};
|
|
80
|
+
modelValue: {
|
|
81
|
+
type: PropType<number | null>;
|
|
82
|
+
default: undefined;
|
|
83
|
+
};
|
|
84
|
+
}>, () => import("vue").VNodeChild, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, OptionEmits<import("@bevelo/core").PrimitiveNumberInputOptions> & ModelEmits<import("@bevelo/core").PrimitiveNumberInputOptions, {
|
|
85
|
+
readonly modelValue: readonly ["value", "onChange"];
|
|
86
|
+
readonly value: readonly ["value", "onChange"];
|
|
87
|
+
}>, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
88
|
+
value: {
|
|
89
|
+
type: PropType<number | null>;
|
|
90
|
+
default: undefined;
|
|
91
|
+
};
|
|
92
|
+
defaultValue: {
|
|
93
|
+
type: PropType<number | null>;
|
|
94
|
+
default: undefined;
|
|
95
|
+
};
|
|
96
|
+
min: {
|
|
97
|
+
type: NumberConstructor;
|
|
98
|
+
required: false;
|
|
99
|
+
};
|
|
100
|
+
max: {
|
|
101
|
+
type: NumberConstructor;
|
|
102
|
+
required: false;
|
|
103
|
+
};
|
|
104
|
+
step: {
|
|
105
|
+
type: NumberConstructor;
|
|
106
|
+
required: false;
|
|
107
|
+
};
|
|
108
|
+
largeStep: {
|
|
109
|
+
type: NumberConstructor;
|
|
110
|
+
required: false;
|
|
111
|
+
};
|
|
112
|
+
smallStep: {
|
|
113
|
+
type: NumberConstructor;
|
|
114
|
+
required: false;
|
|
115
|
+
};
|
|
116
|
+
precision: {
|
|
117
|
+
type: NumberConstructor;
|
|
118
|
+
required: false;
|
|
119
|
+
};
|
|
120
|
+
format: {
|
|
121
|
+
type: PropType<Intl.NumberFormatOptions | ((value: number) => string)>;
|
|
122
|
+
required: false;
|
|
123
|
+
};
|
|
124
|
+
parse: {
|
|
125
|
+
type: PropType<(text: string) => number | undefined>;
|
|
126
|
+
required: false;
|
|
127
|
+
};
|
|
128
|
+
locale: {
|
|
129
|
+
type: StringConstructor;
|
|
130
|
+
required: false;
|
|
131
|
+
};
|
|
132
|
+
wheel: {
|
|
133
|
+
type: BooleanConstructor;
|
|
134
|
+
default: boolean;
|
|
135
|
+
};
|
|
136
|
+
disabled: {
|
|
137
|
+
type: BooleanConstructor;
|
|
138
|
+
default: undefined;
|
|
139
|
+
};
|
|
140
|
+
readOnly: {
|
|
141
|
+
type: BooleanConstructor;
|
|
142
|
+
default: boolean;
|
|
143
|
+
};
|
|
144
|
+
required: {
|
|
145
|
+
type: BooleanConstructor;
|
|
146
|
+
default: boolean;
|
|
147
|
+
};
|
|
148
|
+
label: {
|
|
149
|
+
type: StringConstructor;
|
|
150
|
+
default: string;
|
|
151
|
+
};
|
|
152
|
+
name: {
|
|
153
|
+
type: StringConstructor;
|
|
154
|
+
default: undefined;
|
|
155
|
+
};
|
|
156
|
+
form: {
|
|
157
|
+
type: StringConstructor;
|
|
158
|
+
required: false;
|
|
159
|
+
};
|
|
160
|
+
controlId: {
|
|
161
|
+
type: PropType<string>;
|
|
162
|
+
default: undefined;
|
|
163
|
+
};
|
|
164
|
+
modelValue: {
|
|
165
|
+
type: PropType<number | null>;
|
|
166
|
+
default: undefined;
|
|
167
|
+
};
|
|
168
|
+
}>> & Readonly<{
|
|
169
|
+
onChange?: (value: number | null, details: import("@bevelo/core").NumberInputChangeDetails) => any;
|
|
170
|
+
"onUpdate:modelValue"?: (value: number | null) => any;
|
|
171
|
+
"onUpdate:value"?: (value: number | null) => any;
|
|
172
|
+
onCommit?: (value: number | null, details: import("@bevelo/core").NumberInputCommitDetails) => any;
|
|
173
|
+
}>, {
|
|
174
|
+
value: number | null;
|
|
175
|
+
label: string;
|
|
176
|
+
required: boolean;
|
|
177
|
+
modelValue: number | null;
|
|
178
|
+
defaultValue: number | null;
|
|
179
|
+
name: string;
|
|
180
|
+
wheel: boolean;
|
|
181
|
+
disabled: boolean;
|
|
182
|
+
readOnly: boolean;
|
|
183
|
+
controlId: string;
|
|
184
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
185
|
+
/** Props for `NumberInput`. */
|
|
186
|
+
export type NumberInputProps = InstanceType<typeof NumberInput>["$props"];
|
|
187
|
+
/**
|
|
188
|
+
* Drag across it to change the value. Inside a `NumberInput` it renders the
|
|
189
|
+
* primitive's scrub area; outside, it starts scrubs through `controller`, the
|
|
190
|
+
* number input's exposed `api`. Its default slot receives the part's state.
|
|
191
|
+
*/
|
|
192
|
+
export declare const NumberInputScrubArea: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
193
|
+
orientation: {
|
|
194
|
+
type: PropType<"horizontal" | "vertical">;
|
|
195
|
+
required: false;
|
|
196
|
+
};
|
|
197
|
+
pixelsPerStep: {
|
|
198
|
+
type: NumberConstructor;
|
|
199
|
+
required: false;
|
|
200
|
+
};
|
|
201
|
+
controller: {
|
|
202
|
+
type: PropType<{
|
|
203
|
+
scrub(event: PointerEvent, area: HTMLElement): void;
|
|
204
|
+
}>;
|
|
205
|
+
required: false;
|
|
206
|
+
};
|
|
207
|
+
as: {
|
|
208
|
+
type: StringConstructor;
|
|
209
|
+
required: false;
|
|
210
|
+
};
|
|
211
|
+
}>, () => string | number | boolean | void | import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
212
|
+
[key: string]: any;
|
|
213
|
+
}> | import("vue").VNodeArrayChildren | null, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
214
|
+
orientation: {
|
|
215
|
+
type: PropType<"horizontal" | "vertical">;
|
|
216
|
+
required: false;
|
|
217
|
+
};
|
|
218
|
+
pixelsPerStep: {
|
|
219
|
+
type: NumberConstructor;
|
|
220
|
+
required: false;
|
|
221
|
+
};
|
|
222
|
+
controller: {
|
|
223
|
+
type: PropType<{
|
|
224
|
+
scrub(event: PointerEvent, area: HTMLElement): void;
|
|
225
|
+
}>;
|
|
226
|
+
required: false;
|
|
227
|
+
};
|
|
228
|
+
as: {
|
|
229
|
+
type: StringConstructor;
|
|
230
|
+
required: false;
|
|
231
|
+
};
|
|
232
|
+
}>> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
@@ -0,0 +1,232 @@
|
|
|
1
|
+
import { n as OptionEmits, t as ModelEmits } from "./options-CGl5jBEY.js";
|
|
2
|
+
import { PropType } from "vue";
|
|
3
|
+
export declare const NumberInput: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
4
|
+
value: {
|
|
5
|
+
type: PropType<number | null>;
|
|
6
|
+
default: undefined;
|
|
7
|
+
};
|
|
8
|
+
defaultValue: {
|
|
9
|
+
type: PropType<number | null>;
|
|
10
|
+
default: undefined;
|
|
11
|
+
};
|
|
12
|
+
min: {
|
|
13
|
+
type: NumberConstructor;
|
|
14
|
+
required: false;
|
|
15
|
+
};
|
|
16
|
+
max: {
|
|
17
|
+
type: NumberConstructor;
|
|
18
|
+
required: false;
|
|
19
|
+
};
|
|
20
|
+
step: {
|
|
21
|
+
type: NumberConstructor;
|
|
22
|
+
required: false;
|
|
23
|
+
};
|
|
24
|
+
largeStep: {
|
|
25
|
+
type: NumberConstructor;
|
|
26
|
+
required: false;
|
|
27
|
+
};
|
|
28
|
+
smallStep: {
|
|
29
|
+
type: NumberConstructor;
|
|
30
|
+
required: false;
|
|
31
|
+
};
|
|
32
|
+
precision: {
|
|
33
|
+
type: NumberConstructor;
|
|
34
|
+
required: false;
|
|
35
|
+
};
|
|
36
|
+
format: {
|
|
37
|
+
type: PropType<Intl.NumberFormatOptions | ((value: number) => string)>;
|
|
38
|
+
required: false;
|
|
39
|
+
};
|
|
40
|
+
parse: {
|
|
41
|
+
type: PropType<(text: string) => number | undefined>;
|
|
42
|
+
required: false;
|
|
43
|
+
};
|
|
44
|
+
locale: {
|
|
45
|
+
type: StringConstructor;
|
|
46
|
+
required: false;
|
|
47
|
+
};
|
|
48
|
+
wheel: {
|
|
49
|
+
type: BooleanConstructor;
|
|
50
|
+
default: boolean;
|
|
51
|
+
};
|
|
52
|
+
disabled: {
|
|
53
|
+
type: BooleanConstructor;
|
|
54
|
+
default: undefined;
|
|
55
|
+
};
|
|
56
|
+
readOnly: {
|
|
57
|
+
type: BooleanConstructor;
|
|
58
|
+
default: boolean;
|
|
59
|
+
};
|
|
60
|
+
required: {
|
|
61
|
+
type: BooleanConstructor;
|
|
62
|
+
default: boolean;
|
|
63
|
+
};
|
|
64
|
+
label: {
|
|
65
|
+
type: StringConstructor;
|
|
66
|
+
default: string;
|
|
67
|
+
};
|
|
68
|
+
name: {
|
|
69
|
+
type: StringConstructor;
|
|
70
|
+
default: undefined;
|
|
71
|
+
};
|
|
72
|
+
form: {
|
|
73
|
+
type: StringConstructor;
|
|
74
|
+
required: false;
|
|
75
|
+
};
|
|
76
|
+
controlId: {
|
|
77
|
+
type: PropType<string>;
|
|
78
|
+
default: undefined;
|
|
79
|
+
};
|
|
80
|
+
modelValue: {
|
|
81
|
+
type: PropType<number | null>;
|
|
82
|
+
default: undefined;
|
|
83
|
+
};
|
|
84
|
+
}>, () => import("vue").VNodeChild, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, OptionEmits<import("@bevelo/core").PrimitiveNumberInputOptions> & ModelEmits<import("@bevelo/core").PrimitiveNumberInputOptions, {
|
|
85
|
+
readonly modelValue: readonly ["value", "onChange"];
|
|
86
|
+
readonly value: readonly ["value", "onChange"];
|
|
87
|
+
}>, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
88
|
+
value: {
|
|
89
|
+
type: PropType<number | null>;
|
|
90
|
+
default: undefined;
|
|
91
|
+
};
|
|
92
|
+
defaultValue: {
|
|
93
|
+
type: PropType<number | null>;
|
|
94
|
+
default: undefined;
|
|
95
|
+
};
|
|
96
|
+
min: {
|
|
97
|
+
type: NumberConstructor;
|
|
98
|
+
required: false;
|
|
99
|
+
};
|
|
100
|
+
max: {
|
|
101
|
+
type: NumberConstructor;
|
|
102
|
+
required: false;
|
|
103
|
+
};
|
|
104
|
+
step: {
|
|
105
|
+
type: NumberConstructor;
|
|
106
|
+
required: false;
|
|
107
|
+
};
|
|
108
|
+
largeStep: {
|
|
109
|
+
type: NumberConstructor;
|
|
110
|
+
required: false;
|
|
111
|
+
};
|
|
112
|
+
smallStep: {
|
|
113
|
+
type: NumberConstructor;
|
|
114
|
+
required: false;
|
|
115
|
+
};
|
|
116
|
+
precision: {
|
|
117
|
+
type: NumberConstructor;
|
|
118
|
+
required: false;
|
|
119
|
+
};
|
|
120
|
+
format: {
|
|
121
|
+
type: PropType<Intl.NumberFormatOptions | ((value: number) => string)>;
|
|
122
|
+
required: false;
|
|
123
|
+
};
|
|
124
|
+
parse: {
|
|
125
|
+
type: PropType<(text: string) => number | undefined>;
|
|
126
|
+
required: false;
|
|
127
|
+
};
|
|
128
|
+
locale: {
|
|
129
|
+
type: StringConstructor;
|
|
130
|
+
required: false;
|
|
131
|
+
};
|
|
132
|
+
wheel: {
|
|
133
|
+
type: BooleanConstructor;
|
|
134
|
+
default: boolean;
|
|
135
|
+
};
|
|
136
|
+
disabled: {
|
|
137
|
+
type: BooleanConstructor;
|
|
138
|
+
default: undefined;
|
|
139
|
+
};
|
|
140
|
+
readOnly: {
|
|
141
|
+
type: BooleanConstructor;
|
|
142
|
+
default: boolean;
|
|
143
|
+
};
|
|
144
|
+
required: {
|
|
145
|
+
type: BooleanConstructor;
|
|
146
|
+
default: boolean;
|
|
147
|
+
};
|
|
148
|
+
label: {
|
|
149
|
+
type: StringConstructor;
|
|
150
|
+
default: string;
|
|
151
|
+
};
|
|
152
|
+
name: {
|
|
153
|
+
type: StringConstructor;
|
|
154
|
+
default: undefined;
|
|
155
|
+
};
|
|
156
|
+
form: {
|
|
157
|
+
type: StringConstructor;
|
|
158
|
+
required: false;
|
|
159
|
+
};
|
|
160
|
+
controlId: {
|
|
161
|
+
type: PropType<string>;
|
|
162
|
+
default: undefined;
|
|
163
|
+
};
|
|
164
|
+
modelValue: {
|
|
165
|
+
type: PropType<number | null>;
|
|
166
|
+
default: undefined;
|
|
167
|
+
};
|
|
168
|
+
}>> & Readonly<{
|
|
169
|
+
onChange?: (value: number | null, details: import("@bevelo/core").NumberInputChangeDetails) => any;
|
|
170
|
+
"onUpdate:modelValue"?: (value: number | null) => any;
|
|
171
|
+
"onUpdate:value"?: (value: number | null) => any;
|
|
172
|
+
onCommit?: (value: number | null, details: import("@bevelo/core").NumberInputCommitDetails) => any;
|
|
173
|
+
}>, {
|
|
174
|
+
value: number | null;
|
|
175
|
+
label: string;
|
|
176
|
+
required: boolean;
|
|
177
|
+
modelValue: number | null;
|
|
178
|
+
defaultValue: number | null;
|
|
179
|
+
name: string;
|
|
180
|
+
wheel: boolean;
|
|
181
|
+
disabled: boolean;
|
|
182
|
+
readOnly: boolean;
|
|
183
|
+
controlId: string;
|
|
184
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
185
|
+
/** Props for `NumberInput`. */
|
|
186
|
+
export type NumberInputProps = InstanceType<typeof NumberInput>["$props"];
|
|
187
|
+
/**
|
|
188
|
+
* Drag across it to change the value. Inside a `NumberInput` it renders the
|
|
189
|
+
* primitive's scrub area; outside, it starts scrubs through `controller`, the
|
|
190
|
+
* number input's exposed `api`. Its default slot receives the part's state.
|
|
191
|
+
*/
|
|
192
|
+
export declare const NumberInputScrubArea: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
193
|
+
orientation: {
|
|
194
|
+
type: PropType<"horizontal" | "vertical">;
|
|
195
|
+
required: false;
|
|
196
|
+
};
|
|
197
|
+
pixelsPerStep: {
|
|
198
|
+
type: NumberConstructor;
|
|
199
|
+
required: false;
|
|
200
|
+
};
|
|
201
|
+
controller: {
|
|
202
|
+
type: PropType<{
|
|
203
|
+
scrub(event: PointerEvent, area: HTMLElement): void;
|
|
204
|
+
}>;
|
|
205
|
+
required: false;
|
|
206
|
+
};
|
|
207
|
+
as: {
|
|
208
|
+
type: StringConstructor;
|
|
209
|
+
required: false;
|
|
210
|
+
};
|
|
211
|
+
}>, () => string | number | boolean | void | import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
212
|
+
[key: string]: any;
|
|
213
|
+
}> | import("vue").VNodeArrayChildren | null, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
214
|
+
orientation: {
|
|
215
|
+
type: PropType<"horizontal" | "vertical">;
|
|
216
|
+
required: false;
|
|
217
|
+
};
|
|
218
|
+
pixelsPerStep: {
|
|
219
|
+
type: NumberConstructor;
|
|
220
|
+
required: false;
|
|
221
|
+
};
|
|
222
|
+
controller: {
|
|
223
|
+
type: PropType<{
|
|
224
|
+
scrub(event: PointerEvent, area: HTMLElement): void;
|
|
225
|
+
}>;
|
|
226
|
+
required: false;
|
|
227
|
+
};
|
|
228
|
+
as: {
|
|
229
|
+
type: StringConstructor;
|
|
230
|
+
required: false;
|
|
231
|
+
};
|
|
232
|
+
}>> & Readonly<{}>, {}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
@@ -0,0 +1,187 @@
|
|
|
1
|
+
import { n as usePrimitive, r as fieldKey, t as renderPart } from "./headless-B3zQWaJm.js";
|
|
2
|
+
import { t as vueOptions } from "./options-BlkyK-uO.js";
|
|
3
|
+
import { focusNumberInput, numberInputPrimitive, startNumberInputScrub } from "@bevelo/core";
|
|
4
|
+
import { defineComponent, h, inject, provide, ref } from "vue";
|
|
5
|
+
// src/number-input.ts
|
|
6
|
+
const schema = vueOptions(numberInputPrimitive, {
|
|
7
|
+
modelValue: ["value", "onChange"],
|
|
8
|
+
value: ["value", "onChange"]
|
|
9
|
+
});
|
|
10
|
+
/** The number input a scrub area inside it renders its part from. */
|
|
11
|
+
const scrubTargetKey = Symbol("number-input-scrub");
|
|
12
|
+
const stepCall = (api, direction, options) => typeof options === "number" ? api.step(direction * options) : direction > 0 ? api.increment(options) : api.decrement(options);
|
|
13
|
+
const NumberInput = defineComponent({
|
|
14
|
+
name: "NumberInput",
|
|
15
|
+
inheritAttrs: false,
|
|
16
|
+
props: {
|
|
17
|
+
...schema.props,
|
|
18
|
+
value: {
|
|
19
|
+
type: [Number, null],
|
|
20
|
+
default: void 0
|
|
21
|
+
},
|
|
22
|
+
defaultValue: {
|
|
23
|
+
type: [Number, null],
|
|
24
|
+
default: void 0
|
|
25
|
+
},
|
|
26
|
+
min: {
|
|
27
|
+
type: Number,
|
|
28
|
+
required: false
|
|
29
|
+
},
|
|
30
|
+
max: {
|
|
31
|
+
type: Number,
|
|
32
|
+
required: false
|
|
33
|
+
},
|
|
34
|
+
step: {
|
|
35
|
+
type: Number,
|
|
36
|
+
required: false
|
|
37
|
+
},
|
|
38
|
+
largeStep: {
|
|
39
|
+
type: Number,
|
|
40
|
+
required: false
|
|
41
|
+
},
|
|
42
|
+
smallStep: {
|
|
43
|
+
type: Number,
|
|
44
|
+
required: false
|
|
45
|
+
},
|
|
46
|
+
precision: {
|
|
47
|
+
type: Number,
|
|
48
|
+
required: false
|
|
49
|
+
},
|
|
50
|
+
format: {
|
|
51
|
+
type: [Object, Function],
|
|
52
|
+
required: false
|
|
53
|
+
},
|
|
54
|
+
parse: {
|
|
55
|
+
type: Function,
|
|
56
|
+
required: false
|
|
57
|
+
},
|
|
58
|
+
locale: {
|
|
59
|
+
type: String,
|
|
60
|
+
required: false
|
|
61
|
+
},
|
|
62
|
+
wheel: {
|
|
63
|
+
type: Boolean,
|
|
64
|
+
default: false
|
|
65
|
+
},
|
|
66
|
+
disabled: {
|
|
67
|
+
type: Boolean,
|
|
68
|
+
default: void 0
|
|
69
|
+
},
|
|
70
|
+
readOnly: {
|
|
71
|
+
type: Boolean,
|
|
72
|
+
default: false
|
|
73
|
+
},
|
|
74
|
+
required: {
|
|
75
|
+
type: Boolean,
|
|
76
|
+
default: false
|
|
77
|
+
},
|
|
78
|
+
label: {
|
|
79
|
+
type: String,
|
|
80
|
+
default: ""
|
|
81
|
+
},
|
|
82
|
+
name: {
|
|
83
|
+
type: String,
|
|
84
|
+
default: void 0
|
|
85
|
+
},
|
|
86
|
+
form: {
|
|
87
|
+
type: String,
|
|
88
|
+
required: false
|
|
89
|
+
}
|
|
90
|
+
},
|
|
91
|
+
emits: schema.emits,
|
|
92
|
+
setup(props, { attrs, slots, expose }) {
|
|
93
|
+
const field = inject(fieldKey, null);
|
|
94
|
+
const handle = usePrimitive(numberInputPrimitive, schema.bind(props, () => {
|
|
95
|
+
const fieldOptions = field?.instance.options();
|
|
96
|
+
const fieldState = field?.instance.get();
|
|
97
|
+
return {
|
|
98
|
+
...field ? { controlId: field.api.controlId() } : {},
|
|
99
|
+
...props.name === void 0 && fieldOptions?.name !== void 0 ? { name: fieldOptions.name } : {},
|
|
100
|
+
...props.disabled === void 0 && fieldState?.disabled === true ? { disabled: true } : {}
|
|
101
|
+
};
|
|
102
|
+
}));
|
|
103
|
+
const kernel = handle.api;
|
|
104
|
+
expose({ api: {
|
|
105
|
+
getValue: () => kernel.getValue(),
|
|
106
|
+
setValue: (next, options) => kernel.setValue(next, options),
|
|
107
|
+
increment: (options) => stepCall(kernel, 1, options),
|
|
108
|
+
decrement: (options) => stepCall(kernel, -1, options),
|
|
109
|
+
focus: () => focusNumberInput(kernel),
|
|
110
|
+
scrub: (event, area) => startNumberInputScrub(kernel, event, area)
|
|
111
|
+
} });
|
|
112
|
+
provide(scrubTargetKey, handle);
|
|
113
|
+
return () => {
|
|
114
|
+
const decrement = renderPart(handle, "decrement", { key: "decrement" });
|
|
115
|
+
const control = renderPart(handle, "control", { key: "control" });
|
|
116
|
+
const increment = renderPart(handle, "increment", { key: "increment" });
|
|
117
|
+
const group = renderPart(handle, "group", { key: "group" }, [
|
|
118
|
+
decrement,
|
|
119
|
+
control,
|
|
120
|
+
increment
|
|
121
|
+
]);
|
|
122
|
+
const hidden = renderPart(handle, "input", { key: "input" });
|
|
123
|
+
return renderPart(handle, "root", { ...attrs }, [
|
|
124
|
+
...slots.default?.() ?? [],
|
|
125
|
+
group,
|
|
126
|
+
hidden
|
|
127
|
+
]);
|
|
128
|
+
};
|
|
129
|
+
}
|
|
130
|
+
});
|
|
131
|
+
/**
|
|
132
|
+
* Drag across it to change the value. Inside a `NumberInput` it renders the
|
|
133
|
+
* primitive's scrub area; outside, it starts scrubs through `controller`, the
|
|
134
|
+
* number input's exposed `api`. Its default slot receives the part's state.
|
|
135
|
+
*/
|
|
136
|
+
const NumberInputScrubArea = defineComponent({
|
|
137
|
+
name: "NumberInputScrubArea",
|
|
138
|
+
inheritAttrs: false,
|
|
139
|
+
props: {
|
|
140
|
+
orientation: {
|
|
141
|
+
type: String,
|
|
142
|
+
required: false
|
|
143
|
+
},
|
|
144
|
+
pixelsPerStep: {
|
|
145
|
+
type: Number,
|
|
146
|
+
required: false
|
|
147
|
+
},
|
|
148
|
+
controller: {
|
|
149
|
+
type: Object,
|
|
150
|
+
required: false
|
|
151
|
+
},
|
|
152
|
+
as: {
|
|
153
|
+
type: String,
|
|
154
|
+
required: false
|
|
155
|
+
}
|
|
156
|
+
},
|
|
157
|
+
setup(props, { attrs, slots }) {
|
|
158
|
+
const target = inject(scrubTargetKey, null);
|
|
159
|
+
const element = ref(null);
|
|
160
|
+
return () => {
|
|
161
|
+
const own = {
|
|
162
|
+
...attrs,
|
|
163
|
+
...props.orientation === void 0 ? {} : { "data-orientation": props.orientation },
|
|
164
|
+
...props.pixelsPerStep === void 0 ? {} : { "data-pixels-per-step": props.pixelsPerStep }
|
|
165
|
+
};
|
|
166
|
+
if (target !== null) {
|
|
167
|
+
const state = target.instance.part("scrub-area")?.state ?? {};
|
|
168
|
+
return renderPart(target, "scrub-area", props.as === void 0 ? own : {
|
|
169
|
+
...own,
|
|
170
|
+
tag: props.as
|
|
171
|
+
}, slots.default?.(state));
|
|
172
|
+
}
|
|
173
|
+
return h(props.as ?? "span", {
|
|
174
|
+
"data-orientation": "horizontal",
|
|
175
|
+
...own,
|
|
176
|
+
"data-part": "scrub-area",
|
|
177
|
+
"data-slot": "number-input-scrub-area",
|
|
178
|
+
style: "touch-action:none;user-select:none;-webkit-user-select:none",
|
|
179
|
+
ref: element,
|
|
180
|
+
onPointerdown: (event) => {
|
|
181
|
+
if (props.controller !== void 0 && element.value !== null) props.controller.scrub(event, element.value);
|
|
182
|
+
}
|
|
183
|
+
}, slots.default?.({}));
|
|
184
|
+
};
|
|
185
|
+
}
|
|
186
|
+
});
|
|
187
|
+
export { NumberInput, NumberInputScrubArea };
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
import { n as descriptionNodes } from "./describe-BlNg9SbK.js";
|
|
2
|
+
import { t as renderPart } from "./headless-B3zQWaJm.js";
|
|
3
|
+
import { Fragment, h } from "vue";
|
|
4
|
+
// src/option-row.ts
|
|
5
|
+
const EMPTY_LISTBOX_OPTIONS = [];
|
|
6
|
+
const EMPTY_LIST_ITEMS = [];
|
|
7
|
+
const PANEL_STYLE = {
|
|
8
|
+
position: "fixed",
|
|
9
|
+
left: "0",
|
|
10
|
+
top: "0"
|
|
11
|
+
};
|
|
12
|
+
const noop = () => {};
|
|
13
|
+
const optionMapCache = /* @__PURE__ */ new WeakMap();
|
|
14
|
+
/** Returns a cached value -> option map for O(1) lookups on adapter hot paths. */
|
|
15
|
+
function optionMapOf(options) {
|
|
16
|
+
let map = optionMapCache.get(options);
|
|
17
|
+
if (map === void 0) {
|
|
18
|
+
map = /* @__PURE__ */ new Map();
|
|
19
|
+
for (const option of options) map.set(option.value, option);
|
|
20
|
+
optionMapCache.set(options, map);
|
|
21
|
+
}
|
|
22
|
+
return map;
|
|
23
|
+
}
|
|
24
|
+
/** Slot props for one row, from its option part's state. */
|
|
25
|
+
function optionSlotProps(option, index, state) {
|
|
26
|
+
return {
|
|
27
|
+
option,
|
|
28
|
+
index,
|
|
29
|
+
selected: state?.selected === true,
|
|
30
|
+
active: state?.active === true,
|
|
31
|
+
disabled: option.disabled === true
|
|
32
|
+
};
|
|
33
|
+
}
|
|
34
|
+
/** Renders grouped and ungrouped option rows for list-backed overlay primitives (`Select`, `Combobox`). */
|
|
35
|
+
function renderOptionSections(handle, sections, slots) {
|
|
36
|
+
const optionRow = (entry) => {
|
|
37
|
+
const option = entry.option;
|
|
38
|
+
const address = {
|
|
39
|
+
index: entry.index,
|
|
40
|
+
scope: "item"
|
|
41
|
+
};
|
|
42
|
+
const scope = optionSlotProps(option, entry.index, handle.part("option", { index: entry.index })?.state);
|
|
43
|
+
const content = slots.option !== void 0 ? [slots.option(scope)] : [
|
|
44
|
+
renderPart(handle, "icon", { key: `${option.value}-icon` }, option.icon === void 0 ? void 0 : descriptionNodes([option.icon]), address),
|
|
45
|
+
renderPart(handle, "label", { key: `${option.value}-label` }, option.label, address),
|
|
46
|
+
renderPart(handle, "indicator", { key: `${option.value}-ind` }, slots.checkIcon?.(scope) ?? "✓", address)
|
|
47
|
+
];
|
|
48
|
+
return renderPart(handle, "option", { key: option.value }, [h(Fragment, null, content)], { index: entry.index });
|
|
49
|
+
};
|
|
50
|
+
const rows = [];
|
|
51
|
+
sections.forEach((section, index) => {
|
|
52
|
+
if (section.group === void 0) {
|
|
53
|
+
for (const entry of section.options) rows.push(optionRow(entry));
|
|
54
|
+
return;
|
|
55
|
+
}
|
|
56
|
+
const groupLabel = renderPart(handle, "label", { key: `gl${index}` }, section.group, {
|
|
57
|
+
index,
|
|
58
|
+
scope: "group"
|
|
59
|
+
});
|
|
60
|
+
rows.push(renderPart(handle, "group", { key: `section:${index}` }, [h(Fragment, null, [groupLabel, ...section.options.map(optionRow)])], { index }));
|
|
61
|
+
});
|
|
62
|
+
return rows;
|
|
63
|
+
}
|
|
64
|
+
export { optionMapOf as a, noop as i, EMPTY_LIST_ITEMS as n, optionSlotProps as o, PANEL_STYLE as r, renderOptionSections as s, EMPTY_LISTBOX_OPTIONS as t };
|