q2-tecton-elements 1.67.0 → 1.67.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 (256) hide show
  1. package/dist/bundle-report.json +431 -431
  2. package/dist/cjs/click-elsewhere.q2-option-list.q2-popover.entry.cjs.js.map +1 -1
  3. package/dist/cjs/click-elsewhere_3.cjs.entry.js +41 -14
  4. package/dist/cjs/click-elsewhere_3.cjs.entry.js.map +1 -1
  5. package/dist/cjs/q2-action-group_2.cjs.entry.js +2 -2
  6. package/dist/cjs/q2-action-sheet.cjs.entry.js +1 -1
  7. package/dist/cjs/q2-avatar.cjs.entry.js +1 -1
  8. package/dist/cjs/q2-btn.q2-loading.entry.cjs.js.map +1 -1
  9. package/dist/cjs/q2-btn_2.cjs.entry.js +4 -2
  10. package/dist/cjs/q2-btn_2.cjs.entry.js.map +1 -1
  11. package/dist/cjs/q2-calendar.cjs.entry.js +1 -1
  12. package/dist/cjs/q2-card-image.cjs.entry.js +2 -2
  13. package/dist/cjs/q2-carousel-pane.cjs.entry.js +2 -2
  14. package/dist/cjs/q2-carousel.cjs.entry.js +1 -1
  15. package/dist/cjs/q2-chart-area.cjs.entry.js +1 -1
  16. package/dist/cjs/q2-chart-bar.cjs.entry.js +1 -1
  17. package/dist/cjs/q2-chart-donut.cjs.entry.js +1 -1
  18. package/dist/cjs/q2-checkbox-group.cjs.entry.js +1 -1
  19. package/dist/cjs/q2-checkbox_2.cjs.entry.js +1 -1
  20. package/dist/cjs/q2-context.cjs.entry.js +1 -1
  21. package/dist/cjs/q2-currency.cjs.entry.js +1 -1
  22. package/dist/cjs/q2-data-table.cjs.entry.js +1 -1
  23. package/dist/cjs/q2-detail.cjs.entry.js +1 -1
  24. package/dist/cjs/q2-dropdown.cjs.entry.js +1 -1
  25. package/dist/cjs/q2-editable-field.cjs.entry.js +1 -1
  26. package/dist/cjs/q2-example.cjs.entry.js +1 -1
  27. package/dist/cjs/q2-form.cjs.entry.js +1 -1
  28. package/dist/cjs/q2-formatted-text.cjs.entry.js +1 -1
  29. package/dist/cjs/q2-grid-area.cjs.entry.js +1 -1
  30. package/dist/cjs/q2-grid.cjs.entry.js +1 -1
  31. package/dist/cjs/q2-input.cjs.entry.js +1 -1
  32. package/dist/cjs/q2-item.cjs.entry.js +1 -1
  33. package/dist/cjs/q2-legend.cjs.entry.js +1 -1
  34. package/dist/cjs/q2-link_2.cjs.entry.js +1 -1
  35. package/dist/cjs/q2-message.cjs.entry.js +1 -1
  36. package/dist/cjs/q2-meter.cjs.entry.js +1 -1
  37. package/dist/cjs/q2-modal.cjs.entry.js +1 -1
  38. package/dist/cjs/q2-month-picker.cjs.entry.js +2 -2
  39. package/dist/cjs/q2-mutation-observer.cjs.entry.js +1 -1
  40. package/dist/cjs/q2-optgroup.cjs.entry.js +1 -1
  41. package/dist/cjs/q2-pagination.cjs.entry.js +3 -3
  42. package/dist/cjs/q2-pill.cjs.entry.js +1 -1
  43. package/dist/cjs/q2-radio-group.cjs.entry.js +1 -1
  44. package/dist/cjs/q2-radio.cjs.entry.js +1 -1
  45. package/dist/cjs/q2-relative-time.cjs.entry.js +1 -1
  46. package/dist/cjs/q2-section.cjs.entry.js +2 -2
  47. package/dist/cjs/q2-select.cjs.entry.js +1 -1
  48. package/dist/cjs/q2-stepper-pane.cjs.entry.js +1 -1
  49. package/dist/cjs/q2-stepper.cjs.entry.js +1 -1
  50. package/dist/cjs/q2-textarea.cjs.entry.js +1 -1
  51. package/dist/collection/collection-manifest.json +3 -3
  52. package/dist/collection/components/q2-action-group/q2-action-group.js +1 -1
  53. package/dist/collection/components/q2-action-sheet/q2-action-sheet.js +1 -1
  54. package/dist/collection/components/q2-avatar/q2-avatar.js +1 -1
  55. package/dist/collection/components/q2-btn/q2-btn.js +4 -2
  56. package/dist/collection/components/q2-btn/q2-btn.js.map +1 -1
  57. package/dist/collection/components/q2-calendar/q2-calendar.js +1 -1
  58. package/dist/collection/components/q2-calendar/q2-month-picker.js +2 -2
  59. package/dist/collection/components/q2-card-image/q2-card-image.js +2 -2
  60. package/dist/collection/components/q2-carousel/q2-carousel.js +1 -1
  61. package/dist/collection/components/q2-carousel-pane/q2-carousel-pane.js +2 -2
  62. package/dist/collection/components/q2-chart-area/q2-chart-area.js +1 -1
  63. package/dist/collection/components/q2-chart-bar/q2-chart-bar.js +1 -1
  64. package/dist/collection/components/q2-chart-donut/q2-chart-donut.js +1 -1
  65. package/dist/collection/components/q2-checkbox/q2-checkbox.js +1 -1
  66. package/dist/collection/components/q2-checkbox-group/q2-checkbox-group.js +1 -1
  67. package/dist/collection/components/q2-context/q2-context.js +1 -1
  68. package/dist/collection/components/q2-currency/q2-currency.js +1 -1
  69. package/dist/collection/components/q2-data-table/q2-data-table.js +1 -1
  70. package/dist/collection/components/q2-detail/q2-detail.js +1 -1
  71. package/dist/collection/components/q2-dropdown/q2-dropdown.js +1 -1
  72. package/dist/collection/components/q2-editable-field/q2-editable-field.js +2 -2
  73. package/dist/collection/components/q2-example/q2-example.js +1 -1
  74. package/dist/collection/components/q2-form/q2-form.js +1 -1
  75. package/dist/collection/components/q2-formatted-text/q2-formatted-text.js +1 -1
  76. package/dist/collection/components/q2-grid/q2-grid.js +31 -31
  77. package/dist/collection/components/q2-grid-area/q2-grid-area.js +43 -43
  78. package/dist/collection/components/q2-input/q2-input.js +3 -3
  79. package/dist/collection/components/q2-item/q2-item.js +1 -1
  80. package/dist/collection/components/q2-legend/q2-legend.js +1 -1
  81. package/dist/collection/components/q2-list/q2-list.js +1 -1
  82. package/dist/collection/components/q2-message/q2-message.js +1 -1
  83. package/dist/collection/components/q2-meter/q2-meter.js +1 -1
  84. package/dist/collection/components/q2-modal/q2-modal.js +1 -1
  85. package/dist/collection/components/q2-mutation-observer/q2-mutation-observer.js +1 -1
  86. package/dist/collection/components/q2-optgroup/q2-optgroup.js +1 -1
  87. package/dist/collection/components/q2-option-list/q2-option-list.js +6 -6
  88. package/dist/collection/components/q2-pagination/q2-pagination.js +3 -3
  89. package/dist/collection/components/q2-pill/q2-pill.js +1 -1
  90. package/dist/collection/components/q2-popover/q2-popover.js +40 -13
  91. package/dist/collection/components/q2-popover/q2-popover.js.map +1 -1
  92. package/dist/collection/components/q2-radio/q2-radio.js +1 -1
  93. package/dist/collection/components/q2-radio-group/q2-radio-group.js +1 -1
  94. package/dist/collection/components/q2-relative-time/q2-relative-time.js +1 -1
  95. package/dist/collection/components/q2-resize-observer/q2-resize-observer.js +1 -1
  96. package/dist/collection/components/q2-section/q2-section.js +2 -2
  97. package/dist/collection/components/q2-select/q2-select.js +1 -1
  98. package/dist/collection/components/q2-stepper/q2-stepper.js +1 -1
  99. package/dist/collection/components/q2-stepper-pane/q2-stepper-pane.js +1 -1
  100. package/dist/collection/components/q2-textarea/q2-textarea.js +1 -1
  101. package/dist/components/q2-action-group2.js +1 -1
  102. package/dist/components/q2-action-sheet.js +1 -1
  103. package/dist/components/q2-avatar2.js +1 -1
  104. package/dist/components/q2-btn2.js +4 -2
  105. package/dist/components/q2-btn2.js.map +1 -1
  106. package/dist/components/q2-calendar.js +1 -1
  107. package/dist/components/q2-card-image.js +2 -2
  108. package/dist/components/q2-carousel-pane.js +2 -2
  109. package/dist/components/q2-carousel.js +1 -1
  110. package/dist/components/q2-chart-area.js +1 -1
  111. package/dist/components/q2-chart-bar.js +1 -1
  112. package/dist/components/q2-chart-donut.js +1 -1
  113. package/dist/components/q2-checkbox-group.js +1 -1
  114. package/dist/components/q2-checkbox2.js +1 -1
  115. package/dist/components/q2-context.js +1 -1
  116. package/dist/components/q2-currency.js +1 -1
  117. package/dist/components/q2-data-table.js +1 -1
  118. package/dist/components/q2-detail.js +1 -1
  119. package/dist/components/q2-dropdown.js +1 -1
  120. package/dist/components/q2-editable-field.js +1 -1
  121. package/dist/components/q2-example.js +1 -1
  122. package/dist/components/q2-form.js +1 -1
  123. package/dist/components/q2-formatted-text.js +1 -1
  124. package/dist/components/q2-grid-area.js +1 -1
  125. package/dist/components/q2-grid.js +1 -1
  126. package/dist/components/q2-input2.js +1 -1
  127. package/dist/components/q2-item2.js +1 -1
  128. package/dist/components/q2-legend2.js +1 -1
  129. package/dist/components/q2-list2.js +1 -1
  130. package/dist/components/q2-message2.js +1 -1
  131. package/dist/components/q2-meter.js +1 -1
  132. package/dist/components/q2-modal.js +1 -1
  133. package/dist/components/q2-month-picker.js +2 -2
  134. package/dist/components/q2-mutation-observer.js +1 -1
  135. package/dist/components/q2-optgroup2.js +1 -1
  136. package/dist/components/q2-option-list2.js +1 -1
  137. package/dist/components/q2-pagination.js +3 -3
  138. package/dist/components/q2-pill.js +1 -1
  139. package/dist/components/q2-popover2.js +40 -13
  140. package/dist/components/q2-popover2.js.map +1 -1
  141. package/dist/components/q2-radio-group.js +1 -1
  142. package/dist/components/q2-radio.js +1 -1
  143. package/dist/components/q2-relative-time.js +1 -1
  144. package/dist/components/q2-resize-observer2.js +1 -1
  145. package/dist/components/q2-section.js +2 -2
  146. package/dist/components/q2-select2.js +1 -1
  147. package/dist/components/q2-stepper-pane.js +1 -1
  148. package/dist/components/q2-stepper.js +1 -1
  149. package/dist/components/q2-textarea.js +1 -1
  150. package/dist/esm/click-elsewhere.q2-option-list.q2-popover.entry.js.map +1 -1
  151. package/dist/esm/click-elsewhere_3.entry.js +41 -14
  152. package/dist/esm/click-elsewhere_3.entry.js.map +1 -1
  153. package/dist/esm/q2-action-group_2.entry.js +2 -2
  154. package/dist/esm/q2-action-sheet.entry.js +1 -1
  155. package/dist/esm/q2-avatar.entry.js +1 -1
  156. package/dist/esm/q2-btn.q2-loading.entry.js.map +1 -1
  157. package/dist/esm/q2-btn_2.entry.js +4 -2
  158. package/dist/esm/q2-btn_2.entry.js.map +1 -1
  159. package/dist/esm/q2-calendar.entry.js +1 -1
  160. package/dist/esm/q2-card-image.entry.js +2 -2
  161. package/dist/esm/q2-carousel-pane.entry.js +2 -2
  162. package/dist/esm/q2-carousel.entry.js +1 -1
  163. package/dist/esm/q2-chart-area.entry.js +1 -1
  164. package/dist/esm/q2-chart-bar.entry.js +1 -1
  165. package/dist/esm/q2-chart-donut.entry.js +1 -1
  166. package/dist/esm/q2-checkbox-group.entry.js +1 -1
  167. package/dist/esm/q2-checkbox_2.entry.js +1 -1
  168. package/dist/esm/q2-context.entry.js +1 -1
  169. package/dist/esm/q2-currency.entry.js +1 -1
  170. package/dist/esm/q2-data-table.entry.js +1 -1
  171. package/dist/esm/q2-detail.entry.js +1 -1
  172. package/dist/esm/q2-dropdown.entry.js +1 -1
  173. package/dist/esm/q2-editable-field.entry.js +1 -1
  174. package/dist/esm/q2-example.entry.js +1 -1
  175. package/dist/esm/q2-form.entry.js +1 -1
  176. package/dist/esm/q2-formatted-text.entry.js +1 -1
  177. package/dist/esm/q2-grid-area.entry.js +1 -1
  178. package/dist/esm/q2-grid.entry.js +1 -1
  179. package/dist/esm/q2-input.entry.js +1 -1
  180. package/dist/esm/q2-item.entry.js +1 -1
  181. package/dist/esm/q2-legend.entry.js +1 -1
  182. package/dist/esm/q2-link_2.entry.js +1 -1
  183. package/dist/esm/q2-message.entry.js +1 -1
  184. package/dist/esm/q2-meter.entry.js +1 -1
  185. package/dist/esm/q2-modal.entry.js +1 -1
  186. package/dist/esm/q2-month-picker.entry.js +2 -2
  187. package/dist/esm/q2-mutation-observer.entry.js +1 -1
  188. package/dist/esm/q2-optgroup.entry.js +1 -1
  189. package/dist/esm/q2-pagination.entry.js +3 -3
  190. package/dist/esm/q2-pill.entry.js +1 -1
  191. package/dist/esm/q2-radio-group.entry.js +1 -1
  192. package/dist/esm/q2-radio.entry.js +1 -1
  193. package/dist/esm/q2-relative-time.entry.js +1 -1
  194. package/dist/esm/q2-section.entry.js +2 -2
  195. package/dist/esm/q2-select.entry.js +1 -1
  196. package/dist/esm/q2-stepper-pane.entry.js +1 -1
  197. package/dist/esm/q2-stepper.entry.js +1 -1
  198. package/dist/esm/q2-textarea.entry.js +1 -1
  199. package/dist/q2-tecton-elements/click-elsewhere.q2-option-list.q2-popover.entry.esm.js.map +1 -1
  200. package/dist/q2-tecton-elements/click-elsewhere_3.entry.js +212 -193
  201. package/dist/q2-tecton-elements/click-elsewhere_3.entry.js.map +1 -1
  202. package/dist/q2-tecton-elements/q2-action-group_2.entry.js +4 -4
  203. package/dist/q2-tecton-elements/q2-action-sheet.entry.js +8 -8
  204. package/dist/q2-tecton-elements/q2-avatar.entry.js +8 -8
  205. package/dist/q2-tecton-elements/q2-btn.q2-loading.entry.esm.js.map +1 -1
  206. package/dist/q2-tecton-elements/q2-btn_2.entry.js +4 -2
  207. package/dist/q2-tecton-elements/q2-btn_2.entry.js.map +1 -1
  208. package/dist/q2-tecton-elements/q2-calendar.entry.js +2 -2
  209. package/dist/q2-tecton-elements/q2-card-image.entry.js +2 -2
  210. package/dist/q2-tecton-elements/q2-carousel-pane.entry.js +3 -3
  211. package/dist/q2-tecton-elements/q2-carousel.entry.js +1 -1
  212. package/dist/q2-tecton-elements/q2-chart-area.entry.js +2 -2
  213. package/dist/q2-tecton-elements/q2-chart-bar.entry.js +2 -2
  214. package/dist/q2-tecton-elements/q2-chart-donut.entry.js +14 -14
  215. package/dist/q2-tecton-elements/q2-checkbox-group.entry.js +6 -6
  216. package/dist/q2-tecton-elements/q2-checkbox_2.entry.js +8 -8
  217. package/dist/q2-tecton-elements/q2-context.entry.js +15 -15
  218. package/dist/q2-tecton-elements/q2-currency.entry.js +11 -11
  219. package/dist/q2-tecton-elements/q2-data-table.entry.js +3 -3
  220. package/dist/q2-tecton-elements/q2-detail.entry.js +3 -3
  221. package/dist/q2-tecton-elements/q2-dropdown.entry.js +79 -79
  222. package/dist/q2-tecton-elements/q2-editable-field.entry.js +1 -1
  223. package/dist/q2-tecton-elements/q2-example.entry.js +1 -1
  224. package/dist/q2-tecton-elements/q2-form.entry.js +2 -2
  225. package/dist/q2-tecton-elements/q2-formatted-text.entry.js +2 -2
  226. package/dist/q2-tecton-elements/q2-grid-area.entry.js +2 -2
  227. package/dist/q2-tecton-elements/q2-grid.entry.js +3 -3
  228. package/dist/q2-tecton-elements/q2-input.entry.js +3 -3
  229. package/dist/q2-tecton-elements/q2-item.entry.js +21 -21
  230. package/dist/q2-tecton-elements/q2-legend.entry.js +2 -2
  231. package/dist/q2-tecton-elements/q2-link_2.entry.js +6 -6
  232. package/dist/q2-tecton-elements/q2-message.entry.js +6 -6
  233. package/dist/q2-tecton-elements/q2-meter.entry.js +7 -7
  234. package/dist/q2-tecton-elements/q2-modal.entry.js +50 -50
  235. package/dist/q2-tecton-elements/q2-month-picker.entry.js +66 -66
  236. package/dist/q2-tecton-elements/q2-mutation-observer.entry.js +1 -1
  237. package/dist/q2-tecton-elements/q2-optgroup.entry.js +4 -4
  238. package/dist/q2-tecton-elements/q2-pagination.entry.js +19 -19
  239. package/dist/q2-tecton-elements/q2-pill.entry.js +36 -36
  240. package/dist/q2-tecton-elements/q2-radio-group.entry.js +6 -6
  241. package/dist/q2-tecton-elements/q2-radio.entry.js +8 -8
  242. package/dist/q2-tecton-elements/q2-relative-time.entry.js +1 -1
  243. package/dist/q2-tecton-elements/q2-section.entry.js +22 -22
  244. package/dist/q2-tecton-elements/q2-select.entry.js +1 -1
  245. package/dist/q2-tecton-elements/q2-stepper-pane.entry.js +11 -11
  246. package/dist/q2-tecton-elements/q2-stepper.entry.js +25 -25
  247. package/dist/q2-tecton-elements/q2-textarea.entry.js +2 -2
  248. package/dist/types/components/q2-popover/q2-popover.d.ts +1 -0
  249. package/dist/types/components/q2-stepper-vertical/q2-stepper-vertical.d.ts +1 -1
  250. package/package.json +71 -69
  251. /package/dist/types/{Users/kvanhouten/Documents/Work/tecton_extra → builds/q2e/development/tecton/tecton}/packages/q2-tecton-elements/.stencil/jest.e2e-coverage.d.ts +0 -0
  252. /package/dist/types/{Users/kvanhouten/Documents/Work/tecton_extra → builds/q2e/development/tecton/tecton}/packages/q2-tecton-elements/.stencil/jest.setup.d.ts +0 -0
  253. /package/dist/types/{Users/kvanhouten/Documents/Work/tecton_extra → builds/q2e/development/tecton/tecton}/packages/q2-tecton-elements/.stencil/scripts/docs-generator/index.d.ts +0 -0
  254. /package/dist/types/{Users/kvanhouten/Documents/Work/tecton_extra → builds/q2e/development/tecton/tecton}/packages/q2-tecton-elements/.stencil/scripts/docs-generator/markdown-generator.d.ts +0 -0
  255. /package/dist/types/{Users/kvanhouten/Documents/Work/tecton_extra → builds/q2e/development/tecton/tecton}/packages/q2-tecton-elements/.stencil/scripts/docs-generator/tag-handlers.d.ts +0 -0
  256. /package/dist/types/{Users/kvanhouten/Documents/Work/tecton_extra → builds/q2e/development/tecton/tecton}/packages/q2-tecton-elements/.stencil/scripts/docs-generator/types.d.ts +0 -0
@@ -145,10 +145,10 @@ const Q2MonthPicker$1 = /*@__PURE__*/ proxyCustomElement(class Q2MonthPicker ext
145
145
  // #endregion
146
146
  // #region Render Methods
147
147
  render() {
148
- return (h("div", { key: 'a79408285992125baf4ab6771f6501d79a6245df', class: "month-container", onKeyDown: this.onMonthKeydown }, h("div", { key: '857185b3278ee9b9f346686e587a39250130e532', class: "navigation" }, h("q2-btn", { key: 'f698f8ea247ba18ecd40d22c74c4247fa300cf3d', class: "year-btn", onClick: () => this.viewChange.emit({
148
+ return (h("div", { key: 'b7429b5ed21f7cda666f140a9a93ee643176979c', class: "month-container", onKeyDown: this.onMonthKeydown }, h("div", { key: '802900b16d0efa602df89edb22e174329736dca4', class: "navigation" }, h("q2-btn", { key: '0a318088ab2eb826620c056246599f5b7803c51e', class: "year-btn", onClick: () => this.viewChange.emit({
149
149
  view: 'year',
150
150
  selectedYear: this.year,
151
- }) }, h("span", { key: 'fc467f87579a2a1c90c72e22aa49715ed4130d22', class: "year" }, this.year), h("q2-icon", { key: '545d4a90b2c57ef0109475746f963a879c4d69d8', class: "year-icon off", type: "chevron-down" })), h("div", { key: '1b1c130e07944ab988e981f41b3351237a638f7e', class: "month-controller" }, h("div", { key: '5967309b329f2f0697a26a69d91dfb50b0a6d526', class: "cal-year-prev-next" }, h("q2-btn", { key: '23295dbba205dd04a809511501b49b74bd845f16', label: loc('tecton.element.calendar.previousYear'), "hide-label": true, class: "cal-nav-btn prev-year", "test-id": "previousYearButton", onClick: () => this.selectYear(this.year - 1) }, h("q2-icon", { key: '845a1a049fe80fd08470cbaf1b530bcf41734c39', type: "arrow-left" })), h("q2-btn", { key: '2074d486e8a0d00cee2ac874230ff2411444f669', label: loc('tecton.element.calendar.nextYear'), "hide-label": true, class: "cal-nav-btn next-year", "test-id": "nextYearButton", onClick: () => this.selectYear(this.year + 1) }, h("q2-icon", { key: '97699d8fa0378afa468bbb71e8bce6ccb9e78423', type: "arrow-right" }))))), h("div", { key: 'f373f6a783137aca3691fdfdc70bea04d487b63e', class: "month-list", onClick: this.onMonthSelection }, this.months.map((month, index) => (h("div", { class: "month" }, h("span", { role: "button", class: "month-button", "data-index": index, "aria-label": month.label, tabindex: index === this.focusedIndex ? 0 : -1 }, month.abbr))))), this.today && (h("div", { key: 'b85641400c0c17171278735aa8e8b81f2497ac27', class: "today-label" }, loc('tecton.element.calendar.today'), ": ", this.today))));
151
+ }) }, h("span", { key: '02018f884cb7b48fb581597fc7d5a2a323497668', class: "year" }, this.year), h("q2-icon", { key: '9ab23a381d4fedb5aca2ecee19eb975d76ff4465', class: "year-icon off", type: "chevron-down" })), h("div", { key: '79dd4cd0864d051a4252c21ebbd697e0e75b0ec3', class: "month-controller" }, h("div", { key: 'd94ad2ebfc317206bfff5b16861c52507a168e09', class: "cal-year-prev-next" }, h("q2-btn", { key: '4d8b12fde9825bd5dca90012d42e73453f2cb777', label: loc('tecton.element.calendar.previousYear'), "hide-label": true, class: "cal-nav-btn prev-year", "test-id": "previousYearButton", onClick: () => this.selectYear(this.year - 1) }, h("q2-icon", { key: '428b2feb8854e145bdbc88bdd2c6a2c25a3a50ce', type: "arrow-left" })), h("q2-btn", { key: '2f7ef439402c9788ae002a199813387a370e0ed3', label: loc('tecton.element.calendar.nextYear'), "hide-label": true, class: "cal-nav-btn next-year", "test-id": "nextYearButton", onClick: () => this.selectYear(this.year + 1) }, h("q2-icon", { key: '5931c20eac7a2268c6b945b336f44e143e9fe484', type: "arrow-right" }))))), h("div", { key: '9e18ae0e86a741201eb2a8c6ff04b9007899cbae', class: "month-list", onClick: this.onMonthSelection }, this.months.map((month, index) => (h("div", { class: "month" }, h("span", { role: "button", class: "month-button", "data-index": index, "aria-label": month.label, tabindex: index === this.focusedIndex ? 0 : -1 }, month.abbr))))), this.today && (h("div", { key: '8dfee8bcf4ee9b4137c9c8644be7f38f5794bf4d', class: "today-label" }, loc('tecton.element.calendar.today'), ": ", this.today))));
152
152
  }
153
153
  get hostElement() { return this; }
154
154
  static get style() { return q2MonthPickerCss; }
@@ -92,7 +92,7 @@ const Q2MutationObserver$1 = /*@__PURE__*/ proxyCustomElement(class Q2MutationOb
92
92
  // #endregion
93
93
  // #region Render Methods
94
94
  render() {
95
- return h("slot", { key: 'b383eb3c2f5d2983f3658f776bd52736b4b6f9a5', onSlotchange: this.handleSlotChange });
95
+ return h("slot", { key: 'a7a47f38488edeb403658d1ad7464e79ef254709', onSlotchange: this.handleSlotChange });
96
96
  }
97
97
  get hostElement() { return this; }
98
98
  static get watchers() { return {
@@ -56,7 +56,7 @@ const Q2Optgroup = /*@__PURE__*/ proxyCustomElement(class Q2Optgroup extends HTM
56
56
  // #endregion
57
57
  // #region Render Methods
58
58
  render() {
59
- return (h("div", { key: '03ea146fc88b43ccd10050cffb20c95bcc64c565', class: "q2-optgroup-container", hidden: this.hidden, "aria-labelledby": this.headerId, role: "group" }, h("div", { key: '4738ff37a955e7d742a634ce7f043bdfc9f9720d', class: "q2-optgroup-header", id: this.headerId }, (this.label && loc(this.label)) || ''), h("div", { key: '5f387ec9d47194ee11415a3c91f01ea5b2107822', class: "q2-optgroup-options" }, h("slot", { key: '765abe9037d131fa65f5c4ace78de0282c2e17a1' }))));
59
+ return (h("div", { key: '1193ca6f02dab8603a148059edfd6b3f01e55556', class: "q2-optgroup-container", hidden: this.hidden, "aria-labelledby": this.headerId, role: "group" }, h("div", { key: '5731f04b1976e5e1f96ab37f577ead3889b80e8c', class: "q2-optgroup-header", id: this.headerId }, (this.label && loc(this.label)) || ''), h("div", { key: 'a52522a81176e91855514da0f051058c740ee4b6', class: "q2-optgroup-options" }, h("slot", { key: '8b0c0e1f18f3b8ca76cd3c00e28e5cef73457ca6' }))));
60
60
  }
61
61
  get hostElement() { return this; }
62
62
  static get watchers() { return {
@@ -582,7 +582,7 @@ const Q2OptionList = /*@__PURE__*/ proxyCustomElement(class Q2OptionList extends
582
582
  // #endregion
583
583
  // #region Render Methods
584
584
  render() {
585
- return (h(Host, { key: '05e3dbeb1ffe4910f7c3c922311f51e0e34a4771' }, h("div", { key: '152c7430207325f6d6bcb6b5253c61528f9338eb', class: "content", ref: el => (this.contentElement = el), onFocusout: this.focusoutHandler }, h("div", { key: 'd94b9d6fe8fe5221b44c59424351cd2fa4e2139b', class: "options", "aria-label": loc('tecton.element.optionList.label', [this.label]), "aria-multiselectable": this.type === 'menu' ? undefined : `${!!this.multiple}`, role: this.type || 'listbox', onKeyDown: this.internalKeydownHandler, onClick: this.clickHandler }, h("slot", { key: 'c655e10092d73bdeb985ee08776024c5dbd6fc96' })))));
585
+ return (h(Host, { key: '99c8a52ef8c6adbd138bdd4ff40340fabe670903' }, h("div", { key: '632777fab876b3ef838e8658de35df410fc1d3b7', class: "content", ref: el => (this.contentElement = el), onFocusout: this.focusoutHandler }, h("div", { key: '97079fcb63d10e57ae3e3f1fcbc0a4c307dcda3c', class: "options", "aria-label": loc('tecton.element.optionList.label', [this.label]), "aria-multiselectable": this.type === 'menu' ? undefined : `${!!this.multiple}`, role: this.type || 'listbox', onKeyDown: this.internalKeydownHandler, onClick: this.clickHandler }, h("slot", { key: '07f07e638defb8427f320db9bf3cfb87f6711f9e' })))));
586
586
  }
587
587
  get hostElement() { return this; }
588
588
  static get watchers() { return {
@@ -317,7 +317,7 @@ const Q2Pagination$1 = /*@__PURE__*/ proxyCustomElement(class Q2Pagination exten
317
317
  total,
318
318
  });
319
319
  }
320
- return (h("nav", { key: 'f99b44d19603ae3981ef849748ef6163fc45919b', class: this.containerClasses.join(' '), ref: el => (this.containerElement = el), "aria-label": loc('tecton.element.pagination.title') }, h("div", { key: 'd1643de16462d1f16fc252eeed2e568e246648a1', class: "description", "test-id": "description" }, pagesOnly
320
+ return (h("nav", { key: '642369130b2d57d4e6a89927608636a4da87f11d', class: this.containerClasses.join(' '), ref: el => (this.containerElement = el), "aria-label": loc('tecton.element.pagination.title') }, h("div", { key: 'e988b3374cec5bb1a73dfbcc705899fb3a3474d6', class: "description", "test-id": "description" }, pagesOnly
321
321
  ? loc('tecton.element.pagination.pages', {
322
322
  current: page,
323
323
  total: totalPages,
@@ -326,10 +326,10 @@ const Q2Pagination$1 = /*@__PURE__*/ proxyCustomElement(class Q2Pagination exten
326
326
  range: currentRange,
327
327
  recordType: recordType.toLowerCase(),
328
328
  total: total.toLocaleString(),
329
- })), h("div", { key: '6ffec6ee2128172163a381f76d9e06fe82c7316b', class: "controls" }, h("div", { key: 'decc2ca51ad2365a07ffd112c1d1726e174b5d0c', class: "btn-group" }, h("q2-btn", { key: '7b85578c7595c4285c995c5e5359f6c441bdda51', ref: el => (this.firstPageBtn = el), label: loc('tecton.element.pagination.goToFirstPage'), disabled: disabled || onFirstPage, hidden: isFullViewHidden, onTctClick: () => this.handlePageChange(1), "test-id": "firstPageBtn", "hide-label": true }, h("q2-icon", { key: '550559c6d68876121fb3aaa87414e4adb11f4429', type: "chevron-double-left" })), h("q2-btn", { key: '6bf47805cabef90404a66317fc4bff10921818bd', ref: el => (this.prevPageBtn = el), label: prevButtonLabel, disabled: disabled || onFirstPage, onTctClick: () => this.handlePageChange(page - 1), "test-id": "prevPageBtn", "hide-label": true }, h("q2-icon", { key: 'cd7e55771f9de549a7729236df927274745825b9', type: "chevron-left" }))), h("div", { key: '730078a28d7d555bfed57381b972e54c8059a556', class: "input-display", hidden: isFullViewHidden }, h("span", { key: '35b93b8034569d72bf0670d73f7ce1ec0fef826e', "aria-hidden": "true" }, loc('tecton.element.pagination.page')), h("div", { key: 'd28c27c41044573a0fb1adf2b8a89ef582c5aa98', class: "input-wrapper", onClick: () => this.inputField.dispatchEvent(new FocusEvent('focus')) }, h("q2-input", { key: '28bf16274c57944a7a7132dd29a2e606d9f6c108', ref: el => (this.inputField = el), type: "number", value: `${page}`, min: 1, max: this.totalPages, hideLabel: true, optional: true, label: `${loc('tecton.element.pagination.page')} (${loc('tecton.element.pagination.ofPages', [totalPages.toLocaleString()])})`, onChange: event => event.stopImmediatePropagation(), onTctChange: event => {
329
+ })), h("div", { key: '8ac5316082ab9fcc03fd6c605e56e31124f5d5dc', class: "controls" }, h("div", { key: 'c7e99c77f10d0d587d31af19b3bd39ba2d64aeb7', class: "btn-group" }, h("q2-btn", { key: 'ba7cc1e9b1eee9d0db75e7f653c74974e06435a6', ref: el => (this.firstPageBtn = el), label: loc('tecton.element.pagination.goToFirstPage'), disabled: disabled || onFirstPage, hidden: isFullViewHidden, onTctClick: () => this.handlePageChange(1), "test-id": "firstPageBtn", "hide-label": true }, h("q2-icon", { key: '90b82dd3b935af151d517c997086e5779e51bd3c', type: "chevron-double-left" })), h("q2-btn", { key: '179b59d1c5cebff1897d5e0a3e825e969da90719', ref: el => (this.prevPageBtn = el), label: prevButtonLabel, disabled: disabled || onFirstPage, onTctClick: () => this.handlePageChange(page - 1), "test-id": "prevPageBtn", "hide-label": true }, h("q2-icon", { key: 'b23b78e56fc5df453036c07c055f2bc7bf10da11', type: "chevron-left" }))), h("div", { key: '5ac4941af9479fe7c2644cfe56fb1bf3f4e2c968', class: "input-display", hidden: isFullViewHidden }, h("span", { key: 'f748874515ec184a25bc2f10f16f1031b4ed5583', "aria-hidden": "true" }, loc('tecton.element.pagination.page')), h("div", { key: '2e870838a5ca57ccfd80f648f8eaf6f895c950be', class: "input-wrapper", onClick: () => this.inputField.dispatchEvent(new FocusEvent('focus')) }, h("q2-input", { key: '3c765b872520ae12cf6d86789a5dfb56fe140d97', ref: el => (this.inputField = el), type: "number", value: `${page}`, min: 1, max: this.totalPages, hideLabel: true, optional: true, label: `${loc('tecton.element.pagination.page')} (${loc('tecton.element.pagination.ofPages', [totalPages.toLocaleString()])})`, onChange: event => event.stopImmediatePropagation(), onTctChange: event => {
330
330
  event.stopPropagation();
331
331
  this.handlePageChange(event.detail.value);
332
- }, "test-id": "pageInput", current: "page", disabled: disabled })), h("span", { key: '5fc845812367d39bf91826657da31f39436fc670', "aria-hidden": "true" }, loc('tecton.element.pagination.ofPages', [totalPages.toLocaleString()]))), h("div", { key: '73183db09f66cad393b33571260579720f2e8c12', class: "btn-group" }, h("q2-btn", { key: 'c3daf5fd49273bede94ce2a9994309d282f1bdbf', ref: el => (this.nextPageBtn = el), label: nextButtonLabel, disabled: disabled || onLastPage, onTctClick: () => this.handlePageChange(page + 1), "test-id": "nextPageBtn", "hide-label": true }, h("q2-icon", { key: '427474ab8f77a0e314a687bb00d199858234f30d', type: "chevron-right" })), h("q2-btn", { key: '607732d95674f7620423817e7394ec4e88ac6e9b', ref: el => (this.lastPageBtn = el), label: "tecton.element.pagination.goToLastPage", disabled: disabled || onLastPage, hidden: isFullViewHidden, onTctClick: () => this.handlePageChange(totalPages), "test-id": "lastPageBtn", "hide-label": true }, h("q2-icon", { key: 'ff871b93e2f4932eddde86761f126fb6937b43fb', type: "chevron-double-right" })))), h("div", { key: '506a9fd9aa1790d1a2efb7b8a744a8fc1d76a409', class: "per-page", hidden: isFullViewHidden || !((_a = this.perPageIncrements) === null || _a === void 0 ? void 0 : _a.length) }, showPerPageSelect && this.renderPerPage())));
332
+ }, "test-id": "pageInput", current: "page", disabled: disabled })), h("span", { key: '1fad0a391c7b5b2bac9439b7116674d43d205a95', "aria-hidden": "true" }, loc('tecton.element.pagination.ofPages', [totalPages.toLocaleString()]))), h("div", { key: '52dc5be6a7deae84418c2cfbf108b68451c3db5b', class: "btn-group" }, h("q2-btn", { key: 'b1aa2468c227ad4f251736eee6596a0525f620dd', ref: el => (this.nextPageBtn = el), label: nextButtonLabel, disabled: disabled || onLastPage, onTctClick: () => this.handlePageChange(page + 1), "test-id": "nextPageBtn", "hide-label": true }, h("q2-icon", { key: '689bc3f2f90724c53ff67d9724d17cc303af716c', type: "chevron-right" })), h("q2-btn", { key: 'bb1bb9cbbbc58454e6f811fcaa5359d561d79042', ref: el => (this.lastPageBtn = el), label: "tecton.element.pagination.goToLastPage", disabled: disabled || onLastPage, hidden: isFullViewHidden, onTctClick: () => this.handlePageChange(totalPages), "test-id": "lastPageBtn", "hide-label": true }, h("q2-icon", { key: 'd271e5fd48c58f95f0b8d2d45af6f48c335038e8', type: "chevron-double-right" })))), h("div", { key: 'cc2ac1c470e2034b242079c44ecf4435cb42548e', class: "per-page", hidden: isFullViewHidden || !((_a = this.perPageIncrements) === null || _a === void 0 ? void 0 : _a.length) }, showPerPageSelect && this.renderPerPage())));
333
333
  }
334
334
  get hostElement() { return this; }
335
335
  static get watchers() { return {
@@ -377,7 +377,7 @@ const Q2Pill$1 = /*@__PURE__*/ proxyCustomElement(class Q2Pill extends HTMLEleme
377
377
  wrapperClassNames.push('has-icon');
378
378
  if (optionCount)
379
379
  wrapperClassNames.push('has-options');
380
- return (h("click-elsewhere", { key: '33f8d76b96617663d26ec896e9d389fcaa18e6e1', onChange: this.onClickElsewhere }, h("div", { key: '96e54e580f5f313a5f50049fe4a795fc444c1de5', class: wrapperClassNames.join(' ') }, h("div", { key: 'a5482940be97c882b54e4674f96f88344553e274', class: "btn-height-wrapper", ref: el => (this.primaryBtnWrapper = el), onClick: this.handleWrapperClick, tabIndex: -1 }, h("button", { key: 'd19714c018c3ba17433614432fc6225f84c2dbba', class: "btn-primary", "test-id": "btn-control", type: "button", role: (optionCount && 'combobox') || undefined, ref: el => (this.primaryBtn = el), onClick: this.handleClick, onKeyDown: this.handleKeydown, onFocusout: this.handleFocusOut, disabled: this.disabled, "aria-roledescription": !optionCount && 'filter', "aria-controls": (optionCount && 'option-list') || undefined, "aria-expanded": (optionCount && `${!!open}`) || undefined, "aria-label": `${this.buttonContent}${!optionCount && active ? ` ${loc('tecton.element.pill.active')}` : ''}`, "aria-describedby": (optionCount && 'option-description') || undefined }, this.truncatedButtonContent)), this.renderIcon(), !!optionCount && this.renderHiddenElement()), this.optionCount > 0 && (h("q2-popover", { key: 'a321b1db273a1d401e932f35f05245e3d3199b88', ref: el => (this.popoverElement = el), controlElement: this.primaryBtn, open: this.open, "max-height": this.popoverMaxHeight, minHeight: this.popoverMinHeight, direction: this.popoverDirection, align: this.popoverAlignment, onFocusout: this.handleFocusOut }, h("div", { key: 'e9fc516f6855ae2c9cc67dd46c041e736c4d552e', class: "popover-content" }, h("div", { key: '9cc43dbc66b7eb40f05d89278684a24f7f2b061f', ref: el => (this.popoverTopContainer = el), class: "popover-top-container", tabindex: "-1", hidden: !this.hasPopoverTop, onKeyDown: this.handleKeydown }, h("slot", { key: 'b3d2ff22c4fc3293ebfa70db9f42c2940e149825', name: "popover-top" })), h("q2-option-list", { key: 'ebb64d5e7086c49c84b8da96669b5ad9eaa9b631', type: "listbox", ref: el => (this.optionList = el), id: "option-list", onChange: this.handleChange, multiple: this.multiple, selectedOptions: this.selectedOptions, onReady: () => this.updateSelectedOptionElements(), onPopoverState: this.onPopoverState, label: loc('tecton.element.optionList.label', [this.optionListLabel]) }, h("slot", { key: 'a09461650fc5b4cd38cdc316eb546f877c0ee9d6' })), h("div", { key: 'f146e3181d0b35dbe28f46b9ab4d0aaf9691f9ef', ref: el => (this.popoverBottomContainer = el), class: "popover-bottom-container", tabindex: "-1", hidden: !this.hasPopoverBottom, onKeyDown: this.handleKeydown }, h("slot", { key: '515c40d83c6de0758426ca430fcfbc35c5266cc3', name: "popover-bottom" })))))));
380
+ return (h("click-elsewhere", { key: 'e967de8b2086ebf86f51cc927c3430c07ad37636', onChange: this.onClickElsewhere }, h("div", { key: '38c871229f1f80d49b003d5c6f7895c335a9eed8', class: wrapperClassNames.join(' ') }, h("div", { key: '8dd9a60999c49de096f8f8f67adccffba0f9a80a', class: "btn-height-wrapper", ref: el => (this.primaryBtnWrapper = el), onClick: this.handleWrapperClick, tabIndex: -1 }, h("button", { key: '1d485d62c6acfaee927e1fa1aa0bc9401c7f2c98', class: "btn-primary", "test-id": "btn-control", type: "button", role: (optionCount && 'combobox') || undefined, ref: el => (this.primaryBtn = el), onClick: this.handleClick, onKeyDown: this.handleKeydown, onFocusout: this.handleFocusOut, disabled: this.disabled, "aria-roledescription": !optionCount && 'filter', "aria-controls": (optionCount && 'option-list') || undefined, "aria-expanded": (optionCount && `${!!open}`) || undefined, "aria-label": `${this.buttonContent}${!optionCount && active ? ` ${loc('tecton.element.pill.active')}` : ''}`, "aria-describedby": (optionCount && 'option-description') || undefined }, this.truncatedButtonContent)), this.renderIcon(), !!optionCount && this.renderHiddenElement()), this.optionCount > 0 && (h("q2-popover", { key: '05ca8c8195186b220364ee67198d6210bbe34455', ref: el => (this.popoverElement = el), controlElement: this.primaryBtn, open: this.open, "max-height": this.popoverMaxHeight, minHeight: this.popoverMinHeight, direction: this.popoverDirection, align: this.popoverAlignment, onFocusout: this.handleFocusOut }, h("div", { key: 'e1eb81bfc0489fd9450975eee632fb59830cce54', class: "popover-content" }, h("div", { key: 'a101a2d7f88fdb18f2a859737f1bca96742bad7e', ref: el => (this.popoverTopContainer = el), class: "popover-top-container", tabindex: "-1", hidden: !this.hasPopoverTop, onKeyDown: this.handleKeydown }, h("slot", { key: '752c27b869d1dd91f5d369e7f1675554e48a4554', name: "popover-top" })), h("q2-option-list", { key: '2f70d1533c8733721326b02a47531a7feb47ab7e', type: "listbox", ref: el => (this.optionList = el), id: "option-list", onChange: this.handleChange, multiple: this.multiple, selectedOptions: this.selectedOptions, onReady: () => this.updateSelectedOptionElements(), onPopoverState: this.onPopoverState, label: loc('tecton.element.optionList.label', [this.optionListLabel]) }, h("slot", { key: '5ffddd45ce88c535a5bb4481f34a74690cb8d46f' })), h("div", { key: '1c5ae3722ea7caace731239ac0d91d4fcbe7eb8b', ref: el => (this.popoverBottomContainer = el), class: "popover-bottom-container", tabindex: "-1", hidden: !this.hasPopoverBottom, onKeyDown: this.handleKeydown }, h("slot", { key: 'afa0d457a65303d7a4e50fa9e633e9fa609922e8', name: "popover-bottom" })))))));
381
381
  }
382
382
  get hostElement() { return this; }
383
383
  static get watchers() { return {
@@ -16,6 +16,7 @@ const Q2Popover = /*@__PURE__*/ proxyCustomElement(class Q2Popover extends HTMLE
16
16
  */
17
17
  this.displayBuffer = 10;
18
18
  this.orientationChanged = false;
19
+ this.pendingAnimationResolve = null;
19
20
  // #endregion
20
21
  // #region State Properties
21
22
  this.animationState = 'idle';
@@ -43,6 +44,8 @@ const Q2Popover = /*@__PURE__*/ proxyCustomElement(class Q2Popover extends HTMLE
43
44
  };
44
45
  this.setAbsoluteCSSProperties = async () => {
45
46
  const { controlElement, containerElement, currentDirection, align } = this;
47
+ if (!containerElement)
48
+ return;
46
49
  if (align === 'right') {
47
50
  containerElement.style.setProperty('--comp-pop-right', '0');
48
51
  containerElement.style.setProperty('--comp-pop-left', 'unset');
@@ -63,11 +66,14 @@ const Q2Popover = /*@__PURE__*/ proxyCustomElement(class Q2Popover extends HTMLE
63
66
  }
64
67
  // Wait for one paint to prevent layout thrashing
65
68
  await waitForNextPaint();
66
- containerElement.style.setProperty('--comp-pop-opacity', '1');
69
+ if (this.containerElement)
70
+ containerElement.style.setProperty('--comp-pop-opacity', '1');
67
71
  };
68
72
  this.setPopoverAPICSSProperties = async () => {
69
73
  var _a, _b, _c;
70
74
  const { controlElement, containerElement, currentDirection, isModule, align } = this;
75
+ if (!containerElement)
76
+ return;
71
77
  const { top: controlTop, bottom: controlBottom, left: controlLeft, right: controlRight, } = (_b = (_a = controlElement === null || controlElement === void 0 ? void 0 : controlElement.getBoundingClientRect) === null || _a === void 0 ? void 0 : _a.call(controlElement)) !== null && _b !== void 0 ? _b : {
72
78
  top: 0,
73
79
  bottom: 0,
@@ -105,7 +111,8 @@ const Q2Popover = /*@__PURE__*/ proxyCustomElement(class Q2Popover extends HTMLE
105
111
  }
106
112
  // Wait for one paint to prevent layout thrashing
107
113
  await waitForNextPaint();
108
- containerElement.style.setProperty('--comp-pop-opacity', '1');
114
+ if (this.containerElement)
115
+ containerElement.style.setProperty('--comp-pop-opacity', '1');
109
116
  };
110
117
  this.viewPortChanged = () => {
111
118
  if (!this.open)
@@ -120,8 +127,13 @@ const Q2Popover = /*@__PURE__*/ proxyCustomElement(class Q2Popover extends HTMLE
120
127
  // #endregion
121
128
  // #region Component Lifecycle Events
122
129
  disconnectedCallback() {
130
+ var _a;
123
131
  this.removeViewportListeners();
124
- this.containerElement.removeEventListener('toggle', this.handlePopoverToggleEvent);
132
+ if (this.pendingAnimationResolve) {
133
+ this.pendingAnimationResolve();
134
+ this.pendingAnimationResolve = null;
135
+ }
136
+ (_a = this.containerElement) === null || _a === void 0 ? void 0 : _a.removeEventListener('toggle', this.handlePopoverToggleEvent);
125
137
  this.containerElement = null;
126
138
  this.contentElement = null;
127
139
  this.controlElement = null;
@@ -133,9 +145,10 @@ const Q2Popover = /*@__PURE__*/ proxyCustomElement(class Q2Popover extends HTMLE
133
145
  }
134
146
  }
135
147
  componentDidLoad() {
148
+ var _a;
136
149
  this.handleMinHeight();
137
150
  if (this.supportsPopoverAPI)
138
- this.containerElement.addEventListener('toggle', this.handlePopoverToggleEvent);
151
+ (_a = this.containerElement) === null || _a === void 0 ? void 0 : _a.addEventListener('toggle', this.handlePopoverToggleEvent);
139
152
  if (this.open)
140
153
  this.determinePopDirection();
141
154
  }
@@ -151,7 +164,8 @@ const Q2Popover = /*@__PURE__*/ proxyCustomElement(class Q2Popover extends HTMLE
151
164
  // #endregion
152
165
  // #region Public Methods API
153
166
  async scrollContainerTo(options) {
154
- this.containerElement.scrollTo(options);
167
+ var _a;
168
+ (_a = this.containerElement) === null || _a === void 0 ? void 0 : _a.scrollTo(options);
155
169
  }
156
170
  async toggle() {
157
171
  this.open = !this.open;
@@ -174,17 +188,25 @@ const Q2Popover = /*@__PURE__*/ proxyCustomElement(class Q2Popover extends HTMLE
174
188
  // Wait for close animation to complete
175
189
  if (this.animated) {
176
190
  await new Promise(resolve => {
191
+ var _a;
177
192
  const handleAnimationEnd = () => {
178
- this.containerElement.removeEventListener('animationend', handleAnimationEnd);
193
+ var _a;
194
+ this.pendingAnimationResolve = null;
195
+ (_a = this.containerElement) === null || _a === void 0 ? void 0 : _a.removeEventListener('animationend', handleAnimationEnd);
179
196
  resolve();
180
197
  };
181
- this.containerElement.addEventListener('animationend', handleAnimationEnd);
198
+ this.pendingAnimationResolve = handleAnimationEnd;
199
+ (_a = this.containerElement) === null || _a === void 0 ? void 0 : _a.addEventListener('animationend', handleAnimationEnd);
200
+ if (!this.containerElement)
201
+ resolve();
182
202
  });
183
203
  }
184
204
  else {
185
205
  // No animation, proceed immediately
186
206
  await waitForNextPaint();
187
207
  }
208
+ if (!this.containerElement)
209
+ return;
188
210
  this.currentDirection = undefined;
189
211
  this.animationState = 'idle';
190
212
  if (this.mode === 'legacy' || !this.supportsPopoverAPI) {
@@ -233,6 +255,8 @@ const Q2Popover = /*@__PURE__*/ proxyCustomElement(class Q2Popover extends HTMLE
233
255
  window.addEventListener('orientationchange', this.viewPortOrientationChanged);
234
256
  }
235
257
  clearCSSProperties() {
258
+ if (!this.containerElement)
259
+ return;
236
260
  this.containerElement.style.removeProperty('--comp-pop-max-height');
237
261
  this.containerElement.style.removeProperty('--comp-pop-top');
238
262
  this.containerElement.style.removeProperty('--comp-pop-bottom');
@@ -247,6 +271,8 @@ const Q2Popover = /*@__PURE__*/ proxyCustomElement(class Q2Popover extends HTMLE
247
271
  if (containerElement)
248
272
  containerElement.style.maxHeight = null;
249
273
  await waitForNextPaint();
274
+ if (!this.containerElement)
275
+ return;
250
276
  const { isModule } = this;
251
277
  const { top: controlTop, bottom: controlBottom } = (_b = (_a = controlElement === null || controlElement === void 0 ? void 0 : controlElement.getBoundingClientRect) === null || _a === void 0 ? void 0 : _a.call(controlElement)) !== null && _b !== void 0 ? _b : {
252
278
  top: 0,
@@ -279,13 +305,13 @@ const Q2Popover = /*@__PURE__*/ proxyCustomElement(class Q2Popover extends HTMLE
279
305
  }
280
306
  const directionWithMostSpace = maxSpaceAbove > maxSpaceBelow ? 'up' : 'down';
281
307
  // We do not want to update the max height once the popover is open unless the page orientation shifts (resize or mobile use cases)
282
- const shouldUpdateMaxHeight = !containerElement.style.getPropertyValue('--comp-pop-max-height') || this.orientationChanged;
308
+ const shouldUpdateMaxHeight = !(containerElement === null || containerElement === void 0 ? void 0 : containerElement.style.getPropertyValue('--comp-pop-max-height')) || this.orientationChanged;
283
309
  // we do not want to constantly update the max-height after an orientation change, so we switch this back to false
284
310
  this.orientationChanged = false;
285
311
  const currentOrDetermineDirection = this.currentDirection || providedDirection || directionWithMostSpace;
286
312
  switch (currentOrDetermineDirection) {
287
313
  case 'up':
288
- if (shouldUpdateMaxHeight) {
314
+ if (shouldUpdateMaxHeight && containerElement) {
289
315
  const priorityMaxHeight = this.validatedMaxHeight || maxSpaceAbove;
290
316
  const maxHeight = Math.min(maxSpaceAbove, priorityMaxHeight);
291
317
  containerElement.style.setProperty('--comp-pop-max-height', `${maxHeight}px`);
@@ -293,7 +319,7 @@ const Q2Popover = /*@__PURE__*/ proxyCustomElement(class Q2Popover extends HTMLE
293
319
  this.setDirectionAndShow('up');
294
320
  break;
295
321
  case 'down':
296
- if (shouldUpdateMaxHeight) {
322
+ if (shouldUpdateMaxHeight && containerElement) {
297
323
  const priorityMaxHeight = this.validatedMaxHeight || maxSpaceBelow;
298
324
  const maxHeight = Math.min(maxSpaceBelow, priorityMaxHeight);
299
325
  containerElement.style.setProperty('--comp-pop-max-height', `${maxHeight}px`);
@@ -311,10 +337,11 @@ const Q2Popover = /*@__PURE__*/ proxyCustomElement(class Q2Popover extends HTMLE
311
337
  window.removeEventListener('orientationchange', this.viewPortOrientationChanged);
312
338
  }
313
339
  setDirectionAndShow(direction) {
340
+ var _a;
314
341
  // Due to some runtime inconsistency across devices/browsers we need to add one more check here because the
315
342
  // popover can be closed between the time the popover is opened and the time the direction is determined
316
343
  const isOpen = this.open;
317
- if (!isOpen)
344
+ if (!isOpen || !this.containerElement)
318
345
  return;
319
346
  this.currentDirection = direction;
320
347
  if (this.mode === 'legacy' || !this.supportsPopoverAPI) {
@@ -323,7 +350,7 @@ const Q2Popover = /*@__PURE__*/ proxyCustomElement(class Q2Popover extends HTMLE
323
350
  }
324
351
  else {
325
352
  this.setPopoverAPICSSProperties();
326
- this.containerElement.showPopover();
353
+ (_a = this.containerElement) === null || _a === void 0 ? void 0 : _a.showPopover();
327
354
  }
328
355
  }
329
356
  // #endregion
@@ -342,7 +369,7 @@ const Q2Popover = /*@__PURE__*/ proxyCustomElement(class Q2Popover extends HTMLE
342
369
  containerClasses.push('animating-open');
343
370
  if (this.animated && this.animationState === 'closing')
344
371
  containerClasses.push('animating-close');
345
- return (h("div", { key: 'b5166478bf50c313679ce71b381e6fe305e03446', ref: el => (this.containerElement = el), class: containerClasses.join(' '), "test-id": "outerContainer", tabIndex: -1, popover: "manual" }, h("div", { key: '9e939ece2775d98418f726066c9e7b1e7dcb7fde', ref: el => (this.contentElement = el), class: "content" }, h("slot", { key: 'dc16dc214cf71f050e49057f6f35271bb141b692' }))));
372
+ return (h("div", { key: '779d18b2765abec3eff0f19ca297b01356a06a7d', ref: el => (this.containerElement = el), class: containerClasses.join(' '), "test-id": "outerContainer", tabIndex: -1, popover: "manual" }, h("div", { key: '47eb4c1420bbc63f821333c03804c1843363f946', ref: el => (this.contentElement = el), class: "content" }, h("slot", { key: '8554a334fd61f07cf712e2bdbe797f7835878469' }))));
346
373
  }
347
374
  get hostElement() { return this; }
348
375
  static get watchers() { return {
@@ -1 +1 @@
1
- {"file":"q2-popover2.js","mappings":";;;;AAAA,MAAM,YAAY,GAAG,gzIAAgzI;;MCkDxzI,SAAS,iBAAAA,kBAAA,CAAA,MAAA,SAAA,SAAA,WAAA,CAAA;AADtB,IAAA,WAAA,GAAA;;;;;;AAMI;;AAEG;AACH,Q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A,CAAA,KAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EACI,GAAG,EAAE,EAAE,KAAK,IAAI,CAAC,gBAAgB,GAAG,EAAE,CAAC,EACvC,KAAK,EAAE,gBAAgB,CAAC,IAAI,CAAC,GAAG,CAAC,EACzB,SAAA,EAAA,gBAAgB,EACxB,QAAQ,EAAE,EAAE,EACZ,OAAO,EAAC,QAAQ,EAAA,EAEhB,CAAA,CAAA,KAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EACI,GAAG,EAAE,EAAE,KAAK,IAAI,CAAC,cAAc,GAAG,EAAE,CAAC,EACrC,KAAK,EAAC,SAAS,EAAA,EAEf,CAAQ,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,CAAA,CACN,CACJ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["__stencil_proxyCustomElement"],"sources":["src/components/q2-popover/q2-popover.scss?tag=q2-popover&encapsulation=shadow","src/components/q2-popover/q2-popover.tsx"],"sourcesContent":["@import '../../styles/host.scss';\n@import '../../styles/functions';\n\n.legacy {\n &.container {\n display: none;\n }\n\n &.show {\n display: block;\n z-index: var-list(--tct-popover-z-index, 50);\n }\n}\n\n@keyframes popoverOpen {\n from {\n opacity: 0;\n transform: scale(0.95);\n }\n to {\n opacity: 1;\n transform: scale(1);\n }\n}\n\n@keyframes popoverClose {\n from {\n opacity: 1;\n transform: scale(1);\n }\n to {\n opacity: 0;\n transform: scale(0.95);\n }\n}\n\n:popover-open,\n.show {\n position: absolute;\n margin: 0;\n padding: var-list(--tct-popover-padding, 0);\n overflow: auto;\n background: var-list(--tct-popover-background, --app-white, #ffffff);\n backdrop-filter: var-list(--tct-popover-backdrop-filter, none);\n color: var-list(--tct-popover-font-color, --t-text, #4d4d4d);\n min-width: var-list(--tct-popover-min-width, 135px);\n margin-block: var-list(--tct-popover-margin-block, 0);\n box-shadow: var-list(\n --tct-popover-box-shadow,\n --app-shadow-3,\n unquote('0px 0px 2px rgba(0, 0, 0, 0.12), 0px 2px 4px rgba(0, 0, 0, 0.14)')\n );\n border-width: var-list(--tct-popover-border-width, 0);\n border-style: solid;\n border-color: var-list(--tct-popover-border-color, transparent);\n border-radius: var-list(--tct-popover-border-radius, 0);\n // the --comp variables are set via JS\n max-height: var(--comp-pop-max-height);\n left: var(--comp-pop-left);\n opacity: var(--comp-pop-opacity, 0);\n\n &.animating-open {\n animation-name: popoverOpen;\n animation-duration: var-list(--tct-popover-open-animation-duration, --t-tween-time-in-1, 150ms);\n animation-timing-function: var-list(--tct-popover-open-animation-timing-function, ease-out);\n animation-fill-mode: var-list(--tct-popover-open-animation-fill-mode, forwards);\n }\n\n &.animating-close {\n animation-name: popoverClose;\n animation-duration: var-list(--tct-popover-close-animation-duration, --t-tween-time-out-1, 100ms);\n animation-timing-function: var-list(--tct-popover-close-animation-timing-function, ease-in);\n animation-fill-mode: var-list(--tct-popover-close-animation-fill-mode, forwards);\n }\n\n // Respect user's motion preferences\n @media (prefers-reduced-motion: reduce) {\n &.animating-open,\n &.animating-close {\n animation: none;\n }\n }\n\n &.block {\n right: unset;\n width: var(--comp-pop-width);\n min-width: var-list(--tct-popover-min-width, unset);\n }\n\n &.left {\n left: var(--comp-pop-left);\n right: unset;\n }\n\n &.right {\n right: var(--comp-pop-right);\n left: unset;\n }\n\n &.down {\n top: var-list(--tct-popover-top, --comp-pop-top);\n bottom: unset;\n }\n\n &.up {\n top: unset;\n bottom: var(--comp-pop-bottom);\n }\n\n // Desktop: corner-based transform origin\n &.down.left:not(.mobile) {\n transform-origin: top left;\n }\n\n &.down.right:not(.mobile) {\n transform-origin: top right;\n }\n\n &.up.left:not(.mobile) {\n transform-origin: bottom left;\n }\n\n &.up.right:not(.mobile) {\n transform-origin: bottom right;\n }\n\n // Mobile: center-based transform origin\n &.mobile.down {\n transform-origin: center top;\n }\n\n &.mobile.up {\n transform-origin: center bottom;\n }\n\n @include tiny-scrollbar();\n}\n\nclick-elsewhere {\n position: relative;\n display: block;\n}\n","import {\n Component,\n Prop,\n h,\n ComponentInterface,\n Element,\n Watch,\n Method,\n Listen,\n EventEmitter,\n Event,\n State,\n} from '@stencil/core';\nimport { handleDeprecationWarning, waitForNextPaint, isMobile, isInScrollableContainer } from '../../utils';\nimport mirrorEmit from '@/utils/mirror-emit';\n\n/**\n * ***********\n * * WARNING *\n * ***********\n * Touching this file obligates you to manually test thoroughly, because Puppeteer can't capture every edgecase.\n *\n * Each of the following Scenarios must be tested on each Device, in each Environment.\n *\n * Scenarios:\n * - Q2 Select searchable\n * - Q2 Select non-searchable\n *\n * Orientations:\n * - Portrait\n * - Landscape\n *\n * Devices:\n * - iOS Safari\n * - Android Chrome\n * - MacOS Safari\n * - Chrome\n * - Firefox\n *\n * Environments:\n * - Standard (Outside of Iframe)\n * - SDK Extension (Inside of Iframe)\n */\n\n/**\n * @name Popover\n * @category Display\n * @summary Use for positioning floating content relative to a trigger element.\n */\n@Component({ tag: 'q2-popover', shadow: true, styleUrl: 'q2-popover.scss' })\nexport class Q2Popover implements ComponentInterface {\n // #region Own Properties\n\n containerElement: HTMLDivElement;\n contentElement: HTMLDivElement;\n /**\n * The number of pixels to leave between the popover and the edge of the viewport\n */\n displayBuffer = 10;\n orientationChanged: boolean = false;\n\n // #endregion\n // #region Host HTML Element\n\n @Element()\n hostElement: HTMLElement;\n\n // #endregion\n // #region State Properties\n\n @State()\n animationState: 'idle' | 'opening' | 'closing' = 'idle';\n\n @State()\n currentDirection: 'down' | 'up' = undefined;\n\n // remove `show` when we transitiong fully to Popover API and get rid of 'legacy' mode\n @State()\n show: boolean = false;\n\n // #endregion\n // #region Public Property API\n\n /** Aligns the popover to the left or right side of the control element. */\n @Prop({ reflect: true })\n align: 'left' | 'right' = 'left';\n\n /**\n * Controls whether the popover is animated when opening/closing.\n * Default is true (animated). Set to false to disable animations.\n * Animation is also disabled if the user has enabled prefers-reduced-motion.\n */\n @Prop({ reflect: true })\n animated: boolean = true;\n\n /** Indicates the popover will match the width of its parent element. */\n @Prop({ reflect: true })\n block: boolean;\n\n /** The element that controls the popover's behavior. */\n @Prop()\n controlElement: HTMLElement;\n\n /**\n * Force the direction of the popover when it opens.\n * If no value is passed, the component will auto-detect the direction based on available space.\n */\n @Prop({ reflect: true })\n direction: 'up' | 'down';\n\n /**\n * Force the maximum height of the popover. This value will be interpreted as pixels.\n * If no value is passed, or the value exceeds available space, the component will auto-detect the maximum height based on available space.\n */\n @Prop()\n maxHeight: number;\n\n /** @deprecated */\n @Prop()\n minHeight: number;\n\n @Prop()\n mode: 'legacy' = null;\n\n /** Controls whether the popover is open or closed. */\n @Prop({ reflect: true, mutable: true })\n open: boolean;\n\n // #endregion\n // #region Events\n\n /**\n * Emitted when the popover is opened or closed.\n * @deprecated Use 'tctPopoverStateChanged' instead\n */\n @Event()\n popoverStateChanged: EventEmitter<{ open: boolean }>;\n\n /**\n * Emitted when the popover is opened or closed.\n */\n @Event()\n tctPopoverStateChanged: EventEmitter<{ open: boolean }>;\n\n // #endregion\n // #region Component Lifecycle Events\n\n disconnectedCallback() {\n this.removeViewportListeners();\n this.containerElement.removeEventListener('toggle', this.handlePopoverToggleEvent);\n this.containerElement = null;\n this.contentElement = null;\n this.controlElement = null;\n }\n\n componentWillLoad() {\n if (!this.supportsPopoverAPI) {\n console.warn(\n 'The Popover API is not supported in this browser. Please update your browser to the latest version. The component will use legacy mode.'\n );\n this.mode = 'legacy';\n }\n }\n\n componentDidLoad() {\n this.handleMinHeight();\n if (this.supportsPopoverAPI) this.containerElement.addEventListener('toggle', this.handlePopoverToggleEvent);\n if (this.open) this.determinePopDirection();\n }\n\n // #endregion\n // #region Listeners\n\n @Listen('popoverState')\n popoverStateHandler(event: CustomEvent<{ open: boolean }>) {\n const {\n detail: { open },\n } = event;\n if (open === this.open) return;\n\n this.open = open;\n event.stopPropagation();\n }\n\n // #endregion\n // #region Public Methods API\n\n @Method()\n async scrollContainerTo(options: ScrollToOptions) {\n this.containerElement.scrollTo(options);\n }\n\n @Method()\n async toggle() {\n this.open = !this.open;\n }\n\n // #endregion\n // #region Watchers\n\n @Watch('minHeight')\n minHeightProvided() {\n this.handleMinHeight();\n }\n\n @Watch('open')\n async openChanged(open: boolean) {\n mirrorEmit(this, ['popoverStateChanged', 'tctPopoverStateChanged'], { open });\n\n if (open) {\n this.animationState = 'opening';\n this.addViewportListeners();\n this.determinePopDirection();\n } else {\n this.animationState = 'closing';\n this.removeViewportListeners();\n\n // Wait for close animation to complete\n if (this.animated) {\n await new Promise<void>(resolve => {\n const handleAnimationEnd = () => {\n this.containerElement.removeEventListener('animationend', handleAnimationEnd);\n resolve();\n };\n this.containerElement.addEventListener('animationend', handleAnimationEnd);\n });\n } else {\n // No animation, proceed immediately\n await waitForNextPaint();\n }\n\n this.currentDirection = undefined;\n this.animationState = 'idle';\n if (this.mode === 'legacy' || !this.supportsPopoverAPI) {\n this.show = false;\n } else {\n this.containerElement.hidePopover();\n }\n\n await waitForNextPaint();\n this.clearCSSProperties();\n }\n }\n\n // #endregion\n // #region Local Methods\n\n get isModule(): boolean {\n const isIframe = window !== window.top;\n const hasPlatformDimensions = Object.keys(window.Tecton?.platformDimensions ?? {}).length > 0;\n return isIframe && hasPlatformDimensions;\n }\n\n get providedDirection(): 'up' | 'down' | undefined {\n const { direction } = this;\n switch (direction) {\n case 'up':\n case 'down':\n return direction;\n default:\n return undefined;\n }\n }\n\n get supportsPopoverAPI(): boolean {\n return Object.hasOwn(HTMLElement.prototype, 'popover');\n }\n\n get validatedMaxHeight(): number | undefined {\n const { maxHeight } = this;\n return isNaN(maxHeight) ? undefined : maxHeight;\n }\n\n addViewportListeners() {\n window.addEventListener('resize', this.viewPortOrientationChanged);\n visualViewport?.addEventListener('resize', this.viewPortChanged);\n if (isInScrollableContainer(this.hostElement) && !isMobile()) {\n window.addEventListener('scroll', this.viewPortChanged, { passive: true, capture: true });\n }\n screen?.orientation?.addEventListener('orientationchange', this.viewPortOrientationChanged);\n window.addEventListener('orientationchange', this.viewPortOrientationChanged);\n }\n\n clearCSSProperties() {\n this.containerElement.style.removeProperty('--comp-pop-max-height');\n this.containerElement.style.removeProperty('--comp-pop-top');\n this.containerElement.style.removeProperty('--comp-pop-bottom');\n this.containerElement.style.removeProperty('--comp-pop-left');\n this.containerElement.style.removeProperty('--comp-pop-right');\n this.containerElement.style.removeProperty('--comp-pop-width');\n this.containerElement.style.removeProperty('--comp-pop-opacity');\n }\n\n async determinePopDirection() {\n const { containerElement, controlElement, providedDirection, displayBuffer } = this;\n if (containerElement) containerElement.style.maxHeight = null;\n await waitForNextPaint();\n\n const { isModule } = this;\n const { top: controlTop, bottom: controlBottom } = controlElement?.getBoundingClientRect?.() ?? {\n top: 0,\n bottom: 0,\n };\n\n let windowHeight: number;\n let maxSpaceAbove: number;\n let maxSpaceBelow: number;\n const isScrollableIframe = isModule && isInScrollableContainer(this.hostElement);\n if (isModule && !isScrollableIframe) {\n const {\n outletOffset = 0,\n innerHeight = window.innerHeight,\n top: topBarHeight = 0,\n bottom: bottomBarHeight = 0,\n } = window.Tecton?.platformDimensions || {};\n\n const distanceToIframeBottom = window.innerHeight - controlBottom;\n\n // controlElement position visually on the page\n const visualControlTop = outletOffset > 0 ? controlTop : controlTop + outletOffset - topBarHeight;\n const visualControlBottom = outletOffset + controlBottom - topBarHeight;\n\n // visual space around the controlElement\n const viewableSpaceAbove = visualControlTop;\n const viewableSpaceBelow = innerHeight - bottomBarHeight - visualControlBottom;\n\n // calculate space above and below controlElement\n const isIframeShorterThanWindow = distanceToIframeBottom < viewableSpaceBelow;\n maxSpaceAbove = viewableSpaceAbove - displayBuffer;\n maxSpaceBelow = isIframeShorterThanWindow\n ? distanceToIframeBottom - displayBuffer\n : viewableSpaceBelow - displayBuffer;\n } else {\n windowHeight = window.innerHeight;\n maxSpaceAbove = controlTop - displayBuffer;\n maxSpaceBelow = windowHeight - controlBottom - displayBuffer;\n }\n\n const directionWithMostSpace: 'up' | 'down' = maxSpaceAbove > maxSpaceBelow ? 'up' : 'down';\n\n // We do not want to update the max height once the popover is open unless the page orientation shifts (resize or mobile use cases)\n const shouldUpdateMaxHeight =\n !containerElement.style.getPropertyValue('--comp-pop-max-height') || this.orientationChanged;\n // we do not want to constantly update the max-height after an orientation change, so we switch this back to false\n this.orientationChanged = false;\n const currentOrDetermineDirection = this.currentDirection || providedDirection || directionWithMostSpace;\n\n switch (currentOrDetermineDirection) {\n case 'up':\n if (shouldUpdateMaxHeight) {\n const priorityMaxHeight = this.validatedMaxHeight || maxSpaceAbove;\n const maxHeight = Math.min(maxSpaceAbove, priorityMaxHeight);\n containerElement.style.setProperty('--comp-pop-max-height', `${maxHeight}px`);\n }\n this.setDirectionAndShow('up');\n break;\n case 'down':\n if (shouldUpdateMaxHeight) {\n const priorityMaxHeight = this.validatedMaxHeight || maxSpaceBelow;\n const maxHeight = Math.min(maxSpaceBelow, priorityMaxHeight);\n containerElement.style.setProperty('--comp-pop-max-height', `${maxHeight}px`);\n }\n this.setDirectionAndShow('down');\n break;\n default:\n break;\n }\n }\n\n handleMinHeight = () => {\n if (this.minHeight) {\n handleDeprecationWarning(this, 'minHeight', 'prop');\n }\n };\n\n handlePopoverToggleEvent = (event: ToggleEvent) => {\n mirrorEmit(this, ['popoverStateChanged', 'tctPopoverStateChanged'], { open: event.newState === 'open' });\n };\n\n removeViewportListeners() {\n window.removeEventListener('resize', this.viewPortOrientationChanged);\n visualViewport?.removeEventListener('resize', this.viewPortChanged);\n window.removeEventListener('scroll', this.viewPortChanged, { capture: true });\n screen?.orientation?.removeEventListener('orientationchange', this.viewPortOrientationChanged);\n window.removeEventListener('orientationchange', this.viewPortOrientationChanged);\n }\n\n setAbsoluteCSSProperties = async () => {\n const { controlElement, containerElement, currentDirection, align } = this;\n\n if (align === 'right') {\n containerElement.style.setProperty('--comp-pop-right', '0');\n containerElement.style.setProperty('--comp-pop-left', 'unset');\n } else {\n containerElement.style.setProperty('--comp-pop-left', '0');\n containerElement.style.setProperty('--comp-pop-right', 'unset');\n }\n\n if (this.block) {\n containerElement.style.setProperty('--comp-pop-width', '100%');\n }\n\n if (currentDirection === 'up') {\n const controlStyle = getComputedStyle(controlElement);\n const controlSize =\n parseInt(controlStyle.height || '0') +\n parseInt(controlStyle.borderTopWidth || '0') +\n parseInt(controlStyle.borderBottomWidth || '0');\n\n containerElement.style.setProperty('--comp-pop-bottom', `${controlSize}px`);\n }\n\n // Wait for one paint to prevent layout thrashing\n await waitForNextPaint();\n containerElement.style.setProperty('--comp-pop-opacity', '1');\n };\n\n setDirectionAndShow(direction: 'up' | 'down') {\n // Due to some runtime inconsistency across devices/browsers we need to add one more check here because the\n // popover can be closed between the time the popover is opened and the time the direction is determined\n const isOpen = this.open;\n if (!isOpen) return;\n\n this.currentDirection = direction;\n if (this.mode === 'legacy' || !this.supportsPopoverAPI) {\n this.show = true;\n this.setAbsoluteCSSProperties();\n } else {\n this.setPopoverAPICSSProperties();\n this.containerElement.showPopover();\n }\n }\n\n setPopoverAPICSSProperties = async () => {\n const { controlElement, containerElement, currentDirection, isModule, align } = this;\n const {\n top: controlTop,\n bottom: controlBottom,\n left: controlLeft,\n right: controlRight,\n } = controlElement?.getBoundingClientRect?.() ?? {\n top: 0,\n bottom: 0,\n left: 0,\n right: 0,\n };\n\n const popoverLeft: number = controlLeft;\n const popoverRight: number = window?.visualViewport?.width - controlRight;\n\n if (align === 'right') {\n containerElement.style.setProperty('--comp-pop-right', `${popoverRight - window.scrollX}px`);\n containerElement.style.setProperty('--comp-pop-left', 'unset');\n } else {\n containerElement.style.setProperty('--comp-pop-left', `${popoverLeft + window.scrollX}px`);\n containerElement.style.setProperty('--comp-pop-right', 'unset');\n }\n\n if (this.block) containerElement.style.setProperty('--comp-pop-width', `${controlElement?.offsetWidth || 0}px`);\n\n const isScrollableIframe = isModule && isInScrollableContainer(this.hostElement);\n\n if (currentDirection === 'up') {\n if (isModule && !isScrollableIframe) {\n containerElement.style.setProperty('--comp-pop-bottom', `${window.innerHeight - controlTop}px`);\n } else {\n containerElement.style.setProperty(\n '--comp-pop-bottom',\n `${window.innerHeight - controlTop - window.scrollY}px`\n );\n }\n }\n\n if (currentDirection === 'down') {\n if (isModule && !isScrollableIframe) {\n containerElement.style.setProperty('--comp-pop-top', `${controlBottom}px`);\n } else {\n containerElement.style.setProperty('--comp-pop-top', `${controlBottom + window.scrollY}px`);\n }\n }\n\n // Wait for one paint to prevent layout thrashing\n await waitForNextPaint();\n containerElement.style.setProperty('--comp-pop-opacity', '1');\n };\n\n viewPortChanged = () => {\n if (!this.open) return;\n this.determinePopDirection();\n };\n\n viewPortOrientationChanged = () => {\n this.orientationChanged = true;\n this.viewPortChanged();\n };\n\n // #endregion\n // #region Render Methods\n\n render() {\n const containerClasses = ['container', this.currentDirection, this.align];\n if (isMobile()) containerClasses.push('mobile');\n if (this.show) containerClasses.push('show');\n if (this.block) containerClasses.push('block');\n if (this.mode === 'legacy') containerClasses.push('legacy');\n if (this.animated && this.animationState === 'opening') containerClasses.push('animating-open');\n if (this.animated && this.animationState === 'closing') containerClasses.push('animating-close');\n\n return (\n <div\n ref={el => (this.containerElement = el)}\n class={containerClasses.join(' ')}\n test-id=\"outerContainer\"\n tabIndex={-1}\n popover=\"manual\"\n >\n <div\n ref={el => (this.contentElement = el)}\n class=\"content\"\n >\n <slot />\n </div>\n </div>\n );\n }\n\n // #endregion\n}\n"],"version":3}
1
+ {"file":"q2-popover2.js","mappings":";;;;AAAA,MAAM,YAAY,GAAG,gzIAAgzI;;MCkDxzI,SAAS,iBAAAA,kBAAA,CAAA,MAAA,SAAA,SAAA,WAAA,CAAA;AADtB,IAAA,WAAA,GAAA;;;;;;AAMI;;AAEG;AACH,QAAA,IAAa,CAAA,aAAA,GAAG,EAAE;AAClB,QAAA,IAAkB,CAAA,kBAAA,GAAY,KAAK;AACnC,QAAA,IAAuB,CAAA,uBAAA,GAAwB,IAAI;;;AAYnD,QAAA,IAAc,CAAA,cAAA,GAAmC,MAAM;AAGvD,QAAA,IAAgB,CAAA,gBAAA,GAAkB,SAAS;;A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AE,EACZ,OAAO,EAAC,QAAQ,EAAA,EAEhB,CAAA,CAAA,KAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EACI,GAAG,EAAE,EAAE,KAAK,IAAI,CAAC,cAAc,GAAG,EAAE,CAAC,EACrC,KAAK,EAAC,SAAS,EAAA,EAEf,CAAQ,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,CAAA,CACN,CACJ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["__stencil_proxyCustomElement"],"sources":["src/components/q2-popover/q2-popover.scss?tag=q2-popover&encapsulation=shadow","src/components/q2-popover/q2-popover.tsx"],"sourcesContent":["@import '../../styles/host.scss';\n@import '../../styles/functions';\n\n.legacy {\n &.container {\n display: none;\n }\n\n &.show {\n display: block;\n z-index: var-list(--tct-popover-z-index, 50);\n }\n}\n\n@keyframes popoverOpen {\n from {\n opacity: 0;\n transform: scale(0.95);\n }\n to {\n opacity: 1;\n transform: scale(1);\n }\n}\n\n@keyframes popoverClose {\n from {\n opacity: 1;\n transform: scale(1);\n }\n to {\n opacity: 0;\n transform: scale(0.95);\n }\n}\n\n:popover-open,\n.show {\n position: absolute;\n margin: 0;\n padding: var-list(--tct-popover-padding, 0);\n overflow: auto;\n background: var-list(--tct-popover-background, --app-white, #ffffff);\n backdrop-filter: var-list(--tct-popover-backdrop-filter, none);\n color: var-list(--tct-popover-font-color, --t-text, #4d4d4d);\n min-width: var-list(--tct-popover-min-width, 135px);\n margin-block: var-list(--tct-popover-margin-block, 0);\n box-shadow: var-list(\n --tct-popover-box-shadow,\n --app-shadow-3,\n unquote('0px 0px 2px rgba(0, 0, 0, 0.12), 0px 2px 4px rgba(0, 0, 0, 0.14)')\n );\n border-width: var-list(--tct-popover-border-width, 0);\n border-style: solid;\n border-color: var-list(--tct-popover-border-color, transparent);\n border-radius: var-list(--tct-popover-border-radius, 0);\n // the --comp variables are set via JS\n max-height: var(--comp-pop-max-height);\n left: var(--comp-pop-left);\n opacity: var(--comp-pop-opacity, 0);\n\n &.animating-open {\n animation-name: popoverOpen;\n animation-duration: var-list(--tct-popover-open-animation-duration, --t-tween-time-in-1, 150ms);\n animation-timing-function: var-list(--tct-popover-open-animation-timing-function, ease-out);\n animation-fill-mode: var-list(--tct-popover-open-animation-fill-mode, forwards);\n }\n\n &.animating-close {\n animation-name: popoverClose;\n animation-duration: var-list(--tct-popover-close-animation-duration, --t-tween-time-out-1, 100ms);\n animation-timing-function: var-list(--tct-popover-close-animation-timing-function, ease-in);\n animation-fill-mode: var-list(--tct-popover-close-animation-fill-mode, forwards);\n }\n\n // Respect user's motion preferences\n @media (prefers-reduced-motion: reduce) {\n &.animating-open,\n &.animating-close {\n animation: none;\n }\n }\n\n &.block {\n right: unset;\n width: var(--comp-pop-width);\n min-width: var-list(--tct-popover-min-width, unset);\n }\n\n &.left {\n left: var(--comp-pop-left);\n right: unset;\n }\n\n &.right {\n right: var(--comp-pop-right);\n left: unset;\n }\n\n &.down {\n top: var-list(--tct-popover-top, --comp-pop-top);\n bottom: unset;\n }\n\n &.up {\n top: unset;\n bottom: var(--comp-pop-bottom);\n }\n\n // Desktop: corner-based transform origin\n &.down.left:not(.mobile) {\n transform-origin: top left;\n }\n\n &.down.right:not(.mobile) {\n transform-origin: top right;\n }\n\n &.up.left:not(.mobile) {\n transform-origin: bottom left;\n }\n\n &.up.right:not(.mobile) {\n transform-origin: bottom right;\n }\n\n // Mobile: center-based transform origin\n &.mobile.down {\n transform-origin: center top;\n }\n\n &.mobile.up {\n transform-origin: center bottom;\n }\n\n @include tiny-scrollbar();\n}\n\nclick-elsewhere {\n position: relative;\n display: block;\n}\n","import {\n Component,\n Prop,\n h,\n ComponentInterface,\n Element,\n Watch,\n Method,\n Listen,\n EventEmitter,\n Event,\n State,\n} from '@stencil/core';\nimport { handleDeprecationWarning, waitForNextPaint, isMobile, isInScrollableContainer } from '../../utils';\nimport mirrorEmit from '@/utils/mirror-emit';\n\n/**\n * ***********\n * * WARNING *\n * ***********\n * Touching this file obligates you to manually test thoroughly, because Puppeteer can't capture every edgecase.\n *\n * Each of the following Scenarios must be tested on each Device, in each Environment.\n *\n * Scenarios:\n * - Q2 Select searchable\n * - Q2 Select non-searchable\n *\n * Orientations:\n * - Portrait\n * - Landscape\n *\n * Devices:\n * - iOS Safari\n * - Android Chrome\n * - MacOS Safari\n * - Chrome\n * - Firefox\n *\n * Environments:\n * - Standard (Outside of Iframe)\n * - SDK Extension (Inside of Iframe)\n */\n\n/**\n * @name Popover\n * @category Display\n * @summary Use for positioning floating content relative to a trigger element.\n */\n@Component({ tag: 'q2-popover', shadow: true, styleUrl: 'q2-popover.scss' })\nexport class Q2Popover implements ComponentInterface {\n // #region Own Properties\n\n containerElement: HTMLDivElement;\n contentElement: HTMLDivElement;\n /**\n * The number of pixels to leave between the popover and the edge of the viewport\n */\n displayBuffer = 10;\n orientationChanged: boolean = false;\n pendingAnimationResolve: (() => void) | null = null;\n\n // #endregion\n // #region Host HTML Element\n\n @Element()\n hostElement: HTMLElement;\n\n // #endregion\n // #region State Properties\n\n @State()\n animationState: 'idle' | 'opening' | 'closing' = 'idle';\n\n @State()\n currentDirection: 'down' | 'up' = undefined;\n\n // remove `show` when we transitiong fully to Popover API and get rid of 'legacy' mode\n @State()\n show: boolean = false;\n\n // #endregion\n // #region Public Property API\n\n /** Aligns the popover to the left or right side of the control element. */\n @Prop({ reflect: true })\n align: 'left' | 'right' = 'left';\n\n /**\n * Controls whether the popover is animated when opening/closing.\n * Default is true (animated). Set to false to disable animations.\n * Animation is also disabled if the user has enabled prefers-reduced-motion.\n */\n @Prop({ reflect: true })\n animated: boolean = true;\n\n /** Indicates the popover will match the width of its parent element. */\n @Prop({ reflect: true })\n block: boolean;\n\n /** The element that controls the popover's behavior. */\n @Prop()\n controlElement: HTMLElement;\n\n /**\n * Force the direction of the popover when it opens.\n * If no value is passed, the component will auto-detect the direction based on available space.\n */\n @Prop({ reflect: true })\n direction: 'up' | 'down';\n\n /**\n * Force the maximum height of the popover. This value will be interpreted as pixels.\n * If no value is passed, or the value exceeds available space, the component will auto-detect the maximum height based on available space.\n */\n @Prop()\n maxHeight: number;\n\n /** @deprecated */\n @Prop()\n minHeight: number;\n\n @Prop()\n mode: 'legacy' = null;\n\n /** Controls whether the popover is open or closed. */\n @Prop({ reflect: true, mutable: true })\n open: boolean;\n\n // #endregion\n // #region Events\n\n /**\n * Emitted when the popover is opened or closed.\n * @deprecated Use 'tctPopoverStateChanged' instead\n */\n @Event()\n popoverStateChanged: EventEmitter<{ open: boolean }>;\n\n /**\n * Emitted when the popover is opened or closed.\n */\n @Event()\n tctPopoverStateChanged: EventEmitter<{ open: boolean }>;\n\n // #endregion\n // #region Component Lifecycle Events\n\n disconnectedCallback() {\n this.removeViewportListeners();\n if (this.pendingAnimationResolve) {\n this.pendingAnimationResolve();\n this.pendingAnimationResolve = null;\n }\n this.containerElement?.removeEventListener('toggle', this.handlePopoverToggleEvent);\n this.containerElement = null;\n this.contentElement = null;\n this.controlElement = null;\n }\n\n componentWillLoad() {\n if (!this.supportsPopoverAPI) {\n console.warn(\n 'The Popover API is not supported in this browser. Please update your browser to the latest version. The component will use legacy mode.'\n );\n this.mode = 'legacy';\n }\n }\n\n componentDidLoad() {\n this.handleMinHeight();\n if (this.supportsPopoverAPI) this.containerElement?.addEventListener('toggle', this.handlePopoverToggleEvent);\n if (this.open) this.determinePopDirection();\n }\n\n // #endregion\n // #region Listeners\n\n @Listen('popoverState')\n popoverStateHandler(event: CustomEvent<{ open: boolean }>) {\n const {\n detail: { open },\n } = event;\n if (open === this.open) return;\n\n this.open = open;\n event.stopPropagation();\n }\n\n // #endregion\n // #region Public Methods API\n\n @Method()\n async scrollContainerTo(options: ScrollToOptions) {\n this.containerElement?.scrollTo(options);\n }\n\n @Method()\n async toggle() {\n this.open = !this.open;\n }\n\n // #endregion\n // #region Watchers\n\n @Watch('minHeight')\n minHeightProvided() {\n this.handleMinHeight();\n }\n\n @Watch('open')\n async openChanged(open: boolean) {\n mirrorEmit(this, ['popoverStateChanged', 'tctPopoverStateChanged'], { open });\n\n if (open) {\n this.animationState = 'opening';\n this.addViewportListeners();\n this.determinePopDirection();\n } else {\n this.animationState = 'closing';\n this.removeViewportListeners();\n\n // Wait for close animation to complete\n if (this.animated) {\n await new Promise<void>(resolve => {\n const handleAnimationEnd = () => {\n this.pendingAnimationResolve = null;\n this.containerElement?.removeEventListener('animationend', handleAnimationEnd);\n resolve();\n };\n this.pendingAnimationResolve = handleAnimationEnd;\n this.containerElement?.addEventListener('animationend', handleAnimationEnd);\n if (!this.containerElement) resolve();\n });\n } else {\n // No animation, proceed immediately\n await waitForNextPaint();\n }\n\n if (!this.containerElement) return;\n\n this.currentDirection = undefined;\n this.animationState = 'idle';\n if (this.mode === 'legacy' || !this.supportsPopoverAPI) {\n this.show = false;\n } else {\n this.containerElement.hidePopover();\n }\n\n await waitForNextPaint();\n this.clearCSSProperties();\n }\n }\n\n // #endregion\n // #region Local Methods\n\n get isModule(): boolean {\n const isIframe = window !== window.top;\n const hasPlatformDimensions = Object.keys(window.Tecton?.platformDimensions ?? {}).length > 0;\n return isIframe && hasPlatformDimensions;\n }\n\n get providedDirection(): 'up' | 'down' | undefined {\n const { direction } = this;\n switch (direction) {\n case 'up':\n case 'down':\n return direction;\n default:\n return undefined;\n }\n }\n\n get supportsPopoverAPI(): boolean {\n return Object.hasOwn(HTMLElement.prototype, 'popover');\n }\n\n get validatedMaxHeight(): number | undefined {\n const { maxHeight } = this;\n return isNaN(maxHeight) ? undefined : maxHeight;\n }\n\n addViewportListeners() {\n window.addEventListener('resize', this.viewPortOrientationChanged);\n visualViewport?.addEventListener('resize', this.viewPortChanged);\n if (isInScrollableContainer(this.hostElement) && !isMobile()) {\n window.addEventListener('scroll', this.viewPortChanged, { passive: true, capture: true });\n }\n screen?.orientation?.addEventListener('orientationchange', this.viewPortOrientationChanged);\n window.addEventListener('orientationchange', this.viewPortOrientationChanged);\n }\n\n clearCSSProperties() {\n if (!this.containerElement) return;\n this.containerElement.style.removeProperty('--comp-pop-max-height');\n this.containerElement.style.removeProperty('--comp-pop-top');\n this.containerElement.style.removeProperty('--comp-pop-bottom');\n this.containerElement.style.removeProperty('--comp-pop-left');\n this.containerElement.style.removeProperty('--comp-pop-right');\n this.containerElement.style.removeProperty('--comp-pop-width');\n this.containerElement.style.removeProperty('--comp-pop-opacity');\n }\n\n async determinePopDirection() {\n const { containerElement, controlElement, providedDirection, displayBuffer } = this;\n if (containerElement) containerElement.style.maxHeight = null;\n await waitForNextPaint();\n if (!this.containerElement) return;\n\n const { isModule } = this;\n const { top: controlTop, bottom: controlBottom } = controlElement?.getBoundingClientRect?.() ?? {\n top: 0,\n bottom: 0,\n };\n\n let windowHeight: number;\n let maxSpaceAbove: number;\n let maxSpaceBelow: number;\n const isScrollableIframe = isModule && isInScrollableContainer(this.hostElement);\n if (isModule && !isScrollableIframe) {\n const {\n outletOffset = 0,\n innerHeight = window.innerHeight,\n top: topBarHeight = 0,\n bottom: bottomBarHeight = 0,\n } = window.Tecton?.platformDimensions || {};\n\n const distanceToIframeBottom = window.innerHeight - controlBottom;\n\n // controlElement position visually on the page\n const visualControlTop = outletOffset > 0 ? controlTop : controlTop + outletOffset - topBarHeight;\n const visualControlBottom = outletOffset + controlBottom - topBarHeight;\n\n // visual space around the controlElement\n const viewableSpaceAbove = visualControlTop;\n const viewableSpaceBelow = innerHeight - bottomBarHeight - visualControlBottom;\n\n // calculate space above and below controlElement\n const isIframeShorterThanWindow = distanceToIframeBottom < viewableSpaceBelow;\n maxSpaceAbove = viewableSpaceAbove - displayBuffer;\n maxSpaceBelow = isIframeShorterThanWindow\n ? distanceToIframeBottom - displayBuffer\n : viewableSpaceBelow - displayBuffer;\n } else {\n windowHeight = window.innerHeight;\n maxSpaceAbove = controlTop - displayBuffer;\n maxSpaceBelow = windowHeight - controlBottom - displayBuffer;\n }\n\n const directionWithMostSpace: 'up' | 'down' = maxSpaceAbove > maxSpaceBelow ? 'up' : 'down';\n\n // We do not want to update the max height once the popover is open unless the page orientation shifts (resize or mobile use cases)\n const shouldUpdateMaxHeight =\n !containerElement?.style.getPropertyValue('--comp-pop-max-height') || this.orientationChanged;\n // we do not want to constantly update the max-height after an orientation change, so we switch this back to false\n this.orientationChanged = false;\n const currentOrDetermineDirection = this.currentDirection || providedDirection || directionWithMostSpace;\n\n switch (currentOrDetermineDirection) {\n case 'up':\n if (shouldUpdateMaxHeight && containerElement) {\n const priorityMaxHeight = this.validatedMaxHeight || maxSpaceAbove;\n const maxHeight = Math.min(maxSpaceAbove, priorityMaxHeight);\n containerElement.style.setProperty('--comp-pop-max-height', `${maxHeight}px`);\n }\n this.setDirectionAndShow('up');\n break;\n case 'down':\n if (shouldUpdateMaxHeight && containerElement) {\n const priorityMaxHeight = this.validatedMaxHeight || maxSpaceBelow;\n const maxHeight = Math.min(maxSpaceBelow, priorityMaxHeight);\n containerElement.style.setProperty('--comp-pop-max-height', `${maxHeight}px`);\n }\n this.setDirectionAndShow('down');\n break;\n default:\n break;\n }\n }\n\n handleMinHeight = () => {\n if (this.minHeight) {\n handleDeprecationWarning(this, 'minHeight', 'prop');\n }\n };\n\n handlePopoverToggleEvent = (event: ToggleEvent) => {\n mirrorEmit(this, ['popoverStateChanged', 'tctPopoverStateChanged'], { open: event.newState === 'open' });\n };\n\n removeViewportListeners() {\n window.removeEventListener('resize', this.viewPortOrientationChanged);\n visualViewport?.removeEventListener('resize', this.viewPortChanged);\n window.removeEventListener('scroll', this.viewPortChanged, { capture: true });\n screen?.orientation?.removeEventListener('orientationchange', this.viewPortOrientationChanged);\n window.removeEventListener('orientationchange', this.viewPortOrientationChanged);\n }\n\n setAbsoluteCSSProperties = async () => {\n const { controlElement, containerElement, currentDirection, align } = this;\n if (!containerElement) return;\n\n if (align === 'right') {\n containerElement.style.setProperty('--comp-pop-right', '0');\n containerElement.style.setProperty('--comp-pop-left', 'unset');\n } else {\n containerElement.style.setProperty('--comp-pop-left', '0');\n containerElement.style.setProperty('--comp-pop-right', 'unset');\n }\n\n if (this.block) {\n containerElement.style.setProperty('--comp-pop-width', '100%');\n }\n\n if (currentDirection === 'up') {\n const controlStyle = getComputedStyle(controlElement);\n const controlSize =\n parseInt(controlStyle.height || '0') +\n parseInt(controlStyle.borderTopWidth || '0') +\n parseInt(controlStyle.borderBottomWidth || '0');\n\n containerElement.style.setProperty('--comp-pop-bottom', `${controlSize}px`);\n }\n\n // Wait for one paint to prevent layout thrashing\n await waitForNextPaint();\n if (this.containerElement) containerElement.style.setProperty('--comp-pop-opacity', '1');\n };\n\n setDirectionAndShow(direction: 'up' | 'down') {\n // Due to some runtime inconsistency across devices/browsers we need to add one more check here because the\n // popover can be closed between the time the popover is opened and the time the direction is determined\n const isOpen = this.open;\n if (!isOpen || !this.containerElement) return;\n\n this.currentDirection = direction;\n if (this.mode === 'legacy' || !this.supportsPopoverAPI) {\n this.show = true;\n this.setAbsoluteCSSProperties();\n } else {\n this.setPopoverAPICSSProperties();\n this.containerElement?.showPopover();\n }\n }\n\n setPopoverAPICSSProperties = async () => {\n const { controlElement, containerElement, currentDirection, isModule, align } = this;\n if (!containerElement) return;\n const {\n top: controlTop,\n bottom: controlBottom,\n left: controlLeft,\n right: controlRight,\n } = controlElement?.getBoundingClientRect?.() ?? {\n top: 0,\n bottom: 0,\n left: 0,\n right: 0,\n };\n\n const popoverLeft: number = controlLeft;\n const popoverRight: number = window?.visualViewport?.width - controlRight;\n\n if (align === 'right') {\n containerElement.style.setProperty('--comp-pop-right', `${popoverRight - window.scrollX}px`);\n containerElement.style.setProperty('--comp-pop-left', 'unset');\n } else {\n containerElement.style.setProperty('--comp-pop-left', `${popoverLeft + window.scrollX}px`);\n containerElement.style.setProperty('--comp-pop-right', 'unset');\n }\n\n if (this.block) containerElement.style.setProperty('--comp-pop-width', `${controlElement?.offsetWidth || 0}px`);\n\n const isScrollableIframe = isModule && isInScrollableContainer(this.hostElement);\n\n if (currentDirection === 'up') {\n if (isModule && !isScrollableIframe) {\n containerElement.style.setProperty('--comp-pop-bottom', `${window.innerHeight - controlTop}px`);\n } else {\n containerElement.style.setProperty(\n '--comp-pop-bottom',\n `${window.innerHeight - controlTop - window.scrollY}px`\n );\n }\n }\n\n if (currentDirection === 'down') {\n if (isModule && !isScrollableIframe) {\n containerElement.style.setProperty('--comp-pop-top', `${controlBottom}px`);\n } else {\n containerElement.style.setProperty('--comp-pop-top', `${controlBottom + window.scrollY}px`);\n }\n }\n\n // Wait for one paint to prevent layout thrashing\n await waitForNextPaint();\n if (this.containerElement) containerElement.style.setProperty('--comp-pop-opacity', '1');\n };\n\n viewPortChanged = () => {\n if (!this.open) return;\n this.determinePopDirection();\n };\n\n viewPortOrientationChanged = () => {\n this.orientationChanged = true;\n this.viewPortChanged();\n };\n\n // #endregion\n // #region Render Methods\n\n render() {\n const containerClasses = ['container', this.currentDirection, this.align];\n if (isMobile()) containerClasses.push('mobile');\n if (this.show) containerClasses.push('show');\n if (this.block) containerClasses.push('block');\n if (this.mode === 'legacy') containerClasses.push('legacy');\n if (this.animated && this.animationState === 'opening') containerClasses.push('animating-open');\n if (this.animated && this.animationState === 'closing') containerClasses.push('animating-close');\n\n return (\n <div\n ref={el => (this.containerElement = el)}\n class={containerClasses.join(' ')}\n test-id=\"outerContainer\"\n tabIndex={-1}\n popover=\"manual\"\n >\n <div\n ref={el => (this.contentElement = el)}\n class=\"content\"\n >\n <slot />\n </div>\n </div>\n );\n }\n\n // #endregion\n}\n"],"version":3}
@@ -181,7 +181,7 @@ const Q2RadioGroup$1 = /*@__PURE__*/ proxyCustomElement(class Q2RadioGroup exten
181
181
  const showLabel = this.label || this.optional || this.readonly;
182
182
  const { hasError } = this;
183
183
  const showLabelRow = (showLabel && !this.hideLabel) || hasError;
184
- return (h(Fragment, { key: 'ccf42e615a57f7a10d1dbf83477abe2f3a09c318' }, showLabelRow && (h("div", { key: 'e1dc942fcf0fd1736b3527471507f952d0823705', class: "label-row" }, showLabel && !this.hideLabel && h("div", { key: '5c9f17f222c2b9724b774e2d1963f4a83288b320', class: "group-legend" }, renderLabel(this)), hasError && (h("q2-icon", { key: 'a78ce480598193b64922b11d37b62a29452dd08c', type: "error", "test-id": "iconError" })))), h("fieldset", { key: 'c90583a3df7d565c92b8a39089f38d2a70487389', onChange: this.onInnerRadioChange, "aria-invalid": hasError ? `${hasError}` : undefined }, showLabel && h("legend", { key: '1f4a2f89ade2bb185ba10dc4edd64fbcfc689c05', class: "sr-only" }, renderLabel(this)), this.inputDom())));
184
+ return (h(Fragment, { key: '3fa5b7ba14cd74a3544ad38d40c74127126f0fc6' }, showLabelRow && (h("div", { key: '254b8a8ec9f21fccf2227966f56e366682957da8', class: "label-row" }, showLabel && !this.hideLabel && h("div", { key: 'f1176458f14bfc50adaab4a0d5342a7fcf58c6a4', class: "group-legend" }, renderLabel(this)), hasError && (h("q2-icon", { key: '7b829af0555cd13090459c5dc83ba22ce4cbe92c', type: "error", "test-id": "iconError" })))), h("fieldset", { key: '1eb9e6e18c1a5442d4582f23649b06d3864412b7', onChange: this.onInnerRadioChange, "aria-invalid": hasError ? `${hasError}` : undefined }, showLabel && h("legend", { key: '2ee4c9b44c86077fbda3f9eef02da24546cb6ec6', class: "sr-only" }, renderLabel(this)), this.inputDom())));
185
185
  }
186
186
  get hostElement() { return this; }
187
187
  static get watchers() { return {
@@ -93,7 +93,7 @@ const Q2Radio$1 = /*@__PURE__*/ proxyCustomElement(class Q2Radio extends HTMLEle
93
93
  // #endregion
94
94
  // #region Render Methods
95
95
  render() {
96
- return (h("div", { key: '1819bf1b409bdb257c590c95fd059f48e9ec2ebb', class: this.groupTileLayout ? 'radio-tile' : 'radio-container' }, h("input", { key: 'a6ef43c7dbb5da2e42dc24bad503ce48dc537080', ref: el => (this.inputField = el), class: "sr", id: this._id, type: "radio", name: this.name, value: this.value, disabled: this.disabled || this.groupDisabled, checked: this.checked, "aria-label": this.label && this.hideLabel ? loc(this.label) : undefined, onChange: this.inputChange, "test-id": "q2RadioInnerRadioBox" }), h("label", { key: '1da75f9e58a0b461d9bbab4bc09ed839a0364b11', htmlFor: this._id, class: this.hideLabel ? 'label-hidden' : undefined, "test-id": "radioButton" }, !this.groupTileLayout && (h("svg", { key: 'a85fa6abe0998cf6f1e377f1242788c41aae034d', viewBox: "0 0 18 18" }, h("circle", { key: '3c0ce4521a486e2f4d8890b844ca960a3f732b66', class: "big-circle", stroke: "none", fill: "none", cx: "9", cy: "9", r: "8" }), h("circle", { key: '95d480099459712896b5941542fef02002f1bd64', class: "small-circle", stroke: "none", fill: "none", cx: "9", cy: "9", r: "4" }))), !this.hideLabel && (h("div", { key: '3d217b5973322972a84dfafafb30055665840544', class: "label-content" }, (this.label && loc(this.label)) || '', h("slot", { key: '1ae3f23813fe800de5e7fa75e6ebfa33205c3961' }))))));
96
+ return (h("div", { key: '1c740c79651798b5aa532b48a8d35fbfb44e47a9', class: this.groupTileLayout ? 'radio-tile' : 'radio-container' }, h("input", { key: '1e8f5b6100d8ad8c43a60afba569184f5ccd8530', ref: el => (this.inputField = el), class: "sr", id: this._id, type: "radio", name: this.name, value: this.value, disabled: this.disabled || this.groupDisabled, checked: this.checked, "aria-label": this.label && this.hideLabel ? loc(this.label) : undefined, onChange: this.inputChange, "test-id": "q2RadioInnerRadioBox" }), h("label", { key: 'd86c5a574f853b570491bc9842996d9300b3a72c', htmlFor: this._id, class: this.hideLabel ? 'label-hidden' : undefined, "test-id": "radioButton" }, !this.groupTileLayout && (h("svg", { key: '473eb06c9c4a1b7ebd8014642da157b2aa4a5d08', viewBox: "0 0 18 18" }, h("circle", { key: '0035db29b3d96bb1e322fd8aa7233554098be30a', class: "big-circle", stroke: "none", fill: "none", cx: "9", cy: "9", r: "8" }), h("circle", { key: '6efda15f869a255325c8f09e9cf250a50627bd6d', class: "small-circle", stroke: "none", fill: "none", cx: "9", cy: "9", r: "4" }))), !this.hideLabel && (h("div", { key: '5def4a33beb0e6bd0e4327cdfb07d3fdabb4a72e', class: "label-content" }, (this.label && loc(this.label)) || '', h("slot", { key: 'f8ca1eac5a03d93e7019b5e5bd25456acf5a1230' }))))));
97
97
  }
98
98
  get hostElement() { return this; }
99
99
  static get watchers() { return {
@@ -154,7 +154,7 @@ const Q2RelativeTime$1 = /*@__PURE__*/ proxyCustomElement(class Q2RelativeTime e
154
154
  // #region Render Methods
155
155
  render() {
156
156
  const { shouldShow, displayedMessage } = this;
157
- return h(Fragment, { key: 'e2c0439b5b2ef14d719309202959a650e1a8e7d5' }, shouldShow ? h("time", { dateTime: displayedMessage }, displayedMessage) : null);
157
+ return h(Fragment, { key: '3a518920ff969cb0b60ca20ac780e11022803bef' }, shouldShow ? h("time", { dateTime: displayedMessage }, displayedMessage) : null);
158
158
  }
159
159
  get hostElement() { return this; }
160
160
  static get watchers() { return {
@@ -78,7 +78,7 @@ const Q2ResizeObserver = /*@__PURE__*/ proxyCustomElement(class Q2ResizeObserver
78
78
  // #endregion
79
79
  // #region Render Methods
80
80
  render() {
81
- return h("slot", { key: '2cf512a7e20957cca3fa7339875f2015effe829e', onSlotchange: this.handleSlotChange });
81
+ return h("slot", { key: 'f415d8b1adcb2cdfd6e76d09e9865fbfbeb2371e', onSlotchange: this.handleSlotChange });
82
82
  }
83
83
  get hostElement() { return this; }
84
84
  static get watchers() { return {
@@ -191,9 +191,9 @@ const Q2Section$1 = /*@__PURE__*/ proxyCustomElement(class Q2Section extends HTM
191
191
  wrapperClasses.push('is-transitioning');
192
192
  }
193
193
  const showDefaultHeader = !this.hasYieldedHeader && !!this.label;
194
- return (h("section", { key: '05ee53a9a05e1037c893f08ac5cf918c25b7f877', class: "wrapper" }, h("header", { key: '52678d55334407ef19cfae457e0e9fe277fb0bdd', class: hasHeader ? 'has-header' : '' }, h("div", { key: '76a3ade1875c6e64866ed5b50d005885c9108c61', class: "header-content", id: this.titleId, onClick: this.collapsible && this.onHeaderClick }, showDefaultHeader && h("h2", { key: '144199b22c9eb4d2b6c16c8890554f80939ac3f3', class: "title" }, loc(this.label)), h("div", { key: 'ce508b60dced7965b3e5a2c79999f8720176827e', ref: el => (this.headerSlotWrapper = el), class: "header-slot-wrapper" }, h("slot", { key: '73e9cfcfc13fe1eb9ae4b12593ca620f103fd3dd', ref: (el) => (this.headerSlot = el), name: "q2-section-header" }))), this.collapsible && !this.noCollapseIcon && (h("q2-btn", { key: 'd3d53f2d0740600a5178d93107db9ba684f29a44', label: loc(this.label || 'tecton.element.section.defaultToggleLabel'), ariaExpanded: `${!!this.expanded}`, ariaControls: this.contentId, "test-id": "toggleButton", "hide-label": true, onClick: this.onHeaderClick }, h("q2-icon", { key: '5c79651503d2222d92bdc8cc9b7811f75306a436', type: "chevron-up" })))), h("div", { key: '55fc425e4aea009b8102eb495069d9e191660045', class: wrapperClasses.join(' '), id: this.contentId, "aria-labelledby": this.titleId, role: "region", onTransitionEnd: this.onTransitionEnd, style: this.collapsible && {
194
+ return (h("section", { key: '3128e3974825bcd873c7713c20e1b4f004d02a30', class: "wrapper" }, h("header", { key: '1eb1fb74a992c76989a2a8baaa3bee68afa57138', class: hasHeader ? 'has-header' : '' }, h("div", { key: '9621ce7f0ccbfb97f522b5640d986371e0ed2d08', class: "header-content", id: this.titleId, onClick: this.collapsible && this.onHeaderClick }, showDefaultHeader && h("h2", { key: '9b4819672218286c3b0d11417933b6661a97c2af', class: "title" }, loc(this.label)), h("div", { key: '3ad3f55b3a554575b5b361ea565883860ce843b3', ref: el => (this.headerSlotWrapper = el), class: "header-slot-wrapper" }, h("slot", { key: 'ada9ab542b0f37d627fd1086c92289ebb6ec9049', ref: (el) => (this.headerSlot = el), name: "q2-section-header" }))), this.collapsible && !this.noCollapseIcon && (h("q2-btn", { key: 'dfd4ba0293689a3d603a1c1168e2f140c5307d60', label: loc(this.label || 'tecton.element.section.defaultToggleLabel'), ariaExpanded: `${!!this.expanded}`, ariaControls: this.contentId, "test-id": "toggleButton", "hide-label": true, onClick: this.onHeaderClick }, h("q2-icon", { key: '6c72dd59ead1dad5a54def864afa4d5d6ff7ce14', type: "chevron-up" })))), h("div", { key: '96434da7e59bf12b908a95aa4aa46fe59655da32', class: wrapperClasses.join(' '), id: this.contentId, "aria-labelledby": this.titleId, role: "region", onTransitionEnd: this.onTransitionEnd, style: this.collapsible && {
195
195
  height: this.contentHeight,
196
- } }, h("div", { key: 'cd773f58a51c95785062f37c7542d0742acf9ab9', ref: el => (this.contentContainer = el), class: "content", tabindex: "-1" }, h("slot", { key: 'e614cef7ec9036998dc509454c79439e3369b660', ref: (el) => (this.contentSlot = el) })))));
196
+ } }, h("div", { key: 'b6ef59a27be6c6b3c0cdc8b23eef7d7a80a0937e', ref: el => (this.contentContainer = el), class: "content", tabindex: "-1" }, h("slot", { key: 'bca7946799bfd50e1be14b24e4106df2a583b43b', ref: (el) => (this.contentSlot = el) })))));
197
197
  }
198
198
  get hostElement() { return this; }
199
199
  static get watchers() { return {
@@ -800,7 +800,7 @@ const Q2Select = /*@__PURE__*/ proxyCustomElement(class Q2Select extends HTMLEle
800
800
  ]), checked: showSelected, "test-id": "selectedOptionsButton", onClick: this.showSelectedOptions, onKeyDown: this.visibilityToggleKeyDown }), h("label", { htmlFor: "selected" }, loc('tecton.element.select.multiHeader.selected', [selectedOptionsCount]))))));
801
801
  }
802
802
  render() {
803
- return (h("click-elsewhere", { key: '3e4e224801ab3110490f94c49d6b1ff1e1f8f227', class: this.wrapperClasses, role: "presentation", onChange: this.clickedElsewhere }, this.renderSelectField()));
803
+ return (h("click-elsewhere", { key: 'c0da37dd6495f81c0e9fa7303ed3059f60521d96', class: this.wrapperClasses, role: "presentation", onChange: this.clickedElsewhere }, this.renderSelectField()));
804
804
  }
805
805
  get hostElement() { return this; }
806
806
  static get watchers() { return {
@@ -75,7 +75,7 @@ const Q2StepperPane$1 = /*@__PURE__*/ proxyCustomElement(class Q2StepperPane ext
75
75
  // #region Render Methods
76
76
  render() {
77
77
  const { label, isActive } = this;
78
- return (h(Host, { key: '69b27313eda3276e7041c2813b2a56a53efc104b', role: "listitem" }, h(Fragment, { key: 'c7c5d0fd3ad3dc8650832d6e2f32ff59ee28b1a6' }, h("div", { key: 'a07608df6dc48453a00b72e501d23f28b72ab5cb', "aria-label": label && loc(label), tabindex: "0", hidden: !isActive && !(this.isChildActive && this.showWithChildren) }, h("slot", { key: '68cef0c9131cf432fa9d48500f62fc88ebba198b' })), h("div", { key: '0b9f7a3e34565490acd91747b047f9802bf9ac49', hidden: true }, h("slot", { key: 'ca7f10c02501ba44b75640d6f6a67d1f4d5dcf92', name: "label", onSlotchange: () => this.contentChange.emit() }), h("slot", { key: 'f1cd0547c27b3f869fc245d6eba144cf85c3e17f', name: "description", onSlotchange: () => this.contentChange.emit() })), h("slot", { key: 'bf21a7e7f578f58649edfa9ebf34849385b712a4', name: "children" }))));
78
+ return (h(Host, { key: '3522e747efa7fceace61bfcbc8ebe875a122b68d', role: "listitem" }, h(Fragment, { key: '986e434647215ff29c168609a2154156fdbb69a1' }, h("div", { key: 'ed2fef05b366c5fd3d8f0b64db2ce4dceb3b6735', "aria-label": label && loc(label), tabindex: "0", hidden: !isActive && !(this.isChildActive && this.showWithChildren) }, h("slot", { key: '5b5333b64c2114e5fd7caada8818eb2ce793900f' })), h("div", { key: '6aeb4f8ebc8700ac3c363bd72023743eba58f841', hidden: true }, h("slot", { key: '7d3eaf00c409f597efbb934a8d356195fa239265', name: "label", onSlotchange: () => this.contentChange.emit() }), h("slot", { key: '258bf88e3a2c98734501a3d3e7b66e1735011f50', name: "description", onSlotchange: () => this.contentChange.emit() })), h("slot", { key: '4013f30dde148392690cdef431959a056af98873', name: "children" }))));
79
79
  }
80
80
  get hostElement() { return this; }
81
81
  static get watchers() { return {
@@ -284,7 +284,7 @@ const Q2Stepper$1 = /*@__PURE__*/ proxyCustomElement(class Q2Stepper extends HTM
284
284
  const containerClasses = ['step-container'];
285
285
  if (scrollEnabled)
286
286
  containerClasses.push('has-scroll');
287
- return (h(Fragment, { key: 'b9bbe49ba3b47a4bcf32a8dc15e8731288f4eebd' }, h("div", { key: '1573c647f547aadef0b6cf393acfe61e431cf0da', class: containerClasses.join(' ') }, scrollEnabled && (h(Fragment, { key: '9d3a985448dd7e4439485fb3b8408871d67df6fc' }, h("div", { key: 'b8ed037c41fa19dcfeb2d30e0690c9838bf9f61a', class: "gradient-left", hidden: !showScrollLeft }), h("div", { key: 'ef91d66fd50ce2377c96999aea029da78cef8438', class: "gradient-right", hidden: !showScrollRight }), h("q2-btn", { key: 'd041a6e7aedabbb47de657cc690d3488cd408d2f', class: "btn-left", hideLabel: true, hidden: !this.showScrollLeft, label: loc('tecton.element.stepper.scrollLeft'), onTctClick: () => this.onScrollBtnClick('left') }, h("q2-icon", { key: '0a4b6a0b982f270dca51fbd61829708daf03ea79', type: "chevron-left" })), h("q2-btn", { key: 'a690d70cc826f0236d2501680850453d3160b636', class: "btn-right", hideLabel: true, hidden: !this.showScrollRight, label: loc('tecton.element.stepper.scrollRight'), onTctClick: () => this.onScrollBtnClick('right') }, h("q2-icon", { key: '0678d7423d4f3fc7529649b23f074fc1b17f6379', type: "chevron-right" })))), h("ul", { key: '623c1491f459cf7e1313d486f3a547d9c31f0bf6', onScroll: this.checkScrollState, ref: el => (this.listElement = el), role: "tablist" }, stepCount > 0 && [...Array(stepCount).keys()].map(stepIndex => this.renderStepBtn(stepIndex)))), h("div", { key: 'cce9355d3553bbefef2eb5cf303463777693ff76', role: "list" }, h("slot", { key: '7de13d3600c9b8093d77b55101f27bb2d7bb19a8', onSlotchange: () => this.onSlotChange() }))));
287
+ return (h(Fragment, { key: '921748b0e20ada57cac4f0b66ac9ed97d2355d26' }, h("div", { key: '3d5099613b5a5e825ade9a246dbec2068e04a7d8', class: containerClasses.join(' ') }, scrollEnabled && (h(Fragment, { key: '3842e7310fa0788566192e34fee1d1df20f48b52' }, h("div", { key: 'ad9d8ba937cc012dca25b8844e2ecea36be1e4c8', class: "gradient-left", hidden: !showScrollLeft }), h("div", { key: '4a17dcc015ac03d2b6c41d2493c7ae81196d850f', class: "gradient-right", hidden: !showScrollRight }), h("q2-btn", { key: 'b38a23630a4c0f330aa52d8b2cfc7643b3fa134c', class: "btn-left", hideLabel: true, hidden: !this.showScrollLeft, label: loc('tecton.element.stepper.scrollLeft'), onTctClick: () => this.onScrollBtnClick('left') }, h("q2-icon", { key: '043873f95eae37851127d03c61fd73c93abae581', type: "chevron-left" })), h("q2-btn", { key: 'b86849ccce00f6ddbdd25a64f345f98e6070dd19', class: "btn-right", hideLabel: true, hidden: !this.showScrollRight, label: loc('tecton.element.stepper.scrollRight'), onTctClick: () => this.onScrollBtnClick('right') }, h("q2-icon", { key: 'de9ea9fc186474cb0f3a57f6314aa1e78539a2cd', type: "chevron-right" })))), h("ul", { key: '10078d2a1382c4abee65f52c88ef3006cfdd0c19', onScroll: this.checkScrollState, ref: el => (this.listElement = el), role: "tablist" }, stepCount > 0 && [...Array(stepCount).keys()].map(stepIndex => this.renderStepBtn(stepIndex)))), h("div", { key: '96efdd3370c5fc3ed7f91d372a645063b9b6ad61', role: "list" }, h("slot", { key: '26bfea7637cd71eb704d626cd93c74c3df13c4ba', onSlotchange: () => this.onSlotChange() }))));
288
288
  }
289
289
  get hostElement() { return this; }
290
290
  static get watchers() { return {