quasar 1.20.0 → 1.20.2
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/QBtnDropdown.json +9 -0
- package/dist/api/QChip.json +9 -0
- package/dist/api/QCircularProgress.json +6 -0
- package/dist/api/QExpansionItem.json +59 -0
- package/dist/api/QField.json +2 -1
- package/dist/api/QFile.json +2 -1
- package/dist/api/QInput.json +2 -1
- package/dist/api/QSelect.json +2 -1
- package/dist/api/QTable.json +2 -2
- package/dist/babel-transforms/imports.js +1 -0
- package/dist/icon-set/bootstrap-icons.umd.min.js +1 -1
- package/dist/icon-set/eva-icons.umd.min.js +1 -1
- package/dist/icon-set/fontawesome-v5-pro.umd.min.js +1 -1
- package/dist/icon-set/fontawesome-v5.umd.min.js +1 -1
- package/dist/icon-set/fontawesome-v6-pro.umd.min.js +1 -1
- package/dist/icon-set/fontawesome-v6.umd.min.js +1 -1
- package/dist/icon-set/ionicons-v4.umd.min.js +1 -1
- package/dist/icon-set/line-awesome.umd.min.js +1 -1
- package/dist/icon-set/material-icons-outlined.umd.min.js +1 -1
- package/dist/icon-set/material-icons-round.umd.min.js +1 -1
- package/dist/icon-set/material-icons-sharp.umd.min.js +1 -1
- package/dist/icon-set/material-icons.umd.min.js +1 -1
- package/dist/icon-set/material-symbols-outlined.umd.min.js +1 -1
- package/dist/icon-set/material-symbols-rounded.umd.min.js +1 -1
- package/dist/icon-set/material-symbols-sharp.umd.min.js +1 -1
- package/dist/icon-set/mdi-v3.umd.min.js +1 -1
- package/dist/icon-set/mdi-v4.umd.min.js +1 -1
- package/dist/icon-set/mdi-v5.umd.min.js +1 -1
- package/dist/icon-set/mdi-v6.umd.min.js +1 -1
- package/dist/icon-set/svg-bootstrap-icons.umd.min.js +1 -1
- package/dist/icon-set/svg-eva-icons.umd.min.js +1 -1
- package/dist/icon-set/svg-fontawesome-v5.umd.min.js +1 -1
- package/dist/icon-set/svg-fontawesome-v6.umd.min.js +1 -1
- package/dist/icon-set/svg-ionicons-v4.umd.min.js +1 -1
- package/dist/icon-set/svg-ionicons-v5.umd.min.js +1 -1
- package/dist/icon-set/svg-ionicons-v6.umd.min.js +1 -1
- package/dist/icon-set/svg-line-awesome.umd.min.js +1 -1
- package/dist/icon-set/svg-material-icons-outlined.umd.min.js +1 -1
- package/dist/icon-set/svg-material-icons-round.umd.min.js +1 -1
- package/dist/icon-set/svg-material-icons-sharp.umd.min.js +1 -1
- package/dist/icon-set/svg-material-icons.umd.min.js +1 -1
- package/dist/icon-set/svg-material-symbols-outlined.umd.min.js +1 -1
- package/dist/icon-set/svg-material-symbols-rounded.umd.min.js +1 -1
- package/dist/icon-set/svg-material-symbols-sharp.umd.min.js +1 -1
- package/dist/icon-set/svg-mdi-v4.umd.min.js +1 -1
- package/dist/icon-set/svg-mdi-v5.umd.min.js +1 -1
- package/dist/icon-set/svg-mdi-v6.umd.min.js +1 -1
- package/dist/icon-set/svg-themify.umd.min.js +1 -1
- package/dist/icon-set/themify.umd.min.js +1 -1
- package/dist/lang/ar.umd.min.js +2 -2
- package/dist/lang/az-latn.umd.min.js +2 -2
- package/dist/lang/bg.umd.min.js +2 -2
- package/dist/lang/ca.umd.min.js +2 -2
- package/dist/lang/cs.umd.min.js +2 -2
- package/dist/lang/da.umd.min.js +2 -2
- package/dist/lang/de.umd.min.js +2 -2
- package/dist/lang/el.umd.min.js +2 -2
- package/dist/lang/en-gb.umd.min.js +2 -2
- package/dist/lang/en-us.umd.min.js +2 -2
- package/dist/lang/eo.umd.min.js +2 -2
- package/dist/lang/es.umd.min.js +2 -2
- package/dist/lang/et.umd.min.js +2 -2
- package/dist/lang/eu.umd.min.js +2 -2
- package/dist/lang/fa-ir.umd.min.js +2 -2
- package/dist/lang/fa.umd.min.js +2 -2
- package/dist/lang/fi.umd.min.js +2 -2
- package/dist/lang/fr.umd.min.js +2 -2
- package/dist/lang/gn.umd.min.js +2 -2
- package/dist/lang/he.umd.min.js +2 -2
- package/dist/lang/hr.umd.min.js +2 -2
- package/dist/lang/hu.umd.min.js +2 -2
- package/dist/lang/id.umd.min.js +2 -2
- package/dist/lang/is.umd.min.js +2 -2
- package/dist/lang/it.umd.min.js +2 -2
- package/dist/lang/ja.umd.min.js +2 -2
- package/dist/lang/km.umd.min.js +2 -2
- package/dist/lang/ko-kr.umd.min.js +2 -2
- package/dist/lang/kur-ckb.umd.min.js +2 -2
- package/dist/lang/kz.umd.min.js +2 -2
- package/dist/lang/lu.umd.min.js +2 -2
- package/dist/lang/lv.umd.min.js +2 -2
- package/dist/lang/ml.umd.min.js +2 -2
- package/dist/lang/mm.umd.min.js +2 -2
- package/dist/lang/ms.umd.min.js +2 -2
- package/dist/lang/my.umd.min.js +2 -2
- package/dist/lang/nb-no.umd.min.js +2 -2
- package/dist/lang/nl.umd.min.js +2 -2
- package/dist/lang/pl.umd.min.js +2 -2
- package/dist/lang/pt-br.umd.min.js +2 -2
- package/dist/lang/pt.umd.min.js +2 -2
- package/dist/lang/ro.umd.min.js +2 -2
- package/dist/lang/ru.umd.min.js +2 -2
- package/dist/lang/sk.umd.min.js +2 -2
- package/dist/lang/sl.umd.min.js +2 -2
- package/dist/lang/sm.umd.min.js +2 -2
- package/dist/lang/sr.umd.min.js +2 -2
- package/dist/lang/sv.umd.min.js +2 -2
- package/dist/lang/ta.umd.min.js +2 -2
- package/dist/lang/th.umd.min.js +2 -2
- package/dist/lang/tr.umd.min.js +2 -2
- package/dist/lang/ug.umd.min.js +2 -2
- package/dist/lang/uk.umd.min.js +2 -2
- package/dist/lang/uz-Cyrl.umd.min.js +2 -2
- package/dist/lang/uz-Latn.umd.min.js +2 -2
- package/dist/lang/vi.umd.min.js +2 -2
- package/dist/lang/zh-hans.umd.min.js +2 -2
- package/dist/lang/zh-hant.umd.min.js +2 -2
- package/dist/quasar.addon.css +1 -1
- package/dist/quasar.addon.rtl.css +1 -1
- package/dist/quasar.common.js +2 -2
- package/dist/quasar.css +1 -1
- package/dist/quasar.esm.js +2 -2
- package/dist/quasar.ie.polyfills.js +1 -1
- package/dist/quasar.ie.polyfills.umd.min.js +1 -1
- package/dist/quasar.rtl.css +1 -1
- package/dist/quasar.sass +1 -1
- package/dist/quasar.styl +1 -1
- package/dist/quasar.umd.js +396 -180
- package/dist/quasar.umd.min.js +2 -2
- package/dist/quasar.umd.modern.js +381 -171
- package/dist/quasar.umd.modern.min.js +2 -2
- package/dist/types/index.d.ts +21 -1
- package/dist/types/utils/is.d.ts +67 -0
- package/dist/types/utils/run-sequential-promises.d.ts +119 -0
- package/dist/types/utils.d.ts +2 -0
- package/dist/vetur/quasar-attributes.json +21 -1
- package/dist/vetur/quasar-tags.json +6 -1
- package/dist/web-types/web-types.json +77 -6
- package/lang/ar.js +3 -1
- package/lang/az-latn.js +3 -1
- package/lang/bg.js +3 -1
- package/lang/ca.js +3 -1
- package/lang/cs.js +3 -1
- package/lang/da.js +3 -1
- package/lang/de.js +3 -1
- package/lang/el.js +3 -1
- package/lang/en-gb.js +3 -1
- package/lang/en-us.js +3 -1
- package/lang/eo.js +3 -1
- package/lang/es.js +3 -1
- package/lang/et.js +3 -1
- package/lang/eu.js +3 -1
- package/lang/fa-ir.js +3 -1
- package/lang/fa.js +3 -1
- package/lang/fi.js +3 -1
- package/lang/fr.js +3 -1
- package/lang/gn.js +3 -1
- package/lang/he.js +3 -1
- package/lang/hr.js +3 -1
- package/lang/hu.js +3 -1
- package/lang/id.js +3 -1
- package/lang/is.js +3 -1
- package/lang/it.js +3 -1
- package/lang/ja.js +3 -1
- package/lang/km.js +3 -1
- package/lang/ko-kr.js +3 -1
- package/lang/kur-ckb.js +3 -1
- package/lang/kz.js +3 -1
- package/lang/lu.js +3 -1
- package/lang/lv.js +3 -1
- package/lang/ml.js +3 -1
- package/lang/mm.js +3 -1
- package/lang/ms.js +3 -1
- package/lang/my.js +3 -1
- package/lang/nb-no.js +3 -1
- package/lang/nl.js +3 -1
- package/lang/pl.js +3 -1
- package/lang/pt-br.js +3 -1
- package/lang/pt.js +3 -1
- package/lang/ro.js +3 -1
- package/lang/ru.js +3 -1
- package/lang/sk.js +3 -1
- package/lang/sl.js +3 -1
- package/lang/sm.js +3 -1
- package/lang/sr.js +3 -1
- package/lang/sv.js +3 -1
- package/lang/ta.js +3 -1
- package/lang/th.js +3 -1
- package/lang/tr.js +3 -1
- package/lang/ug.js +3 -1
- package/lang/uk.js +3 -1
- package/lang/uz-Cyrl.js +3 -1
- package/lang/uz-Latn.js +3 -1
- package/lang/vi.js +3 -1
- package/lang/zh-hans.js +3 -1
- package/lang/zh-hant.js +3 -1
- package/package.json +1 -1
- package/src/components/btn-dropdown/QBtnDropdown.js +17 -4
- package/src/components/btn-dropdown/QBtnDropdown.json +8 -0
- package/src/components/chip/QChip.js +8 -1
- package/src/components/chip/QChip.json +8 -0
- package/src/components/circular-progress/QCircularProgress.js +5 -2
- package/src/components/circular-progress/QCircularProgress.json +7 -0
- package/src/components/dialog/QDialog.js +7 -1
- package/src/components/expansion-item/QExpansionItem.js +38 -3
- package/src/components/expansion-item/QExpansionItem.json +67 -0
- package/src/components/fab/QFab.js +24 -1
- package/src/components/form/QForm.js +43 -49
- package/src/components/input/QInput.js +18 -15
- package/src/components/menu/QMenu.js +1 -0
- package/src/components/select/QSelect.js +1 -4
- package/src/components/table/QTable.js +1 -1
- package/src/components/table/QTable.json +2 -2
- package/src/mixins/file.js +7 -5
- package/src/mixins/validate.js +6 -4
- package/src/mixins/validate.json +2 -1
- package/src/utils/is.js +8 -0
- package/src/utils/run-sequential-promises.js +115 -0
- package/src/utils.js +4 -0
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* Quasar Framework v1.20.
|
|
2
|
+
* Quasar Framework v1.20.2
|
|
3
3
|
* (c) 2015-present Razvan Stoenescu
|
|
4
4
|
* Released under the MIT License.
|
|
5
5
|
*/
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
|
|
13
13
|
Vue = Vue && Object.prototype.hasOwnProperty.call(Vue, 'default') ? Vue['default'] : Vue;
|
|
14
14
|
|
|
15
|
-
var version = "1.20.
|
|
15
|
+
var version = "1.20.2";
|
|
16
16
|
|
|
17
17
|
/* eslint-disable no-useless-escape */
|
|
18
18
|
|
|
@@ -980,7 +980,9 @@
|
|
|
980
980
|
create: 'Create',
|
|
981
981
|
search: 'Search',
|
|
982
982
|
filter: 'Filter',
|
|
983
|
-
refresh: 'Refresh'
|
|
983
|
+
refresh: 'Refresh',
|
|
984
|
+
expand: function (label) { return label ? `Expand "${label}"` : 'Expand' },
|
|
985
|
+
collapse: function (label) { return label ? `Collapse "${label}"` : 'Collapse' }
|
|
984
986
|
},
|
|
985
987
|
date: {
|
|
986
988
|
days: 'Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday'.split('_'),
|
|
@@ -5340,6 +5342,7 @@
|
|
|
5340
5342
|
attrs () {
|
|
5341
5343
|
return {
|
|
5342
5344
|
tabindex: -1,
|
|
5345
|
+
role: 'menu',
|
|
5343
5346
|
...this.qAttrs
|
|
5344
5347
|
}
|
|
5345
5348
|
}
|
|
@@ -5567,6 +5570,79 @@
|
|
|
5567
5570
|
}
|
|
5568
5571
|
});
|
|
5569
5572
|
|
|
5573
|
+
/**
|
|
5574
|
+
* Based on the work of https://github.com/jchook/uuid-random
|
|
5575
|
+
*/
|
|
5576
|
+
|
|
5577
|
+
let
|
|
5578
|
+
buf,
|
|
5579
|
+
bufIdx = 0;
|
|
5580
|
+
const hexBytes = new Array(256);
|
|
5581
|
+
|
|
5582
|
+
// Pre-calculate toString(16) for speed
|
|
5583
|
+
for (let i = 0; i < 256; i++) {
|
|
5584
|
+
hexBytes[i] = (i + 0x100).toString(16).substr(1);
|
|
5585
|
+
}
|
|
5586
|
+
|
|
5587
|
+
// Use best available PRNG
|
|
5588
|
+
const randomBytes = (() => {
|
|
5589
|
+
// Node & Browser support
|
|
5590
|
+
const lib = typeof crypto !== 'undefined'
|
|
5591
|
+
? crypto
|
|
5592
|
+
: (
|
|
5593
|
+
typeof window !== 'undefined'
|
|
5594
|
+
? window.msCrypto // IE11
|
|
5595
|
+
: void 0
|
|
5596
|
+
);
|
|
5597
|
+
|
|
5598
|
+
if (lib !== void 0) {
|
|
5599
|
+
if (lib.randomBytes !== void 0) {
|
|
5600
|
+
return lib.randomBytes
|
|
5601
|
+
}
|
|
5602
|
+
if (lib.getRandomValues !== void 0) {
|
|
5603
|
+
return n => {
|
|
5604
|
+
var bytes = new Uint8Array(n);
|
|
5605
|
+
lib.getRandomValues(bytes);
|
|
5606
|
+
return bytes
|
|
5607
|
+
}
|
|
5608
|
+
}
|
|
5609
|
+
}
|
|
5610
|
+
|
|
5611
|
+
return n => {
|
|
5612
|
+
const r = [];
|
|
5613
|
+
for (let i = n; i > 0; i--) {
|
|
5614
|
+
r.push(Math.floor(Math.random() * 256));
|
|
5615
|
+
}
|
|
5616
|
+
return r
|
|
5617
|
+
}
|
|
5618
|
+
})();
|
|
5619
|
+
|
|
5620
|
+
// Buffer random numbers for speed
|
|
5621
|
+
// Reduce memory usage by decreasing this number (min 16)
|
|
5622
|
+
// or improve speed by increasing this number (try 16384)
|
|
5623
|
+
const BUFFER_SIZE = 4096;
|
|
5624
|
+
|
|
5625
|
+
function uid () {
|
|
5626
|
+
// Buffer some random bytes for speed
|
|
5627
|
+
if (buf === void 0 || (bufIdx + 16 > BUFFER_SIZE)) {
|
|
5628
|
+
bufIdx = 0;
|
|
5629
|
+
buf = randomBytes(BUFFER_SIZE);
|
|
5630
|
+
}
|
|
5631
|
+
|
|
5632
|
+
const b = Array.prototype.slice.call(buf, bufIdx, (bufIdx += 16));
|
|
5633
|
+
b[6] = (b[6] & 0x0f) | 0x40;
|
|
5634
|
+
b[8] = (b[8] & 0x3f) | 0x80;
|
|
5635
|
+
|
|
5636
|
+
return hexBytes[b[0]] + hexBytes[b[1]] +
|
|
5637
|
+
hexBytes[b[2]] + hexBytes[b[3]] + '-' +
|
|
5638
|
+
hexBytes[b[4]] + hexBytes[b[5]] + '-' +
|
|
5639
|
+
hexBytes[b[6]] + hexBytes[b[7]] + '-' +
|
|
5640
|
+
hexBytes[b[8]] + hexBytes[b[9]] + '-' +
|
|
5641
|
+
hexBytes[b[10]] + hexBytes[b[11]] +
|
|
5642
|
+
hexBytes[b[12]] + hexBytes[b[13]] +
|
|
5643
|
+
hexBytes[b[14]] + hexBytes[b[15]]
|
|
5644
|
+
}
|
|
5645
|
+
|
|
5570
5646
|
var QBtnDropdown = Vue.extend({
|
|
5571
5647
|
name: 'QBtnDropdown',
|
|
5572
5648
|
|
|
@@ -5600,7 +5676,9 @@
|
|
|
5600
5676
|
disableMainBtn: Boolean,
|
|
5601
5677
|
disableDropdown: Boolean,
|
|
5602
5678
|
|
|
5603
|
-
noIconAnimation: Boolean
|
|
5679
|
+
noIconAnimation: Boolean,
|
|
5680
|
+
|
|
5681
|
+
toggleAriaLabel: String
|
|
5604
5682
|
},
|
|
5605
5683
|
|
|
5606
5684
|
data () {
|
|
@@ -5623,7 +5701,10 @@
|
|
|
5623
5701
|
const label = slot(this, 'label', []);
|
|
5624
5702
|
const attrs = {
|
|
5625
5703
|
'aria-expanded': this.showing === true ? 'true' : 'false',
|
|
5626
|
-
'aria-haspopup': 'true'
|
|
5704
|
+
'aria-haspopup': 'true',
|
|
5705
|
+
'aria-controls': this.targetUid,
|
|
5706
|
+
'aria-owns': this.targetUid,
|
|
5707
|
+
'aria-label': this.toggleAriaLabel || this.$q.lang.label[ this.showing === true ? 'collapse' : 'expand' ](this.label)
|
|
5627
5708
|
};
|
|
5628
5709
|
|
|
5629
5710
|
if (
|
|
@@ -5648,6 +5729,9 @@
|
|
|
5648
5729
|
this.disableDropdown !== true && Arrow.push(
|
|
5649
5730
|
h(QMenu, {
|
|
5650
5731
|
ref: 'menu',
|
|
5732
|
+
attrs: {
|
|
5733
|
+
id: this.targetUid
|
|
5734
|
+
},
|
|
5651
5735
|
props: {
|
|
5652
5736
|
cover: this.cover,
|
|
5653
5737
|
fit: true,
|
|
@@ -5692,8 +5776,8 @@
|
|
|
5692
5776
|
round: false
|
|
5693
5777
|
},
|
|
5694
5778
|
attrs: {
|
|
5695
|
-
...
|
|
5696
|
-
...
|
|
5779
|
+
...attrs,
|
|
5780
|
+
...this.qAttrs
|
|
5697
5781
|
},
|
|
5698
5782
|
on: cache(this, 'nonSpl', {
|
|
5699
5783
|
click: e => {
|
|
@@ -5775,6 +5859,10 @@
|
|
|
5775
5859
|
}
|
|
5776
5860
|
},
|
|
5777
5861
|
|
|
5862
|
+
created () {
|
|
5863
|
+
this.targetUid = `d_${uid()}`;
|
|
5864
|
+
},
|
|
5865
|
+
|
|
5778
5866
|
mounted () {
|
|
5779
5867
|
this.value === true && this.show();
|
|
5780
5868
|
}
|
|
@@ -6889,6 +6977,14 @@
|
|
|
6889
6977
|
return typeof v === 'number' && isFinite(v)
|
|
6890
6978
|
}
|
|
6891
6979
|
|
|
6980
|
+
var is = {
|
|
6981
|
+
deepEqual: isDeepEqual,
|
|
6982
|
+
object: isObject,
|
|
6983
|
+
date: isDate,
|
|
6984
|
+
regexp: isRegexp,
|
|
6985
|
+
number: isNumber
|
|
6986
|
+
};
|
|
6987
|
+
|
|
6892
6988
|
var QCarousel = Vue.extend({
|
|
6893
6989
|
name: 'QCarousel',
|
|
6894
6990
|
|
|
@@ -7737,6 +7833,8 @@
|
|
|
7737
7833
|
clickable: Boolean,
|
|
7738
7834
|
removable: Boolean,
|
|
7739
7835
|
|
|
7836
|
+
removeAriaLabel: String,
|
|
7837
|
+
|
|
7740
7838
|
tabindex: [String, Number],
|
|
7741
7839
|
disable: Boolean
|
|
7742
7840
|
},
|
|
@@ -7781,7 +7879,12 @@
|
|
|
7781
7879
|
attrs () {
|
|
7782
7880
|
return this.disable === true
|
|
7783
7881
|
? { tabindex: -1, 'aria-disabled': 'true' }
|
|
7784
|
-
: {
|
|
7882
|
+
: {
|
|
7883
|
+
tabindex: this.tabindex || 0,
|
|
7884
|
+
role: 'button',
|
|
7885
|
+
'aria-hidden': 'false',
|
|
7886
|
+
'aria-label': this.removeAriaLabel || this.$q.lang.label.remove
|
|
7887
|
+
}
|
|
7785
7888
|
}
|
|
7786
7889
|
},
|
|
7787
7890
|
|
|
@@ -7906,6 +8009,7 @@
|
|
|
7906
8009
|
trackColor: String,
|
|
7907
8010
|
|
|
7908
8011
|
fontSize: String,
|
|
8012
|
+
rounded: Boolean,
|
|
7909
8013
|
|
|
7910
8014
|
// ratio
|
|
7911
8015
|
thickness: {
|
|
@@ -7975,7 +8079,7 @@
|
|
|
7975
8079
|
},
|
|
7976
8080
|
|
|
7977
8081
|
methods: {
|
|
7978
|
-
__getCircle (h, { thickness, offset, color, cls }) {
|
|
8082
|
+
__getCircle (h, { thickness, offset, color, cls, rounded }) {
|
|
7979
8083
|
return h('circle', {
|
|
7980
8084
|
staticClass: 'q-circular-progress__' + cls,
|
|
7981
8085
|
class: color !== void 0 ? `text-${color}` : null,
|
|
@@ -7986,6 +8090,7 @@
|
|
|
7986
8090
|
'stroke-width': thickness,
|
|
7987
8091
|
'stroke-dasharray': strokeDashArray,
|
|
7988
8092
|
'stroke-dashoffset': offset,
|
|
8093
|
+
'stroke-linecap': rounded,
|
|
7989
8094
|
cx: this.viewBox,
|
|
7990
8095
|
cy: this.viewBox,
|
|
7991
8096
|
r: radius
|
|
@@ -8024,7 +8129,8 @@
|
|
|
8024
8129
|
cls: 'circle',
|
|
8025
8130
|
thickness: this.strokeWidth,
|
|
8026
8131
|
offset: this.strokeDashOffset,
|
|
8027
|
-
color: this.color
|
|
8132
|
+
color: this.color,
|
|
8133
|
+
rounded: this.rounded === true ? 'round' : void 0
|
|
8028
8134
|
})
|
|
8029
8135
|
);
|
|
8030
8136
|
|
|
@@ -8225,7 +8331,7 @@
|
|
|
8225
8331
|
}
|
|
8226
8332
|
}
|
|
8227
8333
|
|
|
8228
|
-
let uid = 0;
|
|
8334
|
+
let uid$1 = 0;
|
|
8229
8335
|
|
|
8230
8336
|
var TouchPan = {
|
|
8231
8337
|
name: 'touch-pan',
|
|
@@ -8252,7 +8358,7 @@
|
|
|
8252
8358
|
}
|
|
8253
8359
|
|
|
8254
8360
|
const ctx = {
|
|
8255
|
-
uid: 'qvtp_' + (uid++),
|
|
8361
|
+
uid: 'qvtp_' + (uid$1++),
|
|
8256
8362
|
handler: value,
|
|
8257
8363
|
modifiers,
|
|
8258
8364
|
direction: getModifierDirections(modifiers),
|
|
@@ -10148,7 +10254,7 @@
|
|
|
10148
10254
|
}
|
|
10149
10255
|
});
|
|
10150
10256
|
|
|
10151
|
-
let uid$
|
|
10257
|
+
let uid$2 = 0;
|
|
10152
10258
|
|
|
10153
10259
|
var QTab = Vue.extend({
|
|
10154
10260
|
name: 'QTab',
|
|
@@ -10175,7 +10281,7 @@
|
|
|
10175
10281
|
|
|
10176
10282
|
name: {
|
|
10177
10283
|
type: [Number, String],
|
|
10178
|
-
default: () => `t_${uid$
|
|
10284
|
+
default: () => `t_${uid$2++}`
|
|
10179
10285
|
},
|
|
10180
10286
|
|
|
10181
10287
|
noCaps: Boolean,
|
|
@@ -14493,6 +14599,12 @@
|
|
|
14493
14599
|
}
|
|
14494
14600
|
|
|
14495
14601
|
return on
|
|
14602
|
+
},
|
|
14603
|
+
|
|
14604
|
+
attrs () {
|
|
14605
|
+
return this.useBackdrop === true
|
|
14606
|
+
? { 'aria-modal': 'true', ...this.qAttrs }
|
|
14607
|
+
: this.qAttrs
|
|
14496
14608
|
}
|
|
14497
14609
|
},
|
|
14498
14610
|
|
|
@@ -14686,7 +14798,7 @@
|
|
|
14686
14798
|
staticClass: `q-dialog fullscreen no-pointer-events q-dialog--${this.useBackdrop === true ? 'modal' : 'seamless'}`,
|
|
14687
14799
|
class: this.contentClass,
|
|
14688
14800
|
style: this.contentStyle,
|
|
14689
|
-
attrs: this.
|
|
14801
|
+
attrs: this.attrs
|
|
14690
14802
|
}, [
|
|
14691
14803
|
h('transition', {
|
|
14692
14804
|
props: { name: 'q-transition--fade' }
|
|
@@ -17391,6 +17503,7 @@
|
|
|
17391
17503
|
|
|
17392
17504
|
dense: Boolean,
|
|
17393
17505
|
|
|
17506
|
+
toggleAriaLabel: String,
|
|
17394
17507
|
expandIcon: String,
|
|
17395
17508
|
expandedIcon: String,
|
|
17396
17509
|
expandIconClass: [ Array, String, Object ],
|
|
@@ -17401,6 +17514,7 @@
|
|
|
17401
17514
|
|
|
17402
17515
|
expandSeparator: Boolean,
|
|
17403
17516
|
defaultOpened: Boolean,
|
|
17517
|
+
hideExpandIcon: Boolean,
|
|
17404
17518
|
expandIconToggle: Boolean,
|
|
17405
17519
|
switchToggleSide: Boolean,
|
|
17406
17520
|
denseToggle: Boolean,
|
|
@@ -17461,6 +17575,30 @@
|
|
|
17461
17575
|
|
|
17462
17576
|
activeToggleIcon () {
|
|
17463
17577
|
return this.disable !== true && (this.hasLink === true || this.expandIconToggle === true)
|
|
17578
|
+
},
|
|
17579
|
+
|
|
17580
|
+
headerSlotScope () {
|
|
17581
|
+
return {
|
|
17582
|
+
expanded: this.showing === true,
|
|
17583
|
+
detailsId: this.targetUid,
|
|
17584
|
+
toggle: this.toggle,
|
|
17585
|
+
show: this.show,
|
|
17586
|
+
hide: this.hide
|
|
17587
|
+
}
|
|
17588
|
+
},
|
|
17589
|
+
|
|
17590
|
+
toggleAriaAttrs () {
|
|
17591
|
+
const toggleAriaLabel = this.toggleAriaLabel !== void 0
|
|
17592
|
+
? this.toggleAriaLabel
|
|
17593
|
+
: this.$q.lang.label[ this.showing === true ? 'collapse' : 'expand' ](this.label);
|
|
17594
|
+
|
|
17595
|
+
return {
|
|
17596
|
+
role: 'button',
|
|
17597
|
+
'aria-expanded': this.showing === true ? 'true' : 'false',
|
|
17598
|
+
'aria-owns': this.targetUid,
|
|
17599
|
+
'aria-controls': this.targetUid,
|
|
17600
|
+
'aria-label': toggleAriaLabel
|
|
17601
|
+
}
|
|
17464
17602
|
}
|
|
17465
17603
|
},
|
|
17466
17604
|
|
|
@@ -17506,7 +17644,10 @@
|
|
|
17506
17644
|
|
|
17507
17645
|
if (this.activeToggleIcon === true) {
|
|
17508
17646
|
Object.assign(data, {
|
|
17509
|
-
attrs: {
|
|
17647
|
+
attrs: {
|
|
17648
|
+
tabindex: 0,
|
|
17649
|
+
...this.toggleAriaAttrs
|
|
17650
|
+
},
|
|
17510
17651
|
on: cache(this, 'inpExt', {
|
|
17511
17652
|
click: this.__toggleIcon,
|
|
17512
17653
|
keyup: this.__toggleIconKeyboard
|
|
@@ -17529,7 +17670,7 @@
|
|
|
17529
17670
|
let child;
|
|
17530
17671
|
|
|
17531
17672
|
if (this.$scopedSlots.header !== void 0) {
|
|
17532
|
-
child = [].concat(this.$scopedSlots.header(
|
|
17673
|
+
child = [].concat(this.$scopedSlots.header(this.headerSlotScope));
|
|
17533
17674
|
}
|
|
17534
17675
|
else {
|
|
17535
17676
|
child = [
|
|
@@ -17560,7 +17701,7 @@
|
|
|
17560
17701
|
);
|
|
17561
17702
|
}
|
|
17562
17703
|
|
|
17563
|
-
this.disable !== true && child[this.switchToggleSide === true ? 'unshift' : 'push'](
|
|
17704
|
+
this.disable !== true && this.hideExpandIcon !== true && child[this.switchToggleSide === true ? 'unshift' : 'push'](
|
|
17564
17705
|
this.__getToggleIcon(h)
|
|
17565
17706
|
);
|
|
17566
17707
|
|
|
@@ -17591,6 +17732,9 @@
|
|
|
17591
17732
|
|
|
17592
17733
|
data.attrs = this.linkProps.attrs;
|
|
17593
17734
|
}
|
|
17735
|
+
else {
|
|
17736
|
+
data.attrs = this.toggleAriaAttrs;
|
|
17737
|
+
}
|
|
17594
17738
|
}
|
|
17595
17739
|
|
|
17596
17740
|
return h(QItem, data, child)
|
|
@@ -17610,6 +17754,7 @@
|
|
|
17610
17754
|
h('div', {
|
|
17611
17755
|
staticClass: 'q-expansion-item__content relative-position',
|
|
17612
17756
|
style: this.contentStyle,
|
|
17757
|
+
attrs: { id: this.targetUid },
|
|
17613
17758
|
directives: [{ name: 'show', value: this.showing }]
|
|
17614
17759
|
}, slot(this, 'default'))
|
|
17615
17760
|
])
|
|
@@ -17647,6 +17792,7 @@
|
|
|
17647
17792
|
|
|
17648
17793
|
created () {
|
|
17649
17794
|
this.group !== void 0 && this.$root.$on(eventName, this.__eventHandler);
|
|
17795
|
+
this.targetUid = `e_${uid()}`;
|
|
17650
17796
|
},
|
|
17651
17797
|
|
|
17652
17798
|
beforeDestroy () {
|
|
@@ -17800,6 +17946,21 @@
|
|
|
17800
17946
|
return `q-fab__actions--${this.direction}` + (this.showing === true ? ' q-fab__actions--opened' : '')
|
|
17801
17947
|
},
|
|
17802
17948
|
|
|
17949
|
+
actionsAttrs () {
|
|
17950
|
+
const attrs = {
|
|
17951
|
+
id: this.targetUid
|
|
17952
|
+
};
|
|
17953
|
+
|
|
17954
|
+
if (this.showing === true) {
|
|
17955
|
+
attrs.role = 'menu';
|
|
17956
|
+
}
|
|
17957
|
+
else {
|
|
17958
|
+
attrs['aria-hidden'] = 'true';
|
|
17959
|
+
}
|
|
17960
|
+
|
|
17961
|
+
return attrs
|
|
17962
|
+
},
|
|
17963
|
+
|
|
17803
17964
|
iconHolderClasses () {
|
|
17804
17965
|
return this.showing === true ? 'q-fab__icon-holder--opened' : ''
|
|
17805
17966
|
},
|
|
@@ -17808,6 +17969,8 @@
|
|
|
17808
17969
|
return {
|
|
17809
17970
|
'aria-expanded': this.showing === true ? 'true' : 'false',
|
|
17810
17971
|
'aria-haspopup': 'true',
|
|
17972
|
+
'aria-controls': this.targetUid,
|
|
17973
|
+
'aria-owns': this.targetUid,
|
|
17811
17974
|
...this.qAttrs
|
|
17812
17975
|
}
|
|
17813
17976
|
},
|
|
@@ -17878,9 +18041,14 @@
|
|
|
17878
18041
|
|
|
17879
18042
|
h('div', {
|
|
17880
18043
|
staticClass: 'q-fab__actions flex no-wrap inline',
|
|
17881
|
-
class: this.actionsClasses
|
|
18044
|
+
class: this.actionsClasses,
|
|
18045
|
+
attrs: this.actionsAttrs
|
|
17882
18046
|
}, slot(this, 'default'))
|
|
17883
18047
|
])
|
|
18048
|
+
},
|
|
18049
|
+
|
|
18050
|
+
created () {
|
|
18051
|
+
this.targetUid = `fb_${uid()}`;
|
|
17884
18052
|
}
|
|
17885
18053
|
});
|
|
17886
18054
|
|
|
@@ -18127,11 +18295,13 @@
|
|
|
18127
18295
|
|
|
18128
18296
|
const index = ++this.validateIndex;
|
|
18129
18297
|
|
|
18130
|
-
|
|
18131
|
-
this.isDirty = true
|
|
18132
|
-
|
|
18298
|
+
const setDirty = this.innerLoading !== true
|
|
18299
|
+
? () => this.isDirty !== true && (this.isDirty = true)
|
|
18300
|
+
: () => {};
|
|
18133
18301
|
|
|
18134
18302
|
const update = (err, msg) => {
|
|
18303
|
+
err === true && setDirty();
|
|
18304
|
+
|
|
18135
18305
|
if (this.innerError !== err) {
|
|
18136
18306
|
this.innerError = err;
|
|
18137
18307
|
}
|
|
@@ -18154,7 +18324,7 @@
|
|
|
18154
18324
|
let res;
|
|
18155
18325
|
|
|
18156
18326
|
if (typeof rule === 'function') {
|
|
18157
|
-
res = rule(val);
|
|
18327
|
+
res = rule(val, testPattern);
|
|
18158
18328
|
}
|
|
18159
18329
|
else if (typeof rule === 'string' && testPattern[rule] !== void 0) {
|
|
18160
18330
|
res = testPattern[rule](val);
|
|
@@ -18220,81 +18390,8 @@
|
|
|
18220
18390
|
}
|
|
18221
18391
|
};
|
|
18222
18392
|
|
|
18223
|
-
/**
|
|
18224
|
-
* Based on the work of https://github.com/jchook/uuid-random
|
|
18225
|
-
*/
|
|
18226
|
-
|
|
18227
|
-
let
|
|
18228
|
-
buf,
|
|
18229
|
-
bufIdx = 0;
|
|
18230
|
-
const hexBytes = new Array(256);
|
|
18231
|
-
|
|
18232
|
-
// Pre-calculate toString(16) for speed
|
|
18233
|
-
for (let i = 0; i < 256; i++) {
|
|
18234
|
-
hexBytes[i] = (i + 0x100).toString(16).substr(1);
|
|
18235
|
-
}
|
|
18236
|
-
|
|
18237
|
-
// Use best available PRNG
|
|
18238
|
-
const randomBytes = (() => {
|
|
18239
|
-
// Node & Browser support
|
|
18240
|
-
const lib = typeof crypto !== 'undefined'
|
|
18241
|
-
? crypto
|
|
18242
|
-
: (
|
|
18243
|
-
typeof window !== 'undefined'
|
|
18244
|
-
? window.msCrypto // IE11
|
|
18245
|
-
: void 0
|
|
18246
|
-
);
|
|
18247
|
-
|
|
18248
|
-
if (lib !== void 0) {
|
|
18249
|
-
if (lib.randomBytes !== void 0) {
|
|
18250
|
-
return lib.randomBytes
|
|
18251
|
-
}
|
|
18252
|
-
if (lib.getRandomValues !== void 0) {
|
|
18253
|
-
return n => {
|
|
18254
|
-
var bytes = new Uint8Array(n);
|
|
18255
|
-
lib.getRandomValues(bytes);
|
|
18256
|
-
return bytes
|
|
18257
|
-
}
|
|
18258
|
-
}
|
|
18259
|
-
}
|
|
18260
|
-
|
|
18261
|
-
return n => {
|
|
18262
|
-
const r = [];
|
|
18263
|
-
for (let i = n; i > 0; i--) {
|
|
18264
|
-
r.push(Math.floor(Math.random() * 256));
|
|
18265
|
-
}
|
|
18266
|
-
return r
|
|
18267
|
-
}
|
|
18268
|
-
})();
|
|
18269
|
-
|
|
18270
|
-
// Buffer random numbers for speed
|
|
18271
|
-
// Reduce memory usage by decreasing this number (min 16)
|
|
18272
|
-
// or improve speed by increasing this number (try 16384)
|
|
18273
|
-
const BUFFER_SIZE = 4096;
|
|
18274
|
-
|
|
18275
|
-
function uid$2 () {
|
|
18276
|
-
// Buffer some random bytes for speed
|
|
18277
|
-
if (buf === void 0 || (bufIdx + 16 > BUFFER_SIZE)) {
|
|
18278
|
-
bufIdx = 0;
|
|
18279
|
-
buf = randomBytes(BUFFER_SIZE);
|
|
18280
|
-
}
|
|
18281
|
-
|
|
18282
|
-
const b = Array.prototype.slice.call(buf, bufIdx, (bufIdx += 16));
|
|
18283
|
-
b[6] = (b[6] & 0x0f) | 0x40;
|
|
18284
|
-
b[8] = (b[8] & 0x3f) | 0x80;
|
|
18285
|
-
|
|
18286
|
-
return hexBytes[b[0]] + hexBytes[b[1]] +
|
|
18287
|
-
hexBytes[b[2]] + hexBytes[b[3]] + '-' +
|
|
18288
|
-
hexBytes[b[4]] + hexBytes[b[5]] + '-' +
|
|
18289
|
-
hexBytes[b[6]] + hexBytes[b[7]] + '-' +
|
|
18290
|
-
hexBytes[b[8]] + hexBytes[b[9]] + '-' +
|
|
18291
|
-
hexBytes[b[10]] + hexBytes[b[11]] +
|
|
18292
|
-
hexBytes[b[12]] + hexBytes[b[13]] +
|
|
18293
|
-
hexBytes[b[14]] + hexBytes[b[15]]
|
|
18294
|
-
}
|
|
18295
|
-
|
|
18296
18393
|
function getTargetUid (val) {
|
|
18297
|
-
return val === void 0 ? `f_${uid
|
|
18394
|
+
return val === void 0 ? `f_${uid()}` : val
|
|
18298
18395
|
}
|
|
18299
18396
|
|
|
18300
18397
|
var QField = Vue.extend({
|
|
@@ -19021,11 +19118,13 @@
|
|
|
19021
19118
|
file.__key = file.webkitRelativePath + file.lastModified + file.name + file.size;
|
|
19022
19119
|
});
|
|
19023
19120
|
|
|
19024
|
-
|
|
19025
|
-
|
|
19026
|
-
|
|
19027
|
-
|
|
19028
|
-
|
|
19121
|
+
if (append === true) {
|
|
19122
|
+
// Avoid duplicate files
|
|
19123
|
+
const filenameMap = currentFileList.map(entry => entry.__key);
|
|
19124
|
+
files = filterFiles(files, rejectedFiles, 'duplicate', file => {
|
|
19125
|
+
return filenameMap.includes(file.__key) === false
|
|
19126
|
+
});
|
|
19127
|
+
}
|
|
19029
19128
|
|
|
19030
19129
|
if (files.length === 0) { return done() }
|
|
19031
19130
|
|
|
@@ -19663,79 +19762,73 @@
|
|
|
19663
19762
|
|
|
19664
19763
|
methods: {
|
|
19665
19764
|
validate (shouldFocus) {
|
|
19666
|
-
const promises = [];
|
|
19667
19765
|
const focus = typeof shouldFocus === 'boolean'
|
|
19668
19766
|
? shouldFocus
|
|
19669
19767
|
: this.noErrorFocus !== true;
|
|
19670
19768
|
|
|
19671
19769
|
const index = ++this.validateIndex;
|
|
19672
19770
|
|
|
19673
|
-
const
|
|
19771
|
+
const registeredComponents = this.getValidationComponents().filter(c => c.disable !== true);
|
|
19674
19772
|
|
|
19675
19773
|
const emit = (res, ref) => {
|
|
19676
19774
|
this.$emit('validation-' + (res === true ? 'success' : 'error'), ref);
|
|
19677
19775
|
};
|
|
19678
19776
|
|
|
19679
|
-
|
|
19680
|
-
const comp = components[i];
|
|
19777
|
+
const validateComponent = comp => {
|
|
19681
19778
|
const valid = comp.validate();
|
|
19682
19779
|
|
|
19683
|
-
|
|
19684
|
-
|
|
19685
|
-
valid
|
|
19686
|
-
|
|
19687
|
-
|
|
19688
|
-
|
|
19689
|
-
|
|
19690
|
-
}
|
|
19691
|
-
else if (valid !== true) {
|
|
19692
|
-
if (this.greedy === false) {
|
|
19693
|
-
emit(false, comp);
|
|
19694
|
-
|
|
19695
|
-
if (focus === true && typeof comp.focus === 'function') {
|
|
19696
|
-
comp.focus();
|
|
19697
|
-
}
|
|
19780
|
+
return typeof valid.then === 'function'
|
|
19781
|
+
? valid.then(
|
|
19782
|
+
valid => ({ valid, comp }),
|
|
19783
|
+
err => ({ valid: false, comp, err })
|
|
19784
|
+
)
|
|
19785
|
+
: Promise.resolve({ valid, comp })
|
|
19786
|
+
};
|
|
19698
19787
|
|
|
19699
|
-
|
|
19700
|
-
|
|
19788
|
+
const errorsPromise = this.greedy === true
|
|
19789
|
+
? Promise
|
|
19790
|
+
.all(registeredComponents.map(validateComponent))
|
|
19791
|
+
.then(res => res.filter(r => r.valid !== true))
|
|
19792
|
+
: registeredComponents
|
|
19793
|
+
.reduce(
|
|
19794
|
+
(acc, comp) => acc.then(() => {
|
|
19795
|
+
return validateComponent(comp).then(r => {
|
|
19796
|
+
if (r.valid === false) { return Promise.reject(r) }
|
|
19797
|
+
})
|
|
19798
|
+
}),
|
|
19799
|
+
Promise.resolve()
|
|
19800
|
+
)
|
|
19801
|
+
.catch(error => [ error ]);
|
|
19701
19802
|
|
|
19702
|
-
|
|
19803
|
+
return errorsPromise.then(errors => {
|
|
19804
|
+
if (errors.length === 0) {
|
|
19805
|
+
index === this.validateIndex && emit(true);
|
|
19806
|
+
return true
|
|
19703
19807
|
}
|
|
19704
|
-
}
|
|
19705
19808
|
|
|
19706
|
-
|
|
19707
|
-
|
|
19708
|
-
return Promise.resolve(true)
|
|
19709
|
-
}
|
|
19809
|
+
if (index === this.validateIndex) {
|
|
19810
|
+
const { comp, err } = errors[0];
|
|
19710
19811
|
|
|
19711
|
-
|
|
19712
|
-
|
|
19713
|
-
const errors = res.filter(r => r.valid !== true);
|
|
19714
|
-
|
|
19715
|
-
if (errors.length === 0) {
|
|
19716
|
-
index === this.validateIndex && emit(true);
|
|
19717
|
-
return true
|
|
19718
|
-
}
|
|
19812
|
+
err !== void 0 && console.error(err);
|
|
19813
|
+
emit(false, comp);
|
|
19719
19814
|
|
|
19720
|
-
|
|
19815
|
+
if (focus === true) {
|
|
19816
|
+
// Try to focus first mounted and active component
|
|
19817
|
+
const activeError = errors.find(({ comp }) => (
|
|
19818
|
+
typeof comp.focus === 'function' &&
|
|
19819
|
+
comp._isBeingDestroyed !== true &&
|
|
19820
|
+
comp._isDestroyed !== true &&
|
|
19821
|
+
comp._inactive !== true
|
|
19822
|
+
));
|
|
19721
19823
|
|
|
19722
|
-
|
|
19723
|
-
|
|
19724
|
-
|
|
19725
|
-
emit(false, comp);
|
|
19726
|
-
|
|
19727
|
-
if (
|
|
19728
|
-
focus === true &&
|
|
19729
|
-
valid !== true &&
|
|
19730
|
-
typeof comp.focus === 'function'
|
|
19731
|
-
) {
|
|
19732
|
-
comp.focus();
|
|
19824
|
+
if (activeError !== void 0) {
|
|
19825
|
+
activeError.comp.focus();
|
|
19733
19826
|
}
|
|
19734
19827
|
}
|
|
19735
|
-
|
|
19736
|
-
return false
|
|
19737
19828
|
}
|
|
19738
|
-
|
|
19829
|
+
|
|
19830
|
+
return false
|
|
19831
|
+
})
|
|
19739
19832
|
},
|
|
19740
19833
|
|
|
19741
19834
|
resetValidation () {
|
|
@@ -21465,21 +21558,24 @@
|
|
|
21465
21558
|
|
|
21466
21559
|
// textarea only
|
|
21467
21560
|
__adjustHeight () {
|
|
21468
|
-
|
|
21469
|
-
|
|
21470
|
-
|
|
21471
|
-
|
|
21561
|
+
requestAnimationFrame(() => {
|
|
21562
|
+
const inp = this.$refs.input;
|
|
21563
|
+
if (inp !== void 0) {
|
|
21564
|
+
const parentStyle = inp.parentNode.style;
|
|
21565
|
+
const { overflow } = inp.style;
|
|
21472
21566
|
|
|
21473
|
-
|
|
21474
|
-
|
|
21475
|
-
|
|
21476
|
-
|
|
21477
|
-
|
|
21567
|
+
// reset height of textarea to a small size to detect the real height
|
|
21568
|
+
// but keep the total control size the same
|
|
21569
|
+
// Firefox rulez #14263, #14344
|
|
21570
|
+
this.$q.platform.is.firefox !== true && (inp.style.overflow = 'hidden');
|
|
21571
|
+
inp.style.height = '1px';
|
|
21572
|
+
parentStyle.marginBottom = (inp.scrollHeight - 1) + 'px';
|
|
21478
21573
|
|
|
21479
|
-
|
|
21480
|
-
|
|
21481
|
-
|
|
21482
|
-
|
|
21574
|
+
inp.style.height = inp.scrollHeight + 'px';
|
|
21575
|
+
inp.style.overflow = overflow;
|
|
21576
|
+
parentStyle.marginBottom = '';
|
|
21577
|
+
}
|
|
21578
|
+
});
|
|
21483
21579
|
},
|
|
21484
21580
|
|
|
21485
21581
|
__onChange (e) {
|
|
@@ -26934,6 +27030,7 @@
|
|
|
26934
27030
|
tabindex: this.tabindex,
|
|
26935
27031
|
role: 'combobox',
|
|
26936
27032
|
'aria-label': this.label,
|
|
27033
|
+
'aria-readonly': this.readonly === true ? 'true' : 'false',
|
|
26937
27034
|
'aria-autocomplete': this.useInput === true ? 'list' : 'none',
|
|
26938
27035
|
'aria-expanded': this.menu === true ? 'true' : 'false',
|
|
26939
27036
|
'aria-owns': `${this.targetUid}_lb`,
|
|
@@ -26954,10 +27051,6 @@
|
|
|
26954
27051
|
'aria-multiselectable': this.multiple === true ? 'true' : 'false'
|
|
26955
27052
|
};
|
|
26956
27053
|
|
|
26957
|
-
if (this.optionIndex >= 0) {
|
|
26958
|
-
attrs['aria-activedescendant'] = `${this.targetUid}_${this.optionIndex}`;
|
|
26959
|
-
}
|
|
26960
|
-
|
|
26961
27054
|
return attrs
|
|
26962
27055
|
}
|
|
26963
27056
|
},
|
|
@@ -33103,7 +33196,7 @@
|
|
|
33103
33196
|
|
|
33104
33197
|
if (rowEl !== null) {
|
|
33105
33198
|
const scrollTarget = this.$el.querySelector('.q-table__middle.scroll');
|
|
33106
|
-
const
|
|
33199
|
+
const offsetTop = rowEl.offsetTop - this.virtualScrollStickySizeStart;
|
|
33107
33200
|
const direction = offsetTop < scrollTarget.scrollTop ? 'decrease' : 'increase';
|
|
33108
33201
|
|
|
33109
33202
|
scrollTarget.scrollTop = offsetTop;
|
|
@@ -40513,6 +40606,121 @@
|
|
|
40513
40606
|
return openWindow(url, reject, windowFeatures)
|
|
40514
40607
|
};
|
|
40515
40608
|
|
|
40609
|
+
function parsePromises (sequentialPromises) {
|
|
40610
|
+
const isList = Array.isArray(sequentialPromises);
|
|
40611
|
+
|
|
40612
|
+
if (isList === true) {
|
|
40613
|
+
const totalJobs = sequentialPromises.length;
|
|
40614
|
+
return {
|
|
40615
|
+
isList,
|
|
40616
|
+
totalJobs,
|
|
40617
|
+
resultAggregator: Array(totalJobs).fill(null)
|
|
40618
|
+
}
|
|
40619
|
+
}
|
|
40620
|
+
|
|
40621
|
+
const resultKeys = Object.keys(sequentialPromises);
|
|
40622
|
+
const resultAggregator = {};
|
|
40623
|
+
resultKeys.forEach(keyName => { resultAggregator[ keyName ] = null; });
|
|
40624
|
+
|
|
40625
|
+
return {
|
|
40626
|
+
isList,
|
|
40627
|
+
totalJobs: resultKeys.length,
|
|
40628
|
+
resultAggregator,
|
|
40629
|
+
resultKeys
|
|
40630
|
+
}
|
|
40631
|
+
}
|
|
40632
|
+
|
|
40633
|
+
/**
|
|
40634
|
+
* Run a list of Promises sequentially, optionally on multiple threads.
|
|
40635
|
+
*
|
|
40636
|
+
* @param {*} sequentialPromises - Array of Functions or Object with Functions as values
|
|
40637
|
+
* Array of Function form: [ (resultAggregator: Array) => Promise<any>, ... ]
|
|
40638
|
+
* Object form: { [key: string]: (resultAggregator: object) => Promise<any>, ... }
|
|
40639
|
+
* @param {*} opts - Optional options Object
|
|
40640
|
+
* Object form: { threadsNumber?: number, abortOnFail?: boolean }
|
|
40641
|
+
* Default: { threadsNumber: 1, abortOnFail: true }
|
|
40642
|
+
* When configuring threadsNumber AND using http requests, be
|
|
40643
|
+
* aware of the maximum threads that the hosting browser
|
|
40644
|
+
* supports (usually 3); any number of threads above that
|
|
40645
|
+
* won't add any real benefits
|
|
40646
|
+
* @returns Promise<Array<Object> | Object>
|
|
40647
|
+
* With opts.abortOnFail set to true (which is default):
|
|
40648
|
+
* When sequentialPromises param is Array:
|
|
40649
|
+
* The Promise resolves with an Array of Objects of the following form:
|
|
40650
|
+
* [ { key: number, status: 'fulfilled', value: any }, ... ]
|
|
40651
|
+
* The Promise rejects with an Object of the following form:
|
|
40652
|
+
* { key: number, status: 'rejected', reason: Error, resultAggregator: array }
|
|
40653
|
+
* When sequentialPromises param is Object:
|
|
40654
|
+
* The Promise resolves with an Object of the following form:
|
|
40655
|
+
* { [key: string]: { key: string, status: 'fulfilled', value: any }, ... }
|
|
40656
|
+
* The Promise rejects with an Object of the following form:
|
|
40657
|
+
* { key: string, status: 'rejected', reason: Error, resultAggregator: object }
|
|
40658
|
+
* With opts.abortOnFail set to false:
|
|
40659
|
+
* The Promise is never rejected (no catch() needed)
|
|
40660
|
+
* The Promise resolves with:
|
|
40661
|
+
* An Array of Objects (when sequentialPromises param is also an Array) of the following form:
|
|
40662
|
+
* [ { key: number, status: 'fulfilled', value: any } | { status: 'rejected', reason: Error }, ... ]
|
|
40663
|
+
* An Object (when sequentialPromises param is also an Object) of the following form:
|
|
40664
|
+
* { [key: string]: { key: string, status: 'fulfilled', value: any } | { key: string, status: 'rejected', reason: Error }, ... }
|
|
40665
|
+
*/
|
|
40666
|
+
function runSequentialPromises (
|
|
40667
|
+
sequentialPromises,
|
|
40668
|
+
{ threadsNumber = 1, abortOnFail = true } = {}
|
|
40669
|
+
) {
|
|
40670
|
+
let jobIndex = -1, hasAborted = false;
|
|
40671
|
+
|
|
40672
|
+
const { isList, totalJobs, resultAggregator, resultKeys } = parsePromises(sequentialPromises);
|
|
40673
|
+
|
|
40674
|
+
const getPromiseThread = () => new Promise((resolve, reject) => {
|
|
40675
|
+
function runNextPromise () {
|
|
40676
|
+
const currentJobIndex = ++jobIndex;
|
|
40677
|
+
|
|
40678
|
+
if (hasAborted === true || currentJobIndex >= totalJobs) {
|
|
40679
|
+
resolve();
|
|
40680
|
+
return
|
|
40681
|
+
}
|
|
40682
|
+
|
|
40683
|
+
const key = isList === true ? currentJobIndex : resultKeys[ currentJobIndex ];
|
|
40684
|
+
|
|
40685
|
+
sequentialPromises[ key ](resultAggregator)
|
|
40686
|
+
.then(value => {
|
|
40687
|
+
if (hasAborted === true) {
|
|
40688
|
+
resolve();
|
|
40689
|
+
return // early exit
|
|
40690
|
+
}
|
|
40691
|
+
|
|
40692
|
+
resultAggregator[ key ] = { key, status: 'fulfilled', value };
|
|
40693
|
+
|
|
40694
|
+
// timeout so it doesn't interfere with the .catch() below
|
|
40695
|
+
setTimeout(runNextPromise);
|
|
40696
|
+
})
|
|
40697
|
+
.catch(reason => {
|
|
40698
|
+
if (hasAborted === true) {
|
|
40699
|
+
resolve();
|
|
40700
|
+
return // early exit
|
|
40701
|
+
}
|
|
40702
|
+
|
|
40703
|
+
const result = { key, status: 'rejected', reason };
|
|
40704
|
+
resultAggregator[ key ] = result;
|
|
40705
|
+
|
|
40706
|
+
if (abortOnFail === true) {
|
|
40707
|
+
hasAborted = true;
|
|
40708
|
+
reject({ ...result, resultAggregator });
|
|
40709
|
+
return // early exit
|
|
40710
|
+
}
|
|
40711
|
+
|
|
40712
|
+
// timeout so no interference
|
|
40713
|
+
setTimeout(runNextPromise);
|
|
40714
|
+
});
|
|
40715
|
+
}
|
|
40716
|
+
|
|
40717
|
+
runNextPromise();
|
|
40718
|
+
});
|
|
40719
|
+
|
|
40720
|
+
const threads = Array(threadsNumber).fill(getPromiseThread());
|
|
40721
|
+
return Promise.all(threads).then(() => resultAggregator)
|
|
40722
|
+
}
|
|
40723
|
+
|
|
40516
40724
|
|
|
40517
40725
|
|
|
40518
40726
|
var utils = /*#__PURE__*/Object.freeze({
|
|
@@ -40529,12 +40737,14 @@
|
|
|
40529
40737
|
format: format,
|
|
40530
40738
|
frameDebounce: frameDebounce,
|
|
40531
40739
|
noop: noop,
|
|
40740
|
+
is: is,
|
|
40532
40741
|
openURL: openUrl,
|
|
40533
40742
|
morph: morph,
|
|
40534
40743
|
patterns: patterns,
|
|
40744
|
+
runSequentialPromises: runSequentialPromises,
|
|
40535
40745
|
scroll: scroll,
|
|
40536
40746
|
throttle: throttle,
|
|
40537
|
-
uid: uid
|
|
40747
|
+
uid: uid
|
|
40538
40748
|
});
|
|
40539
40749
|
|
|
40540
40750
|
Vue.use({ install }, {
|