@vuetify/nightly 3.6.5-master.2024-05-12 → 3.6.5-master.2024-05-13

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.
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * Vuetify v3.6.5-master.2024-05-12
2
+ * Vuetify v3.6.5-master.2024-05-13
3
3
  * Forged by John Leider
4
4
  * Released under the MIT License.
5
5
  */
@@ -2078,9 +2078,9 @@ else{const{mount:a}=e
2078
2078
  e.mount=function(){const l=a(...arguments)
2079
2079
  return t.nextTick((()=>c.update())),e.mount=a,l}}Ct.reset(),("boolean"!=typeof __VUE_OPTIONS_API__||__VUE_OPTIONS_API__)&&e.mixin({computed:{$vuetify(){return t.reactive({defaults:lf.call(this,ct),display:lf.call(this,dn),theme:lf.call(this,ma),icons:lf.call(this,Dt),locale:lf.call(this,ca),date:lf.call(this,cu)})}}})}
2080
2080
  return{install:g,defaults:u,display:c,theme:d,icons:v,locale:p,date:f,goTo:m}}function lf(e){const t=this.$,a=t.parent?.provides??t.vnode.appContext?.provides
2081
- if(a&&e in a)return a[e]}af.version="3.6.5-master.2024-05-12"
2081
+ if(a&&e in a)return a[e]}af.version="3.6.5-master.2024-05-13"
2082
2082
  const of=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{}
2083
- return af({components:Gp,directives:tf,...e})},nf="3.6.5-master.2024-05-12"
2083
+ return af({components:Gp,directives:tf,...e})},nf="3.6.5-master.2024-05-13"
2084
2084
  of.version=nf,e.blueprints=Yt,e.components=Gp,e.createVuetify=of,e.directives=tf,e.useDate=pu,e.useDefaults=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0
2085
2085
  const{props:a,provideSubDefaults:l}=mt(e,t)
2086
2086
  return l(),a},e.useDisplay=yn,e.useGoTo=xn,e.useLayout=Qt,e.useLocale=va,e.useRtl=fa,e.useTheme=ba,e.version=nf}))
@@ -16,7 +16,7 @@ export const createVuetify = function () {
16
16
  ...options
17
17
  });
18
18
  };
19
- export const version = "3.6.5-master.2024-05-12";
19
+ export const version = "3.6.5-master.2024-05-13";
20
20
  createVuetify.version = version;
21
21
  export { blueprints, components, directives };
22
22
  export * from "./composables/index.mjs";
package/lib/framework.mjs CHANGED
@@ -97,7 +97,7 @@ export function createVuetify() {
97
97
  goTo
98
98
  };
99
99
  }
100
- export const version = "3.6.5-master.2024-05-12";
100
+ export const version = "3.6.5-master.2024-05-13";
101
101
  createVuetify.version = version;
102
102
 
103
103
  // Vue's inject() can only be used in setup
package/lib/index.d.mts CHANGED
@@ -493,28 +493,30 @@ declare module '@vue/runtime-core' {
493
493
  }
494
494
 
495
495
  export interface GlobalComponents {
496
- VApp: typeof import('vuetify/components')['VApp']
497
496
  VAlert: typeof import('vuetify/components')['VAlert']
498
497
  VAlertTitle: typeof import('vuetify/components')['VAlertTitle']
499
- VAutocomplete: typeof import('vuetify/components')['VAutocomplete']
498
+ VApp: typeof import('vuetify/components')['VApp']
499
+ VAvatar: typeof import('vuetify/components')['VAvatar']
500
500
  VAppBar: typeof import('vuetify/components')['VAppBar']
501
501
  VAppBarNavIcon: typeof import('vuetify/components')['VAppBarNavIcon']
502
502
  VAppBarTitle: typeof import('vuetify/components')['VAppBarTitle']
503
- VAvatar: typeof import('vuetify/components')['VAvatar']
503
+ VAutocomplete: typeof import('vuetify/components')['VAutocomplete']
504
504
  VBadge: typeof import('vuetify/components')['VBadge']
505
505
  VBanner: typeof import('vuetify/components')['VBanner']
506
506
  VBannerActions: typeof import('vuetify/components')['VBannerActions']
507
507
  VBannerText: typeof import('vuetify/components')['VBannerText']
508
- VBottomNavigation: typeof import('vuetify/components')['VBottomNavigation']
509
508
  VBreadcrumbs: typeof import('vuetify/components')['VBreadcrumbs']
510
509
  VBreadcrumbsItem: typeof import('vuetify/components')['VBreadcrumbsItem']
511
510
  VBreadcrumbsDivider: typeof import('vuetify/components')['VBreadcrumbsDivider']
511
+ VBottomNavigation: typeof import('vuetify/components')['VBottomNavigation']
512
512
  VBottomSheet: typeof import('vuetify/components')['VBottomSheet']
513
- VBtn: typeof import('vuetify/components')['VBtn']
514
513
  VBtnGroup: typeof import('vuetify/components')['VBtnGroup']
514
+ VBtn: typeof import('vuetify/components')['VBtn']
515
515
  VBtnToggle: typeof import('vuetify/components')['VBtnToggle']
516
516
  VCarousel: typeof import('vuetify/components')['VCarousel']
517
517
  VCarouselItem: typeof import('vuetify/components')['VCarouselItem']
518
+ VCheckbox: typeof import('vuetify/components')['VCheckbox']
519
+ VCheckboxBtn: typeof import('vuetify/components')['VCheckboxBtn']
518
520
  VCard: typeof import('vuetify/components')['VCard']
519
521
  VCardActions: typeof import('vuetify/components')['VCardActions']
520
522
  VCardItem: typeof import('vuetify/components')['VCardItem']
@@ -522,12 +524,15 @@ declare module '@vue/runtime-core' {
522
524
  VCardText: typeof import('vuetify/components')['VCardText']
523
525
  VCardTitle: typeof import('vuetify/components')['VCardTitle']
524
526
  VCode: typeof import('vuetify/components')['VCode']
525
- VCheckbox: typeof import('vuetify/components')['VCheckbox']
526
- VCheckboxBtn: typeof import('vuetify/components')['VCheckboxBtn']
527
- VChip: typeof import('vuetify/components')['VChip']
528
- VColorPicker: typeof import('vuetify/components')['VColorPicker']
529
527
  VChipGroup: typeof import('vuetify/components')['VChipGroup']
530
- VCounter: typeof import('vuetify/components')['VCounter']
528
+ VColorPicker: typeof import('vuetify/components')['VColorPicker']
529
+ VChip: typeof import('vuetify/components')['VChip']
530
+ VDatePicker: typeof import('vuetify/components')['VDatePicker']
531
+ VDatePickerControls: typeof import('vuetify/components')['VDatePickerControls']
532
+ VDatePickerHeader: typeof import('vuetify/components')['VDatePickerHeader']
533
+ VDatePickerMonth: typeof import('vuetify/components')['VDatePickerMonth']
534
+ VDatePickerMonths: typeof import('vuetify/components')['VDatePickerMonths']
535
+ VDatePickerYears: typeof import('vuetify/components')['VDatePickerYears']
531
536
  VCombobox: typeof import('vuetify/components')['VCombobox']
532
537
  VDataTable: typeof import('vuetify/components')['VDataTable']
533
538
  VDataTableHeaders: typeof import('vuetify/components')['VDataTableHeaders']
@@ -536,34 +541,30 @@ declare module '@vue/runtime-core' {
536
541
  VDataTableRow: typeof import('vuetify/components')['VDataTableRow']
537
542
  VDataTableVirtual: typeof import('vuetify/components')['VDataTableVirtual']
538
543
  VDataTableServer: typeof import('vuetify/components')['VDataTableServer']
539
- VDatePicker: typeof import('vuetify/components')['VDatePicker']
540
- VDatePickerControls: typeof import('vuetify/components')['VDatePickerControls']
541
- VDatePickerHeader: typeof import('vuetify/components')['VDatePickerHeader']
542
- VDatePickerMonth: typeof import('vuetify/components')['VDatePickerMonth']
543
- VDatePickerMonths: typeof import('vuetify/components')['VDatePickerMonths']
544
- VDatePickerYears: typeof import('vuetify/components')['VDatePickerYears']
545
- VDivider: typeof import('vuetify/components')['VDivider']
544
+ VCounter: typeof import('vuetify/components')['VCounter']
545
+ VFab: typeof import('vuetify/components')['VFab']
546
546
  VDialog: typeof import('vuetify/components')['VDialog']
547
+ VDivider: typeof import('vuetify/components')['VDivider']
548
+ VFileInput: typeof import('vuetify/components')['VFileInput']
549
+ VEmptyState: typeof import('vuetify/components')['VEmptyState']
547
550
  VExpansionPanels: typeof import('vuetify/components')['VExpansionPanels']
548
551
  VExpansionPanel: typeof import('vuetify/components')['VExpansionPanel']
549
552
  VExpansionPanelText: typeof import('vuetify/components')['VExpansionPanelText']
550
553
  VExpansionPanelTitle: typeof import('vuetify/components')['VExpansionPanelTitle']
551
- VEmptyState: typeof import('vuetify/components')['VEmptyState']
552
554
  VField: typeof import('vuetify/components')['VField']
553
555
  VFieldLabel: typeof import('vuetify/components')['VFieldLabel']
554
- VFab: typeof import('vuetify/components')['VFab']
555
- VFileInput: typeof import('vuetify/components')['VFileInput']
556
556
  VFooter: typeof import('vuetify/components')['VFooter']
557
557
  VIcon: typeof import('vuetify/components')['VIcon']
558
558
  VComponentIcon: typeof import('vuetify/components')['VComponentIcon']
559
559
  VSvgIcon: typeof import('vuetify/components')['VSvgIcon']
560
560
  VLigatureIcon: typeof import('vuetify/components')['VLigatureIcon']
561
561
  VClassIcon: typeof import('vuetify/components')['VClassIcon']
562
- VInput: typeof import('vuetify/components')['VInput']
563
- VInfiniteScroll: typeof import('vuetify/components')['VInfiniteScroll']
564
562
  VImg: typeof import('vuetify/components')['VImg']
563
+ VInfiniteScroll: typeof import('vuetify/components')['VInfiniteScroll']
564
+ VInput: typeof import('vuetify/components')['VInput']
565
565
  VItemGroup: typeof import('vuetify/components')['VItemGroup']
566
566
  VItem: typeof import('vuetify/components')['VItem']
567
+ VLabel: typeof import('vuetify/components')['VLabel']
567
568
  VKbd: typeof import('vuetify/components')['VKbd']
568
569
  VList: typeof import('vuetify/components')['VList']
569
570
  VListGroup: typeof import('vuetify/components')['VListGroup']
@@ -574,27 +575,26 @@ declare module '@vue/runtime-core' {
574
575
  VListItemSubtitle: typeof import('vuetify/components')['VListItemSubtitle']
575
576
  VListItemTitle: typeof import('vuetify/components')['VListItemTitle']
576
577
  VListSubheader: typeof import('vuetify/components')['VListSubheader']
577
- VLabel: typeof import('vuetify/components')['VLabel']
578
578
  VMenu: typeof import('vuetify/components')['VMenu']
579
- VNavigationDrawer: typeof import('vuetify/components')['VNavigationDrawer']
580
- VMessages: typeof import('vuetify/components')['VMessages']
581
579
  VMain: typeof import('vuetify/components')['VMain']
582
- VOverlay: typeof import('vuetify/components')['VOverlay']
580
+ VNavigationDrawer: typeof import('vuetify/components')['VNavigationDrawer']
583
581
  VOtpInput: typeof import('vuetify/components')['VOtpInput']
582
+ VMessages: typeof import('vuetify/components')['VMessages']
584
583
  VPagination: typeof import('vuetify/components')['VPagination']
584
+ VOverlay: typeof import('vuetify/components')['VOverlay']
585
585
  VProgressCircular: typeof import('vuetify/components')['VProgressCircular']
586
586
  VProgressLinear: typeof import('vuetify/components')['VProgressLinear']
587
- VRating: typeof import('vuetify/components')['VRating']
588
587
  VSelect: typeof import('vuetify/components')['VSelect']
589
588
  VRadioGroup: typeof import('vuetify/components')['VRadioGroup']
589
+ VRating: typeof import('vuetify/components')['VRating']
590
590
  VSelectionControl: typeof import('vuetify/components')['VSelectionControl']
591
- VSkeletonLoader: typeof import('vuetify/components')['VSkeletonLoader']
591
+ VSheet: typeof import('vuetify/components')['VSheet']
592
+ VSelectionControlGroup: typeof import('vuetify/components')['VSelectionControlGroup']
593
+ VSlider: typeof import('vuetify/components')['VSlider']
592
594
  VSlideGroup: typeof import('vuetify/components')['VSlideGroup']
593
595
  VSlideGroupItem: typeof import('vuetify/components')['VSlideGroupItem']
594
- VSelectionControlGroup: typeof import('vuetify/components')['VSelectionControlGroup']
595
- VSheet: typeof import('vuetify/components')['VSheet']
596
+ VSkeletonLoader: typeof import('vuetify/components')['VSkeletonLoader']
596
597
  VSnackbar: typeof import('vuetify/components')['VSnackbar']
597
- VSlider: typeof import('vuetify/components')['VSlider']
598
598
  VStepper: typeof import('vuetify/components')['VStepper']
599
599
  VStepperActions: typeof import('vuetify/components')['VStepperActions']
600
600
  VStepperHeader: typeof import('vuetify/components')['VStepperHeader']
@@ -602,42 +602,42 @@ declare module '@vue/runtime-core' {
602
602
  VStepperWindow: typeof import('vuetify/components')['VStepperWindow']
603
603
  VStepperWindowItem: typeof import('vuetify/components')['VStepperWindowItem']
604
604
  VSwitch: typeof import('vuetify/components')['VSwitch']
605
- VSystemBar: typeof import('vuetify/components')['VSystemBar']
605
+ VTextarea: typeof import('vuetify/components')['VTextarea']
606
606
  VTable: typeof import('vuetify/components')['VTable']
607
+ VTextField: typeof import('vuetify/components')['VTextField']
608
+ VSystemBar: typeof import('vuetify/components')['VSystemBar']
607
609
  VTab: typeof import('vuetify/components')['VTab']
608
610
  VTabs: typeof import('vuetify/components')['VTabs']
609
611
  VTabsWindow: typeof import('vuetify/components')['VTabsWindow']
610
612
  VTabsWindowItem: typeof import('vuetify/components')['VTabsWindowItem']
613
+ VTooltip: typeof import('vuetify/components')['VTooltip']
611
614
  VTimeline: typeof import('vuetify/components')['VTimeline']
612
615
  VTimelineItem: typeof import('vuetify/components')['VTimelineItem']
613
- VTextarea: typeof import('vuetify/components')['VTextarea']
614
- VTextField: typeof import('vuetify/components')['VTextField']
615
616
  VToolbar: typeof import('vuetify/components')['VToolbar']
616
617
  VToolbarTitle: typeof import('vuetify/components')['VToolbarTitle']
617
618
  VToolbarItems: typeof import('vuetify/components')['VToolbarItems']
618
- VTooltip: typeof import('vuetify/components')['VTooltip']
619
619
  VWindow: typeof import('vuetify/components')['VWindow']
620
620
  VWindowItem: typeof import('vuetify/components')['VWindowItem']
621
621
  VConfirmEdit: typeof import('vuetify/components')['VConfirmEdit']
622
622
  VDataIterator: typeof import('vuetify/components')['VDataIterator']
623
623
  VDefaultsProvider: typeof import('vuetify/components')['VDefaultsProvider']
624
+ VForm: typeof import('vuetify/components')['VForm']
624
625
  VContainer: typeof import('vuetify/components')['VContainer']
625
626
  VCol: typeof import('vuetify/components')['VCol']
626
627
  VRow: typeof import('vuetify/components')['VRow']
627
628
  VSpacer: typeof import('vuetify/components')['VSpacer']
628
- VForm: typeof import('vuetify/components')['VForm']
629
629
  VHover: typeof import('vuetify/components')['VHover']
630
630
  VLayout: typeof import('vuetify/components')['VLayout']
631
631
  VLayoutItem: typeof import('vuetify/components')['VLayoutItem']
632
632
  VLazy: typeof import('vuetify/components')['VLazy']
633
633
  VLocaleProvider: typeof import('vuetify/components')['VLocaleProvider']
634
634
  VNoSsr: typeof import('vuetify/components')['VNoSsr']
635
- VRadio: typeof import('vuetify/components')['VRadio']
636
635
  VParallax: typeof import('vuetify/components')['VParallax']
637
636
  VRangeSlider: typeof import('vuetify/components')['VRangeSlider']
637
+ VRadio: typeof import('vuetify/components')['VRadio']
638
638
  VResponsive: typeof import('vuetify/components')['VResponsive']
639
- VSpeedDial: typeof import('vuetify/components')['VSpeedDial']
640
639
  VSparkline: typeof import('vuetify/components')['VSparkline']
640
+ VSpeedDial: typeof import('vuetify/components')['VSpeedDial']
641
641
  VThemeProvider: typeof import('vuetify/components')['VThemeProvider']
642
642
  VValidation: typeof import('vuetify/components')['VValidation']
643
643
  VVirtualScroll: typeof import('vuetify/components')['VVirtualScroll']
@@ -657,6 +657,8 @@ declare module '@vue/runtime-core' {
657
657
  VExpandTransition: typeof import('vuetify/components')['VExpandTransition']
658
658
  VExpandXTransition: typeof import('vuetify/components')['VExpandXTransition']
659
659
  VDialogTransition: typeof import('vuetify/components')['VDialogTransition']
660
+ VPicker: typeof import('vuetify/labs/components')['VPicker']
661
+ VPickerTitle: typeof import('vuetify/labs/components')['VPickerTitle']
660
662
  VCalendar: typeof import('vuetify/labs/components')['VCalendar']
661
663
  VCalendarDay: typeof import('vuetify/labs/components')['VCalendarDay']
662
664
  VCalendarHeader: typeof import('vuetify/labs/components')['VCalendarHeader']
@@ -664,17 +666,15 @@ declare module '@vue/runtime-core' {
664
666
  VCalendarIntervalEvent: typeof import('vuetify/labs/components')['VCalendarIntervalEvent']
665
667
  VCalendarMonthDay: typeof import('vuetify/labs/components')['VCalendarMonthDay']
666
668
  VNumberInput: typeof import('vuetify/labs/components')['VNumberInput']
667
- VPicker: typeof import('vuetify/labs/components')['VPicker']
668
- VPickerTitle: typeof import('vuetify/labs/components')['VPickerTitle']
669
669
  VStepperVertical: typeof import('vuetify/labs/components')['VStepperVertical']
670
670
  VStepperVerticalItem: typeof import('vuetify/labs/components')['VStepperVerticalItem']
671
671
  VStepperVerticalActions: typeof import('vuetify/labs/components')['VStepperVerticalActions']
672
- VTimePicker: typeof import('vuetify/labs/components')['VTimePicker']
673
- VTimePickerClock: typeof import('vuetify/labs/components')['VTimePickerClock']
674
- VTimePickerControls: typeof import('vuetify/labs/components')['VTimePickerControls']
675
672
  VTreeview: typeof import('vuetify/labs/components')['VTreeview']
676
673
  VTreeviewItem: typeof import('vuetify/labs/components')['VTreeviewItem']
677
674
  VTreeviewGroup: typeof import('vuetify/labs/components')['VTreeviewGroup']
675
+ VTimePicker: typeof import('vuetify/labs/components')['VTimePicker']
676
+ VTimePickerClock: typeof import('vuetify/labs/components')['VTimePickerClock']
677
+ VTimePickerControls: typeof import('vuetify/labs/components')['VTimePickerControls']
678
678
  VDateInput: typeof import('vuetify/labs/components')['VDateInput']
679
679
  VPullToRefresh: typeof import('vuetify/labs/components')['VPullToRefresh']
680
680
  VSnackbarQueue: typeof import('vuetify/labs/components')['VSnackbarQueue']
@@ -84,10 +84,12 @@ export const VNumberInput = genericComponent()({
84
84
  if (canDecrease.value) model.value = +(model.value - props.step).toFixed(decimals);
85
85
  }
86
86
  }
87
- function onClickUp() {
87
+ function onClickUp(e) {
88
+ e.stopPropagation();
88
89
  toggleUpDown();
89
90
  }
90
- function onClickDown() {
91
+ function onClickDown(e) {
92
+ e.stopPropagation();
91
93
  toggleUpDown(false);
92
94
  }
93
95
  function onKeydown(e) {
@@ -111,6 +113,9 @@ export const VNumberInput = genericComponent()({
111
113
  function onModelUpdate(v) {
112
114
  model.value = v ? +v : undefined;
113
115
  }
116
+ function onControlMousedown(e) {
117
+ e.stopPropagation();
118
+ }
114
119
  useRender(() => {
115
120
  const {
116
121
  modelValue: _,
@@ -129,7 +134,8 @@ export const VNumberInput = genericComponent()({
129
134
  "icon": "$expand",
130
135
  "size": "small",
131
136
  "tabindex": "-1",
132
- "onClick": onClickDown
137
+ "onClick": onClickDown,
138
+ "onMousedown": onControlMousedown
133
139
  }, null) : _createVNode(VDefaultsProvider, {
134
140
  "key": "decrement-defaults",
135
141
  "defaults": {
@@ -153,6 +159,7 @@ export const VNumberInput = genericComponent()({
153
159
  "name": "increment-btn",
154
160
  "icon": "$collapse",
155
161
  "onClick": onClickUp,
162
+ "onMousedown": onControlMousedown,
156
163
  "size": "small",
157
164
  "tabindex": "-1"
158
165
  }, null) : _createVNode(VDefaultsProvider, {
@@ -185,7 +192,8 @@ export const VNumberInput = genericComponent()({
185
192
  "icon": "$plus",
186
193
  "tile": true,
187
194
  "tabindex": "-1",
188
- "onClick": onClickUp
195
+ "onClick": onClickUp,
196
+ "onMousedown": onControlMousedown
189
197
  }, null)]) : !props.reverse ? _createVNode(_Fragment, null, [dividerNode(), controlNode()]) : undefined;
190
198
  const hasAppendInner = slots['append-inner'] || appendInnerControl;
191
199
  const prependInnerControl = controlVariant.value === 'split' ? _createVNode("div", {
@@ -196,7 +204,8 @@ export const VNumberInput = genericComponent()({
196
204
  "icon": "$minus",
197
205
  "tile": true,
198
206
  "tabindex": "-1",
199
- "onClick": onClickDown
207
+ "onClick": onClickDown,
208
+ "onMousedown": onControlMousedown
200
209
  }, null), _createVNode(VDivider, {
201
210
  "vertical": true
202
211
  }, null)]) : props.reverse ? _createVNode(_Fragment, null, [controlNode(), dividerNode()]) : undefined;
@@ -214,7 +223,8 @@ export const VNumberInput = genericComponent()({
214
223
  'v-number-input--stacked': controlVariant.value === 'stacked'
215
224
  }, props.class]
216
225
  }, textFieldProps, {
217
- "style": props.style
226
+ "style": props.style,
227
+ "inputmode": "decimal"
218
228
  }), {
219
229
  ...slots,
220
230
  'append-inner': hasAppendInner ? function () {
@@ -1 +1 @@
1
- {"version":3,"file":"VNumberInput.mjs","names":["VBtn","VDefaultsProvider","VDivider","makeVTextFieldProps","VTextField","useProxiedModel","computed","watchEffect","clamp","genericComponent","getDecimals","omit","propsFactory","useRender","makeVNumberInputProps","controlVariant","type","String","default","inset","Boolean","hideInput","min","Number","Infinity","max","step","VNumberInput","name","inheritAttrs","props","emits","val","setup","_ref","attrs","emit","slots","model","stepDecimals","modelDecimals","value","canIncrease","canDecrease","incrementSlotProps","click","onClickUp","decrementSlotProps","onClickDown","toggleUpDown","increment","arguments","length","undefined","decimals","Math","toFixed","onKeydown","e","includes","key","ctrlKey","preventDefault","test","onModelUpdate","v","modelValue","_","textFieldProps","filterProps","controlNode","defaultHeight","_createVNode","decrement","disabled","flat","height","size","icon","dividerNode","appendInnerControl","reverse","_Fragment","hasAppendInner","prependInnerControl","hasPrependInner","_mergeProps","class","style","_len","args","Array","_key","_len2","_key2"],"sources":["../../../src/labs/VNumberInput/VNumberInput.tsx"],"sourcesContent":["// Styles\nimport './VNumberInput.sass'\n\n// Components\nimport { VBtn } from '../../components/VBtn'\nimport { VDefaultsProvider } from '../../components/VDefaultsProvider'\nimport { VDivider } from '../../components/VDivider'\nimport { makeVTextFieldProps, VTextField } from '@/components/VTextField/VTextField'\n\n// Composables\nimport { useProxiedModel } from '@/composables/proxiedModel'\n\n// Utilities\nimport { computed, watchEffect } from 'vue'\nimport { clamp, genericComponent, getDecimals, omit, propsFactory, useRender } from '@/util'\n\n// Types\nimport type { PropType } from 'vue'\nimport type { VTextFieldSlots } from '@/components/VTextField/VTextField'\n\ntype ControlSlot = {\n click: () => void\n}\n\ntype VNumberInputSlots = Omit<VTextFieldSlots, 'default'> & {\n increment: ControlSlot\n decrement: ControlSlot\n}\n\ntype ControlVariant = 'default' | 'stacked' | 'split'\n\nconst makeVNumberInputProps = propsFactory({\n controlVariant: {\n type: String as PropType<ControlVariant>,\n default: 'default',\n },\n inset: Boolean,\n hideInput: Boolean,\n min: {\n type: Number,\n default: -Infinity,\n },\n max: {\n type: Number,\n default: Infinity,\n },\n step: {\n type: Number,\n default: 1,\n },\n\n ...omit(makeVTextFieldProps(), ['appendInnerIcon', 'prependInnerIcon']),\n}, 'VNumberInput')\n\nexport const VNumberInput = genericComponent<VNumberInputSlots>()({\n name: 'VNumberInput',\n\n inheritAttrs: false,\n\n props: {\n ...makeVNumberInputProps(),\n },\n\n emits: {\n 'update:modelValue': (val: number) => true,\n },\n\n setup (props, { attrs, emit, slots }) {\n const model = useProxiedModel(props, 'modelValue')\n\n const stepDecimals = computed(() => getDecimals(props.step))\n const modelDecimals = computed(() => model.value != null ? getDecimals(model.value) : 0)\n\n const canIncrease = computed(() => {\n if (model.value == null) return true\n return model.value + props.step <= props.max\n })\n const canDecrease = computed(() => {\n if (model.value == null) return true\n return model.value - props.step >= props.min\n })\n\n watchEffect(() => {\n if (model.value != null && (model.value < props.min || model.value > props.max)) {\n model.value = clamp(model.value, props.min, props.max)\n }\n })\n\n const controlVariant = computed(() => {\n return props.hideInput ? 'stacked' : props.controlVariant\n })\n\n const incrementSlotProps = computed(() => ({ click: onClickUp }))\n\n const decrementSlotProps = computed(() => ({ click: onClickDown }))\n\n function toggleUpDown (increment = true) {\n if (model.value == null) {\n model.value = 0\n return\n }\n\n const decimals = Math.max(modelDecimals.value, stepDecimals.value)\n if (increment) {\n if (canIncrease.value) model.value = +(((model.value + props.step).toFixed(decimals)))\n } else {\n if (canDecrease.value) model.value = +(((model.value - props.step).toFixed(decimals)))\n }\n }\n\n function onClickUp () {\n toggleUpDown()\n }\n\n function onClickDown () {\n toggleUpDown(false)\n }\n\n function onKeydown (e: KeyboardEvent) {\n if (\n ['Enter', 'ArrowLeft', 'ArrowRight', 'Backspace', 'Tab'].includes(e.key) ||\n e.ctrlKey\n ) return\n\n if (['ArrowDown'].includes(e.key)) {\n e.preventDefault()\n toggleUpDown(false)\n return\n }\n if (['ArrowUp'].includes(e.key)) {\n e.preventDefault()\n toggleUpDown()\n return\n }\n\n // Only numbers, +, - & . are allowed\n if (!/^[0-9\\-+.]+$/.test(e.key)) {\n e.preventDefault()\n }\n }\n\n function onModelUpdate (v: string) {\n model.value = v ? +(v) : undefined\n }\n\n useRender(() => {\n const { modelValue: _, ...textFieldProps } = VTextField.filterProps(props)\n\n function controlNode () {\n const defaultHeight = controlVariant.value === 'stacked' ? 'auto' : '100%'\n return (\n <div class=\"v-number-input__control\">\n {\n !slots.decrement ? (\n <VBtn\n disabled={ !canDecrease.value }\n flat\n key=\"decrement-btn\"\n height={ defaultHeight }\n name=\"decrement-btn\"\n icon=\"$expand\"\n size=\"small\"\n tabindex=\"-1\"\n onClick={ onClickDown }\n />\n ) : (\n <VDefaultsProvider\n key=\"decrement-defaults\"\n defaults={{\n VBtn: {\n disabled: !canDecrease.value,\n flat: true,\n height: defaultHeight,\n size: 'small',\n icon: '$expand',\n },\n }}\n >\n { slots.decrement(decrementSlotProps.value) }\n </VDefaultsProvider>\n )\n }\n\n <VDivider\n vertical={ controlVariant.value !== 'stacked' }\n />\n\n {\n !slots.increment ? (\n <VBtn\n disabled={ !canIncrease.value }\n flat\n key=\"increment-btn\"\n height={ defaultHeight }\n name=\"increment-btn\"\n icon=\"$collapse\"\n onClick={ onClickUp }\n size=\"small\"\n tabindex=\"-1\"\n />\n ) : (\n <VDefaultsProvider\n key=\"increment-defaults\"\n defaults={{\n VBtn: {\n disabled: !canIncrease.value,\n flat: true,\n height: defaultHeight,\n size: 'small',\n icon: '$collapse',\n },\n }}\n >\n { slots.increment(incrementSlotProps.value) }\n </VDefaultsProvider>\n )\n }\n </div>\n )\n }\n\n function dividerNode () {\n return !props.hideInput && !props.inset ? <VDivider vertical /> : undefined\n }\n\n const appendInnerControl =\n controlVariant.value === 'split'\n ? (\n <div class=\"v-number-input__control\">\n <VDivider vertical />\n\n <VBtn\n flat\n height=\"100%\"\n icon=\"$plus\"\n tile\n tabindex=\"-1\"\n onClick={ onClickUp }\n />\n </div>\n ) : (!props.reverse\n ? <>{ dividerNode() }{ controlNode() }</>\n : undefined)\n\n const hasAppendInner = slots['append-inner'] || appendInnerControl\n\n const prependInnerControl =\n controlVariant.value === 'split'\n ? (\n <div class=\"v-number-input__control\">\n <VBtn\n flat\n height=\"100%\"\n icon=\"$minus\"\n tile\n tabindex=\"-1\"\n onClick={ onClickDown }\n />\n\n <VDivider vertical />\n </div>\n ) : (props.reverse\n ? <>{ controlNode() }{ dividerNode() }</>\n : undefined)\n\n const hasPrependInner = slots['prepend-inner'] || prependInnerControl\n\n return (\n <VTextField\n modelValue={ model.value }\n onUpdate:modelValue={ onModelUpdate }\n onKeydown={ onKeydown }\n class={[\n 'v-number-input',\n {\n 'v-number-input--default': controlVariant.value === 'default',\n 'v-number-input--hide-input': props.hideInput,\n 'v-number-input--inset': props.inset,\n 'v-number-input--reverse': props.reverse,\n 'v-number-input--split': controlVariant.value === 'split',\n 'v-number-input--stacked': controlVariant.value === 'stacked',\n },\n props.class,\n ]}\n { ...textFieldProps }\n style={ props.style }\n >\n {{\n ...slots,\n 'append-inner': hasAppendInner ? (...args) => (\n <>\n { slots['append-inner']?.(...args) }\n { appendInnerControl }\n </>\n ) : undefined,\n 'prepend-inner': hasPrependInner ? (...args) => (\n <>\n { prependInnerControl }\n { slots['prepend-inner']?.(...args) }\n </>\n ) : undefined,\n }}\n </VTextField>\n )\n })\n },\n})\n\nexport type VNumberInput = InstanceType<typeof VNumberInput>\n"],"mappings":";AAAA;AACA;;AAEA;AAAA,SACSA,IAAI;AAAA,SACJC,iBAAiB;AAAA,SACjBC,QAAQ;AAAA,SACRC,mBAAmB,EAAEC,UAAU,sDAExC;AAAA,SACSC,eAAe,8CAExB;AACA,SAASC,QAAQ,EAAEC,WAAW,QAAQ,KAAK;AAAA,SAClCC,KAAK,EAAEC,gBAAgB,EAAEC,WAAW,EAAEC,IAAI,EAAEC,YAAY,EAAEC,SAAS,gCAE5E;AAeA,MAAMC,qBAAqB,GAAGF,YAAY,CAAC;EACzCG,cAAc,EAAE;IACdC,IAAI,EAAEC,MAAkC;IACxCC,OAAO,EAAE;EACX,CAAC;EACDC,KAAK,EAAEC,OAAO;EACdC,SAAS,EAAED,OAAO;EAClBE,GAAG,EAAE;IACHN,IAAI,EAAEO,MAAM;IACZL,OAAO,EAAE,CAACM;EACZ,CAAC;EACDC,GAAG,EAAE;IACHT,IAAI,EAAEO,MAAM;IACZL,OAAO,EAAEM;EACX,CAAC;EACDE,IAAI,EAAE;IACJV,IAAI,EAAEO,MAAM;IACZL,OAAO,EAAE;EACX,CAAC;EAED,GAAGP,IAAI,CAACR,mBAAmB,CAAC,CAAC,EAAE,CAAC,iBAAiB,EAAE,kBAAkB,CAAC;AACxE,CAAC,EAAE,cAAc,CAAC;AAElB,OAAO,MAAMwB,YAAY,GAAGlB,gBAAgB,CAAoB,CAAC,CAAC;EAChEmB,IAAI,EAAE,cAAc;EAEpBC,YAAY,EAAE,KAAK;EAEnBC,KAAK,EAAE;IACL,GAAGhB,qBAAqB,CAAC;EA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AAA,MAAAA,IAAA,GAAAH,IAAA,EAAAG,IAAA;YAAJF,IAAI,CAAAE,IAAA,IAAAzC,SAAA,CAAAyC,IAAA;UAAA;UAAA,OAAApB,YAAA,CAAAU,SAAA,SAEnC7C,KAAK,CAAC,cAAc,CAAC,GAAG,GAAGqD,IAAI,CAAC,EAChCV,kBAAkB;QAAA,CAEvB,GAAG3B,SAAS;QACb,eAAe,EAAEgC,eAAe,GAAG;UAAA,SAAAQ,KAAA,GAAA1C,SAAA,CAAAC,MAAA,EAAIsC,IAAI,OAAAC,KAAA,CAAAE,KAAA,GAAAC,KAAA,MAAAA,KAAA,GAAAD,KAAA,EAAAC,KAAA;YAAJJ,IAAI,CAAAI,KAAA,IAAA3C,SAAA,CAAA2C,KAAA;UAAA;UAAA,OAAAtB,YAAA,CAAAU,SAAA,SAErCE,mBAAmB,EACnB/C,KAAK,CAAC,eAAe,CAAC,GAAG,GAAGqD,IAAI,CAAC;QAAA,CAEtC,GAAGrC;MAAS;IAIrB,CAAC,CAAC;EACJ;AACF,CAAC,CAAC","ignoreList":[]}
1
+ {"version":3,"file":"VNumberInput.mjs","names":["VBtn","VDefaultsProvider","VDivider","makeVTextFieldProps","VTextField","useProxiedModel","computed","watchEffect","clamp","genericComponent","getDecimals","omit","propsFactory","useRender","makeVNumberInputProps","controlVariant","type","String","default","inset","Boolean","hideInput","min","Number","Infinity","max","step","VNumberInput","name","inheritAttrs","props","emits","val","setup","_ref","attrs","emit","slots","model","stepDecimals","modelDecimals","value","canIncrease","canDecrease","incrementSlotProps","click","onClickUp","decrementSlotProps","onClickDown","toggleUpDown","increment","arguments","length","undefined","decimals","Math","toFixed","e","stopPropagation","onKeydown","includes","key","ctrlKey","preventDefault","test","onModelUpdate","v","onControlMousedown","modelValue","_","textFieldProps","filterProps","controlNode","defaultHeight","_createVNode","decrement","disabled","flat","height","size","icon","dividerNode","appendInnerControl","reverse","_Fragment","hasAppendInner","prependInnerControl","hasPrependInner","_mergeProps","class","style","_len","args","Array","_key","_len2","_key2"],"sources":["../../../src/labs/VNumberInput/VNumberInput.tsx"],"sourcesContent":["// Styles\nimport './VNumberInput.sass'\n\n// Components\nimport { VBtn } from '../../components/VBtn'\nimport { VDefaultsProvider } from '../../components/VDefaultsProvider'\nimport { VDivider } from '../../components/VDivider'\nimport { makeVTextFieldProps, VTextField } from '@/components/VTextField/VTextField'\n\n// Composables\nimport { useProxiedModel } from '@/composables/proxiedModel'\n\n// Utilities\nimport { computed, watchEffect } from 'vue'\nimport { clamp, genericComponent, getDecimals, omit, propsFactory, useRender } from '@/util'\n\n// Types\nimport type { PropType } from 'vue'\nimport type { VTextFieldSlots } from '@/components/VTextField/VTextField'\n\ntype ControlSlot = {\n click: (e: MouseEvent) => void\n}\n\ntype VNumberInputSlots = Omit<VTextFieldSlots, 'default'> & {\n increment: ControlSlot\n decrement: ControlSlot\n}\n\ntype ControlVariant = 'default' | 'stacked' | 'split'\n\nconst makeVNumberInputProps = propsFactory({\n controlVariant: {\n type: String as PropType<ControlVariant>,\n default: 'default',\n },\n inset: Boolean,\n hideInput: Boolean,\n min: {\n type: Number,\n default: -Infinity,\n },\n max: {\n type: Number,\n default: Infinity,\n },\n step: {\n type: Number,\n default: 1,\n },\n\n ...omit(makeVTextFieldProps(), ['appendInnerIcon', 'prependInnerIcon']),\n}, 'VNumberInput')\n\nexport const VNumberInput = genericComponent<VNumberInputSlots>()({\n name: 'VNumberInput',\n\n inheritAttrs: false,\n\n props: {\n ...makeVNumberInputProps(),\n },\n\n emits: {\n 'update:modelValue': (val: number) => true,\n },\n\n setup (props, { attrs, emit, slots }) {\n const model = useProxiedModel(props, 'modelValue')\n\n const stepDecimals = computed(() => getDecimals(props.step))\n const modelDecimals = computed(() => model.value != null ? getDecimals(model.value) : 0)\n\n const canIncrease = computed(() => {\n if (model.value == null) return true\n return model.value + props.step <= props.max\n })\n const canDecrease = computed(() => {\n if (model.value == null) return true\n return model.value - props.step >= props.min\n })\n\n watchEffect(() => {\n if (model.value != null && (model.value < props.min || model.value > props.max)) {\n model.value = clamp(model.value, props.min, props.max)\n }\n })\n\n const controlVariant = computed(() => {\n return props.hideInput ? 'stacked' : props.controlVariant\n })\n\n const incrementSlotProps = computed(() => ({ click: onClickUp }))\n\n const decrementSlotProps = computed(() => ({ click: onClickDown }))\n\n function toggleUpDown (increment = true) {\n if (model.value == null) {\n model.value = 0\n return\n }\n\n const decimals = Math.max(modelDecimals.value, stepDecimals.value)\n if (increment) {\n if (canIncrease.value) model.value = +(((model.value + props.step).toFixed(decimals)))\n } else {\n if (canDecrease.value) model.value = +(((model.value - props.step).toFixed(decimals)))\n }\n }\n\n function onClickUp (e: MouseEvent) {\n e.stopPropagation()\n toggleUpDown()\n }\n\n function onClickDown (e: MouseEvent) {\n e.stopPropagation()\n toggleUpDown(false)\n }\n\n function onKeydown (e: KeyboardEvent) {\n if (\n ['Enter', 'ArrowLeft', 'ArrowRight', 'Backspace', 'Tab'].includes(e.key) ||\n e.ctrlKey\n ) return\n\n if (['ArrowDown'].includes(e.key)) {\n e.preventDefault()\n toggleUpDown(false)\n return\n }\n if (['ArrowUp'].includes(e.key)) {\n e.preventDefault()\n toggleUpDown()\n return\n }\n\n // Only numbers, +, - & . are allowed\n if (!/^[0-9\\-+.]+$/.test(e.key)) {\n e.preventDefault()\n }\n }\n\n function onModelUpdate (v: string) {\n model.value = v ? +(v) : undefined\n }\n\n function onControlMousedown (e: MouseEvent) {\n e.stopPropagation()\n }\n\n useRender(() => {\n const { modelValue: _, ...textFieldProps } = VTextField.filterProps(props)\n\n function controlNode () {\n const defaultHeight = controlVariant.value === 'stacked' ? 'auto' : '100%'\n return (\n <div class=\"v-number-input__control\">\n {\n !slots.decrement ? (\n <VBtn\n disabled={ !canDecrease.value }\n flat\n key=\"decrement-btn\"\n height={ defaultHeight }\n name=\"decrement-btn\"\n icon=\"$expand\"\n size=\"small\"\n tabindex=\"-1\"\n onClick={ onClickDown }\n onMousedown={ onControlMousedown }\n />\n ) : (\n <VDefaultsProvider\n key=\"decrement-defaults\"\n defaults={{\n VBtn: {\n disabled: !canDecrease.value,\n flat: true,\n height: defaultHeight,\n size: 'small',\n icon: '$expand',\n },\n }}\n >\n { slots.decrement(decrementSlotProps.value) }\n </VDefaultsProvider>\n )\n }\n\n <VDivider\n vertical={ controlVariant.value !== 'stacked' }\n />\n\n {\n !slots.increment ? (\n <VBtn\n disabled={ !canIncrease.value }\n flat\n key=\"increment-btn\"\n height={ defaultHeight }\n name=\"increment-btn\"\n icon=\"$collapse\"\n onClick={ onClickUp }\n onMousedown={ onControlMousedown }\n size=\"small\"\n tabindex=\"-1\"\n />\n ) : (\n <VDefaultsProvider\n key=\"increment-defaults\"\n defaults={{\n VBtn: {\n disabled: !canIncrease.value,\n flat: true,\n height: defaultHeight,\n size: 'small',\n icon: '$collapse',\n },\n }}\n >\n { slots.increment(incrementSlotProps.value) }\n </VDefaultsProvider>\n )\n }\n </div>\n )\n }\n\n function dividerNode () {\n return !props.hideInput && !props.inset ? <VDivider vertical /> : undefined\n }\n\n const appendInnerControl =\n controlVariant.value === 'split'\n ? (\n <div class=\"v-number-input__control\">\n <VDivider vertical />\n\n <VBtn\n flat\n height=\"100%\"\n icon=\"$plus\"\n tile\n tabindex=\"-1\"\n onClick={ onClickUp }\n onMousedown={ onControlMousedown }\n />\n </div>\n ) : (!props.reverse\n ? <>{ dividerNode() }{ controlNode() }</>\n : undefined)\n\n const hasAppendInner = slots['append-inner'] || appendInnerControl\n\n const prependInnerControl =\n controlVariant.value === 'split'\n ? (\n <div class=\"v-number-input__control\">\n <VBtn\n flat\n height=\"100%\"\n icon=\"$minus\"\n tile\n tabindex=\"-1\"\n onClick={ onClickDown }\n onMousedown={ onControlMousedown }\n />\n\n <VDivider vertical />\n </div>\n ) : (props.reverse\n ? <>{ controlNode() }{ dividerNode() }</>\n : undefined)\n\n const hasPrependInner = slots['prepend-inner'] || prependInnerControl\n\n return (\n <VTextField\n modelValue={ model.value }\n onUpdate:modelValue={ onModelUpdate }\n onKeydown={ onKeydown }\n class={[\n 'v-number-input',\n {\n 'v-number-input--default': controlVariant.value === 'default',\n 'v-number-input--hide-input': props.hideInput,\n 'v-number-input--inset': props.inset,\n 'v-number-input--reverse': props.reverse,\n 'v-number-input--split': controlVariant.value === 'split',\n 'v-number-input--stacked': controlVariant.value === 'stacked',\n },\n props.class,\n ]}\n { ...textFieldProps }\n style={ props.style }\n inputmode=\"decimal\"\n >\n {{\n ...slots,\n 'append-inner': hasAppendInner ? (...args) => (\n <>\n { slots['append-inner']?.(...args) }\n { appendInnerControl }\n </>\n ) : undefined,\n 'prepend-inner': hasPrependInner ? (...args) => (\n <>\n { prependInnerControl }\n { slots['prepend-inner']?.(...args) }\n </>\n ) : undefined,\n }}\n </VTextField>\n )\n })\n },\n})\n\nexport type VNumberInput = InstanceType<typeof VNumberInput>\n"],"mappings":";AAAA;AACA;;AAEA;AAAA,SACSA,IAAI;AAAA,SACJC,iBAAiB;AAAA,SACjBC,QAAQ;AAAA,SACRC,mBAAmB,EAAEC,UAAU,sDAExC;AAAA,SACSC,eAAe,8CAExB;AACA,SAASC,QAAQ,EAAEC,WAAW,QAAQ,KAAK;AAAA,SAClCC,KAAK,EAAEC,gBAAgB,EAAEC,WAAW,EAAEC,IAAI,EAAEC,YAAY,EAAEC,SAAS,gCAE5E;AAeA,MAAMC,qBAAqB,GAAGF,YAAY,CAAC;EACzCG,cAAc,EAAE;IACdC,IAAI,EAAEC,MAAkC;IACxCC,OAAO,EAAE;EACX,CAAC;EACDC,KAAK,EAAEC,OAAO;EACdC,SAAS,EAAED,OAAO;EAClBE,GAAG,EAAE;IACHN,IAAI,EAAEO,MAAM;IACZL,OAAO,EAAE,CAACM;EACZ,CAAC;EACDC,GAAG,EAAE;IACHT,IAAI,EAAEO,MAAM;IACZL,OAAO,EAAEM;EACX,CAAC;EACDE,IAAI,EAAE;IACJV,IAAI,EAAEO,MAAM;IACZL,OAAO,EAAE;EACX,CAAC;EAED,GAAGP,IAAI,CAACR,mBAAmB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  }
52
52
 
53
53
  type ControlSlot = {
54
- click: () => void;
54
+ click: (e: MouseEvent) => void;
55
55
  };
56
56
  type ControlVariant = 'default' | 'stacked' | 'split';
57
57
  declare const VNumberInput: {
@@ -2902,7 +2902,7 @@ interface DefaultInputSlot {
2902
2902
  }
2903
2903
 
2904
2904
  type ControlSlot = {
2905
- click: () => void;
2905
+ click: (e: MouseEvent) => void;
2906
2906
  };
2907
2907
  type ControlVariant = 'default' | 'stacked' | 'split';
2908
2908
  declare const VNumberInput: {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@vuetify/nightly",
3
3
  "description": "Vue Material Component Framework",
4
- "version": "3.6.5-master.2024-05-12",
4
+ "version": "3.6.5-master.2024-05-13",
5
5
  "author": {
6
6
  "name": "John Leider",
7
7
  "email": "john@vuetifyjs.com"