vuetify 3.5.16 → 3.5.18
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/dist/json/attributes.json +226 -30
- package/dist/json/importMap-labs.json +12 -8
- package/dist/json/importMap.json +114 -114
- package/dist/json/tags.json +54 -0
- package/dist/json/web-types.json +607 -84
- package/dist/vuetify-labs.css +2293 -2267
- package/dist/vuetify-labs.d.ts +742 -64
- package/dist/vuetify-labs.esm.js +365 -132
- package/dist/vuetify-labs.esm.js.map +1 -1
- package/dist/vuetify-labs.js +364 -131
- package/dist/vuetify-labs.min.css +2 -2
- package/dist/vuetify.css +2324 -2298
- package/dist/vuetify.d.ts +120 -55
- package/dist/vuetify.esm.js +177 -104
- package/dist/vuetify.esm.js.map +1 -1
- package/dist/vuetify.js +176 -103
- package/dist/vuetify.js.map +1 -1
- package/dist/vuetify.min.css +2 -2
- package/dist/vuetify.min.js +183 -179
- package/dist/vuetify.min.js.map +1 -1
- package/lib/components/VAppBar/index.d.mts +1 -0
- package/lib/components/VAutocomplete/VAutocomplete.mjs +8 -10
- package/lib/components/VAutocomplete/VAutocomplete.mjs.map +1 -1
- package/lib/components/VBanner/VBanner.css +1 -1
- package/lib/components/VBreadcrumbs/VBreadcrumbs.css +1 -1
- package/lib/components/VBtn/index.d.mts +1 -0
- package/lib/components/VBtnToggle/index.d.mts +1 -0
- package/lib/components/VCard/VCard.css +3 -3
- package/lib/components/VCarousel/VCarouselItem.mjs +1 -1
- package/lib/components/VCarousel/VCarouselItem.mjs.map +1 -1
- package/lib/components/VCarousel/index.d.mts +1 -0
- package/lib/components/VChip/VChip.css +1 -1
- package/lib/components/VChip/VChip.sass +1 -0
- package/lib/components/VChipGroup/index.d.mts +1 -0
- package/lib/components/VCombobox/VCombobox.mjs +8 -10
- package/lib/components/VCombobox/VCombobox.mjs.map +1 -1
- package/lib/components/VDatePicker/VDatePicker.mjs +12 -2
- package/lib/components/VDatePicker/VDatePicker.mjs.map +1 -1
- package/lib/components/VDialog/VDialog.mjs +6 -2
- package/lib/components/VDialog/VDialog.mjs.map +1 -1
- package/lib/components/VDialog/__test__/VDialog.spec.cy.mjs +39 -0
- package/lib/components/VDialog/__test__/VDialog.spec.cy.mjs.map +1 -0
- package/lib/components/VDialog/index.d.mts +4 -10
- package/lib/components/VFileInput/VFileInput.mjs +1 -1
- package/lib/components/VFileInput/VFileInput.mjs.map +1 -1
- package/lib/components/VFileInput/index.d.mts +17 -5
- package/lib/components/VInput/VInput.mjs +6 -1
- package/lib/components/VInput/VInput.mjs.map +1 -1
- package/lib/components/VInput/index.d.mts +6 -0
- package/lib/components/VList/VList.mjs +2 -1
- package/lib/components/VList/VList.mjs.map +1 -1
- package/lib/components/VList/VListItem.css +1 -1
- package/lib/components/VNavigationDrawer/VNavigationDrawer.mjs +3 -3
- package/lib/components/VNavigationDrawer/VNavigationDrawer.mjs.map +1 -1
- package/lib/components/VNavigationDrawer/touch.mjs +16 -2
- package/lib/components/VNavigationDrawer/touch.mjs.map +1 -1
- package/lib/components/VProgressLinear/VProgressLinear.mjs +11 -1
- package/lib/components/VProgressLinear/VProgressLinear.mjs.map +1 -1
- package/lib/components/VProgressLinear/index.d.mts +21 -0
- package/lib/components/VRangeSlider/index.d.mts +6 -0
- package/lib/components/VSelect/VSelect.mjs +5 -1
- package/lib/components/VSelect/VSelect.mjs.map +1 -1
- package/lib/components/VSlideGroup/index.d.mts +1 -0
- package/lib/components/VSlider/index.d.mts +6 -0
- package/lib/components/VSnackbar/VSnackbar.css +18 -4
- package/lib/components/VSnackbar/VSnackbar.mjs +34 -9
- package/lib/components/VSnackbar/VSnackbar.mjs.map +1 -1
- package/lib/components/VSnackbar/VSnackbar.sass +19 -3
- package/lib/components/VSwitch/VSwitch.css +14 -2
- package/lib/components/VSwitch/VSwitch.sass +8 -2
- package/lib/components/VSystemBar/VSystemBar.css +1 -1
- package/lib/components/VTabs/index.d.mts +1 -0
- package/lib/components/VTextField/index.d.mts +15 -3
- package/lib/components/VTextarea/index.d.mts +15 -3
- package/lib/components/VWindow/index.d.mts +1 -0
- package/lib/components/index.d.mts +85 -21
- package/lib/composables/directiveComponent.mjs +4 -2
- package/lib/composables/directiveComponent.mjs.map +1 -1
- package/lib/composables/group.mjs +10 -1
- package/lib/composables/group.mjs.map +1 -1
- package/lib/entry-bundler.mjs +1 -1
- package/lib/framework.mjs +1 -1
- package/lib/index.d.mts +35 -34
- package/lib/labs/VCalendar/VCalendar.css +0 -1
- package/lib/labs/VCalendar/VCalendar.sass +0 -2
- package/lib/labs/VEmptyState/VEmptyState.css +3 -3
- package/lib/labs/VFab/VFab.css +1 -0
- package/lib/labs/VFab/VFab.mjs +3 -2
- package/lib/labs/VFab/VFab.mjs.map +1 -1
- package/lib/labs/VFab/VFab.sass +1 -0
- package/lib/labs/VFab/index.d.mts +10 -0
- package/lib/labs/VNumberInput/VNumberInput.mjs +79 -24
- package/lib/labs/VNumberInput/VNumberInput.mjs.map +1 -1
- package/lib/labs/VNumberInput/index.d.mts +56 -29
- package/lib/labs/VSnackbarQueue/VSnackbarQueue.mjs +112 -0
- package/lib/labs/VSnackbarQueue/VSnackbarQueue.mjs.map +1 -0
- package/lib/labs/VSnackbarQueue/index.d.mts +2693 -0
- package/lib/labs/VSnackbarQueue/index.mjs +2 -0
- package/lib/labs/VSnackbarQueue/index.mjs.map +1 -0
- package/lib/labs/VSpeedDial/VSpeedDial.mjs +1 -2
- package/lib/labs/VSpeedDial/VSpeedDial.mjs.map +1 -1
- package/lib/labs/VTimePicker/VTimePickerClock.mjs +1 -3
- package/lib/labs/VTimePicker/VTimePickerClock.mjs.map +1 -1
- package/lib/labs/VTimePicker/index.d.mts +6 -13
- package/lib/labs/components.d.mts +2893 -282
- package/lib/labs/components.mjs +1 -0
- package/lib/labs/components.mjs.map +1 -1
- package/lib/locale/af.mjs +1 -0
- package/lib/locale/af.mjs.map +1 -1
- package/lib/locale/ar.mjs +1 -0
- package/lib/locale/ar.mjs.map +1 -1
- package/lib/locale/az.mjs +1 -0
- package/lib/locale/az.mjs.map +1 -1
- package/lib/locale/bg.mjs +1 -0
- package/lib/locale/bg.mjs.map +1 -1
- package/lib/locale/ca.mjs +1 -0
- package/lib/locale/ca.mjs.map +1 -1
- package/lib/locale/ckb.mjs +1 -0
- package/lib/locale/ckb.mjs.map +1 -1
- package/lib/locale/cs.mjs +1 -0
- package/lib/locale/cs.mjs.map +1 -1
- package/lib/locale/da.mjs +1 -0
- package/lib/locale/da.mjs.map +1 -1
- package/lib/locale/de.mjs +1 -0
- package/lib/locale/de.mjs.map +1 -1
- package/lib/locale/el.mjs +1 -0
- package/lib/locale/el.mjs.map +1 -1
- package/lib/locale/en.mjs +1 -0
- package/lib/locale/en.mjs.map +1 -1
- package/lib/locale/es.mjs +1 -0
- package/lib/locale/es.mjs.map +1 -1
- package/lib/locale/et.mjs +1 -0
- package/lib/locale/et.mjs.map +1 -1
- package/lib/locale/fa.mjs +1 -0
- package/lib/locale/fa.mjs.map +1 -1
- package/lib/locale/fi.mjs +1 -0
- package/lib/locale/fi.mjs.map +1 -1
- package/lib/locale/fr.mjs +1 -0
- package/lib/locale/fr.mjs.map +1 -1
- package/lib/locale/he.mjs +1 -0
- package/lib/locale/he.mjs.map +1 -1
- package/lib/locale/hr.mjs +1 -0
- package/lib/locale/hr.mjs.map +1 -1
- package/lib/locale/hu.mjs +1 -0
- package/lib/locale/hu.mjs.map +1 -1
- package/lib/locale/id.mjs +1 -0
- package/lib/locale/id.mjs.map +1 -1
- package/lib/locale/index.d.mts +43 -0
- package/lib/locale/it.mjs +1 -0
- package/lib/locale/it.mjs.map +1 -1
- package/lib/locale/ja.mjs +1 -0
- package/lib/locale/ja.mjs.map +1 -1
- package/lib/locale/km.mjs +1 -0
- package/lib/locale/km.mjs.map +1 -1
- package/lib/locale/ko.mjs +9 -8
- package/lib/locale/ko.mjs.map +1 -1
- package/lib/locale/lt.mjs +1 -0
- package/lib/locale/lt.mjs.map +1 -1
- package/lib/locale/lv.mjs +1 -0
- package/lib/locale/lv.mjs.map +1 -1
- package/lib/locale/nl.mjs +1 -0
- package/lib/locale/nl.mjs.map +1 -1
- package/lib/locale/no.mjs +1 -0
- package/lib/locale/no.mjs.map +1 -1
- package/lib/locale/pl.mjs +1 -0
- package/lib/locale/pl.mjs.map +1 -1
- package/lib/locale/pt.mjs +1 -0
- package/lib/locale/pt.mjs.map +1 -1
- package/lib/locale/ro.mjs +1 -0
- package/lib/locale/ro.mjs.map +1 -1
- package/lib/locale/ru.mjs +1 -0
- package/lib/locale/ru.mjs.map +1 -1
- package/lib/locale/sk.mjs +1 -0
- package/lib/locale/sk.mjs.map +1 -1
- package/lib/locale/sl.mjs +1 -0
- package/lib/locale/sl.mjs.map +1 -1
- package/lib/locale/sr-Cyrl.mjs +1 -0
- package/lib/locale/sr-Cyrl.mjs.map +1 -1
- package/lib/locale/sr-Latn.mjs +1 -0
- package/lib/locale/sr-Latn.mjs.map +1 -1
- package/lib/locale/sv.mjs +1 -0
- package/lib/locale/sv.mjs.map +1 -1
- package/lib/locale/th.mjs +1 -0
- package/lib/locale/th.mjs.map +1 -1
- package/lib/locale/tr.mjs +1 -0
- package/lib/locale/tr.mjs.map +1 -1
- package/lib/locale/uk.mjs +1 -0
- package/lib/locale/uk.mjs.map +1 -1
- package/lib/locale/vi.mjs +1 -0
- package/lib/locale/vi.mjs.map +1 -1
- package/lib/locale/zh-Hans.mjs +1 -0
- package/lib/locale/zh-Hans.mjs.map +1 -1
- package/lib/locale/zh-Hant.mjs +1 -0
- package/lib/locale/zh-Hant.mjs.map +1 -1
- package/lib/styles/main.css +78 -78
- package/lib/styles/settings/_variables.scss +21 -14
- package/package.json +2 -2
package/dist/vuetify-labs.esm.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* Vuetify v3.5.
|
|
2
|
+
* Vuetify v3.5.18
|
|
3
3
|
* Forged by John Leider
|
|
4
4
|
* Released under the MIT License.
|
|
5
5
|
*/
|
|
6
6
|
|
|
7
|
-
import { Fragment, reactive, computed, watchEffect, toRefs, capitalize, isVNode, Comment, unref, warn, ref, provide, shallowRef, inject as inject$1, defineComponent as defineComponent$1, camelize, h, getCurrentInstance as getCurrentInstance$1, onBeforeUnmount, watch, readonly, onDeactivated, onActivated, onMounted, onScopeDispose, effectScope, toRaw, createVNode, TransitionGroup, Transition, mergeProps, isRef, toRef, onBeforeMount, nextTick, withDirectives, resolveDirective, vShow, Text, resolveDynamicComponent, Teleport, cloneVNode, createTextVNode, onUnmounted, onBeforeUpdate, withModifiers, toDisplayString, vModelText } from 'vue';
|
|
7
|
+
import { Fragment, reactive, computed, watchEffect, toRefs, capitalize, isVNode, Comment, unref, warn, ref, provide, shallowRef, inject as inject$1, defineComponent as defineComponent$1, camelize, h, getCurrentInstance as getCurrentInstance$1, onBeforeUnmount, watch, readonly, onDeactivated, onActivated, onMounted, onScopeDispose, effectScope, toRaw, createVNode, TransitionGroup, Transition, mergeProps, isRef, toRef, onBeforeMount, nextTick, withDirectives, resolveDirective, vShow, onUpdated, Text, resolveDynamicComponent, Teleport, cloneVNode, createTextVNode, onUnmounted, onBeforeUpdate, withModifiers, toDisplayString, vModelText } from 'vue';
|
|
8
8
|
|
|
9
9
|
// Types
|
|
10
10
|
// eslint-disable-line vue/prefer-import-from-vue
|
|
@@ -1931,6 +1931,7 @@ var en = {
|
|
|
1931
1931
|
badge: 'Badge',
|
|
1932
1932
|
open: 'Open',
|
|
1933
1933
|
close: 'Close',
|
|
1934
|
+
dismiss: 'Dismiss',
|
|
1934
1935
|
confirmEdit: {
|
|
1935
1936
|
ok: 'OK',
|
|
1936
1937
|
cancel: 'Cancel'
|
|
@@ -4155,6 +4156,7 @@ function useGroup(props, injectKey) {
|
|
|
4155
4156
|
const index = children.indexOf(vm);
|
|
4156
4157
|
if (unref(unwrapped.value) == null) {
|
|
4157
4158
|
unwrapped.value = index;
|
|
4159
|
+
unwrapped.useIndexAsValue = true;
|
|
4158
4160
|
}
|
|
4159
4161
|
if (index > -1) {
|
|
4160
4162
|
items.splice(index, 0, unwrapped);
|
|
@@ -4187,6 +4189,14 @@ function useGroup(props, injectKey) {
|
|
|
4187
4189
|
onBeforeUnmount(() => {
|
|
4188
4190
|
isUnmounted = true;
|
|
4189
4191
|
});
|
|
4192
|
+
onUpdated(() => {
|
|
4193
|
+
// #19655 update the items that use the index as the value.
|
|
4194
|
+
for (let i = 0; i < items.length; i++) {
|
|
4195
|
+
if (items[i].useIndexAsValue) {
|
|
4196
|
+
items[i].value = i;
|
|
4197
|
+
}
|
|
4198
|
+
}
|
|
4199
|
+
});
|
|
4190
4200
|
function select(id, value) {
|
|
4191
4201
|
const item = items.find(item => item.id === id);
|
|
4192
4202
|
if (value && item?.disabled) return;
|
|
@@ -4775,6 +4785,65 @@ const VProgressCircular = genericComponent()({
|
|
|
4775
4785
|
}
|
|
4776
4786
|
});
|
|
4777
4787
|
|
|
4788
|
+
// Composables
|
|
4789
|
+
|
|
4790
|
+
// Types
|
|
4791
|
+
|
|
4792
|
+
const oppositeMap = {
|
|
4793
|
+
center: 'center',
|
|
4794
|
+
top: 'bottom',
|
|
4795
|
+
bottom: 'top',
|
|
4796
|
+
left: 'right',
|
|
4797
|
+
right: 'left'
|
|
4798
|
+
};
|
|
4799
|
+
const makeLocationProps = propsFactory({
|
|
4800
|
+
location: String
|
|
4801
|
+
}, 'location');
|
|
4802
|
+
function useLocation(props) {
|
|
4803
|
+
let opposite = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
|
|
4804
|
+
let offset = arguments.length > 2 ? arguments[2] : undefined;
|
|
4805
|
+
const {
|
|
4806
|
+
isRtl
|
|
4807
|
+
} = useRtl();
|
|
4808
|
+
const locationStyles = computed(() => {
|
|
4809
|
+
if (!props.location) return {};
|
|
4810
|
+
const {
|
|
4811
|
+
side,
|
|
4812
|
+
align
|
|
4813
|
+
} = parseAnchor(props.location.split(' ').length > 1 ? props.location : `${props.location} center`, isRtl.value);
|
|
4814
|
+
function getOffset(side) {
|
|
4815
|
+
return offset ? offset(side) : 0;
|
|
4816
|
+
}
|
|
4817
|
+
const styles = {};
|
|
4818
|
+
if (side !== 'center') {
|
|
4819
|
+
if (opposite) styles[oppositeMap[side]] = `calc(100% - ${getOffset(side)}px)`;else styles[side] = 0;
|
|
4820
|
+
}
|
|
4821
|
+
if (align !== 'center') {
|
|
4822
|
+
if (opposite) styles[oppositeMap[align]] = `calc(100% - ${getOffset(align)}px)`;else styles[align] = 0;
|
|
4823
|
+
} else {
|
|
4824
|
+
if (side === 'center') styles.top = styles.left = '50%';else {
|
|
4825
|
+
styles[{
|
|
4826
|
+
top: 'left',
|
|
4827
|
+
bottom: 'left',
|
|
4828
|
+
left: 'top',
|
|
4829
|
+
right: 'top'
|
|
4830
|
+
}[side]] = '50%';
|
|
4831
|
+
}
|
|
4832
|
+
styles.transform = {
|
|
4833
|
+
top: 'translateX(-50%)',
|
|
4834
|
+
bottom: 'translateX(-50%)',
|
|
4835
|
+
left: 'translateY(-50%)',
|
|
4836
|
+
right: 'translateY(-50%)',
|
|
4837
|
+
center: 'translate(-50%, -50%)'
|
|
4838
|
+
}[side];
|
|
4839
|
+
}
|
|
4840
|
+
return styles;
|
|
4841
|
+
});
|
|
4842
|
+
return {
|
|
4843
|
+
locationStyles
|
|
4844
|
+
};
|
|
4845
|
+
}
|
|
4846
|
+
|
|
4778
4847
|
const makeVProgressLinearProps = propsFactory({
|
|
4779
4848
|
absolute: Boolean,
|
|
4780
4849
|
active: {
|
|
@@ -4807,6 +4876,9 @@ const makeVProgressLinearProps = propsFactory({
|
|
|
4807
4876
|
striped: Boolean,
|
|
4808
4877
|
roundedBar: Boolean,
|
|
4809
4878
|
...makeComponentProps(),
|
|
4879
|
+
...makeLocationProps({
|
|
4880
|
+
location: 'top'
|
|
4881
|
+
}),
|
|
4810
4882
|
...makeRoundedProps(),
|
|
4811
4883
|
...makeTagProps(),
|
|
4812
4884
|
...makeThemeProps()
|
|
@@ -4829,6 +4901,9 @@ const VProgressLinear = genericComponent()({
|
|
|
4829
4901
|
const {
|
|
4830
4902
|
themeClasses
|
|
4831
4903
|
} = provideTheme(props);
|
|
4904
|
+
const {
|
|
4905
|
+
locationStyles
|
|
4906
|
+
} = useLocation(props);
|
|
4832
4907
|
const {
|
|
4833
4908
|
textColorClasses,
|
|
4834
4909
|
textColorStyles
|
|
@@ -4878,8 +4953,11 @@ const VProgressLinear = genericComponent()({
|
|
|
4878
4953
|
'v-progress-linear--striped': props.striped
|
|
4879
4954
|
}, roundedClasses.value, themeClasses.value, rtlClasses.value, props.class],
|
|
4880
4955
|
"style": [{
|
|
4956
|
+
bottom: props.location === 'bottom' ? 0 : undefined,
|
|
4957
|
+
top: props.location === 'top' ? 0 : undefined,
|
|
4881
4958
|
height: props.active ? convertToUnit(height.value) : 0,
|
|
4882
|
-
'--v-progress-linear-height': convertToUnit(height.value)
|
|
4959
|
+
'--v-progress-linear-height': convertToUnit(height.value),
|
|
4960
|
+
...(props.absolute ? locationStyles.value : {})
|
|
4883
4961
|
}, props.style],
|
|
4884
4962
|
"role": "progressbar",
|
|
4885
4963
|
"aria-hidden": props.active ? 'false' : 'true',
|
|
@@ -4965,65 +5043,6 @@ function LoaderSlot(props, _ref) {
|
|
|
4965
5043
|
}, null)]);
|
|
4966
5044
|
}
|
|
4967
5045
|
|
|
4968
|
-
// Composables
|
|
4969
|
-
|
|
4970
|
-
// Types
|
|
4971
|
-
|
|
4972
|
-
const oppositeMap = {
|
|
4973
|
-
center: 'center',
|
|
4974
|
-
top: 'bottom',
|
|
4975
|
-
bottom: 'top',
|
|
4976
|
-
left: 'right',
|
|
4977
|
-
right: 'left'
|
|
4978
|
-
};
|
|
4979
|
-
const makeLocationProps = propsFactory({
|
|
4980
|
-
location: String
|
|
4981
|
-
}, 'location');
|
|
4982
|
-
function useLocation(props) {
|
|
4983
|
-
let opposite = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
|
|
4984
|
-
let offset = arguments.length > 2 ? arguments[2] : undefined;
|
|
4985
|
-
const {
|
|
4986
|
-
isRtl
|
|
4987
|
-
} = useRtl();
|
|
4988
|
-
const locationStyles = computed(() => {
|
|
4989
|
-
if (!props.location) return {};
|
|
4990
|
-
const {
|
|
4991
|
-
side,
|
|
4992
|
-
align
|
|
4993
|
-
} = parseAnchor(props.location.split(' ').length > 1 ? props.location : `${props.location} center`, isRtl.value);
|
|
4994
|
-
function getOffset(side) {
|
|
4995
|
-
return offset ? offset(side) : 0;
|
|
4996
|
-
}
|
|
4997
|
-
const styles = {};
|
|
4998
|
-
if (side !== 'center') {
|
|
4999
|
-
if (opposite) styles[oppositeMap[side]] = `calc(100% - ${getOffset(side)}px)`;else styles[side] = 0;
|
|
5000
|
-
}
|
|
5001
|
-
if (align !== 'center') {
|
|
5002
|
-
if (opposite) styles[oppositeMap[align]] = `calc(100% - ${getOffset(align)}px)`;else styles[align] = 0;
|
|
5003
|
-
} else {
|
|
5004
|
-
if (side === 'center') styles.top = styles.left = '50%';else {
|
|
5005
|
-
styles[{
|
|
5006
|
-
top: 'left',
|
|
5007
|
-
bottom: 'left',
|
|
5008
|
-
left: 'top',
|
|
5009
|
-
right: 'top'
|
|
5010
|
-
}[side]] = '50%';
|
|
5011
|
-
}
|
|
5012
|
-
styles.transform = {
|
|
5013
|
-
top: 'translateX(-50%)',
|
|
5014
|
-
bottom: 'translateX(-50%)',
|
|
5015
|
-
left: 'translateY(-50%)',
|
|
5016
|
-
right: 'translateY(-50%)',
|
|
5017
|
-
center: 'translate(-50%, -50%)'
|
|
5018
|
-
}[side];
|
|
5019
|
-
}
|
|
5020
|
-
return styles;
|
|
5021
|
-
});
|
|
5022
|
-
return {
|
|
5023
|
-
locationStyles
|
|
5024
|
-
};
|
|
5025
|
-
}
|
|
5026
|
-
|
|
5027
5046
|
// Utilities
|
|
5028
5047
|
|
|
5029
5048
|
// Types
|
|
@@ -6738,6 +6757,7 @@ const makeVInputProps = propsFactory({
|
|
|
6738
6757
|
'onClick:append': EventProp(),
|
|
6739
6758
|
...makeComponentProps(),
|
|
6740
6759
|
...makeDensityProps(),
|
|
6760
|
+
...makeThemeProps(),
|
|
6741
6761
|
...makeValidationProps()
|
|
6742
6762
|
}, 'VInput');
|
|
6743
6763
|
const VInput = genericComponent()({
|
|
@@ -6757,6 +6777,9 @@ const VInput = genericComponent()({
|
|
|
6757
6777
|
const {
|
|
6758
6778
|
densityClasses
|
|
6759
6779
|
} = useDensity(props);
|
|
6780
|
+
const {
|
|
6781
|
+
themeClasses
|
|
6782
|
+
} = provideTheme(props);
|
|
6760
6783
|
const {
|
|
6761
6784
|
rtlClasses
|
|
6762
6785
|
} = useRtl();
|
|
@@ -6810,7 +6833,7 @@ const VInput = genericComponent()({
|
|
|
6810
6833
|
"class": ['v-input', `v-input--${props.direction}`, {
|
|
6811
6834
|
'v-input--center-affix': props.centerAffix,
|
|
6812
6835
|
'v-input--hide-spin-buttons': props.hideSpinButtons
|
|
6813
|
-
}, densityClasses.value, rtlClasses.value, validationClasses.value, props.class],
|
|
6836
|
+
}, densityClasses.value, themeClasses.value, rtlClasses.value, validationClasses.value, props.class],
|
|
6814
6837
|
"style": props.style
|
|
6815
6838
|
}, [hasPrepend && createVNode("div", {
|
|
6816
6839
|
"key": "prepend",
|
|
@@ -9166,7 +9189,8 @@ const VList = genericComponent()({
|
|
|
9166
9189
|
if (!isFocused.value && !(e.relatedTarget && contentRef.value?.contains(e.relatedTarget))) focus();
|
|
9167
9190
|
}
|
|
9168
9191
|
function onKeydown(e) {
|
|
9169
|
-
|
|
9192
|
+
const target = e.target;
|
|
9193
|
+
if (!contentRef.value || ['INPUT', 'TEXTAREA'].includes(target.tagName)) return;
|
|
9170
9194
|
if (e.key === 'ArrowDown') {
|
|
9171
9195
|
focus('next');
|
|
9172
9196
|
} else if (e.key === 'ArrowUp') {
|
|
@@ -12080,6 +12104,10 @@ const VSelect = genericComponent()({
|
|
|
12080
12104
|
const item = items.value.find(item => item.title.toLowerCase().startsWith(keyboardLookupPrefix));
|
|
12081
12105
|
if (item !== undefined) {
|
|
12082
12106
|
model.value = [item];
|
|
12107
|
+
const index = displayItems.value.indexOf(item);
|
|
12108
|
+
IN_BROWSER && window.requestAnimationFrame(() => {
|
|
12109
|
+
index >= 0 && vVirtualScrollRef.value?.scrollToIndex(index);
|
|
12110
|
+
});
|
|
12083
12111
|
}
|
|
12084
12112
|
}
|
|
12085
12113
|
|
|
@@ -12128,7 +12156,7 @@ const VSelect = genericComponent()({
|
|
|
12128
12156
|
vTextFieldRef.value.value = '';
|
|
12129
12157
|
}
|
|
12130
12158
|
}
|
|
12131
|
-
watch(
|
|
12159
|
+
watch(menu, () => {
|
|
12132
12160
|
if (!props.hideSelected && menu.value && model.value.length) {
|
|
12133
12161
|
const index = displayItems.value.findIndex(item => model.value.some(s => props.valueComparator(s.value, item.value)));
|
|
12134
12162
|
IN_BROWSER && window.requestAnimationFrame(() => {
|
|
@@ -12582,16 +12610,14 @@ const VAutocomplete = genericComponent()({
|
|
|
12582
12610
|
listRef.value?.focus('next');
|
|
12583
12611
|
}
|
|
12584
12612
|
if (['Backspace', 'Delete'].includes(e.key)) {
|
|
12585
|
-
if (!props.multiple && hasSelectionSlot.value && model.value.length > 0) return select(model.value[0], false);
|
|
12586
|
-
if (selectionIndex.value
|
|
12587
|
-
|
|
12588
|
-
|
|
12589
|
-
|
|
12590
|
-
|
|
12613
|
+
if (!props.multiple && hasSelectionSlot.value && model.value.length > 0 && !search.value) return select(model.value[0], false);
|
|
12614
|
+
if (~selectionIndex.value) {
|
|
12615
|
+
const originalSelectionIndex = selectionIndex.value;
|
|
12616
|
+
select(model.value[selectionIndex.value], false);
|
|
12617
|
+
selectionIndex.value = originalSelectionIndex >= length - 1 ? length - 2 : originalSelectionIndex;
|
|
12618
|
+
} else if (e.key === 'Backspace' && !search.value) {
|
|
12619
|
+
selectionIndex.value = length - 1;
|
|
12591
12620
|
}
|
|
12592
|
-
const originalSelectionIndex = selectionIndex.value;
|
|
12593
|
-
select(model.value[selectionIndex.value], false);
|
|
12594
|
-
selectionIndex.value = originalSelectionIndex >= length - 1 ? length - 2 : originalSelectionIndex;
|
|
12595
12621
|
}
|
|
12596
12622
|
if (!props.multiple) return;
|
|
12597
12623
|
if (e.key === 'ArrowLeft') {
|
|
@@ -12639,7 +12665,7 @@ const VAutocomplete = genericComponent()({
|
|
|
12639
12665
|
listHasFocus.value = false;
|
|
12640
12666
|
}
|
|
12641
12667
|
function onUpdateModelValue(v) {
|
|
12642
|
-
if (v == null || v === '' && !props.multiple) model.value = [];
|
|
12668
|
+
if (v == null || v === '' && !props.multiple && !hasSelectionSlot.value) model.value = [];
|
|
12643
12669
|
}
|
|
12644
12670
|
const isSelecting = shallowRef(false);
|
|
12645
12671
|
|
|
@@ -13277,12 +13303,12 @@ const VDialog = genericComponent()({
|
|
|
13277
13303
|
name: 'VDialog',
|
|
13278
13304
|
props: makeVDialogProps(),
|
|
13279
13305
|
emits: {
|
|
13280
|
-
'click:outside': e => true,
|
|
13281
13306
|
'update:modelValue': value => true,
|
|
13282
13307
|
afterLeave: () => true
|
|
13283
13308
|
},
|
|
13284
13309
|
setup(props, _ref) {
|
|
13285
13310
|
let {
|
|
13311
|
+
emit,
|
|
13286
13312
|
slots
|
|
13287
13313
|
} = _ref;
|
|
13288
13314
|
const isActive = useProxiedModel(props, 'modelValue');
|
|
@@ -13325,6 +13351,9 @@ const VDialog = genericComponent()({
|
|
|
13325
13351
|
});
|
|
13326
13352
|
}
|
|
13327
13353
|
}
|
|
13354
|
+
function onAfterLeave() {
|
|
13355
|
+
emit('afterLeave');
|
|
13356
|
+
}
|
|
13328
13357
|
watch(isActive, async val => {
|
|
13329
13358
|
if (!val) {
|
|
13330
13359
|
await nextTick();
|
|
@@ -13356,7 +13385,8 @@ const VDialog = genericComponent()({
|
|
|
13356
13385
|
"activatorProps": activatorProps,
|
|
13357
13386
|
"contentProps": contentProps,
|
|
13358
13387
|
"role": "dialog",
|
|
13359
|
-
"onAfterEnter": onAfterEnter
|
|
13388
|
+
"onAfterEnter": onAfterEnter,
|
|
13389
|
+
"onAfterLeave": onAfterLeave
|
|
13360
13390
|
}, scopeId), {
|
|
13361
13391
|
activator: slots.activator,
|
|
13362
13392
|
default: function () {
|
|
@@ -14406,7 +14436,7 @@ const VCarouselItem = genericComponent()({
|
|
|
14406
14436
|
const imgProps = VImg.filterProps(props);
|
|
14407
14437
|
const windowItemProps = VWindowItem.filterProps(props);
|
|
14408
14438
|
return createVNode(VWindowItem, mergeProps({
|
|
14409
|
-
"class":
|
|
14439
|
+
"class": ['v-carousel-item', props.class]
|
|
14410
14440
|
}, windowItemProps), {
|
|
14411
14441
|
default: () => [createVNode(VImg, mergeProps(attrs, imgProps), slots)]
|
|
14412
14442
|
});
|
|
@@ -16411,16 +16441,14 @@ const VCombobox = genericComponent()({
|
|
|
16411
16441
|
if (hasSelectionSlot.value) _search.value = '';
|
|
16412
16442
|
}
|
|
16413
16443
|
if (['Backspace', 'Delete'].includes(e.key)) {
|
|
16414
|
-
if (!props.multiple && hasSelectionSlot.value && model.value.length > 0) return select(model.value[0], false);
|
|
16415
|
-
if (selectionIndex.value
|
|
16416
|
-
|
|
16417
|
-
|
|
16418
|
-
|
|
16419
|
-
|
|
16444
|
+
if (!props.multiple && hasSelectionSlot.value && model.value.length > 0 && !search.value) return select(model.value[0], false);
|
|
16445
|
+
if (~selectionIndex.value) {
|
|
16446
|
+
const originalSelectionIndex = selectionIndex.value;
|
|
16447
|
+
select(model.value[selectionIndex.value], false);
|
|
16448
|
+
selectionIndex.value = originalSelectionIndex >= length - 1 ? length - 2 : originalSelectionIndex;
|
|
16449
|
+
} else if (e.key === 'Backspace' && !search.value) {
|
|
16450
|
+
selectionIndex.value = length - 1;
|
|
16420
16451
|
}
|
|
16421
|
-
const originalSelectionIndex = selectionIndex.value;
|
|
16422
|
-
select(model.value[selectionIndex.value], false);
|
|
16423
|
-
selectionIndex.value = originalSelectionIndex >= length - 1 ? length - 2 : originalSelectionIndex;
|
|
16424
16452
|
}
|
|
16425
16453
|
if (!props.multiple) return;
|
|
16426
16454
|
if (e.key === 'ArrowLeft') {
|
|
@@ -16489,7 +16517,7 @@ const VCombobox = genericComponent()({
|
|
|
16489
16517
|
listHasFocus.value = false;
|
|
16490
16518
|
}
|
|
16491
16519
|
function onUpdateModelValue(v) {
|
|
16492
|
-
if (v == null || v === '' && !props.multiple) model.value = [];
|
|
16520
|
+
if (v == null || v === '' && !props.multiple && !hasSelectionSlot.value) model.value = [];
|
|
16493
16521
|
}
|
|
16494
16522
|
watch(isFocused, (val, oldVal) => {
|
|
16495
16523
|
if (val || val === oldVal) return;
|
|
@@ -21350,8 +21378,18 @@ const VDatePicker = genericComponent()({
|
|
|
21350
21378
|
emit('update:year', value);
|
|
21351
21379
|
}
|
|
21352
21380
|
watch(model, (val, oldVal) => {
|
|
21353
|
-
const before = adapter.date(wrapInArray(
|
|
21354
|
-
const after = adapter.date(wrapInArray(
|
|
21381
|
+
const before = adapter.date(wrapInArray(oldVal)[oldVal.length - 1]);
|
|
21382
|
+
const after = adapter.date(wrapInArray(val)[val.length - 1]);
|
|
21383
|
+
const newMonth = adapter.getMonth(after);
|
|
21384
|
+
const newYear = adapter.getYear(after);
|
|
21385
|
+
if (newMonth !== month.value) {
|
|
21386
|
+
month.value = newMonth;
|
|
21387
|
+
onUpdateMonth(month.value);
|
|
21388
|
+
}
|
|
21389
|
+
if (newYear !== year.value) {
|
|
21390
|
+
year.value = newYear;
|
|
21391
|
+
onUpdateYear(year.value);
|
|
21392
|
+
}
|
|
21355
21393
|
isReversing.value = adapter.isBefore(before, after);
|
|
21356
21394
|
});
|
|
21357
21395
|
useRender(() => {
|
|
@@ -21705,7 +21743,7 @@ const makeVFileInputProps = propsFactory({
|
|
|
21705
21743
|
}),
|
|
21706
21744
|
modelValue: {
|
|
21707
21745
|
type: [Array, Object],
|
|
21708
|
-
default:
|
|
21746
|
+
default: props => props.multiple ? [] : null,
|
|
21709
21747
|
validator: val => {
|
|
21710
21748
|
return wrapInArray(val).every(v => v != null && typeof v === 'object');
|
|
21711
21749
|
}
|
|
@@ -22734,6 +22772,7 @@ function oops$1() {
|
|
|
22734
22772
|
|
|
22735
22773
|
function useTouch(_ref) {
|
|
22736
22774
|
let {
|
|
22775
|
+
el,
|
|
22737
22776
|
isActive,
|
|
22738
22777
|
isTemporary,
|
|
22739
22778
|
width,
|
|
@@ -22783,10 +22822,10 @@ function useTouch(_ref) {
|
|
|
22783
22822
|
const inTouchZone = position.value === 'left' ? touchX < touchZone : position.value === 'right' ? touchX > document.documentElement.clientWidth - touchZone : position.value === 'top' ? touchY < touchZone : position.value === 'bottom' ? touchY > document.documentElement.clientHeight - touchZone : oops();
|
|
22784
22823
|
const inElement = isActive.value && (position.value === 'left' ? touchX < width.value : position.value === 'right' ? touchX > document.documentElement.clientWidth - width.value : position.value === 'top' ? touchY < width.value : position.value === 'bottom' ? touchY > document.documentElement.clientHeight - width.value : oops());
|
|
22785
22824
|
if (inTouchZone || inElement || isActive.value && isTemporary.value) {
|
|
22786
|
-
maybeDragging = true;
|
|
22787
22825
|
start = [touchX, touchY];
|
|
22788
22826
|
offset.value = getOffset(isHorizontal.value ? touchX : touchY, isActive.value);
|
|
22789
22827
|
dragProgress.value = getProgress(isHorizontal.value ? touchX : touchY);
|
|
22828
|
+
maybeDragging = offset.value > -20 && offset.value < 80;
|
|
22790
22829
|
endTouch(e);
|
|
22791
22830
|
addMovement(e);
|
|
22792
22831
|
}
|
|
@@ -22846,6 +22885,18 @@ function useTouch(_ref) {
|
|
|
22846
22885
|
transition: 'none'
|
|
22847
22886
|
} : undefined;
|
|
22848
22887
|
});
|
|
22888
|
+
useToggleScope(isDragging, () => {
|
|
22889
|
+
const transform = el.value?.style.transform ?? null;
|
|
22890
|
+
const transition = el.value?.style.transition ?? null;
|
|
22891
|
+
watchEffect(() => {
|
|
22892
|
+
el.value?.style.setProperty('transform', dragStyles.value?.transform || 'none');
|
|
22893
|
+
el.value?.style.setProperty('transition', dragStyles.value?.transition || null);
|
|
22894
|
+
});
|
|
22895
|
+
onScopeDispose(() => {
|
|
22896
|
+
el.value?.style.setProperty('transform', transform);
|
|
22897
|
+
el.value?.style.setProperty('transition', transition);
|
|
22898
|
+
});
|
|
22899
|
+
});
|
|
22849
22900
|
return {
|
|
22850
22901
|
isDragging,
|
|
22851
22902
|
dragProgress,
|
|
@@ -22978,9 +23029,9 @@ const VNavigationDrawer = genericComponent()({
|
|
|
22978
23029
|
});
|
|
22979
23030
|
const {
|
|
22980
23031
|
isDragging,
|
|
22981
|
-
dragProgress
|
|
22982
|
-
dragStyles
|
|
23032
|
+
dragProgress
|
|
22983
23033
|
} = useTouch({
|
|
23034
|
+
el: rootEl,
|
|
22984
23035
|
isActive,
|
|
22985
23036
|
isTemporary,
|
|
22986
23037
|
width,
|
|
@@ -23050,7 +23101,7 @@ const VNavigationDrawer = genericComponent()({
|
|
|
23050
23101
|
'v-navigation-drawer--active': isActive.value,
|
|
23051
23102
|
'v-navigation-drawer--sticky': isSticky.value
|
|
23052
23103
|
}, themeClasses.value, backgroundColorClasses.value, borderClasses.value, displayClasses.value, elevationClasses.value, roundedClasses.value, props.class],
|
|
23053
|
-
"style": [backgroundColorStyles.value, layoutItemStyles.value,
|
|
23104
|
+
"style": [backgroundColorStyles.value, layoutItemStyles.value, ssrBootStyles.value, stickyStyles.value, props.style]
|
|
23054
23105
|
}, scopeId, attrs), {
|
|
23055
23106
|
default: () => [hasImage && createVNode("div", {
|
|
23056
23107
|
"key": "image",
|
|
@@ -24160,9 +24211,6 @@ const VSnackbar = genericComponent()({
|
|
|
24160
24211
|
slots
|
|
24161
24212
|
} = _ref;
|
|
24162
24213
|
const isActive = useProxiedModel(props, 'modelValue');
|
|
24163
|
-
const {
|
|
24164
|
-
locationStyles
|
|
24165
|
-
} = useLocation(props);
|
|
24166
24214
|
const {
|
|
24167
24215
|
positionClasses
|
|
24168
24216
|
} = usePosition(props);
|
|
@@ -24184,6 +24232,15 @@ const VSnackbar = genericComponent()({
|
|
|
24184
24232
|
const overlay = ref();
|
|
24185
24233
|
const timerRef = ref();
|
|
24186
24234
|
const isHovering = shallowRef(false);
|
|
24235
|
+
const startY = shallowRef(0);
|
|
24236
|
+
const mainStyles = ref();
|
|
24237
|
+
const hasLayout = inject$1(VuetifyLayoutKey, undefined);
|
|
24238
|
+
useToggleScope(() => !!hasLayout, () => {
|
|
24239
|
+
const layout = useLayout();
|
|
24240
|
+
watchEffect(() => {
|
|
24241
|
+
mainStyles.value = layout.mainStyles.value;
|
|
24242
|
+
});
|
|
24243
|
+
});
|
|
24187
24244
|
watch(isActive, startTimeout);
|
|
24188
24245
|
watch(() => props.timeout, startTimeout);
|
|
24189
24246
|
onMounted(() => {
|
|
@@ -24213,6 +24270,20 @@ const VSnackbar = genericComponent()({
|
|
|
24213
24270
|
isHovering.value = false;
|
|
24214
24271
|
startTimeout();
|
|
24215
24272
|
}
|
|
24273
|
+
function onTouchstart(event) {
|
|
24274
|
+
startY.value = event.touches[0].clientY;
|
|
24275
|
+
}
|
|
24276
|
+
function onTouchend(event) {
|
|
24277
|
+
if (Math.abs(startY.value - event.changedTouches[0].clientY) > 50) {
|
|
24278
|
+
isActive.value = false;
|
|
24279
|
+
}
|
|
24280
|
+
}
|
|
24281
|
+
const locationClasses = computed(() => {
|
|
24282
|
+
return props.location.split(' ').reduce((acc, loc) => {
|
|
24283
|
+
acc[`v-snackbar--${loc}`] = true;
|
|
24284
|
+
return acc;
|
|
24285
|
+
}, {});
|
|
24286
|
+
});
|
|
24216
24287
|
useRender(() => {
|
|
24217
24288
|
const overlayProps = VOverlay.filterProps(props);
|
|
24218
24289
|
const hasContent = !!(slots.default || slots.text || props.text);
|
|
@@ -24223,14 +24294,14 @@ const VSnackbar = genericComponent()({
|
|
|
24223
24294
|
'v-snackbar--multi-line': props.multiLine && !props.vertical,
|
|
24224
24295
|
'v-snackbar--timer': !!props.timer,
|
|
24225
24296
|
'v-snackbar--vertical': props.vertical
|
|
24226
|
-
}, positionClasses.value, props.class],
|
|
24227
|
-
"style": props.style
|
|
24297
|
+
}, locationClasses.value, positionClasses.value, props.class],
|
|
24298
|
+
"style": [mainStyles.value, props.style]
|
|
24228
24299
|
}, overlayProps, {
|
|
24229
24300
|
"modelValue": isActive.value,
|
|
24230
24301
|
"onUpdate:modelValue": $event => isActive.value = $event,
|
|
24231
24302
|
"contentProps": mergeProps({
|
|
24232
24303
|
class: ['v-snackbar__wrapper', themeClasses.value, colorClasses.value, roundedClasses.value, variantClasses.value],
|
|
24233
|
-
style: [
|
|
24304
|
+
style: [colorStyles.value],
|
|
24234
24305
|
onPointerenter,
|
|
24235
24306
|
onPointerleave
|
|
24236
24307
|
}, overlayProps.contentProps),
|
|
@@ -24238,7 +24309,9 @@ const VSnackbar = genericComponent()({
|
|
|
24238
24309
|
"noClickAnimation": true,
|
|
24239
24310
|
"scrim": false,
|
|
24240
24311
|
"scrollStrategy": "none",
|
|
24241
|
-
"_disableGlobalStack": true
|
|
24312
|
+
"_disableGlobalStack": true,
|
|
24313
|
+
"onTouchstartPassive": onTouchstart,
|
|
24314
|
+
"onTouchend": onTouchend
|
|
24242
24315
|
}, scopeId), {
|
|
24243
24316
|
default: () => [genOverlays(false, 'v-snackbar'), props.timer && !isHovering.value && createVNode("div", {
|
|
24244
24317
|
"key": "timer",
|
|
@@ -26410,6 +26483,7 @@ const makeVFabProps = propsFactory({
|
|
|
26410
26483
|
app: Boolean,
|
|
26411
26484
|
appear: Boolean,
|
|
26412
26485
|
extended: Boolean,
|
|
26486
|
+
layout: Boolean,
|
|
26413
26487
|
location: {
|
|
26414
26488
|
type: String,
|
|
26415
26489
|
default: 'bottom end'
|
|
@@ -26460,8 +26534,8 @@ const VFab = genericComponent()({
|
|
|
26460
26534
|
id: props.name,
|
|
26461
26535
|
order: computed(() => parseInt(props.order, 10)),
|
|
26462
26536
|
position,
|
|
26463
|
-
layoutSize: height,
|
|
26464
|
-
elementSize: computed(() => height.value +
|
|
26537
|
+
layoutSize: computed(() => props.layout ? height.value + 24 : 0),
|
|
26538
|
+
elementSize: computed(() => height.value + 24),
|
|
26465
26539
|
active: computed(() => props.app && model.value),
|
|
26466
26540
|
absolute: toRef(props, 'absolute')
|
|
26467
26541
|
});
|
|
@@ -26515,9 +26589,18 @@ const makeVNumberInputProps = propsFactory({
|
|
|
26515
26589
|
},
|
|
26516
26590
|
inset: Boolean,
|
|
26517
26591
|
hideInput: Boolean,
|
|
26518
|
-
min:
|
|
26519
|
-
|
|
26520
|
-
|
|
26592
|
+
min: {
|
|
26593
|
+
type: Number,
|
|
26594
|
+
default: -Infinity
|
|
26595
|
+
},
|
|
26596
|
+
max: {
|
|
26597
|
+
type: Number,
|
|
26598
|
+
default: Infinity
|
|
26599
|
+
},
|
|
26600
|
+
step: {
|
|
26601
|
+
type: Number,
|
|
26602
|
+
default: 1
|
|
26603
|
+
},
|
|
26521
26604
|
...only(makeVInputProps(), ['density', 'disabled', 'focused', 'hideDetails', 'hint', 'label', 'persistentHint', 'readonly']),
|
|
26522
26605
|
...only(makeVFieldProps(), ['baseColor', 'bgColor', 'class', 'color', 'disabled', 'error', 'loading', 'reverse', 'rounded', 'style', 'theme', 'variant']),
|
|
26523
26606
|
...makeFocusProps()
|
|
@@ -26528,8 +26611,8 @@ const VNumberInput = genericComponent()({
|
|
|
26528
26611
|
props: {
|
|
26529
26612
|
...makeVNumberInputProps(),
|
|
26530
26613
|
modelValue: {
|
|
26531
|
-
type:
|
|
26532
|
-
default:
|
|
26614
|
+
type: Number,
|
|
26615
|
+
default: undefined
|
|
26533
26616
|
}
|
|
26534
26617
|
},
|
|
26535
26618
|
emits: {
|
|
@@ -26548,20 +26631,45 @@ const VNumberInput = genericComponent()({
|
|
|
26548
26631
|
blur
|
|
26549
26632
|
} = useFocus(props);
|
|
26550
26633
|
const inputRef = ref();
|
|
26634
|
+
const stepDecimals = computed(() => getDecimals(props.step));
|
|
26635
|
+
const modelDecimals = computed(() => model.value != null ? getDecimals(model.value) : 0);
|
|
26636
|
+
const canIncrease = computed(() => {
|
|
26637
|
+
if (model.value == null) return true;
|
|
26638
|
+
return model.value + props.step <= props.max;
|
|
26639
|
+
});
|
|
26640
|
+
const canDecrease = computed(() => {
|
|
26641
|
+
if (model.value == null) return true;
|
|
26642
|
+
return model.value - props.step >= props.min;
|
|
26643
|
+
});
|
|
26644
|
+
watchEffect(() => {
|
|
26645
|
+
if (model.value != null && (model.value < props.min || model.value > props.max)) {
|
|
26646
|
+
model.value = clamp(model.value, props.min, props.max);
|
|
26647
|
+
}
|
|
26648
|
+
});
|
|
26551
26649
|
function onFocus() {
|
|
26552
26650
|
if (!isFocused.value) focus();
|
|
26553
26651
|
}
|
|
26554
26652
|
const controlVariant = computed(() => {
|
|
26555
26653
|
return props.hideInput ? 'stacked' : props.controlVariant;
|
|
26556
26654
|
});
|
|
26655
|
+
const incrementSlotProps = computed(() => ({
|
|
26656
|
+
click: onClickUp
|
|
26657
|
+
}));
|
|
26658
|
+
const decrementSlotProps = computed(() => ({
|
|
26659
|
+
click: onClickDown
|
|
26660
|
+
}));
|
|
26557
26661
|
function toggleUpDown() {
|
|
26558
26662
|
let increment = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : true;
|
|
26663
|
+
if (model.value == null) {
|
|
26664
|
+
model.value = 0;
|
|
26665
|
+
return;
|
|
26666
|
+
}
|
|
26667
|
+
const decimals = Math.max(modelDecimals.value, stepDecimals.value);
|
|
26559
26668
|
if (increment) {
|
|
26560
|
-
|
|
26669
|
+
if (canIncrease.value) model.value = +(model.value + props.step).toFixed(decimals);
|
|
26561
26670
|
} else {
|
|
26562
|
-
|
|
26671
|
+
if (canDecrease.value) model.value = +(model.value - props.step).toFixed(decimals);
|
|
26563
26672
|
}
|
|
26564
|
-
if (inputRef.value) model.value = parseInt(inputRef.value.value, 10);
|
|
26565
26673
|
}
|
|
26566
26674
|
function onClickUp() {
|
|
26567
26675
|
toggleUpDown();
|
|
@@ -26569,12 +26677,28 @@ const VNumberInput = genericComponent()({
|
|
|
26569
26677
|
function onClickDown() {
|
|
26570
26678
|
toggleUpDown(false);
|
|
26571
26679
|
}
|
|
26572
|
-
|
|
26573
|
-
|
|
26574
|
-
|
|
26575
|
-
|
|
26576
|
-
|
|
26577
|
-
|
|
26680
|
+
function onKeydown(e) {
|
|
26681
|
+
if (['Enter', 'ArrowLeft', 'ArrowRight', 'Backspace'].includes(e.key) || e.ctrlKey) return;
|
|
26682
|
+
if (['ArrowDown'].includes(e.key)) {
|
|
26683
|
+
e.preventDefault();
|
|
26684
|
+
toggleUpDown(false);
|
|
26685
|
+
return;
|
|
26686
|
+
}
|
|
26687
|
+
if (['ArrowUp'].includes(e.key)) {
|
|
26688
|
+
e.preventDefault();
|
|
26689
|
+
toggleUpDown();
|
|
26690
|
+
return;
|
|
26691
|
+
}
|
|
26692
|
+
|
|
26693
|
+
// Only numbers, +, - & . are allowed
|
|
26694
|
+
if (!/^[0-9\-+.]+$/.test(e.key)) {
|
|
26695
|
+
e.preventDefault();
|
|
26696
|
+
}
|
|
26697
|
+
}
|
|
26698
|
+
function onInput(e) {
|
|
26699
|
+
const el = e.target;
|
|
26700
|
+
model.value = el.value ? +el.value : undefined;
|
|
26701
|
+
}
|
|
26578
26702
|
useRender(() => {
|
|
26579
26703
|
const fieldProps = filterFieldProps(props);
|
|
26580
26704
|
const [rootAttrs, inputAttrs] = filterInputAttrs(attrs);
|
|
@@ -26587,9 +26711,11 @@ const VNumberInput = genericComponent()({
|
|
|
26587
26711
|
return createVNode("div", {
|
|
26588
26712
|
"class": "v-number-input__control"
|
|
26589
26713
|
}, [!slots.decrement ? createVNode(VBtn, {
|
|
26714
|
+
"disabled": !canDecrease.value,
|
|
26590
26715
|
"flat": true,
|
|
26591
26716
|
"key": "decrement-btn",
|
|
26592
26717
|
"height": defaultHeight,
|
|
26718
|
+
"name": "decrement-btn",
|
|
26593
26719
|
"icon": "$expand",
|
|
26594
26720
|
"size": "small",
|
|
26595
26721
|
"onClick": onClickDown
|
|
@@ -26597,6 +26723,7 @@ const VNumberInput = genericComponent()({
|
|
|
26597
26723
|
"key": "decrement-defaults",
|
|
26598
26724
|
"defaults": {
|
|
26599
26725
|
VBtn: {
|
|
26726
|
+
disabled: !canDecrease.value,
|
|
26600
26727
|
flat: true,
|
|
26601
26728
|
height: defaultHeight,
|
|
26602
26729
|
size: 'small',
|
|
@@ -26608,9 +26735,11 @@ const VNumberInput = genericComponent()({
|
|
|
26608
26735
|
}), createVNode(VDivider, {
|
|
26609
26736
|
"vertical": controlVariant.value !== 'stacked'
|
|
26610
26737
|
}, null), !slots.increment ? createVNode(VBtn, {
|
|
26738
|
+
"disabled": !canIncrease.value,
|
|
26611
26739
|
"flat": true,
|
|
26612
26740
|
"key": "increment-btn",
|
|
26613
26741
|
"height": defaultHeight,
|
|
26742
|
+
"name": "increment-btn",
|
|
26614
26743
|
"icon": "$collapse",
|
|
26615
26744
|
"onClick": onClickUp,
|
|
26616
26745
|
"size": "small"
|
|
@@ -26618,6 +26747,7 @@ const VNumberInput = genericComponent()({
|
|
|
26618
26747
|
"key": "increment-defaults",
|
|
26619
26748
|
"defaults": {
|
|
26620
26749
|
VBtn: {
|
|
26750
|
+
disabled: !canIncrease.value,
|
|
26621
26751
|
flat: true,
|
|
26622
26752
|
height: defaultHeight,
|
|
26623
26753
|
size: 'small',
|
|
@@ -26659,17 +26789,16 @@ const VNumberInput = genericComponent()({
|
|
|
26659
26789
|
...slotProps
|
|
26660
26790
|
}
|
|
26661
26791
|
} = _ref2;
|
|
26662
|
-
return
|
|
26792
|
+
return createVNode("input", mergeProps({
|
|
26663
26793
|
"ref": inputRef,
|
|
26664
|
-
"type": "
|
|
26665
|
-
"
|
|
26794
|
+
"type": "text",
|
|
26795
|
+
"value": model.value,
|
|
26796
|
+
"onInput": onInput,
|
|
26797
|
+
"onKeydown": onKeydown,
|
|
26666
26798
|
"class": fieldClass,
|
|
26667
|
-
"max": props.max,
|
|
26668
|
-
"min": props.min,
|
|
26669
|
-
"step": props.step,
|
|
26670
26799
|
"onFocus": onFocus,
|
|
26671
26800
|
"onBlur": blur
|
|
26672
|
-
}, inputAttrs), null)
|
|
26801
|
+
}, inputAttrs), null);
|
|
26673
26802
|
},
|
|
26674
26803
|
'append-inner': controlVariant.value === 'split' ? () => createVNode("div", {
|
|
26675
26804
|
"class": "v-number-input__control"
|
|
@@ -26699,6 +26828,112 @@ const VNumberInput = genericComponent()({
|
|
|
26699
26828
|
}
|
|
26700
26829
|
});
|
|
26701
26830
|
|
|
26831
|
+
// Types
|
|
26832
|
+
|
|
26833
|
+
const makeVSnackbarQueueProps = propsFactory({
|
|
26834
|
+
// TODO: Port this to Snackbar on dev
|
|
26835
|
+
closable: [Boolean, String],
|
|
26836
|
+
closeText: {
|
|
26837
|
+
type: String,
|
|
26838
|
+
default: '$vuetify.dismiss'
|
|
26839
|
+
},
|
|
26840
|
+
modelValue: {
|
|
26841
|
+
type: Array,
|
|
26842
|
+
default: () => []
|
|
26843
|
+
},
|
|
26844
|
+
...omit(makeVSnackbarProps(), ['modelValue'])
|
|
26845
|
+
}, 'VSnackbarQueue');
|
|
26846
|
+
const VSnackbarQueue = genericComponent()({
|
|
26847
|
+
name: 'VSnackbarQueue',
|
|
26848
|
+
props: makeVSnackbarQueueProps(),
|
|
26849
|
+
emits: {
|
|
26850
|
+
'update:modelValue': val => true
|
|
26851
|
+
},
|
|
26852
|
+
setup(props, _ref) {
|
|
26853
|
+
let {
|
|
26854
|
+
emit,
|
|
26855
|
+
slots
|
|
26856
|
+
} = _ref;
|
|
26857
|
+
const {
|
|
26858
|
+
t
|
|
26859
|
+
} = useLocale();
|
|
26860
|
+
const isActive = shallowRef(false);
|
|
26861
|
+
const isVisible = shallowRef(false);
|
|
26862
|
+
const current = shallowRef();
|
|
26863
|
+
watch(() => props.modelValue.length, (val, oldVal) => {
|
|
26864
|
+
if (!isVisible.value && val > oldVal) {
|
|
26865
|
+
showNext();
|
|
26866
|
+
}
|
|
26867
|
+
});
|
|
26868
|
+
watch(isActive, val => {
|
|
26869
|
+
if (val) isVisible.value = true;
|
|
26870
|
+
});
|
|
26871
|
+
function onAfterLeave() {
|
|
26872
|
+
if (props.modelValue.length) {
|
|
26873
|
+
showNext();
|
|
26874
|
+
} else {
|
|
26875
|
+
current.value = undefined;
|
|
26876
|
+
isVisible.value = false;
|
|
26877
|
+
}
|
|
26878
|
+
}
|
|
26879
|
+
function showNext() {
|
|
26880
|
+
const [next, ...rest] = props.modelValue;
|
|
26881
|
+
emit('update:modelValue', rest);
|
|
26882
|
+
current.value = typeof next === 'string' ? {
|
|
26883
|
+
text: next
|
|
26884
|
+
} : next;
|
|
26885
|
+
nextTick(() => {
|
|
26886
|
+
isActive.value = true;
|
|
26887
|
+
});
|
|
26888
|
+
}
|
|
26889
|
+
function onClickClose() {
|
|
26890
|
+
isActive.value = false;
|
|
26891
|
+
}
|
|
26892
|
+
const btnProps = computed(() => ({
|
|
26893
|
+
color: typeof props.closable === 'string' ? props.closable : undefined,
|
|
26894
|
+
text: t(props.closeText)
|
|
26895
|
+
}));
|
|
26896
|
+
useRender(() => {
|
|
26897
|
+
const hasActions = !!(props.closable || slots.actions);
|
|
26898
|
+
const {
|
|
26899
|
+
modelValue: _,
|
|
26900
|
+
...snackbarProps
|
|
26901
|
+
} = VSnackbar.filterProps(props);
|
|
26902
|
+
return createVNode(Fragment, null, [isVisible.value && !!current.value && (slots.default ? createVNode(VDefaultsProvider, {
|
|
26903
|
+
"defaults": {
|
|
26904
|
+
VSnackbar: current.value
|
|
26905
|
+
}
|
|
26906
|
+
}, {
|
|
26907
|
+
default: () => [slots.default({
|
|
26908
|
+
item: current.value
|
|
26909
|
+
})]
|
|
26910
|
+
}) : createVNode(VSnackbar, mergeProps(snackbarProps, current.value, {
|
|
26911
|
+
"modelValue": isActive.value,
|
|
26912
|
+
"onUpdate:modelValue": $event => isActive.value = $event,
|
|
26913
|
+
"onAfterLeave": onAfterLeave
|
|
26914
|
+
}), {
|
|
26915
|
+
text: slots.text ? () => slots.text?.({
|
|
26916
|
+
item: current.value
|
|
26917
|
+
}) : undefined,
|
|
26918
|
+
actions: hasActions ? () => createVNode(Fragment, null, [!slots.actions ? createVNode(VBtn, mergeProps(btnProps.value, {
|
|
26919
|
+
"onClick": onClickClose
|
|
26920
|
+
}), null) : createVNode(VDefaultsProvider, {
|
|
26921
|
+
"defaults": {
|
|
26922
|
+
VBtn: btnProps.value
|
|
26923
|
+
}
|
|
26924
|
+
}, {
|
|
26925
|
+
default: () => [slots.actions({
|
|
26926
|
+
item: current.value,
|
|
26927
|
+
props: {
|
|
26928
|
+
onClick: onClickClose
|
|
26929
|
+
}
|
|
26930
|
+
})]
|
|
26931
|
+
})]) : undefined
|
|
26932
|
+
}))]);
|
|
26933
|
+
});
|
|
26934
|
+
}
|
|
26935
|
+
});
|
|
26936
|
+
|
|
26702
26937
|
// Utilities
|
|
26703
26938
|
|
|
26704
26939
|
// Types
|
|
@@ -27195,8 +27430,7 @@ const VSpeedDial = genericComponent()({
|
|
|
27195
27430
|
default: () => [createVNode(MaybeTransition, {
|
|
27196
27431
|
"appear": true,
|
|
27197
27432
|
"group": true,
|
|
27198
|
-
"transition": props.transition
|
|
27199
|
-
"mode": "out-in"
|
|
27433
|
+
"transition": props.transition
|
|
27200
27434
|
}, {
|
|
27201
27435
|
default: () => [slots.default?.(slotProps)]
|
|
27202
27436
|
})]
|
|
@@ -27214,9 +27448,7 @@ const makeVTimePickerClockProps = propsFactory({
|
|
|
27214
27448
|
ampm: Boolean,
|
|
27215
27449
|
color: String,
|
|
27216
27450
|
disabled: Boolean,
|
|
27217
|
-
displayedValue:
|
|
27218
|
-
default: null
|
|
27219
|
-
},
|
|
27451
|
+
displayedValue: null,
|
|
27220
27452
|
double: Boolean,
|
|
27221
27453
|
format: {
|
|
27222
27454
|
type: Function,
|
|
@@ -28345,6 +28577,7 @@ var components = /*#__PURE__*/Object.freeze({
|
|
|
28345
28577
|
VSlideYTransition: VSlideYTransition,
|
|
28346
28578
|
VSlider: VSlider,
|
|
28347
28579
|
VSnackbar: VSnackbar,
|
|
28580
|
+
VSnackbarQueue: VSnackbarQueue,
|
|
28348
28581
|
VSpacer: VSpacer,
|
|
28349
28582
|
VSparkline: VSparkline,
|
|
28350
28583
|
VSpeedDial: VSpeedDial,
|
|
@@ -28601,7 +28834,7 @@ function createVuetify$1() {
|
|
|
28601
28834
|
goTo
|
|
28602
28835
|
};
|
|
28603
28836
|
}
|
|
28604
|
-
const version$1 = "3.5.
|
|
28837
|
+
const version$1 = "3.5.18";
|
|
28605
28838
|
createVuetify$1.version = version$1;
|
|
28606
28839
|
|
|
28607
28840
|
// Vue's inject() can only be used in setup
|
|
@@ -28854,7 +29087,7 @@ var index = /*#__PURE__*/Object.freeze({
|
|
|
28854
29087
|
|
|
28855
29088
|
/* eslint-disable local-rules/sort-imports */
|
|
28856
29089
|
|
|
28857
|
-
const version = "3.5.
|
|
29090
|
+
const version = "3.5.18";
|
|
28858
29091
|
|
|
28859
29092
|
/* eslint-disable local-rules/sort-imports */
|
|
28860
29093
|
|