@vuetify/nightly 3.8.7-dev.2025-05-27 → 3.8.7-master.2025-05-29
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/CHANGELOG.md +5 -24
- package/dist/json/attributes.json +3311 -3363
- package/dist/json/importMap-labs.json +20 -20
- package/dist/json/importMap.json +206 -206
- package/dist/json/tags.json +6 -19
- package/dist/json/web-types.json +6080 -6298
- package/dist/vuetify-labs.cjs +204 -321
- package/dist/vuetify-labs.css +5998 -6026
- package/dist/vuetify-labs.d.ts +1384 -1583
- package/dist/vuetify-labs.esm.js +205 -322
- package/dist/vuetify-labs.esm.js.map +1 -1
- package/dist/vuetify-labs.js +204 -321
- package/dist/vuetify-labs.min.css +2 -2
- package/dist/vuetify.cjs +193 -315
- package/dist/vuetify.cjs.map +1 -1
- package/dist/vuetify.css +4658 -4686
- package/dist/vuetify.d.ts +541 -742
- package/dist/vuetify.esm.js +194 -316
- package/dist/vuetify.esm.js.map +1 -1
- package/dist/vuetify.js +193 -315
- package/dist/vuetify.js.map +1 -1
- package/dist/vuetify.min.css +2 -2
- package/dist/vuetify.min.js +1198 -1197
- package/dist/vuetify.min.js.map +1 -1
- package/lib/components/VAlert/VAlert.css +1 -6
- package/lib/components/VAlert/VAlert.d.ts +0 -35
- package/lib/components/VAlert/VAlert.js +10 -15
- package/lib/components/VAlert/VAlert.js.map +1 -1
- package/lib/components/VAlert/VAlert.sass +1 -7
- package/lib/components/VAutocomplete/VAutocomplete.d.ts +96 -133
- package/lib/components/VAutocomplete/VAutocomplete.js +2 -19
- package/lib/components/VAutocomplete/VAutocomplete.js.map +1 -1
- package/lib/components/VBtnGroup/VBtnGroup.css +7 -30
- package/lib/components/VBtnGroup/VBtnGroup.d.ts +32 -58
- package/lib/components/VBtnGroup/VBtnGroup.js +3 -7
- package/lib/components/VBtnGroup/VBtnGroup.js.map +1 -1
- package/lib/components/VBtnGroup/VBtnGroup.sass +17 -44
- package/lib/components/VBtnToggle/VBtnToggle.d.ts +0 -25
- package/lib/components/VCheckbox/VCheckbox.d.ts +3 -3
- package/lib/components/VChipGroup/VChipGroup.d.ts +0 -10
- package/lib/components/VCombobox/VCombobox.d.ts +96 -133
- package/lib/components/VCombobox/VCombobox.js +2 -20
- package/lib/components/VCombobox/VCombobox.js.map +1 -1
- package/lib/components/VDataTable/VDataTable.d.ts +0 -18
- package/lib/components/VDataTable/VDataTableHeaders.d.ts +0 -13
- package/lib/components/VDataTable/VDataTableHeaders.js +2 -4
- package/lib/components/VDataTable/VDataTableHeaders.js.map +1 -1
- package/lib/components/VDataTable/VDataTableServer.d.ts +0 -13
- package/lib/components/VDataTable/VDataTableVirtual.d.ts +0 -13
- package/lib/components/VDatePicker/VDatePicker.d.ts +20 -10
- package/lib/components/VDatePicker/VDatePicker.js +39 -2
- package/lib/components/VDatePicker/VDatePicker.js.map +1 -1
- package/lib/components/VDatePicker/VDatePickerMonth.d.ts +0 -10
- package/lib/components/VDatePicker/VDatePickerMonth.js +1 -1
- package/lib/components/VDatePicker/VDatePickerMonth.js.map +1 -1
- package/lib/components/VDatePicker/VDatePickerMonths.d.ts +10 -0
- package/lib/components/VDatePicker/VDatePickerMonths.js +12 -2
- package/lib/components/VDatePicker/VDatePickerMonths.js.map +1 -1
- package/lib/components/VDatePicker/VDatePickerYears.d.ts +10 -0
- package/lib/components/VDatePicker/VDatePickerYears.js +14 -2
- package/lib/components/VDatePicker/VDatePickerYears.js.map +1 -1
- package/lib/components/VField/VField.d.ts +3 -3
- package/lib/components/VFileInput/VFileInput.d.ts +15 -15
- package/lib/components/VInput/VInput.d.ts +4 -4
- package/lib/components/VList/VListChildren.js.map +1 -1
- package/lib/components/VNumberInput/VNumberInput.d.ts +89 -103
- package/lib/components/VNumberInput/VNumberInput.js +15 -29
- package/lib/components/VNumberInput/VNumberInput.js.map +1 -1
- package/lib/components/VOtpInput/VOtpInput.js +1 -2
- package/lib/components/VOtpInput/VOtpInput.js.map +1 -1
- package/lib/components/VOverlay/VOverlay.css +1 -1
- package/lib/components/VOverlay/_variables.scss +1 -1
- package/lib/components/VRadioGroup/VRadioGroup.d.ts +3 -3
- package/lib/components/VRangeSlider/VRangeSlider.d.ts +3 -3
- package/lib/components/VSelect/VSelect.d.ts +96 -138
- package/lib/components/VSelect/VSelect.js +3 -21
- package/lib/components/VSelect/VSelect.js.map +1 -1
- package/lib/components/VSlideGroup/VSlideGroup.d.ts +0 -10
- package/lib/components/VSlideGroup/VSlideGroup.js +1 -2
- package/lib/components/VSlideGroup/VSlideGroup.js.map +1 -1
- package/lib/components/VSlider/VSlider.d.ts +3 -3
- package/lib/components/VSwitch/VSwitch.d.ts +3 -3
- package/lib/components/VTabs/VTabs.d.ts +0 -10
- package/lib/components/VTextField/VTextField.d.ts +27 -27
- package/lib/components/VTextarea/VTextarea.d.ts +15 -15
- package/lib/composables/calendar.d.ts +0 -6
- package/lib/composables/calendar.js +1 -2
- package/lib/composables/calendar.js.map +1 -1
- package/lib/composables/date/DateAdapter.d.ts +1 -1
- package/lib/composables/date/DateAdapter.js.map +1 -1
- package/lib/composables/date/adapters/vuetify.d.ts +1 -1
- package/lib/composables/date/adapters/vuetify.js +4 -4
- package/lib/composables/date/adapters/vuetify.js.map +1 -1
- package/lib/composables/date/date.d.ts +1 -1
- package/lib/composables/date/index.d.ts +0 -1
- package/lib/composables/date/index.js +0 -1
- package/lib/composables/date/index.js.map +1 -1
- package/lib/composables/filter.js +0 -3
- package/lib/composables/filter.js.map +1 -1
- package/lib/composables/theme.d.ts +1 -6
- package/lib/composables/theme.js +26 -94
- package/lib/composables/theme.js.map +1 -1
- package/lib/composables/virtual.js +1 -6
- package/lib/composables/virtual.js.map +1 -1
- package/lib/entry-bundler.d.ts +1 -1
- package/lib/entry-bundler.js +1 -1
- package/lib/entry-bundler.js.map +1 -1
- package/lib/framework.d.ts +71 -76
- package/lib/framework.js +1 -1
- package/lib/framework.js.map +1 -1
- package/lib/labs/VCalendar/VCalendar.d.ts +0 -10
- package/lib/labs/VColorInput/VColorInput.d.ts +3 -3
- package/lib/labs/VDateInput/VDateInput.d.ts +107 -97
- package/lib/labs/VFileUpload/VFileUpload.d.ts +3 -3
- package/lib/labs/VIconBtn/VIconBtn.d.ts +29 -29
- package/lib/labs/VIconBtn/VIconBtn.js +11 -7
- package/lib/labs/VIconBtn/VIconBtn.js.map +1 -1
- package/lib/labs/entry-bundler.d.ts +1 -1
- package/lib/util/globals.d.ts +0 -1
- package/lib/util/globals.js +0 -1
- package/lib/util/globals.js.map +1 -1
- package/package.json +1 -3
- package/lib/composables/iconSizes.d.ts +0 -28
- package/lib/composables/iconSizes.js +0 -23
- package/lib/composables/iconSizes.js.map +0 -1
package/dist/vuetify.js
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
/*!
|
2
|
-
* Vuetify v3.8.7-
|
2
|
+
* Vuetify v3.8.7-master.2025-05-29
|
3
3
|
* Forged by John Leider
|
4
4
|
* Released under the MIT License.
|
5
5
|
*/
|
@@ -14,7 +14,6 @@
|
|
14
14
|
const SUPPORTS_INTERSECTION = IN_BROWSER && 'IntersectionObserver' in window;
|
15
15
|
const SUPPORTS_TOUCH = IN_BROWSER && ('ontouchstart' in window || window.navigator.maxTouchPoints > 0);
|
16
16
|
const SUPPORTS_EYE_DROPPER = IN_BROWSER && 'EyeDropper' in window;
|
17
|
-
const SUPPORTS_MATCH_MEDIA = IN_BROWSER && 'matchMedia' in window && typeof window.matchMedia === 'function';
|
18
17
|
|
19
18
|
function _classPrivateFieldInitSpec(e, t, a) { _checkPrivateRedeclaration(e, t), t.set(e, a); }
|
20
19
|
function _checkPrivateRedeclaration(e, t) { if (t.has(e)) throw new TypeError("Cannot initialize the same private elements twice on an object"); }
|
@@ -2829,7 +2828,6 @@
|
|
2829
2828
|
function genDefaults$1() {
|
2830
2829
|
return {
|
2831
2830
|
defaultTheme: 'light',
|
2832
|
-
prefix: 'v-',
|
2833
2831
|
variations: {
|
2834
2832
|
colors: [],
|
2835
2833
|
lighten: 0,
|
@@ -2911,10 +2909,7 @@
|
|
2911
2909
|
}
|
2912
2910
|
}
|
2913
2911
|
},
|
2914
|
-
stylesheetId: 'vuetify-theme-stylesheet'
|
2915
|
-
scoped: false,
|
2916
|
-
unimportant: false,
|
2917
|
-
utilities: true
|
2912
|
+
stylesheetId: 'vuetify-theme-stylesheet'
|
2918
2913
|
};
|
2919
2914
|
}
|
2920
2915
|
function parseThemeOptions() {
|
@@ -2937,21 +2932,21 @@
|
|
2937
2932
|
function createCssClass(lines, selector, content, scope) {
|
2938
2933
|
lines.push(`${getScopedSelector(selector, scope)} {\n`, ...content.map(line => ` ${line};\n`), '}\n');
|
2939
2934
|
}
|
2940
|
-
function genCssVariables(theme
|
2935
|
+
function genCssVariables(theme) {
|
2941
2936
|
const lightOverlay = theme.dark ? 2 : 1;
|
2942
2937
|
const darkOverlay = theme.dark ? 1 : 2;
|
2943
2938
|
const variables = [];
|
2944
2939
|
for (const [key, value] of Object.entries(theme.colors)) {
|
2945
2940
|
const rgb = parseColor(value);
|
2946
|
-
variables.push(
|
2941
|
+
variables.push(`--v-theme-${key}: ${rgb.r},${rgb.g},${rgb.b}`);
|
2947
2942
|
if (!key.startsWith('on-')) {
|
2948
|
-
variables.push(
|
2943
|
+
variables.push(`--v-theme-${key}-overlay-multiplier: ${getLuma(value) > 0.18 ? lightOverlay : darkOverlay}`);
|
2949
2944
|
}
|
2950
2945
|
}
|
2951
2946
|
for (const [key, value] of Object.entries(theme.variables)) {
|
2952
2947
|
const color = typeof value === 'string' && value.startsWith('#') ? parseColor(value) : undefined;
|
2953
2948
|
const rgb = color ? `${color.r}, ${color.g}, ${color.b}` : undefined;
|
2954
|
-
variables.push(
|
2949
|
+
variables.push(`--v-${key}: ${rgb ?? value}`);
|
2955
2950
|
}
|
2956
2951
|
return variables;
|
2957
2952
|
}
|
@@ -2995,8 +2990,7 @@
|
|
2995
2990
|
const scopeSelector = `:where(${scope})`;
|
2996
2991
|
return selector === ':root' ? scopeSelector : `${scopeSelector} ${selector}`;
|
2997
2992
|
}
|
2998
|
-
function upsertStyles(
|
2999
|
-
const styleEl = getOrCreateStyleElement(id, cspNonce);
|
2993
|
+
function upsertStyles(styleEl, styles) {
|
3000
2994
|
if (!styleEl) return;
|
3001
2995
|
styleEl.innerHTML = styles;
|
3002
2996
|
}
|
@@ -3016,17 +3010,8 @@
|
|
3016
3010
|
// Composables
|
3017
3011
|
function createTheme(options) {
|
3018
3012
|
const parsedOptions = parseThemeOptions(options);
|
3019
|
-
const
|
3013
|
+
const name = vue.shallowRef(parsedOptions.defaultTheme);
|
3020
3014
|
const themes = vue.ref(parsedOptions.themes);
|
3021
|
-
const systemName = vue.shallowRef('light');
|
3022
|
-
const name = vue.computed({
|
3023
|
-
get() {
|
3024
|
-
return _name.value === 'system' ? systemName.value : _name.value;
|
3025
|
-
},
|
3026
|
-
set(val) {
|
3027
|
-
_name.value = val;
|
3028
|
-
}
|
3029
|
-
});
|
3030
3015
|
const computedThemes = vue.computed(() => {
|
3031
3016
|
const acc = {};
|
3032
3017
|
for (const [name, original] of Object.entries(themes.value)) {
|
@@ -3047,49 +3032,28 @@
|
|
3047
3032
|
const current = vue.toRef(() => computedThemes.value[name.value]);
|
3048
3033
|
const styles = vue.computed(() => {
|
3049
3034
|
const lines = [];
|
3050
|
-
const important = parsedOptions.unimportant ? '' : ' !important';
|
3051
|
-
const scoped = parsedOptions.scoped ? parsedOptions.prefix : '';
|
3052
3035
|
if (current.value?.dark) {
|
3053
3036
|
createCssClass(lines, ':root', ['color-scheme: dark'], parsedOptions.scope);
|
3054
3037
|
}
|
3055
|
-
createCssClass(lines, ':root', genCssVariables(current.value
|
3038
|
+
createCssClass(lines, ':root', genCssVariables(current.value), parsedOptions.scope);
|
3056
3039
|
for (const [themeName, theme] of Object.entries(computedThemes.value)) {
|
3057
|
-
createCssClass(lines,
|
3058
|
-
}
|
3059
|
-
|
3060
|
-
|
3061
|
-
|
3062
|
-
|
3063
|
-
|
3064
|
-
|
3065
|
-
|
3066
|
-
}
|
3067
|
-
|
3068
|
-
|
3069
|
-
createCssClass(fgLines, `.${scoped}border-${key}`, [`--${parsedOptions.prefix}border-color: var(--${parsedOptions.prefix}theme-${key})`], parsedOptions.scope);
|
3070
|
-
}
|
3040
|
+
createCssClass(lines, `.v-theme--${themeName}`, [`color-scheme: ${theme.dark ? 'dark' : 'normal'}`, ...genCssVariables(theme)], parsedOptions.scope);
|
3041
|
+
}
|
3042
|
+
const bgLines = [];
|
3043
|
+
const fgLines = [];
|
3044
|
+
const colors = new Set(Object.values(computedThemes.value).flatMap(theme => Object.keys(theme.colors)));
|
3045
|
+
for (const key of colors) {
|
3046
|
+
if (key.startsWith('on-')) {
|
3047
|
+
createCssClass(fgLines, `.${key}`, [`color: rgb(var(--v-theme-${key})) !important`], parsedOptions.scope);
|
3048
|
+
} else {
|
3049
|
+
createCssClass(bgLines, `.bg-${key}`, [`--v-theme-overlay-multiplier: var(--v-theme-${key}-overlay-multiplier)`, `background-color: rgb(var(--v-theme-${key})) !important`, `color: rgb(var(--v-theme-on-${key})) !important`], parsedOptions.scope);
|
3050
|
+
createCssClass(fgLines, `.text-${key}`, [`color: rgb(var(--v-theme-${key})) !important`], parsedOptions.scope);
|
3051
|
+
createCssClass(fgLines, `.border-${key}`, [`--v-border-color: var(--v-theme-${key})`], parsedOptions.scope);
|
3071
3052
|
}
|
3072
|
-
lines.push(...bgLines, ...fgLines);
|
3073
3053
|
}
|
3054
|
+
lines.push(...bgLines, ...fgLines);
|
3074
3055
|
return lines.map((str, i) => i === 0 ? str : ` ${str}`).join('');
|
3075
3056
|
});
|
3076
|
-
const themeClasses = vue.toRef(() => parsedOptions.isDisabled ? undefined : `${parsedOptions.prefix}theme--${name.value}`);
|
3077
|
-
const themeNames = vue.toRef(() => Object.keys(computedThemes.value));
|
3078
|
-
if (SUPPORTS_MATCH_MEDIA) {
|
3079
|
-
const media = window.matchMedia('(prefers-color-scheme: dark)');
|
3080
|
-
function updateSystemName() {
|
3081
|
-
systemName.value = media.matches ? 'dark' : 'light';
|
3082
|
-
}
|
3083
|
-
updateSystemName();
|
3084
|
-
media.addEventListener('change', updateSystemName, {
|
3085
|
-
passive: true
|
3086
|
-
});
|
3087
|
-
if (vue.getCurrentScope()) {
|
3088
|
-
vue.onScopeDispose(() => {
|
3089
|
-
media.removeEventListener('change', updateSystemName);
|
3090
|
-
});
|
3091
|
-
}
|
3092
|
-
}
|
3093
3057
|
function install(app) {
|
3094
3058
|
if (parsedOptions.isDisabled) return;
|
3095
3059
|
const head = app._context.provides.usehead;
|
@@ -3127,55 +3091,22 @@
|
|
3127
3091
|
updateStyles();
|
3128
3092
|
}
|
3129
3093
|
function updateStyles() {
|
3130
|
-
upsertStyles(parsedOptions.stylesheetId, parsedOptions.cspNonce, styles.value);
|
3094
|
+
upsertStyles(getOrCreateStyleElement(parsedOptions.stylesheetId, parsedOptions.cspNonce), styles.value);
|
3131
3095
|
}
|
3132
3096
|
}
|
3133
3097
|
}
|
3134
|
-
|
3135
|
-
if (!themeNames.value.includes(themeName)) {
|
3136
|
-
consoleWarn(`Theme "${themeName}" not found on the Vuetify theme instance`);
|
3137
|
-
return;
|
3138
|
-
}
|
3139
|
-
name.value = themeName;
|
3140
|
-
}
|
3141
|
-
function cycle() {
|
3142
|
-
let themeArray = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : themeNames.value;
|
3143
|
-
const currentIndex = themeArray.indexOf(name.value);
|
3144
|
-
const nextIndex = currentIndex === -1 ? 0 : (currentIndex + 1) % themeArray.length;
|
3145
|
-
change(themeArray[nextIndex]);
|
3146
|
-
}
|
3147
|
-
function toggle() {
|
3148
|
-
let themeArray = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : ['light', 'dark'];
|
3149
|
-
cycle(themeArray);
|
3150
|
-
}
|
3151
|
-
const globalName = new Proxy(name, {
|
3152
|
-
get(target, prop) {
|
3153
|
-
return target[prop];
|
3154
|
-
},
|
3155
|
-
set(target, prop, val) {
|
3156
|
-
if (prop === 'value') {
|
3157
|
-
deprecate(`theme.global.name.value = ${val}`, `theme.change('${val}')`);
|
3158
|
-
}
|
3159
|
-
// @ts-expect-error
|
3160
|
-
target[prop] = val;
|
3161
|
-
return true;
|
3162
|
-
}
|
3163
|
-
});
|
3098
|
+
const themeClasses = vue.toRef(() => parsedOptions.isDisabled ? undefined : `v-theme--${name.value}`);
|
3164
3099
|
return {
|
3165
3100
|
install,
|
3166
|
-
change,
|
3167
|
-
cycle,
|
3168
|
-
toggle,
|
3169
3101
|
isDisabled: parsedOptions.isDisabled,
|
3170
3102
|
name,
|
3171
3103
|
themes,
|
3172
3104
|
current,
|
3173
3105
|
computedThemes,
|
3174
|
-
prefix: parsedOptions.prefix,
|
3175
3106
|
themeClasses,
|
3176
3107
|
styles,
|
3177
3108
|
global: {
|
3178
|
-
name
|
3109
|
+
name,
|
3179
3110
|
current
|
3180
3111
|
}
|
3181
3112
|
};
|
@@ -3186,7 +3117,7 @@
|
|
3186
3117
|
if (!theme) throw new Error('Could not find Vuetify theme injection');
|
3187
3118
|
const name = vue.toRef(() => props.theme ?? theme.name.value);
|
3188
3119
|
const current = vue.toRef(() => theme.themes.value[name.value]);
|
3189
|
-
const themeClasses = vue.toRef(() => theme.isDisabled ? undefined :
|
3120
|
+
const themeClasses = vue.toRef(() => theme.isDisabled ? undefined : `v-theme--${name.value}`);
|
3190
3121
|
const newTheme = {
|
3191
3122
|
...theme,
|
3192
3123
|
name,
|
@@ -4733,15 +4664,9 @@
|
|
4733
4664
|
};
|
4734
4665
|
}
|
4735
4666
|
|
4736
|
-
// Types
|
4737
|
-
|
4738
4667
|
const makeVBtnGroupProps = propsFactory({
|
4739
4668
|
baseColor: String,
|
4740
4669
|
divided: Boolean,
|
4741
|
-
direction: {
|
4742
|
-
type: String,
|
4743
|
-
default: 'horizontal'
|
4744
|
-
},
|
4745
4670
|
...makeBorderProps(),
|
4746
4671
|
...makeComponentProps(),
|
4747
4672
|
...makeDensityProps(),
|
@@ -4775,7 +4700,7 @@
|
|
4775
4700
|
} = useRounded(props);
|
4776
4701
|
provideDefaults({
|
4777
4702
|
VBtn: {
|
4778
|
-
height:
|
4703
|
+
height: 'auto',
|
4779
4704
|
baseColor: vue.toRef(() => props.baseColor),
|
4780
4705
|
color: vue.toRef(() => props.color),
|
4781
4706
|
density: vue.toRef(() => props.density),
|
@@ -4785,7 +4710,7 @@
|
|
4785
4710
|
});
|
4786
4711
|
useRender(() => {
|
4787
4712
|
return vue.createVNode(props.tag, {
|
4788
|
-
"class": vue.normalizeClass(['v-btn-group',
|
4713
|
+
"class": vue.normalizeClass(['v-btn-group', {
|
4789
4714
|
'v-btn-group--divided': props.divided
|
4790
4715
|
}, themeClasses.value, borderClasses.value, densityClasses.value, elevationClasses.value, roundedClasses.value, props.class]),
|
4791
4716
|
"style": vue.normalizeStyle(props.style)
|
@@ -6264,31 +6189,6 @@
|
|
6264
6189
|
// Utilities
|
6265
6190
|
const VAlertTitle = createSimpleFunctional('v-alert-title');
|
6266
6191
|
|
6267
|
-
// Utilities
|
6268
|
-
|
6269
|
-
// Types
|
6270
|
-
|
6271
|
-
// Types
|
6272
|
-
|
6273
|
-
// Composables
|
6274
|
-
const makeIconSizeProps = propsFactory({
|
6275
|
-
iconSize: [Number, String],
|
6276
|
-
iconSizes: {
|
6277
|
-
type: Array,
|
6278
|
-
default: () => [['x-small', 10], ['small', 16], ['default', 24], ['large', 28], ['x-large', 32]]
|
6279
|
-
}
|
6280
|
-
}, 'iconSize');
|
6281
|
-
function useIconSizes(props, fallback) {
|
6282
|
-
const iconSize = vue.computed(() => {
|
6283
|
-
const iconSizeMap = new Map(props.iconSizes);
|
6284
|
-
const _iconSize = props.iconSize ?? fallback() ?? 'default';
|
6285
|
-
return iconSizeMap.has(_iconSize) ? iconSizeMap.get(_iconSize) : _iconSize;
|
6286
|
-
});
|
6287
|
-
return {
|
6288
|
-
iconSize
|
6289
|
-
};
|
6290
|
-
}
|
6291
|
-
|
6292
6192
|
// Types
|
6293
6193
|
|
6294
6194
|
const allowedTypes = ['success', 'info', 'warning', 'error'];
|
@@ -6328,7 +6228,6 @@
|
|
6328
6228
|
...makeDensityProps(),
|
6329
6229
|
...makeDimensionProps(),
|
6330
6230
|
...makeElevationProps(),
|
6331
|
-
...makeIconSizeProps(),
|
6332
6231
|
...makeLocationProps(),
|
6333
6232
|
...makePositionProps(),
|
6334
6233
|
...makeRoundedProps(),
|
@@ -6356,9 +6255,6 @@
|
|
6356
6255
|
if (!props.type) return props.icon;
|
6357
6256
|
return props.icon ?? `$${props.type}`;
|
6358
6257
|
});
|
6359
|
-
const {
|
6360
|
-
iconSize
|
6361
|
-
} = useIconSizes(props, () => props.prominent ? 44 : 28);
|
6362
6258
|
const {
|
6363
6259
|
themeClasses
|
6364
6260
|
} = provideTheme(props);
|
@@ -6406,11 +6302,6 @@
|
|
6406
6302
|
const hasPrepend = !!(slots.prepend || icon.value);
|
6407
6303
|
const hasTitle = !!(slots.title || props.title);
|
6408
6304
|
const hasClose = !!(slots.close || props.closable);
|
6409
|
-
const iconProps = {
|
6410
|
-
density: props.density,
|
6411
|
-
icon: icon.value,
|
6412
|
-
size: iconSize.value
|
6413
|
-
};
|
6414
6305
|
return isActive.value && vue.createVNode(props.tag, {
|
6415
6306
|
"class": vue.normalizeClass(['v-alert', props.border && {
|
6416
6307
|
'v-alert--border': !!props.border,
|
@@ -6428,14 +6319,19 @@
|
|
6428
6319
|
}, null), hasPrepend && vue.createElementVNode("div", {
|
6429
6320
|
"key": "prepend",
|
6430
6321
|
"class": "v-alert__prepend"
|
6431
|
-
}, [!slots.prepend ? vue.createVNode(VIcon,
|
6432
|
-
"key": "prepend-icon"
|
6433
|
-
|
6322
|
+
}, [!slots.prepend ? vue.createVNode(VIcon, {
|
6323
|
+
"key": "prepend-icon",
|
6324
|
+
"density": props.density,
|
6325
|
+
"icon": icon.value,
|
6326
|
+
"size": props.prominent ? 44 : 28
|
6327
|
+
}, null) : vue.createVNode(VDefaultsProvider, {
|
6434
6328
|
"key": "prepend-defaults",
|
6435
6329
|
"disabled": !icon.value,
|
6436
6330
|
"defaults": {
|
6437
6331
|
VIcon: {
|
6438
|
-
|
6332
|
+
density: props.density,
|
6333
|
+
icon: icon.value,
|
6334
|
+
size: props.prominent ? 44 : 28
|
6439
6335
|
}
|
6440
6336
|
}
|
6441
6337
|
}, slots.prepend)]), vue.createElementVNode("div", {
|
@@ -7960,7 +7856,6 @@
|
|
7960
7856
|
const VSlideGroupSymbol = Symbol.for('vuetify:v-slide-group');
|
7961
7857
|
const makeVSlideGroupProps = propsFactory({
|
7962
7858
|
centerActive: Boolean,
|
7963
|
-
contentClass: null,
|
7964
7859
|
direction: {
|
7965
7860
|
type: String,
|
7966
7861
|
default: 'horizontal'
|
@@ -8273,7 +8168,7 @@
|
|
8273
8168
|
})]), vue.createElementVNode("div", {
|
8274
8169
|
"key": "container",
|
8275
8170
|
"ref": containerRef,
|
8276
|
-
"class":
|
8171
|
+
"class": "v-slide-group__container",
|
8277
8172
|
"onScroll": onScroll
|
8278
8173
|
}, [vue.createElementVNode("div", {
|
8279
8174
|
"ref": contentRef,
|
@@ -8635,68 +8530,6 @@
|
|
8635
8530
|
}
|
8636
8531
|
});
|
8637
8532
|
|
8638
|
-
const makeVDividerProps = propsFactory({
|
8639
|
-
color: String,
|
8640
|
-
inset: Boolean,
|
8641
|
-
length: [Number, String],
|
8642
|
-
opacity: [Number, String],
|
8643
|
-
thickness: [Number, String],
|
8644
|
-
vertical: Boolean,
|
8645
|
-
...makeComponentProps(),
|
8646
|
-
...makeThemeProps()
|
8647
|
-
}, 'VDivider');
|
8648
|
-
const VDivider = genericComponent()({
|
8649
|
-
name: 'VDivider',
|
8650
|
-
props: makeVDividerProps(),
|
8651
|
-
setup(props, _ref) {
|
8652
|
-
let {
|
8653
|
-
attrs,
|
8654
|
-
slots
|
8655
|
-
} = _ref;
|
8656
|
-
const {
|
8657
|
-
themeClasses
|
8658
|
-
} = provideTheme(props);
|
8659
|
-
const {
|
8660
|
-
textColorClasses,
|
8661
|
-
textColorStyles
|
8662
|
-
} = useTextColor(() => props.color);
|
8663
|
-
const dividerStyles = vue.computed(() => {
|
8664
|
-
const styles = {};
|
8665
|
-
if (props.length) {
|
8666
|
-
styles[props.vertical ? 'height' : 'width'] = convertToUnit(props.length);
|
8667
|
-
}
|
8668
|
-
if (props.thickness) {
|
8669
|
-
styles[props.vertical ? 'borderRightWidth' : 'borderTopWidth'] = convertToUnit(props.thickness);
|
8670
|
-
}
|
8671
|
-
return styles;
|
8672
|
-
});
|
8673
|
-
useRender(() => {
|
8674
|
-
const divider = vue.createElementVNode("hr", {
|
8675
|
-
"class": vue.normalizeClass([{
|
8676
|
-
'v-divider': true,
|
8677
|
-
'v-divider--inset': props.inset,
|
8678
|
-
'v-divider--vertical': props.vertical
|
8679
|
-
}, themeClasses.value, textColorClasses.value, props.class]),
|
8680
|
-
"style": vue.normalizeStyle([dividerStyles.value, textColorStyles.value, {
|
8681
|
-
'--v-border-opacity': props.opacity
|
8682
|
-
}, props.style]),
|
8683
|
-
"aria-orientation": !attrs.role || attrs.role === 'separator' ? props.vertical ? 'vertical' : 'horizontal' : undefined,
|
8684
|
-
"role": `${attrs.role || 'separator'}`
|
8685
|
-
}, null);
|
8686
|
-
if (!slots.default) return divider;
|
8687
|
-
return vue.createElementVNode("div", {
|
8688
|
-
"class": vue.normalizeClass(['v-divider__wrapper', {
|
8689
|
-
'v-divider__wrapper--vertical': props.vertical,
|
8690
|
-
'v-divider__wrapper--inset': props.inset
|
8691
|
-
}])
|
8692
|
-
}, [divider, vue.createElementVNode("div", {
|
8693
|
-
"class": "v-divider__content"
|
8694
|
-
}, [slots.default()]), divider]);
|
8695
|
-
});
|
8696
|
-
return {};
|
8697
|
-
}
|
8698
|
-
});
|
8699
|
-
|
8700
8533
|
// Utilities
|
8701
8534
|
|
8702
8535
|
// List
|
@@ -9848,6 +9681,68 @@
|
|
9848
9681
|
}
|
9849
9682
|
});
|
9850
9683
|
|
9684
|
+
const makeVDividerProps = propsFactory({
|
9685
|
+
color: String,
|
9686
|
+
inset: Boolean,
|
9687
|
+
length: [Number, String],
|
9688
|
+
opacity: [Number, String],
|
9689
|
+
thickness: [Number, String],
|
9690
|
+
vertical: Boolean,
|
9691
|
+
...makeComponentProps(),
|
9692
|
+
...makeThemeProps()
|
9693
|
+
}, 'VDivider');
|
9694
|
+
const VDivider = genericComponent()({
|
9695
|
+
name: 'VDivider',
|
9696
|
+
props: makeVDividerProps(),
|
9697
|
+
setup(props, _ref) {
|
9698
|
+
let {
|
9699
|
+
attrs,
|
9700
|
+
slots
|
9701
|
+
} = _ref;
|
9702
|
+
const {
|
9703
|
+
themeClasses
|
9704
|
+
} = provideTheme(props);
|
9705
|
+
const {
|
9706
|
+
textColorClasses,
|
9707
|
+
textColorStyles
|
9708
|
+
} = useTextColor(() => props.color);
|
9709
|
+
const dividerStyles = vue.computed(() => {
|
9710
|
+
const styles = {};
|
9711
|
+
if (props.length) {
|
9712
|
+
styles[props.vertical ? 'height' : 'width'] = convertToUnit(props.length);
|
9713
|
+
}
|
9714
|
+
if (props.thickness) {
|
9715
|
+
styles[props.vertical ? 'borderRightWidth' : 'borderTopWidth'] = convertToUnit(props.thickness);
|
9716
|
+
}
|
9717
|
+
return styles;
|
9718
|
+
});
|
9719
|
+
useRender(() => {
|
9720
|
+
const divider = vue.createElementVNode("hr", {
|
9721
|
+
"class": vue.normalizeClass([{
|
9722
|
+
'v-divider': true,
|
9723
|
+
'v-divider--inset': props.inset,
|
9724
|
+
'v-divider--vertical': props.vertical
|
9725
|
+
}, themeClasses.value, textColorClasses.value, props.class]),
|
9726
|
+
"style": vue.normalizeStyle([dividerStyles.value, textColorStyles.value, {
|
9727
|
+
'--v-border-opacity': props.opacity
|
9728
|
+
}, props.style]),
|
9729
|
+
"aria-orientation": !attrs.role || attrs.role === 'separator' ? props.vertical ? 'vertical' : 'horizontal' : undefined,
|
9730
|
+
"role": `${attrs.role || 'separator'}`
|
9731
|
+
}, null);
|
9732
|
+
if (!slots.default) return divider;
|
9733
|
+
return vue.createElementVNode("div", {
|
9734
|
+
"class": vue.normalizeClass(['v-divider__wrapper', {
|
9735
|
+
'v-divider__wrapper--vertical': props.vertical,
|
9736
|
+
'v-divider__wrapper--inset': props.inset
|
9737
|
+
}])
|
9738
|
+
}, [divider, vue.createElementVNode("div", {
|
9739
|
+
"class": "v-divider__content"
|
9740
|
+
}, [slots.default()]), divider]);
|
9741
|
+
});
|
9742
|
+
return {};
|
9743
|
+
}
|
9744
|
+
});
|
9745
|
+
|
9851
9746
|
// Types
|
9852
9747
|
|
9853
9748
|
const makeVListChildrenProps = propsFactory({
|
@@ -12775,12 +12670,7 @@
|
|
12775
12670
|
}
|
12776
12671
|
function calculateOffset(index) {
|
12777
12672
|
index = clamp(index, 0, items.value.length - 1);
|
12778
|
-
|
12779
|
-
const fraction = index % 1;
|
12780
|
-
const next = whole + 1;
|
12781
|
-
const wholeOffset = offsets[whole] || 0;
|
12782
|
-
const nextOffset = offsets[next] || wholeOffset;
|
12783
|
-
return wholeOffset + (nextOffset - wholeOffset) * fraction;
|
12673
|
+
return offsets[index] || 0;
|
12784
12674
|
}
|
12785
12675
|
function calculateIndex(scrollTop) {
|
12786
12676
|
return binaryClosest(offsets, scrollTop);
|
@@ -13134,7 +13024,6 @@
|
|
13134
13024
|
},
|
13135
13025
|
openOnClear: Boolean,
|
13136
13026
|
itemColor: String,
|
13137
|
-
noAutoScroll: Boolean,
|
13138
13027
|
...makeItemsProps({
|
13139
13028
|
itemChildren: false
|
13140
13029
|
})
|
@@ -13349,7 +13238,7 @@
|
|
13349
13238
|
vue.watch(menu, () => {
|
13350
13239
|
if (!props.hideSelected && menu.value && model.value.length) {
|
13351
13240
|
const index = displayItems.value.findIndex(item => model.value.some(s => (props.valueComparator || deepEqual)(s.value, item.value)));
|
13352
|
-
IN_BROWSER &&
|
13241
|
+
IN_BROWSER && window.requestAnimationFrame(() => {
|
13353
13242
|
index >= 0 && vVirtualScrollRef.value?.scrollToIndex(index);
|
13354
13243
|
});
|
13355
13244
|
}
|
@@ -13441,22 +13330,6 @@
|
|
13441
13330
|
key: item.value,
|
13442
13331
|
onClick: () => select(item, null)
|
13443
13332
|
});
|
13444
|
-
if (item.raw.type === 'divider') {
|
13445
|
-
return slots.divider?.({
|
13446
|
-
props: item.raw,
|
13447
|
-
index
|
13448
|
-
}) ?? vue.createVNode(VDivider, vue.mergeProps(item.props, {
|
13449
|
-
"key": `divider-${index}`
|
13450
|
-
}), null);
|
13451
|
-
}
|
13452
|
-
if (item.raw.type === 'subheader') {
|
13453
|
-
return slots.subheader?.({
|
13454
|
-
props: item.raw,
|
13455
|
-
index
|
13456
|
-
}) ?? vue.createVNode(VListSubheader, vue.mergeProps(item.props, {
|
13457
|
-
"key": `subheader-${index}`
|
13458
|
-
}), null);
|
13459
|
-
}
|
13460
13333
|
return slots.item?.({
|
13461
13334
|
item,
|
13462
13335
|
index,
|
@@ -13617,9 +13490,6 @@
|
|
13617
13490
|
let match = -1;
|
13618
13491
|
if ((query || customFiltersLength > 0) && !options?.noFilter) {
|
13619
13492
|
if (typeof item === 'object') {
|
13620
|
-
if (['divider', 'subheader'].includes(item.raw?.type)) {
|
13621
|
-
continue;
|
13622
|
-
}
|
13623
13493
|
const filterKeys = keys || Object.keys(transformed);
|
13624
13494
|
for (const key of filterKeys) {
|
13625
13495
|
const value = getPropertyFromItem(transformed, key);
|
@@ -14058,22 +13928,6 @@
|
|
14058
13928
|
active: highlightFirst.value && index === 0 ? true : undefined,
|
14059
13929
|
onClick: () => select(item, null)
|
14060
13930
|
});
|
14061
|
-
if (item.raw.type === 'divider') {
|
14062
|
-
return slots.divider?.({
|
14063
|
-
props: item.raw,
|
14064
|
-
index
|
14065
|
-
}) ?? vue.createVNode(VDivider, vue.mergeProps(item.props, {
|
14066
|
-
"key": `divider-${index}`
|
14067
|
-
}), null);
|
14068
|
-
}
|
14069
|
-
if (item.raw.type === 'subheader') {
|
14070
|
-
return slots.subheader?.({
|
14071
|
-
props: item.raw,
|
14072
|
-
index
|
14073
|
-
}) ?? vue.createVNode(VListSubheader, vue.mergeProps(item.props, {
|
14074
|
-
"key": `subheader-${index}`
|
14075
|
-
}), null);
|
14076
|
-
}
|
14077
13931
|
return slots.item?.({
|
14078
13932
|
item,
|
14079
13933
|
index,
|
@@ -17669,13 +17523,13 @@
|
|
17669
17523
|
return null;
|
17670
17524
|
}
|
17671
17525
|
const sundayJanuarySecond2000 = new Date(2000, 0, 2);
|
17672
|
-
function getWeekdays(locale, firstDayOfWeek
|
17526
|
+
function getWeekdays(locale, firstDayOfWeek) {
|
17673
17527
|
const daysFromSunday = firstDayOfWeek ?? weekInfo(locale)?.firstDay ?? 0;
|
17674
17528
|
return createRange(7).map(i => {
|
17675
17529
|
const weekday = new Date(sundayJanuarySecond2000);
|
17676
17530
|
weekday.setDate(sundayJanuarySecond2000.getDate() + daysFromSunday + i);
|
17677
17531
|
return new Intl.DateTimeFormat(locale, {
|
17678
|
-
weekday:
|
17532
|
+
weekday: 'narrow'
|
17679
17533
|
}).format(weekday);
|
17680
17534
|
});
|
17681
17535
|
}
|
@@ -18139,9 +17993,9 @@
|
|
18139
17993
|
getDiff(date, comparing, unit) {
|
18140
17994
|
return getDiff(date, comparing, unit);
|
18141
17995
|
}
|
18142
|
-
getWeekdays(firstDayOfWeek
|
17996
|
+
getWeekdays(firstDayOfWeek) {
|
18143
17997
|
const firstDay = firstDayOfWeek !== undefined ? Number(firstDayOfWeek) : undefined;
|
18144
|
-
return getWeekdays(this.locale, firstDay
|
17998
|
+
return getWeekdays(this.locale, firstDay);
|
18145
17999
|
}
|
18146
18000
|
getYear(date) {
|
18147
18001
|
return getYear(date);
|
@@ -18484,7 +18338,6 @@
|
|
18484
18338
|
_search.value = val ?? '';
|
18485
18339
|
if (!props.multiple && !hasSelectionSlot.value) {
|
18486
18340
|
model.value = [transformItem$3(props, val)];
|
18487
|
-
vue.nextTick(() => vVirtualScrollRef.value?.scrollToIndex(0));
|
18488
18341
|
}
|
18489
18342
|
if (val && props.multiple && props.delimiters?.length) {
|
18490
18343
|
const values = val.split(new RegExp(`(?:${props.delimiters.join('|')})+`));
|
@@ -18801,22 +18654,6 @@
|
|
18801
18654
|
active: highlightFirst.value && index === 0 ? true : undefined,
|
18802
18655
|
onClick: () => select(item, null)
|
18803
18656
|
});
|
18804
|
-
if (item.raw.type === 'divider') {
|
18805
|
-
return slots.divider?.({
|
18806
|
-
props: item.raw,
|
18807
|
-
index
|
18808
|
-
}) ?? vue.createVNode(VDivider, vue.mergeProps(item.props, {
|
18809
|
-
"key": `divider-${index}`
|
18810
|
-
}), null);
|
18811
|
-
}
|
18812
|
-
if (item.raw.type === 'subheader') {
|
18813
|
-
return slots.subheader?.({
|
18814
|
-
props: item.raw,
|
18815
|
-
index
|
18816
|
-
}) ?? vue.createVNode(VListSubheader, vue.mergeProps(item.props, {
|
18817
|
-
"key": `subheader-${index}`
|
18818
|
-
}), null);
|
18819
|
-
}
|
18820
18657
|
return slots.item?.({
|
18821
18658
|
item,
|
18822
18659
|
index,
|
@@ -20696,7 +20533,6 @@
|
|
20696
20533
|
color: String,
|
20697
20534
|
disableSort: Boolean,
|
20698
20535
|
fixedHeader: Boolean,
|
20699
|
-
lastFixed: Boolean,
|
20700
20536
|
multiSort: Boolean,
|
20701
20537
|
sortAscIcon: {
|
20702
20538
|
type: IconValue,
|
@@ -20743,11 +20579,10 @@
|
|
20743
20579
|
loaderClasses
|
20744
20580
|
} = useLoader(props);
|
20745
20581
|
function getFixedStyles(column, y) {
|
20746
|
-
if (!(props.sticky || props.fixedHeader) && !
|
20582
|
+
if (!(props.sticky || props.fixedHeader) && !column.fixed) return undefined;
|
20747
20583
|
return {
|
20748
20584
|
position: 'sticky',
|
20749
|
-
left: column.fixed
|
20750
|
-
right: column.lastFixed ? convertToUnit(column.fixedOffset ?? 0) : undefined,
|
20585
|
+
left: column.fixed ? convertToUnit(column.fixedOffset) : undefined,
|
20751
20586
|
top: props.sticky || props.fixedHeader ? `calc(var(--v-table-header-height) * ${y})` : undefined
|
20752
20587
|
};
|
20753
20588
|
}
|
@@ -22462,8 +22297,7 @@
|
|
22462
22297
|
firstDayOfWeek: {
|
22463
22298
|
type: [Number, String],
|
22464
22299
|
default: undefined
|
22465
|
-
}
|
22466
|
-
weekdayFormat: String
|
22300
|
+
}
|
22467
22301
|
}, 'calendar');
|
22468
22302
|
function useCalendar(props) {
|
22469
22303
|
const adapter = useDate();
|
@@ -22711,7 +22545,7 @@
|
|
22711
22545
|
"ref": daysRef,
|
22712
22546
|
"key": daysInMonth.value[0].date?.toString(),
|
22713
22547
|
"class": "v-date-picker-month__days"
|
22714
|
-
}, [!props.hideWeekdays && adapter.getWeekdays(props.firstDayOfWeek
|
22548
|
+
}, [!props.hideWeekdays && adapter.getWeekdays(props.firstDayOfWeek).map(weekDay => vue.createElementVNode("div", {
|
22715
22549
|
"class": ['v-date-picker-month__day', 'v-date-picker-month__weekday']
|
22716
22550
|
}, [weekDay])), daysInMonth.value.map((item, i) => {
|
22717
22551
|
const slotProps = {
|
@@ -22754,7 +22588,8 @@
|
|
22754
22588
|
min: null,
|
22755
22589
|
max: null,
|
22756
22590
|
modelValue: Number,
|
22757
|
-
year: Number
|
22591
|
+
year: Number,
|
22592
|
+
allowedMonths: [Array, Function]
|
22758
22593
|
}, 'VDatePickerMonths');
|
22759
22594
|
const VDatePickerMonths = genericComponent()({
|
22760
22595
|
name: 'VDatePickerMonths',
|
@@ -22776,7 +22611,7 @@
|
|
22776
22611
|
}
|
22777
22612
|
return createRange(12).map(i => {
|
22778
22613
|
const text = adapter.format(date, 'monthShort');
|
22779
|
-
const isDisabled = !!(props.min && adapter.isAfter(adapter.startOfMonth(adapter.date(props.min)), date) || props.max && adapter.isAfter(date, adapter.startOfMonth(adapter.date(props.max))));
|
22614
|
+
const isDisabled = !!(!isMonthAllowed(i) || props.min && adapter.isAfter(adapter.startOfMonth(adapter.date(props.min)), date) || props.max && adapter.isAfter(date, adapter.startOfMonth(adapter.date(props.max))));
|
22780
22615
|
date = adapter.getNextMonth(date);
|
22781
22616
|
return {
|
22782
22617
|
isDisabled,
|
@@ -22788,6 +22623,15 @@
|
|
22788
22623
|
vue.watchEffect(() => {
|
22789
22624
|
model.value = model.value ?? adapter.getMonth(adapter.date());
|
22790
22625
|
});
|
22626
|
+
function isMonthAllowed(month) {
|
22627
|
+
if (Array.isArray(props.allowedMonths) && props.allowedMonths.length) {
|
22628
|
+
return props.allowedMonths.includes(month);
|
22629
|
+
}
|
22630
|
+
if (typeof props.allowedMonths === 'function') {
|
22631
|
+
return props.allowedMonths(month);
|
22632
|
+
}
|
22633
|
+
return true;
|
22634
|
+
}
|
22791
22635
|
useRender(() => vue.createElementVNode("div", {
|
22792
22636
|
"class": "v-date-picker-months",
|
22793
22637
|
"style": vue.normalizeStyle({
|
@@ -22833,7 +22677,8 @@
|
|
22833
22677
|
height: [String, Number],
|
22834
22678
|
min: null,
|
22835
22679
|
max: null,
|
22836
|
-
modelValue: Number
|
22680
|
+
modelValue: Number,
|
22681
|
+
allowedYears: [Array, Function]
|
22837
22682
|
}, 'VDatePickerYears');
|
22838
22683
|
const VDatePickerYears = genericComponent()({
|
22839
22684
|
name: 'VDatePickerYears',
|
@@ -22865,7 +22710,8 @@
|
|
22865
22710
|
date = adapter.setYear(date, adapter.getYear(date) + 1);
|
22866
22711
|
return {
|
22867
22712
|
text,
|
22868
|
-
value: i
|
22713
|
+
value: i,
|
22714
|
+
isDisabled: !isYearAllowed(i)
|
22869
22715
|
};
|
22870
22716
|
});
|
22871
22717
|
});
|
@@ -22879,6 +22725,15 @@
|
|
22879
22725
|
block: 'center'
|
22880
22726
|
});
|
22881
22727
|
});
|
22728
|
+
function isYearAllowed(year) {
|
22729
|
+
if (Array.isArray(props.allowedYears) && props.allowedYears.length) {
|
22730
|
+
return props.allowedYears.includes(year);
|
22731
|
+
}
|
22732
|
+
if (typeof props.allowedYears === 'function') {
|
22733
|
+
return props.allowedYears(year);
|
22734
|
+
}
|
22735
|
+
return true;
|
22736
|
+
}
|
22882
22737
|
useRender(() => vue.createElementVNode("div", {
|
22883
22738
|
"class": "v-date-picker-years",
|
22884
22739
|
"style": vue.normalizeStyle({
|
@@ -22893,6 +22748,7 @@
|
|
22893
22748
|
color: model.value === year.value ? props.color : undefined,
|
22894
22749
|
rounded: true,
|
22895
22750
|
text: year.text,
|
22751
|
+
disabled: year.isDisabled,
|
22896
22752
|
variant: model.value === year.value ? 'flat' : 'text',
|
22897
22753
|
onClick: () => {
|
22898
22754
|
if (model.value === year.value) {
|
@@ -23042,6 +22898,41 @@
|
|
23042
22898
|
}
|
23043
22899
|
return targets;
|
23044
22900
|
});
|
22901
|
+
function isAllowedInRange(start, end) {
|
22902
|
+
const allowedDates = props.allowedDates;
|
22903
|
+
if (typeof allowedDates !== 'function') return true;
|
22904
|
+
const days = adapter.getDiff(end, start, 'days');
|
22905
|
+
for (let i = 0; i < days; i++) {
|
22906
|
+
if (allowedDates(adapter.addDays(start, i))) return true;
|
22907
|
+
}
|
22908
|
+
return false;
|
22909
|
+
}
|
22910
|
+
function allowedYears(year) {
|
22911
|
+
if (typeof props.allowedDates === 'function') {
|
22912
|
+
const startOfYear = adapter.parseISO(`${year}-01-01`);
|
22913
|
+
return isAllowedInRange(startOfYear, adapter.endOfYear(startOfYear));
|
22914
|
+
}
|
22915
|
+
if (Array.isArray(props.allowedDates) && props.allowedDates.length) {
|
22916
|
+
for (const date of props.allowedDates) {
|
22917
|
+
if (adapter.getYear(adapter.date(date)) === year) return true;
|
22918
|
+
}
|
22919
|
+
return false;
|
22920
|
+
}
|
22921
|
+
return true;
|
22922
|
+
}
|
22923
|
+
function allowedMonths(month) {
|
22924
|
+
if (typeof props.allowedDates === 'function') {
|
22925
|
+
const startOfMonth = adapter.parseISO(`${year.value}-${month + 1}-01`);
|
22926
|
+
return isAllowedInRange(startOfMonth, adapter.endOfMonth(startOfMonth));
|
22927
|
+
}
|
22928
|
+
if (Array.isArray(props.allowedDates) && props.allowedDates.length) {
|
22929
|
+
for (const date of props.allowedDates) {
|
22930
|
+
if (adapter.getYear(adapter.date(date)) === year.value && adapter.getMonth(adapter.date(date)) === month) return true;
|
22931
|
+
}
|
22932
|
+
return false;
|
22933
|
+
}
|
22934
|
+
return true;
|
22935
|
+
}
|
23045
22936
|
|
23046
22937
|
// function onClickAppend () {
|
23047
22938
|
// inputMode.value = inputMode.value === 'calendar' ? 'keyboard' : 'calendar'
|
@@ -23157,14 +23048,16 @@
|
|
23157
23048
|
"onUpdate:modelValue": [$event => month.value = $event, onUpdateMonth],
|
23158
23049
|
"min": minDate.value,
|
23159
23050
|
"max": maxDate.value,
|
23160
|
-
"year": year.value
|
23051
|
+
"year": year.value,
|
23052
|
+
"allowedMonths": allowedMonths
|
23161
23053
|
}), null) : viewMode.value === 'year' ? vue.createVNode(VDatePickerYears, vue.mergeProps({
|
23162
23054
|
"key": "date-picker-years"
|
23163
23055
|
}, datePickerYearsProps, {
|
23164
23056
|
"modelValue": year.value,
|
23165
23057
|
"onUpdate:modelValue": [$event => year.value = $event, onUpdateYear],
|
23166
23058
|
"min": minDate.value,
|
23167
|
-
"max": maxDate.value
|
23059
|
+
"max": maxDate.value,
|
23060
|
+
"allowedYears": allowedYears
|
23168
23061
|
}), null) : vue.createVNode(VDatePickerMonth, vue.mergeProps({
|
23169
23062
|
"key": "date-picker-month"
|
23170
23063
|
}, datePickerMonthProps, {
|
@@ -25242,10 +25135,6 @@
|
|
25242
25135
|
type: Number,
|
25243
25136
|
default: 0
|
25244
25137
|
},
|
25245
|
-
minFractionDigits: {
|
25246
|
-
type: Number,
|
25247
|
-
default: null
|
25248
|
-
},
|
25249
25138
|
...omit(makeVTextFieldProps(), ['modelValue', 'validationValue'])
|
25250
25139
|
}, 'VNumberInput');
|
25251
25140
|
const VNumberInput = genericComponent()({
|
@@ -25276,19 +25165,9 @@
|
|
25276
25165
|
} = useFocus(props);
|
25277
25166
|
function correctPrecision(val) {
|
25278
25167
|
let precision = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : props.precision;
|
25279
|
-
|
25280
|
-
|
25281
|
-
|
25282
|
-
let fixed = val.toFixed(precision);
|
25283
|
-
if (isFocused.value) {
|
25284
|
-
return Number(fixed).toString(); // trim zeros
|
25285
|
-
}
|
25286
|
-
if ((props.minFractionDigits ?? precision) < precision) {
|
25287
|
-
const trimLimit = precision - props.minFractionDigits;
|
25288
|
-
const [baseDigits, fractionDigits] = fixed.split('.');
|
25289
|
-
fixed = [baseDigits, fractionDigits.replace(new RegExp(`0{1,${trimLimit}}$`), '')].filter(Boolean).join('.');
|
25290
|
-
}
|
25291
|
-
return fixed;
|
25168
|
+
const fixed = precision == null ? String(val) : val.toFixed(precision);
|
25169
|
+
return isFocused.value ? Number(fixed).toString() // trim zeros
|
25170
|
+
: fixed;
|
25292
25171
|
}
|
25293
25172
|
const model = useProxiedModel(props, 'modelValue', null, val => val ?? null, val => val == null ? val ?? null : clamp(Number(val), props.min, props.max));
|
25294
25173
|
const _inputText = vue.shallowRef(null);
|
@@ -25328,26 +25207,21 @@
|
|
25328
25207
|
const controlNodeDefaultHeight = vue.toRef(() => controlVariant.value === 'stacked' ? 'auto' : '100%');
|
25329
25208
|
const incrementSlotProps = {
|
25330
25209
|
props: {
|
25331
|
-
style: {
|
25332
|
-
touchAction: 'none'
|
25333
|
-
},
|
25334
25210
|
onClick: onControlClick,
|
25335
25211
|
onPointerup: onControlMouseup,
|
25336
|
-
onPointerdown: onUpControlMousedown
|
25212
|
+
onPointerdown: onUpControlMousedown,
|
25213
|
+
onPointercancel: onControlPointerCancel
|
25337
25214
|
}
|
25338
25215
|
};
|
25339
25216
|
const decrementSlotProps = {
|
25340
25217
|
props: {
|
25341
|
-
style: {
|
25342
|
-
touchAction: 'none'
|
25343
|
-
},
|
25344
25218
|
onClick: onControlClick,
|
25345
25219
|
onPointerup: onControlMouseup,
|
25346
|
-
onPointerdown: onDownControlMousedown
|
25220
|
+
onPointerdown: onDownControlMousedown,
|
25221
|
+
onPointercancel: onControlPointerCancel
|
25347
25222
|
}
|
25348
25223
|
};
|
25349
25224
|
vue.watch(() => props.precision, () => formatInputValue());
|
25350
|
-
vue.watch(() => props.minFractionDigits, () => formatInputValue());
|
25351
25225
|
vue.onMounted(() => {
|
25352
25226
|
clampModel();
|
25353
25227
|
});
|
@@ -25441,6 +25315,11 @@
|
|
25441
25315
|
e.stopPropagation();
|
25442
25316
|
holdStart('down');
|
25443
25317
|
}
|
25318
|
+
function onControlPointerCancel(e) {
|
25319
|
+
const el = e.currentTarget;
|
25320
|
+
el?.releasePointerCapture(e.pointerId);
|
25321
|
+
holdStop();
|
25322
|
+
}
|
25444
25323
|
function clampModel() {
|
25445
25324
|
if (controlsDisabled.value) return;
|
25446
25325
|
if (!vTextFieldRef.value) return;
|
@@ -25457,7 +25336,7 @@
|
|
25457
25336
|
inputText.value = null;
|
25458
25337
|
return;
|
25459
25338
|
}
|
25460
|
-
inputText.value =
|
25339
|
+
inputText.value = props.precision == null ? String(model.value) : model.value.toFixed(props.precision);
|
25461
25340
|
}
|
25462
25341
|
function trimDecimalZeros() {
|
25463
25342
|
if (controlsDisabled.value) return;
|
@@ -25492,8 +25371,8 @@
|
|
25492
25371
|
"onClick": onControlClick,
|
25493
25372
|
"onPointerdown": onUpControlMousedown,
|
25494
25373
|
"onPointerup": onControlMouseup,
|
25374
|
+
"onPointercancel": onControlPointerCancel,
|
25495
25375
|
"size": controlNodeSize.value,
|
25496
|
-
"style": "touch-action: none",
|
25497
25376
|
"tabindex": "-1"
|
25498
25377
|
}, null) : vue.createVNode(VDefaultsProvider, {
|
25499
25378
|
"key": "increment-defaults",
|
@@ -25522,8 +25401,8 @@
|
|
25522
25401
|
"onClick": onControlClick,
|
25523
25402
|
"onPointerdown": onDownControlMousedown,
|
25524
25403
|
"onPointerup": onControlMouseup,
|
25404
|
+
"onPointercancel": onControlPointerCancel,
|
25525
25405
|
"size": controlNodeSize.value,
|
25526
|
-
"style": "touch-action: none",
|
25527
25406
|
"tabindex": "-1"
|
25528
25407
|
}, null) : vue.createVNode(VDefaultsProvider, {
|
25529
25408
|
"key": "decrement-defaults",
|
@@ -25717,10 +25596,9 @@
|
|
25717
25596
|
e.preventDefault();
|
25718
25597
|
e.stopPropagation();
|
25719
25598
|
const clipboardText = e?.clipboardData?.getData('Text').slice(0, length.value) ?? '';
|
25720
|
-
const finalIndex = clipboardText.length - 1 === -1 ? index : clipboardText.length - 1;
|
25721
25599
|
if (isValidNumber(clipboardText)) return;
|
25722
25600
|
model.value = clipboardText.split('');
|
25723
|
-
inputRef.value?.[
|
25601
|
+
inputRef.value?.[index].blur();
|
25724
25602
|
}
|
25725
25603
|
function reset() {
|
25726
25604
|
model.value = [];
|
@@ -29502,7 +29380,7 @@
|
|
29502
29380
|
};
|
29503
29381
|
});
|
29504
29382
|
}
|
29505
|
-
const version$1 = "3.8.7-
|
29383
|
+
const version$1 = "3.8.7-master.2025-05-29";
|
29506
29384
|
createVuetify$1.version = version$1;
|
29507
29385
|
|
29508
29386
|
// Vue's inject() can only be used in setup
|
@@ -29527,7 +29405,7 @@
|
|
29527
29405
|
...options
|
29528
29406
|
});
|
29529
29407
|
};
|
29530
|
-
const version = "3.8.7-
|
29408
|
+
const version = "3.8.7-master.2025-05-29";
|
29531
29409
|
createVuetify.version = version;
|
29532
29410
|
|
29533
29411
|
exports.blueprints = index;
|