@vuetify/nightly 3.8.10-dev.2025-06-18 → 3.8.10-dev.2025-06-19
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 +14 -4
- package/dist/_component-variables-labs.sass +1 -3
- package/dist/_component-variables.sass +2 -0
- package/dist/json/attributes.json +3889 -3885
- package/dist/json/importMap-labs.json +32 -56
- package/dist/json/importMap.json +180 -156
- package/dist/json/tags.json +7 -6
- package/dist/json/web-types.json +7006 -6996
- package/dist/vuetify-labs.cjs +3071 -3065
- package/dist/vuetify-labs.css +5691 -5661
- package/dist/vuetify-labs.d.ts +8142 -4681
- package/dist/vuetify-labs.esm.js +3071 -3065
- package/dist/vuetify-labs.esm.js.map +1 -1
- package/dist/vuetify-labs.js +3071 -3065
- package/dist/vuetify-labs.min.css +2 -2
- package/dist/vuetify.cjs +1218 -160
- package/dist/vuetify.cjs.map +1 -1
- package/dist/vuetify.css +5014 -4715
- package/dist/vuetify.d.ts +6675 -1051
- package/dist/vuetify.esm.js +1218 -160
- package/dist/vuetify.esm.js.map +1 -1
- package/dist/vuetify.js +1218 -160
- package/dist/vuetify.js.map +1 -1
- package/dist/vuetify.min.css +2 -2
- package/dist/vuetify.min.js +1224 -1143
- package/dist/vuetify.min.js.map +1 -1
- package/lib/components/VAutocomplete/VAutocomplete.d.ts +18 -18
- package/lib/components/VCarousel/VCarousel.d.ts +11 -1
- package/lib/components/VCheckbox/VCheckbox.d.ts +696 -3
- package/lib/components/VCheckbox/VCheckbox.js +5 -2
- package/lib/components/VCheckbox/VCheckbox.js.map +1 -1
- package/lib/components/VCombobox/VCombobox.d.ts +18 -18
- package/lib/components/VFileInput/VFileInput.d.ts +6 -6
- package/lib/components/VList/VListItem.d.ts +3 -3
- package/lib/components/VList/VListItem.js.map +1 -1
- package/lib/components/VNumberInput/VNumberInput.d.ts +18 -18
- package/lib/components/VRadioGroup/VRadioGroup.d.ts +696 -3
- package/lib/components/VRadioGroup/VRadioGroup.js +5 -2
- package/lib/components/VRadioGroup/VRadioGroup.js.map +1 -1
- package/lib/components/VRangeSlider/VRangeSlider.d.ts +696 -3
- package/lib/components/VRangeSlider/VRangeSlider.js +2 -1
- package/lib/components/VRangeSlider/VRangeSlider.js.map +1 -1
- package/lib/components/VSelect/VSelect.d.ts +18 -18
- package/lib/components/VSlider/VSlider.d.ts +696 -3
- package/lib/components/VSlider/VSlider.js +4 -1
- package/lib/components/VSlider/VSlider.js.map +1 -1
- package/lib/components/VStepper/VStepperWindow.d.ts +10 -0
- package/lib/components/VSwitch/VSwitch.d.ts +696 -3
- package/lib/components/VSwitch/VSwitch.js +4 -1
- package/lib/components/VSwitch/VSwitch.js.map +1 -1
- package/lib/components/VTabs/VTabsWindow.d.ts +10 -0
- package/lib/components/VTextField/VTextField.d.ts +6 -6
- package/lib/components/VTextarea/VTextarea.d.ts +6 -6
- package/lib/{labs → components}/VTimePicker/VTimePicker.d.ts +1 -14
- package/lib/{labs → components}/VTimePicker/VTimePicker.js +2 -4
- package/lib/components/VTimePicker/VTimePicker.js.map +1 -0
- package/lib/components/VTimePicker/VTimePickerClock.js.map +1 -0
- package/lib/{labs → components}/VTimePicker/VTimePickerControls.d.ts +0 -26
- package/lib/{labs → components}/VTimePicker/VTimePickerControls.js +3 -7
- package/lib/components/VTimePicker/VTimePickerControls.js.map +1 -0
- package/lib/{labs → components}/VTimePicker/_variables.scss +1 -1
- package/lib/components/VTimePicker/index.js.map +1 -0
- package/lib/components/VTimePicker/shared.js.map +1 -0
- package/lib/components/VTimePicker/util.js.map +1 -0
- package/lib/{labs → components}/VTreeview/VTreeview.d.ts +10 -10
- package/lib/{labs → components}/VTreeview/VTreeview.js +1 -1
- package/lib/components/VTreeview/VTreeview.js.map +1 -0
- package/lib/{labs → components}/VTreeview/VTreeviewChildren.d.ts +22 -22
- package/lib/{labs → components}/VTreeview/VTreeviewChildren.js +1 -1
- package/lib/components/VTreeview/VTreeviewChildren.js.map +1 -0
- package/lib/{labs → components}/VTreeview/VTreeviewGroup.js +2 -2
- package/lib/components/VTreeview/VTreeviewGroup.js.map +1 -0
- package/lib/{labs → components}/VTreeview/VTreeviewItem.d.ts +58 -58
- package/lib/{labs → components}/VTreeview/VTreeviewItem.js +4 -4
- package/lib/components/VTreeview/VTreeviewItem.js.map +1 -0
- package/lib/components/VTreeview/index.js.map +1 -0
- package/lib/components/VTreeview/shared.js.map +1 -0
- package/lib/components/VWindow/VWindow.css +15 -0
- package/lib/components/VWindow/VWindow.d.ts +10 -0
- package/lib/components/VWindow/VWindow.js +8 -2
- package/lib/components/VWindow/VWindow.js.map +1 -1
- package/lib/components/VWindow/VWindow.sass +17 -0
- package/lib/components/VWindow/_variables.scss +1 -0
- package/lib/components/index.d.ts +2 -0
- package/lib/components/index.js +4 -2
- package/lib/components/index.js.map +1 -1
- package/lib/composables/forwardRefs.d.ts +2 -2
- package/lib/composables/forwardRefs.js.map +1 -1
- package/lib/composables/icons.d.ts +1 -1
- package/lib/composables/icons.js.map +1 -1
- package/lib/composables/mask.d.ts +1 -1
- package/lib/composables/mask.js.map +1 -1
- package/lib/composables/theme.d.ts +1 -1
- package/lib/composables/theme.js +2 -4
- package/lib/composables/theme.js.map +1 -1
- package/lib/entry-bundler.js +1 -1
- package/lib/framework.d.ts +68 -68
- package/lib/framework.js +1 -1
- package/lib/labs/VCalendar/VCalendar.d.ts +24 -24
- package/lib/labs/VCalendar/VCalendar.js.map +1 -1
- package/lib/labs/VDateInput/VDateInput.d.ts +18 -18
- package/lib/labs/VMaskInput/VMaskInput.d.ts +18 -18
- package/lib/labs/components.d.ts +0 -2
- package/lib/labs/components.js +0 -2
- package/lib/labs/components.js.map +1 -1
- package/lib/styles/main.css +15 -0
- package/lib/styles/utilities/_index.sass +1 -0
- package/lib/styles/utilities/_pointer-events.sass +16 -0
- package/lib/util/helpers.d.ts +1 -0
- package/lib/util/helpers.js.map +1 -1
- package/package.json +1 -1
- package/lib/labs/VTimePicker/VTimePicker.js.map +0 -1
- package/lib/labs/VTimePicker/VTimePickerClock.js.map +0 -1
- package/lib/labs/VTimePicker/VTimePickerControls.js.map +0 -1
- package/lib/labs/VTimePicker/index.js.map +0 -1
- package/lib/labs/VTimePicker/shared.js.map +0 -1
- package/lib/labs/VTimePicker/util.js.map +0 -1
- package/lib/labs/VTreeview/VTreeview.js.map +0 -1
- package/lib/labs/VTreeview/VTreeviewChildren.js.map +0 -1
- package/lib/labs/VTreeview/VTreeviewGroup.js.map +0 -1
- package/lib/labs/VTreeview/VTreeviewItem.js.map +0 -1
- package/lib/labs/VTreeview/index.js.map +0 -1
- package/lib/labs/VTreeview/shared.js.map +0 -1
- /package/lib/{labs → components}/VTimePicker/VTimePicker.css +0 -0
- /package/lib/{labs → components}/VTimePicker/VTimePicker.sass +0 -0
- /package/lib/{labs → components}/VTimePicker/VTimePickerClock.css +0 -0
- /package/lib/{labs → components}/VTimePicker/VTimePickerClock.d.ts +0 -0
- /package/lib/{labs → components}/VTimePicker/VTimePickerClock.js +0 -0
- /package/lib/{labs → components}/VTimePicker/VTimePickerClock.sass +0 -0
- /package/lib/{labs → components}/VTimePicker/VTimePickerControls.css +0 -0
- /package/lib/{labs → components}/VTimePicker/VTimePickerControls.sass +0 -0
- /package/lib/{labs → components}/VTimePicker/index.d.ts +0 -0
- /package/lib/{labs → components}/VTimePicker/index.js +0 -0
- /package/lib/{labs → components}/VTimePicker/shared.d.ts +0 -0
- /package/lib/{labs → components}/VTimePicker/shared.js +0 -0
- /package/lib/{labs → components}/VTimePicker/util.d.ts +0 -0
- /package/lib/{labs → components}/VTimePicker/util.js +0 -0
- /package/lib/{labs → components}/VTreeview/VTreeviewGroup.d.ts +0 -0
- /package/lib/{labs → components}/VTreeview/VTreeviewItem.css +0 -0
- /package/lib/{labs → components}/VTreeview/VTreeviewItem.sass +0 -0
- /package/lib/{labs → components}/VTreeview/_variables.scss +0 -0
- /package/lib/{labs → components}/VTreeview/index.d.ts +0 -0
- /package/lib/{labs → components}/VTreeview/index.js +0 -0
- /package/lib/{labs → components}/VTreeview/shared.d.ts +0 -0
- /package/lib/{labs → components}/VTreeview/shared.js +0 -0
package/lib/framework.d.ts
CHANGED
@@ -149,7 +149,7 @@ type DeepPartial<T> = T extends object ? {
|
|
149
149
|
} : T;
|
150
150
|
type ThemeOptions = false | {
|
151
151
|
cspNonce?: string;
|
152
|
-
defaultTheme?: 'light' | 'dark' | 'system' | string;
|
152
|
+
defaultTheme?: 'light' | 'dark' | 'system' | string & {};
|
153
153
|
variations?: false | VariationsOptions;
|
154
154
|
themes?: Record<string, ThemeDefinition>;
|
155
155
|
stylesheetId?: string;
|
@@ -277,7 +277,7 @@ interface IconAliases {
|
|
277
277
|
interface IconProps {
|
278
278
|
tag: string | JSXComponent;
|
279
279
|
icon?: IconValue;
|
280
|
-
disabled?:
|
280
|
+
disabled?: boolean;
|
281
281
|
}
|
282
282
|
type IconComponent = JSXComponent<IconProps>;
|
283
283
|
interface IconSet {
|
@@ -2553,64 +2553,66 @@ declare module 'vue' {
|
|
2553
2553
|
$children?: VNodeChild
|
2554
2554
|
}
|
2555
2555
|
export interface GlobalComponents {
|
2556
|
-
VAlert: typeof import('vuetify/components')['VAlert']
|
2557
|
-
VAlertTitle: typeof import('vuetify/components')['VAlertTitle']
|
2558
|
-
VBanner: typeof import('vuetify/components')['VBanner']
|
2559
|
-
VBannerActions: typeof import('vuetify/components')['VBannerActions']
|
2560
|
-
VBannerText: typeof import('vuetify/components')['VBannerText']
|
2561
2556
|
VAppBar: typeof import('vuetify/components')['VAppBar']
|
2562
2557
|
VAppBarNavIcon: typeof import('vuetify/components')['VAppBarNavIcon']
|
2563
2558
|
VAppBarTitle: typeof import('vuetify/components')['VAppBarTitle']
|
2564
|
-
VAvatar: typeof import('vuetify/components')['VAvatar']
|
2565
2559
|
VApp: typeof import('vuetify/components')['VApp']
|
2560
|
+
VAutocomplete: typeof import('vuetify/components')['VAutocomplete']
|
2561
|
+
VAlert: typeof import('vuetify/components')['VAlert']
|
2562
|
+
VAlertTitle: typeof import('vuetify/components')['VAlertTitle']
|
2563
|
+
VAvatar: typeof import('vuetify/components')['VAvatar']
|
2564
|
+
VBottomNavigation: typeof import('vuetify/components')['VBottomNavigation']
|
2566
2565
|
VBottomSheet: typeof import('vuetify/components')['VBottomSheet']
|
2567
2566
|
VBreadcrumbs: typeof import('vuetify/components')['VBreadcrumbs']
|
2568
2567
|
VBreadcrumbsItem: typeof import('vuetify/components')['VBreadcrumbsItem']
|
2569
2568
|
VBreadcrumbsDivider: typeof import('vuetify/components')['VBreadcrumbsDivider']
|
2570
|
-
VBtn: typeof import('vuetify/components')['VBtn']
|
2571
|
-
VBtnToggle: typeof import('vuetify/components')['VBtnToggle']
|
2572
2569
|
VBtnGroup: typeof import('vuetify/components')['VBtnGroup']
|
2570
|
+
VBtnToggle: typeof import('vuetify/components')['VBtnToggle']
|
2571
|
+
VBtn: typeof import('vuetify/components')['VBtn']
|
2572
|
+
VBanner: typeof import('vuetify/components')['VBanner']
|
2573
|
+
VBannerActions: typeof import('vuetify/components')['VBannerActions']
|
2574
|
+
VBannerText: typeof import('vuetify/components')['VBannerText']
|
2575
|
+
VChip: typeof import('vuetify/components')['VChip']
|
2576
|
+
VChipGroup: typeof import('vuetify/components')['VChipGroup']
|
2577
|
+
VColorPicker: typeof import('vuetify/components')['VColorPicker']
|
2578
|
+
VCarousel: typeof import('vuetify/components')['VCarousel']
|
2579
|
+
VCarouselItem: typeof import('vuetify/components')['VCarouselItem']
|
2580
|
+
VCode: typeof import('vuetify/components')['VCode']
|
2581
|
+
VCombobox: typeof import('vuetify/components')['VCombobox']
|
2582
|
+
VCheckbox: typeof import('vuetify/components')['VCheckbox']
|
2583
|
+
VCheckboxBtn: typeof import('vuetify/components')['VCheckboxBtn']
|
2573
2584
|
VCard: typeof import('vuetify/components')['VCard']
|
2574
2585
|
VCardActions: typeof import('vuetify/components')['VCardActions']
|
2575
2586
|
VCardItem: typeof import('vuetify/components')['VCardItem']
|
2576
2587
|
VCardSubtitle: typeof import('vuetify/components')['VCardSubtitle']
|
2577
2588
|
VCardText: typeof import('vuetify/components')['VCardText']
|
2578
2589
|
VCardTitle: typeof import('vuetify/components')['VCardTitle']
|
2579
|
-
VCarousel: typeof import('vuetify/components')['VCarousel']
|
2580
|
-
VCarouselItem: typeof import('vuetify/components')['VCarouselItem']
|
2581
|
-
VBadge: typeof import('vuetify/components')['VBadge']
|
2582
|
-
VAutocomplete: typeof import('vuetify/components')['VAutocomplete']
|
2583
|
-
VBottomNavigation: typeof import('vuetify/components')['VBottomNavigation']
|
2584
|
-
VCheckbox: typeof import('vuetify/components')['VCheckbox']
|
2585
|
-
VCheckboxBtn: typeof import('vuetify/components')['VCheckboxBtn']
|
2586
|
-
VChipGroup: typeof import('vuetify/components')['VChipGroup']
|
2587
|
-
VCode: typeof import('vuetify/components')['VCode']
|
2588
|
-
VChip: typeof import('vuetify/components')['VChip']
|
2589
|
-
VColorPicker: typeof import('vuetify/components')['VColorPicker']
|
2590
|
-
VCombobox: typeof import('vuetify/components')['VCombobox']
|
2591
2590
|
VDatePicker: typeof import('vuetify/components')['VDatePicker']
|
2592
2591
|
VDatePickerControls: typeof import('vuetify/components')['VDatePickerControls']
|
2593
2592
|
VDatePickerHeader: typeof import('vuetify/components')['VDatePickerHeader']
|
2594
2593
|
VDatePickerMonth: typeof import('vuetify/components')['VDatePickerMonth']
|
2595
2594
|
VDatePickerMonths: typeof import('vuetify/components')['VDatePickerMonths']
|
2596
2595
|
VDatePickerYears: typeof import('vuetify/components')['VDatePickerYears']
|
2597
|
-
|
2598
|
-
|
2596
|
+
VDataTable: typeof import('vuetify/components')['VDataTable']
|
2597
|
+
VDataTableHeaders: typeof import('vuetify/components')['VDataTableHeaders']
|
2598
|
+
VDataTableFooter: typeof import('vuetify/components')['VDataTableFooter']
|
2599
|
+
VDataTableRows: typeof import('vuetify/components')['VDataTableRows']
|
2600
|
+
VDataTableRow: typeof import('vuetify/components')['VDataTableRow']
|
2601
|
+
VDataTableVirtual: typeof import('vuetify/components')['VDataTableVirtual']
|
2602
|
+
VDataTableServer: typeof import('vuetify/components')['VDataTableServer']
|
2603
|
+
VBadge: typeof import('vuetify/components')['VBadge']
|
2599
2604
|
VDialog: typeof import('vuetify/components')['VDialog']
|
2600
2605
|
VExpansionPanels: typeof import('vuetify/components')['VExpansionPanels']
|
2601
2606
|
VExpansionPanel: typeof import('vuetify/components')['VExpansionPanel']
|
2602
2607
|
VExpansionPanelText: typeof import('vuetify/components')['VExpansionPanelText']
|
2603
2608
|
VExpansionPanelTitle: typeof import('vuetify/components')['VExpansionPanelTitle']
|
2604
2609
|
VFab: typeof import('vuetify/components')['VFab']
|
2610
|
+
VFileInput: typeof import('vuetify/components')['VFileInput']
|
2611
|
+
VDivider: typeof import('vuetify/components')['VDivider']
|
2605
2612
|
VFooter: typeof import('vuetify/components')['VFooter']
|
2606
2613
|
VEmptyState: typeof import('vuetify/components')['VEmptyState']
|
2607
|
-
|
2608
|
-
|
2609
|
-
VDataTableFooter: typeof import('vuetify/components')['VDataTableFooter']
|
2610
|
-
VDataTableRows: typeof import('vuetify/components')['VDataTableRows']
|
2611
|
-
VDataTableRow: typeof import('vuetify/components')['VDataTableRow']
|
2612
|
-
VDataTableVirtual: typeof import('vuetify/components')['VDataTableVirtual']
|
2613
|
-
VDataTableServer: typeof import('vuetify/components')['VDataTableServer']
|
2614
|
+
VField: typeof import('vuetify/components')['VField']
|
2615
|
+
VFieldLabel: typeof import('vuetify/components')['VFieldLabel']
|
2614
2616
|
VIcon: typeof import('vuetify/components')['VIcon']
|
2615
2617
|
VComponentIcon: typeof import('vuetify/components')['VComponentIcon']
|
2616
2618
|
VSvgIcon: typeof import('vuetify/components')['VSvgIcon']
|
@@ -2619,7 +2621,10 @@ declare module 'vue' {
|
|
2619
2621
|
VInfiniteScroll: typeof import('vuetify/components')['VInfiniteScroll']
|
2620
2622
|
VImg: typeof import('vuetify/components')['VImg']
|
2621
2623
|
VInput: typeof import('vuetify/components')['VInput']
|
2624
|
+
VKbd: typeof import('vuetify/components')['VKbd']
|
2622
2625
|
VLabel: typeof import('vuetify/components')['VLabel']
|
2626
|
+
VItemGroup: typeof import('vuetify/components')['VItemGroup']
|
2627
|
+
VItem: typeof import('vuetify/components')['VItem']
|
2623
2628
|
VList: typeof import('vuetify/components')['VList']
|
2624
2629
|
VListGroup: typeof import('vuetify/components')['VListGroup']
|
2625
2630
|
VListImg: typeof import('vuetify/components')['VListImg']
|
@@ -2629,79 +2634,78 @@ declare module 'vue' {
|
|
2629
2634
|
VListItemSubtitle: typeof import('vuetify/components')['VListItemSubtitle']
|
2630
2635
|
VListItemTitle: typeof import('vuetify/components')['VListItemTitle']
|
2631
2636
|
VListSubheader: typeof import('vuetify/components')['VListSubheader']
|
2632
|
-
VItemGroup: typeof import('vuetify/components')['VItemGroup']
|
2633
|
-
VItem: typeof import('vuetify/components')['VItem']
|
2634
|
-
VMenu: typeof import('vuetify/components')['VMenu']
|
2635
2637
|
VMain: typeof import('vuetify/components')['VMain']
|
2636
2638
|
VMessages: typeof import('vuetify/components')['VMessages']
|
2639
|
+
VMenu: typeof import('vuetify/components')['VMenu']
|
2637
2640
|
VNavigationDrawer: typeof import('vuetify/components')['VNavigationDrawer']
|
2638
|
-
VNumberInput: typeof import('vuetify/components')['VNumberInput']
|
2639
|
-
VOverlay: typeof import('vuetify/components')['VOverlay']
|
2640
2641
|
VOtpInput: typeof import('vuetify/components')['VOtpInput']
|
2641
2642
|
VPagination: typeof import('vuetify/components')['VPagination']
|
2642
|
-
|
2643
|
-
|
2643
|
+
VOverlay: typeof import('vuetify/components')['VOverlay']
|
2644
|
+
VNumberInput: typeof import('vuetify/components')['VNumberInput']
|
2644
2645
|
VRadioGroup: typeof import('vuetify/components')['VRadioGroup']
|
2646
|
+
VProgressLinear: typeof import('vuetify/components')['VProgressLinear']
|
2647
|
+
VProgressCircular: typeof import('vuetify/components')['VProgressCircular']
|
2645
2648
|
VRating: typeof import('vuetify/components')['VRating']
|
2646
2649
|
VSelectionControl: typeof import('vuetify/components')['VSelectionControl']
|
2647
2650
|
VSelectionControlGroup: typeof import('vuetify/components')['VSelectionControlGroup']
|
2651
|
+
VSkeletonLoader: typeof import('vuetify/components')['VSkeletonLoader']
|
2648
2652
|
VSlideGroup: typeof import('vuetify/components')['VSlideGroup']
|
2649
2653
|
VSlideGroupItem: typeof import('vuetify/components')['VSlideGroupItem']
|
2650
|
-
|
2654
|
+
VSlider: typeof import('vuetify/components')['VSlider']
|
2651
2655
|
VSnackbar: typeof import('vuetify/components')['VSnackbar']
|
2652
2656
|
VSheet: typeof import('vuetify/components')['VSheet']
|
2653
|
-
VSelect: typeof import('vuetify/components')['VSelect']
|
2654
2657
|
VStepper: typeof import('vuetify/components')['VStepper']
|
2655
2658
|
VStepperActions: typeof import('vuetify/components')['VStepperActions']
|
2656
2659
|
VStepperHeader: typeof import('vuetify/components')['VStepperHeader']
|
2657
2660
|
VStepperItem: typeof import('vuetify/components')['VStepperItem']
|
2658
2661
|
VStepperWindow: typeof import('vuetify/components')['VStepperWindow']
|
2659
2662
|
VStepperWindowItem: typeof import('vuetify/components')['VStepperWindowItem']
|
2660
|
-
|
2663
|
+
VSwitch: typeof import('vuetify/components')['VSwitch']
|
2661
2664
|
VSystemBar: typeof import('vuetify/components')['VSystemBar']
|
2665
|
+
VTextarea: typeof import('vuetify/components')['VTextarea']
|
2662
2666
|
VTable: typeof import('vuetify/components')['VTable']
|
2663
|
-
VSwitch: typeof import('vuetify/components')['VSwitch']
|
2664
2667
|
VTab: typeof import('vuetify/components')['VTab']
|
2665
2668
|
VTabs: typeof import('vuetify/components')['VTabs']
|
2666
2669
|
VTabsWindow: typeof import('vuetify/components')['VTabsWindow']
|
2667
2670
|
VTabsWindowItem: typeof import('vuetify/components')['VTabsWindowItem']
|
2668
|
-
VTextarea: typeof import('vuetify/components')['VTextarea']
|
2669
|
-
VTextField: typeof import('vuetify/components')['VTextField']
|
2670
2671
|
VTimeline: typeof import('vuetify/components')['VTimeline']
|
2671
2672
|
VTimelineItem: typeof import('vuetify/components')['VTimelineItem']
|
2672
|
-
|
2673
|
+
VTreeview: typeof import('vuetify/components')['VTreeview']
|
2674
|
+
VTreeviewItem: typeof import('vuetify/components')['VTreeviewItem']
|
2675
|
+
VTreeviewGroup: typeof import('vuetify/components')['VTreeviewGroup']
|
2676
|
+
VTimePicker: typeof import('vuetify/components')['VTimePicker']
|
2677
|
+
VTimePickerClock: typeof import('vuetify/components')['VTimePickerClock']
|
2678
|
+
VTimePickerControls: typeof import('vuetify/components')['VTimePickerControls']
|
2673
2679
|
VToolbar: typeof import('vuetify/components')['VToolbar']
|
2674
2680
|
VToolbarTitle: typeof import('vuetify/components')['VToolbarTitle']
|
2675
2681
|
VToolbarItems: typeof import('vuetify/components')['VToolbarItems']
|
2676
2682
|
VWindow: typeof import('vuetify/components')['VWindow']
|
2677
2683
|
VWindowItem: typeof import('vuetify/components')['VWindowItem']
|
2678
|
-
VField: typeof import('vuetify/components')['VField']
|
2679
|
-
VFieldLabel: typeof import('vuetify/components')['VFieldLabel']
|
2680
|
-
VFileInput: typeof import('vuetify/components')['VFileInput']
|
2681
2684
|
VConfirmEdit: typeof import('vuetify/components')['VConfirmEdit']
|
2682
2685
|
VDataIterator: typeof import('vuetify/components')['VDataIterator']
|
2683
2686
|
VDefaultsProvider: typeof import('vuetify/components')['VDefaultsProvider']
|
2687
|
+
VForm: typeof import('vuetify/components')['VForm']
|
2684
2688
|
VContainer: typeof import('vuetify/components')['VContainer']
|
2685
2689
|
VCol: typeof import('vuetify/components')['VCol']
|
2686
2690
|
VRow: typeof import('vuetify/components')['VRow']
|
2687
2691
|
VSpacer: typeof import('vuetify/components')['VSpacer']
|
2688
2692
|
VHover: typeof import('vuetify/components')['VHover']
|
2689
|
-
VForm: typeof import('vuetify/components')['VForm']
|
2690
2693
|
VLayout: typeof import('vuetify/components')['VLayout']
|
2691
2694
|
VLayoutItem: typeof import('vuetify/components')['VLayoutItem']
|
2692
2695
|
VLazy: typeof import('vuetify/components')['VLazy']
|
2693
|
-
VKbd: typeof import('vuetify/components')['VKbd']
|
2694
2696
|
VLocaleProvider: typeof import('vuetify/components')['VLocaleProvider']
|
2695
2697
|
VNoSsr: typeof import('vuetify/components')['VNoSsr']
|
2696
2698
|
VParallax: typeof import('vuetify/components')['VParallax']
|
2697
|
-
VRadio: typeof import('vuetify/components')['VRadio']
|
2698
2699
|
VRangeSlider: typeof import('vuetify/components')['VRangeSlider']
|
2699
2700
|
VResponsive: typeof import('vuetify/components')['VResponsive']
|
2701
|
+
VSelect: typeof import('vuetify/components')['VSelect']
|
2702
|
+
VRadio: typeof import('vuetify/components')['VRadio']
|
2703
|
+
VSnackbarQueue: typeof import('vuetify/components')['VSnackbarQueue']
|
2700
2704
|
VSparkline: typeof import('vuetify/components')['VSparkline']
|
2701
2705
|
VSpeedDial: typeof import('vuetify/components')['VSpeedDial']
|
2702
2706
|
VThemeProvider: typeof import('vuetify/components')['VThemeProvider']
|
2703
|
-
|
2704
|
-
|
2707
|
+
VTooltip: typeof import('vuetify/components')['VTooltip']
|
2708
|
+
VCounter: typeof import('vuetify/components')['VCounter']
|
2705
2709
|
VFabTransition: typeof import('vuetify/components')['VFabTransition']
|
2706
2710
|
VDialogBottomTransition: typeof import('vuetify/components')['VDialogBottomTransition']
|
2707
2711
|
VDialogTopTransition: typeof import('vuetify/components')['VDialogTopTransition']
|
@@ -2718,31 +2722,27 @@ declare module 'vue' {
|
|
2718
2722
|
VExpandTransition: typeof import('vuetify/components')['VExpandTransition']
|
2719
2723
|
VExpandXTransition: typeof import('vuetify/components')['VExpandXTransition']
|
2720
2724
|
VDialogTransition: typeof import('vuetify/components')['VDialogTransition']
|
2725
|
+
VValidation: typeof import('vuetify/components')['VValidation']
|
2721
2726
|
VVirtualScroll: typeof import('vuetify/components')['VVirtualScroll']
|
2722
|
-
|
2723
|
-
VCalendar: typeof import('vuetify/labs/components')['VCalendar']
|
2724
|
-
VCalendarDay: typeof import('vuetify/labs/components')['VCalendarDay']
|
2725
|
-
VCalendarHeader: typeof import('vuetify/labs/components')['VCalendarHeader']
|
2726
|
-
VCalendarInterval: typeof import('vuetify/labs/components')['VCalendarInterval']
|
2727
|
-
VCalendarIntervalEvent: typeof import('vuetify/labs/components')['VCalendarIntervalEvent']
|
2728
|
-
VCalendarMonthDay: typeof import('vuetify/labs/components')['VCalendarMonthDay']
|
2729
|
-
VIconBtn: typeof import('vuetify/labs/components')['VIconBtn']
|
2727
|
+
VTextField: typeof import('vuetify/components')['VTextField']
|
2730
2728
|
VFileUpload: typeof import('vuetify/labs/components')['VFileUpload']
|
2731
2729
|
VFileUploadItem: typeof import('vuetify/labs/components')['VFileUploadItem']
|
2730
|
+
VIconBtn: typeof import('vuetify/labs/components')['VIconBtn']
|
2732
2731
|
VPicker: typeof import('vuetify/labs/components')['VPicker']
|
2733
2732
|
VPickerTitle: typeof import('vuetify/labs/components')['VPickerTitle']
|
2734
|
-
VTreeview: typeof import('vuetify/labs/components')['VTreeview']
|
2735
|
-
VTreeviewItem: typeof import('vuetify/labs/components')['VTreeviewItem']
|
2736
|
-
VTreeviewGroup: typeof import('vuetify/labs/components')['VTreeviewGroup']
|
2737
|
-
VTimePicker: typeof import('vuetify/labs/components')['VTimePicker']
|
2738
|
-
VTimePickerClock: typeof import('vuetify/labs/components')['VTimePickerClock']
|
2739
|
-
VTimePickerControls: typeof import('vuetify/labs/components')['VTimePickerControls']
|
2740
2733
|
VStepperVertical: typeof import('vuetify/labs/components')['VStepperVertical']
|
2741
2734
|
VStepperVerticalItem: typeof import('vuetify/labs/components')['VStepperVerticalItem']
|
2742
2735
|
VStepperVerticalActions: typeof import('vuetify/labs/components')['VStepperVerticalActions']
|
2743
|
-
|
2736
|
+
VColorInput: typeof import('vuetify/labs/components')['VColorInput']
|
2744
2737
|
VDateInput: typeof import('vuetify/labs/components')['VDateInput']
|
2745
2738
|
VPullToRefresh: typeof import('vuetify/labs/components')['VPullToRefresh']
|
2739
|
+
VMaskInput: typeof import('vuetify/labs/components')['VMaskInput']
|
2740
|
+
VCalendar: typeof import('vuetify/labs/components')['VCalendar']
|
2741
|
+
VCalendarDay: typeof import('vuetify/labs/components')['VCalendarDay']
|
2742
|
+
VCalendarHeader: typeof import('vuetify/labs/components')['VCalendarHeader']
|
2743
|
+
VCalendarInterval: typeof import('vuetify/labs/components')['VCalendarInterval']
|
2744
|
+
VCalendarIntervalEvent: typeof import('vuetify/labs/components')['VCalendarIntervalEvent']
|
2745
|
+
VCalendarMonthDay: typeof import('vuetify/labs/components')['VCalendarMonthDay']
|
2746
2746
|
}
|
2747
2747
|
export interface GlobalDirectives {
|
2748
2748
|
vClickOutside: typeof import('vuetify/directives')['ClickOutside']
|
package/lib/framework.js
CHANGED
@@ -268,7 +268,7 @@ export type VCalendarSlots = VCalendarDaySlots & {
|
|
268
268
|
};
|
269
269
|
'day-event': {
|
270
270
|
day?: CalendarDay;
|
271
|
-
allDay:
|
271
|
+
allDay: boolean;
|
272
272
|
event?: Record<string, unknown>;
|
273
273
|
};
|
274
274
|
header: {
|
@@ -279,7 +279,7 @@ export type VCalendarSlots = VCalendarDaySlots & {
|
|
279
279
|
};
|
280
280
|
'day-interval': {
|
281
281
|
day?: CalendarDay;
|
282
|
-
dayIndex:
|
282
|
+
dayIndex: number;
|
283
283
|
events?: Array<any>;
|
284
284
|
};
|
285
285
|
title: {
|
@@ -359,7 +359,7 @@ export declare const VCalendar: {
|
|
359
359
|
}) => import("vue").VNodeChild) | undefined;
|
360
360
|
'day-event'?: ((arg: {
|
361
361
|
day?: CalendarDay;
|
362
|
-
allDay:
|
362
|
+
allDay: boolean;
|
363
363
|
event?: Record<string, unknown>;
|
364
364
|
}) => import("vue").VNodeChild) | undefined;
|
365
365
|
header?: ((arg: {
|
@@ -370,7 +370,7 @@ export declare const VCalendar: {
|
|
370
370
|
}) => import("vue").VNodeChild) | undefined;
|
371
371
|
'day-interval'?: ((arg: {
|
372
372
|
day?: CalendarDay;
|
373
|
-
dayIndex:
|
373
|
+
dayIndex: number;
|
374
374
|
events?: Array<any>;
|
375
375
|
}) => import("vue").VNodeChild) | undefined;
|
376
376
|
title?: ((arg: {
|
@@ -416,7 +416,7 @@ export declare const VCalendar: {
|
|
416
416
|
}) => import("vue").VNodeChild) | undefined;
|
417
417
|
'day-event'?: false | ((arg: {
|
418
418
|
day?: CalendarDay;
|
419
|
-
allDay:
|
419
|
+
allDay: boolean;
|
420
420
|
event?: Record<string, unknown>;
|
421
421
|
}) => import("vue").VNodeChild) | undefined;
|
422
422
|
header?: false | ((arg: {
|
@@ -427,7 +427,7 @@ export declare const VCalendar: {
|
|
427
427
|
}) => import("vue").VNodeChild) | undefined;
|
428
428
|
'day-interval'?: false | ((arg: {
|
429
429
|
day?: CalendarDay;
|
430
|
-
dayIndex:
|
430
|
+
dayIndex: number;
|
431
431
|
events?: Array<any>;
|
432
432
|
}) => import("vue").VNodeChild) | undefined;
|
433
433
|
title?: false | ((arg: {
|
@@ -473,7 +473,7 @@ export declare const VCalendar: {
|
|
473
473
|
}) => import("vue").VNodeChild) | undefined;
|
474
474
|
"v-slot:day-event"?: false | ((arg: {
|
475
475
|
day?: CalendarDay;
|
476
|
-
allDay:
|
476
|
+
allDay: boolean;
|
477
477
|
event?: Record<string, unknown>;
|
478
478
|
}) => import("vue").VNodeChild) | undefined;
|
479
479
|
"v-slot:header"?: false | ((arg: {
|
@@ -484,7 +484,7 @@ export declare const VCalendar: {
|
|
484
484
|
}) => import("vue").VNodeChild) | undefined;
|
485
485
|
"v-slot:day-interval"?: false | ((arg: {
|
486
486
|
day?: CalendarDay;
|
487
|
-
dayIndex:
|
487
|
+
dayIndex: number;
|
488
488
|
events?: Array<any>;
|
489
489
|
}) => import("vue").VNodeChild) | undefined;
|
490
490
|
"v-slot:title"?: false | ((arg: {
|
@@ -563,7 +563,7 @@ export declare const VCalendar: {
|
|
563
563
|
}) => import("vue").VNode[];
|
564
564
|
'day-event': (arg: {
|
565
565
|
day?: CalendarDay;
|
566
|
-
allDay:
|
566
|
+
allDay: boolean;
|
567
567
|
event?: Record<string, unknown>;
|
568
568
|
}) => import("vue").VNode[];
|
569
569
|
header: (arg: {
|
@@ -574,7 +574,7 @@ export declare const VCalendar: {
|
|
574
574
|
}) => import("vue").VNode[];
|
575
575
|
'day-interval': (arg: {
|
576
576
|
day?: CalendarDay;
|
577
|
-
dayIndex:
|
577
|
+
dayIndex: number;
|
578
578
|
events?: Array<any>;
|
579
579
|
}) => import("vue").VNode[];
|
580
580
|
title: (arg: {
|
@@ -659,7 +659,7 @@ export declare const VCalendar: {
|
|
659
659
|
}) => import("vue").VNodeChild) | undefined;
|
660
660
|
'day-event'?: ((arg: {
|
661
661
|
day?: CalendarDay;
|
662
|
-
allDay:
|
662
|
+
allDay: boolean;
|
663
663
|
event?: Record<string, unknown>;
|
664
664
|
}) => import("vue").VNodeChild) | undefined;
|
665
665
|
header?: ((arg: {
|
@@ -670,7 +670,7 @@ export declare const VCalendar: {
|
|
670
670
|
}) => import("vue").VNodeChild) | undefined;
|
671
671
|
'day-interval'?: ((arg: {
|
672
672
|
day?: CalendarDay;
|
673
|
-
dayIndex:
|
673
|
+
dayIndex: number;
|
674
674
|
events?: Array<any>;
|
675
675
|
}) => import("vue").VNodeChild) | undefined;
|
676
676
|
title?: ((arg: {
|
@@ -716,7 +716,7 @@ export declare const VCalendar: {
|
|
716
716
|
}) => import("vue").VNodeChild) | undefined;
|
717
717
|
'day-event'?: false | ((arg: {
|
718
718
|
day?: CalendarDay;
|
719
|
-
allDay:
|
719
|
+
allDay: boolean;
|
720
720
|
event?: Record<string, unknown>;
|
721
721
|
}) => import("vue").VNodeChild) | undefined;
|
722
722
|
header?: false | ((arg: {
|
@@ -727,7 +727,7 @@ export declare const VCalendar: {
|
|
727
727
|
}) => import("vue").VNodeChild) | undefined;
|
728
728
|
'day-interval'?: false | ((arg: {
|
729
729
|
day?: CalendarDay;
|
730
|
-
dayIndex:
|
730
|
+
dayIndex: number;
|
731
731
|
events?: Array<any>;
|
732
732
|
}) => import("vue").VNodeChild) | undefined;
|
733
733
|
title?: false | ((arg: {
|
@@ -773,7 +773,7 @@ export declare const VCalendar: {
|
|
773
773
|
}) => import("vue").VNodeChild) | undefined;
|
774
774
|
"v-slot:day-event"?: false | ((arg: {
|
775
775
|
day?: CalendarDay;
|
776
|
-
allDay:
|
776
|
+
allDay: boolean;
|
777
777
|
event?: Record<string, unknown>;
|
778
778
|
}) => import("vue").VNodeChild) | undefined;
|
779
779
|
"v-slot:header"?: false | ((arg: {
|
@@ -784,7 +784,7 @@ export declare const VCalendar: {
|
|
784
784
|
}) => import("vue").VNodeChild) | undefined;
|
785
785
|
"v-slot:day-interval"?: false | ((arg: {
|
786
786
|
day?: CalendarDay;
|
787
|
-
dayIndex:
|
787
|
+
dayIndex: number;
|
788
788
|
events?: Array<any>;
|
789
789
|
}) => import("vue").VNodeChild) | undefined;
|
790
790
|
"v-slot:title"?: false | ((arg: {
|
@@ -895,7 +895,7 @@ export declare const VCalendar: {
|
|
895
895
|
}) => import("vue").VNodeChild) | undefined;
|
896
896
|
'day-event'?: ((arg: {
|
897
897
|
day?: CalendarDay;
|
898
|
-
allDay:
|
898
|
+
allDay: boolean;
|
899
899
|
event?: Record<string, unknown>;
|
900
900
|
}) => import("vue").VNodeChild) | undefined;
|
901
901
|
header?: ((arg: {
|
@@ -906,7 +906,7 @@ export declare const VCalendar: {
|
|
906
906
|
}) => import("vue").VNodeChild) | undefined;
|
907
907
|
'day-interval'?: ((arg: {
|
908
908
|
day?: CalendarDay;
|
909
|
-
dayIndex:
|
909
|
+
dayIndex: number;
|
910
910
|
events?: Array<any>;
|
911
911
|
}) => import("vue").VNodeChild) | undefined;
|
912
912
|
title?: ((arg: {
|
@@ -952,7 +952,7 @@ export declare const VCalendar: {
|
|
952
952
|
}) => import("vue").VNodeChild) | undefined;
|
953
953
|
'day-event'?: false | ((arg: {
|
954
954
|
day?: CalendarDay;
|
955
|
-
allDay:
|
955
|
+
allDay: boolean;
|
956
956
|
event?: Record<string, unknown>;
|
957
957
|
}) => import("vue").VNodeChild) | undefined;
|
958
958
|
header?: false | ((arg: {
|
@@ -963,7 +963,7 @@ export declare const VCalendar: {
|
|
963
963
|
}) => import("vue").VNodeChild) | undefined;
|
964
964
|
'day-interval'?: false | ((arg: {
|
965
965
|
day?: CalendarDay;
|
966
|
-
dayIndex:
|
966
|
+
dayIndex: number;
|
967
967
|
events?: Array<any>;
|
968
968
|
}) => import("vue").VNodeChild) | undefined;
|
969
969
|
title?: false | ((arg: {
|
@@ -1009,7 +1009,7 @@ export declare const VCalendar: {
|
|
1009
1009
|
}) => import("vue").VNodeChild) | undefined;
|
1010
1010
|
"v-slot:day-event"?: false | ((arg: {
|
1011
1011
|
day?: CalendarDay;
|
1012
|
-
allDay:
|
1012
|
+
allDay: boolean;
|
1013
1013
|
event?: Record<string, unknown>;
|
1014
1014
|
}) => import("vue").VNodeChild) | undefined;
|
1015
1015
|
"v-slot:header"?: false | ((arg: {
|
@@ -1020,7 +1020,7 @@ export declare const VCalendar: {
|
|
1020
1020
|
}) => import("vue").VNodeChild) | undefined;
|
1021
1021
|
"v-slot:day-interval"?: false | ((arg: {
|
1022
1022
|
day?: CalendarDay;
|
1023
|
-
dayIndex:
|
1023
|
+
dayIndex: number;
|
1024
1024
|
events?: Array<any>;
|
1025
1025
|
}) => import("vue").VNodeChild) | undefined;
|
1026
1026
|
"v-slot:title"?: false | ((arg: {
|
@@ -1099,7 +1099,7 @@ export declare const VCalendar: {
|
|
1099
1099
|
}) => import("vue").VNode[];
|
1100
1100
|
'day-event': (arg: {
|
1101
1101
|
day?: CalendarDay;
|
1102
|
-
allDay:
|
1102
|
+
allDay: boolean;
|
1103
1103
|
event?: Record<string, unknown>;
|
1104
1104
|
}) => import("vue").VNode[];
|
1105
1105
|
header: (arg: {
|
@@ -1110,7 +1110,7 @@ export declare const VCalendar: {
|
|
1110
1110
|
}) => import("vue").VNode[];
|
1111
1111
|
'day-interval': (arg: {
|
1112
1112
|
day?: CalendarDay;
|
1113
|
-
dayIndex:
|
1113
|
+
dayIndex: number;
|
1114
1114
|
events?: Array<any>;
|
1115
1115
|
}) => import("vue").VNode[];
|
1116
1116
|
title: (arg: {
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"VCalendar.js","names":["makeVCalendarDayProps","VCalendarDay","makeVCalendarHeaderProps","VCalendarHeader","VCalendarMonthDay","makeCalendarProps","useCalendar","useDate","computed","nextTick","chunkArray","genericComponent","getPrefixedEventHandlers","pick","propsFactory","useRender","makeVCalendarProps","hideHeader","Boolean","hideWeekNumber","VCalendar","name","props","emits","next","prev","today","setup","_ref","attrs","emit","slots","adapter","daysInMonth","daysInWeek","genDays","model","displayValue","weekNumbers","weekDays","dayNames","getWeekdays","onClickNext","viewMode","value","addMonths","addDays","onClickPrev","onClickToday","date","title","format","calendarDayProps","filterProps","calendarHeaderProps","_createElementVNode","_normalizeClass","header","clickNext","clickPrev","clickToday","_createVNode","_mergeProps","length","hideDayHeader","map","weekday","week","wi","weekNumber","day","getTime","events","filter","e","isSameDay","start","end","i","dayIndex"],"sources":["../../../src/labs/VCalendar/VCalendar.tsx"],"sourcesContent":["// Styles\nimport './VCalendar.sass'\n\n// Components\nimport { makeVCalendarDayProps, VCalendarDay } from './VCalendarDay'\nimport { makeVCalendarHeaderProps, VCalendarHeader } from './VCalendarHeader'\nimport { VCalendarMonthDay } from './VCalendarMonthDay'\n\n// Composables\nimport { makeCalendarProps, useCalendar } from '@/composables/calendar'\nimport { useDate } from '@/composables/date/date'\n\n// Utilities\nimport { computed, nextTick } from 'vue'\nimport { chunkArray, genericComponent, getPrefixedEventHandlers, pick, propsFactory, useRender } from '@/util'\n\n// Types\nimport type { VCalendarDaySlots } from './VCalendarDay'\nimport type { CalendarDay } from '@/composables/calendar'\n\nexport const makeVCalendarProps = propsFactory({\n hideHeader: Boolean,\n hideWeekNumber: Boolean,\n\n ...makeCalendarProps(),\n ...makeVCalendarDayProps(),\n ...makeVCalendarHeaderProps(),\n}, 'VCalendar')\n\nexport type VCalendarSlots = VCalendarDaySlots & {\n 'day-body': { day?: CalendarDay, events?: Array<any> }\n 'day-title': { title?: number | string }\n 'day-event': { day?: CalendarDay, allDay: Boolean, event?: Record<string, unknown> }\n header: { title: string, clickNext: Function, clickPrev: Function, clickToday: Function }\n 'day-interval': { day?: CalendarDay, dayIndex: Number, events?: Array<any> }\n title: { title?: string }\n}\n\nexport const VCalendar = genericComponent<VCalendarSlots>()({\n name: 'VCalendar',\n\n props: makeVCalendarProps(),\n\n emits: {\n next: null,\n prev: null,\n today: null,\n 'update:modelValue': null,\n },\n\n setup (props, { attrs, emit, slots }) {\n const adapter = useDate()\n\n const { daysInMonth, daysInWeek, genDays, model, displayValue, weekNumbers, weekDays } = useCalendar(props as any)\n\n const dayNames = adapter.getWeekdays()\n\n function onClickNext () {\n if (props.viewMode === 'month') {\n model.value = [adapter.addMonths(displayValue.value, 1)]\n } else if (props.viewMode === 'week') {\n model.value = [adapter.addDays(displayValue.value, 7)]\n } else if (props.viewMode === 'day') {\n model.value = [adapter.addDays(displayValue.value, 1)]\n }\n nextTick(() => {\n emit('next', model.value[0])\n })\n }\n\n function onClickPrev () {\n if (props.viewMode === 'month') {\n model.value = [adapter.addMonths(displayValue.value, -1)]\n } else if (props.viewMode === 'week') {\n model.value = [adapter.addDays(displayValue.value, -7)]\n } else if (props.viewMode === 'day') {\n model.value = [adapter.addDays(displayValue.value, -1)]\n }\n nextTick(() => {\n emit('prev', model.value[0])\n })\n }\n\n function onClickToday () {\n const date = adapter.date()\n model.value = [date]\n nextTick(() => {\n emit('today', model.value[0])\n })\n }\n\n const title = computed(() => {\n return adapter.format(displayValue.value, 'monthAndYear')\n })\n\n useRender(() => {\n const calendarDayProps = VCalendarDay.filterProps(props)\n const calendarHeaderProps = VCalendarHeader.filterProps(props)\n\n return (\n <div class={[\n 'v-calendar',\n {\n 'v-calendar-monthly': props.viewMode === 'month',\n 'v-calendar-weekly': props.viewMode === 'week',\n 'v-calendar-day': props.viewMode === 'day',\n },\n ]}\n >\n <div>\n { !props.hideHeader && (\n slots.header?.({\n title: title.value,\n clickNext: onClickNext,\n clickPrev: onClickPrev,\n clickToday: onClickToday,\n }) ?? (\n <VCalendarHeader\n key=\"calendar-header\"\n { ...calendarHeaderProps }\n title={ title.value }\n onClick:next={ onClickNext }\n onClick:prev={ onClickPrev }\n onClick:toToday={ onClickToday }\n >\n {{ title: slots.title }}\n </VCalendarHeader>\n )\n )}\n </div>\n\n <div class={['v-calendar__container', `days__${weekDays.value.length}`]}>\n { props.viewMode === 'month' && !props.hideDayHeader && (\n <div\n class={\n [\n 'v-calendar-weekly__head',\n `days__${weekDays.value.length}`,\n ...(!props.hideWeekNumber ? ['v-calendar-weekly__head-weeknumbers'] : []),\n ]\n }\n key=\"calendarWeeklyHead\"\n >\n { !props.hideWeekNumber ? <div key=\"weekNumber0\" class=\"v-calendar-weekly__head-weeknumber\"></div> : '' }\n {\n weekDays.value.map(weekday => (\n <div class={ `v-calendar-weekly__head-weekday${!props.hideWeekNumber ? '-with-weeknumber' : ''}` }>\n { dayNames[weekday] }\n </div>\n ))\n }\n </div>\n )}\n\n { props.viewMode === 'month' && (\n <div\n key=\"VCalendarMonth\"\n class={\n [\n 'v-calendar-month__days',\n `days${!props.hideWeekNumber ? '-with-weeknumbers' : ''}__${weekDays.value.length}`,\n ...(!props.hideWeekNumber ? ['v-calendar-month__weeknumbers'] : []),\n ]\n }\n >\n { chunkArray(daysInMonth.value, weekDays.value.length)\n .map((week, wi) => (\n [\n !props.hideWeekNumber ? (\n <div\n class=\"v-calendar-month__weeknumber\"\n { ...getPrefixedEventHandlers(attrs, ':weekNumber', () => ({ weekNumber: weekNumbers.value[wi], week })) }\n >{ weekNumbers.value[wi] }</div>\n ) : '',\n week.map(day => (\n <VCalendarMonthDay\n key={ day.date.getTime() }\n { ...calendarDayProps }\n day={ day }\n title={ adapter.format(day.date, 'dayOfMonth') }\n events={ props.events?.filter(e => adapter.isSameDay(day.date, e.start) || adapter.isSameDay(day.date, e.end)) }\n { ...attrs }\n >\n {{\n ...pick(slots, ['day-body', 'day-event', 'day-title']),\n }}\n </VCalendarMonthDay>\n )),\n ]\n ))\n }\n </div>\n )}\n { props.viewMode === 'week' && (\n daysInWeek.value.map((day, i) =>\n slots['day-interval'] ? slots['day-interval']?.({\n ...calendarDayProps,\n day,\n dayIndex: i,\n events: props.events?.filter(e => adapter.isSameDay(e.start, day.date) || adapter.isSameDay(e.end, day.date)),\n }) : (\n <VCalendarDay\n { ...calendarDayProps }\n day={ day }\n dayIndex={ i }\n events={ props.events?.filter(e => adapter.isSameDay(e.start, day.date) || adapter.isSameDay(e.end, day.date)) }\n { ...attrs }\n >\n {{ ...pick(slots, ['interval', 'intervalBody', 'intervalEvent', 'intervalTitle']) }}\n </VCalendarDay>\n )\n ))\n }\n\n { props.viewMode === 'day' && (\n slots['day-interval'] ? slots['day-interval']({\n day: genDays([displayValue.value as Date], adapter.date() as Date)[0],\n dayIndex: 0,\n events: props.events?.filter(e =>\n adapter.isSameDay(e.start, genDays([displayValue.value as Date], adapter.date() as Date)[0].date) ||\n adapter.isSameDay(e.end, genDays([displayValue.value as Date], adapter.date() as Date)[0].date)\n ),\n }) : (\n <VCalendarDay\n { ...calendarDayProps }\n day={ genDays([model.value[0] as Date], adapter.date() as Date)[0] }\n dayIndex={ 0 }\n events={\n props.events?.filter(e =>\n adapter.isSameDay(e.start, genDays([model.value[0] as Date], adapter.date() as Date)[0].date) ||\n adapter.isSameDay(e.end, genDays([model.value[0] as Date], adapter.date() as Date)[0].date)\n )\n }\n { ...attrs }\n ></VCalendarDay>\n )\n )}\n </div>\n </div>\n )\n })\n\n return { daysInMonth, daysInWeek, genDays }\n },\n})\n\nexport type VCalendar = InstanceType<typeof VCalendar>\n"],"mappings":";AAAA;AACA;;AAEA;AAAA,SACSA,qBAAqB,EAAEC,YAAY;AAAA,SACnCC,wBAAwB,EAAEC,eAAe;AAAA,SACzCC,iBAAiB,kCAE1B;AAAA,SACSC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D,WAAA,CAEOV,gBAAgB;QAAA,OACfjB,OAAO,CAAC,CAACC,KAAK,CAACQ,KAAK,CAAC,CAAC,CAAC,CAAS,EAAEZ,OAAO,CAACiB,IAAI,CAAC,CAAS,CAAC,CAAC,CAAC,CAAC;QAAA,YACvD,CAAC;QAAA,UAEV3B,KAAK,CAACkD,MAAM,EAAEC,MAAM,CAACC,CAAC,IACpB1C,OAAO,CAAC2C,SAAS,CAACD,CAAC,CAACE,KAAK,EAAEzC,OAAO,CAAC,CAACC,KAAK,CAACQ,KAAK,CAAC,CAAC,CAAC,CAAS,EAAEZ,OAAO,CAACiB,IAAI,CAAC,CAAS,CAAC,CAAC,CAAC,CAAC,CAACA,IAAI,CAAC,IAC7FjB,OAAO,CAAC2C,SAAS,CAACD,CAAC,CAACG,GAAG,EAAE1C,OAAO,CAAC,CAACC,KAAK,CAACQ,KAAK,CAAC,CAAC,CAAC,CAAS,EAAEZ,OAAO,CAACiB,IAAI,CAAC,CAAS,CAAC,CAAC,CAAC,CAAC,CAACA,IAAI,CAC5F;MAAC,GAEEpB,KAAK,QAEb,CACF;IAIT,CAAC,CAAC;IAEF,OAAO;MAAEI,WAAW;MAAEC,UAAU;MAAEC;IAAQ,CAAC;EAC7C;AACF,CAAC,CAAC","ignoreList":[]}
|
1
|
+
{"version":3,"file":"VCalendar.js","names":["makeVCalendarDayProps","VCalendarDay","makeVCalendarHeaderProps","VCalendarHeader","VCalendarMonthDay","makeCalendarProps","useCalendar","useDate","computed","nextTick","chunkArray","genericComponent","getPrefixedEventHandlers","pick","propsFactory","useRender","makeVCalendarProps","hideHeader","Boolean","hideWeekNumber","VCalendar","name","props","emits","next","prev","today","setup","_ref","attrs","emit","slots","adapter","daysInMonth","daysInWeek","genDays","model","displayValue","weekNumbers","weekDays","dayNames","getWeekdays","onClickNext","viewMode","value","addMonths","addDays","onClickPrev","onClickToday","date","title","format","calendarDayProps","filterProps","calendarHeaderProps","_createElementVNode","_normalizeClass","header","clickNext","clickPrev","clickToday","_createVNode","_mergeProps","length","hideDayHeader","map","weekday","week","wi","weekNumber","day","getTime","events","filter","e","isSameDay","start","end","i","dayIndex"],"sources":["../../../src/labs/VCalendar/VCalendar.tsx"],"sourcesContent":["// Styles\nimport './VCalendar.sass'\n\n// Components\nimport { makeVCalendarDayProps, VCalendarDay } from './VCalendarDay'\nimport { makeVCalendarHeaderProps, VCalendarHeader } from './VCalendarHeader'\nimport { VCalendarMonthDay } from './VCalendarMonthDay'\n\n// Composables\nimport { makeCalendarProps, useCalendar } from '@/composables/calendar'\nimport { useDate } from '@/composables/date/date'\n\n// Utilities\nimport { computed, nextTick } from 'vue'\nimport { chunkArray, genericComponent, getPrefixedEventHandlers, pick, propsFactory, useRender } from '@/util'\n\n// Types\nimport type { VCalendarDaySlots } from './VCalendarDay'\nimport type { CalendarDay } from '@/composables/calendar'\n\nexport const makeVCalendarProps = propsFactory({\n hideHeader: Boolean,\n hideWeekNumber: Boolean,\n\n ...makeCalendarProps(),\n ...makeVCalendarDayProps(),\n ...makeVCalendarHeaderProps(),\n}, 'VCalendar')\n\nexport type VCalendarSlots = VCalendarDaySlots & {\n 'day-body': { day?: CalendarDay, events?: Array<any> }\n 'day-title': { title?: number | string }\n 'day-event': { day?: CalendarDay, allDay: boolean, event?: Record<string, unknown> }\n header: { title: string, clickNext: Function, clickPrev: Function, clickToday: Function }\n 'day-interval': { day?: CalendarDay, dayIndex: number, events?: Array<any> }\n title: { title?: string }\n}\n\nexport const VCalendar = genericComponent<VCalendarSlots>()({\n name: 'VCalendar',\n\n props: makeVCalendarProps(),\n\n emits: {\n next: null,\n prev: null,\n today: null,\n 'update:modelValue': null,\n },\n\n setup (props, { attrs, emit, slots }) {\n const adapter = useDate()\n\n const { daysInMonth, daysInWeek, genDays, model, displayValue, weekNumbers, weekDays } = useCalendar(props as any)\n\n const dayNames = adapter.getWeekdays()\n\n function onClickNext () {\n if (props.viewMode === 'month') {\n model.value = [adapter.addMonths(displayValue.value, 1)]\n } else if (props.viewMode === 'week') {\n model.value = [adapter.addDays(displayValue.value, 7)]\n } else if (props.viewMode === 'day') {\n model.value = [adapter.addDays(displayValue.value, 1)]\n }\n nextTick(() => {\n emit('next', model.value[0])\n })\n }\n\n function onClickPrev () {\n if (props.viewMode === 'month') {\n model.value = [adapter.addMonths(displayValue.value, -1)]\n } else if (props.viewMode === 'week') {\n model.value = [adapter.addDays(displayValue.value, -7)]\n } else if (props.viewMode === 'day') {\n model.value = [adapter.addDays(displayValue.value, -1)]\n }\n nextTick(() => {\n emit('prev', model.value[0])\n })\n }\n\n function onClickToday () {\n const date = adapter.date()\n model.value = [date]\n nextTick(() => {\n emit('today', model.value[0])\n })\n }\n\n const title = computed(() => {\n return adapter.format(displayValue.value, 'monthAndYear')\n })\n\n useRender(() => {\n const calendarDayProps = VCalendarDay.filterProps(props)\n const calendarHeaderProps = VCalendarHeader.filterProps(props)\n\n return (\n <div class={[\n 'v-calendar',\n {\n 'v-calendar-monthly': props.viewMode === 'month',\n 'v-calendar-weekly': props.viewMode === 'week',\n 'v-calendar-day': props.viewMode === 'day',\n },\n ]}\n >\n <div>\n { !props.hideHeader && (\n slots.header?.({\n title: title.value,\n clickNext: onClickNext,\n clickPrev: onClickPrev,\n clickToday: onClickToday,\n }) ?? (\n <VCalendarHeader\n key=\"calendar-header\"\n { ...calendarHeaderProps }\n title={ title.value }\n onClick:next={ onClickNext }\n onClick:prev={ onClickPrev }\n onClick:toToday={ onClickToday }\n >\n {{ title: slots.title }}\n </VCalendarHeader>\n )\n )}\n </div>\n\n <div class={['v-calendar__container', `days__${weekDays.value.length}`]}>\n { props.viewMode === 'month' && !props.hideDayHeader && (\n <div\n class={\n [\n 'v-calendar-weekly__head',\n `days__${weekDays.value.length}`,\n ...(!props.hideWeekNumber ? ['v-calendar-weekly__head-weeknumbers'] : []),\n ]\n }\n key=\"calendarWeeklyHead\"\n >\n { !props.hideWeekNumber ? <div key=\"weekNumber0\" class=\"v-calendar-weekly__head-weeknumber\"></div> : '' }\n {\n weekDays.value.map(weekday => (\n <div class={ `v-calendar-weekly__head-weekday${!props.hideWeekNumber ? '-with-weeknumber' : ''}` }>\n { dayNames[weekday] }\n </div>\n ))\n }\n </div>\n )}\n\n { props.viewMode === 'month' && (\n <div\n key=\"VCalendarMonth\"\n class={\n [\n 'v-calendar-month__days',\n `days${!props.hideWeekNumber ? '-with-weeknumbers' : ''}__${weekDays.value.length}`,\n ...(!props.hideWeekNumber ? ['v-calendar-month__weeknumbers'] : []),\n ]\n }\n >\n { chunkArray(daysInMonth.value, weekDays.value.length)\n .map((week, wi) => (\n [\n !props.hideWeekNumber ? (\n <div\n class=\"v-calendar-month__weeknumber\"\n { ...getPrefixedEventHandlers(attrs, ':weekNumber', () => ({ weekNumber: weekNumbers.value[wi], week })) }\n >{ weekNumbers.value[wi] }</div>\n ) : '',\n week.map(day => (\n <VCalendarMonthDay\n key={ day.date.getTime() }\n { ...calendarDayProps }\n day={ day }\n title={ adapter.format(day.date, 'dayOfMonth') }\n events={ props.events?.filter(e => adapter.isSameDay(day.date, e.start) || adapter.isSameDay(day.date, e.end)) }\n { ...attrs }\n >\n {{\n ...pick(slots, ['day-body', 'day-event', 'day-title']),\n }}\n </VCalendarMonthDay>\n )),\n ]\n ))\n }\n </div>\n )}\n { props.viewMode === 'week' && (\n daysInWeek.value.map((day, i) =>\n slots['day-interval'] ? slots['day-interval']?.({\n ...calendarDayProps,\n day,\n dayIndex: i,\n events: props.events?.filter(e => adapter.isSameDay(e.start, day.date) || adapter.isSameDay(e.end, day.date)),\n }) : (\n <VCalendarDay\n { ...calendarDayProps }\n day={ day }\n dayIndex={ i }\n events={ props.events?.filter(e => adapter.isSameDay(e.start, day.date) || adapter.isSameDay(e.end, day.date)) }\n { ...attrs }\n >\n {{ ...pick(slots, ['interval', 'intervalBody', 'intervalEvent', 'intervalTitle']) }}\n </VCalendarDay>\n )\n ))\n }\n\n { props.viewMode === 'day' && (\n slots['day-interval'] ? slots['day-interval']({\n day: genDays([displayValue.value as Date], adapter.date() as Date)[0],\n dayIndex: 0,\n events: props.events?.filter(e =>\n adapter.isSameDay(e.start, genDays([displayValue.value as Date], adapter.date() as Date)[0].date) ||\n adapter.isSameDay(e.end, genDays([displayValue.value as Date], adapter.date() as Date)[0].date)\n ),\n }) : (\n <VCalendarDay\n { ...calendarDayProps }\n day={ genDays([model.value[0] as Date], adapter.date() as Date)[0] }\n dayIndex={ 0 }\n events={\n props.events?.filter(e =>\n adapter.isSameDay(e.start, genDays([model.value[0] as Date], adapter.date() as Date)[0].date) ||\n adapter.isSameDay(e.end, genDays([model.value[0] as Date], adapter.date() as Date)[0].date)\n )\n }\n { ...attrs }\n ></VCalendarDay>\n )\n )}\n </div>\n </div>\n )\n })\n\n return { daysInMonth, daysInWeek, genDays }\n },\n})\n\nexport type VCalendar = InstanceType<typeof VCalendar>\n"],"mappings":";AAAA;AACA;;AAEA;AAAA,SACSA,qBAAqB,EAAEC,YAAY;AAAA,SACnCC,wBAAwB,EAAEC,eAAe;AAAA,SACzCC,iBAAiB,kCAE1B;AAAA,SACSC,iBAAiB,EAAEC,WAAW;AAAA,SAC9BC,OAAO,0CAEhB;AACA,SAASC,QAAQ,EAAEC,QAAQ,QAAQ,KAAK;AAAA,SAC/BC,UAAU,EAAEC,gBAAgB,EAAEC,wBAAwB,EAAEC,IAAI,EAAEC,YAAY,EAAEC,SAAS,+BAE9F;AAIA,OAAO,MAAMC,kBAAkB,GAAGF,YAAY,CAAC;EAC7CG,UAAU,EAAEC,OAAO;EACnBC,cAAc,EAAED,OAAO;EAEvB,GAAGb,iBAAiB,CAAC,CAAC;EACtB,GAAGL,qBAAqB,CAAC,CAAC;EAC1B,GAAGE,wBAAwB,CAAC;AAC9B,CAAC,EAAE,WAAW,CAAC;AAWf,OAAO,MAAMkB,SAAS,GAAGT,gBAAgB,CAAiB,CAAC,CAAC;EAC1DU,IAAI,EAAE,WAAW;EAEjBC,KAAK,EAAEN,kBAAkB,CAAC,CAAC;EAE3BO,KAAK,EAAE;I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