@vuetify/nightly 3.8.1-next.2025-04-15 → 3.8.2-master.2025-04-17
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 -27
- package/dist/json/attributes.json +3031 -3031
- package/dist/json/importMap-labs.json +36 -36
- package/dist/json/importMap.json +150 -150
- package/dist/json/web-types.json +5537 -5577
- package/dist/vuetify-labs.cjs +197 -346
- package/dist/vuetify-labs.css +25469 -23739
- package/dist/vuetify-labs.d.ts +677 -274
- package/dist/vuetify-labs.esm.js +198 -347
- package/dist/vuetify-labs.esm.js.map +1 -1
- package/dist/vuetify-labs.js +197 -346
- package/dist/vuetify-labs.min.css +4 -3
- package/dist/vuetify.cjs +173 -328
- package/dist/vuetify.cjs.map +1 -1
- package/dist/vuetify.css +24041 -22315
- package/dist/vuetify.d.ts +680 -277
- package/dist/vuetify.esm.js +174 -329
- package/dist/vuetify.esm.js.map +1 -1
- package/dist/vuetify.js +173 -328
- package/dist/vuetify.js.map +1 -1
- package/dist/vuetify.min.css +4 -3
- package/dist/vuetify.min.js +1161 -1152
- package/dist/vuetify.min.js.map +1 -1
- package/lib/blueprints/md3.js +18 -5
- package/lib/blueprints/md3.js.map +1 -1
- package/lib/components/VAlert/VAlert.css +215 -207
- package/lib/components/VApp/VApp.css +15 -16
- package/lib/components/VAppBar/VAppBar.css +12 -14
- package/lib/components/VAutocomplete/VAutocomplete.css +84 -85
- package/lib/components/VAutocomplete/VAutocomplete.d.ts +9 -18
- package/lib/components/VAutocomplete/VAutocomplete.js +3 -6
- package/lib/components/VAutocomplete/VAutocomplete.js.map +1 -1
- package/lib/components/VAvatar/VAvatar.css +106 -108
- package/lib/components/VBadge/VBadge.css +77 -77
- package/lib/components/VBanner/VBanner.css +166 -161
- package/lib/components/VBottomNavigation/VBottomNavigation.css +64 -65
- package/lib/components/VBottomSheet/VBottomSheet.css +31 -34
- package/lib/components/VBreadcrumbs/VBreadcrumbs.css +57 -54
- package/lib/components/VBtn/VBtn.css +408 -385
- package/lib/components/VBtn/VBtn.sass +4 -4
- package/lib/components/VBtnGroup/VBtnGroup.css +64 -63
- package/lib/components/VBtnToggle/VBtnToggle.css +14 -16
- package/lib/components/VCard/VCard.css +302 -294
- package/lib/components/VCarousel/VCarousel.css +65 -63
- package/lib/components/VCarousel/VCarousel.sass +1 -1
- package/lib/components/VCheckbox/VCheckbox.css +5 -7
- package/lib/components/VChip/VChip.css +411 -378
- package/lib/components/VChipGroup/VChipGroup.css +18 -19
- package/lib/components/VCode/VCode.css +11 -10
- package/lib/components/VCode/VCode.sass +3 -0
- package/lib/components/VColorPicker/VColorPicker.css +23 -23
- package/lib/components/VColorPicker/VColorPickerCanvas.css +22 -24
- package/lib/components/VColorPicker/VColorPickerEdit.css +28 -29
- package/lib/components/VColorPicker/VColorPickerPreview.css +67 -69
- package/lib/components/VColorPicker/VColorPickerPreview.sass +2 -4
- package/lib/components/VColorPicker/VColorPickerSwatches.css +34 -34
- package/lib/components/VCombobox/VCombobox.css +84 -85
- package/lib/components/VCombobox/VCombobox.d.ts +9 -18
- package/lib/components/VCombobox/VCombobox.js +3 -6
- package/lib/components/VCombobox/VCombobox.js.map +1 -1
- package/lib/components/VCounter/VCounter.css +5 -7
- package/lib/components/VDataTable/VDataTable.css +186 -189
- package/lib/components/VDataTable/VDataTable.sass +11 -21
- package/lib/components/VDataTable/VDataTableFooter.css +31 -33
- package/lib/components/VDatePicker/VDatePicker.css +6 -8
- package/lib/components/VDatePicker/VDatePicker.d.ts +7 -7
- package/lib/components/VDatePicker/VDatePickerControls.css +57 -55
- package/lib/components/VDatePicker/VDatePickerHeader.css +60 -56
- package/lib/components/VDatePicker/VDatePickerMonth.css +55 -51
- package/lib/components/VDatePicker/VDatePickerMonth.d.ts +7 -7
- package/lib/components/VDatePicker/VDatePickerMonths.css +19 -20
- package/lib/components/VDatePicker/VDatePickerYears.css +15 -16
- package/lib/components/VDialog/VDialog.css +98 -98
- package/lib/components/VDivider/VDivider.css +52 -52
- package/lib/components/VEmptyState/VEmptyState.css +67 -62
- package/lib/components/VExpansionPanel/VExpansionPanel.css +209 -203
- package/lib/components/VExpansionPanel/VExpansionPanel.sass +25 -27
- package/lib/components/VFab/VFab.css +73 -78
- package/lib/components/VFab/VFab.sass +4 -5
- package/lib/components/VField/VField.css +589 -548
- package/lib/components/VFileInput/VFileInput.css +28 -30
- package/lib/components/VFooter/VFooter.css +36 -38
- package/lib/components/VForm/VForm.d.ts +531 -111
- package/lib/components/VForm/VForm.js +1 -11
- package/lib/components/VForm/VForm.js.map +1 -1
- package/lib/components/VGrid/VGrid.css +592 -565
- package/lib/components/VIcon/VIcon.css +53 -52
- package/lib/components/VImg/VImg.css +51 -50
- package/lib/components/VInfiniteScroll/VInfiniteScroll.css +37 -36
- package/lib/components/VInput/VInput.css +147 -136
- package/lib/components/VItemGroup/VItemGroup.css +5 -7
- package/lib/components/VKbd/VKbd.css +11 -13
- package/lib/components/VLabel/VLabel.css +15 -16
- package/lib/components/VLayout/VLayout.css +8 -10
- package/lib/components/VLayout/VLayoutItem.css +7 -8
- package/lib/components/VList/VList.css +108 -104
- package/lib/components/VList/VList.sass +1 -1
- package/lib/components/VList/VListItem.css +452 -440
- package/lib/components/VList/VListItem.sass +1 -2
- package/lib/components/VLocaleProvider/VLocaleProvider.css +2 -4
- package/lib/components/VMain/VMain.css +30 -32
- package/lib/components/VMenu/VMenu.css +19 -21
- package/lib/components/VMessages/VMessages.css +15 -17
- package/lib/components/VNavigationDrawer/VNavigationDrawer.css +104 -102
- package/lib/components/VNumberInput/VNumberInput.css +46 -48
- package/lib/components/VOtpInput/VOtpInput.css +58 -56
- package/lib/components/VOverlay/VOverlay.css +64 -61
- package/lib/components/VOverlay/VOverlay.sass +13 -14
- package/lib/components/VPagination/VPagination.css +8 -10
- package/lib/components/VParallax/VParallax.css +6 -8
- package/lib/components/VProgressCircular/VProgressCircular.css +101 -95
- package/lib/components/VProgressLinear/VProgressLinear.css +222 -209
- package/lib/components/VRadioGroup/VRadioGroup.css +12 -14
- package/lib/components/VRating/VRating.css +53 -52
- package/lib/components/VResponsive/VResponsive.css +26 -25
- package/lib/components/VSelect/VSelect.css +51 -53
- package/lib/components/VSelect/VSelect.d.ts +9 -18
- package/lib/components/VSelect/VSelect.js +3 -6
- package/lib/components/VSelect/VSelect.js.map +1 -1
- package/lib/components/VSelectionControl/VSelectionControl.css +100 -98
- package/lib/components/VSelectionControlGroup/VSelectionControlGroup.css +8 -10
- package/lib/components/VSheet/VSheet.css +36 -38
- package/lib/components/VSkeletonLoader/VSkeletonLoader.css +224 -225
- package/lib/components/VSlideGroup/VSlideGroup.css +55 -53
- package/lib/components/VSlider/VSlider.css +57 -53
- package/lib/components/VSlider/VSliderThumb.css +153 -142
- package/lib/components/VSlider/VSliderTrack.css +174 -155
- package/lib/components/VSnackbar/VSnackbar.css +140 -140
- package/lib/components/VSpeedDial/VSpeedDial.css +41 -43
- package/lib/components/VStepper/VStepper.css +56 -55
- package/lib/components/VStepper/VStepperItem.css +115 -112
- package/lib/components/VSwitch/VSwitch.css +139 -129
- package/lib/components/VSystemBar/VSystemBar.css +43 -45
- package/lib/components/VTable/VTable.css +141 -140
- package/lib/components/VTable/VTable.sass +2 -4
- package/lib/components/VTabs/VTab.css +29 -30
- package/lib/components/VTabs/VTabs.css +65 -59
- package/lib/components/VTextField/VTextField.css +85 -77
- package/lib/components/VTextarea/VTextarea.css +40 -48
- package/lib/components/VTextarea/VTextarea.sass +2 -4
- package/lib/components/VThemeProvider/VThemeProvider.css +3 -5
- package/lib/components/VTimeline/VTimeline.css +427 -388
- package/lib/components/VToolbar/VToolbar.css +144 -137
- package/lib/components/VTooltip/VTooltip.css +23 -27
- package/lib/components/VTooltip/VTooltip.sass +6 -8
- package/lib/components/VVirtualScroll/VVirtualScroll.css +9 -11
- package/lib/components/VWindow/VWindow.css +70 -73
- package/lib/composables/calendar.d.ts +2 -2
- package/lib/composables/calendar.js +5 -7
- package/lib/composables/calendar.js.map +1 -1
- package/lib/composables/date/DateAdapter.d.ts +1 -0
- package/lib/composables/date/DateAdapter.js.map +1 -1
- package/lib/composables/date/adapters/vuetify.d.ts +1 -0
- package/lib/composables/date/adapters/vuetify.js +101 -160
- package/lib/composables/date/adapters/vuetify.js.map +1 -1
- package/lib/composables/date/date.d.ts +1 -1
- package/lib/composables/date/date.js +0 -20
- package/lib/composables/date/date.js.map +1 -1
- package/lib/composables/filter.js +2 -1
- package/lib/composables/filter.js.map +1 -1
- package/lib/composables/theme.d.ts +1 -6
- package/lib/composables/theme.js +30 -98
- package/lib/composables/theme.js.map +1 -1
- package/lib/composables/validation.js +5 -0
- package/lib/composables/validation.js.map +1 -1
- package/lib/composables/virtual.js +1 -6
- package/lib/composables/virtual.js.map +1 -1
- package/lib/directives/ripple/VRipple.css +36 -38
- package/lib/entry-bundler.d.ts +1 -0
- package/lib/entry-bundler.js +1 -1
- package/lib/entry-bundler.js.map +1 -1
- package/lib/framework.d.ts +64 -66
- package/lib/framework.js +1 -1
- package/lib/framework.js.map +1 -1
- package/lib/labs/VCalendar/VCalendar.css +225 -219
- package/lib/labs/VCalendar/VCalendar.d.ts +7 -7
- package/lib/labs/VCalendar/VCalendarDay.css +32 -33
- package/lib/labs/VCalendar/VCalendarHeader.css +13 -13
- package/lib/labs/VCalendar/VCalendarInterval.css +42 -43
- package/lib/labs/VCalendar/VCalendarInterval.js +25 -19
- package/lib/labs/VCalendar/VCalendarInterval.js.map +1 -1
- package/lib/labs/VCalendar/VCalendarIntervalEvent.css +5 -7
- package/lib/labs/VCalendar/VCalendarMonthDay.css +58 -61
- package/lib/labs/VCalendar/VCalendarMonthDay.sass +2 -3
- package/lib/labs/VDateInput/VDateInput.d.ts +7 -7
- package/lib/labs/VFileUpload/VFileUpload.css +77 -74
- package/lib/labs/VIconBtn/VIconBtn.css +164 -162
- package/lib/labs/VPicker/VPicker.css +63 -58
- package/lib/labs/VTimePicker/VTimePicker.css +7 -9
- package/lib/labs/VTimePicker/VTimePickerClock.css +129 -126
- package/lib/labs/VTimePicker/VTimePickerControls.css +103 -102
- package/lib/labs/VTreeview/VTreeviewItem.css +28 -30
- package/lib/labs/VTreeview/VTreeviewItem.sass +2 -3
- package/lib/labs/entry-bundler.d.ts +1 -0
- package/lib/styles/elements/_global.sass +1 -1
- package/lib/styles/generic/_colors.scss +3 -3
- package/lib/styles/generic/_layers.scss +1 -13
- package/lib/styles/generic/_reset.scss +1 -0
- package/lib/styles/generic/_transitions.scss +32 -32
- package/lib/styles/main.css +16142 -14667
- package/lib/styles/settings/_utilities.scss +5 -0
- package/lib/styles/settings/_variables.scss +2 -1
- package/lib/styles/tools/_bootable.sass +3 -0
- package/lib/styles/tools/_border.sass +4 -4
- package/lib/styles/tools/_display.sass +10 -0
- package/lib/styles/tools/_elevation.sass +2 -2
- package/lib/styles/tools/_index.sass +2 -0
- package/lib/styles/tools/_layer.scss +2 -4
- package/lib/styles/tools/_position.sass +2 -2
- package/lib/styles/tools/_radius.sass +10 -0
- package/lib/styles/tools/_rounded.sass +2 -2
- package/lib/styles/tools/_utilities.sass +5 -1
- package/lib/styles/utilities/_elevation.scss +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 +46 -45
package/dist/vuetify-labs.esm.js
CHANGED
@@ -1,10 +1,10 @@
|
|
1
1
|
/*!
|
2
|
-
* Vuetify v3.8.
|
2
|
+
* Vuetify v3.8.2-master.2025-04-17
|
3
3
|
* Forged by John Leider
|
4
4
|
* Released under the MIT License.
|
5
5
|
*/
|
6
6
|
|
7
|
-
import { shallowRef, reactive, computed, watchEffect, toRefs, capitalize, unref, Fragment, isVNode, Comment, warn, getCurrentInstance as getCurrentInstance$1, ref, provide, inject as inject$1, defineComponent as defineComponent$1, h, camelize, onBeforeUnmount, watch, readonly, onMounted, useId, onDeactivated, onActivated, onScopeDispose, effectScope, toRaw,
|
7
|
+
import { shallowRef, reactive, computed, watchEffect, toRefs, capitalize, unref, Fragment, isVNode, Comment, warn, getCurrentInstance as getCurrentInstance$1, ref, provide, inject as inject$1, defineComponent as defineComponent$1, h, camelize, onBeforeUnmount, watch, readonly, onMounted, useId, onDeactivated, onActivated, onScopeDispose, effectScope, toRaw, createVNode, TransitionGroup, Transition, mergeProps, isRef, toRef, onBeforeMount, nextTick, withDirectives, resolveDirective, vShow, onUpdated, Text, resolveDynamicComponent, toDisplayString, markRaw, Teleport, cloneVNode, createTextVNode, onUnmounted, onBeforeUpdate, withModifiers, vModelText, resolveComponent, render } from 'vue';
|
8
8
|
|
9
9
|
// Types
|
10
10
|
// eslint-disable-line vue/prefer-import-from-vue
|
@@ -81,7 +81,6 @@ const IN_BROWSER = typeof window !== 'undefined';
|
|
81
81
|
const SUPPORTS_INTERSECTION = IN_BROWSER && 'IntersectionObserver' in window;
|
82
82
|
const SUPPORTS_TOUCH = IN_BROWSER && ('ontouchstart' in window || window.navigator.maxTouchPoints > 0);
|
83
83
|
const SUPPORTS_EYE_DROPPER = IN_BROWSER && 'EyeDropper' in window;
|
84
|
-
const SUPPORTS_MATCH_MEDIA = IN_BROWSER && 'matchMedia' in window && typeof window.matchMedia === 'function';
|
85
84
|
|
86
85
|
function _classPrivateFieldInitSpec(e, t, a) { _checkPrivateRedeclaration(e, t), t.set(e, a); }
|
87
86
|
function _checkPrivateRedeclaration(e, t) { if (t.has(e)) throw new TypeError("Cannot initialize the same private elements twice on an object"); }
|
@@ -2281,8 +2280,7 @@ const makeThemeProps = propsFactory({
|
|
2281
2280
|
}, 'theme');
|
2282
2281
|
function genDefaults$2() {
|
2283
2282
|
return {
|
2284
|
-
defaultTheme: '
|
2285
|
-
prefix: 'v-',
|
2283
|
+
defaultTheme: 'light',
|
2286
2284
|
variations: {
|
2287
2285
|
colors: [],
|
2288
2286
|
lighten: 0,
|
@@ -2333,8 +2331,8 @@ function genDefaults$2() {
|
|
2333
2331
|
surface: '#212121',
|
2334
2332
|
'surface-bright': '#ccbfd6',
|
2335
2333
|
'surface-light': '#424242',
|
2336
|
-
'surface-variant': '#
|
2337
|
-
'on-surface-variant': '#
|
2334
|
+
'surface-variant': '#c8c8c8',
|
2335
|
+
'on-surface-variant': '#000000',
|
2338
2336
|
primary: '#2196F3',
|
2339
2337
|
'primary-darken-1': '#277CC1',
|
2340
2338
|
secondary: '#54B6B2',
|
@@ -2364,10 +2362,7 @@ function genDefaults$2() {
|
|
2364
2362
|
}
|
2365
2363
|
}
|
2366
2364
|
},
|
2367
|
-
stylesheetId: 'vuetify-theme-stylesheet'
|
2368
|
-
scoped: false,
|
2369
|
-
unimportant: true,
|
2370
|
-
utilities: true
|
2365
|
+
stylesheetId: 'vuetify-theme-stylesheet'
|
2371
2366
|
};
|
2372
2367
|
}
|
2373
2368
|
function parseThemeOptions() {
|
@@ -2390,21 +2385,21 @@ function parseThemeOptions() {
|
|
2390
2385
|
function createCssClass(lines, selector, content, scope) {
|
2391
2386
|
lines.push(`${getScopedSelector(selector, scope)} {\n`, ...content.map(line => ` ${line};\n`), '}\n');
|
2392
2387
|
}
|
2393
|
-
function genCssVariables(theme
|
2388
|
+
function genCssVariables(theme) {
|
2394
2389
|
const lightOverlay = theme.dark ? 2 : 1;
|
2395
2390
|
const darkOverlay = theme.dark ? 1 : 2;
|
2396
2391
|
const variables = [];
|
2397
2392
|
for (const [key, value] of Object.entries(theme.colors)) {
|
2398
2393
|
const rgb = parseColor(value);
|
2399
|
-
variables.push(
|
2394
|
+
variables.push(`--v-theme-${key}: ${rgb.r},${rgb.g},${rgb.b}`);
|
2400
2395
|
if (!key.startsWith('on-')) {
|
2401
|
-
variables.push(
|
2396
|
+
variables.push(`--v-theme-${key}-overlay-multiplier: ${getLuma(value) > 0.18 ? lightOverlay : darkOverlay}`);
|
2402
2397
|
}
|
2403
2398
|
}
|
2404
2399
|
for (const [key, value] of Object.entries(theme.variables)) {
|
2405
2400
|
const color = typeof value === 'string' && value.startsWith('#') ? parseColor(value) : undefined;
|
2406
2401
|
const rgb = color ? `${color.r}, ${color.g}, ${color.b}` : undefined;
|
2407
|
-
variables.push(
|
2402
|
+
variables.push(`--v-${key}: ${rgb ?? value}`);
|
2408
2403
|
}
|
2409
2404
|
return variables;
|
2410
2405
|
}
|
@@ -2448,8 +2443,7 @@ function getScopedSelector(selector, scope) {
|
|
2448
2443
|
const scopeSelector = `:where(${scope})`;
|
2449
2444
|
return selector === ':root' ? scopeSelector : `${scopeSelector} ${selector}`;
|
2450
2445
|
}
|
2451
|
-
function upsertStyles(
|
2452
|
-
const styleEl = getOrCreateStyleElement(id, cspNonce);
|
2446
|
+
function upsertStyles(styleEl, styles) {
|
2453
2447
|
if (!styleEl) return;
|
2454
2448
|
styleEl.innerHTML = styles;
|
2455
2449
|
}
|
@@ -2469,17 +2463,8 @@ function getOrCreateStyleElement(id, cspNonce) {
|
|
2469
2463
|
// Composables
|
2470
2464
|
function createTheme(options) {
|
2471
2465
|
const parsedOptions = parseThemeOptions(options);
|
2472
|
-
const
|
2466
|
+
const name = shallowRef(parsedOptions.defaultTheme);
|
2473
2467
|
const themes = ref(parsedOptions.themes);
|
2474
|
-
const systemName = shallowRef('light');
|
2475
|
-
const name = computed({
|
2476
|
-
get() {
|
2477
|
-
return _name.value === 'system' ? systemName.value : _name.value;
|
2478
|
-
},
|
2479
|
-
set(val) {
|
2480
|
-
_name.value = val;
|
2481
|
-
}
|
2482
|
-
});
|
2483
2468
|
const computedThemes = computed(() => {
|
2484
2469
|
const acc = {};
|
2485
2470
|
for (const [name, original] of Object.entries(themes.value)) {
|
@@ -2500,49 +2485,28 @@ function createTheme(options) {
|
|
2500
2485
|
const current = computed(() => computedThemes.value[name.value]);
|
2501
2486
|
const styles = computed(() => {
|
2502
2487
|
const lines = [];
|
2503
|
-
const important = parsedOptions.unimportant ? '' : ' !important';
|
2504
|
-
const scoped = parsedOptions.scoped ? parsedOptions.prefix : '';
|
2505
2488
|
if (current.value?.dark) {
|
2506
2489
|
createCssClass(lines, ':root', ['color-scheme: dark'], parsedOptions.scope);
|
2507
2490
|
}
|
2508
|
-
createCssClass(lines, ':root', genCssVariables(current.value
|
2491
|
+
createCssClass(lines, ':root', genCssVariables(current.value), parsedOptions.scope);
|
2509
2492
|
for (const [themeName, theme] of Object.entries(computedThemes.value)) {
|
2510
|
-
createCssClass(lines,
|
2511
|
-
}
|
2512
|
-
|
2513
|
-
|
2514
|
-
|
2515
|
-
|
2516
|
-
|
2517
|
-
|
2518
|
-
|
2519
|
-
}
|
2520
|
-
|
2521
|
-
|
2522
|
-
createCssClass(fgLines, `.${scoped}border-${key}`, [`--${parsedOptions.prefix}border-color: var(--${parsedOptions.prefix}theme-${key})`], parsedOptions.scope);
|
2523
|
-
}
|
2493
|
+
createCssClass(lines, `.v-theme--${themeName}`, [`color-scheme: ${theme.dark ? 'dark' : 'normal'}`, ...genCssVariables(theme)], parsedOptions.scope);
|
2494
|
+
}
|
2495
|
+
const bgLines = [];
|
2496
|
+
const fgLines = [];
|
2497
|
+
const colors = new Set(Object.values(computedThemes.value).flatMap(theme => Object.keys(theme.colors)));
|
2498
|
+
for (const key of colors) {
|
2499
|
+
if (key.startsWith('on-')) {
|
2500
|
+
createCssClass(fgLines, `.${key}`, [`color: rgb(var(--v-theme-${key})) !important`], parsedOptions.scope);
|
2501
|
+
} else {
|
2502
|
+
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);
|
2503
|
+
createCssClass(fgLines, `.text-${key}`, [`color: rgb(var(--v-theme-${key})) !important`], parsedOptions.scope);
|
2504
|
+
createCssClass(fgLines, `.border-${key}`, [`--v-border-color: var(--v-theme-${key})`], parsedOptions.scope);
|
2524
2505
|
}
|
2525
|
-
lines.push(...bgLines, ...fgLines);
|
2526
2506
|
}
|
2527
|
-
|
2507
|
+
lines.push(...bgLines, ...fgLines);
|
2508
|
+
return lines.map((str, i) => i === 0 ? str : ` ${str}`).join('');
|
2528
2509
|
});
|
2529
|
-
const themeClasses = computed(() => parsedOptions.isDisabled ? undefined : `${parsedOptions.prefix}theme--${name.value}`);
|
2530
|
-
const themeNames = computed(() => Object.keys(computedThemes.value));
|
2531
|
-
if (SUPPORTS_MATCH_MEDIA) {
|
2532
|
-
const media = window.matchMedia('(prefers-color-scheme: dark)');
|
2533
|
-
function updateSystemName() {
|
2534
|
-
systemName.value = media.matches ? 'dark' : 'light';
|
2535
|
-
}
|
2536
|
-
updateSystemName();
|
2537
|
-
media.addEventListener('change', updateSystemName, {
|
2538
|
-
passive: true
|
2539
|
-
});
|
2540
|
-
if (getCurrentScope()) {
|
2541
|
-
onScopeDispose(() => {
|
2542
|
-
media.removeEventListener('change', updateSystemName);
|
2543
|
-
});
|
2544
|
-
}
|
2545
|
-
}
|
2546
2510
|
function install(app) {
|
2547
2511
|
if (parsedOptions.isDisabled) return;
|
2548
2512
|
const head = app._context.provides.usehead;
|
@@ -2580,55 +2544,22 @@ function createTheme(options) {
|
|
2580
2544
|
updateStyles();
|
2581
2545
|
}
|
2582
2546
|
function updateStyles() {
|
2583
|
-
upsertStyles(parsedOptions.stylesheetId, parsedOptions.cspNonce, styles.value);
|
2547
|
+
upsertStyles(getOrCreateStyleElement(parsedOptions.stylesheetId, parsedOptions.cspNonce), styles.value);
|
2584
2548
|
}
|
2585
2549
|
}
|
2586
2550
|
}
|
2587
|
-
|
2588
|
-
if (!themeNames.value.includes(themeName)) {
|
2589
|
-
consoleWarn(`Theme "${themeName}" not found on the Vuetify theme instance`);
|
2590
|
-
return;
|
2591
|
-
}
|
2592
|
-
name.value = themeName;
|
2593
|
-
}
|
2594
|
-
function cycle() {
|
2595
|
-
let themeArray = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : themeNames.value;
|
2596
|
-
const currentIndex = themeArray.indexOf(name.value);
|
2597
|
-
const nextIndex = currentIndex === -1 ? 0 : (currentIndex + 1) % themeArray.length;
|
2598
|
-
change(themeArray[nextIndex]);
|
2599
|
-
}
|
2600
|
-
function toggle() {
|
2601
|
-
let themeArray = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : ['light', 'dark'];
|
2602
|
-
cycle(themeArray);
|
2603
|
-
}
|
2604
|
-
const globalName = new Proxy(name, {
|
2605
|
-
get(target, prop) {
|
2606
|
-
return target[prop];
|
2607
|
-
},
|
2608
|
-
set(target, prop, val) {
|
2609
|
-
if (prop === 'value') {
|
2610
|
-
deprecate(`theme.global.name.value = ${val}`, `theme.change('${val}')`);
|
2611
|
-
}
|
2612
|
-
// @ts-expect-error
|
2613
|
-
target[prop] = val;
|
2614
|
-
return true;
|
2615
|
-
}
|
2616
|
-
});
|
2551
|
+
const themeClasses = computed(() => parsedOptions.isDisabled ? undefined : `v-theme--${name.value}`);
|
2617
2552
|
return {
|
2618
2553
|
install,
|
2619
|
-
change,
|
2620
|
-
cycle,
|
2621
|
-
toggle,
|
2622
2554
|
isDisabled: parsedOptions.isDisabled,
|
2623
2555
|
name,
|
2624
2556
|
themes,
|
2625
2557
|
current,
|
2626
2558
|
computedThemes,
|
2627
|
-
prefix: parsedOptions.prefix,
|
2628
2559
|
themeClasses,
|
2629
2560
|
styles,
|
2630
2561
|
global: {
|
2631
|
-
name
|
2562
|
+
name,
|
2632
2563
|
current
|
2633
2564
|
}
|
2634
2565
|
};
|
@@ -2639,7 +2570,7 @@ function provideTheme(props) {
|
|
2639
2570
|
if (!theme) throw new Error('Could not find Vuetify theme injection');
|
2640
2571
|
const name = computed(() => props.theme ?? theme.name.value);
|
2641
2572
|
const current = computed(() => theme.themes.value[name.value]);
|
2642
|
-
const themeClasses = computed(() => theme.isDisabled ? undefined :
|
2573
|
+
const themeClasses = computed(() => theme.isDisabled ? undefined : `v-theme--${name.value}`);
|
2643
2574
|
const newTheme = {
|
2644
2575
|
...theme,
|
2645
2576
|
name,
|
@@ -6963,6 +6894,11 @@ function useValidation(props) {
|
|
6963
6894
|
}
|
6964
6895
|
async function validate() {
|
6965
6896
|
let silent = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;
|
6897
|
+
if (props.disabled || props.readonly) {
|
6898
|
+
internalErrorMessages.value = [];
|
6899
|
+
isValidating.value = false;
|
6900
|
+
return internalErrorMessages.value;
|
6901
|
+
}
|
6966
6902
|
const results = [];
|
6967
6903
|
isValidating.value = true;
|
6968
6904
|
for (const rule of props.rules) {
|
@@ -12372,12 +12308,7 @@ function useVirtual(props, items) {
|
|
12372
12308
|
}
|
12373
12309
|
function calculateOffset(index) {
|
12374
12310
|
index = clamp(index, 0, items.value.length - 1);
|
12375
|
-
|
12376
|
-
const fraction = index % 1;
|
12377
|
-
const next = whole + 1;
|
12378
|
-
const wholeOffset = offsets[whole] || 0;
|
12379
|
-
const nextOffset = offsets[next] || wholeOffset;
|
12380
|
-
return wholeOffset + (nextOffset - wholeOffset) * fraction;
|
12311
|
+
return offsets[index] || 0;
|
12381
12312
|
}
|
12382
12313
|
function calculateIndex(scrollTop) {
|
12383
12314
|
return binaryClosest(offsets, scrollTop);
|
@@ -13006,8 +12937,7 @@ const VSelect = genericComponent()({
|
|
13006
12937
|
onClick: () => select(item, null)
|
13007
12938
|
});
|
13008
12939
|
return slots.item?.({
|
13009
|
-
item
|
13010
|
-
internalItem: item,
|
12940
|
+
item,
|
13011
12941
|
index,
|
13012
12942
|
props: itemProps
|
13013
12943
|
}) ?? createVNode(VListItem, mergeProps(itemProps, {
|
@@ -13055,13 +12985,11 @@ const VSelect = genericComponent()({
|
|
13055
12985
|
};
|
13056
12986
|
const hasSlot = hasChips ? !!slots.chip : !!slots.selection;
|
13057
12987
|
const slotContent = hasSlot ? ensureValidVNode(hasChips ? slots.chip({
|
13058
|
-
item
|
13059
|
-
internalItem: item,
|
12988
|
+
item,
|
13060
12989
|
index,
|
13061
12990
|
props: slotProps
|
13062
12991
|
}) : slots.selection({
|
13063
|
-
item
|
13064
|
-
internalItem: item,
|
12992
|
+
item,
|
13065
12993
|
index
|
13066
12994
|
})) : undefined;
|
13067
12995
|
if (hasSlot && !slotContent) return undefined;
|
@@ -13127,6 +13055,7 @@ const VSelect = genericComponent()({
|
|
13127
13055
|
// Composables
|
13128
13056
|
const defaultFilter = (value, query, item) => {
|
13129
13057
|
if (value == null || query == null) return -1;
|
13058
|
+
if (!query.length) return 0;
|
13130
13059
|
value = value.toString().toLocaleLowerCase();
|
13131
13060
|
query = query.toString().toLocaleLowerCase();
|
13132
13061
|
const result = [];
|
@@ -13139,7 +13068,7 @@ const defaultFilter = (value, query, item) => {
|
|
13139
13068
|
};
|
13140
13069
|
function normaliseMatch(match, query) {
|
13141
13070
|
if (match == null || typeof match === 'boolean' || match === -1) return;
|
13142
|
-
if (typeof match === 'number') return [[match, query.length]];
|
13071
|
+
if (typeof match === 'number') return [[match, match + query.length]];
|
13143
13072
|
if (Array.isArray(match[0])) return match;
|
13144
13073
|
return [match];
|
13145
13074
|
}
|
@@ -13607,8 +13536,7 @@ const VAutocomplete = genericComponent()({
|
|
13607
13536
|
onClick: () => select(item, null)
|
13608
13537
|
});
|
13609
13538
|
return slots.item?.({
|
13610
|
-
item
|
13611
|
-
internalItem: item,
|
13539
|
+
item,
|
13612
13540
|
index,
|
13613
13541
|
props: itemProps
|
13614
13542
|
}) ?? createVNode(VListItem, mergeProps(itemProps, {
|
@@ -13659,13 +13587,11 @@ const VAutocomplete = genericComponent()({
|
|
13659
13587
|
};
|
13660
13588
|
const hasSlot = hasChips.value ? !!slots.chip : !!slots.selection;
|
13661
13589
|
const slotContent = hasSlot ? ensureValidVNode(hasChips.value ? slots.chip({
|
13662
|
-
item
|
13663
|
-
internalItem: item,
|
13590
|
+
item,
|
13664
13591
|
index,
|
13665
13592
|
props: slotProps
|
13666
13593
|
}) : slots.selection({
|
13667
|
-
item
|
13668
|
-
internalItem: item,
|
13594
|
+
item,
|
13669
13595
|
index
|
13670
13596
|
})) : undefined;
|
13671
13597
|
if (hasSlot && !slotContent) return undefined;
|
@@ -17057,165 +16983,81 @@ const VPicker = genericComponent()({
|
|
17057
16983
|
|
17058
16984
|
// Types
|
17059
16985
|
|
17060
|
-
|
17061
|
-
|
17062
|
-
|
17063
|
-
|
17064
|
-
|
17065
|
-
|
17066
|
-
|
17067
|
-
|
17068
|
-
|
17069
|
-
|
17070
|
-
|
17071
|
-
|
17072
|
-
|
17073
|
-
|
17074
|
-
|
17075
|
-
|
17076
|
-
|
17077
|
-
|
17078
|
-
|
17079
|
-
|
17080
|
-
|
17081
|
-
|
17082
|
-
|
17083
|
-
|
17084
|
-
|
17085
|
-
|
17086
|
-
|
17087
|
-
|
17088
|
-
|
17089
|
-
|
17090
|
-
|
17091
|
-
|
17092
|
-
|
17093
|
-
|
17094
|
-
|
17095
|
-
|
17096
|
-
|
17097
|
-
|
17098
|
-
|
17099
|
-
|
17100
|
-
|
17101
|
-
|
17102
|
-
|
17103
|
-
|
17104
|
-
|
17105
|
-
|
17106
|
-
|
17107
|
-
|
17108
|
-
|
17109
|
-
|
17110
|
-
|
17111
|
-
|
17112
|
-
|
17113
|
-
|
17114
|
-
|
17115
|
-
|
17116
|
-
|
17117
|
-
|
17118
|
-
|
17119
|
-
|
17120
|
-
|
17121
|
-
|
17122
|
-
|
17123
|
-
|
17124
|
-
|
17125
|
-
|
17126
|
-
|
17127
|
-
|
17128
|
-
|
17129
|
-
IQ: 6,
|
17130
|
-
IR: 6,
|
17131
|
-
IS: 1,
|
17132
|
-
IT: 1,
|
17133
|
-
JM: 0,
|
17134
|
-
JO: 6,
|
17135
|
-
JP: 0,
|
17136
|
-
KE: 0,
|
17137
|
-
KG: 1,
|
17138
|
-
KH: 0,
|
17139
|
-
KR: 0,
|
17140
|
-
KW: 6,
|
17141
|
-
KZ: 1,
|
17142
|
-
LA: 0,
|
17143
|
-
LB: 1,
|
17144
|
-
LI: 1,
|
17145
|
-
LK: 1,
|
17146
|
-
LT: 1,
|
17147
|
-
LU: 1,
|
17148
|
-
LV: 1,
|
17149
|
-
LY: 6,
|
17150
|
-
MC: 1,
|
17151
|
-
MD: 1,
|
17152
|
-
ME: 1,
|
17153
|
-
MH: 0,
|
17154
|
-
MK: 1,
|
17155
|
-
MM: 0,
|
17156
|
-
MN: 1,
|
17157
|
-
MO: 0,
|
17158
|
-
MQ: 1,
|
17159
|
-
MT: 0,
|
17160
|
-
MV: 5,
|
17161
|
-
MX: 0,
|
17162
|
-
MY: 1,
|
17163
|
-
MZ: 0,
|
17164
|
-
NI: 0,
|
17165
|
-
NL: 1,
|
17166
|
-
NO: 1,
|
17167
|
-
NP: 0,
|
17168
|
-
NZ: 1,
|
17169
|
-
OM: 6,
|
17170
|
-
PA: 0,
|
17171
|
-
PE: 0,
|
17172
|
-
PH: 0,
|
17173
|
-
PK: 0,
|
17174
|
-
PL: 1,
|
17175
|
-
PR: 0,
|
17176
|
-
PT: 0,
|
17177
|
-
PY: 0,
|
17178
|
-
QA: 6,
|
17179
|
-
RE: 1,
|
17180
|
-
RO: 1,
|
17181
|
-
RS: 1,
|
17182
|
-
RU: 1,
|
17183
|
-
SA: 0,
|
17184
|
-
SD: 6,
|
17185
|
-
SE: 1,
|
17186
|
-
SG: 0,
|
17187
|
-
SI: 1,
|
17188
|
-
SK: 1,
|
17189
|
-
SM: 1,
|
17190
|
-
SV: 0,
|
17191
|
-
SY: 6,
|
17192
|
-
TH: 0,
|
17193
|
-
TJ: 1,
|
17194
|
-
TM: 1,
|
17195
|
-
TR: 1,
|
17196
|
-
TT: 0,
|
17197
|
-
TW: 0,
|
17198
|
-
UA: 1,
|
17199
|
-
UM: 0,
|
17200
|
-
US: 0,
|
17201
|
-
UY: 1,
|
17202
|
-
UZ: 1,
|
17203
|
-
VA: 1,
|
17204
|
-
VE: 0,
|
17205
|
-
VI: 0,
|
17206
|
-
VN: 1,
|
17207
|
-
WS: 0,
|
17208
|
-
XK: 1,
|
17209
|
-
YE: 0,
|
17210
|
-
ZA: 0,
|
17211
|
-
ZW: 0
|
17212
|
-
};
|
16986
|
+
function weekInfo(locale) {
|
16987
|
+
// https://simplelocalize.io/data/locales/
|
16988
|
+
// then `new Intl.Locale(...).getWeekInfo()`
|
16989
|
+
const code = locale.slice(-2).toUpperCase();
|
16990
|
+
switch (true) {
|
16991
|
+
case locale === 'GB-alt-variant':
|
16992
|
+
{
|
16993
|
+
return {
|
16994
|
+
firstDay: 0,
|
16995
|
+
firstWeekSize: 4
|
16996
|
+
};
|
16997
|
+
}
|
16998
|
+
case locale === '001':
|
16999
|
+
{
|
17000
|
+
return {
|
17001
|
+
firstDay: 1,
|
17002
|
+
firstWeekSize: 1
|
17003
|
+
};
|
17004
|
+
}
|
17005
|
+
case `AG AS BD BR BS BT BW BZ CA CO DM DO ET GT GU HK HN ID IL IN JM JP KE
|
17006
|
+
KH KR LA MH MM MO MT MX MZ NI NP PA PE PH PK PR PY SA SG SV TH TT TW UM US
|
17007
|
+
VE VI WS YE ZA ZW`.includes(code):
|
17008
|
+
{
|
17009
|
+
return {
|
17010
|
+
firstDay: 0,
|
17011
|
+
firstWeekSize: 1
|
17012
|
+
};
|
17013
|
+
}
|
17014
|
+
case `AI AL AM AR AU AZ BA BM BN BY CL CM CN CR CY EC GE HR KG KZ LB LK LV
|
17015
|
+
MD ME MK MN MY NZ RO RS SI TJ TM TR UA UY UZ VN XK`.includes(code):
|
17016
|
+
{
|
17017
|
+
return {
|
17018
|
+
firstDay: 1,
|
17019
|
+
firstWeekSize: 1
|
17020
|
+
};
|
17021
|
+
}
|
17022
|
+
case `AD AN AT AX BE BG CH CZ DE DK EE ES FI FJ FO FR GB GF GP GR HU IE IS
|
17023
|
+
IT LI LT LU MC MQ NL NO PL RE RU SE SK SM VA`.includes(code):
|
17024
|
+
{
|
17025
|
+
return {
|
17026
|
+
firstDay: 1,
|
17027
|
+
firstWeekSize: 4
|
17028
|
+
};
|
17029
|
+
}
|
17030
|
+
case `AE AF BH DJ DZ EG IQ IR JO KW LY OM QA SD SY`.includes(code):
|
17031
|
+
{
|
17032
|
+
return {
|
17033
|
+
firstDay: 6,
|
17034
|
+
firstWeekSize: 1
|
17035
|
+
};
|
17036
|
+
}
|
17037
|
+
case code === 'MV':
|
17038
|
+
{
|
17039
|
+
return {
|
17040
|
+
firstDay: 5,
|
17041
|
+
firstWeekSize: 1
|
17042
|
+
};
|
17043
|
+
}
|
17044
|
+
case code === 'PT':
|
17045
|
+
{
|
17046
|
+
return {
|
17047
|
+
firstDay: 0,
|
17048
|
+
firstWeekSize: 4
|
17049
|
+
};
|
17050
|
+
}
|
17051
|
+
default:
|
17052
|
+
return null;
|
17053
|
+
}
|
17054
|
+
}
|
17213
17055
|
function getWeekArray(date, locale, firstDayOfWeek) {
|
17214
17056
|
const weeks = [];
|
17215
17057
|
let currentWeek = [];
|
17216
17058
|
const firstDayOfMonth = startOfMonth(date);
|
17217
17059
|
const lastDayOfMonth = endOfMonth(date);
|
17218
|
-
const first = firstDayOfWeek ??
|
17060
|
+
const first = firstDayOfWeek ?? weekInfo(locale)?.firstDay ?? 0;
|
17219
17061
|
const firstDayWeekIndex = (firstDayOfMonth.getDay() - first + 7) % 7;
|
17220
17062
|
const lastDayWeekIndex = (lastDayOfMonth.getDay() - first + 7) % 7;
|
17221
17063
|
for (let i = 0; i < firstDayWeekIndex; i++) {
|
@@ -17246,7 +17088,7 @@ function getWeekArray(date, locale, firstDayOfWeek) {
|
|
17246
17088
|
return weeks;
|
17247
17089
|
}
|
17248
17090
|
function startOfWeek(date, locale, firstDayOfWeek) {
|
17249
|
-
const day = firstDayOfWeek ??
|
17091
|
+
const day = firstDayOfWeek ?? weekInfo(locale)?.firstDay ?? 0;
|
17250
17092
|
const d = new Date(date);
|
17251
17093
|
while (d.getDay() !== day) {
|
17252
17094
|
d.setDate(d.getDate() - 1);
|
@@ -17255,7 +17097,7 @@ function startOfWeek(date, locale, firstDayOfWeek) {
|
|
17255
17097
|
}
|
17256
17098
|
function endOfWeek(date, locale) {
|
17257
17099
|
const d = new Date(date);
|
17258
|
-
const lastDay = ((
|
17100
|
+
const lastDay = ((weekInfo(locale)?.firstDay ?? 0) + 6) % 7;
|
17259
17101
|
while (d.getDay() !== lastDay) {
|
17260
17102
|
d.setDate(d.getDate() + 1);
|
17261
17103
|
}
|
@@ -17290,7 +17132,7 @@ function date(value) {
|
|
17290
17132
|
}
|
17291
17133
|
const sundayJanuarySecond2000 = new Date(2000, 0, 2);
|
17292
17134
|
function getWeekdays(locale, firstDayOfWeek) {
|
17293
|
-
const daysFromSunday = firstDayOfWeek ??
|
17135
|
+
const daysFromSunday = firstDayOfWeek ?? weekInfo(locale)?.firstDay ?? 0;
|
17294
17136
|
return createRange(7).map(i => {
|
17295
17137
|
const weekday = new Date(sundayJanuarySecond2000);
|
17296
17138
|
weekday.setDate(sundayJanuarySecond2000.getDate() + daysFromSunday + i);
|
@@ -17538,6 +17380,24 @@ function getYear(date) {
|
|
17538
17380
|
function getMonth(date) {
|
17539
17381
|
return date.getMonth();
|
17540
17382
|
}
|
17383
|
+
function getWeek(date, locale, firstDayOfWeek, firstWeekMinSize) {
|
17384
|
+
const weekInfoFromLocale = weekInfo(locale);
|
17385
|
+
const weekStart = firstDayOfWeek ?? weekInfoFromLocale?.firstDay ?? 0;
|
17386
|
+
const minWeekSize = firstWeekMinSize ?? weekInfoFromLocale?.firstWeekSize ?? 1;
|
17387
|
+
function firstWeekSize(year) {
|
17388
|
+
const yearStart = new Date(year, 0, 1);
|
17389
|
+
return 7 - getDiff(yearStart, startOfWeek(yearStart, locale, weekStart), 'days');
|
17390
|
+
}
|
17391
|
+
let year = getYear(date);
|
17392
|
+
const currentWeekEnd = addDays(startOfWeek(date, locale, weekStart), 6);
|
17393
|
+
if (year < getYear(currentWeekEnd) && firstWeekSize(year + 1) >= minWeekSize) {
|
17394
|
+
year++;
|
17395
|
+
}
|
17396
|
+
const yearStart = new Date(year, 0, 1);
|
17397
|
+
const size = firstWeekSize(year);
|
17398
|
+
const d1w1 = size >= minWeekSize ? addDays(yearStart, size - 7) : addDays(yearStart, size);
|
17399
|
+
return 1 + getDiff(date, d1w1, 'weeks');
|
17400
|
+
}
|
17541
17401
|
function getDate(date) {
|
17542
17402
|
return date.getDate();
|
17543
17403
|
}
|
@@ -17677,10 +17537,12 @@ class VuetifyDateAdapter {
|
|
17677
17537
|
return addMonths(date, amount);
|
17678
17538
|
}
|
17679
17539
|
getWeekArray(date, firstDayOfWeek) {
|
17680
|
-
|
17540
|
+
const firstDay = firstDayOfWeek !== undefined ? Number(firstDayOfWeek) : undefined;
|
17541
|
+
return getWeekArray(date, this.locale, firstDay);
|
17681
17542
|
}
|
17682
17543
|
startOfWeek(date, firstDayOfWeek) {
|
17683
|
-
|
17544
|
+
const firstDay = firstDayOfWeek !== undefined ? Number(firstDayOfWeek) : undefined;
|
17545
|
+
return startOfWeek(date, this.locale, firstDay);
|
17684
17546
|
}
|
17685
17547
|
endOfWeek(date) {
|
17686
17548
|
return endOfWeek(date, this.locale);
|
@@ -17740,7 +17602,8 @@ class VuetifyDateAdapter {
|
|
17740
17602
|
return getDiff(date, comparing, unit);
|
17741
17603
|
}
|
17742
17604
|
getWeekdays(firstDayOfWeek) {
|
17743
|
-
|
17605
|
+
const firstDay = firstDayOfWeek !== undefined ? Number(firstDayOfWeek) : undefined;
|
17606
|
+
return getWeekdays(this.locale, firstDay);
|
17744
17607
|
}
|
17745
17608
|
getYear(date) {
|
17746
17609
|
return getYear(date);
|
@@ -17748,6 +17611,10 @@ class VuetifyDateAdapter {
|
|
17748
17611
|
getMonth(date) {
|
17749
17612
|
return getMonth(date);
|
17750
17613
|
}
|
17614
|
+
getWeek(date, firstDayOfWeek, firstWeekMinSize) {
|
17615
|
+
const firstDay = firstDayOfWeek !== undefined ? Number(firstDayOfWeek) : undefined;
|
17616
|
+
return getWeek(date, this.locale, firstDay, firstWeekMinSize);
|
17617
|
+
}
|
17751
17618
|
getDate(date) {
|
17752
17619
|
return getDate(date);
|
17753
17620
|
}
|
@@ -17851,26 +17718,6 @@ function useDate() {
|
|
17851
17718
|
return createInstance(options, locale);
|
17852
17719
|
}
|
17853
17720
|
|
17854
|
-
// https://stackoverflow.com/questions/274861/how-do-i-calculate-the-week-number-given-a-date/275024#275024
|
17855
|
-
function getWeek(adapter, value) {
|
17856
|
-
const date = adapter.toJsDate(value);
|
17857
|
-
let year = date.getFullYear();
|
17858
|
-
let d1w1 = new Date(year, 0, 1);
|
17859
|
-
if (date < d1w1) {
|
17860
|
-
year = year - 1;
|
17861
|
-
d1w1 = new Date(year, 0, 1);
|
17862
|
-
} else {
|
17863
|
-
const tv = new Date(year + 1, 0, 1);
|
17864
|
-
if (date >= tv) {
|
17865
|
-
year = year + 1;
|
17866
|
-
d1w1 = tv;
|
17867
|
-
}
|
17868
|
-
}
|
17869
|
-
const diffTime = Math.abs(date.getTime() - d1w1.getTime());
|
17870
|
-
const diffDays = Math.ceil(diffTime / (1000 * 60 * 60 * 24));
|
17871
|
-
return Math.floor(diffDays / 7) + 1;
|
17872
|
-
}
|
17873
|
-
|
17874
17721
|
// Types
|
17875
17722
|
|
17876
17723
|
const makeVColorPickerProps = propsFactory({
|
@@ -18417,8 +18264,7 @@ const VCombobox = genericComponent()({
|
|
18417
18264
|
onClick: () => select(item, null)
|
18418
18265
|
});
|
18419
18266
|
return slots.item?.({
|
18420
|
-
item
|
18421
|
-
internalItem: item,
|
18267
|
+
item,
|
18422
18268
|
index,
|
18423
18269
|
props: itemProps
|
18424
18270
|
}) ?? createVNode(VListItem, mergeProps(itemProps, {
|
@@ -18469,13 +18315,11 @@ const VCombobox = genericComponent()({
|
|
18469
18315
|
};
|
18470
18316
|
const hasSlot = hasChips.value ? !!slots.chip : !!slots.selection;
|
18471
18317
|
const slotContent = hasSlot ? ensureValidVNode(hasChips.value ? slots.chip({
|
18472
|
-
item
|
18473
|
-
internalItem: item,
|
18318
|
+
item,
|
18474
18319
|
index,
|
18475
18320
|
props: slotProps
|
18476
18321
|
}) : slots.selection({
|
18477
|
-
item
|
18478
|
-
internalItem: item,
|
18322
|
+
item,
|
18479
18323
|
index
|
18480
18324
|
})) : undefined;
|
18481
18325
|
if (hasSlot && !slotContent) return undefined;
|
@@ -22062,7 +21906,7 @@ const makeCalendarProps = propsFactory({
|
|
22062
21906
|
},
|
22063
21907
|
firstDayOfWeek: {
|
22064
21908
|
type: [Number, String],
|
22065
|
-
default:
|
21909
|
+
default: undefined
|
22066
21910
|
}
|
22067
21911
|
}, 'calendar');
|
22068
21912
|
function useCalendar(props) {
|
@@ -22085,14 +21929,12 @@ function useCalendar(props) {
|
|
22085
21929
|
return adapter.setMonth(date, value);
|
22086
21930
|
}, v => adapter.getMonth(v));
|
22087
21931
|
const weekDays = computed(() => {
|
22088
|
-
const firstDayOfWeek =
|
22089
|
-
|
21932
|
+
const firstDayOfWeek = adapter.toJsDate(adapter.startOfWeek(adapter.date(), props.firstDayOfWeek)).getDay();
|
22090
21933
|
// Always generate all days, regardless of props.weekdays
|
22091
21934
|
return [0, 1, 2, 3, 4, 5, 6].map(day => (day + firstDayOfWeek) % 7);
|
22092
21935
|
});
|
22093
21936
|
const weeksInMonth = computed(() => {
|
22094
|
-
const
|
22095
|
-
const weeks = adapter.getWeekArray(month.value, firstDayOfWeek);
|
21937
|
+
const weeks = adapter.getWeekArray(month.value, props.firstDayOfWeek);
|
22096
21938
|
const days = weeks.flat();
|
22097
21939
|
|
22098
21940
|
// Make sure there's always 6 weeks in month (6 * 7 days)
|
@@ -22156,7 +21998,7 @@ function useCalendar(props) {
|
|
22156
21998
|
});
|
22157
21999
|
const weekNumbers = computed(() => {
|
22158
22000
|
return weeksInMonth.value.map(week => {
|
22159
|
-
return week.length ? getWeek(
|
22001
|
+
return week.length ? adapter.getWeek(week[0], props.firstDayOfWeek) : null;
|
22160
22002
|
});
|
22161
22003
|
});
|
22162
22004
|
function isDisabled(value) {
|
@@ -23645,17 +23487,7 @@ const VForm = genericComponent()({
|
|
23645
23487
|
"novalidate": true,
|
23646
23488
|
"onReset": onReset,
|
23647
23489
|
"onSubmit": onSubmit
|
23648
|
-
}, [slots.default?.(
|
23649
|
-
errors: form.errors.value,
|
23650
|
-
isDisabled: form.isDisabled.value,
|
23651
|
-
isReadonly: form.isReadonly.value,
|
23652
|
-
isValidating: form.isValidating.value,
|
23653
|
-
isValid: form.isValid.value,
|
23654
|
-
items: form.items.value,
|
23655
|
-
validate: form.validate,
|
23656
|
-
reset: form.reset,
|
23657
|
-
resetValidation: form.resetValidation
|
23658
|
-
})]));
|
23490
|
+
}, [slots.default?.(form)]));
|
23659
23491
|
return forwardRefs(form, formRef);
|
23660
23492
|
}
|
23661
23493
|
});
|
@@ -28714,37 +28546,43 @@ const VCalendarInterval = genericComponent()({
|
|
28714
28546
|
"style": `height: ${convertToUnit(props.intervalHeight)}`
|
28715
28547
|
}, [createVNode("div", {
|
28716
28548
|
"class": "v-calendar-day__row-label"
|
28717
|
-
}, [createVNode("slot", {
|
28549
|
+
}, [createVNode(resolveComponent("slot"), {
|
28718
28550
|
"name": "intervalFormat",
|
28719
28551
|
"interval": interval.value
|
28720
|
-
},
|
28552
|
+
}, {
|
28553
|
+
default: () => [props.index ? props.intervalFormat ? typeof props.intervalFormat === 'string' ? adapter.format(interval.value.start, 'hours12h') : props.intervalFormat(interval.value) : interval.value.label : '']
|
28554
|
+
})]), createVNode("div", {
|
28721
28555
|
"class": "v-calendar-day__row-hairline"
|
28722
28556
|
}, null), createVNode("div", {
|
28723
28557
|
"class": ['v-calendar-day__row-content', interval.value.events.some(e => !e.last) ? 'v-calendar-day__row-content-through' : '']
|
28724
|
-
}, [createVNode("slot", {
|
28558
|
+
}, [createVNode(resolveComponent("slot"), {
|
28725
28559
|
"name": "intervalBody",
|
28726
28560
|
"interval": interval.value
|
28727
|
-
},
|
28728
|
-
|
28729
|
-
|
28730
|
-
|
28731
|
-
|
28732
|
-
|
28733
|
-
|
28561
|
+
}, {
|
28562
|
+
default: () => [interval.value.events?.map(event => createVNode(VCalendarIntervalEvent, {
|
28563
|
+
"event": event,
|
28564
|
+
"interval": interval.value,
|
28565
|
+
"intervalDivisions": props.intervalDivisions,
|
28566
|
+
"intervalDuration": props.intervalDuration,
|
28567
|
+
"intervalHeight": props.intervalHeight
|
28568
|
+
}, null))]
|
28569
|
+
})])]) : createVNode("div", {
|
28734
28570
|
"class": "v-calendar-day__row-without-label",
|
28735
28571
|
"style": `height: ${convertToUnit(props.intervalHeight)}`
|
28736
28572
|
}, [createVNode("div", {
|
28737
28573
|
"class": ['v-calendar-day__row-content', interval.value.events.some(e => !e.last) ? 'v-calendar-day__row-content-through' : '']
|
28738
|
-
}, [createVNode("slot", {
|
28574
|
+
}, [createVNode(resolveComponent("slot"), {
|
28739
28575
|
"name": "intervalBody",
|
28740
28576
|
"interval": interval.value
|
28741
|
-
},
|
28742
|
-
|
28743
|
-
|
28744
|
-
|
28745
|
-
|
28746
|
-
|
28747
|
-
|
28577
|
+
}, {
|
28578
|
+
default: () => [interval.value.events?.filter(event => !event.allDay).map(event => createVNode(VCalendarIntervalEvent, {
|
28579
|
+
"event": event,
|
28580
|
+
"interval": interval.value,
|
28581
|
+
"intervalDivisions": props.intervalDivisions,
|
28582
|
+
"intervalDuration": props.intervalDuration,
|
28583
|
+
"intervalHeight": props.intervalHeight
|
28584
|
+
}, null))]
|
28585
|
+
})])]);
|
28748
28586
|
});
|
28749
28587
|
return {
|
28750
28588
|
interval
|
@@ -31653,7 +31491,7 @@ function createVuetify$1() {
|
|
31653
31491
|
};
|
31654
31492
|
});
|
31655
31493
|
}
|
31656
|
-
const version$1 = "3.8.
|
31494
|
+
const version$1 = "3.8.2-master.2025-04-17";
|
31657
31495
|
createVuetify$1.version = version$1;
|
31658
31496
|
|
31659
31497
|
// Vue's inject() can only be used in setup
|
@@ -31836,7 +31674,7 @@ const md3 = {
|
|
31836
31674
|
flat: true
|
31837
31675
|
},
|
31838
31676
|
VAutocomplete: {
|
31839
|
-
variant: '
|
31677
|
+
variant: 'outlined'
|
31840
31678
|
},
|
31841
31679
|
VBanner: {
|
31842
31680
|
color: 'primary'
|
@@ -31865,7 +31703,10 @@ const md3 = {
|
|
31865
31703
|
rounded: 'sm'
|
31866
31704
|
},
|
31867
31705
|
VCombobox: {
|
31868
|
-
variant: '
|
31706
|
+
variant: 'outlined'
|
31707
|
+
},
|
31708
|
+
VDateInput: {
|
31709
|
+
variant: 'outlined'
|
31869
31710
|
},
|
31870
31711
|
VDatePicker: {
|
31871
31712
|
controlHeight: 48,
|
@@ -31879,6 +31720,9 @@ const md3 = {
|
|
31879
31720
|
rounded: 'circle'
|
31880
31721
|
}
|
31881
31722
|
},
|
31723
|
+
VFileInput: {
|
31724
|
+
variant: 'outlined'
|
31725
|
+
},
|
31882
31726
|
VNavigationDrawer: {
|
31883
31727
|
// VList: {
|
31884
31728
|
// nav: true,
|
@@ -31887,8 +31731,15 @@ const md3 = {
|
|
31887
31731
|
// },
|
31888
31732
|
// },
|
31889
31733
|
},
|
31734
|
+
VNumberInput: {
|
31735
|
+
variant: 'outlined',
|
31736
|
+
VBtn: {
|
31737
|
+
color: undefined,
|
31738
|
+
rounded: undefined
|
31739
|
+
}
|
31740
|
+
},
|
31890
31741
|
VSelect: {
|
31891
|
-
variant: '
|
31742
|
+
variant: 'outlined'
|
31892
31743
|
},
|
31893
31744
|
VSlider: {
|
31894
31745
|
color: 'primary'
|
@@ -31897,10 +31748,10 @@ const md3 = {
|
|
31897
31748
|
color: 'primary'
|
31898
31749
|
},
|
31899
31750
|
VTextarea: {
|
31900
|
-
variant: '
|
31751
|
+
variant: 'outlined'
|
31901
31752
|
},
|
31902
31753
|
VTextField: {
|
31903
|
-
variant: '
|
31754
|
+
variant: 'outlined'
|
31904
31755
|
},
|
31905
31756
|
VToolbar: {
|
31906
31757
|
VBtn: {
|
@@ -31938,7 +31789,7 @@ var index = /*#__PURE__*/Object.freeze({
|
|
31938
31789
|
|
31939
31790
|
/* eslint-disable local-rules/sort-imports */
|
31940
31791
|
|
31941
|
-
const version = "3.8.
|
31792
|
+
const version = "3.8.2-master.2025-04-17";
|
31942
31793
|
|
31943
31794
|
/* eslint-disable local-rules/sort-imports */
|
31944
31795
|
|