quasar 2.6.6 → 2.7.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.
Files changed (214) hide show
  1. package/dist/api/QBtnDropdown.json +1 -0
  2. package/dist/api/QBtnToggle.json +1 -0
  3. package/dist/api/QCarousel.json +2 -1
  4. package/dist/api/QCheckbox.json +1 -0
  5. package/dist/api/QChip.json +3 -1
  6. package/dist/api/QColor.json +1 -0
  7. package/dist/api/QDate.json +1 -0
  8. package/dist/api/QDialog.json +6 -0
  9. package/dist/api/QEditor.json +3 -1
  10. package/dist/api/QExpansionItem.json +1 -0
  11. package/dist/api/QFab.json +1 -0
  12. package/dist/api/QFile.json +1 -0
  13. package/dist/api/QFooter.json +1 -0
  14. package/dist/api/QHeader.json +1 -0
  15. package/dist/api/QInput.json +1 -0
  16. package/dist/api/QItem.json +3 -1
  17. package/dist/api/QKnob.json +1 -0
  18. package/dist/api/QOptionGroup.json +1 -0
  19. package/dist/api/QPagination.json +2 -1
  20. package/dist/api/QPopupEdit.json +1 -0
  21. package/dist/api/QPopupProxy.json +1 -0
  22. package/dist/api/QRadio.json +1 -0
  23. package/dist/api/QRange.json +1 -0
  24. package/dist/api/QRating.json +1 -0
  25. package/dist/api/QSelect.json +1 -0
  26. package/dist/api/QSlider.json +1 -0
  27. package/dist/api/QSplitter.json +1 -0
  28. package/dist/api/QTable.json +5 -1
  29. package/dist/api/QTabs.json +1 -0
  30. package/dist/api/QTime.json +1 -0
  31. package/dist/api/QToggle.json +1 -0
  32. package/dist/api/QTree.json +6 -3
  33. package/dist/icon-set/bootstrap-icons.umd.prod.js +1 -1
  34. package/dist/icon-set/eva-icons.umd.prod.js +1 -1
  35. package/dist/icon-set/fontawesome-v5-pro.umd.prod.js +1 -1
  36. package/dist/icon-set/fontawesome-v5.umd.prod.js +1 -1
  37. package/dist/icon-set/fontawesome-v6-pro.umd.prod.js +1 -1
  38. package/dist/icon-set/fontawesome-v6.umd.prod.js +1 -1
  39. package/dist/icon-set/ionicons-v4.umd.prod.js +1 -1
  40. package/dist/icon-set/line-awesome.umd.prod.js +1 -1
  41. package/dist/icon-set/material-icons-outlined.umd.prod.js +1 -1
  42. package/dist/icon-set/material-icons-round.umd.prod.js +1 -1
  43. package/dist/icon-set/material-icons-sharp.umd.prod.js +1 -1
  44. package/dist/icon-set/material-icons.umd.prod.js +1 -1
  45. package/dist/icon-set/material-symbols-outlined.umd.prod.js +6 -0
  46. package/dist/icon-set/material-symbols-rounded.umd.prod.js +6 -0
  47. package/dist/icon-set/material-symbols-sharp.umd.prod.js +6 -0
  48. package/dist/icon-set/mdi-v3.umd.prod.js +1 -1
  49. package/dist/icon-set/mdi-v4.umd.prod.js +1 -1
  50. package/dist/icon-set/mdi-v5.umd.prod.js +1 -1
  51. package/dist/icon-set/mdi-v6.umd.prod.js +1 -1
  52. package/dist/icon-set/svg-bootstrap-icons.umd.prod.js +1 -1
  53. package/dist/icon-set/svg-eva-icons.umd.prod.js +1 -1
  54. package/dist/icon-set/svg-fontawesome-v5.umd.prod.js +1 -1
  55. package/dist/icon-set/svg-fontawesome-v6.umd.prod.js +1 -1
  56. package/dist/icon-set/svg-ionicons-v4.umd.prod.js +1 -1
  57. package/dist/icon-set/svg-ionicons-v5.umd.prod.js +1 -1
  58. package/dist/icon-set/svg-ionicons-v6.umd.prod.js +1 -1
  59. package/dist/icon-set/svg-line-awesome.umd.prod.js +1 -1
  60. package/dist/icon-set/svg-material-icons-outlined.umd.prod.js +1 -1
  61. package/dist/icon-set/svg-material-icons-round.umd.prod.js +1 -1
  62. package/dist/icon-set/svg-material-icons-sharp.umd.prod.js +1 -1
  63. package/dist/icon-set/svg-material-icons.umd.prod.js +1 -1
  64. package/dist/icon-set/svg-material-symbols-outlined.umd.prod.js +6 -0
  65. package/dist/icon-set/svg-material-symbols-rounded.umd.prod.js +6 -0
  66. package/dist/icon-set/svg-material-symbols-sharp.umd.prod.js +6 -0
  67. package/dist/icon-set/svg-mdi-v6.umd.prod.js +1 -1
  68. package/dist/icon-set/svg-themify.umd.prod.js +1 -1
  69. package/dist/icon-set/themify.umd.prod.js +1 -1
  70. package/dist/lang/ar-TN.umd.prod.js +1 -1
  71. package/dist/lang/ar.umd.prod.js +1 -1
  72. package/dist/lang/az-Latn.umd.prod.js +1 -1
  73. package/dist/lang/bg.umd.prod.js +1 -1
  74. package/dist/lang/bn.umd.prod.js +1 -1
  75. package/dist/lang/ca.umd.prod.js +2 -2
  76. package/dist/lang/cs.umd.prod.js +1 -1
  77. package/dist/lang/da.umd.prod.js +1 -1
  78. package/dist/lang/de.umd.prod.js +1 -1
  79. package/dist/lang/el.umd.prod.js +1 -1
  80. package/dist/lang/en-GB.umd.prod.js +1 -1
  81. package/dist/lang/en-US.umd.prod.js +1 -1
  82. package/dist/lang/eo.umd.prod.js +1 -1
  83. package/dist/lang/es.umd.prod.js +2 -2
  84. package/dist/lang/et.umd.prod.js +1 -1
  85. package/dist/lang/eu.umd.prod.js +1 -1
  86. package/dist/lang/fa-IR.umd.prod.js +1 -1
  87. package/dist/lang/fa.umd.prod.js +1 -1
  88. package/dist/lang/fi.umd.prod.js +1 -1
  89. package/dist/lang/fr.umd.prod.js +1 -1
  90. package/dist/lang/gn.umd.prod.js +1 -1
  91. package/dist/lang/he.umd.prod.js +1 -1
  92. package/dist/lang/hr.umd.prod.js +1 -1
  93. package/dist/lang/hu.umd.prod.js +1 -1
  94. package/dist/lang/id.umd.prod.js +1 -1
  95. package/dist/lang/is.umd.prod.js +1 -1
  96. package/dist/lang/it.umd.prod.js +1 -1
  97. package/dist/lang/ja.umd.prod.js +1 -1
  98. package/dist/lang/km.umd.prod.js +1 -1
  99. package/dist/lang/ko-KR.umd.prod.js +2 -2
  100. package/dist/lang/kur-CKB.umd.prod.js +1 -1
  101. package/dist/lang/kz.umd.prod.js +1 -1
  102. package/dist/lang/lt.umd.prod.js +1 -1
  103. package/dist/lang/lu.umd.prod.js +1 -1
  104. package/dist/lang/lv.umd.prod.js +1 -1
  105. package/dist/lang/ml.umd.prod.js +1 -1
  106. package/dist/lang/mm.umd.prod.js +6 -0
  107. package/dist/lang/ms.umd.prod.js +1 -1
  108. package/dist/lang/my.umd.prod.js +1 -1
  109. package/dist/lang/nb-NO.umd.prod.js +1 -1
  110. package/dist/lang/nl.umd.prod.js +1 -1
  111. package/dist/lang/pl.umd.prod.js +1 -1
  112. package/dist/lang/pt-BR.umd.prod.js +1 -1
  113. package/dist/lang/pt.umd.prod.js +1 -1
  114. package/dist/lang/ro.umd.prod.js +1 -1
  115. package/dist/lang/ru.umd.prod.js +1 -1
  116. package/dist/lang/sk.umd.prod.js +1 -1
  117. package/dist/lang/sl.umd.prod.js +1 -1
  118. package/dist/lang/sm.umd.prod.js +6 -0
  119. package/dist/lang/sr-CYR.umd.prod.js +1 -1
  120. package/dist/lang/sr.umd.prod.js +1 -1
  121. package/dist/lang/sv.umd.prod.js +1 -1
  122. package/dist/lang/ta.umd.prod.js +1 -1
  123. package/dist/lang/th.umd.prod.js +1 -1
  124. package/dist/lang/tr.umd.prod.js +1 -1
  125. package/dist/lang/ug.umd.prod.js +1 -1
  126. package/dist/lang/uk.umd.prod.js +1 -1
  127. package/dist/lang/vi.umd.prod.js +1 -1
  128. package/dist/lang/zh-CN.umd.prod.js +1 -1
  129. package/dist/lang/zh-TW.umd.prod.js +1 -1
  130. package/dist/quasar.addon.rtl.css +251 -0
  131. package/dist/quasar.cjs.prod.js +2 -2
  132. package/dist/quasar.css +9 -9
  133. package/dist/quasar.esm.prod.js +2 -2
  134. package/dist/quasar.prod.css +1 -1
  135. package/dist/quasar.rtl.css +1229 -9
  136. package/dist/quasar.rtl.prod.css +1 -1
  137. package/dist/quasar.sass +10 -9
  138. package/dist/quasar.umd.js +182 -126
  139. package/dist/quasar.umd.prod.js +2 -2
  140. package/dist/types/api/quploader.d.ts +7 -7
  141. package/dist/types/extras/icon-set.d.ts +6 -0
  142. package/dist/types/index.d.ts +265 -255
  143. package/dist/types/utils/dom.d.ts +1 -1
  144. package/dist/types/utils.d.ts +11 -0
  145. package/dist/vetur/quasar-attributes.json +4 -0
  146. package/dist/vetur/quasar-tags.json +2 -1
  147. package/dist/web-types/web-types.json +12 -2
  148. package/icon-set/material-symbols-outlined.js +133 -0
  149. package/icon-set/material-symbols-outlined.mjs +128 -0
  150. package/icon-set/material-symbols-rounded.js +133 -0
  151. package/icon-set/material-symbols-rounded.mjs +128 -0
  152. package/icon-set/material-symbols-sharp.js +133 -0
  153. package/icon-set/material-symbols-sharp.mjs +128 -0
  154. package/icon-set/svg-material-symbols-outlined.js +201 -0
  155. package/icon-set/svg-material-symbols-outlined.mjs +201 -0
  156. package/icon-set/svg-material-symbols-rounded.js +201 -0
  157. package/icon-set/svg-material-symbols-rounded.mjs +201 -0
  158. package/icon-set/svg-material-symbols-sharp.js +201 -0
  159. package/icon-set/svg-material-symbols-sharp.mjs +201 -0
  160. package/lang/ca.js +31 -31
  161. package/lang/ca.mjs +31 -31
  162. package/lang/es.js +1 -1
  163. package/lang/es.mjs +1 -1
  164. package/lang/index.json +8 -0
  165. package/lang/ko-KR.js +21 -21
  166. package/lang/ko-KR.mjs +21 -21
  167. package/lang/mm.js +96 -0
  168. package/lang/mm.mjs +91 -0
  169. package/lang/sm.js +96 -0
  170. package/lang/sm.mjs +91 -0
  171. package/package.json +15 -15
  172. package/src/api.extends.json +1 -0
  173. package/src/components/avatar/__tests__/QAvatar.spec.js +1 -1
  174. package/src/components/badge/QBadge.js +2 -2
  175. package/src/components/badge/__tests__/QBadge.spec.js +1 -1
  176. package/src/components/btn/QBtn.js +2 -2
  177. package/src/components/checkbox/use-checkbox.js +8 -7
  178. package/src/components/dialog/QDialog.js +3 -1
  179. package/src/components/dialog/QDialog.json +7 -0
  180. package/src/components/editor/QEditor.js +11 -25
  181. package/src/components/file/QFile.js +6 -1
  182. package/src/components/icon/QIcon.js +24 -1
  183. package/src/components/icon/QIcon.sass +7 -3
  184. package/src/components/img/QImg.sass +1 -0
  185. package/src/components/infinite-scroll/QInfiniteScroll.js +10 -10
  186. package/src/components/input/QInput.js +6 -1
  187. package/src/components/item/QItem.js +5 -2
  188. package/src/components/item/QItem.json +2 -1
  189. package/src/components/layout/QLayout.js +2 -1
  190. package/src/components/menu/__tests__/QMenu.spec.js +23 -23
  191. package/src/components/pagination/QPagination.json +1 -1
  192. package/src/components/radio/QRadio.js +2 -2
  193. package/src/components/select/QSelect.js +28 -16
  194. package/src/components/select/__tests__/QSelect.spec.js +427 -451
  195. package/src/components/slider/use-slider.js +1 -1
  196. package/src/components/table/QTable.js +0 -1
  197. package/src/components/table/QTable.json +3 -0
  198. package/src/components/table/QTable.sass +1 -1
  199. package/src/components/tabs/QTabs.sass +0 -6
  200. package/src/components/uploader/uploader-core.js +23 -18
  201. package/src/components/virtual-scroll/use-virtual-scroll.js +9 -4
  202. package/src/composables/private/__tests__/use-anchor.spec.js +6 -6
  203. package/src/composables/private/__tests__/use-field.spec.js +7 -7
  204. package/src/composables/private/__tests__/use-model-toggle.spec.js +20 -19
  205. package/src/composables/private/__tests__/use-size.spec.js +2 -2
  206. package/src/composables/private/__tests__/use-transition.spec.js +5 -5
  207. package/src/composables/private/__tests__/use-validate.spec.js +5 -5
  208. package/src/composables/private/use-anchor.js +1 -1
  209. package/src/composables/private/use-field.js +2 -1
  210. package/src/composables/private/use-key-composition.js +16 -13
  211. package/src/directives/Ripple.js +2 -7
  212. package/src/utils/date.js +1 -1
  213. package/src/utils/private/global-dialog.js +22 -10
  214. package/src/components/select/__tests__/WrapperOne.vue +0 -28
@@ -129,7 +129,7 @@ export default function ({ updateValue, updatePosition, getDragging, formAttrs }
129
129
  && innerMin.value < innerMax.value
130
130
  ))
131
131
 
132
- const decimals = computed(() => (String(props.step).trim('0').split('.')[ 1 ] || '').length)
132
+ const decimals = computed(() => (String(props.step).trim().split('.')[ 1 ] || '').length)
133
133
  const step = computed(() => (props.step === 0 ? 1 : props.step))
134
134
  const tabindex = computed(() => (editable.value === true ? props.tabindex || 0 : -1))
135
135
 
@@ -152,7 +152,6 @@ export default createComponent({
152
152
 
153
153
  const __containerClass = computed(() =>
154
154
  `q-table__container q-table--${ props.separator }-separator column no-wrap`
155
- + (props.loading === true ? ' q-table--loading' : '')
156
155
  + (props.grid === true ? ' q-table--grid' : cardDefaultClass.value)
157
156
  + (isDark.value === true ? ' q-table--dark' : '')
158
157
  + (props.dense === true ? ' q-table--dense' : '')
@@ -676,6 +676,7 @@
676
676
  "examples": [ 100, 200 ]
677
677
  }
678
678
  },
679
+ "syncable": true,
679
680
  "examples": [
680
681
  ":pagination=\"myInitialPagination\"",
681
682
  "v-model:pagination=\"myPagination\""
@@ -706,6 +707,7 @@
706
707
  "type": "Array",
707
708
  "desc": "Keeps the user selection array",
708
709
  "default": "[]",
710
+ "syncable": true,
709
711
  "examples": [
710
712
  "v-model:selected=\"selection\""
711
713
  ],
@@ -716,6 +718,7 @@
716
718
  "type": "Array",
717
719
  "desc": "Keeps the array with expanded rows keys",
718
720
  "default": "[]",
721
+ "syncable": true,
719
722
  "examples": [
720
723
  "v-model:expanded=\"expanded\""
721
724
  ],
@@ -183,7 +183,7 @@
183
183
  * Separators
184
184
  */
185
185
  .q-table--horizontal-separator, .q-table--cell-separator
186
- thead th, tbody tr:not(:last-child) td
186
+ thead th, tbody tr:not(:last-child) > td
187
187
  border-bottom-width: 1px
188
188
 
189
189
  .q-table--vertical-separator, .q-table--cell-separator
@@ -181,9 +181,3 @@
181
181
  min-height: 36px
182
182
  &--full
183
183
  min-height: 52px
184
-
185
-
186
- @media (min-width: $breakpoint-lg-min)
187
- .q-header, .q-footer
188
- .q-tab__content
189
- min-width: 128px
@@ -149,6 +149,7 @@ export function getRenderer (getPlugin) {
149
149
  + (props.square === true ? ' q-uploader--square no-border-radius' : '')
150
150
  + (props.flat === true ? ' q-uploader--flat no-shadow' : '')
151
151
  + (props.disable === true ? ' disabled q-uploader--disable' : '')
152
+ + (dnd.value === true ? ' q-uploader--dnd' : '')
152
153
  )
153
154
 
154
155
  const colorClass = computed(() =>
@@ -339,28 +340,32 @@ export function getRenderer (getPlugin) {
339
340
 
340
341
  return [
341
342
  h('div', {
342
- class: 'q-uploader__header-content flex flex-center no-wrap q-gutter-xs'
343
+ class: 'q-uploader__header-content column'
343
344
  }, [
344
- getBtn(state.queuedFiles.value.length > 0, 'removeQueue', removeQueuedFiles),
345
- getBtn(state.uploadedFiles.value.length > 0, 'removeUploaded', removeUploadedFiles),
346
-
347
- state.isUploading.value === true
348
- ? h(QSpinner, { class: 'q-uploader__spinner' })
349
- : null,
350
-
351
- h('div', { class: 'col column justify-center' }, [
352
- props.label !== void 0
353
- ? h('div', { class: 'q-uploader__title' }, [ props.label ])
345
+ h('div', {
346
+ class: 'flex flex-center no-wrap q-gutter-xs'
347
+ }, [
348
+ getBtn(state.queuedFiles.value.length > 0, 'removeQueue', removeQueuedFiles),
349
+ getBtn(state.uploadedFiles.value.length > 0, 'removeUploaded', removeUploadedFiles),
350
+
351
+ state.isUploading.value === true
352
+ ? h(QSpinner, { class: 'q-uploader__spinner' })
354
353
  : null,
355
354
 
356
- h('div', { class: 'q-uploader__subtitle' }, [
357
- uploadSizeLabel.value + ' / ' + uploadProgressLabel.value
358
- ])
359
- ]),
355
+ h('div', { class: 'col column justify-center' }, [
356
+ props.label !== void 0
357
+ ? h('div', { class: 'q-uploader__title' }, [ props.label ])
358
+ : null,
359
+
360
+ h('div', { class: 'q-uploader__subtitle' }, [
361
+ uploadSizeLabel.value + ' / ' + uploadProgressLabel.value
362
+ ])
363
+ ]),
360
364
 
361
- getBtn(canAddFiles.value, 'add'),
362
- getBtn(props.hideUploadBtn === false && canUpload.value === true, 'upload', state.upload),
363
- getBtn(state.isUploading.value, 'clear', state.abort)
365
+ getBtn(canAddFiles.value, 'add'),
366
+ getBtn(props.hideUploadBtn === false && canUpload.value === true, 'upload', state.upload),
367
+ getBtn(state.isUploading.value, 'clear', state.abort)
368
+ ])
364
369
  ])
365
370
  ]
366
371
  }
@@ -20,8 +20,13 @@ const filterProto = Array.prototype.filter
20
20
  const setOverflowAnchor = __QUASAR_SSR__ || window.getComputedStyle(document.body).overflowAnchor === void 0
21
21
  ? noop
22
22
  : function (contentEl, index) {
23
- requestAnimationFrame(() => {
24
- if (contentEl === void 0) {
23
+ if (contentEl === null) {
24
+ return
25
+ }
26
+
27
+ cancelAnimationFrame(contentEl._qOverflowAnimationFrame)
28
+ contentEl._qOverflowAnimationFrame = requestAnimationFrame(() => {
29
+ if (contentEl === null) {
25
30
  return
26
31
  }
27
32
 
@@ -415,7 +420,7 @@ export function useVirtualScroll ({
415
420
  contentEl.addEventListener('focusout', onBlurRefocusFn)
416
421
 
417
422
  setTimeout(() => {
418
- contentEl !== void 0 && contentEl.removeEventListener('focusout', onBlurRefocusFn)
423
+ contentEl !== null && contentEl.removeEventListener('focusout', onBlurRefocusFn)
419
424
  })
420
425
  }
421
426
 
@@ -528,7 +533,7 @@ export function useVirtualScroll ({
528
533
  }
529
534
 
530
535
  function onBlurRefocusFn () {
531
- contentRef.value !== void 0 && contentRef.value.focus()
536
+ contentRef.value !== null && contentRef.value !== void 0 && contentRef.value.focus()
532
537
  }
533
538
 
534
539
  function localResetVirtualScroll (toIndex, fullReset) {
@@ -7,7 +7,7 @@ describe('use-anchor API', () => {
7
7
  describe('(prop): target', () => {
8
8
  it('should use another target using a CSS selector', () => {
9
9
  mount(WrapperOne, {
10
- attrs: {
10
+ props: {
11
11
  target: '.other-target'
12
12
  }
13
13
  })
@@ -27,7 +27,7 @@ describe('use-anchor API', () => {
27
27
 
28
28
  it('should not show when target is false', () => {
29
29
  mount(WrapperOne, {
30
- attrs: {
30
+ props: {
31
31
  target: false
32
32
  }
33
33
  })
@@ -42,7 +42,7 @@ describe('use-anchor API', () => {
42
42
  describe('(prop): no-parent-event', () => {
43
43
  it('should not show when clicking parent with no-parent-event true', () => {
44
44
  mount(WrapperOne, {
45
- attrs: {
45
+ props: {
46
46
  'no-parent-event': true
47
47
  }
48
48
  })
@@ -55,7 +55,7 @@ describe('use-anchor API', () => {
55
55
 
56
56
  it('should show when clicking parent with no-parent-event false', () => {
57
57
  mount(WrapperOne, {
58
- attrs: {
58
+ props: {
59
59
  'no-parent-event': false
60
60
  }
61
61
  })
@@ -70,7 +70,7 @@ describe('use-anchor API', () => {
70
70
  describe('(prop): context-menu', () => {
71
71
  it('should not show when left clicking parent', () => {
72
72
  mount(WrapperOne, {
73
- attrs: {
73
+ props: {
74
74
  'context-menu': true
75
75
  }
76
76
  })
@@ -83,7 +83,7 @@ describe('use-anchor API', () => {
83
83
 
84
84
  it('should show when right clicking parent', () => {
85
85
  mount(WrapperOne, {
86
- attrs: {
86
+ props: {
87
87
  'context-menu': true
88
88
  }
89
89
  })
@@ -42,7 +42,7 @@ describe('use-field API', () => {
42
42
  it('should show the label when supplied', () => {
43
43
  const label = 'Select something'
44
44
  mount(FieldWrapper, {
45
- attrs: {
45
+ props: {
46
46
  label
47
47
  }
48
48
  })
@@ -53,7 +53,7 @@ describe('use-field API', () => {
53
53
  it('should show the label centered when not focused', () => {
54
54
  const label = 'Select something'
55
55
  mount(FieldWrapper, {
56
- attrs: {
56
+ props: {
57
57
  label
58
58
  }
59
59
  })
@@ -66,7 +66,7 @@ describe('use-field API', () => {
66
66
  it('should show the label stacked when focused', () => {
67
67
  const label = 'Select something'
68
68
  mount(FieldWrapper, {
69
- attrs: {
69
+ props: {
70
70
  label
71
71
  }
72
72
  })
@@ -82,7 +82,7 @@ describe('use-field API', () => {
82
82
  it('should show the label stacked', () => {
83
83
  const label = 'Select something'
84
84
  mount(FieldWrapper, {
85
- attrs: {
85
+ props: {
86
86
  label,
87
87
  stackLabel: true
88
88
  }
@@ -97,7 +97,7 @@ describe('use-field API', () => {
97
97
  it('should show a hint text', () => {
98
98
  const hint = 'Select something'
99
99
  mount(FieldWrapper, {
100
- attrs: {
100
+ props: {
101
101
  hint
102
102
  }
103
103
  })
@@ -110,7 +110,7 @@ describe('use-field API', () => {
110
110
  it('should not show a hint text when not focused', () => {
111
111
  const hint = 'Select something'
112
112
  mount(FieldWrapper, {
113
- attrs: {
113
+ props: {
114
114
  hint,
115
115
  hideHint: true
116
116
  }
@@ -121,7 +121,7 @@ describe('use-field API', () => {
121
121
  it('should show a hint text when focused', () => {
122
122
  const hint = 'Select something'
123
123
  mount(FieldWrapper, {
124
- attrs: {
124
+ props: {
125
125
  hint,
126
126
  hideHint: true
127
127
  }
@@ -3,40 +3,41 @@ import { mount } from '@cypress/vue'
3
3
  import WrapperOne from './../../../components/menu/__tests__/WrapperOne.vue'
4
4
  import WrapperTwo from './../../../components/menu/__tests__/WrapperTwo.vue'
5
5
  import { ref } from 'vue'
6
+ import { vModelAdapter } from '../../../../test/cypress/helpers/v-model-adapter'
6
7
 
7
8
  describe('use-model-toggle API', () => {
8
9
  describe('Props', () => {
9
10
  describe('Category: model', () => {
10
11
  describe('(prop): model-value', () => {
11
12
  it('should open the dialog when modifying the model-value', () => {
12
- const modelValue = ref(false)
13
+ const model = ref(false)
13
14
  mount(WrapperOne, {
14
- attrs: {
15
- modelValue
15
+ props: {
16
+ ...vModelAdapter(model)
16
17
  }
17
18
  })
18
19
  cy.dataCy('wrapper')
19
20
  cy.dataCy('menu')
20
21
  .should('not.exist')
21
22
  .then(() => {
22
- modelValue.value = true
23
+ model.value = true
23
24
  cy.dataCy('menu')
24
25
  .should('exist')
25
26
  })
26
27
  })
27
28
 
28
29
  it('should close the dialog when modifying the model-value', () => {
29
- const modelValue = ref(true)
30
+ const model = ref(true)
30
31
  mount(WrapperOne, {
31
- attrs: {
32
- modelValue
32
+ props: {
33
+ ...vModelAdapter(model)
33
34
  }
34
35
  })
35
36
  cy.dataCy('wrapper')
36
37
  cy.dataCy('menu')
37
38
  .should('exist')
38
39
  .then(() => {
39
- modelValue.value = false
40
+ model.value = false
40
41
  cy.dataCy('menu')
41
42
  .should('not.exist')
42
43
  })
@@ -50,7 +51,7 @@ describe('use-model-toggle API', () => {
50
51
  it('should emit @update:model-value event when state changes', () => {
51
52
  const fn = cy.stub()
52
53
  mount(WrapperOne, {
53
- attrs: {
54
+ props: {
54
55
  'onUpdate:modelValue': fn
55
56
  }
56
57
  })
@@ -70,7 +71,7 @@ describe('use-model-toggle API', () => {
70
71
  it('should emit @show event when menu is triggered by parent', () => {
71
72
  const fn = cy.stub()
72
73
  mount(WrapperOne, {
73
- attrs: {
74
+ props: {
74
75
  onShow: fn
75
76
  }
76
77
  })
@@ -89,7 +90,7 @@ describe('use-model-toggle API', () => {
89
90
  it('should emit @show event when component is triggered with the show() method', () => {
90
91
  const fn = cy.stub()
91
92
  mount(WrapperOne, {
92
- attrs: {
93
+ props: {
93
94
  onShow: fn
94
95
  }
95
96
  })
@@ -111,7 +112,7 @@ describe('use-model-toggle API', () => {
111
112
  it('should emit @before-show event when menu is triggered by parent', () => {
112
113
  const fn = cy.stub()
113
114
  mount(WrapperOne, {
114
- attrs: {
115
+ props: {
115
116
  onBeforeShow: fn
116
117
  }
117
118
  })
@@ -129,7 +130,7 @@ describe('use-model-toggle API', () => {
129
130
  it('should emit @before-show event when component is triggered with the show() method', () => {
130
131
  const fn = cy.stub()
131
132
  mount(WrapperOne, {
132
- attrs: {
133
+ props: {
133
134
  onBeforeShow: fn
134
135
  }
135
136
  })
@@ -150,7 +151,7 @@ describe('use-model-toggle API', () => {
150
151
  it('should emit @hide event when menu is triggered by parent', () => {
151
152
  const fn = cy.stub()
152
153
  mount(WrapperOne, {
153
- attrs: {
154
+ props: {
154
155
  onHide: fn
155
156
  }
156
157
  })
@@ -175,7 +176,7 @@ describe('use-model-toggle API', () => {
175
176
  it('should emit @hide event when component is triggered with the show() method', () => {
176
177
  const fn = cy.stub()
177
178
  mount(WrapperOne, {
178
- attrs: {
179
+ props: {
179
180
  onHide: fn
180
181
  }
181
182
  })
@@ -203,7 +204,7 @@ describe('use-model-toggle API', () => {
203
204
  it('should emit @before-hide event when menu is triggered by parent', () => {
204
205
  const fn = cy.stub()
205
206
  mount(WrapperOne, {
206
- attrs: {
207
+ props: {
207
208
  onBeforeHide: fn
208
209
  }
209
210
  })
@@ -228,7 +229,7 @@ describe('use-model-toggle API', () => {
228
229
  it('should emit @before-hide event when component is triggered with the show() method', () => {
229
230
  const fn = cy.stub()
230
231
  mount(WrapperOne, {
231
- attrs: {
232
+ props: {
232
233
  onBeforeHide: fn
233
234
  }
234
235
  })
@@ -255,7 +256,7 @@ describe('use-model-toggle API', () => {
255
256
 
256
257
  describe('Methods', () => {
257
258
  describe('(method): show', () => {
258
- it('should tigger the menu to show', () => {
259
+ it('should trigger the menu to show', () => {
259
260
  mount(WrapperOne)
260
261
 
261
262
  cy.dataCy('wrapper')
@@ -267,7 +268,7 @@ describe('use-model-toggle API', () => {
267
268
  })
268
269
 
269
270
  describe('(method): hide', () => {
270
- it('should tigger the menu to hide', () => {
271
+ it('should trigger the menu to hide', () => {
271
272
  mount(WrapperOne)
272
273
 
273
274
  cy.dataCy('wrapper')
@@ -1,6 +1,6 @@
1
- import QAvatar from './../../../components/avatar/QAvatar'
1
+ import QAvatar from './../../../components/avatar/QAvatar.js'
2
2
  import { mount } from '@cypress/vue'
3
- import { useSizeDefaults } from './../use-size'
3
+ import { useSizeDefaults } from './../use-size.js'
4
4
 
5
5
  describe('use-size API', () => {
6
6
  describe('Props', () => {
@@ -16,7 +16,7 @@ describe('use-transition API', () => {
16
16
  it('should use a different show transition if defined', () => {
17
17
  const transition = 'scale'
18
18
  mount(WrapperOne, {
19
- attrs: {
19
+ props: {
20
20
  transitionShow: transition
21
21
  }
22
22
  })
@@ -43,7 +43,7 @@ describe('use-transition API', () => {
43
43
  it('should use a different hide transition if defined', () => {
44
44
  const transition = 'scale'
45
45
  mount(WrapperOne, {
46
- attrs: {
46
+ props: {
47
47
  transitionHide: transition
48
48
  }
49
49
  })
@@ -64,7 +64,7 @@ describe('use-transition API', () => {
64
64
  cy.dataCy('wrapper')
65
65
  .click()
66
66
  .wait(300)
67
- cy.dataCy('menu', { timeout: 0 }) // Disable retry
67
+ cy.dataCy('menu', { timeout: 350 })
68
68
  .should('not.have.class', 'q-transition--fade-enter-active')
69
69
  })
70
70
 
@@ -79,7 +79,7 @@ describe('use-transition API', () => {
79
79
 
80
80
  it('should be done after a custom 1000ms passed', () => {
81
81
  mount(WrapperOne, {
82
- attrs: {
82
+ props: {
83
83
  transitionDuration: 1000
84
84
  }
85
85
  })
@@ -92,7 +92,7 @@ describe('use-transition API', () => {
92
92
 
93
93
  it('should not be done before a custom 1000ms passed', () => {
94
94
  mount(WrapperOne, {
95
- attrs: {
95
+ props: {
96
96
  transitionDuration: 1000
97
97
  }
98
98
  })
@@ -1,6 +1,6 @@
1
1
  import { mount } from '@cypress/vue'
2
2
  import FieldWrapper from './FieldWrapper.vue'
3
- import Icons from './../../../../icon-set/material-icons'
3
+ import Icons from './../../../../icon-set/material-icons.mjs'
4
4
 
5
5
  // const snapshotOptions = { customSnapshotsDir: '../__tests__' }
6
6
 
@@ -37,7 +37,7 @@ describe('use-validate API', () => {
37
37
  it('should show an error-message when error is true', () => {
38
38
  const message = 'Please select something'
39
39
  mount(FieldWrapper, {
40
- attrs: {
40
+ props: {
41
41
  error: true,
42
42
  errorMessage: message
43
43
  }
@@ -49,7 +49,7 @@ describe('use-validate API', () => {
49
49
  it('should not show an error-message when error is false', () => {
50
50
  const message = 'Please select something'
51
51
  mount(FieldWrapper, {
52
- attrs: {
52
+ props: {
53
53
  error: false,
54
54
  errorMessage: message
55
55
  }
@@ -62,7 +62,7 @@ describe('use-validate API', () => {
62
62
  describe('(prop): no-error-icon', () => {
63
63
  it('should not show an error icon when error is true', () => {
64
64
  mount(FieldWrapper, {
65
- attrs: {
65
+ props: {
66
66
  error: true,
67
67
  noErrorIcon: true
68
68
  }
@@ -74,7 +74,7 @@ describe('use-validate API', () => {
74
74
 
75
75
  it('should show an error icon when error is true an no-error-icon is false', () => {
76
76
  mount(FieldWrapper, {
77
- attrs: {
77
+ props: {
78
78
  error: true,
79
79
  noErrorIcon: false
80
80
  }
@@ -137,7 +137,7 @@ export default function ({
137
137
  }
138
138
 
139
139
  function pickAnchorEl () {
140
- if (props.target === false || props.target === '') {
140
+ if (props.target === false || props.target === '' || proxy.$el.parentNode === null) {
141
141
  anchorEl.value = null
142
142
  }
143
143
  else if (props.target === true) {
@@ -445,6 +445,7 @@ export default function (state) {
445
445
  h('div', {
446
446
  ref: state.targetRef,
447
447
  class: 'q-field__native row',
448
+ tabindex: -1,
448
449
  ...state.splitAttrs.attributes.value,
449
450
  'data-autofocus': props.autofocus === true || void 0
450
451
  }, slots.control(controlSlotScope.value))
@@ -555,7 +556,7 @@ export default function (state) {
555
556
  const labelAttrs = state.getControl === void 0 && slots.control === void 0
556
557
  ? {
557
558
  ...state.splitAttrs.attributes.value,
558
- 'data-autofocus': props.autofocus,
559
+ 'data-autofocus': props.autofocus === true || void 0,
559
560
  ...attributes.value
560
561
  }
561
562
  : attributes.value
@@ -1,26 +1,29 @@
1
+ import { client } from '../../plugins/Platform.js'
2
+
1
3
  const isJapanese = /[\u3000-\u303f\u3040-\u309f\u30a0-\u30ff\uff00-\uff9f\u4e00-\u9faf\u3400-\u4dbf]/
2
4
  const isChinese = /[\u4e00-\u9fff\u3400-\u4dbf\u{20000}-\u{2a6df}\u{2a700}-\u{2b73f}\u{2b740}-\u{2b81f}\u{2b820}-\u{2ceaf}\uf900-\ufaff\u3300-\u33ff\ufe30-\ufe4f\uf900-\ufaff\u{2f800}-\u{2fa1f}]/u
3
5
  const isKorean = /[\u3131-\u314e\u314f-\u3163\uac00-\ud7a3]/
6
+ const isPlainText = /[a-z0-9_ -]$/i
4
7
 
5
8
  export default function (onInput) {
6
9
  return function onComposition (e) {
7
10
  if (e.type === 'compositionend' || e.type === 'change') {
8
- if (e.target.composing !== true) { return }
9
- e.target.composing = false
11
+ if (e.target.qComposing !== true) { return }
12
+ e.target.qComposing = false
10
13
  onInput(e)
11
14
  }
12
- else if (e.type === 'compositionupdate') {
13
- if (
14
- typeof e.data === 'string'
15
- && isJapanese.test(e.data) === false
16
- && isChinese.test(e.data) === false
17
- && isKorean.test(e.data) === false
18
- ) {
19
- e.target.composing = false
15
+ else if (
16
+ e.type === 'compositionupdate'
17
+ && e.target.qComposing !== true
18
+ && typeof e.data === 'string'
19
+ ) {
20
+ const isComposing = client.is.firefox === true
21
+ ? isPlainText.test(e.data) === false
22
+ : isJapanese.test(e.data) === true || isChinese.test(e.data) === true || isKorean.test(e.data) === true
23
+
24
+ if (isComposing === true) {
25
+ e.target.qComposing = true
20
26
  }
21
27
  }
22
- else {
23
- e.target.composing = true
24
- }
25
28
  }
26
29
  }
@@ -87,11 +87,7 @@ export default createDirective(__QUASAR_SSR_SERVER__
87
87
  if (
88
88
  ctx.enabled === true
89
89
  && evt.qSkipRipple !== true
90
- && (
91
- ctx.modifiers.early === true
92
- ? [ 'mousedown', 'touchstart' ].includes(evt.type) === true
93
- : evt.type === 'click'
94
- )
90
+ && evt.type === (ctx.modifiers.early === true ? 'pointerdown' : 'click')
95
91
  ) {
96
92
  showRipple(evt, el, ctx, evt.qKeyEvent === true)
97
93
  }
@@ -114,8 +110,7 @@ export default createDirective(__QUASAR_SSR_SERVER__
114
110
  el.__qripple = ctx
115
111
 
116
112
  addEvt(ctx, 'main', [
117
- [ el, 'mousedown', 'start', 'passive' ],
118
- [ el, 'touchstart', 'start', 'passive' ],
113
+ [ el, 'pointerdown', 'start', 'passive' ],
119
114
  [ el, 'click', 'start', 'passive' ],
120
115
  [ el, 'keydown', 'keystart', 'passive' ],
121
116
  [ el, 'keyup', 'keystart', 'passive' ]
package/src/utils/date.js CHANGED
@@ -308,7 +308,7 @@ export function extractDate (str, mask, dateLocale) {
308
308
  const date = new Date(
309
309
  d.year,
310
310
  d.month === null ? null : d.month - 1,
311
- d.day,
311
+ d.day === null ? 1 : d.day,
312
312
  d.hour,
313
313
  d.minute,
314
314
  d.second,
@@ -59,19 +59,31 @@ export default function (DefaultComponent, supportsCustomComponent, parentApp) {
59
59
  const applyState = cmd => {
60
60
  if (dialogRef.value !== null && dialogRef.value[ cmd ] !== void 0) {
61
61
  dialogRef.value[ cmd ]()
62
+ return
62
63
  }
63
- else if (
64
+
65
+ const target = vm.$.subTree
66
+
67
+ if (target && target.component) {
64
68
  // account for "script setup" way of declaring component
65
- vm.$.subTree
66
- && vm.$.subTree.component
67
- && vm.$.subTree.component.proxy
68
- && vm.$.subTree.component.proxy[ cmd ]
69
- ) {
70
- vm.$.subTree.component.proxy[ cmd ]()
71
- }
72
- else {
73
- console.error('[Quasar] Incorrectly defined Dialog component')
69
+ if (target.component.proxy && target.component.proxy[ cmd ]) {
70
+ target.component.proxy[ cmd ]()
71
+ return
72
+ }
73
+
74
+ // account for "script setup" + async component way of declaring component
75
+ if (
76
+ target.component.subTree &&
77
+ target.component.subTree.component &&
78
+ target.component.subTree.component.proxy &&
79
+ target.component.subTree.component.proxy[ cmd ]
80
+ ) {
81
+ target.component.subTree.component.proxy[ cmd ]()
82
+ return
83
+ }
74
84
  }
85
+
86
+ console.error('[Quasar] Incorrectly defined Dialog component')
75
87
  }
76
88
 
77
89
  const