@zanichelli/albe-web-components 4.0.4 → 4.2.0

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 (303) hide show
  1. package/CHANGELOG.md +66 -0
  2. package/dist/cjs/{index-6b6a3299.js → index-0e75c8cc.js} +16 -45
  3. package/dist/cjs/index.cjs.js +2 -2
  4. package/dist/cjs/loader.cjs.js +1 -1
  5. package/dist/cjs/utils-155eec04.js +2706 -0
  6. package/dist/cjs/{utils-8cc414c9.js → utils-97262bbd.js} +1 -1
  7. package/dist/cjs/web-components-library.cjs.js +1 -1
  8. package/dist/cjs/z-app-switcher_9.cjs.entry.js +736 -0
  9. package/dist/cjs/z-aria-alert.cjs.entry.js +1 -1
  10. package/dist/cjs/z-avatar.cjs.entry.js +1 -1
  11. package/dist/cjs/z-button-deprecated.cjs.entry.js +1 -1
  12. package/dist/cjs/z-button.cjs.entry.js +44 -0
  13. package/dist/cjs/z-card.cjs.entry.js +69 -0
  14. package/dist/cjs/z-carousel.cjs.entry.js +24 -0
  15. package/dist/cjs/z-chip.cjs.entry.js +2 -2
  16. package/dist/cjs/z-combobox.cjs.entry.js +2 -2
  17. package/dist/cjs/z-contextual-menu.cjs.entry.js +18 -7
  18. package/dist/cjs/z-cookiebar.cjs.entry.js +1 -1
  19. package/dist/cjs/z-date-picker.cjs.entry.js +10 -2701
  20. package/dist/cjs/z-file-upload.cjs.entry.js +2 -2
  21. package/dist/cjs/z-file.cjs.entry.js +10 -9
  22. package/dist/cjs/z-footer.cjs.entry.js +1 -1
  23. package/dist/cjs/z-ghost-loading.cjs.entry.js +19 -0
  24. package/dist/cjs/z-input-deprecated.cjs.entry.js +2 -2
  25. package/dist/cjs/z-input-label_2.cjs.entry.js +2 -2
  26. package/dist/cjs/z-list-group.cjs.entry.js +1 -1
  27. package/dist/cjs/z-list_2.cjs.entry.js +1 -1
  28. package/dist/cjs/z-menu-dropdown_2.cjs.entry.js +2 -2
  29. package/dist/cjs/z-messages-pocket.cjs.entry.js +1 -1
  30. package/dist/cjs/z-modal-login.cjs.entry.js +1 -1
  31. package/dist/cjs/z-myz-card-alert.cjs.entry.js +1 -1
  32. package/dist/cjs/z-myz-card-dictionary.cjs.entry.js +1 -1
  33. package/dist/cjs/z-myz-card-footer.cjs.entry.js +1 -1
  34. package/dist/cjs/z-myz-card-info.cjs.entry.js +4 -4
  35. package/dist/cjs/z-myz-card_4.cjs.entry.js +1 -1
  36. package/dist/cjs/z-myz-list-item.cjs.entry.js +2 -2
  37. package/dist/cjs/z-myz-topbar.cjs.entry.js +1 -1
  38. package/dist/cjs/z-navigation-tab-link.cjs.entry.js +1 -1
  39. package/dist/cjs/z-navigation-tab.cjs.entry.js +1 -1
  40. package/dist/cjs/z-navigation-tabs.cjs.entry.js +1 -1
  41. package/dist/cjs/z-offcanvas.cjs.entry.js +63 -0
  42. package/dist/cjs/z-otp.cjs.entry.js +1 -1
  43. package/dist/cjs/z-pagination-bar.cjs.entry.js +2 -2
  44. package/dist/cjs/z-pocket_3.cjs.entry.js +2 -2
  45. package/dist/cjs/z-popover-deprecated.cjs.entry.js +338 -0
  46. package/dist/cjs/z-popover.cjs.entry.js +304 -97
  47. package/dist/cjs/z-section-title.cjs.entry.js +1 -1
  48. package/dist/cjs/z-skip-to-content.cjs.entry.js +2 -2
  49. package/dist/cjs/z-slideshow.cjs.entry.js +2 -2
  50. package/dist/cjs/z-status-tag.cjs.entry.js +1 -1
  51. package/dist/cjs/z-table-cell.cjs.entry.js +1 -1
  52. package/dist/cjs/z-table-header.cjs.entry.js +8 -11
  53. package/dist/cjs/z-table-row.cjs.entry.js +1 -1
  54. package/dist/cjs/z-table.cjs.entry.js +1 -1
  55. package/dist/cjs/z-toast-notification-list.cjs.entry.js +1 -1
  56. package/dist/cjs/z-toast-notification.cjs.entry.js +1 -1
  57. package/dist/cjs/z-toggle-switch.cjs.entry.js +2 -2
  58. package/dist/cjs/z-tooltip-deprecated.cjs.entry.js +274 -0
  59. package/dist/cjs/z-tooltip.cjs.entry.js +8 -251
  60. package/dist/collection/beans/index.js +16 -45
  61. package/dist/collection/collection-manifest.json +4 -1
  62. package/dist/collection/components/{z-date-picker → date-picker}/styles.css +69 -17
  63. package/dist/collection/components/date-picker/utils.js +76 -0
  64. package/dist/collection/components/{z-date-picker → date-picker/z-date-picker}/index.js +13 -84
  65. package/dist/collection/components/date-picker/z-range-picker/index.js +483 -0
  66. package/dist/collection/components/file-upload/z-file/index.js +13 -13
  67. package/dist/collection/components/file-upload/z-file/styles.css +2 -2
  68. package/dist/collection/components/inputs/z-input/styles.css +2 -0
  69. package/dist/collection/components/notification/z-tooltip/index.js +45 -298
  70. package/dist/collection/components/notification/z-tooltip/styles.css +8 -120
  71. package/dist/collection/components/z-contextual-menu/index.js +26 -16
  72. package/dist/collection/components/z-contextual-menu/styles.css +16 -5
  73. package/dist/collection/components/z-popover/index.js +381 -166
  74. package/dist/collection/components/z-popover/styles.css +91 -180
  75. package/dist/collection/components/z-table/z-table-header/index.js +10 -16
  76. package/dist/collection/components/z-table/z-table-header/styles.css +7 -1
  77. package/dist/collection/deprecated/z-popover-deprecated/index.js +489 -0
  78. package/dist/collection/deprecated/z-popover-deprecated/styles.css +134 -0
  79. package/dist/collection/deprecated/z-tooltip-deprecated/index.js +379 -0
  80. package/dist/collection/deprecated/z-tooltip-deprecated/styles.css +128 -0
  81. package/dist/collection/snowflakes/myz/card/z-myz-card-info/index.js +2 -2
  82. package/dist/collection/snowflakes/myz/card/z-myz-card-info/styles.css +1 -1
  83. package/dist/esm/{index-46ca649a.js → index-c1ce8cab.js} +17 -46
  84. package/dist/esm/index.js +2 -2
  85. package/dist/esm/loader.js +1 -1
  86. package/dist/esm/{utils-5d5963ef.js → utils-99c70c57.js} +2 -2
  87. package/dist/esm/utils-fa9f38ec.js +2701 -0
  88. package/dist/esm/web-components-library.js +1 -1
  89. package/dist/esm/z-app-switcher_9.entry.js +724 -0
  90. package/dist/esm/z-aria-alert.entry.js +1 -1
  91. package/dist/esm/z-avatar.entry.js +1 -1
  92. package/dist/esm/z-button-deprecated.entry.js +1 -1
  93. package/dist/esm/z-button.entry.js +40 -0
  94. package/dist/esm/z-card.entry.js +65 -0
  95. package/dist/esm/z-carousel.entry.js +20 -0
  96. package/dist/esm/z-chip.entry.js +2 -2
  97. package/dist/esm/z-combobox.entry.js +2 -2
  98. package/dist/esm/z-contextual-menu.entry.js +19 -8
  99. package/dist/esm/z-cookiebar.entry.js +1 -1
  100. package/dist/esm/z-date-picker.entry.js +9 -2700
  101. package/dist/esm/z-file-upload.entry.js +2 -2
  102. package/dist/esm/z-file.entry.js +10 -9
  103. package/dist/esm/z-footer.entry.js +1 -1
  104. package/dist/esm/z-ghost-loading.entry.js +15 -0
  105. package/dist/esm/z-input-deprecated.entry.js +2 -2
  106. package/dist/esm/z-input-label_2.entry.js +2 -2
  107. package/dist/esm/z-list-group.entry.js +1 -1
  108. package/dist/esm/z-list_2.entry.js +1 -1
  109. package/dist/esm/z-menu-dropdown_2.entry.js +2 -2
  110. package/dist/esm/z-messages-pocket.entry.js +1 -1
  111. package/dist/esm/z-modal-login.entry.js +1 -1
  112. package/dist/esm/z-myz-card-alert.entry.js +1 -1
  113. package/dist/esm/z-myz-card-dictionary.entry.js +1 -1
  114. package/dist/esm/z-myz-card-footer.entry.js +1 -1
  115. package/dist/esm/z-myz-card-info.entry.js +4 -4
  116. package/dist/esm/z-myz-card_4.entry.js +1 -1
  117. package/dist/esm/z-myz-list-item.entry.js +2 -2
  118. package/dist/esm/z-myz-topbar.entry.js +1 -1
  119. package/dist/esm/z-navigation-tab-link.entry.js +1 -1
  120. package/dist/esm/z-navigation-tab.entry.js +1 -1
  121. package/dist/esm/z-navigation-tabs.entry.js +1 -1
  122. package/dist/esm/z-offcanvas.entry.js +59 -0
  123. package/dist/esm/z-otp.entry.js +1 -1
  124. package/dist/esm/z-pagination-bar.entry.js +2 -2
  125. package/dist/esm/z-pocket_3.entry.js +2 -2
  126. package/dist/esm/z-popover-deprecated.entry.js +334 -0
  127. package/dist/esm/z-popover.entry.js +305 -98
  128. package/dist/esm/z-section-title.entry.js +1 -1
  129. package/dist/esm/z-skip-to-content.entry.js +2 -2
  130. package/dist/esm/z-slideshow.entry.js +2 -2
  131. package/dist/esm/z-status-tag.entry.js +1 -1
  132. package/dist/esm/z-table-cell.entry.js +1 -1
  133. package/dist/esm/z-table-header.entry.js +8 -11
  134. package/dist/esm/z-table-row.entry.js +1 -1
  135. package/dist/esm/z-table.entry.js +1 -1
  136. package/dist/esm/z-toast-notification-list.entry.js +1 -1
  137. package/dist/esm/z-toast-notification.entry.js +1 -1
  138. package/dist/esm/z-toggle-switch.entry.js +2 -2
  139. package/dist/esm/z-tooltip-deprecated.entry.js +270 -0
  140. package/dist/esm/z-tooltip.entry.js +9 -252
  141. package/dist/types/beans/index.d.ts +7 -33
  142. package/dist/types/components/date-picker/utils.d.ts +3 -0
  143. package/dist/types/components/{z-date-picker → date-picker/z-date-picker}/index.d.ts +3 -8
  144. package/dist/types/components/date-picker/z-range-picker/index.d.ts +43 -0
  145. package/dist/types/components/file-upload/z-file/index.d.ts +3 -3
  146. package/dist/types/components/notification/z-tooltip/index.d.ts +14 -29
  147. package/dist/types/components/z-contextual-menu/index.d.ts +8 -4
  148. package/dist/types/components/z-popover/index.d.ts +57 -28
  149. package/dist/types/components/z-table/z-table-header/index.d.ts +2 -1
  150. package/dist/types/components.d.ts +210 -35
  151. package/dist/types/deprecated/z-popover-deprecated/index.d.ts +57 -0
  152. package/dist/types/deprecated/z-tooltip-deprecated/index.d.ts +41 -0
  153. package/dist/web-components-library/index.esm.js +1 -1
  154. package/dist/web-components-library/{p-4af112a7.entry.js → p-053846df.entry.js} +1 -1
  155. package/dist/web-components-library/{p-e2102da3.entry.js → p-0f6edb58.entry.js} +1 -1
  156. package/dist/web-components-library/p-10be0462.entry.js +1 -0
  157. package/dist/web-components-library/{p-b15efba3.entry.js → p-15fa8ca4.entry.js} +1 -1
  158. package/dist/web-components-library/{p-02ea7e49.entry.js → p-1a76a57d.entry.js} +1 -1
  159. package/{www/build/p-1f73a6d8.entry.js → dist/web-components-library/p-1b1717c9.entry.js} +1 -1
  160. package/{www/build/p-3edbd35c.entry.js → dist/web-components-library/p-1d5aa37b.entry.js} +1 -1
  161. package/dist/web-components-library/{p-9074e1a5.entry.js → p-1eb357e8.entry.js} +1 -1
  162. package/dist/web-components-library/{p-57d1acdc.entry.js → p-28e4abc4.entry.js} +1 -1
  163. package/dist/web-components-library/p-41f33f7b.entry.js +1 -0
  164. package/dist/web-components-library/{p-d33fea26.entry.js → p-46aecb12.entry.js} +1 -1
  165. package/dist/web-components-library/{p-63ccb013.entry.js → p-4be52491.entry.js} +1 -1
  166. package/{www/build/p-55ddbfe9.entry.js → dist/web-components-library/p-4d6f2f01.entry.js} +1 -1
  167. package/dist/web-components-library/p-514719d2.entry.js +1 -0
  168. package/dist/web-components-library/p-53dade4b.entry.js +16 -0
  169. package/{www/build/p-df4e963b.entry.js → dist/web-components-library/p-55f09348.entry.js} +1 -1
  170. package/dist/web-components-library/p-5789bbe7.entry.js +1 -0
  171. package/dist/web-components-library/{p-de25c7f0.entry.js → p-5dcbba4e.entry.js} +1 -1
  172. package/dist/web-components-library/{p-9f9e4266.entry.js → p-659fc25e.entry.js} +1 -1
  173. package/dist/web-components-library/{p-8fbc2ce9.entry.js → p-6bbd53ec.entry.js} +1 -1
  174. package/dist/web-components-library/{p-5be162d5.entry.js → p-6c52ed1b.entry.js} +1 -1
  175. package/dist/web-components-library/p-78df5dbf.entry.js +1 -0
  176. package/dist/web-components-library/{p-b9da171f.js → p-7f1cc90f.js} +1 -1
  177. package/dist/web-components-library/{p-0f17db30.entry.js → p-805af37b.entry.js} +1 -1
  178. package/dist/web-components-library/p-870dabdc.entry.js +1 -0
  179. package/dist/web-components-library/{p-43329b81.entry.js → p-897f9491.entry.js} +1 -1
  180. package/dist/web-components-library/{p-3c111c2a.entry.js → p-8ce4b2c4.entry.js} +1 -1
  181. package/dist/web-components-library/p-8cf3798f.entry.js +1 -0
  182. package/dist/web-components-library/p-8ddbbe24.entry.js +1 -0
  183. package/{www/build/p-dffdf60a.entry.js → dist/web-components-library/p-91ec5eb4.entry.js} +1 -1
  184. package/dist/web-components-library/{p-292bc0c4.entry.js → p-92895bce.entry.js} +1 -1
  185. package/dist/web-components-library/p-970bd07c.entry.js +1 -0
  186. package/dist/web-components-library/{p-6c6b4e80.entry.js → p-990b8236.entry.js} +1 -1
  187. package/dist/web-components-library/{p-51cdabeb.entry.js → p-99a562cb.entry.js} +1 -1
  188. package/dist/web-components-library/p-b359a3b4.entry.js +1 -0
  189. package/dist/web-components-library/p-b6cd034b.js +1 -0
  190. package/dist/web-components-library/{p-edb8d2ab.entry.js → p-b9cc2dfc.entry.js} +1 -1
  191. package/dist/web-components-library/p-bfc78a89.entry.js +1 -0
  192. package/dist/web-components-library/{p-d995d9dc.entry.js → p-c042e745.entry.js} +1 -1
  193. package/dist/web-components-library/{p-ccdebe3f.entry.js → p-c8383456.entry.js} +1 -1
  194. package/dist/web-components-library/{p-0e256fdc.entry.js → p-caa21a6f.entry.js} +1 -1
  195. package/{www/build/p-bfe5693d.entry.js → dist/web-components-library/p-cd88cead.entry.js} +1 -1
  196. package/dist/web-components-library/p-d04f3cb6.entry.js +1 -0
  197. package/{www/build/p-9a5ee6c2.entry.js → dist/web-components-library/p-d6361790.entry.js} +1 -1
  198. package/dist/web-components-library/{p-69ef6ddc.entry.js → p-dd0efdbf.entry.js} +1 -1
  199. package/dist/web-components-library/p-e007cd0b.entry.js +1 -0
  200. package/dist/web-components-library/{p-0a0aee35.entry.js → p-e74b3fd9.entry.js} +1 -1
  201. package/{www/build/p-d97a2db9.entry.js → dist/web-components-library/p-eca4cb15.entry.js} +1 -1
  202. package/dist/web-components-library/p-ed1cd6b1.js +1 -0
  203. package/dist/web-components-library/p-f26251dd.entry.js +1 -0
  204. package/dist/web-components-library/p-f61fd81e.entry.js +1 -0
  205. package/dist/web-components-library/{p-1727c1c8.entry.js → p-f78d6123.entry.js} +1 -1
  206. package/dist/web-components-library/p-fbfaa699.entry.js +1 -0
  207. package/dist/web-components-library/{p-ba29bc12.entry.js → p-fdd91263.entry.js} +1 -1
  208. package/dist/web-components-library/{p-fe927bf4.entry.js → p-ff4a0f6f.entry.js} +1 -1
  209. package/dist/web-components-library/web-components-library.esm.js +1 -1
  210. package/package.json +1 -1
  211. package/react/components.d.ts +3 -0
  212. package/react/components.js +5 -2
  213. package/react/components.js.map +1 -1
  214. package/www/build/index.esm.js +1 -1
  215. package/www/build/{p-4af112a7.entry.js → p-053846df.entry.js} +1 -1
  216. package/www/build/{p-e2102da3.entry.js → p-0f6edb58.entry.js} +1 -1
  217. package/www/build/p-10be0462.entry.js +1 -0
  218. package/www/build/{p-b15efba3.entry.js → p-15fa8ca4.entry.js} +1 -1
  219. package/www/build/{p-02ea7e49.entry.js → p-1a76a57d.entry.js} +1 -1
  220. package/{dist/web-components-library/p-1f73a6d8.entry.js → www/build/p-1b1717c9.entry.js} +1 -1
  221. package/{dist/web-components-library/p-3edbd35c.entry.js → www/build/p-1d5aa37b.entry.js} +1 -1
  222. package/www/build/{p-9074e1a5.entry.js → p-1eb357e8.entry.js} +1 -1
  223. package/www/build/{p-57d1acdc.entry.js → p-28e4abc4.entry.js} +1 -1
  224. package/www/build/p-41f33f7b.entry.js +1 -0
  225. package/www/build/{p-d33fea26.entry.js → p-46aecb12.entry.js} +1 -1
  226. package/www/build/{p-63ccb013.entry.js → p-4be52491.entry.js} +1 -1
  227. package/{dist/web-components-library/p-55ddbfe9.entry.js → www/build/p-4d6f2f01.entry.js} +1 -1
  228. package/www/build/p-514719d2.entry.js +1 -0
  229. package/www/build/p-53dade4b.entry.js +16 -0
  230. package/{dist/web-components-library/p-df4e963b.entry.js → www/build/p-55f09348.entry.js} +1 -1
  231. package/www/build/p-5789bbe7.entry.js +1 -0
  232. package/www/build/{p-de25c7f0.entry.js → p-5dcbba4e.entry.js} +1 -1
  233. package/www/build/{p-9f9e4266.entry.js → p-659fc25e.entry.js} +1 -1
  234. package/www/build/{p-8fbc2ce9.entry.js → p-6bbd53ec.entry.js} +1 -1
  235. package/www/build/{p-5be162d5.entry.js → p-6c52ed1b.entry.js} +1 -1
  236. package/www/build/p-78df5dbf.entry.js +1 -0
  237. package/www/build/{p-b9da171f.js → p-7f1cc90f.js} +1 -1
  238. package/www/build/{p-0f17db30.entry.js → p-805af37b.entry.js} +1 -1
  239. package/www/build/p-870dabdc.entry.js +1 -0
  240. package/www/build/{p-43329b81.entry.js → p-897f9491.entry.js} +1 -1
  241. package/www/build/{p-3c111c2a.entry.js → p-8ce4b2c4.entry.js} +1 -1
  242. package/www/build/p-8cf3798f.entry.js +1 -0
  243. package/www/build/p-8ddbbe24.entry.js +1 -0
  244. package/{dist/web-components-library/p-dffdf60a.entry.js → www/build/p-91ec5eb4.entry.js} +1 -1
  245. package/www/build/{p-292bc0c4.entry.js → p-92895bce.entry.js} +1 -1
  246. package/www/build/p-970bd07c.entry.js +1 -0
  247. package/www/build/p-975e9d42.js +129 -0
  248. package/www/build/{p-6c6b4e80.entry.js → p-990b8236.entry.js} +1 -1
  249. package/www/build/{p-51cdabeb.entry.js → p-99a562cb.entry.js} +1 -1
  250. package/www/build/p-b359a3b4.entry.js +1 -0
  251. package/www/build/p-b6cd034b.js +1 -0
  252. package/www/build/{p-edb8d2ab.entry.js → p-b9cc2dfc.entry.js} +1 -1
  253. package/www/build/p-bfc78a89.entry.js +1 -0
  254. package/www/build/{p-d995d9dc.entry.js → p-c042e745.entry.js} +1 -1
  255. package/www/build/{p-ccdebe3f.entry.js → p-c8383456.entry.js} +1 -1
  256. package/www/build/{p-0e256fdc.entry.js → p-caa21a6f.entry.js} +1 -1
  257. package/{dist/web-components-library/p-bfe5693d.entry.js → www/build/p-cd88cead.entry.js} +1 -1
  258. package/www/build/p-d04f3cb6.entry.js +1 -0
  259. package/{dist/web-components-library/p-9a5ee6c2.entry.js → www/build/p-d6361790.entry.js} +1 -1
  260. package/www/build/{p-69ef6ddc.entry.js → p-dd0efdbf.entry.js} +1 -1
  261. package/www/build/p-e007cd0b.entry.js +1 -0
  262. package/www/build/{p-0a0aee35.entry.js → p-e74b3fd9.entry.js} +1 -1
  263. package/{dist/web-components-library/p-d97a2db9.entry.js → www/build/p-eca4cb15.entry.js} +1 -1
  264. package/www/build/p-ed1cd6b1.js +1 -0
  265. package/www/build/p-f26251dd.entry.js +1 -0
  266. package/www/build/p-f61fd81e.entry.js +1 -0
  267. package/www/build/{p-1727c1c8.entry.js → p-f78d6123.entry.js} +1 -1
  268. package/www/build/p-fbfaa699.entry.js +1 -0
  269. package/www/build/p-fcff1237.css +812 -0
  270. package/www/build/{p-ba29bc12.entry.js → p-fdd91263.entry.js} +1 -1
  271. package/www/build/{p-fe927bf4.entry.js → p-ff4a0f6f.entry.js} +1 -1
  272. package/www/build/web-components-library.esm.js +1 -1
  273. package/www/index.html +6 -70
  274. package/dist/cjs/z-app-switcher_11.cjs.entry.js +0 -377
  275. package/dist/cjs/z-input_2.cjs.entry.js +0 -228
  276. package/dist/esm/z-app-switcher_11.entry.js +0 -363
  277. package/dist/esm/z-input_2.entry.js +0 -223
  278. package/dist/web-components-library/p-0d29d851.entry.js +0 -1
  279. package/dist/web-components-library/p-0e408871.entry.js +0 -1
  280. package/dist/web-components-library/p-0ef6c549.entry.js +0 -1
  281. package/dist/web-components-library/p-20d62443.entry.js +0 -1
  282. package/dist/web-components-library/p-562e2d52.entry.js +0 -1
  283. package/dist/web-components-library/p-5eacbfc7.entry.js +0 -1
  284. package/dist/web-components-library/p-6218514a.entry.js +0 -1
  285. package/dist/web-components-library/p-71accd8e.entry.js +0 -1
  286. package/dist/web-components-library/p-7c6d4440.entry.js +0 -1
  287. package/dist/web-components-library/p-9f5d707a.js +0 -1
  288. package/dist/web-components-library/p-a8875b97.entry.js +0 -16
  289. package/dist/web-components-library/p-e2431b92.entry.js +0 -1
  290. package/www/build/p-0d29d851.entry.js +0 -1
  291. package/www/build/p-0e408871.entry.js +0 -1
  292. package/www/build/p-0ef6c549.entry.js +0 -1
  293. package/www/build/p-20d62443.entry.js +0 -1
  294. package/www/build/p-562e2d52.entry.js +0 -1
  295. package/www/build/p-5eacbfc7.entry.js +0 -1
  296. package/www/build/p-6218514a.entry.js +0 -1
  297. package/www/build/p-71accd8e.entry.js +0 -1
  298. package/www/build/p-7614383b.js +0 -1
  299. package/www/build/p-7c6d4440.entry.js +0 -1
  300. package/www/build/p-88b56b6e.css +0 -1
  301. package/www/build/p-9f5d707a.js +0 -1
  302. package/www/build/p-a8875b97.entry.js +0 -16
  303. package/www/build/p-e2431b92.entry.js +0 -1
@@ -1,126 +1,332 @@
1
- import { Component, Prop, h, Host, State, Listen, Event, } from "@stencil/core";
2
- import classNames from "classnames";
3
- import { PopoverPosition, PopoverBorderRadius, PopoverShadow, KeyboardKeys, } from "../../beans";
1
+ import { Component, Prop, h, Watch, Listen, Element, State, Event, } from "@stencil/core";
2
+ import { PopoverPositions, KeyboardKeys } from "../../beans";
4
3
  import { getElementTree } from "../../utils/utils";
4
+ const documentElement = document.documentElement;
5
+ function getParentElement(element) {
6
+ if (element.parentNode.host) {
7
+ return element.parentNode.host;
8
+ }
9
+ return element.parentNode;
10
+ }
11
+ /**
12
+ * Find the closest scrollable parent of a node.
13
+ *
14
+ * @param {Element} element The node
15
+ */
16
+ function findScrollableParent(element) {
17
+ let parent = getParentElement(element);
18
+ while (parent && parent !== documentElement) {
19
+ const { overflow, overflowX, overflowY } = window.getComputedStyle(parent);
20
+ if (overflow === "hidden" ||
21
+ overflowY === "hidden" ||
22
+ overflowX === "hidden") {
23
+ return parent;
24
+ }
25
+ if ((parent.scrollHeight > parent.clientHeight &&
26
+ overflow !== "visible" &&
27
+ overflowY !== "visible") ||
28
+ (parent.scrollWidth > parent.clientWidth &&
29
+ overflow !== "visible" &&
30
+ overflowX !== "visible")) {
31
+ return parent;
32
+ }
33
+ parent = getParentElement(parent);
34
+ }
35
+ return documentElement;
36
+ }
37
+ /**
38
+ * Calculate computed offset.
39
+ * It includes matrix transformations.
40
+ * @param element The target element.
41
+ * @param targetParentOffset The relative offset parent.
42
+ * @return A client rect object.
43
+ */
44
+ function computeOffset(element, targetParentOffset) {
45
+ const rect = element.getBoundingClientRect();
46
+ const width = rect.width;
47
+ const height = rect.height;
48
+ let top = 0;
49
+ let left = 0;
50
+ let offsetParent = element;
51
+ while (offsetParent && offsetParent != targetParentOffset) {
52
+ left += offsetParent.offsetLeft;
53
+ // document.body sometimes has offsetTop == 0 but still has an
54
+ // offset because of children margins!
55
+ if (offsetParent === document.body) {
56
+ top += offsetParent.getBoundingClientRect().top + window.scrollY;
57
+ }
58
+ else {
59
+ top += offsetParent.offsetTop;
60
+ }
61
+ if (window.DOMMatrix) {
62
+ const style = window.getComputedStyle(offsetParent);
63
+ const transform = style.transform || style.webkitTransform;
64
+ const domMatrix = new DOMMatrix(transform);
65
+ if (domMatrix) {
66
+ left += domMatrix.m41;
67
+ if (offsetParent !== document.body) {
68
+ top += domMatrix.m42;
69
+ }
70
+ }
71
+ }
72
+ if (!offsetParent.offsetParent) {
73
+ break;
74
+ }
75
+ offsetParent = offsetParent.offsetParent;
76
+ }
77
+ let parentWidth;
78
+ let parentHeight;
79
+ if (offsetParent === document.body) {
80
+ parentWidth = window.innerWidth;
81
+ parentHeight = window.innerHeight;
82
+ }
83
+ else {
84
+ parentWidth = offsetParent.offsetWidth;
85
+ parentHeight = offsetParent.offsetHeight;
86
+ }
87
+ const right = parentWidth - left - rect.width;
88
+ const bottom = parentHeight - top - rect.height;
89
+ return { top, right, bottom, left, width, height };
90
+ }
91
+ /**
92
+ * Popover component.
93
+ *
94
+ * @cssprop --z-popover-theme--surface - background color of the popover.
95
+ * @cssprop --z-popover-theme--text - foreground color of the popover.
96
+ * @cssprop --z-popover-padding - padding of the popover.
97
+ * @cssprop --z-popover-shadow-filter - drop-shadow filter of the popover. Defaults to `drop-shadow(0 1px 2px var(--shadow-color-base))`.
98
+ */
5
99
  export class ZPopover {
6
- /**
7
- * Constructor.
8
- */
9
100
  constructor() {
10
- /** [optional] Popover position */
11
- this.position = PopoverPosition["after-up"];
12
- /** [optional] Background color token for popover */
13
- this.backgroundColor = "color-white";
14
- /** [optional] Border radius token for popover */
15
- this.borderRadius = PopoverBorderRadius.small;
16
- /** [optional] Box shadow token for popover */
17
- this.boxShadow = PopoverShadow["shadow-1"];
18
- /** [optional] Show or hide arrow */
101
+ /** Popover position. */
102
+ this.position = PopoverPositions.AUTO;
103
+ /**
104
+ * The open state of the popover.
105
+ */
106
+ this.open = false;
107
+ /**
108
+ * Whether to show popover's arrow.
109
+ */
19
110
  this.showArrow = false;
20
- /** [optional] Sets padding for Popover container */
21
- this.padding = "8px";
22
- this.isVisible = false;
23
- this.popoverPosition = this.position;
24
- this.handleKeyDown = this.handleKeyDown.bind(this);
111
+ /**
112
+ * Whether to center the popup on the main side (according to "position").
113
+ */
114
+ this.center = false;
115
+ /**
116
+ * Whether the popover should be closed when the user clicks outside of it or hit "ESC".
117
+ */
118
+ this.closable = true;
25
119
  }
26
- emitTriggerClick() {
27
- this.triggerClick.emit({
28
- isVisible: this.isVisible,
29
- });
120
+ closePopoverWithKeyboard(e) {
121
+ if (this.closable && e.key === KeyboardKeys.ESC) {
122
+ this.open = false;
123
+ }
30
124
  }
31
- openPopover() {
32
- const width = document.body.clientWidth;
33
- const height = window.innerHeight;
34
- const rect = this.popoverElem.getBoundingClientRect();
35
- const l = rect.left;
36
- const r = rect.right;
37
- const t = rect.top;
38
- const b = rect.bottom;
39
- let firstSide = this.position.split("-")[0];
40
- let secondSide = this.position.split("-")[1];
41
- // If top is outside viewport
42
- if (t < 0) {
43
- if (this.position.startsWith("above")) {
44
- firstSide = "below";
125
+ handleOutsideClick(e) {
126
+ if (!this.closable) {
127
+ return;
128
+ }
129
+ const tree = getElementTree(e.target);
130
+ const parent = tree.find((elem) => elem.nodeName.toLowerCase() === "z-popover");
131
+ if (!parent) {
132
+ this.open = false;
133
+ this.positionChange.emit({ position: this.currentPosition });
134
+ }
135
+ }
136
+ validatePosition(newValue) {
137
+ if (newValue &&
138
+ Object.values(PopoverPositions).every((position) => newValue !== position)) {
139
+ this.position = PopoverPositions.AUTO;
140
+ }
141
+ this.currentPosition = this.position;
142
+ this.positionChange.emit({ position: this.currentPosition });
143
+ }
144
+ /**
145
+ * Setup popover behaviors on opening.
146
+ */
147
+ onOpen() {
148
+ cancelAnimationFrame(this.animationFrameRequestId);
149
+ if (this.open) {
150
+ const setPosition = () => {
151
+ if (this.open) {
152
+ this.setPosition();
153
+ this.animationFrameRequestId = requestAnimationFrame(setPosition);
154
+ }
155
+ };
156
+ setPosition();
157
+ }
158
+ else if (this.host.hasAttribute('current-position')) {
159
+ this.host.removeAttribute('current-position');
160
+ this.currentPosition = undefined;
161
+ }
162
+ this.openChange.emit({ open: this.open });
163
+ }
164
+ disconnectedCallback() {
165
+ cancelAnimationFrame(this.animationFrameRequestId);
166
+ }
167
+ /**
168
+ * Set the position of the popover.
169
+ */
170
+ setPosition() {
171
+ let element;
172
+ if (typeof this.bindTo === "string") {
173
+ element = this.host.ownerDocument.querySelector(this.bindTo);
174
+ }
175
+ else if (this.bindTo) {
176
+ element = this.bindTo;
177
+ }
178
+ else {
179
+ element = this.host.parentElement;
180
+ }
181
+ if (!element) {
182
+ return;
183
+ }
184
+ const scrollContainer = findScrollableParent(element);
185
+ const scrollingBoundingRect = scrollContainer.getBoundingClientRect();
186
+ const offsetContainer = this.host.offsetParent;
187
+ const relativeBoundingRect = offsetContainer
188
+ ? computeOffset(offsetContainer, scrollContainer)
189
+ : { top: 0, right: 0, bottom: 0, left: 0 };
190
+ const boundingRect = computeOffset(element, scrollContainer);
191
+ const top = boundingRect.top - scrollContainer.scrollTop;
192
+ const bottom = scrollingBoundingRect.height -
193
+ (boundingRect.top + boundingRect.height) +
194
+ scrollContainer.scrollTop;
195
+ const left = boundingRect.left - scrollContainer.scrollLeft;
196
+ const right = scrollingBoundingRect.width -
197
+ (boundingRect.left + boundingRect.width) +
198
+ scrollContainer.scrollLeft;
199
+ const overflowBottom = Math.max(0, scrollingBoundingRect.top +
200
+ scrollingBoundingRect.height -
201
+ window.innerHeight);
202
+ const overflowRight = Math.max(0, scrollingBoundingRect.left +
203
+ scrollingBoundingRect.width -
204
+ window.innerWidth);
205
+ const availableTop = Math.min(top, top + scrollingBoundingRect.top);
206
+ const availableBottom = Math.min(bottom, bottom - overflowBottom);
207
+ const availableLeft = Math.min(left, left + scrollingBoundingRect.left);
208
+ const availableRight = Math.min(right, right - overflowRight);
209
+ const availableHeight = availableTop + availableBottom + boundingRect.height;
210
+ const availableWidth = availableLeft + availableRight + boundingRect.width;
211
+ let position = this.currentPosition;
212
+ const positions = [];
213
+ if (this.position === PopoverPositions.AUTO) {
214
+ /**
215
+ * The `AUTO` position tries to place the popover in the 'safest' area,
216
+ * where there's more space available.
217
+ */
218
+ if (availableLeft / availableWidth > 0.6) {
219
+ positions.push(PopoverPositions.LEFT);
45
220
  }
46
- else {
47
- secondSide = "down";
221
+ else if (availableLeft / availableWidth < 0.4) {
222
+ positions.push(PopoverPositions.RIGHT);
48
223
  }
49
- }
50
- // If bottom is outside viewport
51
- if (b > height) {
52
- if (this.position.startsWith("below")) {
53
- firstSide = "above";
224
+ if (availableTop / availableHeight > 0.9) {
225
+ positions.unshift(PopoverPositions.TOP);
54
226
  }
55
- else {
56
- secondSide = "up";
227
+ else if (availableTop / availableHeight > 0.6) {
228
+ positions.push(PopoverPositions.TOP);
57
229
  }
58
- }
59
- // If right is outside viewport
60
- if (r > width) {
61
- if (this.position.startsWith("above") ||
62
- this.position.startsWith("below")) {
63
- secondSide = "left";
230
+ else if (availableTop / availableHeight < 0.1) {
231
+ positions.unshift(PopoverPositions.BOTTOM);
64
232
  }
65
233
  else {
66
- firstSide = "before";
234
+ positions.push(PopoverPositions.BOTTOM);
67
235
  }
236
+ position = positions.join("_");
68
237
  }
69
- // If left is outside viewport
70
- if (l < 0) {
71
- if (this.position.startsWith("above") ||
72
- this.position.startsWith("below")) {
73
- secondSide = "right";
238
+ const style = this.host.style;
239
+ style.position = "absolute";
240
+ const offsetTop = boundingRect.top - relativeBoundingRect.top;
241
+ const offsetRight = boundingRect.right - relativeBoundingRect.right;
242
+ const offsetBottom = boundingRect.bottom - relativeBoundingRect.bottom;
243
+ const offsetLeft = boundingRect.left - relativeBoundingRect.left;
244
+ const offsetModifier = this.center ? 0.5 : 0;
245
+ const sizeModifier = this.center ? 0.5 : 0;
246
+ if (position === PopoverPositions.TOP ||
247
+ position === PopoverPositions.TOP_RIGHT) {
248
+ style.top = "auto";
249
+ style.right = "auto";
250
+ style.bottom = `${offsetBottom + boundingRect.height}px`;
251
+ style.left = `${offsetLeft + boundingRect.width * offsetModifier}px`;
252
+ style.maxHeight = `${availableTop}px`;
253
+ if (position === PopoverPositions.TOP_RIGHT) {
254
+ style.maxWidth = `${availableRight + boundingRect.width * sizeModifier}px`;
74
255
  }
75
- else {
76
- firstSide = "after";
256
+ }
257
+ else if (position === PopoverPositions.TOP_LEFT) {
258
+ style.top = "auto";
259
+ style.right = `${offsetRight + boundingRect.width * offsetModifier}px`;
260
+ style.bottom = `${offsetBottom + boundingRect.height}px`;
261
+ style.left = "auto";
262
+ style.maxWidth = `${availableLeft}px`;
263
+ style.maxHeight = `${availableTop}px`;
264
+ }
265
+ else if (position === PopoverPositions.BOTTOM ||
266
+ position === PopoverPositions.BOTTOM_RIGHT) {
267
+ style.top = `${offsetTop + boundingRect.height}px`;
268
+ style.right = "auto";
269
+ style.bottom = "auto";
270
+ style.left = `${offsetLeft + boundingRect.width * offsetModifier}px`;
271
+ style.maxHeight = `${availableBottom}px`;
272
+ if (position === PopoverPositions.BOTTOM_RIGHT) {
273
+ style.maxWidth = `${availableRight + boundingRect.width * sizeModifier}px`;
77
274
  }
78
275
  }
79
- this.popoverPosition = PopoverPosition[`${firstSide}-${secondSide}`];
80
- this.isVisible = true;
81
- }
82
- closePopover() {
83
- this.popoverPosition = this.position;
84
- this.isVisible = false;
85
- }
86
- closePopoverWithKeyboard(e) {
87
- if (e.key === KeyboardKeys.ESC) {
88
- this.closePopover();
276
+ else if (position === PopoverPositions.BOTTOM_LEFT) {
277
+ style.top = `${offsetTop + boundingRect.height}px`;
278
+ style.right = `${offsetRight + boundingRect.width * offsetModifier}px`;
279
+ style.bottom = "auto";
280
+ style.left = "auto";
281
+ style.maxWidth = `${availableLeft}px`;
282
+ style.maxHeight = `${availableBottom}px`;
89
283
  }
90
- }
91
- handleClick(event) {
92
- this.isVisible ? this.closePopover() : this.openPopover();
93
- this.emitTriggerClick();
94
- event.stopPropagation();
95
- }
96
- handleKeyDown(event) {
97
- if (event.code === KeyboardKeys.ENTER) {
98
- this.isVisible ? this.closePopover() : this.openPopover();
284
+ else if (position === PopoverPositions.RIGHT ||
285
+ position === PopoverPositions.RIGHT_BOTTOM) {
286
+ style.top = `${offsetTop + boundingRect.height * offsetModifier}px`;
287
+ style.right = "auto";
288
+ style.bottom = "auto";
289
+ style.left = `${offsetLeft + boundingRect.width}px`;
290
+ style.maxWidth = `${availableRight}px`;
291
+ style.maxHeight = `${availableBottom + boundingRect.height * sizeModifier}px`;
99
292
  }
100
- }
101
- handleOutsideClick(e) {
102
- const tree = getElementTree(e.target);
103
- const parent = tree.find((elem) => elem.nodeName.toLowerCase() === "z-popover");
104
- if (!parent) {
105
- this.closePopover();
293
+ else if (position === PopoverPositions.RIGHT_TOP) {
294
+ style.top = "auto";
295
+ style.right = "auto";
296
+ style.bottom = `${offsetBottom + boundingRect.height * offsetModifier}px`;
297
+ style.left = `${offsetLeft + boundingRect.width}px`;
298
+ style.maxWidth = `${availableRight}px`;
299
+ style.maxHeight = `${availableTop + boundingRect.height * sizeModifier}px`;
106
300
  }
301
+ else if (position === PopoverPositions.LEFT ||
302
+ position === PopoverPositions.LEFT_BOTTOM) {
303
+ style.top = `${offsetTop + boundingRect.height * offsetModifier}px`;
304
+ style.right = `${offsetRight + boundingRect.width}px`;
305
+ style.bottom = "auto";
306
+ style.left = "auto";
307
+ style.maxWidth = `${availableLeft}px`;
308
+ style.maxHeight = `${availableBottom + boundingRect.height * sizeModifier}px`;
309
+ }
310
+ else if (position === PopoverPositions.LEFT_TOP) {
311
+ style.top = "auto";
312
+ style.right = `${offsetRight + boundingRect.width}px`;
313
+ style.bottom = `${offsetBottom + boundingRect.height * offsetModifier}px`;
314
+ style.left = "auto";
315
+ style.maxWidth = `${availableLeft}px`;
316
+ style.maxHeight = `${availableTop + boundingRect.height * sizeModifier}px`;
317
+ }
318
+ this.currentPosition = position || this.position;
319
+ this.host.setAttribute('current-position', this.currentPosition);
320
+ }
321
+ componentWillLoad() {
322
+ this.validatePosition(this.position);
323
+ this.onOpen();
107
324
  }
108
325
  render() {
109
- return (h(Host, { onKeyDown: this.handleKeyDown },
110
- h("div", { tabindex: "0", onClick: (event) => this.handleClick(event), onKeyDown: (event) => {
111
- if (event.key === KeyboardKeys.ENTER) {
112
- this.handleClick(event);
113
- }
114
- } },
115
- h("slot", { name: "trigger" })),
116
- h("div", { ref: (e) => (this.popoverElem = e), class: classNames("popover-content-container", this.popoverPosition, `border-radius-${this.borderRadius}`, this.boxShadow, { "show-arrow": this.showArrow }, { visible: this.isVisible }), style: {
117
- backgroundColor: `var(--${this.backgroundColor})`,
118
- padding: this.padding,
119
- } },
120
- h("slot", { name: "popover" }))));
326
+ return h("slot", null);
121
327
  }
122
328
  static get is() { return "z-popover"; }
123
- static get encapsulation() { return "scoped"; }
329
+ static get encapsulation() { return "shadow"; }
124
330
  static get originalStyleUrls() { return {
125
331
  "$": ["styles.css"]
126
332
  }; }
@@ -130,55 +336,54 @@ export class ZPopover {
130
336
  static get properties() { return {
131
337
  "position": {
132
338
  "type": "string",
133
- "mutable": false,
339
+ "mutable": true,
134
340
  "complexType": {
135
- "original": "PopoverPosition",
136
- "resolved": "typeof PopoverPosition[\"above-center\"] | typeof PopoverPosition[\"above-left\"] | typeof PopoverPosition[\"above-right\"] | typeof PopoverPosition[\"after-center\"] | typeof PopoverPosition[\"after-down\"] | typeof PopoverPosition[\"after-up\"] | typeof PopoverPosition[\"before-center\"] | typeof PopoverPosition[\"before-down\"] | typeof PopoverPosition[\"before-up\"] | typeof PopoverPosition[\"below-center\"] | typeof PopoverPosition[\"below-left\"] | typeof PopoverPosition[\"below-right\"]",
341
+ "original": "PopoverPositions",
342
+ "resolved": "PopoverPositions.AUTO | PopoverPositions.BOTTOM | PopoverPositions.BOTTOM_LEFT | PopoverPositions.BOTTOM_RIGHT | PopoverPositions.LEFT | PopoverPositions.LEFT_BOTTOM | PopoverPositions.LEFT_TOP | PopoverPositions.RIGHT | PopoverPositions.RIGHT_BOTTOM | PopoverPositions.RIGHT_TOP | PopoverPositions.TOP | PopoverPositions.TOP_LEFT | PopoverPositions.TOP_RIGHT",
137
343
  "references": {
138
- "PopoverPosition": {
344
+ "PopoverPositions": {
139
345
  "location": "import",
140
346
  "path": "../../beans"
141
347
  }
142
348
  }
143
349
  },
144
350
  "required": false,
145
- "optional": true,
351
+ "optional": false,
146
352
  "docs": {
147
353
  "tags": [],
148
- "text": "[optional] Popover position"
354
+ "text": "Popover position."
149
355
  },
150
356
  "attribute": "position",
151
- "reflect": false,
152
- "defaultValue": "PopoverPosition[\"after-up\"]"
357
+ "reflect": true,
358
+ "defaultValue": "PopoverPositions.AUTO"
153
359
  },
154
- "backgroundColor": {
155
- "type": "string",
156
- "mutable": false,
360
+ "open": {
361
+ "type": "boolean",
362
+ "mutable": true,
157
363
  "complexType": {
158
- "original": "string",
159
- "resolved": "string",
364
+ "original": "boolean",
365
+ "resolved": "boolean",
160
366
  "references": {}
161
367
  },
162
368
  "required": false,
163
- "optional": true,
369
+ "optional": false,
164
370
  "docs": {
165
371
  "tags": [],
166
- "text": "[optional] Background color token for popover"
372
+ "text": "The open state of the popover."
167
373
  },
168
- "attribute": "background-color",
169
- "reflect": false,
170
- "defaultValue": "\"color-white\""
374
+ "attribute": "open",
375
+ "reflect": true,
376
+ "defaultValue": "false"
171
377
  },
172
- "borderRadius": {
378
+ "bindTo": {
173
379
  "type": "string",
174
380
  "mutable": false,
175
381
  "complexType": {
176
- "original": "PopoverBorderRadius",
177
- "resolved": "PopoverBorderRadius.medium | PopoverBorderRadius.none | PopoverBorderRadius.small",
382
+ "original": "string | HTMLElement",
383
+ "resolved": "HTMLElement | string",
178
384
  "references": {
179
- "PopoverBorderRadius": {
180
- "location": "import",
181
- "path": "../../beans"
385
+ "HTMLElement": {
386
+ "location": "global"
182
387
  }
183
388
  }
184
389
  },
@@ -186,36 +391,30 @@ export class ZPopover {
186
391
  "optional": true,
187
392
  "docs": {
188
393
  "tags": [],
189
- "text": "[optional] Border radius token for popover"
394
+ "text": "The selector or the element bound with the popover."
190
395
  },
191
- "attribute": "border-radius",
192
- "reflect": false,
193
- "defaultValue": "PopoverBorderRadius.small"
396
+ "attribute": "bind-to",
397
+ "reflect": false
194
398
  },
195
- "boxShadow": {
196
- "type": "string",
399
+ "showArrow": {
400
+ "type": "boolean",
197
401
  "mutable": false,
198
402
  "complexType": {
199
- "original": "PopoverShadow",
200
- "resolved": "typeof PopoverShadow[\"shadow-1\"] | typeof PopoverShadow[\"shadow-12\"] | typeof PopoverShadow[\"shadow-16\"] | typeof PopoverShadow[\"shadow-2\"] | typeof PopoverShadow[\"shadow-24\"] | typeof PopoverShadow[\"shadow-3\"] | typeof PopoverShadow[\"shadow-4\"] | typeof PopoverShadow[\"shadow-6\"] | typeof PopoverShadow[\"shadow-8\"]",
201
- "references": {
202
- "PopoverShadow": {
203
- "location": "import",
204
- "path": "../../beans"
205
- }
206
- }
403
+ "original": "boolean",
404
+ "resolved": "boolean",
405
+ "references": {}
207
406
  },
208
407
  "required": false,
209
- "optional": true,
408
+ "optional": false,
210
409
  "docs": {
211
410
  "tags": [],
212
- "text": "[optional] Box shadow token for popover"
411
+ "text": "Whether to show popover's arrow."
213
412
  },
214
- "attribute": "box-shadow",
215
- "reflect": false,
216
- "defaultValue": "PopoverShadow[\"shadow-1\"]"
413
+ "attribute": "show-arrow",
414
+ "reflect": true,
415
+ "defaultValue": "false"
217
416
  },
218
- "showArrow": {
417
+ "center": {
219
418
  "type": "boolean",
220
419
  "mutable": false,
221
420
  "complexType": {
@@ -224,47 +423,61 @@ export class ZPopover {
224
423
  "references": {}
225
424
  },
226
425
  "required": false,
227
- "optional": true,
426
+ "optional": false,
228
427
  "docs": {
229
428
  "tags": [],
230
- "text": "[optional] Show or hide arrow"
429
+ "text": "Whether to center the popup on the main side (according to \"position\")."
231
430
  },
232
- "attribute": "show-arrow",
233
- "reflect": false,
431
+ "attribute": "center",
432
+ "reflect": true,
234
433
  "defaultValue": "false"
235
434
  },
236
- "padding": {
237
- "type": "string",
435
+ "closable": {
436
+ "type": "boolean",
238
437
  "mutable": false,
239
438
  "complexType": {
240
- "original": "string",
241
- "resolved": "string",
439
+ "original": "boolean",
440
+ "resolved": "boolean",
242
441
  "references": {}
243
442
  },
244
443
  "required": false,
245
- "optional": true,
444
+ "optional": false,
246
445
  "docs": {
247
446
  "tags": [],
248
- "text": "[optional] Sets padding for Popover container"
447
+ "text": "Whether the popover should be closed when the user clicks outside of it or hit \"ESC\"."
249
448
  },
250
- "attribute": "padding",
449
+ "attribute": "closable",
251
450
  "reflect": false,
252
- "defaultValue": "\"8px\""
451
+ "defaultValue": "true"
253
452
  }
254
453
  }; }
255
454
  static get states() { return {
256
- "isVisible": {},
257
- "popoverPosition": {}
455
+ "currentPosition": {}
258
456
  }; }
259
457
  static get events() { return [{
260
- "method": "triggerClick",
261
- "name": "triggerClick",
458
+ "method": "positionChange",
459
+ "name": "positionChange",
262
460
  "bubbles": true,
263
461
  "cancelable": true,
264
462
  "composed": true,
265
463
  "docs": {
266
464
  "tags": [],
267
- "text": "Emitted on popover click, returns isVisible state"
465
+ "text": "Position change event."
466
+ },
467
+ "complexType": {
468
+ "original": "any",
469
+ "resolved": "any",
470
+ "references": {}
471
+ }
472
+ }, {
473
+ "method": "openChange",
474
+ "name": "openChange",
475
+ "bubbles": true,
476
+ "cancelable": true,
477
+ "composed": true,
478
+ "docs": {
479
+ "tags": [],
480
+ "text": "Open change event."
268
481
  },
269
482
  "complexType": {
270
483
  "original": "any",
@@ -272,13 +485,15 @@ export class ZPopover {
272
485
  "references": {}
273
486
  }
274
487
  }]; }
275
- static get listeners() { return [{
276
- "name": "closePopover",
277
- "method": "closePopover",
278
- "target": undefined,
279
- "capture": false,
280
- "passive": false
488
+ static get elementRef() { return "host"; }
489
+ static get watchers() { return [{
490
+ "propName": "position",
491
+ "methodName": "validatePosition"
281
492
  }, {
493
+ "propName": "open",
494
+ "methodName": "onOpen"
495
+ }]; }
496
+ static get listeners() { return [{
282
497
  "name": "keyup",
283
498
  "method": "closePopoverWithKeyboard",
284
499
  "target": "window",