@vuetify/nightly 3.8.3-master.2025-04-30 → 3.8.3-master.2025-05-01
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 +17 -3
- package/dist/json/attributes.json +3412 -3408
- package/dist/json/importMap-labs.json +24 -24
- package/dist/json/importMap.json +142 -142
- package/dist/json/tags.json +1 -0
- package/dist/json/web-types.json +6053 -6043
- package/dist/vuetify-labs.cjs +31 -11
- package/dist/vuetify-labs.css +3636 -3640
- package/dist/vuetify-labs.d.ts +74 -54
- package/dist/vuetify-labs.esm.js +31 -11
- package/dist/vuetify-labs.esm.js.map +1 -1
- package/dist/vuetify-labs.js +31 -11
- package/dist/vuetify-labs.min.css +2 -2
- package/dist/vuetify.cjs +4 -4
- package/dist/vuetify.cjs.map +1 -1
- package/dist/vuetify.css +3206 -3210
- package/dist/vuetify.d.ts +52 -52
- package/dist/vuetify.esm.js +4 -4
- package/dist/vuetify.esm.js.map +1 -1
- package/dist/vuetify.js +4 -4
- package/dist/vuetify.js.map +1 -1
- package/dist/vuetify.min.css +2 -2
- package/dist/vuetify.min.js +4 -4
- package/dist/vuetify.min.js.map +1 -1
- package/lib/components/VDataTable/composables/select.js +1 -1
- package/lib/components/VDataTable/composables/select.js.map +1 -1
- package/lib/components/VTable/VTable.css +2 -6
- package/lib/components/VTable/VTable.sass +4 -22
- package/lib/entry-bundler.js +1 -1
- package/lib/framework.d.ts +52 -52
- package/lib/framework.js +1 -1
- package/lib/labs/VDateInput/VDateInput.d.ts +41 -4
- package/lib/labs/VDateInput/VDateInput.js +27 -7
- package/lib/labs/VDateInput/VDateInput.js.map +1 -1
- package/package.json +1 -1
@@ -145,7 +145,7 @@ export function provideSelection(props, _ref9) {
|
|
145
145
|
index = index ?? currentPage.value.findIndex(i => i.value === item.value);
|
146
146
|
if (props.selectStrategy !== 'single' && event?.shiftKey && lastSelectedIndex.value !== null) {
|
147
147
|
const [start, end] = [lastSelectedIndex.value, index].sort((a, b) => a - b);
|
148
|
-
items.push(...currentPage.value.slice(start, end + 1));
|
148
|
+
items.push(...currentPage.value.slice(start, end + 1).filter(item => item.selectable));
|
149
149
|
} else {
|
150
150
|
items.push(item);
|
151
151
|
lastSelectedIndex.value = index;
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"select.js","names":["useProxiedModel","computed","inject","provide","shallowRef","toRef","deepEqual","propsFactory","wrapInArray","singleSelectStrategy","showSelectAll","allSelected","select","_ref","items","value","Set","selectAll","_ref2","selected","pageSelectStrategy","_ref3","currentPage","_ref4","item","add","delete","_ref5","allSelectStrategy","_ref6","allItems","_ref7","_ref8","makeDataTableSelectProps","showSelect","Boolean","selectStrategy","type","String","Object","default","modelValue","Array","valueComparator","Function","VDataTableSelectionSymbol","Symbol","for","provideSelection","props","_ref9","v","map","find","values","allSelectable","filter","selectable","currentPageSelectable","lastSelectedIndex","isSelected","every","has","isSomeSelected","some","newSelected","toggleSelect","index","event","findIndex","i","shiftKey","start","end","sort","a","b","push","slice","someSelected","size","length","data","useSelection","Error"],"sources":["../../../../src/components/VDataTable/composables/select.ts"],"sourcesContent":["// Composables\nimport { useProxiedModel } from '@/composables/proxiedModel'\n\n// Utilities\nimport { computed, inject, provide, shallowRef, toRef } from 'vue'\nimport { deepEqual, propsFactory, wrapInArray } from '@/util'\n\n// Types\nimport type { InjectionKey, PropType, Ref } from 'vue'\nimport type { DataTableItemProps } from './items'\nimport type { EventProp } from '@/util'\n\nexport interface SelectableItem {\n value: any\n selectable: boolean\n}\n\nexport interface DataTableSelectStrategy {\n showSelectAll: boolean\n allSelected: (data: {\n allItems: SelectableItem[]\n currentPage: SelectableItem[]\n }) => SelectableItem[]\n select: (data: {\n items: SelectableItem[]\n value: boolean\n selected: Set<unknown>\n }) => Set<unknown>\n selectAll: (data: {\n value: boolean\n allItems: SelectableItem[]\n currentPage: SelectableItem[]\n selected: Set<unknown>\n }) => Set<unknown>\n}\n\ntype SelectionProps = Pick<DataTableItemProps, 'itemValue'> & {\n modelValue: readonly any[]\n selectStrategy: 'single' | 'page' | 'all'\n valueComparator: typeof deepEqual\n 'onUpdate:modelValue': EventProp<[any[]]> | undefined\n}\n\nconst singleSelectStrategy: DataTableSelectStrategy = {\n showSelectAll: false,\n allSelected: () => [],\n select: ({ items, value }) => {\n return new Set(value ? [items[0]?.value] : [])\n },\n selectAll: ({ selected }) => selected,\n}\n\nconst pageSelectStrategy: DataTableSelectStrategy = {\n showSelectAll: true,\n allSelected: ({ currentPage }) => currentPage,\n select: ({ items, value, selected }) => {\n for (const item of items) {\n if (value) selected.add(item.value)\n else selected.delete(item.value)\n }\n\n return selected\n },\n selectAll: ({ value, currentPage, selected }) => pageSelectStrategy.select({ items: currentPage, value, selected }),\n}\n\nconst allSelectStrategy: DataTableSelectStrategy = {\n showSelectAll: true,\n allSelected: ({ allItems }) => allItems,\n select: ({ items, value, selected }) => {\n for (const item of items) {\n if (value) selected.add(item.value)\n else selected.delete(item.value)\n }\n\n return selected\n },\n selectAll: ({ value, allItems, selected }) => allSelectStrategy.select({ items: allItems, value, selected }),\n}\n\nexport const makeDataTableSelectProps = propsFactory({\n showSelect: Boolean,\n selectStrategy: {\n type: [String, Object] as PropType<'single' | 'page' | 'all'>,\n default: 'page',\n },\n modelValue: {\n type: Array as PropType<readonly any[]>,\n default: () => ([]),\n },\n valueComparator: {\n type: Function as PropType<typeof deepEqual>,\n default: deepEqual,\n },\n}, 'DataTable-select')\n\nexport const VDataTableSelectionSymbol: InjectionKey<ReturnType<typeof provideSelection>> = Symbol.for('vuetify:data-table-selection')\n\nexport function provideSelection (\n props: SelectionProps,\n { allItems, currentPage }: { allItems: Ref<SelectableItem[]>, currentPage: Ref<SelectableItem[]> }\n) {\n const selected = useProxiedModel(props, 'modelValue', props.modelValue, v => {\n return new Set(wrapInArray(v).map(v => {\n return allItems.value.find(item => props.valueComparator(v, item.value))?.value ?? v\n }))\n }, v => {\n return [...v.values()]\n })\n\n const allSelectable = computed(() => allItems.value.filter(item => item.selectable))\n const currentPageSelectable = computed(() => currentPage.value.filter(item => item.selectable))\n\n const selectStrategy = computed(() => {\n if (typeof props.selectStrategy === 'object') return props.selectStrategy\n\n switch (props.selectStrategy) {\n case 'single': return singleSelectStrategy\n case 'all': return allSelectStrategy\n case 'page':\n default: return pageSelectStrategy\n }\n })\n\n const lastSelectedIndex = shallowRef<number | null>(null)\n\n function isSelected (items: SelectableItem | SelectableItem[]) {\n return wrapInArray(items).every(item => selected.value.has(item.value))\n }\n\n function isSomeSelected (items: SelectableItem | SelectableItem[]) {\n return wrapInArray(items).some(item => selected.value.has(item.value))\n }\n\n function select (items: SelectableItem[], value: boolean) {\n const newSelected = selectStrategy.value.select({\n items,\n value,\n selected: new Set(selected.value),\n })\n\n selected.value = newSelected\n }\n\n function toggleSelect (item: SelectableItem, index?: number, event?: MouseEvent) {\n const items = []\n index = index ?? currentPage.value.findIndex(i => i.value === item.value)\n\n if (props.selectStrategy !== 'single' && event?.shiftKey && lastSelectedIndex.value !== null) {\n const [start, end] = [lastSelectedIndex.value, index].sort((a, b) => a - b)\n\n items.push(...currentPage.value.slice(start, end + 1))\n } else {\n items.push(item)\n lastSelectedIndex.value = index\n }\n\n select(items, !isSelected([item]))\n }\n\n function selectAll (value: boolean) {\n const newSelected = selectStrategy.value.selectAll({\n value,\n allItems: allSelectable.value,\n currentPage: currentPageSelectable.value,\n selected: new Set(selected.value),\n })\n\n selected.value = newSelected\n }\n\n const someSelected = computed(() => selected.value.size > 0)\n const allSelected = computed(() => {\n const items = selectStrategy.value.allSelected({\n allItems: allSelectable.value,\n currentPage: currentPageSelectable.value,\n })\n return !!items.length && isSelected(items)\n })\n const showSelectAll = toRef(() => selectStrategy.value.showSelectAll)\n\n const data = {\n toggleSelect,\n select,\n selectAll,\n isSelected,\n isSomeSelected,\n someSelected,\n allSelected,\n showSelectAll,\n lastSelectedIndex,\n selectStrategy,\n }\n\n provide(VDataTableSelectionSymbol, data)\n\n return data\n}\n\nexport function useSelection () {\n const data = inject(VDataTableSelectionSymbol)\n\n if (!data) throw new Error('Missing selection!')\n\n return data\n}\n"],"mappings":"AAAA;AAAA,SACSA,eAAe,gDAExB;AACA,SAASC,QAAQ,EAAEC,MAAM,EAAEC,OAAO,EAAEC,UAAU,EAAEC,KAAK,QAAQ,KAAK;AAAA,SACzDC,SAAS,EAAEC,YAAY,EAAEC,WAAW,kCAE7C;AAoCA,MAAMC,oBAA6C,GAAG;EACpDC,aAAa,EAAE,KAAK;EACpBC,WAAW,EAAEA,CAAA,KAAM,EAAE;EACrBC,MAAM,EAAEC,IAAA,IAAsB;IAAA,IAArB;MAAEC,KAAK;MAAEC;IAAM,CAAC,GAAAF,IAAA;IACvB,OAAO,IAAIG,GAAG,CAACD,KAAK,GAAG,CAACD,KAAK,CAAC,CAAC,CAAC,EAAEC,KAAK,CAAC,GAAG,EAAE,CAAC;EAChD,CAAC;EACDE,SAAS,EAAEC,KAAA;IAAA,IAAC;MAAEC;IAAS,CAAC,GAAAD,KAAA;IAAA,OAAKC,QAAQ;EAAA;AACvC,CAAC;AAED,MAAMC,kBAA2C,GAAG;EAClDV,aAAa,EAAE,IAAI;EACnBC,WAAW,EAAEU,KAAA;IAAA,IAAC;MAAEC;IAAY,CAAC,GAAAD,KAAA;IAAA,OAAKC,WAAW;EAAA;EAC7CV,MAAM,EAAEW,KAAA,IAAgC;IAAA,IAA/B;MAAET,KAAK;MAAEC,KAAK;MAAEI;IAAS,CAAC,GAAAI,KAAA;IACjC,KAAK,MAAMC,IAAI,IAAIV,KAAK,EAAE;MACxB,IAAIC,KAAK,EAAEI,QAAQ,CAACM,GAAG,CAACD,IAAI,CAACT,KAAK,CAAC,MAC9BI,QAAQ,CAACO,MAAM,CAACF,IAAI,CAACT,KAAK,CAAC;IAClC;IAEA,OAAOI,QAAQ;EACjB,CAAC;EACDF,SAAS,EAAEU,KAAA;IAAA,IAAC;MAAEZ,KAAK;MAAEO,WAAW;MAAEH;IAAS,CAAC,GAAAQ,K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XhB,YAAY;IACZtD,MAAM;IACNK,SAAS;IACT2C,UAAU;IACVG,cAAc;IACdgB,YAAY;IACZpE,WAAW;IACXD,aAAa;IACbiD,iBAAiB;IACjBvB;EACF,CAAC;EAEDjC,OAAO,CAAC0C,yBAAyB,EAAEqC,IAAI,CAAC;EAExC,OAAOA,IAAI;AACb;AAEA,OAAO,SAASC,YAAYA,CAAA,EAAI;EAC9B,MAAMD,IAAI,GAAGhF,MAAM,CAAC2C,yBAAyB,CAAC;EAE9C,IAAI,CAACqC,IAAI,EAAE,MAAM,IAAIE,KAAK,CAAC,oBAAoB,CAAC;EAEhD,OAAOF,IAAI;AACb","ignoreList":[]}
|
1
|
+
{"version":3,"file":"select.js","names":["useProxiedModel","computed","inject","provide","shallowRef","toRef","deepEqual","propsFactory","wrapInArray","singleSelectStrategy","showSelectAll","allSelected","select","_ref","items","value","Set","selectAll","_ref2","selected","pageSelectStrategy","_ref3","currentPage","_ref4","item","add","delete","_ref5","allSelectStrategy","_ref6","allItems","_ref7","_ref8","makeDataTableSelectProps","showSelect","Boolean","selectStrategy","type","String","Object","default","modelValue","Array","valueComparator","Function","VDataTableSelectionSymbol","Symbol","for","provideSelection","props","_ref9","v","map","find","values","allSelectable","filter","selectable","currentPageSelectable","lastSelectedIndex","isSelected","every","has","isSomeSelected","some","newSelected","toggleSelect","index","event","findIndex","i","shiftKey","start","end","sort","a","b","push","slice","someSelected","size","length","data","useSelection","Error"],"sources":["../../../../src/components/VDataTable/composables/select.ts"],"sourcesContent":["// Composables\nimport { useProxiedModel } from '@/composables/proxiedModel'\n\n// Utilities\nimport { computed, inject, provide, shallowRef, toRef } from 'vue'\nimport { deepEqual, propsFactory, wrapInArray } from '@/util'\n\n// Types\nimport type { InjectionKey, PropType, Ref } from 'vue'\nimport type { DataTableItemProps } from './items'\nimport type { EventProp } from '@/util'\n\nexport interface SelectableItem {\n value: any\n selectable: boolean\n}\n\nexport interface DataTableSelectStrategy {\n showSelectAll: boolean\n allSelected: (data: {\n allItems: SelectableItem[]\n currentPage: SelectableItem[]\n }) => SelectableItem[]\n select: (data: {\n items: SelectableItem[]\n value: boolean\n selected: Set<unknown>\n }) => Set<unknown>\n selectAll: (data: {\n value: boolean\n allItems: SelectableItem[]\n currentPage: SelectableItem[]\n selected: Set<unknown>\n }) => Set<unknown>\n}\n\ntype SelectionProps = Pick<DataTableItemProps, 'itemValue'> & {\n modelValue: readonly any[]\n selectStrategy: 'single' | 'page' | 'all'\n valueComparator: typeof deepEqual\n 'onUpdate:modelValue': EventProp<[any[]]> | undefined\n}\n\nconst singleSelectStrategy: DataTableSelectStrategy = {\n showSelectAll: false,\n allSelected: () => [],\n select: ({ items, value }) => {\n return new Set(value ? [items[0]?.value] : [])\n },\n selectAll: ({ selected }) => selected,\n}\n\nconst pageSelectStrategy: DataTableSelectStrategy = {\n showSelectAll: true,\n allSelected: ({ currentPage }) => currentPage,\n select: ({ items, value, selected }) => {\n for (const item of items) {\n if (value) selected.add(item.value)\n else selected.delete(item.value)\n }\n\n return selected\n },\n selectAll: ({ value, currentPage, selected }) => pageSelectStrategy.select({ items: currentPage, value, selected }),\n}\n\nconst allSelectStrategy: DataTableSelectStrategy = {\n showSelectAll: true,\n allSelected: ({ allItems }) => allItems,\n select: ({ items, value, selected }) => {\n for (const item of items) {\n if (value) selected.add(item.value)\n else selected.delete(item.value)\n }\n\n return selected\n },\n selectAll: ({ value, allItems, selected }) => allSelectStrategy.select({ items: allItems, value, selected }),\n}\n\nexport const makeDataTableSelectProps = propsFactory({\n showSelect: Boolean,\n selectStrategy: {\n type: [String, Object] as PropType<'single' | 'page' | 'all'>,\n default: 'page',\n },\n modelValue: {\n type: Array as PropType<readonly any[]>,\n default: () => ([]),\n },\n valueComparator: {\n type: Function as PropType<typeof deepEqual>,\n default: deepEqual,\n },\n}, 'DataTable-select')\n\nexport const VDataTableSelectionSymbol: InjectionKey<ReturnType<typeof provideSelection>> = Symbol.for('vuetify:data-table-selection')\n\nexport function provideSelection (\n props: SelectionProps,\n { allItems, currentPage }: { allItems: Ref<SelectableItem[]>, currentPage: Ref<SelectableItem[]> }\n) {\n const selected = useProxiedModel(props, 'modelValue', props.modelValue, v => {\n return new Set(wrapInArray(v).map(v => {\n return allItems.value.find(item => props.valueComparator(v, item.value))?.value ?? v\n }))\n }, v => {\n return [...v.values()]\n })\n\n const allSelectable = computed(() => allItems.value.filter(item => item.selectable))\n const currentPageSelectable = computed(() => currentPage.value.filter(item => item.selectable))\n\n const selectStrategy = computed(() => {\n if (typeof props.selectStrategy === 'object') return props.selectStrategy\n\n switch (props.selectStrategy) {\n case 'single': return singleSelectStrategy\n case 'all': return allSelectStrategy\n case 'page':\n default: return pageSelectStrategy\n }\n })\n\n const lastSelectedIndex = shallowRef<number | null>(null)\n\n function isSelected (items: SelectableItem | SelectableItem[]) {\n return wrapInArray(items).every(item => selected.value.has(item.value))\n }\n\n function isSomeSelected (items: SelectableItem | SelectableItem[]) {\n return wrapInArray(items).some(item => selected.value.has(item.value))\n }\n\n function select (items: SelectableItem[], value: boolean) {\n const newSelected = selectStrategy.value.select({\n items,\n value,\n selected: new Set(selected.value),\n })\n\n selected.value = newSelected\n }\n\n function toggleSelect (item: SelectableItem, index?: number, event?: MouseEvent) {\n const items = []\n index = index ?? currentPage.value.findIndex(i => i.value === item.value)\n\n if (props.selectStrategy !== 'single' && event?.shiftKey && lastSelectedIndex.value !== null) {\n const [start, end] = [lastSelectedIndex.value, index].sort((a, b) => a - b)\n\n items.push(...currentPage.value.slice(start, end + 1).filter(item => item.selectable))\n } else {\n items.push(item)\n lastSelectedIndex.value = index\n }\n\n select(items, !isSelected([item]))\n }\n\n function selectAll (value: boolean) {\n const newSelected = selectStrategy.value.selectAll({\n value,\n allItems: allSelectable.value,\n currentPage: currentPageSelectable.value,\n selected: new Set(selected.value),\n })\n\n selected.value = newSelected\n }\n\n const someSelected = computed(() => selected.value.size > 0)\n const allSelected = computed(() => {\n const items = selectStrategy.value.allSelected({\n allItems: allSelectable.value,\n currentPage: currentPageSelectable.value,\n })\n return !!items.length && isSelected(items)\n })\n const showSelectAll = toRef(() => selectStrategy.value.showSelectAll)\n\n const data = {\n toggleSelect,\n select,\n selectAll,\n isSelected,\n isSomeSelected,\n someSelected,\n allSelected,\n showSelectAll,\n lastSelectedIndex,\n selectStrategy,\n }\n\n provide(VDataTableSelectionSymbol, data)\n\n return data\n}\n\nexport function useSelection () {\n const data = inject(VDataTableSelectionSymbol)\n\n if (!data) throw new Error('Missing selection!')\n\n return data\n}\n"],"mappings":"AAAA;AAAA,SACSA,eAAe,gDAExB;AACA,SAASC,QAAQ,EAAEC,MAAM,EAAEC,OAAO,EAAEC,UAAU,EAAEC,KAAK,QAAQ,KAAK;AAAA,SACzDC,SAAS,EAAEC,YAAY,EAAEC,WAAW,kCAE7C;AAoCA,MAAMC,oBAA6C,GAAG;EACpDC,aAAa,EAAE,KAAK;EACpBC,WAAW,EAAEA,CAAA,KAAM,EAAE;EACrBC,MAAM,EAAEC,IAAA,IAAsB;IAAA,IAArB;MAAEC,KAAK;MAAEC;IAAM,CAAC,GAAAF,IAAA;IACvB,OAAO,IAAIG,GAAG,CAACD,KAAK,GAAG,CAACD,KAAK,CAAC,CAAC,CAAC,EAAEC,KAAK,CAAC,GAAG,EAAE,CAAC;EAChD,CAAC;EACDE,SAAS,EAAEC,KAAA;IAAA,IAAC;MAAEC;IAAS,CAAC,GAAAD,KAAA;IAAA,OAAKC,QAAQ;EAAA;AACvC,CAAC;AAED,MAAMC,kBAA2C,GAAG;EAClDV,aAAa,EAAE,IAAI;EACnBC,WAAW,EAAEU,KAAA;IAAA,IAAC;MAAEC;IAAY,CAAC,GAAAD,KAAA;IAAA,OAAKC,WAAW;EAAA;EAC7CV,MAAM,EAAEW,KAAA,IAAgC;IAAA,IAA/B;MAAET,KAAK;MAAEC,KAAK;MAAEI;IAAS,CAAC,GAAAI,KAAA;IACjC,KAAK,MAAMC,IAAI,IAAIV,KAAK,EAAE;MACxB,IAAIC,KAAK,EAAEI,QA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,EAAEyB,aAAa,CAACxC,KAAK;MAC7BO,WAAW,EAAEoC,qBAAqB,CAAC3C;IACrC,CAAC,CAAC;IACF,OAAO,CAAC,CAACD,KAAK,CAACmE,MAAM,IAAIrB,UAAU,CAAC9C,KAAK,CAAC;EAC5C,CAAC,CAAC;EACF,MAAMJ,aAAa,GAAGL,KAAK,CAAC,MAAM+B,cAAc,CAACrB,KAAK,CAACL,aAAa,CAAC;EAErE,MAAMwE,IAAI,GAAG;IACXhB,YAAY;IACZtD,MAAM;IACNK,SAAS;IACT2C,UAAU;IACVG,cAAc;IACdgB,YAAY;IACZpE,WAAW;IACXD,aAAa;IACbiD,iBAAiB;IACjBvB;EACF,CAAC;EAEDjC,OAAO,CAAC0C,yBAAyB,EAAEqC,IAAI,CAAC;EAExC,OAAOA,IAAI;AACb;AAEA,OAAO,SAASC,YAAYA,CAAA,EAAI;EAC9B,MAAMD,IAAI,GAAGhF,MAAM,CAAC2C,yBAAyB,CAAC;EAE9C,IAAI,CAACqC,IAAI,EAAE,MAAM,IAAIE,KAAK,CAAC,oBAAoB,CAAC;EAEhD,OAAOF,IAAI;AACb","ignoreList":[]}
|
@@ -104,17 +104,13 @@
|
|
104
104
|
flex: 1 1 auto;
|
105
105
|
}
|
106
106
|
|
107
|
-
.v-table--has-top > .v-table__wrapper
|
107
|
+
.v-table--has-top > .v-table__wrapper {
|
108
108
|
border-top-left-radius: 0;
|
109
|
-
}
|
110
|
-
.v-table--has-top > .v-table__wrapper > table > tbody > tr:first-child:hover > td:last-child {
|
111
109
|
border-top-right-radius: 0;
|
112
110
|
}
|
113
111
|
|
114
|
-
.v-table--has-bottom > .v-table__wrapper
|
112
|
+
.v-table--has-bottom > .v-table__wrapper {
|
115
113
|
border-bottom-left-radius: 0;
|
116
|
-
}
|
117
|
-
.v-table--has-bottom > .v-table__wrapper > table > tbody > tr:last-child:hover > td:last-child {
|
118
114
|
border-bottom-right-radius: 0;
|
119
115
|
}
|
120
116
|
|
@@ -115,31 +115,13 @@
|
|
115
115
|
// Modifiers
|
116
116
|
.v-table--has-top
|
117
117
|
> .v-table__wrapper
|
118
|
-
|
119
|
-
|
120
|
-
> tr
|
121
|
-
&:first-child
|
122
|
-
&:hover
|
123
|
-
> td
|
124
|
-
&:first-child
|
125
|
-
border-top-left-radius: 0
|
126
|
-
|
127
|
-
&:last-child
|
128
|
-
border-top-right-radius: 0
|
118
|
+
border-top-left-radius: 0
|
119
|
+
border-top-right-radius: 0
|
129
120
|
|
130
121
|
.v-table--has-bottom
|
131
122
|
> .v-table__wrapper
|
132
|
-
|
133
|
-
|
134
|
-
> tr
|
135
|
-
&:last-child
|
136
|
-
&:hover
|
137
|
-
> td
|
138
|
-
&:first-child
|
139
|
-
border-bottom-left-radius: 0
|
140
|
-
|
141
|
-
&:last-child
|
142
|
-
border-bottom-right-radius: 0
|
123
|
+
border-bottom-left-radius: 0
|
124
|
+
border-bottom-right-radius: 0
|
143
125
|
|
144
126
|
.v-table--fixed-height
|
145
127
|
> .v-table__wrapper
|
package/lib/entry-bundler.js
CHANGED
@@ -16,7 +16,7 @@ export const createVuetify = function () {
|
|
16
16
|
...options
|
17
17
|
});
|
18
18
|
};
|
19
|
-
export const version = "3.8.3-master.2025-
|
19
|
+
export const version = "3.8.3-master.2025-05-01";
|
20
20
|
createVuetify.version = version;
|
21
21
|
export { blueprints, components, directives };
|
22
22
|
export * from "./composables/index.js";
|
package/lib/framework.d.ts
CHANGED
@@ -2537,42 +2537,39 @@ declare module 'vue' {
|
|
2537
2537
|
$children?: VNodeChild
|
2538
2538
|
}
|
2539
2539
|
export interface GlobalComponents {
|
2540
|
-
VApp: typeof import('vuetify/components')['VApp']
|
2541
|
-
VAppBar: typeof import('vuetify/components')['VAppBar']
|
2542
|
-
VAppBarNavIcon: typeof import('vuetify/components')['VAppBarNavIcon']
|
2543
|
-
VAppBarTitle: typeof import('vuetify/components')['VAppBarTitle']
|
2544
2540
|
VAlert: typeof import('vuetify/components')['VAlert']
|
2545
2541
|
VAlertTitle: typeof import('vuetify/components')['VAlertTitle']
|
2546
2542
|
VAutocomplete: typeof import('vuetify/components')['VAutocomplete']
|
2543
|
+
VAppBar: typeof import('vuetify/components')['VAppBar']
|
2544
|
+
VAppBarNavIcon: typeof import('vuetify/components')['VAppBarNavIcon']
|
2545
|
+
VAppBarTitle: typeof import('vuetify/components')['VAppBarTitle']
|
2547
2546
|
VAvatar: typeof import('vuetify/components')['VAvatar']
|
2548
|
-
VBottomNavigation: typeof import('vuetify/components')['VBottomNavigation']
|
2549
|
-
VBottomSheet: typeof import('vuetify/components')['VBottomSheet']
|
2550
2547
|
VBadge: typeof import('vuetify/components')['VBadge']
|
2548
|
+
VBottomSheet: typeof import('vuetify/components')['VBottomSheet']
|
2551
2549
|
VBanner: typeof import('vuetify/components')['VBanner']
|
2552
2550
|
VBannerActions: typeof import('vuetify/components')['VBannerActions']
|
2553
2551
|
VBannerText: typeof import('vuetify/components')['VBannerText']
|
2552
|
+
VBtnToggle: typeof import('vuetify/components')['VBtnToggle']
|
2553
|
+
VBtn: typeof import('vuetify/components')['VBtn']
|
2554
2554
|
VBreadcrumbs: typeof import('vuetify/components')['VBreadcrumbs']
|
2555
2555
|
VBreadcrumbsItem: typeof import('vuetify/components')['VBreadcrumbsItem']
|
2556
2556
|
VBreadcrumbsDivider: typeof import('vuetify/components')['VBreadcrumbsDivider']
|
2557
|
-
|
2558
|
-
|
2557
|
+
VApp: typeof import('vuetify/components')['VApp']
|
2558
|
+
VBottomNavigation: typeof import('vuetify/components')['VBottomNavigation']
|
2559
|
+
VBtnGroup: typeof import('vuetify/components')['VBtnGroup']
|
2560
|
+
VCarousel: typeof import('vuetify/components')['VCarousel']
|
2561
|
+
VCarouselItem: typeof import('vuetify/components')['VCarouselItem']
|
2559
2562
|
VCard: typeof import('vuetify/components')['VCard']
|
2560
2563
|
VCardActions: typeof import('vuetify/components')['VCardActions']
|
2561
2564
|
VCardItem: typeof import('vuetify/components')['VCardItem']
|
2562
2565
|
VCardSubtitle: typeof import('vuetify/components')['VCardSubtitle']
|
2563
2566
|
VCardText: typeof import('vuetify/components')['VCardText']
|
2564
2567
|
VCardTitle: typeof import('vuetify/components')['VCardTitle']
|
2568
|
+
VChip: typeof import('vuetify/components')['VChip']
|
2565
2569
|
VCheckbox: typeof import('vuetify/components')['VCheckbox']
|
2566
2570
|
VCheckboxBtn: typeof import('vuetify/components')['VCheckboxBtn']
|
2567
|
-
VBtnGroup: typeof import('vuetify/components')['VBtnGroup']
|
2568
|
-
VCarousel: typeof import('vuetify/components')['VCarousel']
|
2569
|
-
VCarouselItem: typeof import('vuetify/components')['VCarouselItem']
|
2570
|
-
VChipGroup: typeof import('vuetify/components')['VChipGroup']
|
2571
|
-
VCounter: typeof import('vuetify/components')['VCounter']
|
2572
|
-
VCode: typeof import('vuetify/components')['VCode']
|
2573
|
-
VCombobox: typeof import('vuetify/components')['VCombobox']
|
2574
2571
|
VColorPicker: typeof import('vuetify/components')['VColorPicker']
|
2575
|
-
|
2572
|
+
VChipGroup: typeof import('vuetify/components')['VChipGroup']
|
2576
2573
|
VDataTable: typeof import('vuetify/components')['VDataTable']
|
2577
2574
|
VDataTableHeaders: typeof import('vuetify/components')['VDataTableHeaders']
|
2578
2575
|
VDataTableFooter: typeof import('vuetify/components')['VDataTableFooter']
|
@@ -2580,35 +2577,37 @@ declare module 'vue' {
|
|
2580
2577
|
VDataTableRow: typeof import('vuetify/components')['VDataTableRow']
|
2581
2578
|
VDataTableVirtual: typeof import('vuetify/components')['VDataTableVirtual']
|
2582
2579
|
VDataTableServer: typeof import('vuetify/components')['VDataTableServer']
|
2580
|
+
VCombobox: typeof import('vuetify/components')['VCombobox']
|
2581
|
+
VCode: typeof import('vuetify/components')['VCode']
|
2582
|
+
VCounter: typeof import('vuetify/components')['VCounter']
|
2583
2583
|
VDatePicker: typeof import('vuetify/components')['VDatePicker']
|
2584
2584
|
VDatePickerControls: typeof import('vuetify/components')['VDatePickerControls']
|
2585
2585
|
VDatePickerHeader: typeof import('vuetify/components')['VDatePickerHeader']
|
2586
2586
|
VDatePickerMonth: typeof import('vuetify/components')['VDatePickerMonth']
|
2587
2587
|
VDatePickerMonths: typeof import('vuetify/components')['VDatePickerMonths']
|
2588
2588
|
VDatePickerYears: typeof import('vuetify/components')['VDatePickerYears']
|
2589
|
-
VDivider: typeof import('vuetify/components')['VDivider']
|
2590
2589
|
VDialog: typeof import('vuetify/components')['VDialog']
|
2591
|
-
|
2590
|
+
VEmptyState: typeof import('vuetify/components')['VEmptyState']
|
2592
2591
|
VExpansionPanels: typeof import('vuetify/components')['VExpansionPanels']
|
2593
2592
|
VExpansionPanel: typeof import('vuetify/components')['VExpansionPanel']
|
2594
2593
|
VExpansionPanelText: typeof import('vuetify/components')['VExpansionPanelText']
|
2595
2594
|
VExpansionPanelTitle: typeof import('vuetify/components')['VExpansionPanelTitle']
|
2596
|
-
|
2597
|
-
VFieldLabel: typeof import('vuetify/components')['VFieldLabel']
|
2595
|
+
VFab: typeof import('vuetify/components')['VFab']
|
2598
2596
|
VFileInput: typeof import('vuetify/components')['VFileInput']
|
2599
2597
|
VFooter: typeof import('vuetify/components')['VFooter']
|
2600
|
-
|
2598
|
+
VDivider: typeof import('vuetify/components')['VDivider']
|
2599
|
+
VField: typeof import('vuetify/components')['VField']
|
2600
|
+
VFieldLabel: typeof import('vuetify/components')['VFieldLabel']
|
2601
2601
|
VIcon: typeof import('vuetify/components')['VIcon']
|
2602
2602
|
VComponentIcon: typeof import('vuetify/components')['VComponentIcon']
|
2603
2603
|
VSvgIcon: typeof import('vuetify/components')['VSvgIcon']
|
2604
2604
|
VLigatureIcon: typeof import('vuetify/components')['VLigatureIcon']
|
2605
2605
|
VClassIcon: typeof import('vuetify/components')['VClassIcon']
|
2606
2606
|
VImg: typeof import('vuetify/components')['VImg']
|
2607
|
-
VInfiniteScroll: typeof import('vuetify/components')['VInfiniteScroll']
|
2608
2607
|
VInput: typeof import('vuetify/components')['VInput']
|
2608
|
+
VInfiniteScroll: typeof import('vuetify/components')['VInfiniteScroll']
|
2609
|
+
VKbd: typeof import('vuetify/components')['VKbd']
|
2609
2610
|
VLabel: typeof import('vuetify/components')['VLabel']
|
2610
|
-
VItemGroup: typeof import('vuetify/components')['VItemGroup']
|
2611
|
-
VItem: typeof import('vuetify/components')['VItem']
|
2612
2611
|
VList: typeof import('vuetify/components')['VList']
|
2613
2612
|
VListGroup: typeof import('vuetify/components')['VListGroup']
|
2614
2613
|
VListImg: typeof import('vuetify/components')['VListImg']
|
@@ -2618,49 +2617,49 @@ declare module 'vue' {
|
|
2618
2617
|
VListItemSubtitle: typeof import('vuetify/components')['VListItemSubtitle']
|
2619
2618
|
VListItemTitle: typeof import('vuetify/components')['VListItemTitle']
|
2620
2619
|
VListSubheader: typeof import('vuetify/components')['VListSubheader']
|
2621
|
-
|
2622
|
-
|
2620
|
+
VItemGroup: typeof import('vuetify/components')['VItemGroup']
|
2621
|
+
VItem: typeof import('vuetify/components')['VItem']
|
2623
2622
|
VMenu: typeof import('vuetify/components')['VMenu']
|
2623
|
+
VMain: typeof import('vuetify/components')['VMain']
|
2624
|
+
VNumberInput: typeof import('vuetify/components')['VNumberInput']
|
2624
2625
|
VMessages: typeof import('vuetify/components')['VMessages']
|
2625
|
-
|
2626
|
+
VOtpInput: typeof import('vuetify/components')['VOtpInput']
|
2626
2627
|
VNavigationDrawer: typeof import('vuetify/components')['VNavigationDrawer']
|
2627
2628
|
VPagination: typeof import('vuetify/components')['VPagination']
|
2628
|
-
|
2629
|
-
VNumberInput: typeof import('vuetify/components')['VNumberInput']
|
2629
|
+
VOverlay: typeof import('vuetify/components')['VOverlay']
|
2630
2630
|
VProgressCircular: typeof import('vuetify/components')['VProgressCircular']
|
2631
|
-
|
2631
|
+
VSelect: typeof import('vuetify/components')['VSelect']
|
2632
2632
|
VRating: typeof import('vuetify/components')['VRating']
|
2633
2633
|
VRadioGroup: typeof import('vuetify/components')['VRadioGroup']
|
2634
|
+
VProgressLinear: typeof import('vuetify/components')['VProgressLinear']
|
2635
|
+
VSlideGroup: typeof import('vuetify/components')['VSlideGroup']
|
2636
|
+
VSlideGroupItem: typeof import('vuetify/components')['VSlideGroupItem']
|
2634
2637
|
VSelectionControl: typeof import('vuetify/components')['VSelectionControl']
|
2635
|
-
|
2638
|
+
VSnackbar: typeof import('vuetify/components')['VSnackbar']
|
2636
2639
|
VSkeletonLoader: typeof import('vuetify/components')['VSkeletonLoader']
|
2637
2640
|
VSelectionControlGroup: typeof import('vuetify/components')['VSelectionControlGroup']
|
2638
|
-
VSheet: typeof import('vuetify/components')['VSheet']
|
2639
2641
|
VSlider: typeof import('vuetify/components')['VSlider']
|
2640
|
-
|
2641
|
-
|
2642
|
-
VSnackbar: typeof import('vuetify/components')['VSnackbar']
|
2642
|
+
VSwitch: typeof import('vuetify/components')['VSwitch']
|
2643
|
+
VSystemBar: typeof import('vuetify/components')['VSystemBar']
|
2643
2644
|
VStepper: typeof import('vuetify/components')['VStepper']
|
2644
2645
|
VStepperActions: typeof import('vuetify/components')['VStepperActions']
|
2645
2646
|
VStepperHeader: typeof import('vuetify/components')['VStepperHeader']
|
2646
2647
|
VStepperItem: typeof import('vuetify/components')['VStepperItem']
|
2647
2648
|
VStepperWindow: typeof import('vuetify/components')['VStepperWindow']
|
2648
2649
|
VStepperWindowItem: typeof import('vuetify/components')['VStepperWindowItem']
|
2649
|
-
VSystemBar: typeof import('vuetify/components')['VSystemBar']
|
2650
|
-
VSwitch: typeof import('vuetify/components')['VSwitch']
|
2651
|
-
VTable: typeof import('vuetify/components')['VTable']
|
2652
2650
|
VTab: typeof import('vuetify/components')['VTab']
|
2653
2651
|
VTabs: typeof import('vuetify/components')['VTabs']
|
2654
2652
|
VTabsWindow: typeof import('vuetify/components')['VTabsWindow']
|
2655
2653
|
VTabsWindowItem: typeof import('vuetify/components')['VTabsWindowItem']
|
2654
|
+
VTable: typeof import('vuetify/components')['VTable']
|
2656
2655
|
VTextarea: typeof import('vuetify/components')['VTextarea']
|
2657
|
-
VTextField: typeof import('vuetify/components')['VTextField']
|
2658
|
-
VTimeline: typeof import('vuetify/components')['VTimeline']
|
2659
|
-
VTimelineItem: typeof import('vuetify/components')['VTimelineItem']
|
2660
|
-
VTooltip: typeof import('vuetify/components')['VTooltip']
|
2661
2656
|
VToolbar: typeof import('vuetify/components')['VToolbar']
|
2662
2657
|
VToolbarTitle: typeof import('vuetify/components')['VToolbarTitle']
|
2663
2658
|
VToolbarItems: typeof import('vuetify/components')['VToolbarItems']
|
2659
|
+
VTooltip: typeof import('vuetify/components')['VTooltip']
|
2660
|
+
VTextField: typeof import('vuetify/components')['VTextField']
|
2661
|
+
VTimeline: typeof import('vuetify/components')['VTimeline']
|
2662
|
+
VTimelineItem: typeof import('vuetify/components')['VTimelineItem']
|
2664
2663
|
VWindow: typeof import('vuetify/components')['VWindow']
|
2665
2664
|
VWindowItem: typeof import('vuetify/components')['VWindowItem']
|
2666
2665
|
VConfirmEdit: typeof import('vuetify/components')['VConfirmEdit']
|
@@ -2674,19 +2673,20 @@ declare module 'vue' {
|
|
2674
2673
|
VHover: typeof import('vuetify/components')['VHover']
|
2675
2674
|
VLayout: typeof import('vuetify/components')['VLayout']
|
2676
2675
|
VLayoutItem: typeof import('vuetify/components')['VLayoutItem']
|
2677
|
-
VLazy: typeof import('vuetify/components')['VLazy']
|
2678
2676
|
VLocaleProvider: typeof import('vuetify/components')['VLocaleProvider']
|
2677
|
+
VLazy: typeof import('vuetify/components')['VLazy']
|
2679
2678
|
VNoSsr: typeof import('vuetify/components')['VNoSsr']
|
2680
2679
|
VParallax: typeof import('vuetify/components')['VParallax']
|
2681
2680
|
VRadio: typeof import('vuetify/components')['VRadio']
|
2682
|
-
VRangeSlider: typeof import('vuetify/components')['VRangeSlider']
|
2683
2681
|
VResponsive: typeof import('vuetify/components')['VResponsive']
|
2682
|
+
VRangeSlider: typeof import('vuetify/components')['VRangeSlider']
|
2684
2683
|
VSnackbarQueue: typeof import('vuetify/components')['VSnackbarQueue']
|
2684
|
+
VSheet: typeof import('vuetify/components')['VSheet']
|
2685
2685
|
VSparkline: typeof import('vuetify/components')['VSparkline']
|
2686
2686
|
VSpeedDial: typeof import('vuetify/components')['VSpeedDial']
|
2687
2687
|
VThemeProvider: typeof import('vuetify/components')['VThemeProvider']
|
2688
|
-
VValidation: typeof import('vuetify/components')['VValidation']
|
2689
2688
|
VVirtualScroll: typeof import('vuetify/components')['VVirtualScroll']
|
2689
|
+
VValidation: typeof import('vuetify/components')['VValidation']
|
2690
2690
|
VFabTransition: typeof import('vuetify/components')['VFabTransition']
|
2691
2691
|
VDialogBottomTransition: typeof import('vuetify/components')['VDialogBottomTransition']
|
2692
2692
|
VDialogTopTransition: typeof import('vuetify/components')['VDialogTopTransition']
|
@@ -2703,27 +2703,27 @@ declare module 'vue' {
|
|
2703
2703
|
VExpandTransition: typeof import('vuetify/components')['VExpandTransition']
|
2704
2704
|
VExpandXTransition: typeof import('vuetify/components')['VExpandXTransition']
|
2705
2705
|
VDialogTransition: typeof import('vuetify/components')['VDialogTransition']
|
2706
|
-
VIconBtn: typeof import('vuetify/labs/components')['VIconBtn']
|
2707
2706
|
VCalendar: typeof import('vuetify/labs/components')['VCalendar']
|
2708
2707
|
VCalendarDay: typeof import('vuetify/labs/components')['VCalendarDay']
|
2709
2708
|
VCalendarHeader: typeof import('vuetify/labs/components')['VCalendarHeader']
|
2710
2709
|
VCalendarInterval: typeof import('vuetify/labs/components')['VCalendarInterval']
|
2711
2710
|
VCalendarIntervalEvent: typeof import('vuetify/labs/components')['VCalendarIntervalEvent']
|
2712
2711
|
VCalendarMonthDay: typeof import('vuetify/labs/components')['VCalendarMonthDay']
|
2713
|
-
VTimePicker: typeof import('vuetify/labs/components')['VTimePicker']
|
2714
|
-
VTimePickerClock: typeof import('vuetify/labs/components')['VTimePickerClock']
|
2715
|
-
VTimePickerControls: typeof import('vuetify/labs/components')['VTimePickerControls']
|
2716
2712
|
VFileUpload: typeof import('vuetify/labs/components')['VFileUpload']
|
2717
2713
|
VFileUploadItem: typeof import('vuetify/labs/components')['VFileUploadItem']
|
2714
|
+
VIconBtn: typeof import('vuetify/labs/components')['VIconBtn']
|
2715
|
+
VPicker: typeof import('vuetify/labs/components')['VPicker']
|
2716
|
+
VPickerTitle: typeof import('vuetify/labs/components')['VPickerTitle']
|
2718
2717
|
VStepperVertical: typeof import('vuetify/labs/components')['VStepperVertical']
|
2719
2718
|
VStepperVerticalItem: typeof import('vuetify/labs/components')['VStepperVerticalItem']
|
2720
2719
|
VStepperVerticalActions: typeof import('vuetify/labs/components')['VStepperVerticalActions']
|
2721
|
-
VPicker: typeof import('vuetify/labs/components')['VPicker']
|
2722
|
-
VPickerTitle: typeof import('vuetify/labs/components')['VPickerTitle']
|
2723
2720
|
VTreeview: typeof import('vuetify/labs/components')['VTreeview']
|
2724
2721
|
VTreeviewItem: typeof import('vuetify/labs/components')['VTreeviewItem']
|
2725
2722
|
VTreeviewGroup: typeof import('vuetify/labs/components')['VTreeviewGroup']
|
2726
|
-
|
2723
|
+
VTimePicker: typeof import('vuetify/labs/components')['VTimePicker']
|
2724
|
+
VTimePickerClock: typeof import('vuetify/labs/components')['VTimePickerClock']
|
2725
|
+
VTimePickerControls: typeof import('vuetify/labs/components')['VTimePickerControls']
|
2727
2726
|
VPullToRefresh: typeof import('vuetify/labs/components')['VPullToRefresh']
|
2727
|
+
VDateInput: typeof import('vuetify/labs/components')['VDateInput']
|
2728
2728
|
}
|
2729
2729
|
}
|
package/lib/framework.js
CHANGED
@@ -116,6 +116,7 @@ export declare const makeVDateInputProps: <Defaults extends {
|
|
116
116
|
mobileBreakpoint?: unknown;
|
117
117
|
displayFormat?: unknown;
|
118
118
|
location?: unknown;
|
119
|
+
updateOn?: unknown;
|
119
120
|
} = {}>(defaults?: Defaults | undefined) => {
|
120
121
|
max: unknown extends Defaults["max"] ? PropType<unknown> : {
|
121
122
|
type: PropType<unknown extends Defaults["max"] ? unknown : unknown>;
|
@@ -743,12 +744,18 @@ export declare const makeVDateInputProps: <Defaults extends {
|
|
743
744
|
type: PropType<unknown extends Defaults["hideActions"] ? boolean : boolean | Defaults["hideActions"]>;
|
744
745
|
default: unknown extends Defaults["hideActions"] ? boolean : boolean | Defaults["hideActions"];
|
745
746
|
};
|
746
|
-
mobile: unknown extends Defaults["mobile"] ? {
|
747
|
+
mobile: unknown extends Defaults["mobile"] ? Omit<{
|
747
748
|
type: PropType<boolean | null>;
|
748
749
|
default: boolean;
|
749
|
-
}
|
750
|
+
}, "type" | "default"> & {
|
751
|
+
type: PropType<boolean | null>;
|
752
|
+
default: NonNullable<boolean | null> | null;
|
753
|
+
} : Omit<Omit<{
|
750
754
|
type: PropType<boolean | null>;
|
751
755
|
default: boolean;
|
756
|
+
}, "type" | "default"> & {
|
757
|
+
type: PropType<boolean | null>;
|
758
|
+
default: NonNullable<boolean | null> | null;
|
752
759
|
}, "type" | "default"> & {
|
753
760
|
type: PropType<unknown extends Defaults["mobile"] ? boolean | null : boolean | Defaults["mobile"] | null>;
|
754
761
|
default: unknown extends Defaults["mobile"] ? boolean | null : NonNullable<boolean | null> | Defaults["mobile"];
|
@@ -771,6 +778,16 @@ export declare const makeVDateInputProps: <Defaults extends {
|
|
771
778
|
type: PropType<unknown extends Defaults["location"] ? import("../../util/index.js").Anchor : import("../../util/index.js").Anchor | Defaults["location"]>;
|
772
779
|
default: unknown extends Defaults["location"] ? import("../../util/index.js").Anchor : NonNullable<import("../../util/index.js").Anchor> | Defaults["location"];
|
773
780
|
};
|
781
|
+
updateOn: unknown extends Defaults["updateOn"] ? {
|
782
|
+
type: PropType<("blur" | "enter")[]>;
|
783
|
+
default: () => string[];
|
784
|
+
} : Omit<{
|
785
|
+
type: PropType<("blur" | "enter")[]>;
|
786
|
+
default: () => string[];
|
787
|
+
}, "type" | "default"> & {
|
788
|
+
type: PropType<unknown extends Defaults["updateOn"] ? ("blur" | "enter")[] : ("blur" | "enter")[] | Defaults["updateOn"]>;
|
789
|
+
default: unknown extends Defaults["updateOn"] ? ("blur" | "enter")[] : ("blur" | "enter")[] | Defaults["updateOn"];
|
790
|
+
};
|
774
791
|
};
|
775
792
|
export declare const VDateInput: {
|
776
793
|
new (...args: any[]): import("vue").CreateComponentPublicInstanceWithMixins<{
|
@@ -826,6 +843,7 @@ export declare const VDateInput: {
|
|
826
843
|
weeksInMonth: "static" | "dynamic";
|
827
844
|
hideWeekdays: boolean;
|
828
845
|
showWeek: boolean;
|
846
|
+
updateOn: ("blur" | "enter")[];
|
829
847
|
} & {
|
830
848
|
name?: string | undefined;
|
831
849
|
max?: unknown;
|
@@ -2939,6 +2957,7 @@ export declare const VDateInput: {
|
|
2939
2957
|
firstDayOfWeek: string | number;
|
2940
2958
|
hideWeekdays: boolean;
|
2941
2959
|
showWeek: boolean;
|
2960
|
+
updateOn: ("blur" | "enter")[];
|
2942
2961
|
}, true, {}, import("vue").SlotsType<Partial<{
|
2943
2962
|
message: (arg: import("../../components/VMessages/VMessages.js").VMessageSlot) => import("vue").VNode[];
|
2944
2963
|
clear: (arg: import("../../components/VField/VField.js").DefaultInputSlot & {
|
@@ -3017,6 +3036,7 @@ export declare const VDateInput: {
|
|
3017
3036
|
weeksInMonth: "static" | "dynamic";
|
3018
3037
|
hideWeekdays: boolean;
|
3019
3038
|
showWeek: boolean;
|
3039
|
+
updateOn: ("blur" | "enter")[];
|
3020
3040
|
} & {
|
3021
3041
|
name?: string | undefined;
|
3022
3042
|
max?: unknown;
|
@@ -5126,6 +5146,7 @@ export declare const VDateInput: {
|
|
5126
5146
|
firstDayOfWeek: string | number;
|
5127
5147
|
hideWeekdays: boolean;
|
5128
5148
|
showWeek: boolean;
|
5149
|
+
updateOn: ("blur" | "enter")[];
|
5129
5150
|
}>;
|
5130
5151
|
__isFragment?: never;
|
5131
5152
|
__isTeleport?: never;
|
@@ -5183,6 +5204,7 @@ export declare const VDateInput: {
|
|
5183
5204
|
weeksInMonth: "static" | "dynamic";
|
5184
5205
|
hideWeekdays: boolean;
|
5185
5206
|
showWeek: boolean;
|
5207
|
+
updateOn: ("blur" | "enter")[];
|
5186
5208
|
} & {
|
5187
5209
|
name?: string | undefined;
|
5188
5210
|
max?: unknown;
|
@@ -7296,6 +7318,7 @@ export declare const VDateInput: {
|
|
7296
7318
|
firstDayOfWeek: string | number;
|
7297
7319
|
hideWeekdays: boolean;
|
7298
7320
|
showWeek: boolean;
|
7321
|
+
updateOn: ("blur" | "enter")[];
|
7299
7322
|
}, {}, string, import("vue").SlotsType<Partial<{
|
7300
7323
|
message: (arg: import("../../components/VMessages/VMessages.js").VMessageSlot) => import("vue").VNode[];
|
7301
7324
|
clear: (arg: import("../../components/VField/VField.js").DefaultInputSlot & {
|
@@ -7527,9 +7550,12 @@ export declare const VDateInput: {
|
|
7527
7550
|
type: PropType<boolean>;
|
7528
7551
|
default: boolean;
|
7529
7552
|
};
|
7530
|
-
mobile: {
|
7553
|
+
mobile: Omit<{
|
7531
7554
|
type: PropType<boolean | null>;
|
7532
7555
|
default: boolean;
|
7556
|
+
}, "type" | "default"> & {
|
7557
|
+
type: PropType<boolean | null>;
|
7558
|
+
default: NonNullable<boolean | null> | null;
|
7533
7559
|
};
|
7534
7560
|
mobileBreakpoint: PropType<number | import("../../composables/display.js").DisplayBreakpoint>;
|
7535
7561
|
displayFormat: (FunctionConstructor | StringConstructor)[];
|
@@ -7537,6 +7563,10 @@ export declare const VDateInput: {
|
|
7537
7563
|
type: PropType<StrategyProps["location"]>;
|
7538
7564
|
default: string;
|
7539
7565
|
};
|
7566
|
+
updateOn: {
|
7567
|
+
type: PropType<("blur" | "enter")[]>;
|
7568
|
+
default: () => string[];
|
7569
|
+
};
|
7540
7570
|
}, import("vue").ExtractPropTypes<{
|
7541
7571
|
max: PropType<unknown>;
|
7542
7572
|
height: (StringConstructor | NumberConstructor)[];
|
@@ -7750,9 +7780,12 @@ export declare const VDateInput: {
|
|
7750
7780
|
type: PropType<boolean>;
|
7751
7781
|
default: boolean;
|
7752
7782
|
};
|
7753
|
-
mobile: {
|
7783
|
+
mobile: Omit<{
|
7754
7784
|
type: PropType<boolean | null>;
|
7755
7785
|
default: boolean;
|
7786
|
+
}, "type" | "default"> & {
|
7787
|
+
type: PropType<boolean | null>;
|
7788
|
+
default: NonNullable<boolean | null> | null;
|
7756
7789
|
};
|
7757
7790
|
mobileBreakpoint: PropType<number | import("../../composables/display.js").DisplayBreakpoint>;
|
7758
7791
|
displayFormat: (FunctionConstructor | StringConstructor)[];
|
@@ -7760,5 +7793,9 @@ export declare const VDateInput: {
|
|
7760
7793
|
type: PropType<StrategyProps["location"]>;
|
7761
7794
|
default: string;
|
7762
7795
|
};
|
7796
|
+
updateOn: {
|
7797
|
+
type: PropType<("blur" | "enter")[]>;
|
7798
|
+
default: () => string[];
|
7799
|
+
};
|
7763
7800
|
}>>;
|
7764
7801
|
export type VDateInput = InstanceType<typeof VDateInput>;
|
@@ -19,7 +19,13 @@ export const makeVDateInputProps = propsFactory({
|
|
19
19
|
type: String,
|
20
20
|
default: 'bottom start'
|
21
21
|
},
|
22
|
-
|
22
|
+
updateOn: {
|
23
|
+
type: Array,
|
24
|
+
default: () => ['blur', 'enter']
|
25
|
+
},
|
26
|
+
...makeDisplayProps({
|
27
|
+
mobile: null
|
28
|
+
}),
|
23
29
|
...makeFocusProps(),
|
24
30
|
...makeVConfirmEditProps({
|
25
31
|
hideActions: true
|
@@ -89,7 +95,10 @@ export const VDateInput = genericComponent()({
|
|
89
95
|
return 'none';
|
90
96
|
});
|
91
97
|
const isInteractive = computed(() => !props.disabled && !props.readonly);
|
92
|
-
const isReadonly = computed(() =>
|
98
|
+
const isReadonly = computed(() => {
|
99
|
+
if (!props.updateOn.length) return true;
|
100
|
+
return !(mobile.value && isEditingInput.value) && props.readonly;
|
101
|
+
});
|
93
102
|
watch(menu, val => {
|
94
103
|
if (val) return;
|
95
104
|
isEditingInput.value = false;
|
@@ -101,8 +110,9 @@ export const VDateInput = genericComponent()({
|
|
101
110
|
menu.value = true;
|
102
111
|
return;
|
103
112
|
}
|
104
|
-
|
105
|
-
|
113
|
+
if (props.updateOn.includes('enter')) {
|
114
|
+
onUserInput(e.target);
|
115
|
+
}
|
106
116
|
}
|
107
117
|
function onClick(e) {
|
108
118
|
e.preventDefault();
|
@@ -126,7 +136,10 @@ export const VDateInput = genericComponent()({
|
|
126
136
|
if (value != null) return;
|
127
137
|
model.value = null;
|
128
138
|
}
|
129
|
-
function onBlur() {
|
139
|
+
function onBlur(e) {
|
140
|
+
if (props.updateOn.includes('blur')) {
|
141
|
+
onUserInput(e.target);
|
142
|
+
}
|
130
143
|
blur();
|
131
144
|
|
132
145
|
// When in mobile mode and editing is done (due to keyboard dismissal), close the menu
|
@@ -135,6 +148,13 @@ export const VDateInput = genericComponent()({
|
|
135
148
|
isEditingInput.value = false;
|
136
149
|
}
|
137
150
|
}
|
151
|
+
function onUserInput(_ref2) {
|
152
|
+
let {
|
153
|
+
value
|
154
|
+
} = _ref2;
|
155
|
+
if (value && !adapter.isValid(value)) return;
|
156
|
+
model.value = !value ? null : value;
|
157
|
+
}
|
138
158
|
useRender(() => {
|
139
159
|
const confirmEditProps = VConfirmEdit.filterProps(props);
|
140
160
|
const datePickerProps = VDatePicker.filterProps(omit(props, ['active', 'location', 'rounded']));
|
@@ -173,14 +193,14 @@ export const VDateInput = genericComponent()({
|
|
173
193
|
"onSave": onSave,
|
174
194
|
"onCancel": onCancel
|
175
195
|
}), {
|
176
|
-
default:
|
196
|
+
default: _ref3 => {
|
177
197
|
let {
|
178
198
|
actions,
|
179
199
|
model: proxyModel,
|
180
200
|
save,
|
181
201
|
cancel,
|
182
202
|
isPristine
|
183
|
-
} =
|
203
|
+
} = _ref3;
|
184
204
|
function onUpdateModel(value) {
|
185
205
|
if (!props.hideActions) {
|
186
206
|
proxyModel.value = value;
|