quasar 2.14.1 → 2.14.3
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/api/Notify.json +2 -2
- package/dist/icon-set/bootstrap-icons.umd.prod.js +1 -1
- package/dist/icon-set/eva-icons.umd.prod.js +1 -1
- package/dist/icon-set/fontawesome-v5-pro.umd.prod.js +1 -1
- package/dist/icon-set/fontawesome-v5.umd.prod.js +1 -1
- package/dist/icon-set/fontawesome-v6-pro.umd.prod.js +1 -1
- package/dist/icon-set/fontawesome-v6.umd.prod.js +1 -1
- package/dist/icon-set/ionicons-v4.umd.prod.js +1 -1
- package/dist/icon-set/line-awesome.umd.prod.js +1 -1
- package/dist/icon-set/material-icons-outlined.umd.prod.js +1 -1
- package/dist/icon-set/material-icons-round.umd.prod.js +1 -1
- package/dist/icon-set/material-icons-sharp.umd.prod.js +1 -1
- package/dist/icon-set/material-icons.umd.prod.js +1 -1
- package/dist/icon-set/material-symbols-outlined.umd.prod.js +1 -1
- package/dist/icon-set/material-symbols-rounded.umd.prod.js +1 -1
- package/dist/icon-set/material-symbols-sharp.umd.prod.js +1 -1
- package/dist/icon-set/mdi-v3.umd.prod.js +1 -1
- package/dist/icon-set/mdi-v4.umd.prod.js +1 -1
- package/dist/icon-set/mdi-v5.umd.prod.js +1 -1
- package/dist/icon-set/mdi-v6.umd.prod.js +1 -1
- package/dist/icon-set/mdi-v7.umd.prod.js +1 -1
- package/dist/icon-set/svg-bootstrap-icons.umd.prod.js +2 -2
- package/dist/icon-set/svg-eva-icons.umd.prod.js +1 -1
- package/dist/icon-set/svg-fontawesome-v5.umd.prod.js +1 -1
- package/dist/icon-set/svg-fontawesome-v6.umd.prod.js +1 -1
- package/dist/icon-set/svg-ionicons-v4.umd.prod.js +1 -1
- package/dist/icon-set/svg-ionicons-v5.umd.prod.js +1 -1
- package/dist/icon-set/svg-ionicons-v6.umd.prod.js +1 -1
- package/dist/icon-set/svg-line-awesome.umd.prod.js +1 -1
- package/dist/icon-set/svg-material-icons-outlined.umd.prod.js +1 -1
- package/dist/icon-set/svg-material-icons-round.umd.prod.js +1 -1
- package/dist/icon-set/svg-material-icons-sharp.umd.prod.js +1 -1
- package/dist/icon-set/svg-material-icons.umd.prod.js +1 -1
- package/dist/icon-set/svg-material-symbols-outlined.umd.prod.js +1 -1
- package/dist/icon-set/svg-material-symbols-rounded.umd.prod.js +1 -1
- package/dist/icon-set/svg-material-symbols-sharp.umd.prod.js +1 -1
- package/dist/icon-set/svg-mdi-v6.umd.prod.js +1 -1
- package/dist/icon-set/svg-mdi-v7.umd.prod.js +1 -1
- package/dist/icon-set/svg-themify.umd.prod.js +1 -1
- package/dist/icon-set/themify.umd.prod.js +1 -1
- package/dist/lang/ar-TN.umd.prod.js +1 -1
- package/dist/lang/ar.umd.prod.js +1 -1
- package/dist/lang/az-Latn.umd.prod.js +1 -1
- package/dist/lang/bg.umd.prod.js +1 -1
- package/dist/lang/bn.umd.prod.js +1 -1
- package/dist/lang/ca.umd.prod.js +1 -1
- package/dist/lang/cs.umd.prod.js +1 -1
- package/dist/lang/da.umd.prod.js +1 -1
- package/dist/lang/de-CH.umd.prod.js +1 -1
- package/dist/lang/de-DE.umd.prod.js +1 -1
- package/dist/lang/de.umd.prod.js +1 -1
- package/dist/lang/el.umd.prod.js +1 -1
- package/dist/lang/en-GB.umd.prod.js +1 -1
- package/dist/lang/en-US.umd.prod.js +1 -1
- package/dist/lang/eo.umd.prod.js +1 -1
- package/dist/lang/es.umd.prod.js +1 -1
- package/dist/lang/et.umd.prod.js +1 -1
- package/dist/lang/eu.umd.prod.js +1 -1
- package/dist/lang/fa-IR.umd.prod.js +1 -1
- package/dist/lang/fa.umd.prod.js +1 -1
- package/dist/lang/fi.umd.prod.js +1 -1
- package/dist/lang/fr.umd.prod.js +1 -1
- package/dist/lang/gn.umd.prod.js +1 -1
- package/dist/lang/he.umd.prod.js +1 -1
- package/dist/lang/hi.umd.prod.js +1 -1
- package/dist/lang/hr.umd.prod.js +1 -1
- package/dist/lang/hu.umd.prod.js +1 -1
- package/dist/lang/id.umd.prod.js +1 -1
- package/dist/lang/is.umd.prod.js +1 -1
- package/dist/lang/it.umd.prod.js +1 -1
- package/dist/lang/ja.umd.prod.js +1 -1
- package/dist/lang/kk.umd.prod.js +1 -1
- package/dist/lang/km.umd.prod.js +1 -1
- package/dist/lang/ko-KR.umd.prod.js +1 -1
- package/dist/lang/kur-CKB.umd.prod.js +1 -1
- package/dist/lang/lt.umd.prod.js +1 -1
- package/dist/lang/lu.umd.prod.js +1 -1
- package/dist/lang/lv.umd.prod.js +1 -1
- package/dist/lang/mk.umd.prod.js +1 -1
- package/dist/lang/ml.umd.prod.js +1 -1
- package/dist/lang/mm.umd.prod.js +1 -1
- package/dist/lang/ms.umd.prod.js +1 -1
- package/dist/lang/my.umd.prod.js +1 -1
- package/dist/lang/nb-NO.umd.prod.js +1 -1
- package/dist/lang/nl.umd.prod.js +1 -1
- package/dist/lang/pl.umd.prod.js +1 -1
- package/dist/lang/pt-BR.umd.prod.js +1 -1
- package/dist/lang/pt.umd.prod.js +1 -1
- package/dist/lang/ro.umd.prod.js +1 -1
- package/dist/lang/ru.umd.prod.js +1 -1
- package/dist/lang/sk.umd.prod.js +1 -1
- package/dist/lang/sl.umd.prod.js +1 -1
- package/dist/lang/sm.umd.prod.js +1 -1
- package/dist/lang/sr-CYR.umd.prod.js +1 -1
- package/dist/lang/sr.umd.prod.js +1 -1
- package/dist/lang/sv.umd.prod.js +1 -1
- package/dist/lang/ta.umd.prod.js +1 -1
- package/dist/lang/th.umd.prod.js +1 -1
- package/dist/lang/tr.umd.prod.js +1 -1
- package/dist/lang/ug.umd.prod.js +1 -1
- package/dist/lang/uk.umd.prod.js +1 -1
- package/dist/lang/uz-Cyrl.umd.prod.js +1 -1
- package/dist/lang/uz-Latn.umd.prod.js +1 -1
- package/dist/lang/vi.umd.prod.js +1 -1
- package/dist/lang/zh-CN.umd.prod.js +1 -1
- package/dist/lang/zh-TW.umd.prod.js +1 -1
- package/dist/quasar.cjs.prod.js +2 -2
- package/dist/quasar.esm.js +153 -146
- package/dist/quasar.esm.prod.js +2 -2
- package/dist/quasar.sass +1 -1
- package/dist/quasar.umd.js +153 -146
- package/dist/quasar.umd.prod.js +2 -2
- package/dist/types/index.d.ts +2 -2
- package/dist/web-types/web-types.json +1 -1
- package/package.json +2 -2
- package/src/components/ajax-bar/QAjaxBar.js +12 -2
- package/src/components/btn-dropdown/QBtnDropdown.js +4 -4
- package/src/components/color/QColor.js +5 -9
- package/src/components/date/QDate.js +1 -1
- package/src/components/editor/QEditor.js +1 -1
- package/src/components/expansion-item/QExpansionItem.js +4 -3
- package/src/components/fab/QFab.js +4 -4
- package/src/components/icon/QIcon.js +3 -3
- package/src/components/infinite-scroll/QInfiniteScroll.js +1 -1
- package/src/components/menu/__tests__/QMenu.cy.js +24 -0
- package/src/components/range/QRange.js +8 -8
- package/src/components/resize-observer/QResizeObserver.js +3 -3
- package/src/components/slider/QSlider.js +2 -2
- package/src/components/slider/use-slider.js +14 -8
- package/src/components/tabs/use-tab.js +1 -1
- package/src/composables/private/use-field.js +13 -33
- package/src/composables/private/use-id.js +34 -0
- package/src/composables/private/use-validate.js +41 -35
- package/src/plugins/Dark.js +3 -27
- package/src/plugins/Notify.js +4 -3
- package/src/plugins/Notify.json +2 -2
- package/src/utils/copy-to-clipboard.js +0 -1
- package/src/utils/get-css-var.js +0 -1
- package/src/utils/is.js +0 -1
- package/src/utils/private/define-reactive-plugin.js +0 -1
- package/src/utils/private/global-config.js +0 -1
- package/src/utils/private/touch.js +0 -1
- package/src/utils/private/vm.js +0 -1
- package/src/utils/run-sequential-promises.js +0 -1
package/dist/quasar.esm.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* Quasar Framework v2.14.
|
|
2
|
+
* Quasar Framework v2.14.3
|
|
3
3
|
* (c) 2015-present Razvan Stoenescu
|
|
4
4
|
* Released under the MIT License.
|
|
5
5
|
*/
|
|
@@ -796,36 +796,13 @@ const Plugin$9 = defineReactivePlugin({
|
|
|
796
796
|
}
|
|
797
797
|
},
|
|
798
798
|
|
|
799
|
-
install ({ $q,
|
|
799
|
+
install ({ $q, ssrContext }) {
|
|
800
800
|
const { dark } = $q.config;
|
|
801
801
|
|
|
802
802
|
$q.dark = this;
|
|
803
803
|
|
|
804
|
-
if (this.__installed
|
|
805
|
-
|
|
806
|
-
}
|
|
807
|
-
|
|
808
|
-
this.isActive = dark === true;
|
|
809
|
-
|
|
810
|
-
const initialVal = dark !== void 0 ? dark : false;
|
|
811
|
-
|
|
812
|
-
if (isRuntimeSsrPreHydration.value === true) {
|
|
813
|
-
const ssrSet = val => {
|
|
814
|
-
this.__fromSSR = val;
|
|
815
|
-
};
|
|
816
|
-
|
|
817
|
-
const originalSet = this.set;
|
|
818
|
-
|
|
819
|
-
this.set = ssrSet;
|
|
820
|
-
ssrSet(initialVal);
|
|
821
|
-
|
|
822
|
-
onSSRHydrated.push(() => {
|
|
823
|
-
this.set = originalSet;
|
|
824
|
-
this.set(this.__fromSSR);
|
|
825
|
-
});
|
|
826
|
-
}
|
|
827
|
-
else {
|
|
828
|
-
this.set(initialVal);
|
|
804
|
+
if (this.__installed !== true) {
|
|
805
|
+
this.set(dark !== void 0 ? dark : false);
|
|
829
806
|
}
|
|
830
807
|
}
|
|
831
808
|
});
|
|
@@ -1651,7 +1628,7 @@ function prepareApp (app, uiOpts, pluginOpts) {
|
|
|
1651
1628
|
}
|
|
1652
1629
|
|
|
1653
1630
|
var installQuasar = function (parentApp, opts = {}) {
|
|
1654
|
-
const $q = { version: '2.14.
|
|
1631
|
+
const $q = { version: '2.14.3' };
|
|
1655
1632
|
|
|
1656
1633
|
if (globalConfigIsFrozen === false) {
|
|
1657
1634
|
if (opts.config !== void 0) {
|
|
@@ -1915,13 +1892,23 @@ var QAjaxBar = createComponent({
|
|
|
1915
1892
|
|
|
1916
1893
|
progress.value = 0;
|
|
1917
1894
|
|
|
1895
|
+
/**
|
|
1896
|
+
* We're trying to avoid side effects if start() is called inside a watchEffect()
|
|
1897
|
+
* so we're accessing the _value property directly (under the covers implementation detail of ref())
|
|
1898
|
+
*
|
|
1899
|
+
* Otherwise, any refs() accessed here would be marked as deps for the watchEffect()
|
|
1900
|
+
* -- and we are changing them below, which would cause an infinite loop
|
|
1901
|
+
*/
|
|
1902
|
+
|
|
1918
1903
|
timer = setTimeout(() => {
|
|
1919
1904
|
timer = null;
|
|
1920
1905
|
animate.value = true;
|
|
1921
1906
|
newSpeed > 0 && planNextStep();
|
|
1922
|
-
|
|
1907
|
+
// eslint-disable-next-line vue/no-ref-as-operand
|
|
1908
|
+
}, onScreen._value === true ? 500 : 1);
|
|
1923
1909
|
|
|
1924
|
-
|
|
1910
|
+
// eslint-disable-next-line vue/no-ref-as-operand
|
|
1911
|
+
if (onScreen._value !== true) {
|
|
1925
1912
|
onScreen.value = true;
|
|
1926
1913
|
animate.value = false;
|
|
1927
1914
|
}
|
|
@@ -2280,13 +2267,13 @@ var QIcon = createComponent({
|
|
|
2280
2267
|
}
|
|
2281
2268
|
|
|
2282
2269
|
if (type.value.img === true) {
|
|
2283
|
-
return h(
|
|
2270
|
+
return h(props.tag, data, hMergeSlot(slots.default, [
|
|
2284
2271
|
h('img', { src: type.value.src })
|
|
2285
2272
|
]))
|
|
2286
2273
|
}
|
|
2287
2274
|
|
|
2288
2275
|
if (type.value.svg === true) {
|
|
2289
|
-
return h(
|
|
2276
|
+
return h(props.tag, data, hMergeSlot(slots.default, [
|
|
2290
2277
|
h('svg', {
|
|
2291
2278
|
viewBox: type.value.viewBox || '0 0 24 24'
|
|
2292
2279
|
}, type.value.nodes)
|
|
@@ -2294,7 +2281,7 @@ var QIcon = createComponent({
|
|
|
2294
2281
|
}
|
|
2295
2282
|
|
|
2296
2283
|
if (type.value.svguse === true) {
|
|
2297
|
-
return h(
|
|
2284
|
+
return h(props.tag, data, hMergeSlot(slots.default, [
|
|
2298
2285
|
h('svg', {
|
|
2299
2286
|
viewBox: type.value.viewBox
|
|
2300
2287
|
}, [
|
|
@@ -5862,6 +5849,35 @@ function uid$3 () {
|
|
|
5862
5849
|
+ hexBytes[ b[ 14 ] ] + hexBytes[ b[ 15 ] ]
|
|
5863
5850
|
}
|
|
5864
5851
|
|
|
5852
|
+
function getId (val, requiredId) {
|
|
5853
|
+
return val === void 0
|
|
5854
|
+
? (requiredId === true ? `f_${ uid$3() }` : void 0)
|
|
5855
|
+
: val
|
|
5856
|
+
}
|
|
5857
|
+
|
|
5858
|
+
/**
|
|
5859
|
+
* Returns an "id" which is a ref() that can be used as a unique identifier.
|
|
5860
|
+
* On SSR, it takes care of generating the id on the client side (only) to
|
|
5861
|
+
* avoid hydration errors.
|
|
5862
|
+
*/
|
|
5863
|
+
function useId (initialId, requiredId = true) {
|
|
5864
|
+
if (isRuntimeSsrPreHydration.value === true) {
|
|
5865
|
+
const id = ref(initialId);
|
|
5866
|
+
|
|
5867
|
+
if (requiredId === true && initialId === void 0) {
|
|
5868
|
+
onMounted(() => {
|
|
5869
|
+
id.value = `f_${ uid$3() }`; // getId(void 0, true)
|
|
5870
|
+
});
|
|
5871
|
+
}
|
|
5872
|
+
|
|
5873
|
+
return id
|
|
5874
|
+
}
|
|
5875
|
+
|
|
5876
|
+
return ref(
|
|
5877
|
+
getId(initialId, requiredId)
|
|
5878
|
+
)
|
|
5879
|
+
}
|
|
5880
|
+
|
|
5865
5881
|
const btnPropsList = Object.keys(useBtnProps);
|
|
5866
5882
|
|
|
5867
5883
|
const passBtnProps = props => btnPropsList.reduce(
|
|
@@ -5919,13 +5935,13 @@ var QBtnDropdown = createComponent({
|
|
|
5919
5935
|
|
|
5920
5936
|
const showing = ref(props.modelValue);
|
|
5921
5937
|
const menuRef = ref(null);
|
|
5922
|
-
const targetUid =
|
|
5938
|
+
const targetUid = useId();
|
|
5923
5939
|
|
|
5924
5940
|
const ariaAttrs = computed(() => {
|
|
5925
5941
|
const acc = {
|
|
5926
5942
|
'aria-expanded': showing.value === true ? 'true' : 'false',
|
|
5927
5943
|
'aria-haspopup': 'true',
|
|
5928
|
-
'aria-controls': targetUid,
|
|
5944
|
+
'aria-controls': targetUid.value,
|
|
5929
5945
|
'aria-label': props.toggleAriaLabel || proxy.$q.lang.label[ showing.value === true ? 'collapse' : 'expand' ](props.label)
|
|
5930
5946
|
};
|
|
5931
5947
|
|
|
@@ -6019,7 +6035,7 @@ var QBtnDropdown = createComponent({
|
|
|
6019
6035
|
props.disableDropdown !== true && Arrow.push(
|
|
6020
6036
|
h(QMenu, {
|
|
6021
6037
|
ref: menuRef,
|
|
6022
|
-
id: targetUid,
|
|
6038
|
+
id: targetUid.value,
|
|
6023
6039
|
class: props.contentClass,
|
|
6024
6040
|
style: props.contentStyle,
|
|
6025
6041
|
cover: props.cover,
|
|
@@ -8835,8 +8851,16 @@ function useSlider ({ updateValue, updatePosition, getDragging, formAttrs }) {
|
|
|
8835
8851
|
&& innerMin.value < innerMax.value
|
|
8836
8852
|
));
|
|
8837
8853
|
|
|
8838
|
-
const
|
|
8839
|
-
|
|
8854
|
+
const roundValueFn = computed(() => {
|
|
8855
|
+
if (props.step === 0) {
|
|
8856
|
+
return v => v
|
|
8857
|
+
}
|
|
8858
|
+
|
|
8859
|
+
const decimals = (String(props.step).trim().split('.')[ 1 ] || '').length;
|
|
8860
|
+
return v => parseFloat(v.toFixed(decimals))
|
|
8861
|
+
});
|
|
8862
|
+
|
|
8863
|
+
const keyStep = computed(() => (props.step === 0 ? 1 : props.step));
|
|
8840
8864
|
const tabindex = computed(() => (editable.value === true ? props.tabindex || 0 : -1));
|
|
8841
8865
|
|
|
8842
8866
|
const trackLen = computed(() => props.max - props.min);
|
|
@@ -8948,9 +8972,7 @@ function useSlider ({ updateValue, updatePosition, getDragging, formAttrs }) {
|
|
|
8948
8972
|
model += (Math.abs(modulo) >= step / 2 ? (modulo < 0 ? -1 : 1) * step : 0) - modulo;
|
|
8949
8973
|
}
|
|
8950
8974
|
|
|
8951
|
-
|
|
8952
|
-
model = parseFloat(model.toFixed(decimals.value));
|
|
8953
|
-
}
|
|
8975
|
+
model = roundValueFn.value(model);
|
|
8954
8976
|
|
|
8955
8977
|
return between(model, innerMin.value, innerMax.value)
|
|
8956
8978
|
}
|
|
@@ -8976,7 +8998,7 @@ function useSlider ({ updateValue, updatePosition, getDragging, formAttrs }) {
|
|
|
8976
8998
|
}
|
|
8977
8999
|
|
|
8978
9000
|
const markerStep = computed(() => (
|
|
8979
|
-
isNumber(props.markers) === true ? props.markers :
|
|
9001
|
+
isNumber(props.markers) === true ? props.markers : keyStep.value)
|
|
8980
9002
|
);
|
|
8981
9003
|
|
|
8982
9004
|
const markerTicks = computed(() => {
|
|
@@ -9336,8 +9358,8 @@ function useSlider ({ updateValue, updatePosition, getDragging, formAttrs }) {
|
|
|
9336
9358
|
tabindex,
|
|
9337
9359
|
attributes,
|
|
9338
9360
|
|
|
9339
|
-
|
|
9340
|
-
|
|
9361
|
+
roundValueFn,
|
|
9362
|
+
keyStep,
|
|
9341
9363
|
trackLen,
|
|
9342
9364
|
innerMin,
|
|
9343
9365
|
innerMinRatio,
|
|
@@ -9483,7 +9505,7 @@ var QSlider = createComponent({
|
|
|
9483
9505
|
stopAndPrevent(evt);
|
|
9484
9506
|
|
|
9485
9507
|
const
|
|
9486
|
-
stepVal = ([ 34, 33 ].includes(evt.keyCode) ? 10 : 1) * state.
|
|
9508
|
+
stepVal = ([ 34, 33 ].includes(evt.keyCode) ? 10 : 1) * state.keyStep.value,
|
|
9487
9509
|
offset = (
|
|
9488
9510
|
([ 34, 37, 40 ].includes(evt.keyCode) ? -1 : 1)
|
|
9489
9511
|
* (state.isReversed.value === true ? -1 : 1)
|
|
@@ -9491,7 +9513,7 @@ var QSlider = createComponent({
|
|
|
9491
9513
|
);
|
|
9492
9514
|
|
|
9493
9515
|
model.value = between(
|
|
9494
|
-
|
|
9516
|
+
state.roundValueFn.value(model.value + offset),
|
|
9495
9517
|
state.innerMin.value,
|
|
9496
9518
|
state.innerMax.value
|
|
9497
9519
|
);
|
|
@@ -9580,6 +9602,9 @@ var QResizeObserver = createComponent({
|
|
|
9580
9602
|
|
|
9581
9603
|
const { proxy } = getCurrentInstance();
|
|
9582
9604
|
|
|
9605
|
+
// expose public method
|
|
9606
|
+
proxy.trigger = trigger;
|
|
9607
|
+
|
|
9583
9608
|
if (hasObserver === true) {
|
|
9584
9609
|
let observer;
|
|
9585
9610
|
|
|
@@ -9653,9 +9678,6 @@ var QResizeObserver = createComponent({
|
|
|
9653
9678
|
|
|
9654
9679
|
onBeforeUnmount(cleanup);
|
|
9655
9680
|
|
|
9656
|
-
// expose public method
|
|
9657
|
-
proxy.trigger = trigger;
|
|
9658
|
-
|
|
9659
9681
|
return () => {
|
|
9660
9682
|
if (canRender.value === true) {
|
|
9661
9683
|
return h('object', {
|
|
@@ -10500,7 +10522,7 @@ function useTab (props, slots, emit, routeData) {
|
|
|
10500
10522
|
if (
|
|
10501
10523
|
hardError === void 0 && (
|
|
10502
10524
|
softError === void 0
|
|
10503
|
-
|| softError.message.startsWith('Avoided redundant navigation') === true
|
|
10525
|
+
|| (softError.message !== void 0 && softError.message.startsWith('Avoided redundant navigation') === true)
|
|
10504
10526
|
)
|
|
10505
10527
|
) {
|
|
10506
10528
|
$tabs.updateModel({ name: props.name });
|
|
@@ -11177,15 +11199,11 @@ var QColor = createComponent({
|
|
|
11177
11199
|
+ (isDark.value === true ? ' q-color-picker--dark q-dark' : '')
|
|
11178
11200
|
);
|
|
11179
11201
|
|
|
11180
|
-
const attributes = computed(() =>
|
|
11181
|
-
|
|
11182
|
-
|
|
11183
|
-
|
|
11184
|
-
|
|
11185
|
-
return { 'aria-readonly': 'true' }
|
|
11186
|
-
}
|
|
11187
|
-
return {}
|
|
11188
|
-
});
|
|
11202
|
+
const attributes = computed(() => (
|
|
11203
|
+
props.disable === true
|
|
11204
|
+
? { 'aria-disabled': 'true' }
|
|
11205
|
+
: {}
|
|
11206
|
+
));
|
|
11189
11207
|
|
|
11190
11208
|
const spectrumDirective = computed(() => {
|
|
11191
11209
|
// if editable.value === true
|
|
@@ -13895,7 +13913,7 @@ var QDate = createComponent({
|
|
|
13895
13913
|
const attributes = computed(() => (
|
|
13896
13914
|
props.disable === true
|
|
13897
13915
|
? { 'aria-disabled': 'true' }
|
|
13898
|
-
:
|
|
13916
|
+
: {}
|
|
13899
13917
|
));
|
|
13900
13918
|
|
|
13901
13919
|
watch(() => props.modelValue, v => {
|
|
@@ -17543,7 +17561,7 @@ var QEditor = createComponent({
|
|
|
17543
17561
|
const attributes = computed(() => (
|
|
17544
17562
|
props.disable === true
|
|
17545
17563
|
? { 'aria-disabled': 'true' }
|
|
17546
|
-
:
|
|
17564
|
+
: {}
|
|
17547
17565
|
));
|
|
17548
17566
|
|
|
17549
17567
|
function onInput () {
|
|
@@ -18070,7 +18088,7 @@ var QExpansionItem = createComponent({
|
|
|
18070
18088
|
);
|
|
18071
18089
|
|
|
18072
18090
|
const blurTargetRef = ref(null);
|
|
18073
|
-
const targetUid =
|
|
18091
|
+
const targetUid = useId();
|
|
18074
18092
|
|
|
18075
18093
|
const { show, hide, toggle } = useModelToggle({ showing });
|
|
18076
18094
|
|
|
@@ -18138,7 +18156,7 @@ var QExpansionItem = createComponent({
|
|
|
18138
18156
|
return {
|
|
18139
18157
|
role: 'button',
|
|
18140
18158
|
'aria-expanded': showing.value === true ? 'true' : 'false',
|
|
18141
|
-
'aria-controls': targetUid,
|
|
18159
|
+
'aria-controls': targetUid.value,
|
|
18142
18160
|
'aria-label': toggleAriaLabel
|
|
18143
18161
|
}
|
|
18144
18162
|
});
|
|
@@ -18315,7 +18333,7 @@ var QExpansionItem = createComponent({
|
|
|
18315
18333
|
key: 'e-content',
|
|
18316
18334
|
class: 'q-expansion-item__content relative-position',
|
|
18317
18335
|
style: contentStyle.value,
|
|
18318
|
-
id: targetUid
|
|
18336
|
+
id: targetUid.value
|
|
18319
18337
|
}, hSlot(slots.default)),
|
|
18320
18338
|
[ [
|
|
18321
18339
|
vShow,
|
|
@@ -18490,7 +18508,7 @@ var QFab = createComponent({
|
|
|
18490
18508
|
setup (props, { slots }) {
|
|
18491
18509
|
const triggerRef = ref(null);
|
|
18492
18510
|
const showing = ref(props.modelValue === true);
|
|
18493
|
-
const targetUid =
|
|
18511
|
+
const targetUid = useId();
|
|
18494
18512
|
|
|
18495
18513
|
const { proxy: { $q } } = getCurrentInstance();
|
|
18496
18514
|
const { formClass, labelProps } = useFab(props, showing);
|
|
@@ -18518,7 +18536,7 @@ var QFab = createComponent({
|
|
|
18518
18536
|
|
|
18519
18537
|
const actionAttrs = computed(() => {
|
|
18520
18538
|
const attrs = {
|
|
18521
|
-
id: targetUid,
|
|
18539
|
+
id: targetUid.value,
|
|
18522
18540
|
role: 'menu'
|
|
18523
18541
|
};
|
|
18524
18542
|
|
|
@@ -18590,7 +18608,7 @@ var QFab = createComponent({
|
|
|
18590
18608
|
fab: true,
|
|
18591
18609
|
'aria-expanded': showing.value === true ? 'true' : 'false',
|
|
18592
18610
|
'aria-haspopup': 'true',
|
|
18593
|
-
'aria-controls': targetUid,
|
|
18611
|
+
'aria-controls': targetUid.value,
|
|
18594
18612
|
onClick: toggle
|
|
18595
18613
|
}, getTriggerContent),
|
|
18596
18614
|
|
|
@@ -18742,6 +18760,7 @@ const useValidateProps = {
|
|
|
18742
18760
|
reactiveRules: Boolean,
|
|
18743
18761
|
lazyRules: {
|
|
18744
18762
|
type: [ Boolean, String ],
|
|
18763
|
+
default: false, // statement unneeded but avoids future vue implementation changes
|
|
18745
18764
|
validator: v => lazyRulesValues.includes(v)
|
|
18746
18765
|
}
|
|
18747
18766
|
};
|
|
@@ -18751,7 +18770,7 @@ function useValidate (focused, innerLoading) {
|
|
|
18751
18770
|
|
|
18752
18771
|
const innerError = ref(false);
|
|
18753
18772
|
const innerErrorMessage = ref(null);
|
|
18754
|
-
const isDirtyModel = ref(
|
|
18773
|
+
const isDirtyModel = ref(false);
|
|
18755
18774
|
|
|
18756
18775
|
useFormChild({ validate, resetValidation });
|
|
18757
18776
|
|
|
@@ -18763,10 +18782,14 @@ function useValidate (focused, innerLoading) {
|
|
|
18763
18782
|
&& props.rules.length !== 0
|
|
18764
18783
|
);
|
|
18765
18784
|
|
|
18766
|
-
const
|
|
18785
|
+
const canDebounceValidate = computed(() => (
|
|
18767
18786
|
props.disable !== true
|
|
18768
18787
|
&& hasRules.value === true
|
|
18769
|
-
|
|
18788
|
+
// Should not have a validation in progress already;
|
|
18789
|
+
// It might mean that focus switched to submit btn and
|
|
18790
|
+
// QForm's submit() has been called already (ENTER key)
|
|
18791
|
+
&& innerLoading.value === false
|
|
18792
|
+
));
|
|
18770
18793
|
|
|
18771
18794
|
const hasError = computed(() =>
|
|
18772
18795
|
props.error === true || innerError.value === true
|
|
@@ -18779,15 +18802,31 @@ function useValidate (focused, innerLoading) {
|
|
|
18779
18802
|
));
|
|
18780
18803
|
|
|
18781
18804
|
watch(() => props.modelValue, () => {
|
|
18782
|
-
|
|
18805
|
+
isDirtyModel.value = true;
|
|
18806
|
+
|
|
18807
|
+
if (
|
|
18808
|
+
canDebounceValidate.value === true
|
|
18809
|
+
// trigger validation if not using any kind of lazy-rules
|
|
18810
|
+
&& props.lazyRules === false
|
|
18811
|
+
) {
|
|
18812
|
+
debouncedValidate();
|
|
18813
|
+
}
|
|
18783
18814
|
});
|
|
18784
18815
|
|
|
18816
|
+
function onRulesChange () {
|
|
18817
|
+
if (
|
|
18818
|
+
props.lazyRules !== 'ondemand'
|
|
18819
|
+
&& canDebounceValidate.value === true
|
|
18820
|
+
&& isDirtyModel.value === true
|
|
18821
|
+
) {
|
|
18822
|
+
debouncedValidate();
|
|
18823
|
+
}
|
|
18824
|
+
}
|
|
18825
|
+
|
|
18785
18826
|
watch(() => props.reactiveRules, val => {
|
|
18786
18827
|
if (val === true) {
|
|
18787
18828
|
if (unwatchRules === void 0) {
|
|
18788
|
-
unwatchRules = watch(() => props.rules,
|
|
18789
|
-
validateIfNeeded(true);
|
|
18790
|
-
});
|
|
18829
|
+
unwatchRules = watch(() => props.rules, onRulesChange, { immediate: true, deep: true });
|
|
18791
18830
|
}
|
|
18792
18831
|
}
|
|
18793
18832
|
else if (unwatchRules !== void 0) {
|
|
@@ -18796,32 +18835,24 @@ function useValidate (focused, innerLoading) {
|
|
|
18796
18835
|
}
|
|
18797
18836
|
}, { immediate: true });
|
|
18798
18837
|
|
|
18838
|
+
watch(() => props.lazyRules, onRulesChange);
|
|
18839
|
+
|
|
18799
18840
|
watch(focused, val => {
|
|
18800
18841
|
if (val === true) {
|
|
18801
|
-
if (isDirtyModel.value === null) {
|
|
18802
|
-
isDirtyModel.value = false;
|
|
18803
|
-
}
|
|
18804
|
-
}
|
|
18805
|
-
else if (isDirtyModel.value === false) {
|
|
18806
18842
|
isDirtyModel.value = true;
|
|
18807
|
-
|
|
18808
|
-
|
|
18809
|
-
|
|
18810
|
-
|
|
18811
|
-
|
|
18812
|
-
|
|
18813
|
-
// QForm's submit() has been called already (ENTER key)
|
|
18814
|
-
&& innerLoading.value === false
|
|
18815
|
-
) {
|
|
18816
|
-
debouncedValidate();
|
|
18817
|
-
}
|
|
18843
|
+
}
|
|
18844
|
+
else if (
|
|
18845
|
+
canDebounceValidate.value === true
|
|
18846
|
+
&& props.lazyRules !== 'ondemand'
|
|
18847
|
+
) {
|
|
18848
|
+
debouncedValidate();
|
|
18818
18849
|
}
|
|
18819
18850
|
});
|
|
18820
18851
|
|
|
18821
18852
|
function resetValidation () {
|
|
18822
18853
|
validateIndex++;
|
|
18823
18854
|
innerLoading.value = false;
|
|
18824
|
-
isDirtyModel.value =
|
|
18855
|
+
isDirtyModel.value = false;
|
|
18825
18856
|
innerError.value = false;
|
|
18826
18857
|
innerErrorMessage.value = null;
|
|
18827
18858
|
debouncedValidate.cancel();
|
|
@@ -18834,7 +18865,10 @@ function useValidate (focused, innerLoading) {
|
|
|
18834
18865
|
* - Promise (pending async validation)
|
|
18835
18866
|
*/
|
|
18836
18867
|
function validate (val = props.modelValue) {
|
|
18837
|
-
if (
|
|
18868
|
+
if (
|
|
18869
|
+
props.disable === true
|
|
18870
|
+
|| hasRules.value === false
|
|
18871
|
+
) {
|
|
18838
18872
|
return true
|
|
18839
18873
|
}
|
|
18840
18874
|
|
|
@@ -18903,16 +18937,6 @@ function useValidate (focused, innerLoading) {
|
|
|
18903
18937
|
)
|
|
18904
18938
|
}
|
|
18905
18939
|
|
|
18906
|
-
function validateIfNeeded (changedRules) {
|
|
18907
|
-
if (
|
|
18908
|
-
hasActiveRules.value === true
|
|
18909
|
-
&& props.lazyRules !== 'ondemand'
|
|
18910
|
-
&& (isDirtyModel.value === true || (props.lazyRules !== true && changedRules !== true))
|
|
18911
|
-
) {
|
|
18912
|
-
debouncedValidate();
|
|
18913
|
-
}
|
|
18914
|
-
}
|
|
18915
|
-
|
|
18916
18940
|
const debouncedValidate = debounce(validate, 0);
|
|
18917
18941
|
|
|
18918
18942
|
onBeforeUnmount(() => {
|
|
@@ -18935,12 +18959,6 @@ function useValidate (focused, innerLoading) {
|
|
|
18935
18959
|
}
|
|
18936
18960
|
}
|
|
18937
18961
|
|
|
18938
|
-
function getTargetUid (val, requiredForAttr) {
|
|
18939
|
-
return val === void 0
|
|
18940
|
-
? (requiredForAttr === true ? `f_${ uid$3() }` : void 0)
|
|
18941
|
-
: val
|
|
18942
|
-
}
|
|
18943
|
-
|
|
18944
18962
|
function fieldValueIsFilled (val) {
|
|
18945
18963
|
return val !== void 0
|
|
18946
18964
|
&& val !== null
|
|
@@ -19001,6 +19019,7 @@ function useFieldState ({ requiredForAttr = true, tagProp } = {}) {
|
|
|
19001
19019
|
const { props, attrs, proxy, vnode } = getCurrentInstance();
|
|
19002
19020
|
|
|
19003
19021
|
const isDark = useDark(props, proxy.$q);
|
|
19022
|
+
const targetUid = useId(props.for, requiredForAttr);
|
|
19004
19023
|
|
|
19005
19024
|
return {
|
|
19006
19025
|
requiredForAttr,
|
|
@@ -19019,9 +19038,7 @@ function useFieldState ({ requiredForAttr = true, tagProp } = {}) {
|
|
|
19019
19038
|
hasPopupOpen: false,
|
|
19020
19039
|
|
|
19021
19040
|
splitAttrs: useSplitAttrs(attrs, vnode),
|
|
19022
|
-
targetUid
|
|
19023
|
-
getTargetUid(props.for, requiredForAttr)
|
|
19024
|
-
),
|
|
19041
|
+
targetUid,
|
|
19025
19042
|
|
|
19026
19043
|
rootRef: ref(null),
|
|
19027
19044
|
targetRef: ref(null),
|
|
@@ -19173,16 +19190,15 @@ function useField (state) {
|
|
|
19173
19190
|
}));
|
|
19174
19191
|
|
|
19175
19192
|
const attributes = computed(() => {
|
|
19176
|
-
const acc = {
|
|
19177
|
-
|
|
19178
|
-
|
|
19193
|
+
const acc = {};
|
|
19194
|
+
|
|
19195
|
+
if (state.targetUid.value) {
|
|
19196
|
+
acc.for = state.targetUid.value;
|
|
19197
|
+
}
|
|
19179
19198
|
|
|
19180
19199
|
if (props.disable === true) {
|
|
19181
19200
|
acc[ 'aria-disabled' ] = 'true';
|
|
19182
19201
|
}
|
|
19183
|
-
else if (props.readonly === true) {
|
|
19184
|
-
acc[ 'aria-readonly' ] = 'true';
|
|
19185
|
-
}
|
|
19186
19202
|
|
|
19187
19203
|
return acc
|
|
19188
19204
|
});
|
|
@@ -19190,7 +19206,7 @@ function useField (state) {
|
|
|
19190
19206
|
watch(() => props.for, val => {
|
|
19191
19207
|
// don't transform targetUid into a computed
|
|
19192
19208
|
// prop as it will break SSR
|
|
19193
|
-
state.targetUid.value =
|
|
19209
|
+
state.targetUid.value = getId(val, state.requiredForAttr);
|
|
19194
19210
|
});
|
|
19195
19211
|
|
|
19196
19212
|
function focusHandler () {
|
|
@@ -19266,7 +19282,7 @@ function useField (state) {
|
|
|
19266
19282
|
document.activeElement.blur();
|
|
19267
19283
|
}
|
|
19268
19284
|
|
|
19269
|
-
if (props.type === 'file') {
|
|
19285
|
+
if (props.type === 'file') {
|
|
19270
19286
|
// do not let focus be triggered
|
|
19271
19287
|
// as it will make the native file dialog
|
|
19272
19288
|
// appear for another selection
|
|
@@ -19277,11 +19293,9 @@ function useField (state) {
|
|
|
19277
19293
|
emit('clear', props.modelValue);
|
|
19278
19294
|
|
|
19279
19295
|
nextTick(() => {
|
|
19296
|
+
const isDirty = isDirtyModel.value;
|
|
19280
19297
|
resetValidation();
|
|
19281
|
-
|
|
19282
|
-
if ($q.platform.is.mobile !== true) {
|
|
19283
|
-
isDirtyModel.value = false;
|
|
19284
|
-
}
|
|
19298
|
+
isDirtyModel.value = isDirty;
|
|
19285
19299
|
});
|
|
19286
19300
|
}
|
|
19287
19301
|
|
|
@@ -19474,16 +19488,8 @@ function useField (state) {
|
|
|
19474
19488
|
shouldActivate === true && props.autofocus === true && proxy.focus();
|
|
19475
19489
|
});
|
|
19476
19490
|
|
|
19477
|
-
onMounted(() => {
|
|
19478
|
-
|
|
19479
|
-
isRuntimeSsrPreHydration.value === true
|
|
19480
|
-
&& state.requiredForAttr === true
|
|
19481
|
-
&& props.for === void 0
|
|
19482
|
-
) {
|
|
19483
|
-
state.targetUid.value = `f_${ uid$3() }`; // getTargetUid(void 0, true)
|
|
19484
|
-
}
|
|
19485
|
-
|
|
19486
|
-
props.autofocus === true && proxy.focus();
|
|
19491
|
+
props.autofocus === true && onMounted(() => {
|
|
19492
|
+
proxy.focus();
|
|
19487
19493
|
});
|
|
19488
19494
|
|
|
19489
19495
|
onBeforeUnmount(() => {
|
|
@@ -21267,7 +21273,7 @@ var QInfiniteScroll = createComponent({
|
|
|
21267
21273
|
const vm = getCurrentInstance();
|
|
21268
21274
|
Object.assign(vm.proxy, {
|
|
21269
21275
|
poll: () => { poll !== void 0 && poll(); },
|
|
21270
|
-
trigger, stop, reset, resume, setIndex
|
|
21276
|
+
trigger, stop, reset, resume, setIndex, updateScrollTarget
|
|
21271
21277
|
});
|
|
21272
21278
|
|
|
21273
21279
|
return () => {
|
|
@@ -25616,15 +25622,15 @@ var QRange = createComponent({
|
|
|
25616
25622
|
case dragType.RANGE:
|
|
25617
25623
|
const
|
|
25618
25624
|
ratioDelta = ratio - dragging.offsetRatio,
|
|
25619
|
-
minR = between(dragging.ratioMin + ratioDelta,
|
|
25625
|
+
minR = between(dragging.ratioMin + ratioDelta, state.innerMinRatio.value, state.innerMaxRatio.value - dragging.rangeRatio),
|
|
25620
25626
|
modelDelta = localModel - dragging.offsetModel,
|
|
25621
|
-
min = between(dragging.valueMin + modelDelta,
|
|
25627
|
+
min = between(dragging.valueMin + modelDelta, state.innerMin.value, state.innerMax.value - dragging.rangeValue);
|
|
25622
25628
|
|
|
25623
25629
|
pos = {
|
|
25624
25630
|
minR,
|
|
25625
25631
|
maxR: minR + dragging.rangeRatio,
|
|
25626
|
-
min:
|
|
25627
|
-
max:
|
|
25632
|
+
min: state.roundValueFn.value(min),
|
|
25633
|
+
max: state.roundValueFn.value(min + dragging.rangeValue)
|
|
25628
25634
|
};
|
|
25629
25635
|
|
|
25630
25636
|
state.focus.value = 'both';
|
|
@@ -25654,7 +25660,7 @@ var QRange = createComponent({
|
|
|
25654
25660
|
stopAndPrevent(evt);
|
|
25655
25661
|
|
|
25656
25662
|
const
|
|
25657
|
-
stepVal = ([ 34, 33 ].includes(evt.keyCode) ? 10 : 1) * state.
|
|
25663
|
+
stepVal = ([ 34, 33 ].includes(evt.keyCode) ? 10 : 1) * state.keyStep.value,
|
|
25658
25664
|
offset = (
|
|
25659
25665
|
([ 34, 37, 40 ].includes(evt.keyCode) ? -1 : 1)
|
|
25660
25666
|
* (state.isReversed.value === true ? -1 : 1)
|
|
@@ -25664,14 +25670,14 @@ var QRange = createComponent({
|
|
|
25664
25670
|
if (state.focus.value === 'both') {
|
|
25665
25671
|
const interval = model.value.max - model.value.min;
|
|
25666
25672
|
const min = between(
|
|
25667
|
-
|
|
25673
|
+
state.roundValueFn.value(model.value.min + offset),
|
|
25668
25674
|
state.innerMin.value,
|
|
25669
25675
|
state.innerMax.value - interval
|
|
25670
25676
|
);
|
|
25671
25677
|
|
|
25672
25678
|
model.value = {
|
|
25673
25679
|
min,
|
|
25674
|
-
max:
|
|
25680
|
+
max: state.roundValueFn.value(min + interval)
|
|
25675
25681
|
};
|
|
25676
25682
|
}
|
|
25677
25683
|
else if (state.focus.value === false) {
|
|
@@ -25683,7 +25689,7 @@ var QRange = createComponent({
|
|
|
25683
25689
|
model.value = {
|
|
25684
25690
|
...model.value,
|
|
25685
25691
|
[ which ]: between(
|
|
25686
|
-
|
|
25692
|
+
state.roundValueFn.value(model.value[ which ] + offset),
|
|
25687
25693
|
which === 'min' ? state.innerMin.value : model.value.min,
|
|
25688
25694
|
which === 'max' ? state.innerMax.value : model.value.max
|
|
25689
25695
|
)
|
|
@@ -39685,6 +39691,7 @@ const notificationsList = {};
|
|
|
39685
39691
|
const positionClass = {};
|
|
39686
39692
|
const emptyRE = /^\s*$/;
|
|
39687
39693
|
const notifRefs = [];
|
|
39694
|
+
const invalidTimeoutValues = [ void 0, null, true, false, '' ];
|
|
39688
39695
|
|
|
39689
39696
|
const positionList = [
|
|
39690
39697
|
'top-left', 'top-right',
|
|
@@ -39778,15 +39785,15 @@ function addNotification (config, $q, originalApi) {
|
|
|
39778
39785
|
notif.position = 'bottom';
|
|
39779
39786
|
}
|
|
39780
39787
|
|
|
39781
|
-
if (notif.timeout ===
|
|
39788
|
+
if (invalidTimeoutValues.includes(notif.timeout) === true) {
|
|
39782
39789
|
notif.timeout = 5000;
|
|
39783
39790
|
}
|
|
39784
39791
|
else {
|
|
39785
|
-
const t =
|
|
39792
|
+
const t = Number(notif.timeout); // we catch exponential notation too with Number() casting
|
|
39786
39793
|
if (isNaN(t) || t < 0) {
|
|
39787
39794
|
return logError('wrong timeout', config)
|
|
39788
39795
|
}
|
|
39789
|
-
notif.timeout = t;
|
|
39796
|
+
notif.timeout = Number.isFinite(t) ? t : 0;
|
|
39790
39797
|
}
|
|
39791
39798
|
|
|
39792
39799
|
if (notif.timeout === 0) {
|
|
@@ -40854,7 +40861,7 @@ function runSequentialPromises (
|
|
|
40854
40861
|
*/
|
|
40855
40862
|
|
|
40856
40863
|
const Quasar = {
|
|
40857
|
-
version: '2.14.
|
|
40864
|
+
version: '2.14.3',
|
|
40858
40865
|
install: installQuasar,
|
|
40859
40866
|
lang: Plugin$8,
|
|
40860
40867
|
iconSet: Plugin$7
|