vuetify 3.7.2 → 3.7.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/json/attributes.json +5843 -5795
- package/dist/json/importMap-labs.json +16 -16
- package/dist/json/importMap.json +150 -150
- package/dist/json/tags.json +14 -1
- package/dist/json/web-types.json +10397 -10309
- package/dist/vuetify-labs.css +2362 -2362
- package/dist/vuetify-labs.d.ts +196 -195
- package/dist/vuetify-labs.esm.js +68 -45
- package/dist/vuetify-labs.esm.js.map +1 -1
- package/dist/vuetify-labs.js +68 -45
- package/dist/vuetify-labs.min.css +2 -2
- package/dist/vuetify.css +2822 -2822
- package/dist/vuetify.d.ts +212 -211
- package/dist/vuetify.esm.js +38 -17
- package/dist/vuetify.esm.js.map +1 -1
- package/dist/vuetify.js +38 -17
- package/dist/vuetify.js.map +1 -1
- package/dist/vuetify.min.css +2 -2
- package/dist/vuetify.min.js +28 -28
- package/dist/vuetify.min.js.map +1 -1
- package/lib/components/VAutocomplete/index.d.mts +22 -22
- package/lib/components/VBottomSheet/VBottomSheet.sass +2 -1
- package/lib/components/VBottomSheet/index.d.mts +4 -4
- package/lib/components/VBtn/VBtn.css +2 -2
- package/lib/components/VBtn/VBtn.sass +7 -8
- package/lib/components/VBtnToggle/VBtnToggle.css +3 -0
- package/lib/components/VBtnToggle/VBtnToggle.sass +3 -0
- package/lib/components/VCarousel/index.d.mts +2 -2
- package/lib/components/VCheckbox/index.d.mts +2 -2
- package/lib/components/VChip/VChip.mjs +2 -1
- package/lib/components/VChip/VChip.mjs.map +1 -1
- package/lib/components/VCode/index.mjs +1 -1
- package/lib/components/VCode/index.mjs.map +1 -1
- package/lib/components/VColorPicker/VColorPicker.mjs +2 -2
- package/lib/components/VColorPicker/VColorPicker.mjs.map +1 -1
- package/lib/components/VCombobox/index.d.mts +22 -22
- package/lib/components/VConfirmEdit/__test__/VConfirmEdit.spec.browser.mjs +87 -0
- package/lib/components/VConfirmEdit/__test__/VConfirmEdit.spec.browser.mjs.map +1 -0
- package/lib/components/VDataTable/VDataTableFooter.mjs.map +1 -1
- package/lib/components/VDataTable/composables/paginate.mjs +4 -2
- package/lib/components/VDataTable/composables/paginate.mjs.map +1 -1
- package/lib/components/VDataTable/index.d.mts +7 -6
- package/lib/components/VDatePicker/index.d.mts +2 -2
- package/lib/components/VDialog/VDialog.css +3 -7
- package/lib/components/VDialog/VDialog.mjs +8 -1
- package/lib/components/VDialog/VDialog.mjs.map +1 -1
- package/lib/components/VDialog/VDialog.sass +6 -7
- package/lib/components/VDialog/index.d.mts +22 -22
- package/lib/components/VField/_variables.scss +2 -1
- package/lib/components/VFileInput/__tests__/text.txt +1 -0
- package/lib/components/VFileInput/index.d.mts +3 -3
- package/lib/components/VInput/index.d.mts +2 -2
- package/lib/components/VKbd/index.mjs +1 -1
- package/lib/components/VKbd/index.mjs.map +1 -1
- package/lib/components/VList/VListItem.css +8 -7
- package/lib/components/VList/VListItem.mjs +1 -0
- package/lib/components/VList/VListItem.mjs.map +1 -1
- package/lib/components/VList/VListItem.sass +16 -10
- package/lib/components/VList/_variables.scss +0 -11
- package/lib/components/VMenu/VMenu.mjs +15 -6
- package/lib/components/VMenu/VMenu.mjs.map +1 -1
- package/lib/components/VMenu/index.d.mts +20 -20
- package/lib/components/VMessages/index.d.mts +8 -8
- package/lib/components/VNavigationDrawer/index.d.mts +7 -7
- package/lib/components/VOverflowBtn/VOverflowBtn.sass +6 -5
- package/lib/components/VOverlay/index.d.mts +4 -4
- package/lib/components/VProgressLinear/_variables.scss +2 -1
- package/lib/components/VRadioGroup/index.d.mts +2 -2
- package/lib/components/VSelect/index.d.mts +22 -22
- package/lib/components/VSnackbar/index.d.mts +31 -31
- package/lib/components/VSpeedDial/index.d.mts +2 -2
- package/lib/components/VSwitch/index.d.mts +2 -2
- package/lib/components/VTable/_mixins.scss +2 -2
- package/lib/components/VTabs/VTabs.sass +1 -1
- package/lib/components/VTextField/index.d.mts +3 -3
- package/lib/components/VTextarea/index.d.mts +3 -3
- package/lib/components/VTooltip/index.d.mts +24 -24
- package/lib/components/VWindow/index.d.mts +2 -2
- package/lib/components/index.d.mts +158 -157
- package/lib/composables/directiveComponent.mjs +4 -3
- package/lib/composables/directiveComponent.mjs.map +1 -1
- package/lib/composables/nested/nested.mjs +2 -2
- package/lib/composables/nested/nested.mjs.map +1 -1
- package/lib/directives/ripple/index.mjs.map +1 -1
- package/lib/entry-bundler.mjs +1 -1
- package/lib/framework.mjs +1 -1
- package/lib/index.d.mts +53 -53
- package/lib/labs/VNumberInput/index.d.mts +9 -9
- package/lib/labs/VSnackbarQueue/index.d.mts +52 -52
- package/lib/labs/VTreeview/VTreeview.mjs +2 -1
- package/lib/labs/VTreeview/VTreeview.mjs.map +1 -1
- package/lib/labs/VTreeview/VTreeviewChildren.mjs +29 -28
- package/lib/labs/VTreeview/VTreeviewChildren.mjs.map +1 -1
- package/lib/labs/VTreeview/index.d.mts +7 -7
- package/lib/labs/components.d.mts +68 -68
- package/lib/locale/el.mjs +0 -0
- package/lib/locale/index.mjs +0 -0
- package/lib/styles/settings/_colors.scss +257 -256
- package/lib/styles/utilities/_display.sass +2 -1
- package/lib/styles/utilities/_elevation.scss +2 -1
- package/lib/styles/utilities/_screenreaders.sass +2 -1
- package/package.json +23 -16
- package/lib/components/VConfirmEdit/__test__/VConfirmEdit.spec.cy.mjs +0 -74
- package/lib/components/VConfirmEdit/__test__/VConfirmEdit.spec.cy.mjs.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"VColorPicker.mjs","names":["VColorPickerCanvas","VColorPickerEdit","VColorPickerPreview","VColorPickerSwatches","makeVSheetProps","VSheet","provideDefaults","useRtl","useProxiedModel","computed","onMounted","ref","watch","extractColor","modes","nullColor","consoleWarn","defineComponent","HSVtoCSS","omit","parseColor","propsFactory","RGBtoHSV","useRender","makeVColorPickerProps","canvasHeight","type","String","Number","default","disabled","Boolean","dotSize","hideCanvas","hideSliders","hideInputs","mode","validator","v","Object","keys","includes","Array","isArray","every","m","showSwatches","swatches","swatchesMaxHeight","modelValue","width","VColorPicker","name","props","emits","color","setup","hue","model","undefined","c","err","currentColor","value","h","rtlClasses","externalChange","immediate","updateColor","hsva","VSlider","trackColor","trackFillColor","sheetProps","filterProps","_createVNode","_mergeProps","rounded","elevation","theme","class","a","style","endsWith"],"sources":["../../../src/components/VColorPicker/VColorPicker.tsx"],"sourcesContent":["// Styles\nimport './VColorPicker.sass'\n\n// Components\nimport { VColorPickerCanvas } from './VColorPickerCanvas'\nimport { VColorPickerEdit } from './VColorPickerEdit'\nimport { VColorPickerPreview } from './VColorPickerPreview'\nimport { VColorPickerSwatches } from './VColorPickerSwatches'\nimport { makeVSheetProps, VSheet } from '@/components/VSheet/VSheet'\n\n// Composables\nimport { provideDefaults } from '@/composables/defaults'\nimport { useRtl } from '@/composables/locale'\nimport { useProxiedModel } from '@/composables/proxiedModel'\n\n// Utilities\nimport { computed, onMounted, ref, watch } from 'vue'\nimport { extractColor, modes, nullColor } from './util'\nimport { consoleWarn, defineComponent, HSVtoCSS, omit, parseColor, propsFactory, RGBtoHSV, useRender } from '@/util'\n\n// Types\nimport type { DeepReadonly, PropType } from 'vue'\nimport type { Color, HSV } from '@/util'\n\nexport const makeVColorPickerProps = propsFactory({\n canvasHeight: {\n type: [String, Number],\n default: 150,\n },\n disabled: Boolean,\n dotSize: {\n type: [Number, String],\n default: 10,\n },\n hideCanvas: Boolean,\n hideSliders: Boolean,\n hideInputs: Boolean,\n mode: {\n type: String as PropType<keyof typeof modes>,\n default: 'rgba',\n validator: (v: string) => Object.keys(modes).includes(v),\n },\n modes: {\n type: Array as PropType<readonly (keyof typeof modes)[]>,\n default: () => Object.keys(modes),\n validator: (v: any) => Array.isArray(v) && v.every(m => Object.keys(modes).includes(m)),\n },\n showSwatches: Boolean,\n swatches: Array as PropType<DeepReadonly<Color[][]>>,\n swatchesMaxHeight: {\n type: [Number, String],\n default: 150,\n },\n modelValue: {\n type: [Object, String] as PropType<Record<string, unknown> | string | undefined | null>,\n },\n\n ...omit(makeVSheetProps({ width: 300 }), [\n 'height',\n 'location',\n 'minHeight',\n 'maxHeight',\n 'minWidth',\n 'maxWidth',\n ]),\n}, 'VColorPicker')\n\nexport const VColorPicker = defineComponent({\n name: 'VColorPicker',\n\n props: makeVColorPickerProps(),\n\n emits: {\n 'update:modelValue': (color: any) => true,\n 'update:mode': (mode: keyof typeof modes) => true,\n },\n\n setup (props) {\n const mode = useProxiedModel(props, 'mode')\n const hue = ref<number | null>(null)\n const model = useProxiedModel(\n props,\n 'modelValue',\n undefined,\n v => {\n if (v == null || v === '') return null\n\n let c: HSV\n try {\n c = RGBtoHSV(parseColor(v as any))\n } catch (err) {\n consoleWarn(err as any)\n return null\n }\n\n return c\n },\n v => {\n if (!v) return null\n\n return extractColor(v, props.modelValue)\n }\n )\n const currentColor = computed(() => {\n return model.value\n ? { ...model.value, h: hue.value ?? model.value.h }\n : null\n })\n const { rtlClasses } = useRtl()\n\n let externalChange = true\n watch(model, v => {\n if (!externalChange) {\n // prevent hue shift from rgb conversion inaccuracy\n externalChange = true\n return\n }\n if (!v) return\n hue.value = v.h\n }, { immediate: true })\n\n const updateColor = (hsva: HSV) => {\n externalChange = false\n hue.value = hsva.h\n model.value = hsva\n }\n\n onMounted(() => {\n if (!props.modes.includes(mode.value)) mode.value = props.modes[0]\n })\n\n provideDefaults({\n VSlider: {\n color: undefined,\n trackColor: undefined,\n trackFillColor: undefined,\n },\n })\n\n useRender(() => {\n const sheetProps = VSheet.filterProps(props)\n\n return (\n <VSheet\n rounded={ props.rounded }\n elevation={ props.elevation }\n theme={ props.theme }\n class={[\n 'v-color-picker',\n rtlClasses.value,\n props.class,\n ]}\n style={[\n {\n '--v-color-picker-color-hsv': HSVtoCSS({ ...(currentColor.value ?? nullColor), a: 1 }),\n },\n props.style,\n ]}\n { ...sheetProps }\n maxWidth={ props.width }\n >\n { !props.hideCanvas && (\n <VColorPickerCanvas\n key=\"canvas\"\n color={ currentColor.value }\n onUpdate:color={ updateColor }\n disabled={ props.disabled }\n dotSize={ props.dotSize }\n width={ props.width }\n height={ props.canvasHeight }\n />\n )}\n\n { (!props.hideSliders || !props.hideInputs) && (\n <div key=\"controls\" class=\"v-color-picker__controls\">\n { !props.hideSliders && (\n <VColorPickerPreview\n key=\"preview\"\n color={ currentColor.value }\n onUpdate:color={ updateColor }\n hideAlpha={ !mode.value.endsWith('a') }\n disabled={ props.disabled }\n />\n )}\n\n { !props.hideInputs && (\n <VColorPickerEdit\n key=\"edit\"\n modes={ props.modes }\n mode={ mode.value }\n onUpdate:mode={ m => mode.value = m }\n color={ currentColor.value }\n onUpdate:color={ updateColor }\n disabled={ props.disabled }\n />\n )}\n </div>\n )}\n\n { props.showSwatches && (\n <VColorPickerSwatches\n key=\"swatches\"\n color={ currentColor.value }\n onUpdate:color={ updateColor }\n maxHeight={ props.swatchesMaxHeight }\n swatches={ props.swatches }\n disabled={ props.disabled }\n />\n )}\n </VSheet>\n )\n })\n\n return {}\n },\n})\n\nexport type VColorPicker = InstanceType<typeof VColorPicker>\n"],"mappings":";AAAA;AACA;;AAEA;AAAA,SACSA,kBAAkB;AAAA,SAClBC,gBAAgB;AAAA,SAChBC,mBAAmB;AAAA,SACnBC,oBAAoB;AAAA,SACpBC,eAAe,EAAEC,MAAM,gCAEhC;AAAA,SACSC,eAAe;AAAA,SACfC,MAAM;AAAA,SACNC,eAAe,8CAExB;AACA,SAASC,QAAQ,EAAEC,SAAS,EAAEC,GAAG,EAAEC,KAAK,QAAQ,KAAK;AAAA,SAC5CC,YAAY,EAAEC,KAAK,EAAEC,SAAS;AAAA,SAC9BC,WAAW,EAAEC,eAAe,EAAEC,QAAQ,EAAEC,IAAI,EAAEC,UAAU,EAAEC,YAAY,EAAEC,QAAQ,EAAEC,SAAS,gCAEpG;AAIA,OAAO,MAAMC,qBAAqB,GAAGH,YAAY,CAAC;EAChDI,YAAY,EAAE;IACZC,IAAI,EAAE,CAACC,MAAM,E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AAC,CAAC","ignoreList":[]}
|
|
1
|
+
{"version":3,"file":"VColorPicker.mjs","names":["VColorPickerCanvas","VColorPickerEdit","VColorPickerPreview","VColorPickerSwatches","makeVSheetProps","VSheet","provideDefaults","useRtl","useProxiedModel","computed","onBeforeMount","ref","watch","extractColor","modes","nullColor","consoleWarn","defineComponent","HSVtoCSS","omit","parseColor","propsFactory","RGBtoHSV","useRender","makeVColorPickerProps","canvasHeight","type","String","Number","default","disabled","Boolean","dotSize","hideCanvas","hideSliders","hideInputs","mode","validator","v","Object","keys","includes","Array","isArray","every","m","showSwatches","swatches","swatchesMaxHeight","modelValue","width","VColorPicker","name","props","emits","color","setup","hue","model","undefined","c","err","currentColor","value","h","rtlClasses","externalChange","immediate","updateColor","hsva","VSlider","trackColor","trackFillColor","sheetProps","filterProps","_createVNode","_mergeProps","rounded","elevation","theme","class","a","style","endsWith"],"sources":["../../../src/components/VColorPicker/VColorPicker.tsx"],"sourcesContent":["// Styles\nimport './VColorPicker.sass'\n\n// Components\nimport { VColorPickerCanvas } from './VColorPickerCanvas'\nimport { VColorPickerEdit } from './VColorPickerEdit'\nimport { VColorPickerPreview } from './VColorPickerPreview'\nimport { VColorPickerSwatches } from './VColorPickerSwatches'\nimport { makeVSheetProps, VSheet } from '@/components/VSheet/VSheet'\n\n// Composables\nimport { provideDefaults } from '@/composables/defaults'\nimport { useRtl } from '@/composables/locale'\nimport { useProxiedModel } from '@/composables/proxiedModel'\n\n// Utilities\nimport { computed, onBeforeMount, ref, watch } from 'vue'\nimport { extractColor, modes, nullColor } from './util'\nimport { consoleWarn, defineComponent, HSVtoCSS, omit, parseColor, propsFactory, RGBtoHSV, useRender } from '@/util'\n\n// Types\nimport type { DeepReadonly, PropType } from 'vue'\nimport type { Color, HSV } from '@/util'\n\nexport const makeVColorPickerProps = propsFactory({\n canvasHeight: {\n type: [String, Number],\n default: 150,\n },\n disabled: Boolean,\n dotSize: {\n type: [Number, String],\n default: 10,\n },\n hideCanvas: Boolean,\n hideSliders: Boolean,\n hideInputs: Boolean,\n mode: {\n type: String as PropType<keyof typeof modes>,\n default: 'rgba',\n validator: (v: string) => Object.keys(modes).includes(v),\n },\n modes: {\n type: Array as PropType<readonly (keyof typeof modes)[]>,\n default: () => Object.keys(modes),\n validator: (v: any) => Array.isArray(v) && v.every(m => Object.keys(modes).includes(m)),\n },\n showSwatches: Boolean,\n swatches: Array as PropType<DeepReadonly<Color[][]>>,\n swatchesMaxHeight: {\n type: [Number, String],\n default: 150,\n },\n modelValue: {\n type: [Object, String] as PropType<Record<string, unknown> | string | undefined | null>,\n },\n\n ...omit(makeVSheetProps({ width: 300 }), [\n 'height',\n 'location',\n 'minHeight',\n 'maxHeight',\n 'minWidth',\n 'maxWidth',\n ]),\n}, 'VColorPicker')\n\nexport const VColorPicker = defineComponent({\n name: 'VColorPicker',\n\n props: makeVColorPickerProps(),\n\n emits: {\n 'update:modelValue': (color: any) => true,\n 'update:mode': (mode: keyof typeof modes) => true,\n },\n\n setup (props) {\n const mode = useProxiedModel(props, 'mode')\n const hue = ref<number | null>(null)\n const model = useProxiedModel(\n props,\n 'modelValue',\n undefined,\n v => {\n if (v == null || v === '') return null\n\n let c: HSV\n try {\n c = RGBtoHSV(parseColor(v as any))\n } catch (err) {\n consoleWarn(err as any)\n return null\n }\n\n return c\n },\n v => {\n if (!v) return null\n\n return extractColor(v, props.modelValue)\n }\n )\n const currentColor = computed(() => {\n return model.value\n ? { ...model.value, h: hue.value ?? model.value.h }\n : null\n })\n const { rtlClasses } = useRtl()\n\n let externalChange = true\n watch(model, v => {\n if (!externalChange) {\n // prevent hue shift from rgb conversion inaccuracy\n externalChange = true\n return\n }\n if (!v) return\n hue.value = v.h\n }, { immediate: true })\n\n const updateColor = (hsva: HSV) => {\n externalChange = false\n hue.value = hsva.h\n model.value = hsva\n }\n\n onBeforeMount(() => {\n if (!props.modes.includes(mode.value)) mode.value = props.modes[0]\n })\n\n provideDefaults({\n VSlider: {\n color: undefined,\n trackColor: undefined,\n trackFillColor: undefined,\n },\n })\n\n useRender(() => {\n const sheetProps = VSheet.filterProps(props)\n\n return (\n <VSheet\n rounded={ props.rounded }\n elevation={ props.elevation }\n theme={ props.theme }\n class={[\n 'v-color-picker',\n rtlClasses.value,\n props.class,\n ]}\n style={[\n {\n '--v-color-picker-color-hsv': HSVtoCSS({ ...(currentColor.value ?? nullColor), a: 1 }),\n },\n props.style,\n ]}\n { ...sheetProps }\n maxWidth={ props.width }\n >\n { !props.hideCanvas && (\n <VColorPickerCanvas\n key=\"canvas\"\n color={ currentColor.value }\n onUpdate:color={ updateColor }\n disabled={ props.disabled }\n dotSize={ props.dotSize }\n width={ props.width }\n height={ props.canvasHeight }\n />\n )}\n\n { (!props.hideSliders || !props.hideInputs) && (\n <div key=\"controls\" class=\"v-color-picker__controls\">\n { !props.hideSliders && (\n <VColorPickerPreview\n key=\"preview\"\n color={ currentColor.value }\n onUpdate:color={ updateColor }\n hideAlpha={ !mode.value.endsWith('a') }\n disabled={ props.disabled }\n />\n )}\n\n { !props.hideInputs && (\n <VColorPickerEdit\n key=\"edit\"\n modes={ props.modes }\n mode={ mode.value }\n onUpdate:mode={ m => mode.value = m }\n color={ currentColor.value }\n onUpdate:color={ updateColor }\n disabled={ props.disabled }\n />\n )}\n </div>\n )}\n\n { props.showSwatches && (\n <VColorPickerSwatches\n key=\"swatches\"\n color={ currentColor.value }\n onUpdate:color={ updateColor }\n maxHeight={ props.swatchesMaxHeight }\n swatches={ props.swatches }\n disabled={ props.disabled }\n />\n )}\n </VSheet>\n )\n })\n\n return {}\n },\n})\n\nexport type VColorPicker = InstanceType<typeof VColorPicker>\n"],"mappings":";AAAA;AACA;;AAEA;AAAA,SACSA,kBAAkB;AAAA,SAClBC,gBAAgB;AAAA,SAChBC,mBAAmB;AAAA,SACnBC,oBAAoB;AAAA,SACpBC,eAAe,EAAEC,MAAM,gCAEhC;AAAA,SACSC,eAAe;AAAA,SACfC,MAAM;AAAA,SACNC,eAAe,8CAExB;AACA,SAAS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AAW;UAAA,YACjBf,KAAK,CAACvB;QAAQ,QAE5B,EAEJ,EAECuB,KAAK,CAACP,YAAY,IAAA6B,YAAA,CAAAxE,oBAAA;UAAA;UAAA,SAGR2D,YAAY,CAACC,KAAK;UAAA,kBACTK,WAAW;UAAA,aAChBf,KAAK,CAACL,iBAAiB;UAAA,YACxBK,KAAK,CAACN,QAAQ;UAAA,YACdM,KAAK,CAACvB;QAAQ,QAE5B;MAAA;IAGP,CAAC,CAAC;IAEF,OAAO,CAAC,CAAC;EACX;AACF,CAAC,CAAC","ignoreList":[]}
|
|
@@ -1101,9 +1101,9 @@ declare const VMenu: {
|
|
|
1101
1101
|
class?: any;
|
|
1102
1102
|
theme?: string | undefined;
|
|
1103
1103
|
contentClass?: any;
|
|
1104
|
+
activator?: Element | "parent" | (string & {}) | vue.ComponentPublicInstance | undefined;
|
|
1104
1105
|
closeDelay?: string | number | undefined;
|
|
1105
1106
|
openDelay?: string | number | undefined;
|
|
1106
|
-
activator?: Element | "parent" | (string & {}) | vue.ComponentPublicInstance | undefined;
|
|
1107
1107
|
openOnClick?: boolean | undefined;
|
|
1108
1108
|
openOnFocus?: boolean | undefined;
|
|
1109
1109
|
contentProps?: any;
|
|
@@ -1180,9 +1180,9 @@ declare const VMenu: {
|
|
|
1180
1180
|
class?: any;
|
|
1181
1181
|
theme?: string | undefined;
|
|
1182
1182
|
contentClass?: any;
|
|
1183
|
+
activator?: Element | "parent" | (string & {}) | vue.ComponentPublicInstance | undefined;
|
|
1183
1184
|
closeDelay?: string | number | undefined;
|
|
1184
1185
|
openDelay?: string | number | undefined;
|
|
1185
|
-
activator?: Element | "parent" | (string & {}) | vue.ComponentPublicInstance | undefined;
|
|
1186
1186
|
openOnClick?: boolean | undefined;
|
|
1187
1187
|
openOnFocus?: boolean | undefined;
|
|
1188
1188
|
contentProps?: any;
|
|
@@ -1243,7 +1243,7 @@ declare const VMenu: {
|
|
|
1243
1243
|
}>;
|
|
1244
1244
|
$root: vue.ComponentPublicInstance | null;
|
|
1245
1245
|
$parent: vue.ComponentPublicInstance | null;
|
|
1246
|
-
$emit: ((event: "
|
|
1246
|
+
$emit: ((event: "update:modelValue", value: boolean) => void) & ((event: "click:outside", e: MouseEvent) => void) & ((event: "afterEnter") => void) & ((event: "afterLeave") => void);
|
|
1247
1247
|
$el: any;
|
|
1248
1248
|
$options: vue.ComponentOptionsBase<{
|
|
1249
1249
|
absolute: boolean;
|
|
@@ -1283,9 +1283,9 @@ declare const VMenu: {
|
|
|
1283
1283
|
class?: any;
|
|
1284
1284
|
theme?: string | undefined;
|
|
1285
1285
|
contentClass?: any;
|
|
1286
|
+
activator?: Element | "parent" | (string & {}) | vue.ComponentPublicInstance | undefined;
|
|
1286
1287
|
closeDelay?: string | number | undefined;
|
|
1287
1288
|
openDelay?: string | number | undefined;
|
|
1288
|
-
activator?: Element | "parent" | (string & {}) | vue.ComponentPublicInstance | undefined;
|
|
1289
1289
|
openOnClick?: boolean | undefined;
|
|
1290
1290
|
openOnFocus?: boolean | undefined;
|
|
1291
1291
|
contentProps?: any;
|
|
@@ -1435,9 +1435,9 @@ declare const VMenu: {
|
|
|
1435
1435
|
class?: any;
|
|
1436
1436
|
theme?: string | undefined;
|
|
1437
1437
|
contentClass?: any;
|
|
1438
|
+
activator?: Element | "parent" | (string & {}) | vue.ComponentPublicInstance | undefined;
|
|
1438
1439
|
closeDelay?: string | number | undefined;
|
|
1439
1440
|
openDelay?: string | number | undefined;
|
|
1440
|
-
activator?: Element | "parent" | (string & {}) | vue.ComponentPublicInstance | undefined;
|
|
1441
1441
|
openOnClick?: boolean | undefined;
|
|
1442
1442
|
openOnFocus?: boolean | undefined;
|
|
1443
1443
|
contentProps?: any;
|
|
@@ -1488,7 +1488,7 @@ declare const VMenu: {
|
|
|
1488
1488
|
globalTop: Readonly<vue.Ref<boolean>>;
|
|
1489
1489
|
localTop: vue.ComputedRef<boolean>;
|
|
1490
1490
|
updateLocation: vue.Ref<((e: Event) => void) | undefined>;
|
|
1491
|
-
}> & {} & vue.ComponentCustomProperties & {}, "offset" | "key" | "height" | "width" | "maxHeight" | "maxWidth" | "minHeight" | "minWidth" | "opacity" | "target" | "class" | "theme" | "ref" | "onAfterEnter" | "onAfterLeave" | "$children" | "v-slots" | "v-slot:default" | "ref_for" | "ref_key" | "onVnodeBeforeMount" | "onVnodeMounted" | "onVnodeBeforeUpdate" | "onVnodeUpdated" | "onVnodeBeforeUnmount" | "onVnodeUnmounted" | "onUpdate:modelValue" | "contentClass" | "
|
|
1491
|
+
}> & {} & vue.ComponentCustomProperties & {}, "offset" | "key" | "height" | "width" | "maxHeight" | "maxWidth" | "minHeight" | "minWidth" | "opacity" | "target" | "class" | "theme" | "ref" | "onAfterEnter" | "onAfterLeave" | "$children" | "v-slots" | "v-slot:default" | "ref_for" | "ref_key" | "onVnodeBeforeMount" | "onVnodeMounted" | "onVnodeBeforeUpdate" | "onVnodeUpdated" | "onVnodeBeforeUnmount" | "onVnodeUnmounted" | "onUpdate:modelValue" | "contentClass" | "activator" | "v-slot:activator" | "closeDelay" | "openDelay" | "contentProps" | "attach" | "onClick:outside" | ("absolute" | "location" | "origin" | "transition" | "zIndex" | "style" | "eager" | "disabled" | "persistent" | "modelValue" | "locationStrategy" | "scrollStrategy" | "activatorProps" | "openOnClick" | "openOnHover" | "openOnFocus" | "closeOnContentClick" | "closeOnBack" | "contained" | "noClickAnimation" | "scrim" | "_disableGlobalStack")>, `$${any}`> & {
|
|
1492
1492
|
_allExposed: {
|
|
1493
1493
|
activatorEl: vue.Ref<HTMLElement | undefined>;
|
|
1494
1494
|
scrimEl: vue.Ref<HTMLElement | undefined>;
|
|
@@ -1782,9 +1782,9 @@ declare const VMenu: {
|
|
|
1782
1782
|
class?: any;
|
|
1783
1783
|
theme?: string | undefined;
|
|
1784
1784
|
contentClass?: any;
|
|
1785
|
+
activator?: Element | "parent" | (string & {}) | vue.ComponentPublicInstance | undefined;
|
|
1785
1786
|
closeDelay?: string | number | undefined;
|
|
1786
1787
|
openDelay?: string | number | undefined;
|
|
1787
|
-
activator?: Element | "parent" | (string & {}) | vue.ComponentPublicInstance | undefined;
|
|
1788
1788
|
openOnClick?: boolean | undefined;
|
|
1789
1789
|
openOnFocus?: boolean | undefined;
|
|
1790
1790
|
contentProps?: any;
|
|
@@ -1861,9 +1861,9 @@ declare const VMenu: {
|
|
|
1861
1861
|
class?: any;
|
|
1862
1862
|
theme?: string | undefined;
|
|
1863
1863
|
contentClass?: any;
|
|
1864
|
+
activator?: Element | "parent" | (string & {}) | vue.ComponentPublicInstance | undefined;
|
|
1864
1865
|
closeDelay?: string | number | undefined;
|
|
1865
1866
|
openDelay?: string | number | undefined;
|
|
1866
|
-
activator?: Element | "parent" | (string & {}) | vue.ComponentPublicInstance | undefined;
|
|
1867
1867
|
openOnClick?: boolean | undefined;
|
|
1868
1868
|
openOnFocus?: boolean | undefined;
|
|
1869
1869
|
contentProps?: any;
|
|
@@ -1924,7 +1924,7 @@ declare const VMenu: {
|
|
|
1924
1924
|
}>;
|
|
1925
1925
|
$root: vue.ComponentPublicInstance | null;
|
|
1926
1926
|
$parent: vue.ComponentPublicInstance | null;
|
|
1927
|
-
$emit: ((event: "
|
|
1927
|
+
$emit: ((event: "update:modelValue", value: boolean) => void) & ((event: "click:outside", e: MouseEvent) => void) & ((event: "afterEnter") => void) & ((event: "afterLeave") => void);
|
|
1928
1928
|
$el: any;
|
|
1929
1929
|
$options: vue.ComponentOptionsBase<{
|
|
1930
1930
|
absolute: boolean;
|
|
@@ -1964,9 +1964,9 @@ declare const VMenu: {
|
|
|
1964
1964
|
class?: any;
|
|
1965
1965
|
theme?: string | undefined;
|
|
1966
1966
|
contentClass?: any;
|
|
1967
|
+
activator?: Element | "parent" | (string & {}) | vue.ComponentPublicInstance | undefined;
|
|
1967
1968
|
closeDelay?: string | number | undefined;
|
|
1968
1969
|
openDelay?: string | number | undefined;
|
|
1969
|
-
activator?: Element | "parent" | (string & {}) | vue.ComponentPublicInstance | undefined;
|
|
1970
1970
|
openOnClick?: boolean | undefined;
|
|
1971
1971
|
openOnFocus?: boolean | undefined;
|
|
1972
1972
|
contentProps?: any;
|
|
@@ -2116,9 +2116,9 @@ declare const VMenu: {
|
|
|
2116
2116
|
class?: any;
|
|
2117
2117
|
theme?: string | undefined;
|
|
2118
2118
|
contentClass?: any;
|
|
2119
|
+
activator?: Element | "parent" | (string & {}) | vue.ComponentPublicInstance | undefined;
|
|
2119
2120
|
closeDelay?: string | number | undefined;
|
|
2120
2121
|
openDelay?: string | number | undefined;
|
|
2121
|
-
activator?: Element | "parent" | (string & {}) | vue.ComponentPublicInstance | undefined;
|
|
2122
2122
|
openOnClick?: boolean | undefined;
|
|
2123
2123
|
openOnFocus?: boolean | undefined;
|
|
2124
2124
|
contentProps?: any;
|
|
@@ -2169,7 +2169,7 @@ declare const VMenu: {
|
|
|
2169
2169
|
globalTop: Readonly<vue.Ref<boolean>>;
|
|
2170
2170
|
localTop: vue.ComputedRef<boolean>;
|
|
2171
2171
|
updateLocation: vue.Ref<((e: Event) => void) | undefined>;
|
|
2172
|
-
}> & {} & vue.ComponentCustomProperties & {}, "offset" | "key" | "height" | "width" | "maxHeight" | "maxWidth" | "minHeight" | "minWidth" | "opacity" | "target" | "class" | "theme" | "ref" | "onAfterEnter" | "onAfterLeave" | "$children" | "v-slots" | "v-slot:default" | "ref_for" | "ref_key" | "onVnodeBeforeMount" | "onVnodeMounted" | "onVnodeBeforeUpdate" | "onVnodeUpdated" | "onVnodeBeforeUnmount" | "onVnodeUnmounted" | "onUpdate:modelValue" | "contentClass" | "
|
|
2172
|
+
}> & {} & vue.ComponentCustomProperties & {}, "offset" | "key" | "height" | "width" | "maxHeight" | "maxWidth" | "minHeight" | "minWidth" | "opacity" | "target" | "class" | "theme" | "ref" | "onAfterEnter" | "onAfterLeave" | "$children" | "v-slots" | "v-slot:default" | "ref_for" | "ref_key" | "onVnodeBeforeMount" | "onVnodeMounted" | "onVnodeBeforeUpdate" | "onVnodeUpdated" | "onVnodeBeforeUnmount" | "onVnodeUnmounted" | "onUpdate:modelValue" | "contentClass" | "activator" | "v-slot:activator" | "closeDelay" | "openDelay" | "contentProps" | "attach" | "onClick:outside" | ("absolute" | "location" | "origin" | "transition" | "zIndex" | "style" | "eager" | "disabled" | "persistent" | "modelValue" | "locationStrategy" | "scrollStrategy" | "activatorProps" | "openOnClick" | "openOnHover" | "openOnFocus" | "closeOnContentClick" | "closeOnBack" | "contained" | "noClickAnimation" | "scrim" | "_disableGlobalStack")>, `$${any}`> & {
|
|
2173
2173
|
_allExposed: {
|
|
2174
2174
|
activatorEl: vue.Ref<HTMLElement | undefined>;
|
|
2175
2175
|
scrimEl: vue.Ref<HTMLElement | undefined>;
|
|
@@ -2368,9 +2368,9 @@ declare const VMenu: {
|
|
|
2368
2368
|
class?: any;
|
|
2369
2369
|
theme?: string | undefined;
|
|
2370
2370
|
contentClass?: any;
|
|
2371
|
+
activator?: Element | "parent" | (string & {}) | vue.ComponentPublicInstance | undefined;
|
|
2371
2372
|
closeDelay?: string | number | undefined;
|
|
2372
2373
|
openDelay?: string | number | undefined;
|
|
2373
|
-
activator?: Element | "parent" | (string & {}) | vue.ComponentPublicInstance | undefined;
|
|
2374
2374
|
openOnClick?: boolean | undefined;
|
|
2375
2375
|
openOnFocus?: boolean | undefined;
|
|
2376
2376
|
contentProps?: any;
|
|
@@ -2447,9 +2447,9 @@ declare const VMenu: {
|
|
|
2447
2447
|
class?: any;
|
|
2448
2448
|
theme?: string | undefined;
|
|
2449
2449
|
contentClass?: any;
|
|
2450
|
+
activator?: Element | "parent" | (string & {}) | vue.ComponentPublicInstance | undefined;
|
|
2450
2451
|
closeDelay?: string | number | undefined;
|
|
2451
2452
|
openDelay?: string | number | undefined;
|
|
2452
|
-
activator?: Element | "parent" | (string & {}) | vue.ComponentPublicInstance | undefined;
|
|
2453
2453
|
openOnClick?: boolean | undefined;
|
|
2454
2454
|
openOnFocus?: boolean | undefined;
|
|
2455
2455
|
contentProps?: any;
|
|
@@ -2510,7 +2510,7 @@ declare const VMenu: {
|
|
|
2510
2510
|
}>;
|
|
2511
2511
|
$root: vue.ComponentPublicInstance | null;
|
|
2512
2512
|
$parent: vue.ComponentPublicInstance | null;
|
|
2513
|
-
$emit: ((event: "
|
|
2513
|
+
$emit: ((event: "update:modelValue", value: boolean) => void) & ((event: "click:outside", e: MouseEvent) => void) & ((event: "afterEnter") => void) & ((event: "afterLeave") => void);
|
|
2514
2514
|
$el: any;
|
|
2515
2515
|
$options: vue.ComponentOptionsBase<{
|
|
2516
2516
|
absolute: boolean;
|
|
@@ -2550,9 +2550,9 @@ declare const VMenu: {
|
|
|
2550
2550
|
class?: any;
|
|
2551
2551
|
theme?: string | undefined;
|
|
2552
2552
|
contentClass?: any;
|
|
2553
|
+
activator?: Element | "parent" | (string & {}) | vue.ComponentPublicInstance | undefined;
|
|
2553
2554
|
closeDelay?: string | number | undefined;
|
|
2554
2555
|
openDelay?: string | number | undefined;
|
|
2555
|
-
activator?: Element | "parent" | (string & {}) | vue.ComponentPublicInstance | undefined;
|
|
2556
2556
|
openOnClick?: boolean | undefined;
|
|
2557
2557
|
openOnFocus?: boolean | undefined;
|
|
2558
2558
|
contentProps?: any;
|
|
@@ -2702,9 +2702,9 @@ declare const VMenu: {
|
|
|
2702
2702
|
class?: any;
|
|
2703
2703
|
theme?: string | undefined;
|
|
2704
2704
|
contentClass?: any;
|
|
2705
|
+
activator?: Element | "parent" | (string & {}) | vue.ComponentPublicInstance | undefined;
|
|
2705
2706
|
closeDelay?: string | number | undefined;
|
|
2706
2707
|
openDelay?: string | number | undefined;
|
|
2707
|
-
activator?: Element | "parent" | (string & {}) | vue.ComponentPublicInstance | undefined;
|
|
2708
2708
|
openOnClick?: boolean | undefined;
|
|
2709
2709
|
openOnFocus?: boolean | undefined;
|
|
2710
2710
|
contentProps?: any;
|
|
@@ -2755,7 +2755,7 @@ declare const VMenu: {
|
|
|
2755
2755
|
globalTop: Readonly<vue.Ref<boolean>>;
|
|
2756
2756
|
localTop: vue.ComputedRef<boolean>;
|
|
2757
2757
|
updateLocation: vue.Ref<((e: Event) => void) | undefined>;
|
|
2758
|
-
}> & {} & vue.ComponentCustomProperties & {}, "offset" | "key" | "height" | "width" | "maxHeight" | "maxWidth" | "minHeight" | "minWidth" | "opacity" | "target" | "class" | "theme" | "ref" | "onAfterEnter" | "onAfterLeave" | "$children" | "v-slots" | "v-slot:default" | "ref_for" | "ref_key" | "onVnodeBeforeMount" | "onVnodeMounted" | "onVnodeBeforeUpdate" | "onVnodeUpdated" | "onVnodeBeforeUnmount" | "onVnodeUnmounted" | "onUpdate:modelValue" | "contentClass" | "
|
|
2758
|
+
}> & {} & vue.ComponentCustomProperties & {}, "offset" | "key" | "height" | "width" | "maxHeight" | "maxWidth" | "minHeight" | "minWidth" | "opacity" | "target" | "class" | "theme" | "ref" | "onAfterEnter" | "onAfterLeave" | "$children" | "v-slots" | "v-slot:default" | "ref_for" | "ref_key" | "onVnodeBeforeMount" | "onVnodeMounted" | "onVnodeBeforeUpdate" | "onVnodeUpdated" | "onVnodeBeforeUnmount" | "onVnodeUnmounted" | "onUpdate:modelValue" | "contentClass" | "activator" | "v-slot:activator" | "closeDelay" | "openDelay" | "contentProps" | "attach" | "onClick:outside" | ("absolute" | "location" | "origin" | "transition" | "zIndex" | "style" | "eager" | "disabled" | "persistent" | "modelValue" | "locationStrategy" | "scrollStrategy" | "activatorProps" | "openOnClick" | "openOnHover" | "openOnFocus" | "closeOnContentClick" | "closeOnBack" | "contained" | "noClickAnimation" | "scrim" | "_disableGlobalStack")>, `$${any}`> & {
|
|
2759
2759
|
_allExposed: {
|
|
2760
2760
|
activatorEl: vue.Ref<HTMLElement | undefined>;
|
|
2761
2761
|
scrimEl: vue.Ref<HTMLElement | undefined>;
|
|
@@ -2864,6 +2864,7 @@ declare const VMenu: {
|
|
|
2864
2864
|
persistent: BooleanConstructor;
|
|
2865
2865
|
modelValue: BooleanConstructor;
|
|
2866
2866
|
contentClass: null;
|
|
2867
|
+
activator: vue.PropType<Element | "parent" | (string & {}) | vue.ComponentPublicInstance | undefined>;
|
|
2867
2868
|
locationStrategy: Omit<{
|
|
2868
2869
|
type: vue.PropType<StrategyProps["locationStrategy"]>;
|
|
2869
2870
|
default: string;
|
|
@@ -2892,7 +2893,6 @@ declare const VMenu: {
|
|
|
2892
2893
|
type: vue.PropType<string | number>;
|
|
2893
2894
|
default: NonNullable<string | number>;
|
|
2894
2895
|
};
|
|
2895
|
-
activator: vue.PropType<Element | "parent" | (string & {}) | vue.ComponentPublicInstance | undefined>;
|
|
2896
2896
|
activatorProps: {
|
|
2897
2897
|
type: vue.PropType<Record<string, any>>;
|
|
2898
2898
|
default: () => {};
|
|
@@ -2981,6 +2981,7 @@ declare const VMenu: {
|
|
|
2981
2981
|
persistent: BooleanConstructor;
|
|
2982
2982
|
modelValue: BooleanConstructor;
|
|
2983
2983
|
contentClass: null;
|
|
2984
|
+
activator: vue.PropType<Element | "parent" | (string & {}) | vue.ComponentPublicInstance | undefined>;
|
|
2984
2985
|
locationStrategy: Omit<{
|
|
2985
2986
|
type: vue.PropType<StrategyProps["locationStrategy"]>;
|
|
2986
2987
|
default: string;
|
|
@@ -3009,7 +3010,6 @@ declare const VMenu: {
|
|
|
3009
3010
|
type: vue.PropType<string | number>;
|
|
3010
3011
|
default: NonNullable<string | number>;
|
|
3011
3012
|
};
|
|
3012
|
-
activator: vue.PropType<Element | "parent" | (string & {}) | vue.ComponentPublicInstance | undefined>;
|
|
3013
3013
|
activatorProps: {
|
|
3014
3014
|
type: vue.PropType<Record<string, any>>;
|
|
3015
3015
|
default: () => {};
|
|
@@ -3547,7 +3547,7 @@ declare const VCombobox: {
|
|
|
3547
3547
|
'update:modelValue': (value: any) => true;
|
|
3548
3548
|
'update:search': (value: string) => true;
|
|
3549
3549
|
'update:menu': (value: boolean) => true;
|
|
3550
|
-
}, "multiple" | "$children" | "v-slots" | "modelValue" | "
|
|
3550
|
+
}, "multiple" | "$children" | "v-slots" | "modelValue" | "items" | "v-slot:prepend" | "v-slot:append" | "update:modelValue" | "v-slot:loader" | "v-slot:label" | "v-slot:message" | "v-slot:details" | "returnObject" | "v-slot:item" | "itemTitle" | "itemValue" | "itemProps" | "v-slot:clear" | "v-slot:prepend-inner" | "v-slot:append-inner" | "v-slot:chip" | "v-slot:selection" | "v-slot:prepend-item" | "v-slot:append-item" | "v-slot:no-data">, vue.VNodeProps & vue.AllowedComponentProps & vue.ComponentCustomProps & {
|
|
3551
3551
|
flat: boolean;
|
|
3552
3552
|
reverse: boolean;
|
|
3553
3553
|
variant: "filled" | "underlined" | "outlined" | "plain" | "solo" | "solo-inverted" | "solo-filled";
|
|
@@ -5165,7 +5165,7 @@ declare const VCombobox: {
|
|
|
5165
5165
|
'update:modelValue': (value: any) => true;
|
|
5166
5166
|
'update:search': (value: string) => true;
|
|
5167
5167
|
'update:menu': (value: boolean) => true;
|
|
5168
|
-
}, "multiple" | "$children" | "v-slots" | "modelValue" | "
|
|
5168
|
+
}, "multiple" | "$children" | "v-slots" | "modelValue" | "items" | "v-slot:prepend" | "v-slot:append" | "update:modelValue" | "v-slot:loader" | "v-slot:label" | "v-slot:message" | "v-slot:details" | "returnObject" | "v-slot:item" | "itemTitle" | "itemValue" | "itemProps" | "v-slot:clear" | "v-slot:prepend-inner" | "v-slot:append-inner" | "v-slot:chip" | "v-slot:selection" | "v-slot:prepend-item" | "v-slot:append-item" | "v-slot:no-data">, string, {
|
|
5169
5169
|
flat: boolean;
|
|
5170
5170
|
reverse: boolean;
|
|
5171
5171
|
variant: "filled" | "underlined" | "outlined" | "plain" | "solo" | "solo-inverted" | "solo-filled";
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
import { createTextVNode as _createTextVNode, Fragment as _Fragment, createVNode as _createVNode } from "vue";
|
|
2
|
+
// Components
|
|
3
|
+
import { VConfirmEdit } from "../index.mjs"; // Utilities
|
|
4
|
+
import { render, screen, userEvent } from '@test';
|
|
5
|
+
import { nextTick, shallowRef } from 'vue';
|
|
6
|
+
describe('VConfirmEdit', () => {
|
|
7
|
+
it('mirrors external updates', async () => {
|
|
8
|
+
const externalModel = shallowRef('foo');
|
|
9
|
+
render(() => _createVNode(VConfirmEdit, {
|
|
10
|
+
"modelValue": externalModel.value
|
|
11
|
+
}, {
|
|
12
|
+
default: _ref => {
|
|
13
|
+
let {
|
|
14
|
+
model
|
|
15
|
+
} = _ref;
|
|
16
|
+
return _createVNode("p", null, [model.value]);
|
|
17
|
+
}
|
|
18
|
+
}));
|
|
19
|
+
expect(screen.getByText('foo')).toBeInTheDocument();
|
|
20
|
+
externalModel.value = 'bar';
|
|
21
|
+
await nextTick();
|
|
22
|
+
expect(screen.getByText('bar')).toBeInTheDocument();
|
|
23
|
+
});
|
|
24
|
+
it("doesn't mutate the original value", async () => {
|
|
25
|
+
const externalModel = shallowRef(['foo']);
|
|
26
|
+
render(() => _createVNode(VConfirmEdit, {
|
|
27
|
+
"modelValue": externalModel.value,
|
|
28
|
+
"onUpdate:modelValue": $event => externalModel.value = $event
|
|
29
|
+
}, {
|
|
30
|
+
default: _ref2 => {
|
|
31
|
+
let {
|
|
32
|
+
model
|
|
33
|
+
} = _ref2;
|
|
34
|
+
return _createVNode(_Fragment, null, [_createVNode("p", null, [model.value.join(',')]), _createVNode("button", {
|
|
35
|
+
"data-testid": "push",
|
|
36
|
+
"onClick": () => model.value.push('bar')
|
|
37
|
+
}, [_createTextVNode("Push")])]);
|
|
38
|
+
}
|
|
39
|
+
}));
|
|
40
|
+
expect(screen.getByText('foo')).toBeInTheDocument();
|
|
41
|
+
await userEvent.click(screen.getByTestId('push'));
|
|
42
|
+
expect(screen.getByText('foo,bar')).toBeInTheDocument();
|
|
43
|
+
expect(externalModel.value).toEqual(['foo']);
|
|
44
|
+
await userEvent.click(screen.getByText('OK'));
|
|
45
|
+
expect(externalModel.value).toEqual(['foo', 'bar']);
|
|
46
|
+
});
|
|
47
|
+
describe('hides actions if used from the slot', () => {
|
|
48
|
+
it('nothing', () => {
|
|
49
|
+
render(() => _createVNode(VConfirmEdit, null, null));
|
|
50
|
+
expect(screen.getAllByCSS('button')).toHaveLength(2);
|
|
51
|
+
});
|
|
52
|
+
it('consume model', () => {
|
|
53
|
+
render(() => _createVNode(VConfirmEdit, null, {
|
|
54
|
+
default: _ref3 => {
|
|
55
|
+
let {
|
|
56
|
+
model
|
|
57
|
+
} = _ref3;
|
|
58
|
+
void model;
|
|
59
|
+
}
|
|
60
|
+
}));
|
|
61
|
+
expect(screen.getAllByCSS('button')).toHaveLength(2);
|
|
62
|
+
});
|
|
63
|
+
it('consume actions', () => {
|
|
64
|
+
render(() => _createVNode(VConfirmEdit, null, {
|
|
65
|
+
default: _ref4 => {
|
|
66
|
+
let {
|
|
67
|
+
actions
|
|
68
|
+
} = _ref4;
|
|
69
|
+
void actions;
|
|
70
|
+
}
|
|
71
|
+
}));
|
|
72
|
+
expect(screen.queryAllByCSS('button')).toHaveLength(0);
|
|
73
|
+
});
|
|
74
|
+
it('render actions', () => {
|
|
75
|
+
render(() => _createVNode(VConfirmEdit, null, {
|
|
76
|
+
default: _ref5 => {
|
|
77
|
+
let {
|
|
78
|
+
actions
|
|
79
|
+
} = _ref5;
|
|
80
|
+
return actions;
|
|
81
|
+
}
|
|
82
|
+
}));
|
|
83
|
+
expect(screen.getAllByCSS('button')).toHaveLength(2);
|
|
84
|
+
});
|
|
85
|
+
});
|
|
86
|
+
});
|
|
87
|
+
//# sourceMappingURL=VConfirmEdit.spec.browser.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"VConfirmEdit.spec.browser.mjs","names":["VConfirmEdit","render","screen","userEvent","nextTick","shallowRef","describe","it","externalModel","_createVNode","value","default","_ref","model","expect","getByText","toBeInTheDocument","$event","_ref2","_Fragment","join","onClick","push","_createTextVNode","click","getByTestId","toEqual","getAllByCSS","toHaveLength","_ref3","_ref4","actions","queryAllByCSS","_ref5"],"sources":["../../../../src/components/VConfirmEdit/__test__/VConfirmEdit.spec.browser.tsx"],"sourcesContent":["// Components\nimport { VConfirmEdit } from '../'\n\n// Utilities\nimport { render, screen, userEvent } from '@test'\nimport { nextTick, shallowRef } from 'vue'\n\ndescribe('VConfirmEdit', () => {\n it('mirrors external updates', async () => {\n const externalModel = shallowRef('foo')\n\n render(() => (\n <VConfirmEdit modelValue={ externalModel.value }>\n { ({ model }) => (\n <p>{ model.value }</p>\n )}\n </VConfirmEdit>\n ))\n\n expect(screen.getByText('foo')).toBeInTheDocument()\n\n externalModel.value = 'bar'\n await nextTick()\n expect(screen.getByText('bar')).toBeInTheDocument()\n })\n\n it(\"doesn't mutate the original value\", async () => {\n const externalModel = shallowRef(['foo'])\n\n render(() => (\n <VConfirmEdit v-model={ externalModel.value } modelValue={ externalModel.value }>\n { ({ model }) => (\n <>\n <p>{ model.value.join(',') }</p>\n <button data-testid=\"push\" onClick={ () => model.value.push('bar') }>Push</button>\n </>\n )}\n </VConfirmEdit>\n ))\n\n expect(screen.getByText('foo')).toBeInTheDocument()\n\n await userEvent.click(screen.getByTestId('push'))\n expect(screen.getByText('foo,bar')).toBeInTheDocument()\n expect(externalModel.value).toEqual(['foo'])\n\n await userEvent.click(screen.getByText('OK'))\n expect(externalModel.value).toEqual(['foo', 'bar'])\n })\n\n describe('hides actions if used from the slot', () => {\n it('nothing', () => {\n render(() => <VConfirmEdit />)\n expect(screen.getAllByCSS('button')).toHaveLength(2)\n })\n\n it('consume model', () => {\n render(() => (\n <VConfirmEdit>\n { ({ model }) => {\n void model\n }}\n </VConfirmEdit>\n ))\n expect(screen.getAllByCSS('button')).toHaveLength(2)\n })\n\n it('consume actions', () => {\n render(() => (\n <VConfirmEdit>\n { ({ actions }) => {\n void actions\n }}\n </VConfirmEdit>\n ))\n expect(screen.queryAllByCSS('button')).toHaveLength(0)\n })\n\n it('render actions', () => {\n render(() => (\n <VConfirmEdit>\n { ({ actions }) => actions }\n </VConfirmEdit>\n ))\n expect(screen.getAllByCSS('button')).toHaveLength(2)\n })\n })\n})\n"],"mappings":";A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E,MAAM;MAC1BN,MAAM,CAAC,MAAAQ,YAAA,CAAAT,YAAA;QAAAW,OAAA,EAEDmB,KAAA,IAAiB;UAAA,IAAhB;YAAEC;UAAQ,CAAC,GAAAD,KAAA;UACZ,KAAKC,OAAO;QACd;MAAC,EAEJ,CAAC;MACFjB,MAAM,CAACZ,MAAM,CAAC8B,aAAa,CAAC,QAAQ,CAAC,CAAC,CAACJ,YAAY,CAAC,CAAC,CAAC;IACxD,CAAC,CAAC;IAEFrB,EAAE,CAAC,gBAAgB,EAAE,MAAM;MACzBN,MAAM,CAAC,MAAAQ,YAAA,CAAAT,YAAA;QAAAW,OAAA,EAEDsB,KAAA;UAAA,IAAC;YAAEF;UAAQ,CAAC,GAAAE,KAAA;UAAA,OAAKF,OAAO;QAAA;MAAA,EAE7B,CAAC;MACFjB,MAAM,CAACZ,MAAM,CAACyB,WAAW,CAAC,QAAQ,CAAC,CAAC,CAACC,YAAY,CAAC,CAAC,CAAC;IACtD,CAAC,CAAC;EACJ,CAAC,CAAC;AACJ,CAAC,CAAC","ignoreList":[]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"VDataTableFooter.mjs","names":["VPagination","VSelect","usePagination","IconValue","useLocale","computed","genericComponent","propsFactory","useRender","makeVDataTableFooterProps","prevIcon","type","default","nextIcon","firstIcon","lastIcon","itemsPerPageText","String","pageText","firstPageLabel","prevPageLabel","nextPageLabel","lastPageLabel","itemsPerPageOptions","Array","value","title","showCurrentPage","Boolean","VDataTableFooter","name","props","setup","_ref","slots","t","page","pageCount","startIndex","stopIndex","itemsLength","itemsPerPage","setItemsPerPage","map","option","isNaN","Number","paginationProps","filterProps","_createVNode","prepend","v","_mergeProps","$event"],"sources":["../../../src/components/VDataTable/VDataTableFooter.tsx"],"sourcesContent":["// Styles\nimport './VDataTableFooter.sass'\n\n// Components\nimport { VPagination } from '@/components/VPagination'\nimport { VSelect } from '@/components/VSelect'\n\n// Composables\nimport { usePagination } from './composables/paginate'\nimport { IconValue } from '@/composables/icons'\nimport { useLocale } from '@/composables/locale'\n\n// Utilities\nimport { computed } from 'vue'\nimport { genericComponent, propsFactory, useRender } from '@/util'\n\n// Types\nimport type { PropType } from 'vue'\n\nexport const makeVDataTableFooterProps = propsFactory({\n prevIcon: {\n type: IconValue,\n default: '$prev',\n },\n nextIcon: {\n type: IconValue,\n default: '$next',\n },\n firstIcon: {\n type: IconValue,\n default: '$first',\n },\n lastIcon: {\n type: IconValue,\n default: '$last',\n },\n itemsPerPageText: {\n type: String,\n default: '$vuetify.dataFooter.itemsPerPageText',\n },\n pageText: {\n type: String,\n default: '$vuetify.dataFooter.pageText',\n },\n firstPageLabel: {\n type: String,\n default: '$vuetify.dataFooter.firstPage',\n },\n prevPageLabel: {\n type: String,\n default: '$vuetify.dataFooter.prevPage',\n },\n nextPageLabel: {\n type: String,\n default: '$vuetify.dataFooter.nextPage',\n },\n lastPageLabel: {\n type: String,\n default: '$vuetify.dataFooter.lastPage',\n },\n itemsPerPageOptions: {\n type: Array as PropType<readonly (number | { title: string, value: number })[]>,\n default: () => ([\n { value: 10, title: '10' },\n { value: 25, title: '25' },\n { value: 50, title: '50' },\n { value: 100, title: '100' },\n { value: -1, title: '$vuetify.dataFooter.itemsPerPageAll' },\n ]),\n },\n showCurrentPage: Boolean,\n}, 'VDataTableFooter')\n\nexport const VDataTableFooter = genericComponent<{ prepend: never }>()({\n name: 'VDataTableFooter',\n\n props: makeVDataTableFooterProps(),\n\n setup (props, { slots }) {\n const { t } = useLocale()\n const { page, pageCount, startIndex, stopIndex, itemsLength, itemsPerPage, setItemsPerPage } = usePagination()\n\n const itemsPerPageOptions = computed(() => (\n props.itemsPerPageOptions.map(option => {\n if (typeof option === 'number') {\n return {\n value: option,\n title: option === -1\n ? t('$vuetify.dataFooter.itemsPerPageAll')\n : String(option),\n }\n }\n\n return {\n ...option,\n title: !isNaN(Number(option.title)) ? option.title : t(option.title),\n }\n })\n ))\n\n useRender(() => {\n const paginationProps = VPagination.filterProps(props)\n\n return (\n <div class=\"v-data-table-footer\">\n { slots.prepend?.() }\n\n <div class=\"v-data-table-footer__items-per-page\">\n <span>{ t(props.itemsPerPageText) }</span>\n\n <VSelect\n items={ itemsPerPageOptions.value }\n modelValue={ itemsPerPage.value }\n onUpdate:modelValue={ v => setItemsPerPage(Number(v)) }\n density=\"compact\"\n variant=\"outlined\"\n hide-details\n />\n </div>\n\n <div class=\"v-data-table-footer__info\">\n <div>\n { t(props.pageText, !itemsLength.value ? 0 : startIndex.value + 1, stopIndex.value, itemsLength.value) }\n </div>\n </div>\n\n <div class=\"v-data-table-footer__pagination\">\n <VPagination\n v-model={ page.value }\n density=\"comfortable\"\n first-aria-label={ props.firstPageLabel }\n last-aria-label={ props.lastPageLabel }\n length={ pageCount.value }\n next-aria-label={ props.nextPageLabel }\n previous-aria-label={ props.prevPageLabel }\n rounded\n show-first-last-page\n total-visible={ props.showCurrentPage ? 1 : 0 }\n variant=\"plain\"\n { ...paginationProps }\n ></VPagination>\n </div>\n </div>\n )\n })\n\n return {}\n },\n})\n"],"mappings":";AAAA;AACA;;AAEA;AAAA,SACSA,WAAW;AAAA,SACXC,OAAO,gCAEhB;AAAA,SACSC,aAAa;AAAA,SACbC,SAAS;AAAA,SACTC,SAAS,wCAElB;AACA,SAASC,QAAQ,QAAQ,KAAK;AAAA,SACrBC,gBAAgB,EAAEC,YAAY,EAAEC,SAAS,gCAElD;AAGA,OAAO,MAAMC,yBAAyB,GAAGF,YAAY,CAAC;EACpDG,QAAQ,EAAE;IACRC,IAAI,EAAER,SAAS;IACfS,OAAO,EAAE;EACX,CAAC;EACDC,QAAQ,EAAE;IACRF,IAAI,EAAER,SAAS;IACfS,OAAO,EAAE;EACX,CAAC;EACDE,SAAS,EAAE;IACTH,IAAI,EAAER,SAAS;IACfS,OAAO,EAAE;EACX,CAAC;EACDG,QAAQ,EAAE;IACRJ,IAAI,EAAER,SAAS;IACfS,OAAO,EAAE;EACX,CAAC;EACDI,gBAAgB,EAAE;I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EAAEe,WAAW,CAACf,KAAK,CAAC,MAAAwB,YAAA;QAAA;MAAA,IAAAA,YAAA,CAAAjD,WAAA,EAAAoD,WAAA;QAAA,cAM5FhB,IAAI,CAACX,KAAK;QAAA,uBAAA4B,MAAA,IAAVjB,IAAI,CAACX,KAAK,GAAA4B,MAAA;QAAA;QAAA,oBAEDtB,KAAK,CAACZ,cAAc;QAAA,mBACrBY,KAAK,CAACT,aAAa;QAAA,UAC5Be,SAAS,CAACZ,KAAK;QAAA,mBACNM,KAAK,CAACV,aAAa;QAAA,uBACfU,KAAK,CAACX,aAAa;QAAA;QAAA;QAAA,iBAGzBW,KAAK,CAACJ,eAAe,GAAG,CAAC,GAAG,CAAC;QAAA;MAAA,GAExCoB,eAAe;IAK9B,CAAC,CAAC;IAEF,OAAO,CAAC,CAAC;EACX;AACF,CAAC,CAAC","ignoreList":[]}
|
|
1
|
+
{"version":3,"file":"VDataTableFooter.mjs","names":["VPagination","VSelect","usePagination","IconValue","useLocale","computed","genericComponent","propsFactory","useRender","makeVDataTableFooterProps","prevIcon","type","default","nextIcon","firstIcon","lastIcon","itemsPerPageText","String","pageText","firstPageLabel","prevPageLabel","nextPageLabel","lastPageLabel","itemsPerPageOptions","Array","value","title","showCurrentPage","Boolean","VDataTableFooter","name","props","setup","_ref","slots","t","page","pageCount","startIndex","stopIndex","itemsLength","itemsPerPage","setItemsPerPage","map","option","isNaN","Number","paginationProps","filterProps","_createVNode","prepend","v","_mergeProps","$event"],"sources":["../../../src/components/VDataTable/VDataTableFooter.tsx"],"sourcesContent":["// Styles\nimport './VDataTableFooter.sass'\n\n// Components\nimport { VPagination } from '@/components/VPagination'\nimport { VSelect } from '@/components/VSelect'\n\n// Composables\nimport { usePagination } from './composables/paginate'\nimport { IconValue } from '@/composables/icons'\nimport { useLocale } from '@/composables/locale'\n\n// Utilities\nimport { computed } from 'vue'\nimport { genericComponent, propsFactory, useRender } from '@/util'\n\n// Types\nimport type { PropType } from 'vue'\n\nexport const makeVDataTableFooterProps = propsFactory({\n prevIcon: {\n type: IconValue,\n default: '$prev',\n },\n nextIcon: {\n type: IconValue,\n default: '$next',\n },\n firstIcon: {\n type: IconValue,\n default: '$first',\n },\n lastIcon: {\n type: IconValue,\n default: '$last',\n },\n itemsPerPageText: {\n type: String,\n default: '$vuetify.dataFooter.itemsPerPageText',\n },\n pageText: {\n type: String,\n default: '$vuetify.dataFooter.pageText',\n },\n firstPageLabel: {\n type: String,\n default: '$vuetify.dataFooter.firstPage',\n },\n prevPageLabel: {\n type: String,\n default: '$vuetify.dataFooter.prevPage',\n },\n nextPageLabel: {\n type: String,\n default: '$vuetify.dataFooter.nextPage',\n },\n lastPageLabel: {\n type: String,\n default: '$vuetify.dataFooter.lastPage',\n },\n itemsPerPageOptions: {\n type: Array as PropType<readonly (number | { title: string, value: number })[]>,\n default: () => ([\n { value: 10, title: '10' },\n { value: 25, title: '25' },\n { value: 50, title: '50' },\n { value: 100, title: '100' },\n { value: -1, title: '$vuetify.dataFooter.itemsPerPageAll' },\n ]),\n },\n showCurrentPage: Boolean,\n}, 'VDataTableFooter')\n\nexport const VDataTableFooter = genericComponent<{ prepend: never }>()({\n name: 'VDataTableFooter',\n\n props: makeVDataTableFooterProps(),\n\n setup (props, { slots }) {\n const { t } = useLocale()\n const { page, pageCount, startIndex, stopIndex, itemsLength, itemsPerPage, setItemsPerPage } = usePagination()\n\n const itemsPerPageOptions = computed(() => (\n props.itemsPerPageOptions.map(option => {\n if (typeof option === 'number') {\n return {\n value: option,\n title: option === -1\n ? t('$vuetify.dataFooter.itemsPerPageAll')\n : String(option),\n }\n }\n\n return {\n ...option,\n title: !isNaN(Number(option.title)) ? option.title : t(option.title),\n }\n })\n ))\n\n useRender(() => {\n const paginationProps = VPagination.filterProps(props)\n\n return (\n <div class=\"v-data-table-footer\">\n { slots.prepend?.() }\n\n <div class=\"v-data-table-footer__items-per-page\">\n <span>{ t(props.itemsPerPageText) }</span>\n\n <VSelect\n items={ itemsPerPageOptions.value }\n modelValue={ itemsPerPage.value }\n onUpdate:modelValue={ v => setItemsPerPage(Number(v)) }\n density=\"compact\"\n variant=\"outlined\"\n hide-details\n />\n </div>\n\n <div class=\"v-data-table-footer__info\">\n <div>\n { t(props.pageText, !itemsLength.value ? 0 : startIndex.value + 1, stopIndex.value, itemsLength.value) }\n </div>\n </div>\n\n <div class=\"v-data-table-footer__pagination\">\n <VPagination\n v-model={ page.value }\n density=\"comfortable\"\n first-aria-label={ props.firstPageLabel }\n last-aria-label={ props.lastPageLabel }\n length={ pageCount.value }\n next-aria-label={ props.nextPageLabel }\n previous-aria-label={ props.prevPageLabel }\n rounded\n show-first-last-page\n total-visible={ props.showCurrentPage ? 1 : 0 }\n variant=\"plain\"\n { ...paginationProps }\n ></VPagination>\n </div>\n </div>\n )\n })\n\n return {}\n },\n})\n\nexport type VDataTableFooter = InstanceType<typeof VDataTableFooter>\n"],"mappings":";AAAA;AACA;;AAEA;AAAA,SACSA,WAAW;AAAA,SACXC,OAAO,gCAEhB;AAAA,SACSC,aAAa;AAAA,SACbC,SAAS;AAAA,SACTC,SAAS,wCAElB;AACA,SAASC,QAAQ,QAAQ,KAAK;AAAA,SACrBC,gBAAgB,EAAEC,YAAY,EAAEC,SAAS,gCAElD;AAGA,OAAO,MAAMC,yBAAyB,GAAGF,YAAY,CAAC;EACpDG,QAAQ,EAAE;IACRC,IAAI,EAAER,SAAS;IACfS,OAAO,EAAE;EACX,CAAC;EACDC,QAAQ,EAAE;IACRF,IAAI,EAAER,SAAS;IACfS,OAAO,EAAE;EACX,CAAC;EACDE,SAAS,EAAE;IACTH,IAAI,EAAER,SAAS;IACfS,OAAO,EAAE;EACX,CAAC;EACDG,QAAQ,EAAE;IACRJ,IAAI,EAAER,SAAS;IACfS,OAAO,EAAE;EACX,CAAC;EACDI,gBAAgB,EAAE;IAChBL,IAAI,EAAEM,MAAM;IACZL,OAAO,EAAE;EACX,CAAC;EACDM,QAAQ,EAAE;IACRP,IAAI,EAAEM,MAAM;IACZL,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,cAM5FhB,IAAI,CAACX,KAAK;QAAA,uBAAA4B,MAAA,IAAVjB,IAAI,CAACX,KAAK,GAAA4B,MAAA;QAAA;QAAA,oBAEDtB,KAAK,CAACZ,cAAc;QAAA,mBACrBY,KAAK,CAACT,aAAa;QAAA,UAC5Be,SAAS,CAACZ,KAAK;QAAA,mBACNM,KAAK,CAACV,aAAa;QAAA,uBACfU,KAAK,CAACX,aAAa;QAAA;QAAA;QAAA,iBAGzBW,KAAK,CAACJ,eAAe,GAAG,CAAC,GAAG,CAAC;QAAA;MAAA,GAExCoB,eAAe;IAK9B,CAAC,CAAC;IAEF,OAAO,CAAC,CAAC;EACX;AACF,CAAC,CAAC","ignoreList":[]}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// Composables
|
|
2
2
|
import { useProxiedModel } from "../../../composables/proxiedModel.mjs"; // Utilities
|
|
3
|
-
import { computed, inject, provide, watch
|
|
3
|
+
import { computed, inject, provide, watch } from 'vue';
|
|
4
4
|
import { clamp, getCurrentInstance, propsFactory } from "../../../util/index.mjs"; // Types
|
|
5
5
|
export const makeDataTablePaginateProps = propsFactory({
|
|
6
6
|
page: {
|
|
@@ -39,7 +39,9 @@ export function providePagination(options) {
|
|
|
39
39
|
if (itemsPerPage.value === -1 || itemsLength.value === 0) return 1;
|
|
40
40
|
return Math.ceil(itemsLength.value / itemsPerPage.value);
|
|
41
41
|
});
|
|
42
|
-
|
|
42
|
+
|
|
43
|
+
// Don't run immediately, items may not have been loaded yet: #17966
|
|
44
|
+
watch([page, pageCount], () => {
|
|
43
45
|
if (page.value > pageCount.value) {
|
|
44
46
|
page.value = pageCount.value;
|
|
45
47
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"paginate.mjs","names":["useProxiedModel","computed","inject","provide","watch","
|
|
1
|
+
{"version":3,"file":"paginate.mjs","names":["useProxiedModel","computed","inject","provide","watch","clamp","getCurrentInstance","propsFactory","makeDataTablePaginateProps","page","type","Number","String","default","itemsPerPage","VDataTablePaginationSymbol","Symbol","for","createPagination","props","undefined","value","providePagination","options","itemsLength","startIndex","stopIndex","Math","min","pageCount","ceil","setItemsPerPage","nextPage","prevPage","setPage","data","usePagination","Error","usePaginatedItems","vm","items","paginatedItems","slice","val","emit"],"sources":["../../../../src/components/VDataTable/composables/paginate.ts"],"sourcesContent":["// Composables\nimport { useProxiedModel } from '@/composables/proxiedModel'\n\n// Utilities\nimport { computed, inject, provide, watch } from 'vue'\nimport { clamp, getCurrentInstance, propsFactory } from '@/util'\n\n// Types\nimport type { InjectionKey, Ref } from 'vue'\nimport type { Group } from './group'\nimport type { EventProp } from '@/util'\n\nexport const makeDataTablePaginateProps = propsFactory({\n page: {\n type: [Number, String],\n default: 1,\n },\n itemsPerPage: {\n type: [Number, String],\n default: 10,\n },\n}, 'DataTable-paginate')\n\nconst VDataTablePaginationSymbol: InjectionKey<{\n page: Ref<number>\n itemsPerPage: Ref<number>\n startIndex: Ref<number>\n stopIndex: Ref<number>\n pageCount: Ref<number>\n itemsLength: Ref<number>\n prevPage: () => void\n nextPage: () => void\n setPage: (value: number) => void\n setItemsPerPage: (value: number) => void\n}> = Symbol.for('vuetify:data-table-pagination')\n\ntype PaginationProps = {\n page: number | string\n 'onUpdate:page': EventProp | undefined\n itemsPerPage: number | string\n 'onUpdate:itemsPerPage': EventProp | undefined\n itemsLength?: number | string\n}\n\nexport function createPagination (props: PaginationProps) {\n const page = useProxiedModel(props, 'page', undefined, value => +(value ?? 1))\n const itemsPerPage = useProxiedModel(props, 'itemsPerPage', undefined, value => +(value ?? 10))\n\n return { page, itemsPerPage }\n}\n\nexport function providePagination (options: {\n page: Ref<number>\n itemsPerPage: Ref<number>\n itemsLength: Ref<number>\n}) {\n const { page, itemsPerPage, itemsLength } = options\n\n const startIndex = computed(() => {\n if (itemsPerPage.value === -1) return 0\n\n return itemsPerPage.value * (page.value - 1)\n })\n const stopIndex = computed(() => {\n if (itemsPerPage.value === -1) return itemsLength.value\n\n return Math.min(itemsLength.value, startIndex.value + itemsPerPage.value)\n })\n\n const pageCount = computed(() => {\n if (itemsPerPage.value === -1 || itemsLength.value === 0) return 1\n\n return Math.ceil(itemsLength.value / itemsPerPage.value)\n })\n\n // Don't run immediately, items may not have been loaded yet: #17966\n watch([page, pageCount], () => {\n if (page.value > pageCount.value) {\n page.value = pageCount.value\n }\n })\n\n function setItemsPerPage (value: number) {\n itemsPerPage.value = value\n page.value = 1\n }\n\n function nextPage () {\n page.value = clamp(page.value + 1, 1, pageCount.value)\n }\n\n function prevPage () {\n page.value = clamp(page.value - 1, 1, pageCount.value)\n }\n\n function setPage (value: number) {\n page.value = clamp(value, 1, pageCount.value)\n }\n\n const data = { page, itemsPerPage, startIndex, stopIndex, pageCount, itemsLength, nextPage, prevPage, setPage, setItemsPerPage }\n\n provide(VDataTablePaginationSymbol, data)\n\n return data\n}\n\nexport function usePagination () {\n const data = inject(VDataTablePaginationSymbol)\n\n if (!data) throw new Error('Missing pagination!')\n\n return data\n}\n\nexport function usePaginatedItems <T> (options: {\n items: Ref<readonly (T | Group<T>)[]>\n startIndex: Ref<number>\n stopIndex: Ref<number>\n itemsPerPage: Ref<number>\n}) {\n const vm = getCurrentInstance('usePaginatedItems')\n\n const { items, startIndex, stopIndex, itemsPerPage } = options\n const paginatedItems = computed(() => {\n if (itemsPerPage.value <= 0) return items.value\n\n return items.value.slice(startIndex.value, stopIndex.value)\n })\n\n watch(paginatedItems, val => {\n vm.emit('update:currentItems', val)\n })\n\n return { paginatedItems }\n}\n"],"mappings":"AAAA;AAAA,SACSA,eAAe,iDAExB;AACA,SAASC,QAAQ,EAAEC,MAAM,EAAEC,OAAO,EAAEC,KAAK,QAAQ,KAAK;AAAA,SAC7CC,KAAK,EAAEC,kBAAkB,EAAEC,YAAY,mCAEhD;AAKA,OAAO,MAAMC,0BAA0B,GAAGD,YAAY,CAAC;EACrDE,IAAI,EAAE;IACJC,IAAI,EAAE,CAACC,MAAM,EAAEC,MAAM,CAAC;IACtBC,OAA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b;AAEA,OAAO,SAASC,aAAaA,CAAA,EAAI;EAC/B,MAAMD,IAAI,GAAGjC,MAAM,CAACa,0BAA0B,CAAC;EAE/C,IAAI,CAACoB,IAAI,EAAE,MAAM,IAAIE,KAAK,CAAC,qBAAqB,CAAC;EAEjD,OAAOF,IAAI;AACb;AAEA,OAAO,SAASG,iBAAiBA,CAAMf,OAKtC,EAAE;EACD,MAAMgB,EAAE,GAAGjC,kBAAkB,CAAC,mBAAmB,CAAC;EAElD,MAAM;IAAEkC,KAAK;IAAEf,UAAU;IAAEC,SAAS;IAAEZ;EAAa,CAAC,GAAGS,OAAO;EAC9D,MAAMkB,cAAc,GAAGxC,QAAQ,CAAC,MAAM;IACpC,IAAIa,YAAY,CAACO,KAAK,IAAI,CAAC,EAAE,OAAOmB,KAAK,CAACnB,KAAK;IAE/C,OAAOmB,KAAK,CAACnB,KAAK,CAACqB,KAAK,CAACjB,UAAU,CAACJ,KAAK,EAAEK,SAAS,CAACL,KAAK,CAAC;EAC7D,CAAC,CAAC;EAEFjB,KAAK,CAACqC,cAAc,EAAEE,GAAG,IAAI;IAC3BJ,EAAE,CAACK,IAAI,CAAC,qBAAqB,EAAED,GAAG,CAAC;EACrC,CAAC,CAAC;EAEF,OAAO;IAAEF;EAAe,CAAC;AAC3B","ignoreList":[]}
|
|
@@ -920,7 +920,7 @@ declare const VDataTable: {
|
|
|
920
920
|
'update:groupBy': (value: any) => true;
|
|
921
921
|
'update:expanded': (value: any) => true;
|
|
922
922
|
'update:currentItems': (value: any) => true;
|
|
923
|
-
}, "headers" | "$children" | "v-slots" | "v-slot:default" | "modelValue" | "
|
|
923
|
+
}, "headers" | "$children" | "v-slots" | "v-slot:default" | "modelValue" | "items" | "update:modelValue" | "v-slot:loader" | "v-slot:item" | "itemValue" | "v-slot:no-data" | "cellProps" | "itemSelectable" | "rowProps" | "v-slot:headers" | `v-slot:header.${string}` | "v-slot:data-table-group" | "v-slot:data-table-select" | `v-slot:item.${string}` | "v-slot:loading" | "v-slot:group-header" | "v-slot:expanded-row" | "v-slot:top" | "v-slot:bottom" | "v-slot:body" | "v-slot:colgroup" | "v-slot:tbody" | "v-slot:tfoot" | "v-slot:thead" | "v-slot:body.prepend" | "v-slot:body.append" | "v-slot:footer.prepend">, vue.VNodeProps & vue.AllowedComponentProps & vue.ComponentCustomProps & {
|
|
924
924
|
page: string | number;
|
|
925
925
|
expanded: readonly string[];
|
|
926
926
|
style: vue.StyleValue;
|
|
@@ -1291,7 +1291,7 @@ declare const VDataTable: {
|
|
|
1291
1291
|
'update:groupBy': (value: any) => true;
|
|
1292
1292
|
'update:expanded': (value: any) => true;
|
|
1293
1293
|
'update:currentItems': (value: any) => true;
|
|
1294
|
-
}, "headers" | "$children" | "v-slots" | "v-slot:default" | "modelValue" | "
|
|
1294
|
+
}, "headers" | "$children" | "v-slots" | "v-slot:default" | "modelValue" | "items" | "update:modelValue" | "v-slot:loader" | "v-slot:item" | "itemValue" | "v-slot:no-data" | "cellProps" | "itemSelectable" | "rowProps" | "v-slot:headers" | `v-slot:header.${string}` | "v-slot:data-table-group" | "v-slot:data-table-select" | `v-slot:item.${string}` | "v-slot:loading" | "v-slot:group-header" | "v-slot:expanded-row" | "v-slot:top" | "v-slot:bottom" | "v-slot:body" | "v-slot:colgroup" | "v-slot:tbody" | "v-slot:tfoot" | "v-slot:thead" | "v-slot:body.prepend" | "v-slot:body.append" | "v-slot:footer.prepend">, string, {
|
|
1295
1295
|
page: string | number;
|
|
1296
1296
|
expanded: readonly string[];
|
|
1297
1297
|
style: vue.StyleValue;
|
|
@@ -1999,6 +1999,7 @@ declare const VDataTableFooter: {
|
|
|
1999
1999
|
};
|
|
2000
2000
|
showCurrentPage: BooleanConstructor;
|
|
2001
2001
|
}>>;
|
|
2002
|
+
type VDataTableFooter = InstanceType<typeof VDataTableFooter>;
|
|
2002
2003
|
|
|
2003
2004
|
type VDataTableVirtualSlotProps<T> = Omit<VDataTableSlotProps<T>, 'setItemsPerPage' | 'page' | 'pageCount' | 'itemsPerPage'>;
|
|
2004
2005
|
type VDataTableVirtualSlots<T> = VDataTableRowsSlots<T> & VDataTableHeadersSlots & {
|
|
@@ -2116,7 +2117,7 @@ declare const VDataTableVirtual: {
|
|
|
2116
2117
|
'update:options': (value: any) => true;
|
|
2117
2118
|
'update:groupBy': (value: any) => true;
|
|
2118
2119
|
'update:expanded': (value: any) => true;
|
|
2119
|
-
}, "$children" | "v-slots" | "modelValue" | "
|
|
2120
|
+
}, "$children" | "v-slots" | "modelValue" | "items" | "update:modelValue" | "v-slot:loader" | "v-slot:item" | "itemValue" | "v-slot:no-data" | "cellProps" | "itemSelectable" | "rowProps" | "v-slot:headers" | `v-slot:header.${string}` | "v-slot:data-table-group" | "v-slot:data-table-select" | `v-slot:item.${string}` | "v-slot:loading" | "v-slot:group-header" | "v-slot:expanded-row" | "v-slot:top" | "v-slot:bottom" | "v-slot:colgroup" | "v-slot:body.prepend" | "v-slot:body.append">, vue.VNodeProps & vue.AllowedComponentProps & vue.ComponentCustomProps & {
|
|
2120
2121
|
expanded: readonly string[];
|
|
2121
2122
|
style: vue.StyleValue;
|
|
2122
2123
|
mobile: boolean | null;
|
|
@@ -2526,7 +2527,7 @@ declare const VDataTableVirtual: {
|
|
|
2526
2527
|
'update:options': (value: any) => true;
|
|
2527
2528
|
'update:groupBy': (value: any) => true;
|
|
2528
2529
|
'update:expanded': (value: any) => true;
|
|
2529
|
-
}, "$children" | "v-slots" | "modelValue" | "
|
|
2530
|
+
}, "$children" | "v-slots" | "modelValue" | "items" | "update:modelValue" | "v-slot:loader" | "v-slot:item" | "itemValue" | "v-slot:no-data" | "cellProps" | "itemSelectable" | "rowProps" | "v-slot:headers" | `v-slot:header.${string}` | "v-slot:data-table-group" | "v-slot:data-table-select" | `v-slot:item.${string}` | "v-slot:loading" | "v-slot:group-header" | "v-slot:expanded-row" | "v-slot:top" | "v-slot:bottom" | "v-slot:colgroup" | "v-slot:body.prepend" | "v-slot:body.append">, string, {
|
|
2530
2531
|
expanded: readonly string[];
|
|
2531
2532
|
style: vue.StyleValue;
|
|
2532
2533
|
mobile: boolean | null;
|
|
@@ -2954,7 +2955,7 @@ declare const VDataTableServer: {
|
|
|
2954
2955
|
'update:options': (options: any) => true;
|
|
2955
2956
|
'update:expanded': (options: any) => true;
|
|
2956
2957
|
'update:groupBy': (value: any) => true;
|
|
2957
|
-
}, "$children" | "v-slots" | "v-slot:default" | "modelValue" | "
|
|
2958
|
+
}, "$children" | "v-slots" | "v-slot:default" | "modelValue" | "items" | "update:modelValue" | "v-slot:loader" | "v-slot:item" | "itemValue" | "v-slot:no-data" | "cellProps" | "itemSelectable" | "rowProps" | "v-slot:headers" | `v-slot:header.${string}` | "v-slot:data-table-group" | "v-slot:data-table-select" | `v-slot:item.${string}` | "v-slot:loading" | "v-slot:group-header" | "v-slot:expanded-row" | "v-slot:top" | "v-slot:bottom" | "v-slot:body" | "v-slot:colgroup" | "v-slot:tbody" | "v-slot:tfoot" | "v-slot:thead" | "v-slot:body.prepend" | "v-slot:body.append" | "v-slot:footer.prepend">, vue.VNodeProps & vue.AllowedComponentProps & vue.ComponentCustomProps & {
|
|
2958
2959
|
page: string | number;
|
|
2959
2960
|
expanded: readonly string[];
|
|
2960
2961
|
style: vue.StyleValue;
|
|
@@ -3440,7 +3441,7 @@ declare const VDataTableServer: {
|
|
|
3440
3441
|
'update:options': (options: any) => true;
|
|
3441
3442
|
'update:expanded': (options: any) => true;
|
|
3442
3443
|
'update:groupBy': (value: any) => true;
|
|
3443
|
-
}, "$children" | "v-slots" | "v-slot:default" | "modelValue" | "
|
|
3444
|
+
}, "$children" | "v-slots" | "v-slot:default" | "modelValue" | "items" | "update:modelValue" | "v-slot:loader" | "v-slot:item" | "itemValue" | "v-slot:no-data" | "cellProps" | "itemSelectable" | "rowProps" | "v-slot:headers" | `v-slot:header.${string}` | "v-slot:data-table-group" | "v-slot:data-table-select" | `v-slot:item.${string}` | "v-slot:loading" | "v-slot:group-header" | "v-slot:expanded-row" | "v-slot:top" | "v-slot:bottom" | "v-slot:body" | "v-slot:colgroup" | "v-slot:tbody" | "v-slot:tfoot" | "v-slot:thead" | "v-slot:body.prepend" | "v-slot:body.append" | "v-slot:footer.prepend">, string, {
|
|
3444
3445
|
page: string | number;
|
|
3445
3446
|
expanded: readonly string[];
|
|
3446
3447
|
style: vue.StyleValue;
|