quasar 2.7.7 → 2.8.1

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.
Files changed (175) hide show
  1. package/dist/api/Loading.json +57 -1
  2. package/dist/api/QBtnDropdown.json +4 -0
  3. package/dist/api/QEditor.json +105 -97
  4. package/dist/api/QField.json +6 -0
  5. package/dist/api/QFile.json +6 -0
  6. package/dist/api/QInput.json +6 -0
  7. package/dist/api/QSelect.json +6 -0
  8. package/dist/api/QTable.json +36 -49
  9. package/dist/api/QUploader.json +86 -8
  10. package/dist/icon-set/bootstrap-icons.umd.prod.js +1 -1
  11. package/dist/icon-set/eva-icons.umd.prod.js +1 -1
  12. package/dist/icon-set/fontawesome-v5-pro.umd.prod.js +1 -1
  13. package/dist/icon-set/fontawesome-v5.umd.prod.js +1 -1
  14. package/dist/icon-set/fontawesome-v6-pro.umd.prod.js +1 -1
  15. package/dist/icon-set/fontawesome-v6.umd.prod.js +1 -1
  16. package/dist/icon-set/ionicons-v4.umd.prod.js +1 -1
  17. package/dist/icon-set/line-awesome.umd.prod.js +1 -1
  18. package/dist/icon-set/material-icons-outlined.umd.prod.js +1 -1
  19. package/dist/icon-set/material-icons-round.umd.prod.js +1 -1
  20. package/dist/icon-set/material-icons-sharp.umd.prod.js +1 -1
  21. package/dist/icon-set/material-icons.umd.prod.js +1 -1
  22. package/dist/icon-set/material-symbols-outlined.umd.prod.js +1 -1
  23. package/dist/icon-set/material-symbols-rounded.umd.prod.js +1 -1
  24. package/dist/icon-set/material-symbols-sharp.umd.prod.js +1 -1
  25. package/dist/icon-set/mdi-v3.umd.prod.js +1 -1
  26. package/dist/icon-set/mdi-v4.umd.prod.js +1 -1
  27. package/dist/icon-set/mdi-v5.umd.prod.js +1 -1
  28. package/dist/icon-set/mdi-v6.umd.prod.js +1 -1
  29. package/dist/icon-set/svg-bootstrap-icons.umd.prod.js +1 -1
  30. package/dist/icon-set/svg-eva-icons.umd.prod.js +1 -1
  31. package/dist/icon-set/svg-fontawesome-v5.umd.prod.js +1 -1
  32. package/dist/icon-set/svg-fontawesome-v6.umd.prod.js +2 -2
  33. package/dist/icon-set/svg-ionicons-v4.umd.prod.js +1 -1
  34. package/dist/icon-set/svg-ionicons-v5.umd.prod.js +1 -1
  35. package/dist/icon-set/svg-ionicons-v6.umd.prod.js +1 -1
  36. package/dist/icon-set/svg-line-awesome.umd.prod.js +1 -1
  37. package/dist/icon-set/svg-material-icons-outlined.umd.prod.js +1 -1
  38. package/dist/icon-set/svg-material-icons-round.umd.prod.js +1 -1
  39. package/dist/icon-set/svg-material-icons-sharp.umd.prod.js +1 -1
  40. package/dist/icon-set/svg-material-icons.umd.prod.js +1 -1
  41. package/dist/icon-set/svg-material-symbols-outlined.umd.prod.js +2 -2
  42. package/dist/icon-set/svg-material-symbols-rounded.umd.prod.js +2 -2
  43. package/dist/icon-set/svg-material-symbols-sharp.umd.prod.js +2 -2
  44. package/dist/icon-set/svg-mdi-v6.umd.prod.js +1 -1
  45. package/dist/icon-set/svg-themify.umd.prod.js +1 -1
  46. package/dist/icon-set/themify.umd.prod.js +1 -1
  47. package/dist/lang/ar-TN.umd.prod.js +1 -1
  48. package/dist/lang/ar.umd.prod.js +1 -1
  49. package/dist/lang/az-Latn.umd.prod.js +1 -1
  50. package/dist/lang/bg.umd.prod.js +1 -1
  51. package/dist/lang/bn.umd.prod.js +1 -1
  52. package/dist/lang/ca.umd.prod.js +1 -1
  53. package/dist/lang/cs.umd.prod.js +1 -1
  54. package/dist/lang/da.umd.prod.js +1 -1
  55. package/dist/lang/de.umd.prod.js +1 -1
  56. package/dist/lang/el.umd.prod.js +1 -1
  57. package/dist/lang/en-GB.umd.prod.js +1 -1
  58. package/dist/lang/en-US.umd.prod.js +1 -1
  59. package/dist/lang/eo.umd.prod.js +1 -1
  60. package/dist/lang/es.umd.prod.js +1 -1
  61. package/dist/lang/et.umd.prod.js +1 -1
  62. package/dist/lang/eu.umd.prod.js +1 -1
  63. package/dist/lang/fa-IR.umd.prod.js +1 -1
  64. package/dist/lang/fa.umd.prod.js +1 -1
  65. package/dist/lang/fi.umd.prod.js +1 -1
  66. package/dist/lang/fr.umd.prod.js +1 -1
  67. package/dist/lang/gn.umd.prod.js +1 -1
  68. package/dist/lang/he.umd.prod.js +1 -1
  69. package/dist/lang/hr.umd.prod.js +1 -1
  70. package/dist/lang/hu.umd.prod.js +1 -1
  71. package/dist/lang/id.umd.prod.js +1 -1
  72. package/dist/lang/is.umd.prod.js +1 -1
  73. package/dist/lang/it.umd.prod.js +1 -1
  74. package/dist/lang/ja.umd.prod.js +1 -1
  75. package/dist/lang/km.umd.prod.js +1 -1
  76. package/dist/lang/ko-KR.umd.prod.js +1 -1
  77. package/dist/lang/kur-CKB.umd.prod.js +1 -1
  78. package/dist/lang/kz.umd.prod.js +1 -1
  79. package/dist/lang/lt.umd.prod.js +1 -1
  80. package/dist/lang/lu.umd.prod.js +1 -1
  81. package/dist/lang/lv.umd.prod.js +1 -1
  82. package/dist/lang/ml.umd.prod.js +1 -1
  83. package/dist/lang/mm.umd.prod.js +1 -1
  84. package/dist/lang/ms.umd.prod.js +1 -1
  85. package/dist/lang/my.umd.prod.js +1 -1
  86. package/dist/lang/nb-NO.umd.prod.js +1 -1
  87. package/dist/lang/nl.umd.prod.js +1 -1
  88. package/dist/lang/pl.umd.prod.js +1 -1
  89. package/dist/lang/pt-BR.umd.prod.js +1 -1
  90. package/dist/lang/pt.umd.prod.js +1 -1
  91. package/dist/lang/ro.umd.prod.js +1 -1
  92. package/dist/lang/ru.umd.prod.js +1 -1
  93. package/dist/lang/sk.umd.prod.js +1 -1
  94. package/dist/lang/sl.umd.prod.js +1 -1
  95. package/dist/lang/sm.umd.prod.js +1 -1
  96. package/dist/lang/sr-CYR.umd.prod.js +1 -1
  97. package/dist/lang/sr.umd.prod.js +1 -1
  98. package/dist/lang/sv.umd.prod.js +1 -1
  99. package/dist/lang/ta.umd.prod.js +1 -1
  100. package/dist/lang/th.umd.prod.js +1 -1
  101. package/dist/lang/tr.umd.prod.js +1 -1
  102. package/dist/lang/ug.umd.prod.js +1 -1
  103. package/dist/lang/uk.umd.prod.js +1 -1
  104. package/dist/lang/uz-Cyrl.umd.prod.js +1 -1
  105. package/dist/lang/uz-Latn.umd.prod.js +1 -1
  106. package/dist/lang/vi.umd.prod.js +1 -1
  107. package/dist/lang/zh-CN.umd.prod.js +1 -1
  108. package/dist/lang/zh-TW.umd.prod.js +1 -1
  109. package/dist/quasar.cjs.prod.js +2 -2
  110. package/dist/quasar.esm.js +39647 -0
  111. package/dist/quasar.esm.prod.js +2 -2
  112. package/dist/quasar.sass +1 -1
  113. package/dist/quasar.umd.js +355 -295
  114. package/dist/quasar.umd.prod.js +2 -2
  115. package/dist/transforms/import-map.json +1 -0
  116. package/dist/types/index.d.ts +223 -117
  117. package/dist/web-types/web-types.json +6 -1
  118. package/package.json +1 -1
  119. package/src/components/banner/QBanner.js +2 -2
  120. package/src/components/bar/QBar.js +2 -2
  121. package/src/components/btn-dropdown/QBtnDropdown.js +8 -2
  122. package/src/components/btn-dropdown/QBtnDropdown.json +5 -0
  123. package/src/components/card/QCard.js +2 -2
  124. package/src/components/carousel/QCarousel.js +1 -1
  125. package/src/components/date/QDate.js +6 -6
  126. package/src/components/dialog-plugin/DialogPlugin.js +1 -1
  127. package/src/components/editor/QEditor.js +5 -5
  128. package/src/components/editor/QEditor.json +76 -67
  129. package/src/components/infinite-scroll/QInfiniteScroll.js +7 -7
  130. package/src/components/page-sticky/use-page-sticky.js +1 -2
  131. package/src/components/popup-edit/QPopupEdit.js +10 -10
  132. package/src/components/popup-proxy/QPopupProxy.js +7 -7
  133. package/src/components/pull-to-refresh/QPullToRefresh.js +3 -3
  134. package/src/components/range/QRange.js +5 -1
  135. package/src/components/resize-observer/QResizeObserver.js +6 -6
  136. package/src/components/scroll-area/QScrollArea.js +25 -25
  137. package/src/components/scroll-observer/QScrollObserver.js +3 -3
  138. package/src/components/select/QSelect.js +2 -1
  139. package/src/components/slider/QSlider.js +5 -1
  140. package/src/components/slider/use-slider.js +1 -1
  141. package/src/components/table/QTable.json +28 -50
  142. package/src/components/table/table-column-selection.js +1 -1
  143. package/src/components/table/table-pagination.js +0 -4
  144. package/src/components/table/table-sort.js +1 -1
  145. package/src/components/time/QTime.js +5 -5
  146. package/src/components/tree/QTree.js +2 -2
  147. package/src/components/uploader/QUploader.json +107 -0
  148. package/src/components/uploader/__tests__/QUploader.spec.js +33 -2
  149. package/src/components/uploader/uploader-core.js +48 -53
  150. package/src/composables/private/use-field.js +5 -4
  151. package/src/composables/private/use-file.js +1 -0
  152. package/src/composables/private/use-panel.js +7 -7
  153. package/src/composables/private/use-portal.js +7 -7
  154. package/src/composables/private/use-validate.json +7 -0
  155. package/src/directives/ClosePopup.js +4 -4
  156. package/src/directives/Intersection.js +1 -1
  157. package/src/index.dev.js +16 -0
  158. package/src/{index.all.js → index.ssr.js} +0 -0
  159. package/src/install-quasar.js +1 -1
  160. package/src/plugins/Loading.js +122 -73
  161. package/src/plugins/Loading.json +48 -1
  162. package/src/plugins/LoadingBar.js +1 -1
  163. package/src/plugins/Notify.js +1 -1
  164. package/src/utils/create-uploader-component.js +1 -1
  165. package/src/utils/date.js +1 -1
  166. package/src/utils/dom.js +2 -5
  167. package/src/utils/{private/is.js → is.js} +11 -7
  168. package/src/utils/morph.js +1 -1
  169. package/src/utils/open-url.js +7 -2
  170. package/src/utils/private/click-outside.js +3 -3
  171. package/src/utils/private/date-persian.js +12 -12
  172. package/src/utils/private/portal.js +24 -24
  173. package/src/utils/private/vm.js +10 -9
  174. package/src/utils/private/web-storage.js +1 -1
  175. package/src/utils.js +2 -0
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * Quasar Framework v2.7.7
2
+ * Quasar Framework v2.8.1
3
3
  * (c) 2015-present Razvan Stoenescu
4
4
  * Released under the MIT License.
5
5
  */
@@ -1401,11 +1401,6 @@
1401
1401
  globalConfigIsFrozen = true;
1402
1402
  }
1403
1403
 
1404
- const
1405
- hasMap = typeof Map === 'function',
1406
- hasSet = typeof Set === 'function',
1407
- hasArrayBuffer = typeof ArrayBuffer === 'function';
1408
-
1409
1404
  function isDeepEqual (a, b) {
1410
1405
  if (a === b) {
1411
1406
  return true
@@ -1434,7 +1429,7 @@
1434
1429
  return true
1435
1430
  }
1436
1431
 
1437
- if (hasMap === true && a.constructor === Map) {
1432
+ if (a.constructor === Map) {
1438
1433
  if (a.size !== b.size) {
1439
1434
  return false
1440
1435
  }
@@ -1458,7 +1453,7 @@
1458
1453
  return true
1459
1454
  }
1460
1455
 
1461
- if (hasSet === true && a.constructor === Set) {
1456
+ if (a.constructor === Set) {
1462
1457
  if (a.size !== b.size) {
1463
1458
  return false
1464
1459
  }
@@ -1474,7 +1469,7 @@
1474
1469
  return true
1475
1470
  }
1476
1471
 
1477
- if (hasArrayBuffer === true && a.buffer != null && a.buffer.constructor === ArrayBuffer) {
1472
+ if (a.buffer != null && a.buffer.constructor === ArrayBuffer) {
1478
1473
  length = a.length;
1479
1474
 
1480
1475
  if (length !== b.length) {
@@ -1541,6 +1536,14 @@
1541
1536
  return typeof v === 'number' && isFinite(v)
1542
1537
  }
1543
1538
 
1539
+ var is = {
1540
+ deepEqual: isDeepEqual,
1541
+ object: isObject,
1542
+ date: isDate,
1543
+ regexp: isRegexp,
1544
+ number: isNumber
1545
+ };
1546
+
1544
1547
  const autoInstalledPlugins = [
1545
1548
  Platform,
1546
1549
  Body,
@@ -1603,7 +1606,7 @@
1603
1606
  }
1604
1607
 
1605
1608
  var installQuasar = function (parentApp, opts = {}) {
1606
- const $q = { version: '2.7.7' };
1609
+ const $q = { version: '2.8.1' };
1607
1610
 
1608
1611
  if (globalConfigIsFrozen === false) {
1609
1612
  if (opts.config !== void 0) {
@@ -2396,8 +2399,8 @@
2396
2399
  },
2397
2400
 
2398
2401
  setup (props, { slots }) {
2399
- const vm = vue.getCurrentInstance();
2400
- const isDark = useDark(props, vm.proxy.$q);
2402
+ const { proxy: { $q } } = vue.getCurrentInstance();
2403
+ const isDark = useDark(props, $q);
2401
2404
 
2402
2405
  const classes = vue.computed(() =>
2403
2406
  'q-banner row items-center'
@@ -2445,8 +2448,8 @@
2445
2448
  },
2446
2449
 
2447
2450
  setup (props, { slots }) {
2448
- const vm = vue.getCurrentInstance();
2449
- const isDark = useDark(props, vm.proxy.$q);
2451
+ const { proxy: { $q } } = vue.getCurrentInstance();
2452
+ const isDark = useDark(props, $q);
2450
2453
 
2451
2454
  const classes = vue.computed(() =>
2452
2455
  'q-bar row no-wrap items-center'
@@ -2491,20 +2494,20 @@
2491
2494
  })
2492
2495
  }
2493
2496
 
2494
- // used directly by docs too
2495
- function getParentVm (vm) {
2496
- if (Object(vm.$parent) === vm.$parent) {
2497
- return vm.$parent
2497
+ // copied to docs too
2498
+ function getParentProxy (proxy) {
2499
+ if (Object(proxy.$parent) === proxy.$parent) {
2500
+ return proxy.$parent
2498
2501
  }
2499
2502
 
2500
- vm = vm.$.parent;
2503
+ let { parent } = proxy.$;
2501
2504
 
2502
- while (Object(vm) === vm) {
2503
- if (Object(vm.proxy) === vm.proxy) {
2504
- return vm.proxy
2505
+ while (Object(parent) === parent) {
2506
+ if (Object(parent.proxy) === parent.proxy) {
2507
+ return parent.proxy
2505
2508
  }
2506
2509
 
2507
- vm = vm.parent;
2510
+ parent = parent.parent;
2508
2511
  }
2509
2512
  }
2510
2513
 
@@ -3066,10 +3069,7 @@
3066
3069
  }
3067
3070
  }
3068
3071
 
3069
- const target = vue.isRef(el) === true
3070
- ? el.value
3071
- : el;
3072
-
3072
+ const target = vue.unref(el);
3073
3073
  if (target) {
3074
3074
  return target.$el || target
3075
3075
  }
@@ -4345,58 +4345,58 @@
4345
4345
  }
4346
4346
  }
4347
4347
 
4348
- const portalList = [];
4348
+ const portalProxyList = [];
4349
4349
 
4350
- function getPortalVm (el) {
4351
- return portalList.find(vm =>
4352
- vm.__qPortalInnerRef.value !== null
4353
- && vm.__qPortalInnerRef.value.contains(el)
4350
+ function getPortalProxy (el) {
4351
+ return portalProxyList.find(proxy =>
4352
+ proxy.__qPortalInnerRef.value !== null
4353
+ && proxy.__qPortalInnerRef.value.contains(el)
4354
4354
  )
4355
4355
  }
4356
4356
 
4357
- function closePortalMenus (vm, evt) {
4357
+ function closePortalMenus (proxy, evt) {
4358
4358
  do {
4359
- if (vm.$options.name === 'QMenu') {
4360
- vm.hide(evt);
4359
+ if (proxy.$options.name === 'QMenu') {
4360
+ proxy.hide(evt);
4361
4361
 
4362
4362
  // is this a point of separation?
4363
- if (vm.$props.separateClosePopup === true) {
4364
- return getParentVm(vm)
4363
+ if (proxy.$props.separateClosePopup === true) {
4364
+ return getParentProxy(proxy)
4365
4365
  }
4366
4366
  }
4367
- else if (vm.__qPortalInnerRef !== void 0) {
4367
+ else if (proxy.__qPortalInnerRef !== void 0) {
4368
4368
  // treat it as point of separation if parent is QPopupProxy
4369
4369
  // (so mobile matches desktop behavior)
4370
4370
  // and hide it too
4371
- const parent = getParentVm(vm);
4371
+ const parent = getParentProxy(proxy);
4372
4372
 
4373
4373
  if (parent !== void 0 && parent.$options.name === 'QPopupProxy') {
4374
- vm.hide(evt);
4374
+ proxy.hide(evt);
4375
4375
  return parent
4376
4376
  }
4377
4377
  else {
4378
- return vm
4378
+ return proxy
4379
4379
  }
4380
4380
  }
4381
4381
 
4382
- vm = getParentVm(vm);
4383
- } while (vm !== void 0 && vm !== null)
4382
+ proxy = getParentProxy(proxy);
4383
+ } while (proxy !== void 0 && proxy !== null)
4384
4384
  }
4385
4385
 
4386
- function closePortals (vm, evt, depth) {
4387
- while (depth !== 0 && vm !== void 0 && vm !== null) {
4388
- if (vm.__qPortalInnerRef !== void 0) {
4386
+ function closePortals (proxy, evt, depth) {
4387
+ while (depth !== 0 && proxy !== void 0 && proxy !== null) {
4388
+ if (proxy.__qPortalInnerRef !== void 0) {
4389
4389
  depth--;
4390
4390
 
4391
- if (vm.$options.name === 'QMenu') {
4392
- vm = closePortalMenus(vm, evt);
4391
+ if (proxy.$options.name === 'QMenu') {
4392
+ proxy = closePortalMenus(proxy, evt);
4393
4393
  continue
4394
4394
  }
4395
4395
 
4396
- vm.hide(evt);
4396
+ proxy.hide(evt);
4397
4397
  }
4398
4398
 
4399
- vm = getParentVm(vm);
4399
+ proxy = getParentProxy(proxy);
4400
4400
  }
4401
4401
  }
4402
4402
 
@@ -4448,7 +4448,7 @@
4448
4448
  portalIsActive.value = true;
4449
4449
 
4450
4450
  // register portal
4451
- portalList.push(vm.proxy);
4451
+ portalProxyList.push(vm.proxy);
4452
4452
 
4453
4453
  addFocusWaitFlag(focusObj);
4454
4454
  }
@@ -4463,9 +4463,9 @@
4463
4463
  portalIsActive.value = false;
4464
4464
 
4465
4465
  // unregister portal
4466
- const index = portalList.indexOf(vm.proxy);
4467
- if (index > -1) {
4468
- portalList.splice(index, 1);
4466
+ const index = portalProxyList.indexOf(vm.proxy);
4467
+ if (index !== -1) {
4468
+ portalProxyList.splice(index, 1);
4469
4469
  }
4470
4470
 
4471
4471
  if (portalEl !== null) {
@@ -4476,8 +4476,8 @@
4476
4476
 
4477
4477
  vue.onUnmounted(() => { hidePortal(true); });
4478
4478
 
4479
- // expose publicly needed stuff for portal utils
4480
- Object.assign(vm.proxy, { __qPortalInnerRef: innerRef });
4479
+ // needed for portal vm detection
4480
+ vm.proxy.__qPortalInnerRef = innerRef;
4481
4481
 
4482
4482
  return {
4483
4483
  showPortal,
@@ -4876,10 +4876,10 @@
4876
4876
 
4877
4877
  // check last portal vm if it's
4878
4878
  // a QDialog and not in seamless mode
4879
- let portalIndex = portalList.length - 1;
4879
+ let portalIndex = portalProxyList.length - 1;
4880
4880
 
4881
4881
  while (portalIndex >= 0) {
4882
- const proxy = portalList[ portalIndex ].$;
4882
+ const proxy = portalProxyList[ portalIndex ].$;
4883
4883
 
4884
4884
  if (proxy.type.name !== 'QDialog') {
4885
4885
  break
@@ -5694,7 +5694,10 @@
5694
5694
  round: false,
5695
5695
  ...attributes.value,
5696
5696
  onClick
5697
- }, () => hSlot(slots.label, []).concat(Arrow))
5697
+ }, {
5698
+ default: () => hSlot(slots.label, []).concat(Arrow),
5699
+ loading: slots.loading
5700
+ })
5698
5701
  }
5699
5702
 
5700
5703
  return vue.h(QBtnGroup, {
@@ -5716,7 +5719,10 @@
5716
5719
  iconRight: props.iconRight,
5717
5720
  round: false,
5718
5721
  onClick: onClickHide
5719
- }, slots.label),
5722
+ }, {
5723
+ default: slots.label,
5724
+ loading: slots.loading
5725
+ }),
5720
5726
 
5721
5727
  vue.h(QBtn, {
5722
5728
  class: 'q-btn-dropdown__arrow-container q-anchor--skip',
@@ -5941,8 +5947,8 @@
5941
5947
  },
5942
5948
 
5943
5949
  setup (props, { slots }) {
5944
- const vm = vue.getCurrentInstance();
5945
- const isDark = useDark(props, vm.proxy.$q);
5950
+ const { proxy: { $q } } = vue.getCurrentInstance();
5951
+ const isDark = useDark(props, $q);
5946
5952
 
5947
5953
  const classes = vue.computed(() =>
5948
5954
  'q-card'
@@ -6450,13 +6456,6 @@
6450
6456
  function nextPanel () { goToPanelByOffset(1); }
6451
6457
  function previousPanel () { goToPanelByOffset(-1); }
6452
6458
 
6453
- // expose public methods
6454
- Object.assign(proxy, {
6455
- next: nextPanel,
6456
- previous: previousPanel,
6457
- goTo: goToPanel
6458
- });
6459
-
6460
6459
  function goToPanel (name) {
6461
6460
  emit('update:modelValue', name);
6462
6461
  }
@@ -6581,6 +6580,13 @@
6581
6580
  return panels
6582
6581
  }
6583
6582
 
6583
+ // expose public methods
6584
+ Object.assign(proxy, {
6585
+ next: nextPanel,
6586
+ previous: previousPanel,
6587
+ goTo: goToPanel
6588
+ });
6589
+
6584
6590
  return {
6585
6591
  panelIndex,
6586
6592
  panelDirectives,
@@ -9066,7 +9072,11 @@
9066
9072
 
9067
9073
  const
9068
9074
  stepVal = ([ 34, 33 ].includes(evt.keyCode) ? 10 : 1) * state.step.value,
9069
- offset = ([ 34, 37, 40 ].includes(evt.keyCode) ? -1 : 1) * (state.isReversed.value === true ? -1 : 1) * stepVal;
9075
+ offset = (
9076
+ ([ 34, 37, 40 ].includes(evt.keyCode) ? -1 : 1)
9077
+ * (state.isReversed.value === true ? -1 : 1)
9078
+ * (props.vertical === true ? -1 : 1) * stepVal
9079
+ );
9070
9080
 
9071
9081
  model.value = between(
9072
9082
  parseFloat((model.value + offset).toFixed(state.decimals.value)),
@@ -9154,17 +9164,14 @@
9154
9164
  }
9155
9165
  }
9156
9166
 
9157
- const vm = vue.getCurrentInstance();
9158
-
9159
- // expose public methods
9160
- Object.assign(vm.proxy, { trigger });
9167
+ const { proxy } = vue.getCurrentInstance();
9161
9168
 
9162
9169
  if (hasObserver === true) {
9163
9170
  let observer;
9164
9171
 
9165
9172
  vue.onMounted(() => {
9166
9173
  vue.nextTick(() => {
9167
- targetEl = vm.proxy.$el.parentNode;
9174
+ targetEl = proxy.$el.parentNode;
9168
9175
 
9169
9176
  if (targetEl) {
9170
9177
  observer = new ResizeObserver(trigger);
@@ -9218,13 +9225,16 @@
9218
9225
 
9219
9226
  vue.onMounted(() => {
9220
9227
  vue.nextTick(() => {
9221
- targetEl = vm.proxy.$el;
9228
+ targetEl = proxy.$el;
9222
9229
  targetEl && onObjLoad();
9223
9230
  });
9224
9231
  });
9225
9232
 
9226
9233
  vue.onBeforeUnmount(cleanup);
9227
9234
 
9235
+ // expose public method
9236
+ proxy.trigger = trigger;
9237
+
9228
9238
  return () => {
9229
9239
  if (canRender.value === true) {
9230
9240
  return vue.h('object', {
@@ -11474,9 +11484,9 @@
11474
11484
  }
11475
11485
 
11476
11486
  return {
11477
- leap: leap,
11478
- gy: gy,
11479
- march: march
11487
+ leap,
11488
+ gy,
11489
+ march
11480
11490
  }
11481
11491
  }
11482
11492
 
@@ -11521,9 +11531,9 @@
11521
11531
  jm = 1 + div(k, 31);
11522
11532
  jd = mod(k, 31) + 1;
11523
11533
  return {
11524
- jy: jy,
11525
- jm: jm,
11526
- jd: jd
11534
+ jy,
11535
+ jm,
11536
+ jd
11527
11537
  }
11528
11538
  }
11529
11539
  else {
@@ -11540,9 +11550,9 @@
11540
11550
  jm = 7 + div(k, 30);
11541
11551
  jd = mod(k, 30) + 1;
11542
11552
  return {
11543
- jy: jy,
11544
- jm: jm,
11545
- jd: jd
11553
+ jy,
11554
+ jm,
11555
+ jd
11546
11556
  }
11547
11557
  }
11548
11558
 
@@ -11586,9 +11596,9 @@
11586
11596
  gm = mod(div(i, 153), 12) + 1,
11587
11597
  gy = div(j, 1461) - 100100 + div(8 - gm, 6);
11588
11598
  return {
11589
- gy: gy,
11590
- gm: gm,
11591
- gd: gd
11599
+ gy,
11600
+ gm,
11601
+ gd
11592
11602
  }
11593
11603
  }
11594
11604
 
@@ -13748,11 +13758,6 @@
13748
13758
  emit('update:modelValue', (props.multiple === true ? model : model[ 0 ]) || null, reason);
13749
13759
  }
13750
13760
 
13751
- // expose public methods
13752
- Object.assign(proxy, {
13753
- setToday, setView, offsetCalendar, setCalendarTo, setEditingRange
13754
- });
13755
-
13756
13761
  function getHeader () {
13757
13762
  if (props.minimal === true) { return }
13758
13763
 
@@ -14110,6 +14115,11 @@
14110
14115
  }
14111
14116
  }
14112
14117
 
14118
+ // expose public methods
14119
+ Object.assign(proxy, {
14120
+ setToday, setView, offsetCalendar, setCalendarTo, setEditingRange
14121
+ });
14122
+
14113
14123
  return () => {
14114
14124
  const content = [
14115
14125
  vue.h('div', {
@@ -17131,11 +17141,6 @@
17131
17141
  return contentRef.value
17132
17142
  }
17133
17143
 
17134
- // expose public methods
17135
- Object.assign(proxy, {
17136
- runCmd, refreshToolbar, focus, getContentEl
17137
- });
17138
-
17139
17144
  vue.onMounted(() => {
17140
17145
  eVm.caret = proxy.caret = new Caret(contentRef.value, eVm);
17141
17146
  setContent(props.modelValue);
@@ -17148,6 +17153,11 @@
17148
17153
  document.removeEventListener('selectionchange', onSelectionchange);
17149
17154
  });
17150
17155
 
17156
+ // expose public methods
17157
+ Object.assign(proxy, {
17158
+ runCmd, refreshToolbar, focus, getContentEl
17159
+ });
17160
+
17151
17161
  return () => {
17152
17162
  let toolbars;
17153
17163
 
@@ -18712,6 +18722,7 @@
18712
18722
  onDragover,
18713
18723
  processFiles,
18714
18724
  getDndNode,
18725
+
18715
18726
  maxFilesNumber,
18716
18727
  maxTotalSizeNumber
18717
18728
  }
@@ -18781,6 +18792,12 @@
18781
18792
  proxy.$forceUpdate();
18782
18793
  }
18783
18794
 
18795
+ const editable = vue.computed(() => props.disable !== true && props.readonly !== true);
18796
+ const dnd = vue.ref(false);
18797
+
18798
+ const rootRef = vue.ref(null);
18799
+ const inputRef = vue.ref(null);
18800
+
18784
18801
  const state = {
18785
18802
  files: vue.ref([]),
18786
18803
  queuedFiles: vue.ref([]),
@@ -18793,22 +18810,6 @@
18793
18810
  }
18794
18811
  };
18795
18812
 
18796
- Object.assign(state, getPlugin({ props, slots, emit, helpers: state }));
18797
-
18798
- const uploadSize = vue.ref(0);
18799
- const editable = vue.computed(() => props.disable !== true && props.readonly !== true);
18800
-
18801
- if (state.isBusy === void 0) {
18802
- state.isBusy = vue.ref(false);
18803
- }
18804
-
18805
- const dnd = vue.ref(false);
18806
-
18807
- const rootRef = vue.ref(null);
18808
- const inputRef = vue.ref(null);
18809
-
18810
- vue.provide(uploaderKey, renderInput);
18811
-
18812
18813
  const {
18813
18814
  pickFiles,
18814
18815
  addFiles,
@@ -18820,6 +18821,21 @@
18820
18821
  maxTotalSizeNumber
18821
18822
  } = useFile({ editable, dnd, getFileInput, addFilesToQueue });
18822
18823
 
18824
+ Object.assign(state, getPlugin({ props, slots, emit, helpers: state }));
18825
+
18826
+ if (state.isBusy === void 0) {
18827
+ state.isBusy = vue.ref(false);
18828
+ }
18829
+
18830
+ const uploadSize = vue.ref(0);
18831
+ const uploadProgress = vue.computed(() => (
18832
+ uploadSize.value === 0
18833
+ ? 0
18834
+ : state.uploadedSize.value / uploadSize.value
18835
+ ));
18836
+ const uploadProgressLabel = vue.computed(() => getProgressLabel(uploadProgress.value));
18837
+ const uploadSizeLabel = vue.computed(() => humanStorageSize(uploadSize.value));
18838
+
18823
18839
  const canAddFiles = vue.computed(() =>
18824
18840
  editable.value === true
18825
18841
  && state.isUploading.value !== true
@@ -18838,14 +18854,7 @@
18838
18854
  && state.queuedFiles.value.length > 0
18839
18855
  );
18840
18856
 
18841
- const uploadProgress = vue.computed(() => (
18842
- uploadSize.value === 0
18843
- ? 0
18844
- : state.uploadedSize.value / uploadSize.value
18845
- ));
18846
-
18847
- const uploadProgressLabel = vue.computed(() => getProgressLabel(uploadProgress.value));
18848
- const uploadSizeLabel = vue.computed(() => humanStorageSize(uploadSize.value));
18857
+ vue.provide(uploaderKey, renderInput);
18849
18858
 
18850
18859
  const classes = vue.computed(() =>
18851
18860
  'q-uploader column no-wrap'
@@ -19040,7 +19049,7 @@
19040
19049
 
19041
19050
  function getHeader () {
19042
19051
  if (slots.header !== void 0) {
19043
- return slots.header(slotScope.value)
19052
+ return slots.header(publicApi)
19044
19053
  }
19045
19054
 
19046
19055
  return [
@@ -19077,7 +19086,7 @@
19077
19086
 
19078
19087
  function getList () {
19079
19088
  if (slots.list !== void 0) {
19080
- return slots.list(slotScope.value)
19089
+ return slots.list(publicApi)
19081
19090
  }
19082
19091
 
19083
19092
  return state.files.value.map(file => vue.h('div', {
@@ -19136,41 +19145,37 @@
19136
19145
  state.files.value.length > 0 && revokeImgURLs();
19137
19146
  });
19138
19147
 
19139
- const publicMethods = {
19140
- pickFiles,
19141
- addFiles,
19148
+ const publicApi = {};
19149
+
19150
+ for (const key in state) {
19151
+ if (vue.isRef(state[ key ]) === true) {
19152
+ injectProp(publicApi, key, () => state[ key ].value);
19153
+ }
19154
+ else { // method or non-computed prop
19155
+ publicApi[ key ] = state[ key ];
19156
+ }
19157
+ }
19158
+
19159
+ Object.assign(publicApi, {
19160
+ upload,
19142
19161
  reset,
19143
19162
  removeUploadedFiles,
19144
19163
  removeQueuedFiles,
19145
19164
  removeFile,
19146
- upload,
19147
- abort: state.abort
19148
- };
19149
19165
 
19150
- // TODO: the result of this computed, especially the dynamic part, isn't currently typed
19151
- // This result in an error with Volar when accessing the state (eg. files array)
19152
- const slotScope = vue.computed(() => {
19153
- const acc = {
19154
- canAddFiles: canAddFiles.value,
19155
- canUpload: canUpload.value,
19156
- uploadSizeLabel: uploadSizeLabel.value,
19157
- uploadProgressLabel: uploadProgressLabel.value
19158
- };
19159
-
19160
- for (const key in state) {
19161
- acc[ key ] = vue.isRef(state[ key ]) === true
19162
- ? state[ key ].value
19163
- : state[ key ];
19164
- }
19166
+ pickFiles,
19167
+ addFiles
19168
+ });
19165
19169
 
19166
- // TODO: (Qv3) Put the QUploader instance under `ref`
19167
- // property for consistency and flexibility
19168
- // return { ref: { ...acc, ...publicMethods } }
19169
- return { ...acc, ...publicMethods }
19170
+ injectMultipleProps(publicApi, {
19171
+ canAddFiles: () => canAddFiles.value,
19172
+ canUpload: () => canUpload.value,
19173
+ uploadSizeLabel: () => uploadSizeLabel.value,
19174
+ uploadProgressLabel: () => uploadProgressLabel.value
19170
19175
  });
19171
19176
 
19172
- // expose public methods
19173
- Object.assign(proxy, publicMethods);
19177
+ // expose public api (methods & computed props)
19178
+ Object.assign(proxy, publicApi);
19174
19179
 
19175
19180
  return () => {
19176
19181
  const children = [
@@ -20318,9 +20323,13 @@
20318
20323
  const cfg = Object.assign({ noopener: true }, winFeatures);
20319
20324
  const feat = [];
20320
20325
  for (const key in cfg) {
20321
- if (cfg[ key ] === true) {
20326
+ const value = cfg[ key ];
20327
+ if (value === true) {
20322
20328
  feat.push(key);
20323
20329
  }
20330
+ else if (isNumber(value) || (typeof value === 'string' && value !== '')) {
20331
+ feat.push(key + '=' + value);
20332
+ }
20324
20333
  }
20325
20334
  return feat.join(',')
20326
20335
  }
@@ -20390,6 +20399,7 @@
20390
20399
  frameDebounce: frameDebounce,
20391
20400
  getCssVar: getCssVar,
20392
20401
  noop: noop,
20402
+ is: is,
20393
20403
  morph: morph,
20394
20404
  openURL: openUrl,
20395
20405
  patterns: patterns,
@@ -21104,7 +21114,8 @@
21104
21114
 
21105
21115
  return vue.h('div', {
21106
21116
  class: 'q-field__bottom row items-start q-field__bottom--'
21107
- + (props.hideBottomSpace !== true ? 'animated' : 'stale')
21117
+ + (props.hideBottomSpace !== true ? 'animated' : 'stale'),
21118
+ onClick: prevent
21108
21119
  }, [
21109
21120
  props.hideBottomSpace === true
21110
21121
  ? main
@@ -21127,9 +21138,6 @@
21127
21138
  }, content)
21128
21139
  }
21129
21140
 
21130
- // expose public methods
21131
- Object.assign(proxy, { focus, blur });
21132
-
21133
21141
  let shouldActivate = false;
21134
21142
 
21135
21143
  vue.onDeactivated(() => {
@@ -21152,6 +21160,9 @@
21152
21160
  clearTimeout(focusoutTimer);
21153
21161
  });
21154
21162
 
21163
+ // expose public methods
21164
+ Object.assign(proxy, { focus, blur });
21165
+
21155
21166
  return function renderField () {
21156
21167
  const labelAttrs = state.getControl === void 0 && slots.control === void 0
21157
21168
  ? {
@@ -22570,13 +22581,6 @@
22570
22581
  index = newIndex;
22571
22582
  }
22572
22583
 
22573
- // expose public methods
22574
- const vm = vue.getCurrentInstance();
22575
- Object.assign(vm.proxy, {
22576
- poll: () => { poll !== void 0 && poll(); },
22577
- trigger, stop, reset, resume, setIndex
22578
- });
22579
-
22580
22584
  function setDebounce (val) {
22581
22585
  val = parseInt(val, 10);
22582
22586
 
@@ -22635,6 +22639,13 @@
22635
22639
  updateScrollTarget();
22636
22640
  });
22637
22641
 
22642
+ // expose public methods
22643
+ const vm = vue.getCurrentInstance();
22644
+ Object.assign(vm.proxy, {
22645
+ poll: () => { poll !== void 0 && poll(); },
22646
+ trigger, stop, reset, resume, setIndex
22647
+ });
22648
+
22638
22649
  return () => {
22639
22650
  const child = hUniqueSlot(slots.default, []);
22640
22651
 
@@ -24305,10 +24316,10 @@
24305
24316
  }
24306
24317
  }
24307
24318
 
24308
- const vm = vue.getCurrentInstance();
24319
+ const { proxy } = vue.getCurrentInstance();
24309
24320
 
24310
24321
  vue.onMounted(() => {
24311
- parentEl = vm.proxy.$el.parentNode;
24322
+ parentEl = proxy.$el.parentNode;
24312
24323
  configureScrollTarget();
24313
24324
  });
24314
24325
 
@@ -24318,7 +24329,7 @@
24318
24329
  });
24319
24330
 
24320
24331
  // expose public methods
24321
- Object.assign(vm.proxy, {
24332
+ Object.assign(proxy, {
24322
24333
  trigger,
24323
24334
  getPosition: () => scroll
24324
24335
  });
@@ -25114,8 +25125,7 @@
25114
25125
  };
25115
25126
 
25116
25127
  function usePageSticky () {
25117
- const { props, proxy } = vue.getCurrentInstance();
25118
- const { $q } = proxy;
25128
+ const { props, proxy: { $q } } = vue.getCurrentInstance();
25119
25129
 
25120
25130
  const $layout = vue.inject(layoutKey, () => {
25121
25131
  console.error('QPageSticky needs to be child of QLayout');
@@ -25985,15 +25995,6 @@
25985
25995
  emit('hide');
25986
25996
  }
25987
25997
 
25988
- // expose public methods
25989
- Object.assign(proxy, {
25990
- set,
25991
- cancel,
25992
- show (e) { menuRef.value !== null && menuRef.value.show(e); },
25993
- hide (e) { menuRef.value !== null && menuRef.value.hide(e); },
25994
- updatePosition
25995
- });
25996
-
25997
25998
  function getContent () {
25998
25999
  const child = slots.default !== void 0
25999
26000
  ? [].concat(slots.default(scope.value))
@@ -26023,6 +26024,15 @@
26023
26024
  return child
26024
26025
  }
26025
26026
 
26027
+ // expose public methods
26028
+ Object.assign(proxy, {
26029
+ set,
26030
+ cancel,
26031
+ show (e) { menuRef.value !== null && menuRef.value.show(e); },
26032
+ hide (e) { menuRef.value !== null && menuRef.value.hide(e); },
26033
+ updatePosition
26034
+ });
26035
+
26026
26036
  return () => {
26027
26037
  if (props.disable === true) { return }
26028
26038
 
@@ -26082,13 +26092,6 @@
26082
26092
  }
26083
26093
  });
26084
26094
 
26085
- // expose public methods
26086
- Object.assign(proxy, {
26087
- show (evt) { canShow(evt) === true && popupRef.value.show(evt); },
26088
- hide (evt) { popupRef.value.hide(evt); },
26089
- toggle (evt) { popupRef.value.toggle(evt); }
26090
- });
26091
-
26092
26095
  function onShow (evt) {
26093
26096
  showing.value = true;
26094
26097
  emit('show', evt);
@@ -26100,6 +26103,13 @@
26100
26103
  emit('hide', evt);
26101
26104
  }
26102
26105
 
26106
+ // expose public methods
26107
+ Object.assign(proxy, {
26108
+ show (evt) { canShow(evt) === true && popupRef.value.show(evt); },
26109
+ hide (evt) { popupRef.value.hide(evt); },
26110
+ toggle (evt) { popupRef.value.toggle(evt); }
26111
+ });
26112
+
26103
26113
  return () => {
26104
26114
  const data = {
26105
26115
  ref: popupRef,
@@ -26393,9 +26403,6 @@
26393
26403
  }, 300);
26394
26404
  }
26395
26405
 
26396
- // expose public methods
26397
- Object.assign(proxy, { trigger, updateScrollTarget });
26398
-
26399
26406
  let $el, localScrollTarget, timer;
26400
26407
 
26401
26408
  function updateScrollTarget () {
@@ -26413,6 +26420,9 @@
26413
26420
  clearTimeout(timer);
26414
26421
  });
26415
26422
 
26423
+ // expose public methods
26424
+ Object.assign(proxy, { trigger, updateScrollTarget });
26425
+
26416
26426
  return () => {
26417
26427
  const child = [
26418
26428
  vue.h('div', { class: contentClass.value }, hSlot(slots.default)),
@@ -26768,7 +26778,11 @@
26768
26778
 
26769
26779
  const
26770
26780
  stepVal = ([ 34, 33 ].includes(evt.keyCode) ? 10 : 1) * state.step.value,
26771
- offset = ([ 34, 37, 40 ].includes(evt.keyCode) ? -1 : 1) * (state.isReversed.value === true ? -1 : 1) * stepVal;
26781
+ offset = (
26782
+ ([ 34, 37, 40 ].includes(evt.keyCode) ? -1 : 1)
26783
+ * (state.isReversed.value === true ? -1 : 1)
26784
+ * (props.vertical === true ? -1 : 1) * stepVal
26785
+ );
26772
26786
 
26773
26787
  if (state.focus.value === 'both') {
26774
26788
  const interval = model.value.max - model.value.min;
@@ -27150,9 +27164,9 @@
27150
27164
  }
27151
27165
  };
27152
27166
 
27153
- const vm = vue.getCurrentInstance();
27167
+ const { proxy } = vue.getCurrentInstance();
27154
27168
 
27155
- const isDark = useDark(props, vm.proxy.$q);
27169
+ const isDark = useDark(props, proxy.$q);
27156
27170
 
27157
27171
  let timer, panRefPos;
27158
27172
 
@@ -27287,7 +27301,7 @@
27287
27301
  // multiple times
27288
27302
  const emitScroll = debounce(() => {
27289
27303
  const info = getScroll();
27290
- info.ref = vm.proxy;
27304
+ info.ref = proxy;
27291
27305
  emit('scroll', info);
27292
27306
  }, 0);
27293
27307
 
@@ -27426,28 +27440,6 @@
27426
27440
  hover.value = false;
27427
27441
  }
27428
27442
 
27429
- // expose public methods
27430
- Object.assign(vm.proxy, {
27431
- getScrollTarget: () => targetRef.value,
27432
- getScroll,
27433
- getScrollPosition: () => ({
27434
- top: scroll.vertical.position.value,
27435
- left: scroll.horizontal.position.value
27436
- }),
27437
- getScrollPercentage: () => ({
27438
- top: scroll.vertical.percentage.value,
27439
- left: scroll.horizontal.percentage.value
27440
- }),
27441
- setScrollPosition: localSetScrollPosition,
27442
- setScrollPercentage (axis, percentage, duration) {
27443
- localSetScrollPosition(
27444
- axis,
27445
- percentage * (scroll[ axis ].size.value - container[ axis ].value),
27446
- duration
27447
- );
27448
- }
27449
- });
27450
-
27451
27443
  let scrollPosition = null;
27452
27444
 
27453
27445
  vue.onDeactivated(() => {
@@ -27470,6 +27462,28 @@
27470
27462
 
27471
27463
  vue.onBeforeUnmount(emitScroll.cancel);
27472
27464
 
27465
+ // expose public methods
27466
+ Object.assign(proxy, {
27467
+ getScrollTarget: () => targetRef.value,
27468
+ getScroll,
27469
+ getScrollPosition: () => ({
27470
+ top: scroll.vertical.position.value,
27471
+ left: scroll.horizontal.position.value
27472
+ }),
27473
+ getScrollPercentage: () => ({
27474
+ top: scroll.vertical.percentage.value,
27475
+ left: scroll.horizontal.percentage.value
27476
+ }),
27477
+ setScrollPosition: localSetScrollPosition,
27478
+ setScrollPercentage (axis, percentage, duration) {
27479
+ localSetScrollPosition(
27480
+ axis,
27481
+ percentage * (scroll[ axis ].size.value - container[ axis ].value),
27482
+ duration
27483
+ );
27484
+ }
27485
+ });
27486
+
27473
27487
  return () => {
27474
27488
  return vue.h('div', {
27475
27489
  class: classes.value,
@@ -29771,6 +29785,7 @@
29771
29785
  vue.h('input', {
29772
29786
  class: 'q-select__autocomplete-input',
29773
29787
  autocomplete: props.autocomplete,
29788
+ tabindex: -1,
29774
29789
  onKeyup: onTargetAutocomplete
29775
29790
  })
29776
29791
  );
@@ -33158,10 +33173,6 @@
33158
33173
  vue.nextTick(() => {
33159
33174
  emit('request', {
33160
33175
  pagination: prop.pagination || computedPagination.value,
33161
- // FIXME: 'props.filter' is string/object, but 'prop.filter' can be controlled by the user, and the docs are suggesting 'prop.filter' is a function
33162
- // So, value of 'filter' becomes function/string/object, which makes a lot of things unpredictable and can break things
33163
- // Either update the docs to say 'prop.filter' should be a string/object, or use 'prop.filter || props.filterMethod' or maybe get 'computedFilterFunction' here and use that instead of 'props.filterMethod'
33164
- // The examples on our docs are using 'filter' as a string in onRequest handler, but the JSON API is saying 'filter' is a function
33165
33176
  filter: prop.filter || props.filter,
33166
33177
  getCellValue
33167
33178
  });
@@ -34710,7 +34721,8 @@
34710
34721
  emits: useDatetimeEmits,
34711
34722
 
34712
34723
  setup (props, { slots, emit }) {
34713
- const { proxy: { $q } } = vue.getCurrentInstance();
34724
+ const vm = vue.getCurrentInstance();
34725
+ const { $q } = vm.proxy;
34714
34726
 
34715
34727
  const isDark = useDark(props, $q);
34716
34728
  const { tabindex, headerClass, getLocale, getCurrentDate } = useDatetime(props, $q);
@@ -35398,10 +35410,6 @@
35398
35410
  emit('update:modelValue', val, date);
35399
35411
  }
35400
35412
 
35401
- // expose public methods
35402
- const vm = vue.getCurrentInstance();
35403
- Object.assign(vm.proxy, { setNow });
35404
-
35405
35413
  function getHeader () {
35406
35414
  const label = [
35407
35415
  vue.h('div', {
@@ -35539,6 +35547,9 @@
35539
35547
  ])
35540
35548
  }
35541
35549
 
35550
+ // expose public method
35551
+ vm.proxy.setNow = setNow;
35552
+
35542
35553
  return () => {
35543
35554
  const child = [ getClock() ];
35544
35555
 
@@ -36393,6 +36404,8 @@
36393
36404
  }
36394
36405
  }
36395
36406
 
36407
+ props.defaultExpandAll === true && expandAll();
36408
+
36396
36409
  // expose public methods
36397
36410
  Object.assign(proxy, {
36398
36411
  getNodeByKey,
@@ -36406,8 +36419,6 @@
36406
36419
  setTicked
36407
36420
  });
36408
36421
 
36409
- props.defaultExpandAll === true && expandAll();
36410
-
36411
36422
  return () => {
36412
36423
  const children = getChildren(props.nodes);
36413
36424
 
@@ -36904,9 +36915,9 @@
36904
36915
  handler (evt) {
36905
36916
  // allow @click to be emitted
36906
36917
  ctx.depth !== 0 && setTimeout(() => {
36907
- const vm = getPortalVm(el);
36908
- if (vm !== void 0) {
36909
- closePortals(vm, evt, ctx.depth);
36918
+ const proxy = getPortalProxy(el);
36919
+ if (proxy !== void 0) {
36920
+ closePortals(proxy, evt, ctx.depth);
36910
36921
  }
36911
36922
  });
36912
36923
  },
@@ -38838,9 +38849,11 @@
38838
38849
  vm,
38839
38850
  uid$1 = 0,
38840
38851
  timeout,
38841
- props = {};
38852
+ props = {},
38853
+ activeGroups = {};
38842
38854
 
38843
38855
  const originalDefaults = {
38856
+ group: '__default_quasar_group__',
38844
38857
  delay: 0,
38845
38858
  message: false,
38846
38859
  html: false,
@@ -38855,101 +38868,148 @@
38855
38868
 
38856
38869
  const defaults$1 = { ...originalDefaults };
38857
38870
 
38871
+ function registerProps (opts) {
38872
+ if (opts && opts.group !== void 0 && activeGroups[ opts.group ] !== void 0) {
38873
+ return Object.assign(activeGroups[ opts.group ], opts)
38874
+ }
38875
+
38876
+ const newProps = isObject(opts) === true && opts.ignoreDefaults === true
38877
+ ? { ...originalDefaults, ...opts }
38878
+ : { ...defaults$1, ...opts };
38879
+
38880
+ activeGroups[ newProps.group ] = newProps;
38881
+ return newProps
38882
+ }
38883
+
38858
38884
  const Plugin$2 = defineReactivePlugin({
38859
38885
  isActive: false
38860
38886
  }, {
38861
38887
  show (opts) {
38862
38888
 
38863
- props = isObject(opts) === true && opts.ignoreDefaults === true
38864
- ? { ...originalDefaults, ...opts }
38865
- : { ...defaults$1, ...opts };
38889
+ props = registerProps(opts);
38890
+ const { group } = props;
38866
38891
 
38867
38892
  Plugin$2.isActive = true;
38868
38893
 
38869
38894
  if (app !== void 0) {
38870
38895
  props.uid = uid$1;
38871
38896
  vm.$forceUpdate();
38872
- return
38873
38897
  }
38898
+ else {
38899
+ props.uid = ++uid$1;
38900
+ clearTimeout(timeout);
38874
38901
 
38875
- props.uid = ++uid$1;
38876
- clearTimeout(timeout);
38877
-
38878
- timeout = setTimeout(() => {
38879
- timeout = void 0;
38902
+ timeout = setTimeout(() => {
38903
+ timeout = void 0;
38880
38904
 
38881
- const el = createGlobalNode('q-loading');
38905
+ const el = createGlobalNode('q-loading');
38882
38906
 
38883
- app = vue.createApp({
38884
- name: 'QLoading',
38907
+ app = vue.createApp({
38908
+ name: 'QLoading',
38885
38909
 
38886
- setup () {
38887
- vue.onMounted(() => {
38888
- preventScroll(true);
38889
- });
38910
+ setup () {
38911
+ vue.onMounted(() => {
38912
+ preventScroll(true);
38913
+ });
38890
38914
 
38891
- function onAfterLeave () {
38892
- // might be called to finalize
38893
- // previous leave, even if it was cancelled
38894
- if (Plugin$2.isActive !== true && app !== void 0) {
38895
- preventScroll(false);
38896
- app.unmount(el);
38897
- removeGlobalNode(el);
38898
- app = void 0;
38899
- vm = void 0;
38915
+ function onAfterLeave () {
38916
+ // might be called to finalize
38917
+ // previous leave, even if it was cancelled
38918
+ if (Plugin$2.isActive !== true && app !== void 0) {
38919
+ preventScroll(false);
38920
+ app.unmount(el);
38921
+ removeGlobalNode(el);
38922
+ app = void 0;
38923
+ vm = void 0;
38924
+ }
38900
38925
  }
38901
- }
38902
38926
 
38903
- function getContent () {
38904
- if (Plugin$2.isActive !== true) {
38905
- return null
38906
- }
38927
+ function getContent () {
38928
+ if (Plugin$2.isActive !== true) {
38929
+ return null
38930
+ }
38907
38931
 
38908
- const content = [
38909
- vue.h(props.spinner, {
38910
- class: 'q-loading__spinner',
38911
- color: props.spinnerColor,
38912
- size: props.spinnerSize
38913
- })
38914
- ];
38932
+ const content = [
38933
+ vue.h(props.spinner, {
38934
+ class: 'q-loading__spinner',
38935
+ color: props.spinnerColor,
38936
+ size: props.spinnerSize
38937
+ })
38938
+ ];
38915
38939
 
38916
- props.message && content.push(
38917
- vue.h('div', {
38918
- class: 'q-loading__message'
38919
- + (props.messageColor ? ` text-${ props.messageColor }` : ''),
38920
- [ props.html === true ? 'innerHTML' : 'textContent' ]: props.message
38921
- })
38922
- );
38940
+ props.message && content.push(
38941
+ vue.h('div', {
38942
+ class: 'q-loading__message'
38943
+ + (props.messageColor ? ` text-${ props.messageColor }` : ''),
38944
+ [ props.html === true ? 'innerHTML' : 'textContent' ]: props.message
38945
+ })
38946
+ );
38923
38947
 
38924
- return vue.h('div', {
38925
- class: 'q-loading fullscreen flex flex-center z-max ' + props.customClass.trim(),
38926
- key: props.uid
38927
- }, [
38928
- vue.h('div', {
38929
- class: 'q-loading__backdrop'
38930
- + (props.backgroundColor ? ` bg-${ props.backgroundColor }` : '')
38931
- }),
38948
+ return vue.h('div', {
38949
+ class: 'q-loading fullscreen flex flex-center z-max ' + props.customClass.trim(),
38950
+ key: props.uid
38951
+ }, [
38952
+ vue.h('div', {
38953
+ class: 'q-loading__backdrop'
38954
+ + (props.backgroundColor ? ` bg-${ props.backgroundColor }` : '')
38955
+ }),
38956
+
38957
+ vue.h('div', {
38958
+ class: 'q-loading__box column items-center ' + props.boxClass
38959
+ }, content)
38960
+ ])
38961
+ }
38932
38962
 
38933
- vue.h('div', {
38934
- class: 'q-loading__box column items-center ' + props.boxClass
38935
- }, content)
38936
- ])
38963
+ return () => vue.h(vue.Transition, {
38964
+ name: 'q-transition--fade',
38965
+ appear: true,
38966
+ onAfterLeave
38967
+ }, getContent)
38937
38968
  }
38969
+ });
38938
38970
 
38939
- return () => vue.h(vue.Transition, {
38940
- name: 'q-transition--fade',
38941
- appear: true,
38942
- onAfterLeave
38943
- }, getContent)
38944
- }
38945
- });
38971
+ vm = app.mount(el);
38972
+ }, props.delay);
38973
+ }
38946
38974
 
38947
- vm = app.mount(el);
38948
- }, props.delay);
38975
+ return paramProps => {
38976
+ // if we don't have params (or not an Object param) then we need to hide this group
38977
+ if (paramProps === void 0 || Object(paramProps) !== paramProps) {
38978
+ Plugin$2.hide(group);
38979
+ return
38980
+ }
38981
+
38982
+ // else we have params so we need to update this group
38983
+ Plugin$2.show({ ...paramProps, group });
38984
+ }
38949
38985
  },
38950
38986
 
38951
- hide () {
38987
+ hide (group) {
38952
38988
  if (Plugin$2.isActive === true) {
38989
+ if (group === void 0) {
38990
+ // clear out any active groups
38991
+ activeGroups = {};
38992
+ }
38993
+ else if (activeGroups[ group ] === void 0) {
38994
+ // we've already hidden it so nothing to do
38995
+ return
38996
+ }
38997
+ else {
38998
+ // remove active group
38999
+ delete activeGroups[ group ];
39000
+
39001
+ const keys = Object.keys(activeGroups);
39002
+
39003
+ // if there are other groups registered then
39004
+ // show last registered one since that one is still active
39005
+ if (keys.length !== 0) {
39006
+ // get last registered group
39007
+ const lastGroup = keys[ keys.length - 1 ];
39008
+ Plugin$2.show({ group: lastGroup });
39009
+ return
39010
+ }
39011
+ }
39012
+
38953
39013
  if (timeout !== void 0) {
38954
39014
  clearTimeout(timeout);
38955
39015
  timeout = void 0;
@@ -39763,7 +39823,7 @@
39763
39823
  });
39764
39824
 
39765
39825
  var index_umd = {
39766
- version: '2.7.7',
39826
+ version: '2.8.1',
39767
39827
  install (app, opts) {
39768
39828
  installQuasar(app, {
39769
39829
  components,