@jumpgroup/jump-design-system 0.2.7 → 0.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (324) hide show
  1. package/dist/cjs/{index-41aaa52a.js → index-674508e2.js} +153 -4
  2. package/dist/cjs/index-674508e2.js.map +1 -0
  3. package/dist/cjs/jump-accordion.cjs.entry.js +22 -0
  4. package/dist/cjs/jump-accordion.cjs.entry.js.map +1 -0
  5. package/dist/cjs/jump-badge.cjs.entry.js +6 -3
  6. package/dist/cjs/jump-badge.cjs.entry.js.map +1 -1
  7. package/dist/cjs/jump-button_2.cjs.entry.js +631 -0
  8. package/dist/cjs/jump-button_2.cjs.entry.js.map +1 -0
  9. package/dist/cjs/jump-card-ecommerce.cjs.entry.js +121 -0
  10. package/dist/cjs/jump-card-ecommerce.cjs.entry.js.map +1 -0
  11. package/dist/cjs/jump-card.cjs.entry.js +4 -4
  12. package/dist/cjs/jump-card.cjs.entry.js.map +1 -1
  13. package/dist/cjs/jump-design-system.cjs.js +2 -2
  14. package/dist/cjs/jump-filter.cjs.entry.js +59 -0
  15. package/dist/cjs/jump-filter.cjs.entry.js.map +1 -0
  16. package/dist/cjs/jump-filtergroup.cjs.entry.js +119 -0
  17. package/dist/cjs/jump-filtergroup.cjs.entry.js.map +1 -0
  18. package/dist/cjs/jump-pagination-table.cjs.entry.js +24 -5
  19. package/dist/cjs/jump-pagination-table.cjs.entry.js.map +1 -1
  20. package/dist/cjs/jump-pagination.cjs.entry.js +19 -5
  21. package/dist/cjs/jump-pagination.cjs.entry.js.map +1 -1
  22. package/dist/cjs/jump-quantity.cjs.entry.js +77 -0
  23. package/dist/cjs/jump-quantity.cjs.entry.js.map +1 -0
  24. package/dist/cjs/jump-tab-item.cjs.entry.js +40 -0
  25. package/dist/cjs/jump-tab-item.cjs.entry.js.map +1 -0
  26. package/dist/cjs/jump-tab-panel.cjs.entry.js +24 -0
  27. package/dist/cjs/jump-tab-panel.cjs.entry.js.map +1 -0
  28. package/dist/cjs/jump-tab.cjs.entry.js +72 -9
  29. package/dist/cjs/jump-tab.cjs.entry.js.map +1 -1
  30. package/dist/cjs/loader.cjs.js +2 -2
  31. package/dist/collection/collection-manifest.json +8 -1
  32. package/dist/collection/components/jump-accordion/jump-accordion.css +3 -0
  33. package/dist/collection/components/jump-accordion/jump-accordion.js +19 -0
  34. package/dist/collection/components/jump-accordion/jump-accordion.js.map +1 -0
  35. package/dist/collection/components/jump-accordion/test/jump-accordion.e2e.js +10 -0
  36. package/dist/collection/components/jump-accordion/test/jump-accordion.e2e.js.map +1 -0
  37. package/dist/collection/components/jump-accordion/test/jump-accordion.spec.js +18 -0
  38. package/dist/collection/components/jump-accordion/test/jump-accordion.spec.js.map +1 -0
  39. package/dist/collection/components/jump-badge/jump-badge.css +90 -12
  40. package/dist/collection/components/jump-badge/jump-badge.js +61 -3
  41. package/dist/collection/components/jump-badge/jump-badge.js.map +1 -1
  42. package/dist/collection/components/jump-badge/jump-badge.stories.js +93 -8
  43. package/dist/collection/components/jump-badge/jump-badge.stories.js.map +1 -1
  44. package/dist/collection/components/jump-button/jump-button-anchor.stories.js +38 -29
  45. package/dist/collection/components/jump-button/jump-button-anchor.stories.js.map +1 -1
  46. package/dist/collection/components/jump-button/jump-button-dimension.stories.js +4 -9
  47. package/dist/collection/components/jump-button/jump-button-dimension.stories.js.map +1 -1
  48. package/dist/collection/components/jump-button/jump-button-filled.stories.js +15 -24
  49. package/dist/collection/components/jump-button/jump-button-filled.stories.js.map +1 -1
  50. package/dist/collection/components/jump-button/jump-button-only-icon.stories.js +43 -73
  51. package/dist/collection/components/jump-button/jump-button-only-icon.stories.js.map +1 -1
  52. package/dist/collection/components/jump-button/jump-button.css +2 -1
  53. package/dist/collection/components/jump-button/jump-button.js +1 -1
  54. package/dist/collection/components/jump-button/jump-button.stories.js +199 -0
  55. package/dist/collection/components/jump-button/jump-button.stories.js.map +1 -0
  56. package/dist/collection/components/jump-card/jump-card.css +2 -2
  57. package/dist/collection/components/jump-card/jump-card.js +2 -2
  58. package/dist/collection/components/jump-card-ecommerce/jump-card-ecommerce.css +183 -0
  59. package/dist/collection/components/jump-card-ecommerce/jump-card-ecommerce.js +583 -0
  60. package/dist/collection/components/jump-card-ecommerce/jump-card-ecommerce.js.map +1 -0
  61. package/dist/collection/components/jump-card-ecommerce/jump-card-ecommerce.stories.js +205 -0
  62. package/dist/collection/components/jump-card-ecommerce/jump-card-ecommerce.stories.js.map +1 -0
  63. package/dist/collection/components/jump-card-ecommerce/test/jump-card-ecommerce.e2e.js +10 -0
  64. package/dist/collection/components/jump-card-ecommerce/test/jump-card-ecommerce.e2e.js.map +1 -0
  65. package/dist/collection/components/jump-card-ecommerce/test/jump-card-ecommerce.spec.js +18 -0
  66. package/dist/collection/components/jump-card-ecommerce/test/jump-card-ecommerce.spec.js.map +1 -0
  67. package/dist/collection/components/jump-filter/jump-filter.css +8 -0
  68. package/dist/collection/components/jump-filter/jump-filter.js +212 -0
  69. package/dist/collection/components/jump-filter/jump-filter.js.map +1 -0
  70. package/dist/collection/components/jump-filter/jump-filter.stories.js +122 -0
  71. package/dist/collection/components/jump-filter/jump-filter.stories.js.map +1 -0
  72. package/dist/collection/components/jump-filtergroup/jump-filtergroup.css +17 -0
  73. package/dist/collection/components/jump-filtergroup/jump-filtergroup.js +328 -0
  74. package/dist/collection/components/jump-filtergroup/jump-filtergroup.js.map +1 -0
  75. package/dist/collection/components/jump-filtergroup/jump-filtergroup.stories.js +49 -0
  76. package/dist/collection/components/jump-filtergroup/jump-filtergroup.stories.js.map +1 -0
  77. package/dist/collection/components/jump-icon/jump-icon-custom.stories.js +67 -0
  78. package/dist/collection/components/jump-icon/jump-icon-custom.stories.js.map +1 -0
  79. package/dist/collection/components/jump-icon/jump-icon-fa-brands.stories.js +73 -0
  80. package/dist/collection/components/jump-icon/jump-icon-fa-brands.stories.js.map +1 -0
  81. package/dist/collection/components/jump-icon/jump-icon-fa-duotone.stories.js +73 -0
  82. package/dist/collection/components/jump-icon/jump-icon-fa-duotone.stories.js.map +1 -0
  83. package/dist/collection/components/jump-icon/jump-icon-fa-light.stories.js +73 -0
  84. package/dist/collection/components/jump-icon/jump-icon-fa-light.stories.js.map +1 -0
  85. package/dist/collection/components/jump-icon/jump-icon-fa-regular.stories.js +73 -0
  86. package/dist/collection/components/jump-icon/jump-icon-fa-regular.stories.js.map +1 -0
  87. package/dist/collection/components/jump-icon/jump-icon-fa-sharp-light.stories.js +73 -0
  88. package/dist/collection/components/jump-icon/jump-icon-fa-sharp-light.stories.js.map +1 -0
  89. package/dist/collection/components/jump-icon/jump-icon-fa-sharp-regular.stories.js +73 -0
  90. package/dist/collection/components/jump-icon/jump-icon-fa-sharp-regular.stories.js.map +1 -0
  91. package/dist/collection/components/jump-icon/jump-icon-fa-sharp-solid.stories.js +73 -0
  92. package/dist/collection/components/jump-icon/jump-icon-fa-sharp-solid.stories.js.map +1 -0
  93. package/dist/collection/components/jump-icon/jump-icon-fa-sharp-thin.stories.js +73 -0
  94. package/dist/collection/components/jump-icon/jump-icon-fa-sharp-thin.stories.js.map +1 -0
  95. package/dist/collection/components/jump-icon/jump-icon-fa-solid.stories.js +73 -0
  96. package/dist/collection/components/jump-icon/jump-icon-fa-solid.stories.js.map +1 -0
  97. package/dist/collection/components/jump-icon/jump-icon-fa-thin.stories.js +73 -0
  98. package/dist/collection/components/jump-icon/jump-icon-fa-thin.stories.js.map +1 -0
  99. package/dist/collection/components/jump-icon/jump-icon-lucide.stories.js +67 -0
  100. package/dist/collection/components/jump-icon/jump-icon-lucide.stories.js.map +1 -0
  101. package/dist/collection/components/jump-icon/jump-icon.css +61 -15
  102. package/dist/collection/components/jump-icon/jump-icon.js +132 -12
  103. package/dist/collection/components/jump-icon/jump-icon.js.map +1 -1
  104. package/dist/collection/components/jump-pagination/jump-pagination.css +1 -0
  105. package/dist/collection/components/jump-pagination/jump-pagination.js +21 -6
  106. package/dist/collection/components/jump-pagination/jump-pagination.js.map +1 -1
  107. package/dist/collection/components/jump-pagination/jump-pagination.stories.js +6 -4
  108. package/dist/collection/components/jump-pagination/jump-pagination.stories.js.map +1 -1
  109. package/dist/collection/components/jump-pagination-table/jump-pagination-table.js +28 -9
  110. package/dist/collection/components/jump-pagination-table/jump-pagination-table.js.map +1 -1
  111. package/dist/collection/components/jump-pagination-table/jump-pagination-table.stories.js +25 -7
  112. package/dist/collection/components/jump-pagination-table/jump-pagination-table.stories.js.map +1 -1
  113. package/dist/collection/components/jump-quantity/jump-quantity.css +52 -0
  114. package/dist/collection/components/jump-quantity/jump-quantity.js +245 -0
  115. package/dist/collection/components/jump-quantity/jump-quantity.js.map +1 -0
  116. package/dist/collection/components/jump-quantity/jump-quantity.stories.js +103 -0
  117. package/dist/collection/components/jump-quantity/jump-quantity.stories.js.map +1 -0
  118. package/dist/collection/components/jump-tab/jump-tab.css +9 -0
  119. package/dist/collection/components/jump-tab/jump-tab.js +107 -21
  120. package/dist/collection/components/jump-tab/jump-tab.js.map +1 -1
  121. package/dist/collection/components/jump-tab/jump-tab.stories.js +129 -0
  122. package/dist/collection/components/jump-tab/jump-tab.stories.js.map +1 -0
  123. package/dist/collection/components/jump-tab-item/jump-tab-item-boxed.stories.js +54 -0
  124. package/dist/collection/components/jump-tab-item/jump-tab-item-boxed.stories.js.map +1 -0
  125. package/dist/collection/components/jump-tab-item/jump-tab-item-inline.stories.js +54 -0
  126. package/dist/collection/components/jump-tab-item/jump-tab-item-inline.stories.js.map +1 -0
  127. package/dist/collection/components/jump-tab-item/jump-tab-item-rounded.stories.js +41 -0
  128. package/dist/collection/components/jump-tab-item/jump-tab-item-rounded.stories.js.map +1 -0
  129. package/dist/collection/components/jump-tab-item/jump-tab-item-sheet.stories.js +42 -0
  130. package/dist/collection/components/jump-tab-item/jump-tab-item-sheet.stories.js.map +1 -0
  131. package/dist/collection/components/jump-tab-item/jump-tab-item.css +109 -0
  132. package/dist/collection/components/jump-tab-item/jump-tab-item.js +173 -0
  133. package/dist/collection/components/jump-tab-item/jump-tab-item.js.map +1 -0
  134. package/dist/collection/components/jump-tab-item/test/jump-tab-item.e2e.js +10 -0
  135. package/dist/collection/components/jump-tab-item/test/jump-tab-item.e2e.js.map +1 -0
  136. package/dist/collection/components/jump-tab-item/test/jump-tab-item.spec.js +18 -0
  137. package/dist/collection/components/jump-tab-item/test/jump-tab-item.spec.js.map +1 -0
  138. package/dist/collection/components/jump-tab-panel/jump-tab-panel.css +11 -0
  139. package/dist/collection/components/jump-tab-panel/jump-tab-panel.js +63 -0
  140. package/dist/collection/components/jump-tab-panel/jump-tab-panel.js.map +1 -0
  141. package/dist/collection/components/jump-tab-panel/test/jump-tab-panel.e2e.js +10 -0
  142. package/dist/collection/components/jump-tab-panel/test/jump-tab-panel.e2e.js.map +1 -0
  143. package/dist/collection/components/jump-tab-panel/test/jump-tab-panel.spec.js +18 -0
  144. package/dist/collection/components/jump-tab-panel/test/jump-tab-panel.spec.js.map +1 -0
  145. package/dist/collection/utils/utils.js +41 -8
  146. package/dist/collection/utils/utils.js.map +1 -1
  147. package/dist/components/jump-accordion.d.ts +11 -0
  148. package/dist/components/jump-accordion.js +36 -0
  149. package/dist/components/jump-accordion.js.map +1 -0
  150. package/dist/components/jump-badge.js +1 -33
  151. package/dist/components/jump-badge.js.map +1 -1
  152. package/dist/components/jump-badge2.js +44 -0
  153. package/dist/components/jump-badge2.js.map +1 -0
  154. package/dist/components/jump-button.js +1 -65
  155. package/dist/components/jump-button.js.map +1 -1
  156. package/dist/components/jump-button2.js +69 -0
  157. package/dist/components/jump-button2.js.map +1 -0
  158. package/dist/components/jump-card-ecommerce.d.ts +11 -0
  159. package/dist/components/jump-card-ecommerce.js +177 -0
  160. package/dist/components/jump-card-ecommerce.js.map +1 -0
  161. package/dist/components/jump-card.js +3 -3
  162. package/dist/components/jump-card.js.map +1 -1
  163. package/dist/components/jump-filter.d.ts +11 -0
  164. package/dist/components/jump-filter.js +96 -0
  165. package/dist/components/jump-filter.js.map +1 -0
  166. package/dist/components/jump-filtergroup.d.ts +11 -0
  167. package/dist/components/jump-filtergroup.js +161 -0
  168. package/dist/components/jump-filtergroup.js.map +1 -0
  169. package/dist/components/jump-icon2.js +556 -2375
  170. package/dist/components/jump-icon2.js.map +1 -1
  171. package/dist/components/jump-pagination-table.js +30 -5
  172. package/dist/components/jump-pagination-table.js.map +1 -1
  173. package/dist/components/jump-pagination.js +27 -6
  174. package/dist/components/jump-pagination.js.map +1 -1
  175. package/dist/components/jump-quantity.d.ts +11 -0
  176. package/dist/components/jump-quantity.js +109 -0
  177. package/dist/components/jump-quantity.js.map +1 -0
  178. package/dist/components/jump-tab-item.d.ts +11 -0
  179. package/dist/components/jump-tab-item.js +68 -0
  180. package/dist/components/jump-tab-item.js.map +1 -0
  181. package/dist/components/jump-tab-panel.d.ts +11 -0
  182. package/dist/components/jump-tab-panel.js +41 -0
  183. package/dist/components/jump-tab-panel.js.map +1 -0
  184. package/dist/components/jump-tab.js +75 -12
  185. package/dist/components/jump-tab.js.map +1 -1
  186. package/dist/esm/{index-192aeaf1.js → index-70f1949a.js} +153 -5
  187. package/dist/esm/index-70f1949a.js.map +1 -0
  188. package/dist/esm/jump-accordion.entry.js +18 -0
  189. package/dist/esm/jump-accordion.entry.js.map +1 -0
  190. package/dist/esm/jump-badge.entry.js +6 -3
  191. package/dist/esm/jump-badge.entry.js.map +1 -1
  192. package/dist/esm/jump-button_2.entry.js +626 -0
  193. package/dist/esm/jump-button_2.entry.js.map +1 -0
  194. package/dist/esm/jump-card-ecommerce.entry.js +117 -0
  195. package/dist/esm/jump-card-ecommerce.entry.js.map +1 -0
  196. package/dist/esm/jump-card.entry.js +4 -4
  197. package/dist/esm/jump-card.entry.js.map +1 -1
  198. package/dist/esm/jump-design-system.js +3 -3
  199. package/dist/esm/jump-filter.entry.js +55 -0
  200. package/dist/esm/jump-filter.entry.js.map +1 -0
  201. package/dist/esm/jump-filtergroup.entry.js +115 -0
  202. package/dist/esm/jump-filtergroup.entry.js.map +1 -0
  203. package/dist/esm/jump-pagination-table.entry.js +24 -5
  204. package/dist/esm/jump-pagination-table.entry.js.map +1 -1
  205. package/dist/esm/jump-pagination.entry.js +19 -5
  206. package/dist/esm/jump-pagination.entry.js.map +1 -1
  207. package/dist/esm/jump-quantity.entry.js +73 -0
  208. package/dist/esm/jump-quantity.entry.js.map +1 -0
  209. package/dist/esm/jump-tab-item.entry.js +36 -0
  210. package/dist/esm/jump-tab-item.entry.js.map +1 -0
  211. package/dist/esm/jump-tab-panel.entry.js +20 -0
  212. package/dist/esm/jump-tab-panel.entry.js.map +1 -0
  213. package/dist/esm/jump-tab.entry.js +72 -9
  214. package/dist/esm/jump-tab.entry.js.map +1 -1
  215. package/dist/esm/loader.js +3 -3
  216. package/dist/jump-design-system/jump-design-system.esm.js +1 -1
  217. package/dist/jump-design-system/jump-design-system.esm.js.map +1 -1
  218. package/dist/jump-design-system/p-2cb7d817.entry.js +2 -0
  219. package/dist/jump-design-system/p-2cb7d817.entry.js.map +1 -0
  220. package/dist/jump-design-system/p-34a46a10.entry.js +2 -0
  221. package/dist/jump-design-system/p-34a46a10.entry.js.map +1 -0
  222. package/dist/jump-design-system/p-377a769b.entry.js +2 -0
  223. package/dist/jump-design-system/p-377a769b.entry.js.map +1 -0
  224. package/dist/jump-design-system/p-493c7f4a.entry.js +2 -0
  225. package/dist/jump-design-system/p-493c7f4a.entry.js.map +1 -0
  226. package/dist/jump-design-system/p-4d6cc90d.js +3 -0
  227. package/dist/jump-design-system/p-4d6cc90d.js.map +1 -0
  228. package/dist/jump-design-system/p-56609b82.entry.js +2 -0
  229. package/dist/jump-design-system/p-56609b82.entry.js.map +1 -0
  230. package/dist/jump-design-system/p-5a6fbc53.entry.js +2 -0
  231. package/dist/jump-design-system/p-5a6fbc53.entry.js.map +1 -0
  232. package/dist/jump-design-system/p-5d713084.entry.js +2 -0
  233. package/dist/jump-design-system/p-5d713084.entry.js.map +1 -0
  234. package/dist/jump-design-system/p-7696c03d.entry.js +2 -0
  235. package/dist/jump-design-system/p-7696c03d.entry.js.map +1 -0
  236. package/dist/jump-design-system/p-8343b4f5.entry.js +2 -0
  237. package/dist/jump-design-system/p-8343b4f5.entry.js.map +1 -0
  238. package/dist/jump-design-system/p-a6fc23f7.entry.js +2 -0
  239. package/dist/jump-design-system/p-a6fc23f7.entry.js.map +1 -0
  240. package/dist/jump-design-system/p-c1665537.entry.js +2 -0
  241. package/dist/jump-design-system/p-c1665537.entry.js.map +1 -0
  242. package/dist/jump-design-system/p-c2bc6395.entry.js +66 -0
  243. package/dist/jump-design-system/p-c2bc6395.entry.js.map +1 -0
  244. package/dist/jump-design-system/p-fafe6478.entry.js +2 -0
  245. package/dist/jump-design-system/p-fafe6478.entry.js.map +1 -0
  246. package/dist/jump-design-system-elements.json +396 -9
  247. package/dist/types/components/jump-accordion/jump-accordion.d.ts +3 -0
  248. package/dist/types/components/jump-badge/jump-badge.d.ts +13 -1
  249. package/dist/types/components/jump-badge/jump-badge.stories.d.ts +22 -0
  250. package/dist/types/components/jump-button/jump-button-anchor.stories.d.ts +18 -4
  251. package/dist/types/components/jump-button/jump-button-dimension.stories.d.ts +0 -5
  252. package/dist/types/components/jump-button/jump-button-only-icon.stories.d.ts +4 -11
  253. package/dist/types/components/jump-button/jump-button.stories.d.ts +98 -0
  254. package/dist/types/components/jump-card-ecommerce/jump-card-ecommerce.d.ts +65 -0
  255. package/dist/types/components/jump-card-ecommerce/jump-card-ecommerce.stories.d.ts +117 -0
  256. package/dist/types/components/jump-filter/jump-filter.d.ts +22 -0
  257. package/dist/types/components/jump-filter/jump-filter.stories.d.ts +40 -0
  258. package/dist/types/components/jump-filtergroup/jump-filtergroup.d.ts +24 -0
  259. package/dist/types/components/jump-filtergroup/jump-filtergroup.stories.d.ts +43 -0
  260. package/dist/types/components/jump-icon/jump-icon-custom.stories.d.ts +40 -0
  261. package/dist/types/components/{jump-button/jump-button-outline.stories.d.ts → jump-icon/jump-icon-fa-brands.stories.d.ts} +19 -30
  262. package/dist/types/components/jump-icon/jump-icon-fa-duotone.stories.d.ts +45 -0
  263. package/dist/types/components/jump-icon/jump-icon-fa-light.stories.d.ts +45 -0
  264. package/dist/types/components/jump-icon/jump-icon-fa-regular.stories.d.ts +45 -0
  265. package/dist/types/components/jump-icon/jump-icon-fa-sharp-light.stories.d.ts +45 -0
  266. package/dist/types/components/jump-icon/jump-icon-fa-sharp-regular.stories.d.ts +45 -0
  267. package/dist/types/components/jump-icon/jump-icon-fa-sharp-solid.stories.d.ts +45 -0
  268. package/dist/types/components/jump-icon/jump-icon-fa-sharp-thin.stories.d.ts +45 -0
  269. package/dist/types/components/jump-icon/jump-icon-fa-solid.stories.d.ts +45 -0
  270. package/dist/types/components/jump-icon/jump-icon-fa-thin.stories.d.ts +45 -0
  271. package/dist/types/components/{jump-button/jump-button-text.stories.d.ts → jump-icon/jump-icon-lucide.stories.d.ts} +16 -16
  272. package/dist/types/components/jump-icon/jump-icon.d.ts +29 -4
  273. package/dist/types/components/jump-pagination/jump-pagination.d.ts +9 -0
  274. package/dist/types/components/jump-pagination-table/jump-pagination-table.d.ts +18 -2
  275. package/dist/types/components/jump-pagination-table/jump-pagination-table.stories.d.ts +5 -1
  276. package/dist/types/components/jump-quantity/jump-quantity.d.ts +24 -0
  277. package/dist/types/components/jump-quantity/jump-quantity.stories.d.ts +41 -0
  278. package/dist/types/components/jump-tab/jump-tab.d.ts +11 -3
  279. package/dist/types/components/jump-tab/jump-tab.stories.d.ts +27 -0
  280. package/dist/types/components/jump-tab-item/jump-tab-item-boxed.stories.d.ts +39 -0
  281. package/dist/types/components/jump-tab-item/jump-tab-item-inline.stories.d.ts +39 -0
  282. package/dist/types/components/jump-tab-item/jump-tab-item-rounded.stories.d.ts +28 -0
  283. package/dist/types/components/jump-tab-item/jump-tab-item-sheet.stories.d.ts +28 -0
  284. package/dist/types/components/jump-tab-item/jump-tab-item.d.ts +29 -0
  285. package/dist/types/components/jump-tab-panel/jump-tab-panel.d.ts +5 -0
  286. package/dist/types/components.d.ts +563 -8
  287. package/dist/types/utils/utils.d.ts +2 -0
  288. package/package.json +3 -2
  289. package/dist/cjs/index-41aaa52a.js.map +0 -1
  290. package/dist/cjs/jump-button.cjs.entry.js +0 -41
  291. package/dist/cjs/jump-button.cjs.entry.js.map +0 -1
  292. package/dist/cjs/jump-icon.cjs.entry.js +0 -2422
  293. package/dist/cjs/jump-icon.cjs.entry.js.map +0 -1
  294. package/dist/collection/components/jump-button/jump-button-outline.stories.js +0 -111
  295. package/dist/collection/components/jump-button/jump-button-outline.stories.js.map +0 -1
  296. package/dist/collection/components/jump-button/jump-button-text.stories.js +0 -83
  297. package/dist/collection/components/jump-button/jump-button-text.stories.js.map +0 -1
  298. package/dist/collection/components/jump-icon/jump-icon.stories.js +0 -35
  299. package/dist/collection/components/jump-icon/jump-icon.stories.js.map +0 -1
  300. package/dist/collection/components/jump-tab/jump-tab-inline.stories.js +0 -28
  301. package/dist/collection/components/jump-tab/jump-tab-inline.stories.js.map +0 -1
  302. package/dist/esm/index-192aeaf1.js.map +0 -1
  303. package/dist/esm/jump-button.entry.js +0 -37
  304. package/dist/esm/jump-button.entry.js.map +0 -1
  305. package/dist/esm/jump-icon.entry.js +0 -2418
  306. package/dist/esm/jump-icon.entry.js.map +0 -1
  307. package/dist/jump-design-system/p-02914b1e.entry.js +0 -2
  308. package/dist/jump-design-system/p-02914b1e.entry.js.map +0 -1
  309. package/dist/jump-design-system/p-1a533536.entry.js +0 -2
  310. package/dist/jump-design-system/p-1a533536.entry.js.map +0 -1
  311. package/dist/jump-design-system/p-20ceb40c.js +0 -3
  312. package/dist/jump-design-system/p-20ceb40c.js.map +0 -1
  313. package/dist/jump-design-system/p-93d8245f.entry.js +0 -2
  314. package/dist/jump-design-system/p-93d8245f.entry.js.map +0 -1
  315. package/dist/jump-design-system/p-e69ee35f.entry.js +0 -2
  316. package/dist/jump-design-system/p-e69ee35f.entry.js.map +0 -1
  317. package/dist/jump-design-system/p-eb16952a.entry.js +0 -2
  318. package/dist/jump-design-system/p-eb16952a.entry.js.map +0 -1
  319. package/dist/jump-design-system/p-ed65e359.entry.js +0 -2
  320. package/dist/jump-design-system/p-ed65e359.entry.js.map +0 -1
  321. package/dist/jump-design-system/p-fa148b53.entry.js +0 -331
  322. package/dist/jump-design-system/p-fa148b53.entry.js.map +0 -1
  323. package/dist/types/components/jump-icon/jump-icon.stories.d.ts +0 -21
  324. package/dist/types/components/jump-tab/jump-tab-inline.stories.d.ts +0 -18
@@ -1,6 +1,6 @@
1
- import { proxyCustomElement, HTMLElement, h, Host } from '@stencil/core/internal/client';
1
+ import { proxyCustomElement, HTMLElement, createEvent, h, Host } from '@stencil/core/internal/client';
2
2
 
3
- const jumpTabCss = ":host{display:block}";
3
+ const jumpTabCss = ":host{display:block;--jump-tab-bg-color:var(--gray-ultralight, #f8f8f8)}:host .Wrapper{display:flex;width:fit-content}:host .Wrapper.rounded{border-radius:50px;background-color:#f8f8f8}";
4
4
  const JumpTabStyle0 = jumpTabCss;
5
5
 
6
6
  const JumpTab$1 = /*@__PURE__*/ proxyCustomElement(class JumpTab extends HTMLElement {
@@ -8,22 +8,85 @@ const JumpTab$1 = /*@__PURE__*/ proxyCustomElement(class JumpTab extends HTMLEle
8
8
  super();
9
9
  this.__registerHost();
10
10
  this.__attachShadow();
11
- this.activeTab = undefined;
12
- this.tabNames = undefined;
11
+ this.setActiveTab = createEvent(this, "jump-change-activetab", 7);
12
+ this.tabGroupName = undefined;
13
+ this.variant = 'inline';
13
14
  }
14
- componentWillLoad() {
15
- console.log('Component is about to be rendered');
16
- console.log('active', this.activeTab);
17
- console.log('tabNames', this.tabNames);
15
+ changeActiveTabHandler(event) {
16
+ this.setActiveTab.emit(event.detail);
17
+ // Recupera il valore della variabile CSS
18
+ const rootStyles = getComputedStyle(document.documentElement);
19
+ const primaryColor = rootStyles.getPropertyValue('--neutral-grey-secondary').trim();
20
+ let items = this.JumpTabEl.querySelectorAll('jump-tab-item');
21
+ if (items.length > 0) {
22
+ items.forEach((item) => {
23
+ if (item.getAttribute('identifier') === event.detail.id) {
24
+ item.setAttribute('active', '');
25
+ if (this.variant === 'sheet') {
26
+ // Aggiungi il bordo ai fratelli dell'elemento attivo tranne l'ultimo
27
+ items.forEach((sibling, index) => {
28
+ if (sibling !== item && index !== items.length - 1) {
29
+ sibling.style.borderRight = `1px solid ${primaryColor}`; // Usa i backticks
30
+ }
31
+ else {
32
+ sibling.style.borderRight = '1px solid transparent';
33
+ }
34
+ });
35
+ // Rimuovi il bordo dal fratello precedente
36
+ let previousSibling = item.previousElementSibling;
37
+ if (previousSibling) {
38
+ previousSibling.style.borderRight = '1px solid transparent';
39
+ }
40
+ }
41
+ }
42
+ else {
43
+ item.removeAttribute('active');
44
+ }
45
+ });
46
+ }
47
+ let panel = this.JumpTabEl.querySelectorAll('jump-tab-panel');
48
+ if (panel.length > 0) {
49
+ panel.forEach((panel) => {
50
+ if (panel.getAttribute('identifier') === event.detail.id) {
51
+ panel.setAttribute('active', '');
52
+ }
53
+ else {
54
+ panel.removeAttribute('active');
55
+ }
56
+ });
57
+ }
58
+ }
59
+ componentDidLoad() {
60
+ console.log('Component has been rendered');
61
+ if (this.variant === 'sheet') {
62
+ // Recupera il valore della variabile CSS
63
+ const rootStyles = getComputedStyle(document.documentElement);
64
+ const primaryColor = rootStyles.getPropertyValue('--neutral-grey-secondary').trim();
65
+ // Seleziona tutti gli elementi jump-tab-item
66
+ let items = this.JumpTabEl.querySelectorAll('jump-tab-item');
67
+ if (items.length > 0) {
68
+ items.forEach((item, index) => {
69
+ // Aggiungi bordo destro a tutti tranne:
70
+ // - l'ultimo elemento
71
+ // - l'elemento attivo (avente classe "active")
72
+ if (index === items.length - 1 || item.classList.contains('active')) {
73
+ item.style.borderRight = '1px solid transparent';
74
+ }
75
+ else {
76
+ item.style.borderRight = `1px solid ${primaryColor}`;
77
+ }
78
+ });
79
+ }
80
+ }
18
81
  }
19
82
  render() {
20
- return (h(Host, { key: '6d974852fbbf04550ddd7eaad3dafbf784513c78', class: "JumpTab" }, (this.tabNames && this.activeTab) && this.tabNames.map((tabName) => (h("div", { class: `JumpTab__Tab ${this.activeTab === tabName ? 'active' : ''}` }, tabName)))));
83
+ return (h(Host, { key: '325ebf63677d7b1307ebb5be3d521d06efa22a5a', class: "JumpTab", id: this.tabGroupName, ref: (el) => { this.JumpTabEl = el; } }, h("div", { key: 'afa4eb17c8582aa59f8f3b55237de34fa04871d5', class: "Wrapper " + this.variant }, h("slot", { key: '69023d9ae6ae85ef8270d7c8ea4c881c60889f63', name: "tab-item" })), h("div", { key: '28257b0f8de4c3ef1b7dd7adb58dc2d0ce342164' }, h("slot", { key: '3097cf4876730499e2067aed722ff822582e173f', name: "tab-content" }))));
21
84
  }
22
85
  static get style() { return JumpTabStyle0; }
23
86
  }, [1, "jump-tab", {
24
- "activeTab": [1, "active-tab"],
25
- "tabNames": [16]
26
- }]);
87
+ "tabGroupName": [1, "tab-group-name"],
88
+ "variant": [1]
89
+ }, [[0, "jump-change-active-tab", "changeActiveTabHandler"]]]);
27
90
  function defineCustomElement$1() {
28
91
  if (typeof customElements === "undefined") {
29
92
  return;
@@ -1 +1 @@
1
- {"file":"jump-tab.js","mappings":";;AAAA,MAAM,UAAU,GAAG,sBAAsB,CAAC;AAC1C,sBAAe,UAAU;;MCMZA,SAAO;;;;;yBAGU,SAAS;wBACH,SAAS;;IAE3C,iBAAiB;QACf,OAAO,CAAC,GAAG,CAAC,mCAAmC,CAAC,CAAC;QACjD,OAAO,CAAC,GAAG,CAAC,QAAQ,EAAC,IAAI,CAAC,SAAS,CAAC,CAAC;QACrC,OAAO,CAAC,GAAG,CAAC,UAAU,EAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;KACvC;IAED,MAAM;QACJ,QACE,EAAC,IAAI,qDAAC,KAAK,EAAC,SAAS,IAClB,CAAC,IAAI,CAAC,QAAQ,IAAI,IAAI,CAAC,SAAS,KAAK,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,CAAC,OAAO,MAC9D,WAAK,KAAK,EAAE,gBAAgB,IAAI,CAAC,SAAS,KAAK,OAAO,GAAG,QAAQ,GAAG,EAAE,EAAE,IACrE,OAAO,CACJ,CACP,CAAC,CACG,EACP;KACH;;;;;;;;;;;;;;;;;;;;;;;;;","names":["JumpTab"],"sources":["src/components/jump-tab/jump-tab.scss?tag=jump-tab&encapsulation=shadow","src/components/jump-tab/jump-tab.tsx"],"sourcesContent":[":host {\n display: block;\n}\n","import { Component, Host, Prop, h } from '@stencil/core';\n\n@Component({\n tag: 'jump-tab',\n styleUrl: 'jump-tab.scss',\n shadow: true,\n})\nexport class JumpTab {\n\n /* ---------------------- @PROPERTIES ------------------------- */\n @Prop() activeTab: string = undefined;\n @Prop() tabNames: Array<string> = undefined;\n\n componentWillLoad() {\n console.log('Component is about to be rendered');\n console.log('active',this.activeTab);\n console.log('tabNames',this.tabNames);\n }\n\n render() {\n return (\n <Host class=\"JumpTab\">\n {(this.tabNames && this.activeTab) && this.tabNames.map((tabName) => (\n <div class={`JumpTab__Tab ${this.activeTab === tabName ? 'active' : ''}`}>\n {tabName}\n </div>\n ))}\n </Host>\n );\n }\n\n}\n"],"version":3}
1
+ {"file":"jump-tab.js","mappings":"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","names":["JumpTab"],"sources":["src/components/jump-tab/jump-tab.scss?tag=jump-tab&encapsulation=shadow","src/components/jump-tab/jump-tab.tsx"],"sourcesContent":[":host {\n display: block;\n\n --jump-tab-bg-color: var(--gray-ultralight, #f8f8f8);\n \n .Wrapper {\n display: flex;\n width: fit-content;\n \n &.rounded {\n border-radius: 50px;\n background-color: #f8f8f8; // dovrà andarci var(--jump-tab-bg-color)\n }\n }\n}","import { Component, Host, Event, EventEmitter, Prop, h, Listen } from '@stencil/core';\n\n@Component({\n tag: 'jump-tab',\n styleUrl: 'jump-tab.scss',\n shadow: true,\n})\nexport class JumpTab {\n\n JumpTabEl: HTMLElement;\n /* ---------------------- @PROPERTIES ------------------------- */\n @Prop() tabGroupName: string = undefined;\n\n /**\n * The style of the tab. The same value must be passed to all the items.\n * Choosed from \"inline\", \"boxed\", \"sheet\", \"rounded\"\n */\n @Prop() variant: string = 'inline';\n\n @Event({ eventName: 'jump-change-activetab'}) setActiveTab: EventEmitter;\n\n @Listen('jump-change-active-tab')\n changeActiveTabHandler(event: CustomEvent) {\n this.setActiveTab.emit(event.detail);\n\n // Recupera il valore della variabile CSS\n const rootStyles = getComputedStyle(document.documentElement);\n const primaryColor = rootStyles.getPropertyValue('--neutral-grey-secondary').trim();\n\n let items = this.JumpTabEl.querySelectorAll('jump-tab-item');\n if (items.length > 0) {\n items.forEach((item) => {\n if (item.getAttribute('identifier') === event.detail.id) {\n item.setAttribute('active', '');\n\n if (this.variant === 'sheet') {\n // Aggiungi il bordo ai fratelli dell'elemento attivo tranne l'ultimo\n items.forEach((sibling, index) => {\n if (sibling !== item && index !== items.length - 1) {\n sibling.style.borderRight = `1px solid ${primaryColor}`; // Usa i backticks\n } else {\n sibling.style.borderRight = '1px solid transparent';\n }\n });\n\n // Rimuovi il bordo dal fratello precedente\n let previousSibling = item.previousElementSibling as any;\n if (previousSibling) {\n previousSibling.style.borderRight = '1px solid transparent';\n }\n }\n\n } else {\n item.removeAttribute('active');\n }\n });\n }\n\n let panel = this.JumpTabEl.querySelectorAll('jump-tab-panel');\n if (panel.length > 0) {\n panel.forEach((panel) => {\n if (panel.getAttribute('identifier') === event.detail.id) {\n panel.setAttribute('active', '');\n } else {\n panel.removeAttribute('active');\n }\n });\n }\n }\n\n\n componentDidLoad() {\n console.log('Component has been rendered');\n if(this.variant === 'sheet') {\n // Recupera il valore della variabile CSS\n const rootStyles = getComputedStyle(document.documentElement);\n const primaryColor = rootStyles.getPropertyValue('--neutral-grey-secondary').trim();\n\n // Seleziona tutti gli elementi jump-tab-item\n let items = this.JumpTabEl.querySelectorAll('jump-tab-item');\n if (items.length > 0) {\n items.forEach((item, index) => {\n // Aggiungi bordo destro a tutti tranne:\n // - l'ultimo elemento\n // - l'elemento attivo (avente classe \"active\")\n if (index === items.length - 1 || item.classList.contains('active')) {\n item.style.borderRight = '1px solid transparent';\n } else {\n item.style.borderRight = `1px solid ${primaryColor}`;\n }\n });\n }\n }\n\n }\n\n render() {\n return (\n <Host class=\"JumpTab\" id={this.tabGroupName} ref={(el) => {this.JumpTabEl = el;}}> \n <div class={\"Wrapper \" + this.variant}>\n <slot name=\"tab-item\"></slot>\n </div>\n <div>\n <slot name=\"tab-content\"></slot>\n </div>\n </Host>\n );\n }\n}"],"version":3}
@@ -1,5 +1,5 @@
1
1
  const NAMESPACE = 'jump-design-system';
2
- const BUILD = /* jump-design-system */ { allRenderFn: true, appendChildSlotFix: false, asyncLoading: true, asyncQueue: false, attachStyles: true, cloneNodeFix: false, cmpDidLoad: true, cmpDidRender: false, cmpDidUnload: false, cmpDidUpdate: false, cmpShouldUpdate: false, cmpWillLoad: true, cmpWillRender: false, cmpWillUpdate: false, connectedCallback: false, constructableCSS: true, cssAnnotations: true, devTools: false, disconnectedCallback: false, element: false, event: true, experimentalScopedSlotChanges: false, experimentalSlotFixes: false, formAssociated: false, hasRenderFn: true, hostListener: false, hostListenerTarget: false, hostListenerTargetBody: false, hostListenerTargetDocument: false, hostListenerTargetParent: false, hostListenerTargetWindow: false, hotModuleReplacement: false, hydrateClientSide: false, hydrateServerSide: false, hydratedAttribute: false, hydratedClass: true, initializeNextTick: false, invisiblePrehydration: true, isDebug: false, isDev: false, isTesting: false, lazyLoad: true, lifecycle: true, lifecycleDOMEvents: false, member: true, method: false, mode: false, observeAttribute: true, profile: false, prop: true, propBoolean: true, propMutable: false, propNumber: true, propString: true, reflect: true, scoped: false, scopedSlotTextContentFix: false, scriptDataOpts: false, shadowDelegatesFocus: false, shadowDom: true, slot: true, slotChildNodesFix: false, slotRelocation: true, state: true, style: true, svg: false, taskQueue: true, transformTagName: false, updatable: true, vdomAttribute: true, vdomClass: true, vdomFunctional: false, vdomKey: true, vdomListener: true, vdomPropOrAttr: true, vdomRef: false, vdomRender: true, vdomStyle: false, vdomText: true, vdomXlink: false, watchCallback: true };
2
+ const BUILD = /* jump-design-system */ { allRenderFn: true, appendChildSlotFix: false, asyncLoading: true, asyncQueue: false, attachStyles: true, cloneNodeFix: false, cmpDidLoad: true, cmpDidRender: false, cmpDidUnload: false, cmpDidUpdate: false, cmpShouldUpdate: false, cmpWillLoad: true, cmpWillRender: false, cmpWillUpdate: false, connectedCallback: false, constructableCSS: true, cssAnnotations: true, devTools: false, disconnectedCallback: true, element: false, event: true, experimentalScopedSlotChanges: false, experimentalSlotFixes: false, formAssociated: true, hasRenderFn: true, hostListener: true, hostListenerTarget: true, hostListenerTargetBody: false, hostListenerTargetDocument: false, hostListenerTargetParent: false, hostListenerTargetWindow: true, hotModuleReplacement: false, hydrateClientSide: false, hydrateServerSide: false, hydratedAttribute: false, hydratedClass: true, initializeNextTick: false, invisiblePrehydration: true, isDebug: false, isDev: false, isTesting: false, lazyLoad: true, lifecycle: true, lifecycleDOMEvents: false, member: true, method: true, mode: false, observeAttribute: true, profile: false, prop: true, propBoolean: true, propMutable: true, propNumber: true, propString: true, reflect: true, scoped: false, scopedSlotTextContentFix: false, scriptDataOpts: false, shadowDelegatesFocus: false, shadowDom: true, slot: true, slotChildNodesFix: false, slotRelocation: true, state: true, style: true, svg: false, taskQueue: true, transformTagName: false, updatable: true, vdomAttribute: true, vdomClass: true, vdomFunctional: false, vdomKey: true, vdomListener: true, vdomPropOrAttr: true, vdomRef: true, vdomRender: true, vdomStyle: false, vdomText: true, vdomXlink: false, watchCallback: true };
3
3
 
4
4
  /**
5
5
  * Virtual DOM patching algorithm based on Snabbdom by
@@ -39,6 +39,12 @@ const HYDRATED_CSS = '{visibility:hidden}.hydrated{visibility:inherit}';
39
39
  * support as of Stencil v4.
40
40
  */
41
41
  const SLOT_FB_CSS = 'slot-fb{display:contents}slot-fb[hidden]{display:none}';
42
+ const FORM_ASSOCIATED_CUSTOM_ELEMENT_CALLBACKS = [
43
+ 'formAssociatedCallback',
44
+ 'formResetCallback',
45
+ 'formDisabledCallback',
46
+ 'formStateRestoreCallback',
47
+ ];
42
48
  /**
43
49
  * Default style mode id
44
50
  */
@@ -367,6 +373,12 @@ const setAccessor = (elm, memberName, oldValue, newValue, isSvg, flags) => {
367
373
  }
368
374
  else if (memberName === 'key')
369
375
  ;
376
+ else if (memberName === 'ref') {
377
+ // minifier will clean this up
378
+ if (newValue) {
379
+ newValue(elm);
380
+ }
381
+ }
370
382
  else if ((!isProp ) &&
371
383
  memberName[0] === 'o' &&
372
384
  memberName[1] === 'n') {
@@ -676,6 +688,7 @@ const removeVnodes = (vnodes, startIdx, endIdx) => {
676
688
  const vnode = vnodes[index];
677
689
  if (vnode) {
678
690
  const elm = vnode.$elm$;
691
+ nullifyVNodeRefs(vnode);
679
692
  if (elm) {
680
693
  {
681
694
  // we're removing this element
@@ -1219,6 +1232,19 @@ const isNodeLocatedInSlot = (nodeToRelocate, slotName) => {
1219
1232
  }
1220
1233
  return slotName === '';
1221
1234
  };
1235
+ /**
1236
+ * 'Nullify' any VDom `ref` callbacks on a VDom node or its children by calling
1237
+ * them with `null`. This signals that the DOM element corresponding to the VDom
1238
+ * node has been removed from the DOM.
1239
+ *
1240
+ * @param vNode a virtual DOM node
1241
+ */
1242
+ const nullifyVNodeRefs = (vNode) => {
1243
+ {
1244
+ vNode.$attrs$ && vNode.$attrs$.ref && vNode.$attrs$.ref(null);
1245
+ vNode.$children$ && vNode.$children$.map(nullifyVNodeRefs);
1246
+ }
1247
+ };
1222
1248
  /**
1223
1249
  * The main entry point for Stencil's virtual DOM-based rendering engine
1224
1250
  *
@@ -1436,6 +1462,13 @@ const dispatchHooks = (hostRef, isInitialLoad) => {
1436
1462
  // called in order after `dispatchHooks` exits.
1437
1463
  let maybePromise;
1438
1464
  if (isInitialLoad) {
1465
+ {
1466
+ hostRef.$flags$ |= 256 /* HOST_FLAGS.isListenReady */;
1467
+ if (hostRef.$queuedListeners$) {
1468
+ hostRef.$queuedListeners$.map(([methodName, event]) => safeCall(instance, methodName, event));
1469
+ hostRef.$queuedListeners$ = undefined;
1470
+ }
1471
+ }
1439
1472
  {
1440
1473
  // If `componentWillLoad` returns a `Promise` then we want to wait on
1441
1474
  // whatever's going on in that `Promise` before we launch into
@@ -1589,6 +1622,9 @@ const postUpdateComponent = (hostRef) => {
1589
1622
  else {
1590
1623
  endPostUpdate();
1591
1624
  }
1625
+ {
1626
+ hostRef.$onInstanceResolve$(elm);
1627
+ }
1592
1628
  // load events fire from bottom to top
1593
1629
  // the deepest elements load first then bubbles up
1594
1630
  {
@@ -1692,6 +1728,28 @@ const setValue = (ref, propName, newVal, cmpMeta) => {
1692
1728
  const proxyComponent = (Cstr, cmpMeta, flags) => {
1693
1729
  var _a;
1694
1730
  const prototype = Cstr.prototype;
1731
+ /**
1732
+ * proxy form associated custom element lifecycle callbacks
1733
+ * @ref https://web.dev/articles/more-capable-form-controls#lifecycle_callbacks
1734
+ */
1735
+ if (cmpMeta.$flags$ & 64 /* CMP_FLAGS.formAssociated */ && flags & 1 /* PROXY_FLAGS.isElementConstructor */) {
1736
+ FORM_ASSOCIATED_CUSTOM_ELEMENT_CALLBACKS.forEach((cbName) => Object.defineProperty(prototype, cbName, {
1737
+ value(...args) {
1738
+ const hostRef = getHostRef(this);
1739
+ const instance = hostRef.$lazyInstance$ ;
1740
+ if (!instance) {
1741
+ hostRef.$onReadyPromise$.then((instance) => {
1742
+ const cb = instance[cbName];
1743
+ typeof cb === 'function' && cb.call(instance, ...args);
1744
+ });
1745
+ }
1746
+ else {
1747
+ const cb = instance[cbName];
1748
+ typeof cb === 'function' && cb.call(instance, ...args);
1749
+ }
1750
+ },
1751
+ }));
1752
+ }
1695
1753
  if (cmpMeta.$members$) {
1696
1754
  if (Cstr.watchers) {
1697
1755
  cmpMeta.$watchers$ = Cstr.watchers;
@@ -1715,6 +1773,17 @@ const proxyComponent = (Cstr, cmpMeta, flags) => {
1715
1773
  enumerable: true,
1716
1774
  });
1717
1775
  }
1776
+ else if (flags & 1 /* PROXY_FLAGS.isElementConstructor */ &&
1777
+ memberFlags & 64 /* MEMBER_FLAGS.Method */) {
1778
+ // proxyComponent - method
1779
+ Object.defineProperty(prototype, memberName, {
1780
+ value(...args) {
1781
+ var _a;
1782
+ const ref = getHostRef(this);
1783
+ return (_a = ref === null || ref === void 0 ? void 0 : ref.$onInstancePromise$) === null || _a === void 0 ? void 0 : _a.then(() => { var _a; return (_a = ref.$lazyInstance$) === null || _a === void 0 ? void 0 : _a[memberName](...args); });
1784
+ },
1785
+ });
1786
+ }
1718
1787
  });
1719
1788
  if ((flags & 1 /* PROXY_FLAGS.isElementConstructor */)) {
1720
1789
  const attrNameToPropName = new Map();
@@ -1965,6 +2034,10 @@ const connectedCallback = (elm) => {
1965
2034
  }
1966
2035
  }
1967
2036
  else {
2037
+ // not the first time this has connected
2038
+ // reattach any event listeners to the host
2039
+ // since they would have been removed when disconnected
2040
+ addHostEventListeners(elm, hostRef, cmpMeta.$listeners$);
1968
2041
  // fire off connectedCallback() on component instance
1969
2042
  if (hostRef === null || hostRef === void 0 ? void 0 : hostRef.$lazyInstance$) ;
1970
2043
  else if (hostRef === null || hostRef === void 0 ? void 0 : hostRef.$onReadyPromise$) {
@@ -1986,13 +2059,24 @@ const setContentReference = (elm) => {
1986
2059
  elm.insertBefore(contentRefElm, elm.firstChild);
1987
2060
  };
1988
2061
  const disconnectInstance = (instance) => {
2062
+ {
2063
+ safeCall(instance, 'disconnectedCallback');
2064
+ }
1989
2065
  };
1990
2066
  const disconnectedCallback = async (elm) => {
1991
2067
  if ((plt.$flags$ & 1 /* PLATFORM_FLAGS.isTmpDisconnected */) === 0) {
1992
2068
  const hostRef = getHostRef(elm);
1993
- if (hostRef === null || hostRef === void 0 ? void 0 : hostRef.$lazyInstance$) ;
2069
+ {
2070
+ if (hostRef.$rmListeners$) {
2071
+ hostRef.$rmListeners$.map((rmListener) => rmListener());
2072
+ hostRef.$rmListeners$ = undefined;
2073
+ }
2074
+ }
2075
+ if (hostRef === null || hostRef === void 0 ? void 0 : hostRef.$lazyInstance$) {
2076
+ disconnectInstance(hostRef.$lazyInstance$);
2077
+ }
1994
2078
  else if (hostRef === null || hostRef === void 0 ? void 0 : hostRef.$onReadyPromise$) {
1995
- hostRef.$onReadyPromise$.then(() => disconnectInstance());
2079
+ hostRef.$onReadyPromise$.then(() => disconnectInstance(hostRef.$lazyInstance$));
1996
2080
  }
1997
2081
  }
1998
2082
  };
@@ -2028,6 +2112,9 @@ const bootstrapLazy = (lazyBundles, options = {}) => {
2028
2112
  {
2029
2113
  cmpMeta.$members$ = compactMeta[2];
2030
2114
  }
2115
+ {
2116
+ cmpMeta.$listeners$ = compactMeta[3];
2117
+ }
2031
2118
  {
2032
2119
  cmpMeta.$attrsToReflect$ = [];
2033
2120
  }
@@ -2074,6 +2161,12 @@ const bootstrapLazy = (lazyBundles, options = {}) => {
2074
2161
  return getHostRef(this).$onReadyPromise$;
2075
2162
  }
2076
2163
  };
2164
+ // if the component is formAssociated we need to set that on the host
2165
+ // element so that it will be ready for `attachInternals` to be called on
2166
+ // it later on
2167
+ if (cmpMeta.$flags$ & 64 /* CMP_FLAGS.formAssociated */) {
2168
+ HostElement.formAssociated = true;
2169
+ }
2077
2170
  cmpMeta.$lazyBundleId$ = lazyBundle[0];
2078
2171
  if (!exclude.includes(tagName) && !customElements.get(tagName)) {
2079
2172
  cmpTags.push(tagName);
@@ -2118,6 +2211,45 @@ const bootstrapLazy = (lazyBundles, options = {}) => {
2118
2211
  // Fallback appLoad event
2119
2212
  endBootstrap();
2120
2213
  };
2214
+ const addHostEventListeners = (elm, hostRef, listeners, attachParentListeners) => {
2215
+ if (listeners) {
2216
+ listeners.map(([flags, name, method]) => {
2217
+ const target = getHostListenerTarget(elm, flags) ;
2218
+ const handler = hostListenerProxy(hostRef, method);
2219
+ const opts = hostListenerOpts(flags);
2220
+ plt.ael(target, name, handler, opts);
2221
+ (hostRef.$rmListeners$ = hostRef.$rmListeners$ || []).push(() => plt.rel(target, name, handler, opts));
2222
+ });
2223
+ }
2224
+ };
2225
+ const hostListenerProxy = (hostRef, methodName) => (ev) => {
2226
+ try {
2227
+ {
2228
+ if (hostRef.$flags$ & 256 /* HOST_FLAGS.isListenReady */) {
2229
+ // instance is ready, let's call it's member method for this event
2230
+ hostRef.$lazyInstance$[methodName](ev);
2231
+ }
2232
+ else {
2233
+ (hostRef.$queuedListeners$ = hostRef.$queuedListeners$ || []).push([methodName, ev]);
2234
+ }
2235
+ }
2236
+ }
2237
+ catch (e) {
2238
+ consoleError(e);
2239
+ }
2240
+ };
2241
+ const getHostListenerTarget = (elm, flags) => {
2242
+ if (flags & 8 /* LISTENER_FLAGS.TargetWindow */)
2243
+ return win;
2244
+ return elm;
2245
+ };
2246
+ // prettier-ignore
2247
+ const hostListenerOpts = (flags) => supportsListenerOptions
2248
+ ? ({
2249
+ passive: (flags & 1 /* LISTENER_FLAGS.Passive */) !== 0,
2250
+ capture: (flags & 2 /* LISTENER_FLAGS.Capture */) !== 0,
2251
+ })
2252
+ : (flags & 2 /* LISTENER_FLAGS.Capture */) !== 0;
2121
2253
  /**
2122
2254
  * Assigns the given value to the nonce property on the runtime platform object.
2123
2255
  * During runtime, this value is used to set the nonce attribute on all dynamically created script and style tags.
@@ -2173,11 +2305,15 @@ const registerHost = (hostElement, cmpMeta) => {
2173
2305
  $cmpMeta$: cmpMeta,
2174
2306
  $instanceValues$: new Map(),
2175
2307
  };
2308
+ {
2309
+ hostRef.$onInstancePromise$ = new Promise((r) => (hostRef.$onInstanceResolve$ = r));
2310
+ }
2176
2311
  {
2177
2312
  hostRef.$onReadyPromise$ = new Promise((r) => (hostRef.$onReadyResolve$ = r));
2178
2313
  hostElement['s-p'] = [];
2179
2314
  hostElement['s-rc'] = [];
2180
2315
  }
2316
+ addHostEventListeners(hostElement, hostRef, cmpMeta.$listeners$);
2181
2317
  return hostRefs.set(hostElement, hostRef);
2182
2318
  };
2183
2319
  const isMemberInElement = (elm, memberName) => memberName in elm;
@@ -2216,6 +2352,18 @@ const plt = {
2216
2352
  rel: (el, eventName, listener, opts) => el.removeEventListener(eventName, listener, opts),
2217
2353
  ce: (eventName, opts) => new CustomEvent(eventName, opts),
2218
2354
  };
2355
+ const supportsListenerOptions = /*@__PURE__*/ (() => {
2356
+ let supportsListenerOptions = false;
2357
+ try {
2358
+ doc.addEventListener('e', null, Object.defineProperty({}, 'passive', {
2359
+ get() {
2360
+ supportsListenerOptions = true;
2361
+ },
2362
+ }));
2363
+ }
2364
+ catch (e) { }
2365
+ return supportsListenerOptions;
2366
+ })();
2219
2367
  const promiseResolve = (v) => Promise.resolve(v);
2220
2368
  const supportsConstructableStylesheets = /*@__PURE__*/ (() => {
2221
2369
  try {
@@ -2269,6 +2417,6 @@ const flush = () => {
2269
2417
  const nextTick = (cb) => promiseResolve().then(cb);
2270
2418
  const writeTask = /*@__PURE__*/ queueTask(queueDomWrites, true);
2271
2419
 
2272
- export { Host as H, bootstrapLazy as b, createEvent as c, h, promiseResolve as p, registerInstance as r, setNonce as s };
2420
+ export { Host as H, bootstrapLazy as b, createEvent as c, getElement as g, h, promiseResolve as p, registerInstance as r, setNonce as s };
2273
2421
 
2274
- //# sourceMappingURL=index-192aeaf1.js.map
2422
+ //# sourceMappingURL=index-70f1949a.js.map