@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
@@ -0,0 +1,270 @@
1
+ import { r as registerInstance, c as createEvent, h, H as Host, g as getElement } from './index-90e18641.js';
2
+ import { P as PopoverPositions } from './index-c1ce8cab.js';
3
+
4
+ const stylesCss = ":host{--z-tooltip-theme--surface:var(--color-surface01);--z-tooltip-theme--text:var(--color-text01);--arrow-size:6px;--edge-offset:calc(-1 * (var(--arrow-size) + calc(var(--space-unit) * 2)));position:relative;display:none;align-items:center;justify-content:center;padding:var(--space-unit);min-width:calc(var(--space-unit) * 8);min-height:calc(var(--space-unit) * 4);color:var(--z-tooltip-theme--text);fill:currentColor;font-family:var(--font-family-sans);text-align:center;border-radius:var(--border-radius-small);background:var(--z-tooltip-theme--surface);filter:drop-shadow(0 4px 8px var(--shadow-color-base));will-change:filter}:host(.legacy){display:inline-flex;padding:calc(var(--space-unit) * 2);min-width:auto;min-height:auto;max-width:200px;font-style:italic;line-height:16px;letter-spacing:0.32px;font-size:12px;border:var(--border-size-small) solid var(--gray200);border-radius:var(--border-radius);filter:drop-shadow(0px 0px 2px rgba(0, 0, 0, 0.08))}:host(.legacy)::before{--arrow-size:14px}:host([position])::before{--arrow-edge-offset:calc(100% - var(--arrow-size) - var(--space-unit));--arrow-center-x-offset:calc(50% - calc(var(--arrow-size) / 2));--arrow-center-y-offset:calc(100% - calc(var(--arrow-size) / 2));content:'';position:absolute;width:var(--arrow-size);height:var(--arrow-size);background:inherit;transform:rotate(45deg)}:host([open][style*='top:']),:host([open][style*='inset:']){display:inline-flex}:host([position^='top']){margin-bottom:var(--space-unit)}:host([position='right']){margin-left:var(--space-unit)}:host([position='top_right']),:host([position='bottom_right']){margin-left:var(--edge-offset)}:host([position^='bottom']){margin-top:var(--space-unit)}:host([position='left']){margin-right:var(--space-unit)}:host([position='top_left']),:host([position='bottom_left']){margin-right:var(--edge-offset)}:host([position^='top'])::before{top:var(--arrow-center-y-offset)}:host([position^='bottom'])::before{bottom:var(--arrow-center-y-offset)}:host([position='top'])::before,:host([position='bottom'])::before{left:var(--arrow-center-x-offset)}:host([position='right'])::before,:host([position='left'])::before{top:var(--arrow-center-x-offset)}:host([position='right'])::before{right:var(--arrow-center-y-offset)}:host([position='top_right'])::before,:host([position='bottom_right'])::before{right:var(--arrow-edge-offset)}:host([position='left'])::before{left:var(--arrow-center-y-offset)}:host([position='top_left'])::before,:host([position='bottom_left'])::before{left:var(--arrow-edge-offset)}::slotted(*){flex:1 auto;overflow:auto}";
5
+
6
+ const documentElement = document.documentElement;
7
+ /**
8
+ * Find the closest scrollable parent of a node.
9
+ *
10
+ * @param {Element} element The node
11
+ */
12
+ function findScrollableParent(element) {
13
+ let parent = element.parentNode;
14
+ while (parent && parent !== documentElement) {
15
+ const { overflow, overflowX, overflowY } = window.getComputedStyle(parent);
16
+ if (overflow === 'hidden' ||
17
+ overflowY === 'hidden' ||
18
+ overflowX === 'hidden') {
19
+ return parent;
20
+ }
21
+ if ((parent.scrollHeight > parent.clientHeight && overflow !== 'visible' && overflowY !== 'visible') ||
22
+ (parent.scrollWidth > parent.clientWidth && overflow !== 'visible' && overflowX !== 'visible')) {
23
+ return parent;
24
+ }
25
+ parent = parent.parentNode;
26
+ }
27
+ return documentElement;
28
+ }
29
+ /**
30
+ * Calculate computed offset.
31
+ * It includes matrix transformations.
32
+ * @param element The target element.
33
+ * @param targetParentOffset The relative offset parent.
34
+ * @return A client rect object.
35
+ */
36
+ function computeOffset(element, targetParentOffset) {
37
+ const rect = element.getBoundingClientRect();
38
+ const width = rect.width;
39
+ const height = rect.height;
40
+ let top = 0;
41
+ let left = 0;
42
+ let offsetParent = element;
43
+ while (offsetParent && offsetParent != targetParentOffset) {
44
+ left += offsetParent.offsetLeft;
45
+ // document.body sometimes has offsetTop == 0 but still has an
46
+ // offset because of children margins!
47
+ if (offsetParent === document.body) {
48
+ top += offsetParent.getBoundingClientRect().top + window.scrollY;
49
+ }
50
+ else {
51
+ top += offsetParent.offsetTop;
52
+ }
53
+ if (window.DOMMatrix) {
54
+ const style = window.getComputedStyle(offsetParent);
55
+ const transform = style.transform || style.webkitTransform;
56
+ const domMatrix = new DOMMatrix(transform);
57
+ if (domMatrix) {
58
+ left += domMatrix.m41;
59
+ if (offsetParent !== document.body) {
60
+ top += domMatrix.m42;
61
+ }
62
+ }
63
+ }
64
+ if (!offsetParent.offsetParent) {
65
+ break;
66
+ }
67
+ offsetParent = offsetParent.offsetParent;
68
+ }
69
+ let parentWidth;
70
+ let parentHeight;
71
+ if (offsetParent === document.body) {
72
+ parentWidth = window.innerWidth;
73
+ parentHeight = window.innerHeight;
74
+ }
75
+ else {
76
+ parentWidth = offsetParent.offsetWidth;
77
+ parentHeight = offsetParent.offsetHeight;
78
+ }
79
+ const right = parentWidth - left - rect.width;
80
+ const bottom = parentHeight - top - rect.height;
81
+ return { top, right, bottom, left, width, height };
82
+ }
83
+ const ZTooltipDeprecated = class {
84
+ constructor(hostRef) {
85
+ registerInstance(this, hostRef);
86
+ this.positionChange = createEvent(this, "positionChange", 7);
87
+ /** Tooltip position. */
88
+ this.type = PopoverPositions.AUTO;
89
+ /**
90
+ * The open state of the tooltip.
91
+ */
92
+ this.open = false;
93
+ }
94
+ validateType(newValue) {
95
+ if (newValue &&
96
+ Object
97
+ .values(PopoverPositions)
98
+ .every((position) => newValue !== position)) {
99
+ this.type = PopoverPositions.AUTO;
100
+ }
101
+ }
102
+ onPositionChange() {
103
+ this.positionChange.emit({ position: this.position });
104
+ }
105
+ disconnectedCallback() {
106
+ cancelAnimationFrame(this.animationFrameRequestId);
107
+ }
108
+ /**
109
+ * Setup tooltip behaviors on opening.
110
+ */
111
+ onOpen() {
112
+ cancelAnimationFrame(this.animationFrameRequestId);
113
+ if (this.content) {
114
+ return;
115
+ }
116
+ if (this.open) {
117
+ const setPosition = () => {
118
+ if (this.open) {
119
+ this.setPosition();
120
+ this.animationFrameRequestId = requestAnimationFrame(setPosition);
121
+ }
122
+ };
123
+ setPosition();
124
+ }
125
+ else {
126
+ const style = this.host.style;
127
+ style.removeProperty("top");
128
+ style.removeProperty("right");
129
+ style.removeProperty("bottom");
130
+ style.removeProperty("left");
131
+ }
132
+ }
133
+ /**
134
+ * Set the position of the tooltip.
135
+ */
136
+ setPosition() {
137
+ let element;
138
+ if (typeof this.bindTo === "string") {
139
+ element = this.host.ownerDocument.querySelector(this.bindTo);
140
+ }
141
+ else if (this.bindTo) {
142
+ element = this.bindTo;
143
+ }
144
+ else {
145
+ element = this.host.parentElement;
146
+ }
147
+ if (!element) {
148
+ return;
149
+ }
150
+ const scrollContainer = findScrollableParent(element);
151
+ const scrollingBoundingRect = scrollContainer.getBoundingClientRect();
152
+ const offsetContainer = this.host.offsetParent;
153
+ const relativeBoundingRect = offsetContainer ? computeOffset(offsetContainer, scrollContainer) : { top: 0, right: 0, bottom: 0, left: 0 };
154
+ const boundingRect = computeOffset(element, scrollContainer);
155
+ const top = boundingRect.top - scrollContainer.scrollTop;
156
+ const bottom = scrollingBoundingRect.height - (boundingRect.top + boundingRect.height) + scrollContainer.scrollTop;
157
+ const left = boundingRect.left - scrollContainer.scrollLeft;
158
+ const right = scrollingBoundingRect.width - (boundingRect.left + boundingRect.width) + scrollContainer.scrollLeft;
159
+ const overflowBottom = Math.max(0, scrollingBoundingRect.top + scrollingBoundingRect.height - window.innerHeight);
160
+ const overflowRight = Math.max(0, scrollingBoundingRect.left + scrollingBoundingRect.width - window.innerWidth);
161
+ const availableTop = Math.min(top, top + scrollingBoundingRect.top);
162
+ const availableBottom = Math.min(bottom, bottom - overflowBottom);
163
+ const availableLeft = Math.min(left, left + scrollingBoundingRect.left);
164
+ const availableRight = Math.min(right, right - overflowRight);
165
+ const availableHeight = availableTop + availableBottom + boundingRect.height;
166
+ const availableWidth = availableLeft + availableRight + boundingRect.width;
167
+ let position = this.type;
168
+ if (position === PopoverPositions.AUTO) {
169
+ /**
170
+ * The `AUTO` position tries to place the tooltip in the "safest" area,
171
+ * where there's more space available.
172
+ */
173
+ const positions = [];
174
+ if (availableTop / availableHeight > 0.9) {
175
+ positions.unshift(PopoverPositions.TOP);
176
+ }
177
+ else if (availableTop / availableHeight > 0.6) {
178
+ positions.push(PopoverPositions.TOP);
179
+ }
180
+ else if (availableTop / availableHeight < 0.1) {
181
+ positions.unshift(PopoverPositions.BOTTOM);
182
+ }
183
+ else {
184
+ positions.push(PopoverPositions.BOTTOM);
185
+ }
186
+ if (availableLeft / availableWidth > 0.6) {
187
+ positions.push(PopoverPositions.LEFT);
188
+ }
189
+ else if (availableLeft / availableWidth < 0.4) {
190
+ positions.push(PopoverPositions.RIGHT);
191
+ }
192
+ position = positions.join("_");
193
+ }
194
+ const style = this.host.style;
195
+ if (!this.content) {
196
+ style.position = "absolute";
197
+ }
198
+ const offsetTop = boundingRect.top - relativeBoundingRect.top;
199
+ const offsetRight = boundingRect.right - relativeBoundingRect.right;
200
+ const offsetBottom = boundingRect.bottom - relativeBoundingRect.bottom;
201
+ const offsetLeft = boundingRect.left - relativeBoundingRect.left;
202
+ if (position === PopoverPositions.TOP ||
203
+ position === PopoverPositions.TOP_RIGHT ||
204
+ position === PopoverPositions.TOP_LEFT) {
205
+ style.top = "auto";
206
+ style.bottom = `${offsetBottom + boundingRect.height}px`;
207
+ }
208
+ if (position === PopoverPositions.BOTTOM ||
209
+ position === PopoverPositions.BOTTOM_RIGHT ||
210
+ position === PopoverPositions.BOTTOM_LEFT) {
211
+ style.top = `${offsetTop + boundingRect.height}px`;
212
+ style.bottom = "auto";
213
+ }
214
+ if (position === PopoverPositions.TOP ||
215
+ position === PopoverPositions.BOTTOM) {
216
+ style.left = `${offsetLeft +
217
+ (boundingRect.width / 2) -
218
+ (this.host.clientWidth / 2)}px`;
219
+ }
220
+ if (position === PopoverPositions.TOP_RIGHT ||
221
+ position === PopoverPositions.BOTTOM_RIGHT) {
222
+ style.right = "auto";
223
+ style.left = `${offsetLeft + boundingRect.width}px`;
224
+ }
225
+ if (position === PopoverPositions.TOP_LEFT ||
226
+ position === PopoverPositions.BOTTOM_LEFT) {
227
+ style.left = "auto";
228
+ style.right = `${offsetRight + boundingRect.width}px`;
229
+ }
230
+ if (position === PopoverPositions.RIGHT ||
231
+ position === PopoverPositions.LEFT) {
232
+ style.top = `${offsetTop +
233
+ (boundingRect.height / 2) -
234
+ (this.host.clientHeight / 2)}px`;
235
+ style.bottom = "auto";
236
+ }
237
+ if (position === PopoverPositions.RIGHT) {
238
+ style.right = "auto";
239
+ style.left = `${offsetLeft + boundingRect.width}px`;
240
+ }
241
+ if (position === PopoverPositions.LEFT) {
242
+ style.left = "auto";
243
+ style.right = `${offsetRight + boundingRect.width}px`;
244
+ }
245
+ this.position = position;
246
+ }
247
+ componentWillLoad() {
248
+ // Keep backward compatibility
249
+ if (this.content) {
250
+ this.open = true;
251
+ }
252
+ this.validateType(this.type);
253
+ this.onOpen();
254
+ }
255
+ render() {
256
+ if (this.content) {
257
+ return (h(Host, { class: "legacy", position: this.type }, this.content));
258
+ }
259
+ return (h(Host, { position: this.position }, h("slot", null)));
260
+ }
261
+ get host() { return getElement(this); }
262
+ static get watchers() { return {
263
+ "type": ["validateType"],
264
+ "position": ["onPositionChange"],
265
+ "open": ["onOpen"]
266
+ }; }
267
+ };
268
+ ZTooltipDeprecated.style = stylesCss;
269
+
270
+ export { ZTooltipDeprecated as z_tooltip_deprecated };
@@ -1,269 +1,26 @@
1
- import { r as registerInstance, c as createEvent, h, H as Host, g as getElement } from './index-90e18641.js';
2
- import { k as TooltipPosition } from './index-46ca649a.js';
1
+ import { r as registerInstance, h } from './index-90e18641.js';
2
+ import { P as PopoverPositions } from './index-c1ce8cab.js';
3
3
 
4
- const stylesCss = ":host{--z-tooltip-theme--surface:var(--color-surface01);--z-tooltip-theme--text:var(--color-text01);--arrow-size:6px;--edge-offset:calc(-1 * (var(--arrow-size) + calc(var(--space-unit) * 2)));position:relative;display:none;align-items:center;justify-content:center;padding:var(--space-unit);min-width:calc(var(--space-unit) * 8);min-height:calc(var(--space-unit) * 4);color:var(--z-tooltip-theme--text);fill:currentColor;font-family:var(--font-family-sans);text-align:center;border-radius:var(--border-radius-small);background:var(--z-tooltip-theme--surface);filter:drop-shadow(0 4px 8px var(--shadow-color-base));will-change:filter}:host(.legacy){display:inline-flex;padding:calc(var(--space-unit) * 2);min-width:auto;min-height:auto;max-width:200px;font-style:italic;line-height:16px;letter-spacing:0.32px;font-size:12px;border:var(--border-size-small) solid var(--gray200);border-radius:var(--border-radius);filter:drop-shadow(0px 0px 2px rgba(0, 0, 0, 0.08))}:host(.legacy)::before{--arrow-size:14px}:host([position])::before{--arrow-edge-offset:calc(100% - var(--arrow-size) - var(--space-unit));--arrow-center-x-offset:calc(50% - calc(var(--arrow-size) / 2));--arrow-center-y-offset:calc(100% - calc(var(--arrow-size) / 2));content:'';position:absolute;width:var(--arrow-size);height:var(--arrow-size);background:inherit;transform:rotate(45deg)}:host([open][style*='top:']),:host([open][style*='inset:']){display:inline-flex}:host([position^='top']){margin-bottom:var(--space-unit)}:host([position='right']){margin-left:var(--space-unit)}:host([position='top_right']),:host([position='bottom_right']){margin-left:var(--edge-offset)}:host([position^='bottom']){margin-top:var(--space-unit)}:host([position='left']){margin-right:var(--space-unit)}:host([position='top_left']),:host([position='bottom_left']){margin-right:var(--edge-offset)}:host([position^='top'])::before{top:var(--arrow-center-y-offset)}:host([position^='bottom'])::before{bottom:var(--arrow-center-y-offset)}:host([position='top'])::before,:host([position='bottom'])::before{left:var(--arrow-center-x-offset)}:host([position='right'])::before,:host([position='left'])::before{top:var(--arrow-center-x-offset)}:host([position='right'])::before{right:var(--arrow-center-y-offset)}:host([position='top_right'])::before,:host([position='bottom_right'])::before{right:var(--arrow-edge-offset)}:host([position='left'])::before{left:var(--arrow-center-y-offset)}:host([position='top_left'])::before,:host([position='bottom_left'])::before{left:var(--arrow-edge-offset)}::slotted(*){flex:1 auto;overflow:auto}";
4
+ const stylesCss = ":host{--z-tooltip-theme--surface:var(--color-surface01);--z-tooltip-theme--text:var(--color-text01);--z-tooltip-shadow-filter:drop-shadow(0 1px 2px var(--shadow-color-base))}:host([dark]) z-popover{--z-popover-theme--surface:var(--color-surface05)}z-popover{--z-popover-padding:var(--space-unit);--z-popover-theme--surface:var(--z-tooltip-theme--surface);--z-popover-theme--text:var(--z-tooltip-theme--text);--z-popover-shadow-filter:var(--z-tooltip-shadow-filter)}";
5
5
 
6
- const documentElement = document.documentElement;
7
- /**
8
- * Find the closest scrollable parent of a node.
9
- *
10
- * @param {Element} element The node
11
- */
12
- function findScrollableParent(element) {
13
- let parent = element.parentNode;
14
- while (parent && parent !== documentElement) {
15
- const { overflow, overflowX, overflowY } = window.getComputedStyle(parent);
16
- if (overflow === 'hidden' ||
17
- overflowY === 'hidden' ||
18
- overflowX === 'hidden') {
19
- return parent;
20
- }
21
- if ((parent.scrollHeight > parent.clientHeight && overflow !== 'visible' && overflowY !== 'visible') ||
22
- (parent.scrollWidth > parent.clientWidth && overflow !== 'visible' && overflowX !== 'visible')) {
23
- return parent;
24
- }
25
- parent = parent.parentNode;
26
- }
27
- return documentElement;
28
- }
29
- /**
30
- * Calculate computed offset.
31
- * It includes matrix transformations.
32
- * @param element The target element.
33
- * @param targetParentOffset The relative offset parent.
34
- * @return A client rect object.
35
- */
36
- function computeOffset(element, targetParentOffset) {
37
- const rect = element.getBoundingClientRect();
38
- const width = rect.width;
39
- const height = rect.height;
40
- let top = 0;
41
- let left = 0;
42
- let offsetParent = element;
43
- while (offsetParent && offsetParent != targetParentOffset) {
44
- left += offsetParent.offsetLeft;
45
- // document.body sometimes has offsetTop == 0 but still has an
46
- // offset because of children margins!
47
- if (offsetParent === document.body) {
48
- top += offsetParent.getBoundingClientRect().top + window.scrollY;
49
- }
50
- else {
51
- top += offsetParent.offsetTop;
52
- }
53
- if (window.DOMMatrix) {
54
- const style = window.getComputedStyle(offsetParent);
55
- const transform = style.transform || style.webkitTransform;
56
- const domMatrix = new DOMMatrix(transform);
57
- if (domMatrix) {
58
- left += domMatrix.m41;
59
- if (offsetParent !== document.body) {
60
- top += domMatrix.m42;
61
- }
62
- }
63
- }
64
- if (!offsetParent.offsetParent) {
65
- break;
66
- }
67
- offsetParent = offsetParent.offsetParent;
68
- }
69
- let parentWidth;
70
- let parentHeight;
71
- if (offsetParent === document.body) {
72
- parentWidth = window.innerWidth;
73
- parentHeight = window.innerHeight;
74
- }
75
- else {
76
- parentWidth = offsetParent.offsetWidth;
77
- parentHeight = offsetParent.offsetHeight;
78
- }
79
- const right = parentWidth - left - rect.width;
80
- const bottom = parentHeight - top - rect.height;
81
- return { top, right, bottom, left, width, height };
82
- }
83
6
  const ZTooltip = class {
84
7
  constructor(hostRef) {
85
8
  registerInstance(this, hostRef);
86
- this.positionChange = createEvent(this, "positionChange", 7);
87
9
  /** Tooltip position. */
88
- this.type = TooltipPosition.AUTO;
10
+ this.position = PopoverPositions.AUTO;
11
+ /** Enable tooltip dark mode. */
12
+ this.dark = false;
89
13
  /**
90
14
  * The open state of the tooltip.
91
15
  */
92
16
  this.open = false;
93
17
  }
94
- validateType(newValue) {
95
- if (newValue &&
96
- Object
97
- .values(TooltipPosition)
98
- .every((position) => newValue !== position)) {
99
- this.type = TooltipPosition.AUTO;
100
- }
101
- }
102
- onPositionChange() {
103
- this.positionChange.emit({ position: this.position });
104
- }
105
- disconnectedCallback() {
106
- cancelAnimationFrame(this.animationFrameRequestId);
107
- }
108
- /**
109
- * Setup tooltip behaviors on opening.
110
- */
111
- onOpen() {
112
- cancelAnimationFrame(this.animationFrameRequestId);
113
- if (this.content) {
114
- return;
115
- }
116
- if (this.open) {
117
- const setPosition = () => {
118
- if (this.open) {
119
- this.setPosition();
120
- this.animationFrameRequestId = requestAnimationFrame(setPosition);
121
- }
122
- };
123
- setPosition();
124
- }
125
- else {
126
- const style = this.host.style;
127
- style.removeProperty("top");
128
- style.removeProperty("right");
129
- style.removeProperty("bottom");
130
- style.removeProperty("left");
131
- }
132
- }
133
- /**
134
- * Set the position of the tooltip.
135
- */
136
- setPosition() {
137
- let element;
138
- if (typeof this.bindTo === "string") {
139
- element = this.host.ownerDocument.querySelector(this.bindTo);
140
- }
141
- else if (this.bindTo) {
142
- element = this.bindTo;
143
- }
144
- else {
145
- element = this.host.parentElement;
146
- }
147
- if (!element) {
148
- return;
149
- }
150
- const scrollContainer = findScrollableParent(element);
151
- const scrollingBoundingRect = scrollContainer.getBoundingClientRect();
152
- const offsetContainer = this.host.offsetParent;
153
- const relativeBoundingRect = offsetContainer ? computeOffset(offsetContainer, scrollContainer) : { top: 0, right: 0, bottom: 0, left: 0 };
154
- const boundingRect = computeOffset(element, scrollContainer);
155
- const top = boundingRect.top - scrollContainer.scrollTop;
156
- const bottom = scrollingBoundingRect.height - (boundingRect.top + boundingRect.height) + scrollContainer.scrollTop;
157
- const left = boundingRect.left - scrollContainer.scrollLeft;
158
- const right = scrollingBoundingRect.width - (boundingRect.left + boundingRect.width) + scrollContainer.scrollLeft;
159
- const overflowBottom = Math.max(0, scrollingBoundingRect.top + scrollingBoundingRect.height - window.innerHeight);
160
- const overflowRight = Math.max(0, scrollingBoundingRect.left + scrollingBoundingRect.width - window.innerWidth);
161
- const availableTop = Math.min(top, top + scrollingBoundingRect.top);
162
- const availableBottom = Math.min(bottom, bottom - overflowBottom);
163
- const availableLeft = Math.min(left, left + scrollingBoundingRect.left);
164
- const availableRight = Math.min(right, right - overflowRight);
165
- const availableHeight = availableTop + availableBottom + boundingRect.height;
166
- const availableWidth = availableLeft + availableRight + boundingRect.width;
167
- let position = this.type;
168
- if (position === TooltipPosition.AUTO) {
169
- /**
170
- * The `AUTO` position tries to place the tooltip in the "safest" area,
171
- * where there's more space available.
172
- */
173
- const positions = [];
174
- if (availableTop / availableHeight > 0.9) {
175
- positions.unshift(TooltipPosition.TOP);
176
- }
177
- else if (availableTop / availableHeight > 0.6) {
178
- positions.push(TooltipPosition.TOP);
179
- }
180
- else if (availableTop / availableHeight < 0.1) {
181
- positions.unshift(TooltipPosition.BOTTOM);
182
- }
183
- else {
184
- positions.push(TooltipPosition.BOTTOM);
185
- }
186
- if (availableLeft / availableWidth > 0.6) {
187
- positions.push(TooltipPosition.LEFT);
188
- }
189
- else if (availableLeft / availableWidth < 0.4) {
190
- positions.push(TooltipPosition.RIGHT);
191
- }
192
- position = positions.join("_");
193
- }
194
- const style = this.host.style;
195
- if (!this.content) {
196
- style.position = "absolute";
197
- }
198
- const offsetTop = boundingRect.top - relativeBoundingRect.top;
199
- const offsetRight = boundingRect.right - relativeBoundingRect.right;
200
- const offsetBottom = boundingRect.bottom - relativeBoundingRect.bottom;
201
- const offsetLeft = boundingRect.left - relativeBoundingRect.left;
202
- if (position === TooltipPosition.TOP ||
203
- position === TooltipPosition.TOP_RIGHT ||
204
- position === TooltipPosition.TOP_LEFT) {
205
- style.top = "auto";
206
- style.bottom = `${offsetBottom + boundingRect.height}px`;
207
- }
208
- if (position === TooltipPosition.BOTTOM ||
209
- position === TooltipPosition.BOTTOM_RIGHT ||
210
- position === TooltipPosition.BOTTOM_LEFT) {
211
- style.top = `${offsetTop + boundingRect.height}px`;
212
- style.bottom = "auto";
213
- }
214
- if (position === TooltipPosition.TOP ||
215
- position === TooltipPosition.BOTTOM) {
216
- style.left = `${offsetLeft +
217
- (boundingRect.width / 2) -
218
- (this.host.clientWidth / 2)}px`;
219
- }
220
- if (position === TooltipPosition.TOP_RIGHT ||
221
- position === TooltipPosition.BOTTOM_RIGHT) {
222
- style.right = "auto";
223
- style.left = `${offsetLeft + boundingRect.width}px`;
224
- }
225
- if (position === TooltipPosition.TOP_LEFT ||
226
- position === TooltipPosition.BOTTOM_LEFT) {
227
- style.left = "auto";
228
- style.right = `${offsetRight + boundingRect.width}px`;
229
- }
230
- if (position === TooltipPosition.RIGHT ||
231
- position === TooltipPosition.LEFT) {
232
- style.top = `${offsetTop +
233
- (boundingRect.height / 2) -
234
- (this.host.clientHeight / 2)}px`;
235
- style.bottom = "auto";
236
- }
237
- if (position === TooltipPosition.RIGHT) {
238
- style.right = "auto";
239
- style.left = `${offsetLeft + boundingRect.width}px`;
240
- }
241
- if (position === TooltipPosition.LEFT) {
242
- style.left = "auto";
243
- style.right = `${offsetRight + boundingRect.width}px`;
244
- }
245
- this.position = position;
246
- }
247
- componentWillLoad() {
248
- // Keep backward compatibility
249
- if (this.content) {
250
- this.open = true;
251
- }
252
- this.validateType(this.type);
253
- this.onOpen();
18
+ onPopoverOpenChange() {
19
+ this.open = this.popover.open;
254
20
  }
255
21
  render() {
256
- if (this.content) {
257
- return (h(Host, { class: "legacy", position: this.type }, this.content));
258
- }
259
- return (h(Host, { position: this.position }, h("slot", null)));
22
+ return h("z-popover", { ref: (el) => (this.popover = el), bindTo: this.bindTo, open: this.open, position: this.position, center: true, showArrow: true }, h("slot", null));
260
23
  }
261
- get host() { return getElement(this); }
262
- static get watchers() { return {
263
- "type": ["validateType"],
264
- "position": ["onPositionChange"],
265
- "open": ["onOpen"]
266
- }; }
267
24
  };
268
25
  ZTooltip.style = stylesCss;
269
26
 
@@ -138,8 +138,8 @@ export declare enum InputStatusEnum {
138
138
  error = "error",
139
139
  warning = "warning"
140
140
  }
141
- export declare type TooltipPositionBean = keyof typeof TooltipPosition;
142
- export declare enum TooltipPosition {
141
+ export declare type PopoverPositionBean = keyof typeof PopoverPositions;
142
+ export declare enum PopoverPositions {
143
143
  AUTO = "auto",
144
144
  TOP = "top",
145
145
  RIGHT = "right",
@@ -148,7 +148,11 @@ export declare enum TooltipPosition {
148
148
  TOP_RIGHT = "top_right",
149
149
  TOP_LEFT = "top_left",
150
150
  BOTTOM_RIGHT = "bottom_right",
151
- BOTTOM_LEFT = "bottom_left"
151
+ BOTTOM_LEFT = "bottom_left",
152
+ RIGHT_TOP = "right_top",
153
+ RIGHT_BOTTOM = "right_bottom",
154
+ LEFT_TOP = "left_top",
155
+ LEFT_BOTTOM = "left_bottom"
152
156
  }
153
157
  export declare enum KeyboardKeyCodeEnum {
154
158
  TAB = 9,
@@ -188,36 +192,6 @@ export declare enum ThemeVariant {
188
192
  dark = "dark",
189
193
  light = "light"
190
194
  }
191
- export declare enum PopoverPosition {
192
- "after-down" = "after-down",
193
- "after-center" = "after-center",
194
- "after-up" = "after-up",
195
- "below-right" = "below-right",
196
- "below-center" = "below-center",
197
- "below-left" = "below-left",
198
- "before-down" = "before-down",
199
- "before-center" = "before-center",
200
- "before-up" = "before-up",
201
- "above-right" = "above-right",
202
- "above-center" = "above-center",
203
- "above-left" = "above-left"
204
- }
205
- export declare enum PopoverBorderRadius {
206
- "none" = "none",
207
- small = "small",
208
- medium = "medium"
209
- }
210
- export declare enum PopoverShadow {
211
- "shadow-1" = "shadow-1",
212
- "shadow-2" = "shadow-2",
213
- "shadow-3" = "shadow-3",
214
- "shadow-4" = "shadow-4",
215
- "shadow-6" = "shadow-6",
216
- "shadow-8" = "shadow-8",
217
- "shadow-12" = "shadow-12",
218
- "shadow-16" = "shadow-16",
219
- "shadow-24" = "shadow-24"
220
- }
221
195
  export declare enum DividerSize {
222
196
  small = "small",
223
197
  medium = "medium",
@@ -0,0 +1,3 @@
1
+ import { ZDatePickerMode, ZDatePickerPosition } from "../../beans";
2
+ export declare function setFlatpickrPosition(element: HTMLElement, mode: ZDatePickerMode): ZDatePickerPosition;
3
+ export declare function setAriaOptions(element: HTMLElement, mode: ZDatePickerMode): void;
@@ -1,9 +1,9 @@
1
- import { EventEmitter } from "../../stencil-public-runtime";
2
- import { ZDatePickerMode, ZDatePickerPosition } from "../../beans";
1
+ import { EventEmitter } from "../../../stencil-public-runtime";
2
+ import { ZDatePickerMode, ZDatePickerPosition } from "../../../beans";
3
3
  export declare class ZDatePicker {
4
4
  element: HTMLElement;
5
5
  /** unique id */
6
- datepickerid: string;
6
+ datePickerId: string;
7
7
  /** z-input aria label */
8
8
  ariaLabel?: string;
9
9
  /** z-input label */
@@ -19,11 +19,6 @@ export declare class ZDatePicker {
19
19
  handleKeyDown(ev: KeyboardEvent): void;
20
20
  componentWillLoad(): void;
21
21
  componentDidLoad(): void;
22
- setAriaOptions(): void;
23
- setMonthsAriaOptions(calendar: any, prevMonthArrow: any, nextMonthArrow: any): void;
24
- setDateAriaOptions(calendar: any, prevMonthArrow: any, nextMonthArrow: any): void;
25
- setDateTimeAriaOptions(calendar: any, prevMonthArrow: any, nextMonthArrow: any): void;
26
- setFlatpickrPosition(): void;
27
22
  renderSlottedContent(): any;
28
23
  renderZInput(): any;
29
24
  render(): any;