@xplortech/apollo-core 3.3.0 → 3.4.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 (370) hide show
  1. package/AGENTS.md +17 -0
  2. package/build/components/dropdown.css +1 -1
  3. package/build/components/icon.css +1 -1
  4. package/build/components/nav-item.css +1 -1
  5. package/build/components/secondary-nav.css +1 -1
  6. package/build/components/top-nav.css +1 -1
  7. package/build/core.css +1 -1
  8. package/build/style.css +1 -1
  9. package/build/variables/apollo.css +1 -0
  10. package/build/variables/field-edge.css +1 -0
  11. package/build/vendor/flatpickr.css +1 -1
  12. package/dist/apollo-core/apollo-core.css +1 -1
  13. package/dist/apollo-core/apollo-core.esm.js +1 -1
  14. package/dist/apollo-core/{p-18486aba.entry.js → p-00e96d61.entry.js} +1 -1
  15. package/dist/apollo-core/{p-439d5cdd.entry.js → p-02a2d1a3.entry.js} +1 -1
  16. package/dist/apollo-core/{p-d204ed1a.entry.js → p-035ed1ad.entry.js} +1 -1
  17. package/dist/apollo-core/{p-af188297.entry.js → p-066d3199.entry.js} +1 -1
  18. package/dist/apollo-core/{p-9955c4f2.entry.js → p-066eccd6.entry.js} +1 -1
  19. package/dist/apollo-core/{p-2b813212.entry.js → p-0e8514ff.entry.js} +1 -1
  20. package/dist/apollo-core/{p-a73b0ca4.entry.js → p-18115cd4.entry.js} +1 -1
  21. package/dist/apollo-core/{p-79d306a2.entry.js → p-19d22455.entry.js} +1 -1
  22. package/dist/apollo-core/{p-9d091b05.entry.js → p-1b00e924.entry.js} +1 -1
  23. package/dist/apollo-core/{p-19fb0e5f.entry.js → p-1ca46c11.entry.js} +1 -1
  24. package/dist/apollo-core/{p-7fd3da3a.entry.js → p-1e07745c.entry.js} +1 -1
  25. package/dist/apollo-core/{p-3e3ab332.entry.js → p-31cbb36f.entry.js} +1 -1
  26. package/dist/apollo-core/{p-cfb00d23.entry.js → p-321319c0.entry.js} +1 -1
  27. package/dist/apollo-core/{p-325a3b43.entry.js → p-3222e5a7.entry.js} +1 -1
  28. package/dist/apollo-core/{p-aece2c3d.entry.js → p-325466bf.entry.js} +1 -1
  29. package/dist/apollo-core/{p-cab7d816.entry.js → p-32ac676a.entry.js} +1 -1
  30. package/dist/apollo-core/{p-6de10879.entry.js → p-33063e8c.entry.js} +1 -1
  31. package/dist/apollo-core/{p-4249ee9b.entry.js → p-34d84be8.entry.js} +1 -1
  32. package/dist/apollo-core/{p-08ea8939.entry.js → p-36965939.entry.js} +1 -1
  33. package/dist/apollo-core/{p-2111cc38.entry.js → p-43fbf2aa.entry.js} +1 -1
  34. package/dist/apollo-core/{p-d1571245.entry.js → p-44a1fd8b.entry.js} +1 -1
  35. package/dist/apollo-core/{p-d9f78325.entry.js → p-462a804c.entry.js} +1 -1
  36. package/dist/apollo-core/{p-38fa8398.entry.js → p-47a4f0a8.entry.js} +1 -1
  37. package/dist/apollo-core/{p-01c55c74.entry.js → p-5cf30b9d.entry.js} +1 -1
  38. package/dist/apollo-core/{p-7f00b542.entry.js → p-606153e1.entry.js} +1 -1
  39. package/dist/apollo-core/{p-17e38eaf.entry.js → p-60e3a798.entry.js} +1 -1
  40. package/dist/apollo-core/{p-a149351a.entry.js → p-663e9521.entry.js} +1 -1
  41. package/dist/apollo-core/{p-b9c85394.entry.js → p-6e22ab86.entry.js} +1 -1
  42. package/dist/apollo-core/{p-fdd1b7da.entry.js → p-7781b569.entry.js} +1 -1
  43. package/dist/apollo-core/{p-73a1c68d.entry.js → p-787a361c.entry.js} +1 -1
  44. package/dist/apollo-core/{p-fc73497e.entry.js → p-7b46b656.entry.js} +1 -1
  45. package/dist/apollo-core/{p-9b757459.entry.js → p-7bfd9cfb.entry.js} +1 -1
  46. package/dist/apollo-core/{p-4b949aeb.entry.js → p-8127dd6b.entry.js} +1 -1
  47. package/dist/apollo-core/{p-3d4a6de1.entry.js → p-88367287.entry.js} +1 -1
  48. package/dist/apollo-core/{p-d13a07ea.entry.js → p-8a59605f.entry.js} +1 -1
  49. package/dist/apollo-core/p-8df2b9e8.entry.js +1 -0
  50. package/dist/apollo-core/{p-e99503a2.entry.js → p-9466f566.entry.js} +1 -1
  51. package/dist/apollo-core/{p-620fc472.entry.js → p-95b6e6e6.entry.js} +1 -1
  52. package/dist/apollo-core/{p-14f5d98a.entry.js → p-966f3702.entry.js} +1 -1
  53. package/dist/apollo-core/{p-cca0f1a2.entry.js → p-9d7ead72.entry.js} +1 -1
  54. package/dist/apollo-core/p-CgJEmBQY.js +3 -0
  55. package/dist/apollo-core/{p-b2dcdb19.entry.js → p-a21c7976.entry.js} +1 -1
  56. package/dist/apollo-core/{p-d060572b.entry.js → p-a30b51c8.entry.js} +1 -1
  57. package/dist/apollo-core/{p-b55951a2.entry.js → p-a3537a74.entry.js} +1 -1
  58. package/dist/apollo-core/{p-6aee7d6b.entry.js → p-ac105b6c.entry.js} +1 -1
  59. package/dist/apollo-core/{p-cd2d73ee.entry.js → p-adc14e6e.entry.js} +1 -1
  60. package/dist/apollo-core/{p-c4fd031e.entry.js → p-b41b7950.entry.js} +1 -1
  61. package/dist/apollo-core/{p-0a7d57ab.entry.js → p-b44a72e9.entry.js} +1 -1
  62. package/dist/apollo-core/{p-e21af3d1.entry.js → p-b6f20359.entry.js} +1 -1
  63. package/dist/apollo-core/{p-dad5d377.entry.js → p-b7f75498.entry.js} +1 -1
  64. package/dist/apollo-core/{p-890c641b.entry.js → p-b9136f21.entry.js} +1 -1
  65. package/dist/apollo-core/{p-e7145461.entry.js → p-c526f16d.entry.js} +1 -1
  66. package/dist/apollo-core/{p-3f8dc5b9.entry.js → p-c7b8a325.entry.js} +1 -1
  67. package/dist/apollo-core/{p-1c2135e3.entry.js → p-c9246567.entry.js} +1 -1
  68. package/dist/apollo-core/{p-b7b91f27.entry.js → p-cc04d4e7.entry.js} +1 -1
  69. package/dist/apollo-core/{p-13253d8f.entry.js → p-cc27a41f.entry.js} +1 -1
  70. package/dist/apollo-core/{p-01ed2bb5.entry.js → p-d58523b6.entry.js} +1 -1
  71. package/dist/apollo-core/{p-a5ddb3c4.entry.js → p-d7fba438.entry.js} +1 -1
  72. package/dist/apollo-core/p-db998e2a.entry.js +1 -0
  73. package/dist/apollo-core/{p-9c7a0229.entry.js → p-e1f095dd.entry.js} +1 -1
  74. package/dist/apollo-core/{p-651b49c3.entry.js → p-e30d204d.entry.js} +1 -1
  75. package/dist/apollo-core/{p-54053547.entry.js → p-e4649020.entry.js} +1 -1
  76. package/dist/apollo-core/{p-9c41d07f.entry.js → p-ebe6a1d6.entry.js} +1 -1
  77. package/dist/apollo-core/{p-d3720611.entry.js → p-f0897ee2.entry.js} +1 -1
  78. package/dist/apollo-core/{p-ba85f686.entry.js → p-f13e14bd.entry.js} +1 -1
  79. package/dist/apollo-core/{p-38a6a53d.entry.js → p-f88eefaf.entry.js} +1 -1
  80. package/dist/apollo-core/{p-9832bc63.entry.js → p-fd2e7bb0.entry.js} +1 -1
  81. package/dist/cjs/apollo-core.cjs.js +1 -1
  82. package/dist/cjs/{index-EdmnG7t8.js → index-CQbPtJas.js} +1 -154
  83. package/dist/cjs/loader.cjs.js +1 -1
  84. package/dist/cjs/xpl-accordion.cjs.entry.js +1 -1
  85. package/dist/cjs/xpl-application-shell.cjs.entry.js +1 -1
  86. package/dist/cjs/xpl-avatar_3.cjs.entry.js +1 -1
  87. package/dist/cjs/xpl-backdrop.cjs.entry.js +1 -1
  88. package/dist/cjs/xpl-badge.cjs.entry.js +1 -1
  89. package/dist/cjs/xpl-banner.cjs.entry.js +1 -1
  90. package/dist/cjs/xpl-breadcrumb-item.cjs.entry.js +1 -1
  91. package/dist/cjs/xpl-breadcrumbs.cjs.entry.js +1 -1
  92. package/dist/cjs/xpl-button-row.cjs.entry.js +1 -1
  93. package/dist/cjs/xpl-button.cjs.entry.js +1 -1
  94. package/dist/cjs/xpl-calendar.cjs.entry.js +2 -2
  95. package/dist/cjs/xpl-checkbox.cjs.entry.js +1 -1
  96. package/dist/cjs/xpl-choicelist.cjs.entry.js +1 -1
  97. package/dist/cjs/xpl-content-area.cjs.entry.js +1 -1
  98. package/dist/cjs/xpl-dashboard.cjs.entry.js +1 -1
  99. package/dist/cjs/xpl-data-card.cjs.entry.js +3 -3
  100. package/dist/cjs/xpl-dropdown_4.cjs.entry.js +1 -1
  101. package/dist/cjs/xpl-dynamic-table-cell.cjs.entry.js +1 -1
  102. package/dist/cjs/xpl-dynamic-table-row.cjs.entry.js +1 -1
  103. package/dist/cjs/xpl-dynamic-table.cjs.entry.js +1 -1
  104. package/dist/cjs/xpl-grid-item.cjs.entry.js +1 -1
  105. package/dist/cjs/xpl-grid.cjs.entry.js +1 -1
  106. package/dist/cjs/xpl-header-accordion.cjs.entry.js +1 -1
  107. package/dist/cjs/xpl-icon.cjs.entry.js +3 -6
  108. package/dist/cjs/xpl-input-color.cjs.entry.js +9 -9
  109. package/dist/cjs/xpl-input-phone.cjs.entry.js +1 -1
  110. package/dist/cjs/xpl-input-time.cjs.entry.js +1 -1
  111. package/dist/cjs/xpl-input_4.cjs.entry.js +4 -4
  112. package/dist/cjs/xpl-large-card.cjs.entry.js +2 -2
  113. package/dist/cjs/xpl-list-item.cjs.entry.js +1 -1
  114. package/dist/cjs/xpl-list.cjs.entry.js +3 -3
  115. package/dist/cjs/xpl-main-nav.cjs.entry.js +1 -1
  116. package/dist/cjs/xpl-modal.cjs.entry.js +1 -1
  117. package/dist/cjs/xpl-nav-header-menu.cjs.entry.js +3 -3
  118. package/dist/cjs/xpl-nav-item.cjs.entry.js +1 -1
  119. package/dist/cjs/xpl-pagination.cjs.entry.js +1 -1
  120. package/dist/cjs/xpl-panel.cjs.entry.js +1 -1
  121. package/dist/cjs/xpl-popover.cjs.entry.js +1 -1
  122. package/dist/cjs/xpl-progress-bar.cjs.entry.js +1 -1
  123. package/dist/cjs/xpl-progress-indicator.cjs.entry.js +1 -1
  124. package/dist/cjs/xpl-secondary-nav.cjs.entry.js +1 -1
  125. package/dist/cjs/xpl-select_2.cjs.entry.js +1 -1
  126. package/dist/cjs/xpl-side-nav-header-item.cjs.entry.js +1 -1
  127. package/dist/cjs/xpl-side-nav-item.cjs.entry.js +1 -1
  128. package/dist/cjs/xpl-side-nav-section.cjs.entry.js +1 -1
  129. package/dist/cjs/xpl-side-nav.cjs.entry.js +3 -3
  130. package/dist/cjs/xpl-skeleton.cjs.entry.js +1 -1
  131. package/dist/cjs/xpl-slideout.cjs.entry.js +1 -1
  132. package/dist/cjs/xpl-spotlight.cjs.entry.js +1 -1
  133. package/dist/cjs/xpl-tab-panel.cjs.entry.js +3 -3
  134. package/dist/cjs/xpl-tab.cjs.entry.js +1 -1
  135. package/dist/cjs/xpl-table-body.cjs.entry.js +1 -1
  136. package/dist/cjs/xpl-table-cell_3.cjs.entry.js +1 -1
  137. package/dist/cjs/xpl-table-footer.cjs.entry.js +1 -1
  138. package/dist/cjs/xpl-table-header.cjs.entry.js +1 -1
  139. package/dist/cjs/xpl-table-row.cjs.entry.js +1 -1
  140. package/dist/cjs/xpl-table.cjs.entry.js +1 -1
  141. package/dist/cjs/xpl-tabs.cjs.entry.js +1 -1
  142. package/dist/cjs/xpl-toast.cjs.entry.js +1 -1
  143. package/dist/cjs/xpl-toggle.cjs.entry.js +1 -1
  144. package/dist/cjs/xpl-toolbar.cjs.entry.js +1 -1
  145. package/dist/cjs/xpl-tooltip.cjs.entry.js +1 -1
  146. package/dist/cjs/xpl-top-nav-item.cjs.entry.js +3 -3
  147. package/dist/cjs/xpl-top-nav-menu.cjs.entry.js +3 -3
  148. package/dist/cjs/xpl-top-nav.cjs.entry.js +6 -6
  149. package/dist/cjs/xpl-utility-bar.cjs.entry.js +1 -1
  150. package/dist/collection/components/xpl-avatar/xpl-avatar.js +8 -8
  151. package/dist/collection/components/xpl-badge/xpl-badge.js +2 -2
  152. package/dist/collection/components/xpl-calendar/xpl-calendar.js +1 -1
  153. package/dist/collection/components/xpl-choicelist/xpl-choicelist.js +1 -1
  154. package/dist/collection/components/xpl-data-card/xpl-data-card.js +2 -2
  155. package/dist/collection/components/xpl-dropdown/xpl-dropdown-group/xpl-dropdown-group.js +1 -1
  156. package/dist/collection/components/xpl-dropdown/xpl-dropdown.js +6 -6
  157. package/dist/collection/components/xpl-icon/xpl-icon.js +2 -12
  158. package/dist/collection/components/xpl-input/xpl-input-color/xpl-input-color.js +8 -8
  159. package/dist/collection/components/xpl-input/xpl-input-date/xpl-input-date.js +3 -3
  160. package/dist/collection/components/xpl-large-card/xpl-large-card.js +1 -1
  161. package/dist/collection/components/xpl-list/xpl-list-item/xpl-list-item.js +2 -2
  162. package/dist/collection/components/xpl-list/xpl-list.js +4 -4
  163. package/dist/collection/components/xpl-popover/xpl-popover.js +2 -2
  164. package/dist/collection/components/xpl-select/xpl-select.js +1 -1
  165. package/dist/collection/components/xpl-side-nav/xpl-side-nav.js +2 -2
  166. package/dist/collection/components/xpl-spotlight/xpl-spotlight.js +4 -4
  167. package/dist/collection/components/xpl-tab/xpl-tab.js +2 -2
  168. package/dist/collection/components/xpl-tab-panel/xpl-tab-panel.js +3 -3
  169. package/dist/collection/components/xpl-table/xpl-table-header-cell/xpl-table-header-cell.js +2 -2
  170. package/dist/collection/components/xpl-table/xpl-table.js +4 -4
  171. package/dist/collection/components/xpl-tag/xpl-tag.js +4 -4
  172. package/dist/collection/components/xpl-top-nav/xpl-nav-header-menu/xpl-nav-header-menu.js +2 -2
  173. package/dist/collection/components/xpl-top-nav/xpl-top-nav-item/xpl-top-nav-item.js +2 -2
  174. package/dist/collection/components/xpl-top-nav/xpl-top-nav-menu/xpl-top-nav-menu.js +2 -2
  175. package/dist/collection/components/xpl-top-nav/xpl-top-nav.js +5 -5
  176. package/dist/components/index.js +1 -1
  177. package/dist/components/{p-Bh-U2qmp.js → p-6-DvgBzG.js} +1 -1
  178. package/dist/components/{p-DHxDWgLP.js → p-B54F4o_Z.js} +1 -1
  179. package/dist/components/{p-Cop4KmAG.js → p-BFUtaXqX.js} +1 -1
  180. package/dist/components/{p-3R1VKKds.js → p-BHRO2whA.js} +1 -1
  181. package/dist/components/{p-CZg3Gb0I.js → p-BKajYWw6.js} +1 -1
  182. package/dist/components/{p-rQFFXcXl.js → p-BU4pW_6c.js} +1 -1
  183. package/dist/components/p-B_6p2HCL.js +1 -0
  184. package/dist/components/{p-BowQ58XR.js → p-Biie85R2.js} +1 -1
  185. package/dist/components/{p-CetimlcM.js → p-CIcKTXQj.js} +1 -1
  186. package/dist/components/{p-n-yq7lf4.js → p-COq-vU2g.js} +1 -1
  187. package/dist/components/{p-ClLyaOG7.js → p-CTy7V3XS.js} +1 -1
  188. package/dist/components/{p-JjlTuq8d.js → p-Cq8V05oj.js} +1 -1
  189. package/dist/components/{p-BZrSTAV1.js → p-CthHapLu.js} +1 -1
  190. package/dist/components/{p-DbN9vTl7.js → p-DGxQJj8d.js} +1 -1
  191. package/dist/components/{p-CcPrBo53.js → p-Dn1Qsv0Y.js} +1 -1
  192. package/dist/components/{p-d4i2Qqvl.js → p-Dn6HsGUr.js} +1 -1
  193. package/dist/components/{p-BNOkHymY.js → p-DxjcChRd.js} +1 -1
  194. package/dist/components/{p-2XxO7M15.js → p-FS6KZMQV.js} +1 -1
  195. package/dist/components/{p-BWAytJnz.js → p-Fj_zi29t.js} +1 -1
  196. package/dist/components/{p-CjzUVpyd.js → p-L9wSxXlk.js} +1 -1
  197. package/dist/components/{p-DORBnmT4.js → p-ULcrhk_V.js} +1 -1
  198. package/dist/components/{p-Dl__XgUD.js → p-WTdJQHaL.js} +1 -1
  199. package/dist/components/{p-CWXfIUHo.js → p-fstojyQr.js} +1 -1
  200. package/dist/components/{p-CfZI7bBe.js → p-gs07oY0j.js} +1 -1
  201. package/dist/components/{p-sjDW_E4p.js → p-nRygucMK.js} +1 -1
  202. package/dist/components/{p-yc1qXhah.js → p-q4zX9LQ0.js} +1 -1
  203. package/dist/components/xpl-accordion.js +1 -1
  204. package/dist/components/xpl-application-shell.js +1 -1
  205. package/dist/components/xpl-avatar.js +1 -1
  206. package/dist/components/xpl-backdrop.js +1 -1
  207. package/dist/components/xpl-badge.js +1 -1
  208. package/dist/components/xpl-banner.js +1 -1
  209. package/dist/components/xpl-breadcrumb-item.js +1 -1
  210. package/dist/components/xpl-breadcrumbs.js +1 -1
  211. package/dist/components/xpl-button-row.js +1 -1
  212. package/dist/components/xpl-button.js +1 -1
  213. package/dist/components/xpl-calendar.js +1 -1
  214. package/dist/components/xpl-checkbox.js +1 -1
  215. package/dist/components/xpl-choicelist.js +1 -1
  216. package/dist/components/xpl-content-area.js +1 -1
  217. package/dist/components/xpl-dashboard.js +1 -1
  218. package/dist/components/xpl-data-card.js +1 -1
  219. package/dist/components/xpl-divider.js +1 -1
  220. package/dist/components/xpl-dropdown-group.js +1 -1
  221. package/dist/components/xpl-dropdown-heading.js +1 -1
  222. package/dist/components/xpl-dropdown-option.js +1 -1
  223. package/dist/components/xpl-dropdown.js +1 -1
  224. package/dist/components/xpl-dynamic-table-cell.js +1 -1
  225. package/dist/components/xpl-dynamic-table-row.js +1 -1
  226. package/dist/components/xpl-dynamic-table.js +1 -1
  227. package/dist/components/xpl-grid-item.js +1 -1
  228. package/dist/components/xpl-grid.js +1 -1
  229. package/dist/components/xpl-header-accordion.js +1 -1
  230. package/dist/components/xpl-icon.js +1 -1
  231. package/dist/components/xpl-input-color.js +1 -1
  232. package/dist/components/xpl-input-date.js +1 -1
  233. package/dist/components/xpl-input-file.js +1 -1
  234. package/dist/components/xpl-input-phone.js +1 -1
  235. package/dist/components/xpl-input-search.js +1 -1
  236. package/dist/components/xpl-input-time.js +1 -1
  237. package/dist/components/xpl-input.js +1 -1
  238. package/dist/components/xpl-large-card.js +1 -1
  239. package/dist/components/xpl-list-item.js +1 -1
  240. package/dist/components/xpl-list.js +1 -1
  241. package/dist/components/xpl-main-nav.js +1 -1
  242. package/dist/components/xpl-modal.js +1 -1
  243. package/dist/components/xpl-nav-header-menu.js +1 -1
  244. package/dist/components/xpl-nav-item.js +1 -1
  245. package/dist/components/xpl-pagination.js +1 -1
  246. package/dist/components/xpl-panel.js +1 -1
  247. package/dist/components/xpl-popover.js +1 -1
  248. package/dist/components/xpl-progress-bar.js +1 -1
  249. package/dist/components/xpl-progress-indicator.js +1 -1
  250. package/dist/components/xpl-radio.js +1 -1
  251. package/dist/components/xpl-secondary-nav.js +1 -1
  252. package/dist/components/xpl-select.js +1 -1
  253. package/dist/components/xpl-side-nav-header-item.js +1 -1
  254. package/dist/components/xpl-side-nav-item.js +1 -1
  255. package/dist/components/xpl-side-nav-section.js +1 -1
  256. package/dist/components/xpl-side-nav.js +1 -1
  257. package/dist/components/xpl-skeleton.js +1 -1
  258. package/dist/components/xpl-slideout.js +1 -1
  259. package/dist/components/xpl-spotlight.js +1 -1
  260. package/dist/components/xpl-tab-panel.js +1 -1
  261. package/dist/components/xpl-tab.js +1 -1
  262. package/dist/components/xpl-table-body.js +1 -1
  263. package/dist/components/xpl-table-cell.js +1 -1
  264. package/dist/components/xpl-table-footer-cell.js +1 -1
  265. package/dist/components/xpl-table-footer.js +1 -1
  266. package/dist/components/xpl-table-header-cell.js +1 -1
  267. package/dist/components/xpl-table-header.js +1 -1
  268. package/dist/components/xpl-table-row.js +1 -1
  269. package/dist/components/xpl-table.js +1 -1
  270. package/dist/components/xpl-tabs.js +1 -1
  271. package/dist/components/xpl-tag.js +1 -1
  272. package/dist/components/xpl-toast.js +1 -1
  273. package/dist/components/xpl-toggle.js +1 -1
  274. package/dist/components/xpl-toolbar.js +1 -1
  275. package/dist/components/xpl-tooltip.js +1 -1
  276. package/dist/components/xpl-top-nav-item.js +1 -1
  277. package/dist/components/xpl-top-nav-menu.js +1 -1
  278. package/dist/components/xpl-top-nav.js +1 -1
  279. package/dist/components/xpl-utility-bar.js +1 -1
  280. package/dist/docs/xpl-avatar/readme.md +1 -1
  281. package/dist/docs/xpl-dropdown/readme.md +10 -1
  282. package/dist/docs/xpl-list/readme.md +1 -1
  283. package/dist/docs/xpl-nav-item/readme.md +1 -1
  284. package/dist/docs/xpl-pagination/readme.md +1 -1
  285. package/dist/docs/xpl-secondary-nav/readme.md +4 -2
  286. package/dist/docs/xpl-toolbar/readme.md +1 -1
  287. package/dist/docs/xpl-top-nav/xpl-nav-header-menu/readme.md +1 -1
  288. package/dist/docs.json +168 -168
  289. package/dist/esm/apollo-core.js +2 -2
  290. package/dist/esm/{index-CJABLO_1.js → index-CgJEmBQY.js} +1 -154
  291. package/dist/esm/loader.js +2 -2
  292. package/dist/esm/xpl-accordion.entry.js +1 -1
  293. package/dist/esm/xpl-application-shell.entry.js +1 -1
  294. package/dist/esm/xpl-avatar_3.entry.js +1 -1
  295. package/dist/esm/xpl-backdrop.entry.js +1 -1
  296. package/dist/esm/xpl-badge.entry.js +1 -1
  297. package/dist/esm/xpl-banner.entry.js +1 -1
  298. package/dist/esm/xpl-breadcrumb-item.entry.js +1 -1
  299. package/dist/esm/xpl-breadcrumbs.entry.js +1 -1
  300. package/dist/esm/xpl-button-row.entry.js +1 -1
  301. package/dist/esm/xpl-button.entry.js +1 -1
  302. package/dist/esm/xpl-calendar.entry.js +2 -2
  303. package/dist/esm/xpl-checkbox.entry.js +1 -1
  304. package/dist/esm/xpl-choicelist.entry.js +1 -1
  305. package/dist/esm/xpl-content-area.entry.js +1 -1
  306. package/dist/esm/xpl-dashboard.entry.js +1 -1
  307. package/dist/esm/xpl-data-card.entry.js +3 -3
  308. package/dist/esm/xpl-dropdown_4.entry.js +1 -1
  309. package/dist/esm/xpl-dynamic-table-cell.entry.js +1 -1
  310. package/dist/esm/xpl-dynamic-table-row.entry.js +1 -1
  311. package/dist/esm/xpl-dynamic-table.entry.js +1 -1
  312. package/dist/esm/xpl-grid-item.entry.js +1 -1
  313. package/dist/esm/xpl-grid.entry.js +1 -1
  314. package/dist/esm/xpl-header-accordion.entry.js +1 -1
  315. package/dist/esm/xpl-icon.entry.js +3 -6
  316. package/dist/esm/xpl-input-color.entry.js +9 -9
  317. package/dist/esm/xpl-input-phone.entry.js +1 -1
  318. package/dist/esm/xpl-input-time.entry.js +1 -1
  319. package/dist/esm/xpl-input_4.entry.js +4 -4
  320. package/dist/esm/xpl-large-card.entry.js +2 -2
  321. package/dist/esm/xpl-list-item.entry.js +1 -1
  322. package/dist/esm/xpl-list.entry.js +3 -3
  323. package/dist/esm/xpl-main-nav.entry.js +1 -1
  324. package/dist/esm/xpl-modal.entry.js +1 -1
  325. package/dist/esm/xpl-nav-header-menu.entry.js +3 -3
  326. package/dist/esm/xpl-nav-item.entry.js +1 -1
  327. package/dist/esm/xpl-pagination.entry.js +1 -1
  328. package/dist/esm/xpl-panel.entry.js +1 -1
  329. package/dist/esm/xpl-popover.entry.js +1 -1
  330. package/dist/esm/xpl-progress-bar.entry.js +1 -1
  331. package/dist/esm/xpl-progress-indicator.entry.js +1 -1
  332. package/dist/esm/xpl-secondary-nav.entry.js +1 -1
  333. package/dist/esm/xpl-select_2.entry.js +1 -1
  334. package/dist/esm/xpl-side-nav-header-item.entry.js +1 -1
  335. package/dist/esm/xpl-side-nav-item.entry.js +1 -1
  336. package/dist/esm/xpl-side-nav-section.entry.js +1 -1
  337. package/dist/esm/xpl-side-nav.entry.js +3 -3
  338. package/dist/esm/xpl-skeleton.entry.js +1 -1
  339. package/dist/esm/xpl-slideout.entry.js +1 -1
  340. package/dist/esm/xpl-spotlight.entry.js +1 -1
  341. package/dist/esm/xpl-tab-panel.entry.js +3 -3
  342. package/dist/esm/xpl-tab.entry.js +1 -1
  343. package/dist/esm/xpl-table-body.entry.js +1 -1
  344. package/dist/esm/xpl-table-cell_3.entry.js +1 -1
  345. package/dist/esm/xpl-table-footer.entry.js +1 -1
  346. package/dist/esm/xpl-table-header.entry.js +1 -1
  347. package/dist/esm/xpl-table-row.entry.js +1 -1
  348. package/dist/esm/xpl-table.entry.js +1 -1
  349. package/dist/esm/xpl-tabs.entry.js +1 -1
  350. package/dist/esm/xpl-toast.entry.js +1 -1
  351. package/dist/esm/xpl-toggle.entry.js +1 -1
  352. package/dist/esm/xpl-toolbar.entry.js +1 -1
  353. package/dist/esm/xpl-tooltip.entry.js +1 -1
  354. package/dist/esm/xpl-top-nav-item.entry.js +3 -3
  355. package/dist/esm/xpl-top-nav-menu.entry.js +3 -3
  356. package/dist/esm/xpl-top-nav.entry.js +6 -6
  357. package/dist/esm/xpl-utility-bar.entry.js +1 -1
  358. package/hydrate/index.js +35 -145
  359. package/hydrate/index.mjs +35 -145
  360. package/package.json +11 -11
  361. package/dist/apollo-core/p-CJABLO_1.js +0 -3
  362. package/dist/apollo-core/p-a2c3a38a.entry.js +0 -1
  363. package/dist/apollo-core/p-ec99c433.entry.js +0 -1
  364. package/dist/collection/components/xpl-icon/xpl-icon.css +0 -5
  365. package/dist/components/p-BqhTjJWq.js +0 -1
  366. /package/dist/{utils → collection/utils}/form-bindings.js +0 -0
  367. /package/dist/{utils → collection/utils}/story-vrt.js +0 -0
  368. /package/dist/types/{third-party.d.ts → types/third-party.d.ts} +0 -0
  369. /package/dist/types/{home/runner/work/apollo/apollo/packages/apollo-core/.stencil/utils → utils}/form-bindings.d.ts +0 -0
  370. /package/dist/types/{home/runner/work/apollo/apollo/packages/apollo-core/.stencil/utils → utils}/story-vrt.d.ts +0 -0
@@ -1 +1 @@
1
- import{r as e,h as r,H as o}from"./p-CJABLO_1.js";const c=class{constructor(r){e(this,r)}render(){return r(o,{key:"1f6a7cae4df63c42c2c3c87bd3a531033d0e04b1",class:"xpl-table-footer",role:"rowgroup"},r("slot",{key:"2b2447283d8fcc7ebf9d48d44e30b98b2af58d9c"}))}};export{c as xpl_table_footer}
1
+ import{r as e,h as r,H as o}from"./p-CgJEmBQY.js";const c=class{constructor(r){e(this,r)}render(){return r(o,{key:"1f6a7cae4df63c42c2c3c87bd3a531033d0e04b1",class:"xpl-table-footer",role:"rowgroup"},r("slot",{key:"2b2447283d8fcc7ebf9d48d44e30b98b2af58d9c"}))}};export{c as xpl_table_footer}
@@ -1 +1 @@
1
- import{r as t,h as s,H as i,g as n}from"./p-CJABLO_1.js";const h=class{constructor(s){t(this,s),this.disabled=!1,this.fullWidth=!1,this.icon="",this.iconOnly=!1,this.iconPosition="start",this.isLoading=!1,this.sentiment="neutral",this.size="default",this.variant="primary"}componentDidRender(){const t=this.el.attributes,s=Object.keys(t).map((t=>Number(t))).filter((s=>{const i=t[s];return i?.name.includes("data-test")||i?.name.includes("aria-")||!1})).reduce(((s,i)=>{const n=t[i];return n&&(s[n.name]=n.value),s}),{}),i=this.el.querySelector("button");i&&Object.entries(s).forEach((([t,s])=>{i.setAttribute(t,s),this.el.removeAttribute(t)}))}handleDisabledClick(t){this.disabled&&(t.preventDefault(),t.stopImmediatePropagation())}renderIcon(){return this.icon?s("xpl-icon",{icon:this.icon}):null}handleLoadingState(t){this.isLoading&&(t.preventDefault(),t.stopPropagation(),t.stopImmediatePropagation())}render(){return s(i,{key:"22c276771971610882e3f2761685fc0194bf4b53",class:{"xpl-button":!0,[`xpl-button--${this.size}`]:!0,[`xpl-button--${this.variant}`]:!0,[`xpl-button--${this.state?this.state:this.sentiment}`]:!0,[this.icon?`xpl-button__icon-position--${this.iconPosition}`:""]:!!this.icon,"xpl-button--full-width":this.fullWidth,"xpl-button--icon-only":this.iconOnly,"xpl-button--disabled":this.disabled,"xpl-button--loading":this.isLoading&&!this.link}},this.link?s("slot",null):s("button",{...this.controlAttrs??{},disabled:this.disabled,onClick:t=>this.handleLoadingState(t),type:!this.isLoading||"submit"!==this.type&&"reset"!==this.type&&void 0!==this.type?this.type:"button",name:this.name,value:this.value,form:this.form,"aria-busy":this.isLoading?"true":void 0},this.icon&&s("span",{class:"xpl-button__icon"},this.renderIcon()),s("slot",null),this.isLoading&&s("span",{class:"xpl-button__loading-overlay","aria-hidden":"true"},s("span",{class:"xpl-button__loading-spinner"},s("xpl-icon",{icon:"loader-4",size:20})))))}get el(){return n(this)}};export{h as xpl_button}
1
+ import{r as t,h as s,H as i,g as n}from"./p-CgJEmBQY.js";const h=class{constructor(s){t(this,s),this.disabled=!1,this.fullWidth=!1,this.icon="",this.iconOnly=!1,this.iconPosition="start",this.isLoading=!1,this.sentiment="neutral",this.size="default",this.variant="primary"}componentDidRender(){const t=this.el.attributes,s=Object.keys(t).map((t=>Number(t))).filter((s=>{const i=t[s];return i?.name.includes("data-test")||i?.name.includes("aria-")||!1})).reduce(((s,i)=>{const n=t[i];return n&&(s[n.name]=n.value),s}),{}),i=this.el.querySelector("button");i&&Object.entries(s).forEach((([t,s])=>{i.setAttribute(t,s),this.el.removeAttribute(t)}))}handleDisabledClick(t){this.disabled&&(t.preventDefault(),t.stopImmediatePropagation())}renderIcon(){return this.icon?s("xpl-icon",{icon:this.icon}):null}handleLoadingState(t){this.isLoading&&(t.preventDefault(),t.stopPropagation(),t.stopImmediatePropagation())}render(){return s(i,{key:"22c276771971610882e3f2761685fc0194bf4b53",class:{"xpl-button":!0,[`xpl-button--${this.size}`]:!0,[`xpl-button--${this.variant}`]:!0,[`xpl-button--${this.state?this.state:this.sentiment}`]:!0,[this.icon?`xpl-button__icon-position--${this.iconPosition}`:""]:!!this.icon,"xpl-button--full-width":this.fullWidth,"xpl-button--icon-only":this.iconOnly,"xpl-button--disabled":this.disabled,"xpl-button--loading":this.isLoading&&!this.link}},this.link?s("slot",null):s("button",{...this.controlAttrs??{},disabled:this.disabled,onClick:t=>this.handleLoadingState(t),type:!this.isLoading||"submit"!==this.type&&"reset"!==this.type&&void 0!==this.type?this.type:"button",name:this.name,value:this.value,form:this.form,"aria-busy":this.isLoading?"true":void 0},this.icon&&s("span",{class:"xpl-button__icon"},this.renderIcon()),s("slot",null),this.isLoading&&s("span",{class:"xpl-button__loading-overlay","aria-hidden":"true"},s("span",{class:"xpl-button__loading-spinner"},s("xpl-icon",{icon:"loader-4",size:20})))))}get el(){return n(this)}};export{h as xpl_button}
@@ -1 +1 @@
1
- import{r as t,h as a,H as s,g as i}from"./p-CJABLO_1.js";import{h as e}from"./p-_r9-FML8.js";const c="graph-content",d=class{constructor(a){t(this,a),this.graphContentPresent=!1,this.leadingIcon=!0,this.tooltipTextSmallStat="",this.tooltipTextStat=""}watchStat(t){this.stat=t}watchShortStat(t){this.shortStat=t}connectedCallback(){this.syncGraphContentSlot(),this.connectGraphContentSlotObserver()}disconnectedCallback(){void 0!==this.graphContentSlotSyncTimeoutId&&(clearTimeout(this.graphContentSlotSyncTimeoutId),this.graphContentSlotSyncTimeoutId=void 0),this.disconnectGraphContentSlotObserver()}componentWillLoad(){this.syncGraphContentSlot()}componentDidLoad(){if(this.link){const t=this.el.getElementsByTagName("a")[0]||this.el.getElementsByTagName("button")[0],a=document.createTextNode(this.name),s=document.createElement("span");s.appendChild(a),t.setAttribute("class","xpl-data-card__anchor"),t.appendChild(s)}}componentWillRender(){this.disconnectGraphContentSlotObserver()}componentDidRender(){this.scheduleGraphContentSlotSync()}connectGraphContentSlotObserver(){this.disconnectGraphContentSlotObserver(),"undefined"!=typeof MutationObserver&&(this.graphContentSlotObserver=new MutationObserver((()=>{this.scheduleGraphContentSlotSync()})),this.graphContentSlotObserver.observe(this.el,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["slot"]}))}disconnectGraphContentSlotObserver(){this.graphContentSlotObserver?.disconnect(),this.graphContentSlotObserver=void 0}scheduleGraphContentSlotSync(){void 0!==this.graphContentSlotSyncTimeoutId&&clearTimeout(this.graphContentSlotSyncTimeoutId),this.graphContentSlotSyncTimeoutId=setTimeout((()=>{this.graphContentSlotSyncTimeoutId=void 0,this.el.isConnected&&(this.syncGraphContentSlot(),this.connectGraphContentSlotObserver())}),0)}syncGraphContentSlot(){const t=e(this.el,c);t!==this.graphContentPresent&&(this.graphContentPresent=t)}render(){const t="positive"===this.smallStatVariant?"arrow-up-right":"negative"===this.smallStatVariant?"arrow-down-right":"dash";return a(s,{key:"67600ec3bea7c67b0adaab720343a44f29a56dd4",role:"group",class:"xpl-data-card "+(this.link?"xpl-data-card__link":""),tabindex:"0"},a("dt",{key:"f49af2614c4dd8eb478bba583c30a9417f45e7f6",class:"xpl-data-card__header xpl-data-card__header--"+("secondary"===this.variant?"secondary":"primary")},a("header",{key:"65fbdb3e3d1676b2b3424fca802f62069e67371e"},!!this.leadingIcon&&this.icon&&a("span",{key:"969a2f56c7a6574fb4259efdb7dfcba236e99ccf",class:`xpl-data-card__icon--${this.variant}`},a("xpl-icon",{key:"b1ccdddd1934feded858fea2170f8226738a30ad",icon:this.icon,"background-color":"secondary"===this.variant?"purple":"orange",size:20})),a("slot",{key:"16872a96b96f7f34bf4ac1f36aef388366899b0d",name:"title"},this.name)),this.link&&a("span",{key:"22fc5c8d7b82689c1e3fd10fb5240df957ea0bb6",class:"xpl-data-card__header-arrow"},a("xpl-icon",{key:"b32326c05e48e6aae857da7ea809e553715cb17e",icon:"chevron-right",size:16}))),a("dd",{key:"462b54b42a2bfdb66e2e7cb816578b46abac2281",class:"xpl-data-card__body"},a("div",{key:"617fe8c2c07d22523a3e233eea84e8509a3665e5",class:"xpl-data-card__left"},a("span",{key:"6fc8a0c0b525574ab0e7b1f8787b445805a2c477",class:"xpl-data-card-stat xpl-data-card-stat--long"},this.stat),this.tooltipTextStat?a("xpl-tooltip",{text:this.tooltipTextStat},a("div",{class:"xpl-data-card-stat xpl-data-card-stat--short"},this.shortStat?this.shortStat:this.stat)):a("div",{class:"xpl-data-card-stat xpl-data-card-stat--short"},a("abbr",{title:this.stat},this.shortStat?this.shortStat:this.stat)),this.smallStatVariant?this.tooltipTextSmallStat?a("xpl-tooltip",{text:this.tooltipTextSmallStat},a("div",{class:`xpl-data-card-stat xpl-data-card-stat--small ${this.smallStatVariant}`},a("xpl-icon",{icon:t,size:16}),this.smallStat)):a("div",{class:`xpl-data-card-stat xpl-data-card-stat--small ${this.smallStatVariant}`},a("xpl-icon",{icon:t,size:16}),this.smallStat):this.smallStatIcon&&(this.tooltipTextSmallStat?a("xpl-tooltip",{text:this.tooltipTextSmallStat},a("div",{class:"xpl-data-card-stat xpl-data-card-stat--small"},a("xpl-icon",{icon:this.smallStatIcon,size:16}),this.smallStat)):a("div",{class:"xpl-data-card-stat xpl-data-card-stat--small"},a("xpl-icon",{icon:this.smallStatIcon,size:16}),this.smallStat)),!!this.detail&&a("span",{key:"800c59505dfa7a9c6c8146d8722b5d941df198a3",class:"xpl-data-card__detail"},this.detail)),this.graphContentPresent&&a("div",{key:"4edecaf0e2a361e0dc676f33ed46efcaeb357148",class:"xpl-data-card__right"},a("slot",{key:"3bbb230c30e850f16376079e2bdac5fe7b13686c",name:c}))))}get el(){return i(this)}static get watchers(){return{stat:[{watchStat:0}],shortStat:[{watchShortStat:0}]}}};export{d as xpl_data_card}
1
+ import{r as t,h as a,H as s,g as i}from"./p-CgJEmBQY.js";import{h as e}from"./p-_r9-FML8.js";const d="graph-content",c=class{constructor(a){t(this,a),this.graphContentPresent=!1,this.leadingIcon=!0,this.tooltipTextSmallStat="",this.tooltipTextStat=""}watchStat(t){this.stat=t}watchShortStat(t){this.shortStat=t}connectedCallback(){this.syncGraphContentSlot(),this.connectGraphContentSlotObserver()}disconnectedCallback(){void 0!==this.graphContentSlotSyncTimeoutId&&(clearTimeout(this.graphContentSlotSyncTimeoutId),this.graphContentSlotSyncTimeoutId=void 0),this.disconnectGraphContentSlotObserver()}componentWillLoad(){this.syncGraphContentSlot()}componentDidLoad(){if(this.link){const t=this.el.getElementsByTagName("a")[0]||this.el.getElementsByTagName("button")[0],a=document.createTextNode(this.name),s=document.createElement("span");s.appendChild(a),t.setAttribute("class","xpl-data-card__anchor"),t.appendChild(s)}}componentWillRender(){this.disconnectGraphContentSlotObserver()}componentDidRender(){this.scheduleGraphContentSlotSync()}connectGraphContentSlotObserver(){this.disconnectGraphContentSlotObserver(),"undefined"!=typeof MutationObserver&&(this.graphContentSlotObserver=new MutationObserver((()=>{this.scheduleGraphContentSlotSync()})),this.graphContentSlotObserver.observe(this.el,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["slot"]}))}disconnectGraphContentSlotObserver(){this.graphContentSlotObserver?.disconnect(),this.graphContentSlotObserver=void 0}scheduleGraphContentSlotSync(){void 0!==this.graphContentSlotSyncTimeoutId&&clearTimeout(this.graphContentSlotSyncTimeoutId),this.graphContentSlotSyncTimeoutId=setTimeout((()=>{this.graphContentSlotSyncTimeoutId=void 0,this.el.isConnected&&(this.syncGraphContentSlot(),this.connectGraphContentSlotObserver())}),0)}syncGraphContentSlot(){const t=e(this.el,d);t!==this.graphContentPresent&&(this.graphContentPresent=t)}render(){const t="positive"===this.smallStatVariant?"arrow-up-right":"negative"===this.smallStatVariant?"arrow-down-right":"dash";return a(s,{key:"fb91175354152014c8369bcae8185f2f0a071178",role:"group",class:"xpl-data-card "+(this.link?"xpl-data-card__link":""),tabindex:"0"},a("dt",{key:"3b8b2ff2bb78c57f791e3f9b4140ea7acfa92b8f",class:"xpl-data-card__header xpl-data-card__header--"+("secondary"===this.variant?"secondary":"primary")},a("header",{key:"6fc0bfd1e215d7287ec0f458281e63f758338b10"},!!this.leadingIcon&&this.icon&&a("span",{key:"f5e05a6211c9e2dc7af4284f86f20d20d77c9303",class:`xpl-data-card__icon--${this.variant}`},a("xpl-icon",{key:"05a8e87ce2af58503f2d1eeff62a1ac28f121aa4",icon:this.icon,"background-color":"secondary"===this.variant?"purple":"orange",size:20})),a("slot",{key:"b0516cf5536fddad413546864414ad631098a982",name:"title"},this.name)),this.link&&a("span",{key:"4a63943da50d3d70e3875928ad74f326d16396f6",class:"xpl-data-card__header-arrow"},a("xpl-icon",{key:"af56c3a9e0f2fc683397aa0b1987f4e98318908a",icon:"chevron-right",size:16}))),a("dd",{key:"7b7df42e84bef6a3dd191d5171471380089be754",class:"xpl-data-card__body"},a("div",{key:"5d59246ce0a1e9b068fd99ad7f15260e668e2f26",class:"xpl-data-card__left"},a("span",{key:"0f6071510c55952ae5ceb031d9c15a648018ade4",class:"xpl-data-card-stat xpl-data-card-stat--long"},this.stat),this.tooltipTextStat?a("xpl-tooltip",{text:this.tooltipTextStat},a("div",{class:"xpl-data-card-stat xpl-data-card-stat--short"},this.shortStat?this.shortStat:this.stat)):a("div",{class:"xpl-data-card-stat xpl-data-card-stat--short"},a("abbr",{title:this.stat},this.shortStat?this.shortStat:this.stat)),this.smallStatVariant?this.tooltipTextSmallStat?a("xpl-tooltip",{text:this.tooltipTextSmallStat},a("div",{class:`xpl-data-card-stat xpl-data-card-stat--small ${this.smallStatVariant}`},a("xpl-icon",{icon:t,size:16}),this.smallStat)):a("div",{class:`xpl-data-card-stat xpl-data-card-stat--small ${this.smallStatVariant}`},a("xpl-icon",{icon:t,size:16}),this.smallStat):this.smallStatIcon&&(this.tooltipTextSmallStat?a("xpl-tooltip",{text:this.tooltipTextSmallStat},a("div",{class:"xpl-data-card-stat xpl-data-card-stat--small"},a("xpl-icon",{icon:this.smallStatIcon,size:16}),this.smallStat)):a("div",{class:"xpl-data-card-stat xpl-data-card-stat--small"},a("xpl-icon",{icon:this.smallStatIcon,size:16}),this.smallStat)),!!this.detail&&a("span",{key:"d412ffb9b685d8d74b6e5acefc1acb67e6edb04c",class:"xpl-data-card__detail"},this.detail)),this.graphContentPresent&&a("div",{key:"bb050d82e4babcc083945c8cc23159476063858e",class:"xpl-data-card__right"},a("slot",{key:"12b236efcc601e022b75b20223b234d385d7ff4a",name:d}))))}get el(){return i(this)}static get watchers(){return{stat:[{watchStat:0}],shortStat:[{watchShortStat:0}]}}};export{c as xpl_data_card}
@@ -1 +1 @@
1
- import{r as e,c as t,h as i,H as s,g as a}from"./p-CJABLO_1.js";const n=class{constructor(i){e(this,i),this.navigate=t(this,"navigate",7),this.hasLeadingSlot=!1,this.hasTrailingSlot=!1,this.selected=!1,this.type="product-label",this.handleClick=()=>{"sub-account"===this.type&&this.navigate.emit()}}connectedCallback(){this.syncSlots(),this.connectSlotObserver()}disconnectedCallback(){void 0!==this.slotSyncTimeoutId&&(clearTimeout(this.slotSyncTimeoutId),this.slotSyncTimeoutId=void 0),this.disconnectSlotObserver()}componentWillLoad(){this.syncSlots()}componentWillRender(){this.disconnectSlotObserver()}componentDidRender(){this.scheduleSlotSync()}connectSlotObserver(){this.disconnectSlotObserver(),"undefined"!=typeof MutationObserver&&(this.slotObserver=new MutationObserver((()=>{this.scheduleSlotSync()})),this.slotObserver.observe(this.el,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["slot"]}))}disconnectSlotObserver(){this.slotObserver?.disconnect(),this.slotObserver=void 0}scheduleSlotSync(){void 0!==this.slotSyncTimeoutId&&clearTimeout(this.slotSyncTimeoutId),this.slotSyncTimeoutId=setTimeout((()=>{this.slotSyncTimeoutId=void 0,this.el.isConnected&&(this.syncSlots(),this.connectSlotObserver())}),0)}syncSlots(){const e=e=>e.closest("xpl-side-nav-header-item")===this.el,t=Array.from(this.el.querySelectorAll('[slot="leading"]')).some(e),i=Array.from(this.el.querySelectorAll('[slot="trailing"]')).some(e);t!==this.hasLeadingSlot&&(this.hasLeadingSlot=t),i!==this.hasTrailingSlot&&(this.hasTrailingSlot=i)}render(){const e="sub-account"===this.type,t=!!this.icon||this.hasLeadingSlot,a=e&&!this.label?.trim()?"Sub-account":void 0,n=e&&!this.hasTrailingSlot,h=this.hasTrailingSlot||n,l=t?i("span",{class:"xpl-side-nav-header-item__leading"},i("slot",{name:"leading"},this.icon?i("xpl-icon",{icon:this.icon,size:16}):null)):null,d=h?i("span",{class:"xpl-side-nav-header-item__trailing","aria-hidden":n?"true":void 0},i("slot",{name:"trailing"},n?i("xpl-icon",{icon:"chevron-expand-y",size:16}):null)):null,r=i("span",{key:"3ea94d1fda38199a65303a9bf911de4a7d48aacc",class:"xpl-side-nav-header-item__content"},l,i("span",{key:"a3f369eb6e7bb4e9a283e8f525a356b152d9c017",class:"xpl-side-nav-header-item__label"},this.label??""),d);return i(s,{key:"d979308c18fd071483cbbe8301ed90ffb842a9ac",class:{"xpl-side-nav-header-item":!0,"xpl-side-nav-header-item--product-label":!e,"xpl-side-nav-header-item--sub-account":e,"xpl-side-nav-header-item--selected":e&&this.selected}},e?i("button",{type:"button",class:"xpl-side-nav-header-item__header","aria-current":this.selected?"true":void 0,"aria-label":a,onClick:this.handleClick},r):i("div",{class:"xpl-side-nav-header-item__header"},r))}get el(){return a(this)}};export{n as xpl_side_nav_header_item}
1
+ import{r as e,c as t,h as i,H as s,g as a}from"./p-CgJEmBQY.js";const n=class{constructor(i){e(this,i),this.navigate=t(this,"navigate",7),this.hasLeadingSlot=!1,this.hasTrailingSlot=!1,this.selected=!1,this.type="product-label",this.handleClick=()=>{"sub-account"===this.type&&this.navigate.emit()}}connectedCallback(){this.syncSlots(),this.connectSlotObserver()}disconnectedCallback(){void 0!==this.slotSyncTimeoutId&&(clearTimeout(this.slotSyncTimeoutId),this.slotSyncTimeoutId=void 0),this.disconnectSlotObserver()}componentWillLoad(){this.syncSlots()}componentWillRender(){this.disconnectSlotObserver()}componentDidRender(){this.scheduleSlotSync()}connectSlotObserver(){this.disconnectSlotObserver(),"undefined"!=typeof MutationObserver&&(this.slotObserver=new MutationObserver((()=>{this.scheduleSlotSync()})),this.slotObserver.observe(this.el,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["slot"]}))}disconnectSlotObserver(){this.slotObserver?.disconnect(),this.slotObserver=void 0}scheduleSlotSync(){void 0!==this.slotSyncTimeoutId&&clearTimeout(this.slotSyncTimeoutId),this.slotSyncTimeoutId=setTimeout((()=>{this.slotSyncTimeoutId=void 0,this.el.isConnected&&(this.syncSlots(),this.connectSlotObserver())}),0)}syncSlots(){const e=e=>e.closest("xpl-side-nav-header-item")===this.el,t=Array.from(this.el.querySelectorAll('[slot="leading"]')).some(e),i=Array.from(this.el.querySelectorAll('[slot="trailing"]')).some(e);t!==this.hasLeadingSlot&&(this.hasLeadingSlot=t),i!==this.hasTrailingSlot&&(this.hasTrailingSlot=i)}render(){const e="sub-account"===this.type,t=!!this.icon||this.hasLeadingSlot,a=e&&!this.label?.trim()?"Sub-account":void 0,n=e&&!this.hasTrailingSlot,h=this.hasTrailingSlot||n,l=t?i("span",{class:"xpl-side-nav-header-item__leading"},i("slot",{name:"leading"},this.icon?i("xpl-icon",{icon:this.icon,size:16}):null)):null,d=h?i("span",{class:"xpl-side-nav-header-item__trailing","aria-hidden":n?"true":void 0},i("slot",{name:"trailing"},n?i("xpl-icon",{icon:"chevron-expand-y",size:16}):null)):null,r=i("span",{key:"3ea94d1fda38199a65303a9bf911de4a7d48aacc",class:"xpl-side-nav-header-item__content"},l,i("span",{key:"a3f369eb6e7bb4e9a283e8f525a356b152d9c017",class:"xpl-side-nav-header-item__label"},this.label??""),d);return i(s,{key:"d979308c18fd071483cbbe8301ed90ffb842a9ac",class:{"xpl-side-nav-header-item":!0,"xpl-side-nav-header-item--product-label":!e,"xpl-side-nav-header-item--sub-account":e,"xpl-side-nav-header-item--selected":e&&this.selected}},e?i("button",{type:"button",class:"xpl-side-nav-header-item__header","aria-current":this.selected?"true":void 0,"aria-label":a,onClick:this.handleClick},r):i("div",{class:"xpl-side-nav-header-item__header"},r))}get el(){return a(this)}};export{n as xpl_side_nav_header_item}
@@ -1 +1 @@
1
- import{r as s,h as t,H as r}from"./p-CJABLO_1.js";const e=class{constructor(t){s(this,t),this.currentStep=0,this.layout="horizontal",this.showLabels=!0,this.showNumbers=!0}validateCurrentStep(){if(!this.steps||0===this.steps.length)return;const s=this.steps.length;this.currentStep<0?this.currentStep=0:this.currentStep>s&&(this.currentStep=s)}renderStepContent(s,r){return r?t("xpl-icon",{icon:"check-2",size:20,class:"xpl-progress-indicator-step-checkmark"}):this.showNumbers?t("span",{class:"xpl-progress-indicator-step-number"},s+1):t("span",{class:"xpl-progress-indicator-step-dot"})}renderStep(s,r){const e=this.currentStep>r,i=this.currentStep===r,o="horizontal"===this.layout,a=t("div",{class:"xpl-progress-indicator-step-circle"},this.renderStepContent(r,e)),p=this.showLabels&&t("div",{class:"xpl-progress-indicator-step-text"},s),c=o?t("div",{class:"xpl-progress-indicator-step-content"},a,p):[a,p];return t("div",{class:{"xpl-progress-indicator-step":!0,"xpl-progress-indicator-step-active":i,"xpl-progress-indicator-step-finished":e},role:"listitem","aria-label":`${s}, ${e?"completed":i?"current":"upcoming"}`,"aria-current":i?"step":void 0},c)}render(){const s=this.steps||[],e={"xpl-progress-indicator":!0,"xpl-progress-indicator-horizontal":"horizontal"===this.layout,"xpl-progress-indicator-vertical":"vertical"===this.layout,"xpl-progress-indicator-no-labels":!this.showLabels},i=s.length,o=this.currentStep>=i,a=Math.min(this.currentStep+1,i);return t(r,{key:"fd361d06ed53a837d2f585f4c7d1d212cf6cad9b",class:e,role:"group","aria-label":i>0?o?`Progress: all ${i} ${1===i?"step":"steps"} complete`:`Progress: step ${a} of ${i}`:"Progress"},t("div",{key:"88f819d70853796e7330bce7aab6a457c2ef959f",class:"xpl-progress-indicator-container",role:"list"},s.map(((s,t)=>this.renderStep(s,t)))))}static get watchers(){return{steps:[{validateCurrentStep:0}],currentStep:[{validateCurrentStep:0}]}}};export{e as xpl_progress_indicator}
1
+ import{r as s,h as t,H as r}from"./p-CgJEmBQY.js";const e=class{constructor(t){s(this,t),this.currentStep=0,this.layout="horizontal",this.showLabels=!0,this.showNumbers=!0}validateCurrentStep(){if(!this.steps||0===this.steps.length)return;const s=this.steps.length;this.currentStep<0?this.currentStep=0:this.currentStep>s&&(this.currentStep=s)}renderStepContent(s,r){return r?t("xpl-icon",{icon:"check-2",size:20,class:"xpl-progress-indicator-step-checkmark"}):this.showNumbers?t("span",{class:"xpl-progress-indicator-step-number"},s+1):t("span",{class:"xpl-progress-indicator-step-dot"})}renderStep(s,r){const e=this.currentStep>r,i=this.currentStep===r,o="horizontal"===this.layout,a=t("div",{class:"xpl-progress-indicator-step-circle"},this.renderStepContent(r,e)),p=this.showLabels&&t("div",{class:"xpl-progress-indicator-step-text"},s),c=o?t("div",{class:"xpl-progress-indicator-step-content"},a,p):[a,p];return t("div",{class:{"xpl-progress-indicator-step":!0,"xpl-progress-indicator-step-active":i,"xpl-progress-indicator-step-finished":e},role:"listitem","aria-label":`${s}, ${e?"completed":i?"current":"upcoming"}`,"aria-current":i?"step":void 0},c)}render(){const s=this.steps||[],e={"xpl-progress-indicator":!0,"xpl-progress-indicator-horizontal":"horizontal"===this.layout,"xpl-progress-indicator-vertical":"vertical"===this.layout,"xpl-progress-indicator-no-labels":!this.showLabels},i=s.length,o=this.currentStep>=i,a=Math.min(this.currentStep+1,i);return t(r,{key:"fd361d06ed53a837d2f585f4c7d1d212cf6cad9b",class:e,role:"group","aria-label":i>0?o?`Progress: all ${i} ${1===i?"step":"steps"} complete`:`Progress: step ${a} of ${i}`:"Progress"},t("div",{key:"88f819d70853796e7330bce7aab6a457c2ef959f",class:"xpl-progress-indicator-container",role:"list"},s.map(((s,t)=>this.renderStep(s,t)))))}static get watchers(){return{steps:[{validateCurrentStep:0}],currentStep:[{validateCurrentStep:0}]}}};export{e as xpl_progress_indicator}
@@ -1 +1 @@
1
- import{r as t,c as s,h as i,H as e}from"./p-CJABLO_1.js";import{f as a}from"./p-CH4yJ6Qx.js";import{i as o}from"./p-Dqb1pIRo.js";import{v as n}from"./p-CK3_k8jD.js";const r=(t=!1)=>`<svg width="8" height="12" viewBox="0 0 8 12" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="${t?"M0.557948 5.6813L6.06209 0.132167C6.23831 -0.0440556 6.52327 -0.0440556 6.69949 0.132167L7.44187 0.874551C7.61809 1.05077 7.61809 1.33573 7.44187 1.51195L2.99882 6L7.44187 10.488C7.61809 10.6643 7.61809 10.9492 7.44187 11.1254L6.69949 11.8678C6.52327 12.0441 6.23831 12.0441 6.06209 11.8678L0.557948 6.3187C0.381726 6.14248 0.381726 5.85752 0.557948 5.6813Z":"M7.44187 6.3187L1.93773 11.8678C1.76151 12.0441 1.47655 12.0441 1.30033 11.8678L0.557948 11.1254C0.381726 10.9492 0.381726 10.6643 0.557948 10.488L5.001 6L0.557948 1.51195C0.381726 1.33573 0.381726 1.05077 0.557948 0.874551L1.30033 0.132167C1.47655 -0.0440556 1.76151 -0.0440556 1.93773 0.132167L7.44187 5.6813C7.6181 5.85752 7.6181 6.14248 7.44187 6.3187Z"}" /></svg>`,h=class{constructor(i){t(this,i),this.dateSelected=s(this,"dateSelected",7),this.inputId=n(),this.dateFormat="Y-m-d",this.mode="single"}async setDate(t){void 0!==this.flatpickrInstance&&("single"===this.mode&&"string"==typeof t||"range"===this.mode&&Array.isArray(t))&&this.flatpickrInstance.setDate(t)}componentWillLoad(){this.calendarInputId=this.inputId??""}componentDidLoad(){o()&&(this.flatpickrInstance=a(this.inputElement,{allowInput:!0,dateFormat:this.dateFormat,defaultDate:this.defaultDate,maxDate:this.max,minDate:this.min,mode:this.mode,nextArrow:r(),prevArrow:r(!0),inline:!0,monthSelectorType:"dropdown",onChange:t=>{this.dateSelected.emit("single"===this.mode?t[0]?.toISOString():t.map((t=>t.toISOString())))}}))}disconnectedCallback(){void 0!==this.flatpickrInstance&&this.flatpickrInstance.destroy()}render(){return i(e,{key:"9482590a1f610ab97fa222cc4b7dd1c5d39646ce",class:"xpl-calendar"},i("input",{key:"1222dcda2f73a3bb174410a2a05c39d1f0614c7e",class:"xpl-calendar-input",type:"text",id:this.calendarInputId,ref:t=>{t&&(this.inputElement=t)}}))}};export{h as xpl_calendar}
1
+ import{r as t,c as s,h as i,H as e}from"./p-CgJEmBQY.js";import{f as a}from"./p-CH4yJ6Qx.js";import{i as o}from"./p-Dqb1pIRo.js";import{v as n}from"./p-CK3_k8jD.js";const r=(t=!1)=>`<svg width="8" height="12" viewBox="0 0 8 12" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="${t?"M0.557948 5.6813L6.06209 0.132167C6.23831 -0.0440556 6.52327 -0.0440556 6.69949 0.132167L7.44187 0.874551C7.61809 1.05077 7.61809 1.33573 7.44187 1.51195L2.99882 6L7.44187 10.488C7.61809 10.6643 7.61809 10.9492 7.44187 11.1254L6.69949 11.8678C6.52327 12.0441 6.23831 12.0441 6.06209 11.8678L0.557948 6.3187C0.381726 6.14248 0.381726 5.85752 0.557948 5.6813Z":"M7.44187 6.3187L1.93773 11.8678C1.76151 12.0441 1.47655 12.0441 1.30033 11.8678L0.557948 11.1254C0.381726 10.9492 0.381726 10.6643 0.557948 10.488L5.001 6L0.557948 1.51195C0.381726 1.33573 0.381726 1.05077 0.557948 0.874551L1.30033 0.132167C1.47655 -0.0440556 1.76151 -0.0440556 1.93773 0.132167L7.44187 5.6813C7.6181 5.85752 7.6181 6.14248 7.44187 6.3187Z"}" /></svg>`,h=class{constructor(i){t(this,i),this.dateSelected=s(this,"dateSelected",7),this.inputId=n(),this.dateFormat="Y-m-d",this.mode="single"}async setDate(t){void 0!==this.flatpickrInstance&&("single"===this.mode&&"string"==typeof t||"range"===this.mode&&Array.isArray(t))&&this.flatpickrInstance.setDate(t)}componentWillLoad(){this.calendarInputId=this.inputId??""}componentDidLoad(){o()&&(this.flatpickrInstance=a(this.inputElement,{allowInput:!0,dateFormat:this.dateFormat,defaultDate:this.defaultDate,maxDate:this.max,minDate:this.min,mode:this.mode,nextArrow:r(),prevArrow:r(!0),inline:!0,monthSelectorType:"dropdown",onChange:t=>{this.dateSelected.emit("single"===this.mode?t[0]?.toISOString():t.map((t=>t.toISOString())))}}))}disconnectedCallback(){void 0!==this.flatpickrInstance&&this.flatpickrInstance.destroy()}render(){return i(e,{key:"a3fe8d5cf72542a8780abff18083667f0bedf2f7",class:"xpl-calendar"},i("input",{key:"3aa859f2f540ba6c04b1347e0b7d339322a181ab",class:"xpl-calendar-input",type:"text",id:this.calendarInputId,ref:t=>{t&&(this.inputElement=t)}}))}};export{h as xpl_calendar}
@@ -1 +1 @@
1
- import{r as e,c as t,h as a,H as s,g as i}from"./p-CJABLO_1.js";let l=0;const d=class{constructor(a){e(this,a),this.modalClosed=t(this,"modalClosed",7),this.dialogElement=null,this.titleId=`xpl-modal-title-${l+=1}`,this.isOpen=!1,this.size="medium",this.variant="default",this.handleDialogClose=()=>{this.isOpen=!1,this.modalClosed.emit()},this.handleNativeBackdropClick=e=>{const{dialogElement:t}=this;if(!t||e.target!==t)return;const a=t.getBoundingClientRect();(e.clientX<a.left||e.clientX>a.right||e.clientY<a.top||e.clientY>a.bottom)&&this.handleDialogClose()}}connectedCallback(){this.bindDialog()}disconnectedCallback(){this.clearCloseTimer(),this.unbindDialog()}componentDidLoad(){this.bindDialog()}updateModalState(){this.clearCloseTimer(),this.isOpen?this.openDialog():this.scheduleClose()}bindDialog(){const e=this.element.querySelector("dialog");e&&(this.dialogElement=e,e.removeEventListener("cancel",this.handleDialogClose),e.removeEventListener("click",this.handleNativeBackdropClick),e.addEventListener("cancel",this.handleDialogClose),e.addEventListener("click",this.handleNativeBackdropClick),this.updateModalState())}unbindDialog(){const e=this.dialogElement;e&&(e.open&&"function"==typeof e.close&&e.close(),e.removeEventListener("cancel",this.handleDialogClose),e.removeEventListener("click",this.handleNativeBackdropClick))}clearCloseTimer(){void 0!==this.closeTimerId&&(clearTimeout(this.closeTimerId),this.closeTimerId=void 0)}openDialog(){this.dialogElement&&!this.dialogElement.open&&this.dialogElement.showModal?.()}scheduleClose(){this.dialogElement&&"function"==typeof this.dialogElement.close&&(this.closeTimerId=setTimeout((()=>{this.closeTimerId=void 0,this.dialogElement?.close()}),250))}render(){return a(s,{key:"03f5eb41f33dd1ef6520c5e606f86af3676b1e72",class:"xpl-modal"},this.isOpen&&a("xpl-backdrop",{key:"50419511db07db7e51664f2c64167e8fa1130478"}),a("dialog",{key:"debe223a70a3e14a5a3937cdba9b18d8e1529497",class:`xpl-modal__dialog xpl-modal-size--${this.size} xpl-modal--${this.isOpen?"is-open":"is-closed"}`,"aria-labelledby":this.titleId},a("div",{key:"7b4a1fda4219622c1e482bfeda808fb25a818df7",class:"xpl-modal__header"},a("div",{key:"4f2f095fd473c97954e7c3b06691133f796df77e",class:"xpl-modal__title"},a("xpl-button",{key:"9a017bf7cbc52bd6828fe647e06b03a4601f988e",type:"button",class:"xpl-modal__close-button","icon-only":!0,variant:"tertiary","aria-label":"Close modal",onClick:this.handleDialogClose},a("xpl-icon",{key:"070c9cb695ee0a85f7bd25e19ceb7cb85ba2d178",icon:"xmark"})),"warning"===this.variant&&a("xpl-icon",{key:"7478625b27763ff01034195312af4e59411174d6",size:20,icon:"triangle-warning",class:"xpl-modal__alert-icon"}),a("span",{key:"092491fb296dd9d4658e3bf4fd2425d0cad791ee",class:"xpl-modal__title-text",id:this.titleId},a("slot",{key:"d91c682a6f51a08e73281f27944bf83b73a026ee",name:"title"}))),a("div",{key:"9a0b0ff9427d66ac44fd65649460ce62cf7b1cc4",class:"xpl-modal__subtitle"},a("slot",{key:"41c6093d7cb31838e49b20d237a0c273df79dabf",name:"subtitle"}))),a("div",{key:"afab32dbee43906310935cb02437e00d2743f555",class:"xpl-modal__body"},a("slot",{key:"dbb0a6eb15e6c519f2eb40a0cfc8de2a68a37811",name:"body"})),a("div",{key:"2e3501f03e002a40737dd02a4a6cfd47c0f08205",class:"xpl-modal__footer"},a("slot",{key:"4b21250f2cc15be589c2622f8cdeda679f881733",name:"primary"}),a("slot",{key:"490d23bfd88b209545e326e1e236beea9f4289da",name:"secondary"}),a("slot",{key:"b8d1457361776e33ebcc3404db8ab6c901be1500",name:"tertiary"}))))}get element(){return i(this)}static get watchers(){return{isOpen:[{updateModalState:0}]}}};export{d as xpl_modal}
1
+ import{r as e,c as t,h as a,H as s,g as i}from"./p-CgJEmBQY.js";let l=0;const d=class{constructor(a){e(this,a),this.modalClosed=t(this,"modalClosed",7),this.dialogElement=null,this.titleId=`xpl-modal-title-${l+=1}`,this.isOpen=!1,this.size="medium",this.variant="default",this.handleDialogClose=()=>{this.isOpen=!1,this.modalClosed.emit()},this.handleNativeBackdropClick=e=>{const{dialogElement:t}=this;if(!t||e.target!==t)return;const a=t.getBoundingClientRect();(e.clientX<a.left||e.clientX>a.right||e.clientY<a.top||e.clientY>a.bottom)&&this.handleDialogClose()}}connectedCallback(){this.bindDialog()}disconnectedCallback(){this.clearCloseTimer(),this.unbindDialog()}componentDidLoad(){this.bindDialog()}updateModalState(){this.clearCloseTimer(),this.isOpen?this.openDialog():this.scheduleClose()}bindDialog(){const e=this.element.querySelector("dialog");e&&(this.dialogElement=e,e.removeEventListener("cancel",this.handleDialogClose),e.removeEventListener("click",this.handleNativeBackdropClick),e.addEventListener("cancel",this.handleDialogClose),e.addEventListener("click",this.handleNativeBackdropClick),this.updateModalState())}unbindDialog(){const e=this.dialogElement;e&&(e.open&&"function"==typeof e.close&&e.close(),e.removeEventListener("cancel",this.handleDialogClose),e.removeEventListener("click",this.handleNativeBackdropClick))}clearCloseTimer(){void 0!==this.closeTimerId&&(clearTimeout(this.closeTimerId),this.closeTimerId=void 0)}openDialog(){this.dialogElement&&!this.dialogElement.open&&this.dialogElement.showModal?.()}scheduleClose(){this.dialogElement&&"function"==typeof this.dialogElement.close&&(this.closeTimerId=setTimeout((()=>{this.closeTimerId=void 0,this.dialogElement?.close()}),250))}render(){return a(s,{key:"03f5eb41f33dd1ef6520c5e606f86af3676b1e72",class:"xpl-modal"},this.isOpen&&a("xpl-backdrop",{key:"50419511db07db7e51664f2c64167e8fa1130478"}),a("dialog",{key:"debe223a70a3e14a5a3937cdba9b18d8e1529497",class:`xpl-modal__dialog xpl-modal-size--${this.size} xpl-modal--${this.isOpen?"is-open":"is-closed"}`,"aria-labelledby":this.titleId},a("div",{key:"7b4a1fda4219622c1e482bfeda808fb25a818df7",class:"xpl-modal__header"},a("div",{key:"4f2f095fd473c97954e7c3b06691133f796df77e",class:"xpl-modal__title"},a("xpl-button",{key:"9a017bf7cbc52bd6828fe647e06b03a4601f988e",type:"button",class:"xpl-modal__close-button","icon-only":!0,variant:"tertiary","aria-label":"Close modal",onClick:this.handleDialogClose},a("xpl-icon",{key:"070c9cb695ee0a85f7bd25e19ceb7cb85ba2d178",icon:"xmark"})),"warning"===this.variant&&a("xpl-icon",{key:"7478625b27763ff01034195312af4e59411174d6",size:20,icon:"triangle-warning",class:"xpl-modal__alert-icon"}),a("span",{key:"092491fb296dd9d4658e3bf4fd2425d0cad791ee",class:"xpl-modal__title-text",id:this.titleId},a("slot",{key:"d91c682a6f51a08e73281f27944bf83b73a026ee",name:"title"}))),a("div",{key:"9a0b0ff9427d66ac44fd65649460ce62cf7b1cc4",class:"xpl-modal__subtitle"},a("slot",{key:"41c6093d7cb31838e49b20d237a0c273df79dabf",name:"subtitle"}))),a("div",{key:"afab32dbee43906310935cb02437e00d2743f555",class:"xpl-modal__body"},a("slot",{key:"dbb0a6eb15e6c519f2eb40a0cfc8de2a68a37811",name:"body"})),a("div",{key:"2e3501f03e002a40737dd02a4a6cfd47c0f08205",class:"xpl-modal__footer"},a("slot",{key:"4b21250f2cc15be589c2622f8cdeda679f881733",name:"primary"}),a("slot",{key:"490d23bfd88b209545e326e1e236beea9f4289da",name:"secondary"}),a("slot",{key:"b8d1457361776e33ebcc3404db8ab6c901be1500",name:"tertiary"}))))}get element(){return i(this)}static get watchers(){return{isOpen:[{updateModalState:0}]}}};export{d as xpl_modal}
@@ -1 +1 @@
1
- import{r as e,c as s,h as a,H as c}from"./p-CJABLO_1.js";const t=class{constructor(a){e(this,a),this.navOpen=s(this,"navOpen",7),this.navControl=!1}onNavToggle(){window.innerWidth<=640&&this.navOpen.emit(!1)}render(){return a(c,{key:"eaae0b2a505bfab9d5d78b22b42b1dc24cb16b38",class:"xpl-nav-item",role:"listitem",onClick:()=>{this.navControl&&this.onNavToggle()}},a("slot",{key:"f69e8bdc7809836f4765c62f82c404fb55e97fb7",name:"link"},a("slot",{key:"044c518562eb68a068ef0a0a2117c69f5486fde5",name:"icon"}),a("slot",{key:"67edf532a3057af42d6b3ec51ccde9cc83d43d0b"})))}};export{t as xpl_nav_item}
1
+ import{r as e,c as s,h as a,H as c}from"./p-CgJEmBQY.js";const t=class{constructor(a){e(this,a),this.navOpen=s(this,"navOpen",7),this.navControl=!1}onNavToggle(){window.innerWidth<=640&&this.navOpen.emit(!1)}render(){return a(c,{key:"eaae0b2a505bfab9d5d78b22b42b1dc24cb16b38",class:"xpl-nav-item",role:"listitem",onClick:()=>{this.navControl&&this.onNavToggle()}},a("slot",{key:"f69e8bdc7809836f4765c62f82c404fb55e97fb7",name:"link"},a("slot",{key:"044c518562eb68a068ef0a0a2117c69f5486fde5",name:"icon"}),a("slot",{key:"67edf532a3057af42d6b3ec51ccde9cc83d43d0b"})))}};export{t as xpl_nav_item}
@@ -1 +1 @@
1
- import{r as e,c as a,h as d,H as c,g as t}from"./p-CJABLO_1.js";const s=class{constructor(d){e(this,d),this.isOpenChange=a(this,"isOpenChange",7),this.isOpen=!1,this.backdrop=!1,this.variant="default",this.showFooter=!0,this.handleClose=()=>{this.isOpen=!1}}watchPropHandler(e){this.isOpen=e,this.isOpenChange.emit(e)}handleScroll(){const e=this.el.querySelector(".content");e&&(e.scrollHeight>e.clientHeight?e.classList.add("has-shadow"):e.classList.remove("has-shadow"))}componentDidLoad(){this.handleScroll()}render(){return d(c,{key:"057b30a3213ae419e0a9bc94cae621cdf303d293",class:"xpl-slideout"},this.backdrop&&this.isOpen&&d("xpl-backdrop",{key:"940911dc6c07731fe40c0a4399cd81a3af7933ee",onClick:this.handleClose}),d("aside",{key:"b3432b92753b96999c528783cebfabd1488141be",class:`slideout slideout--${!this.isOpen&&"closed"}`},d("header",{key:"d87ec6cd3b3085131dd4bb6f2524e0ae39d36201",class:"header"},d("div",{key:"e2e3387ad686479d91810c022d657f44f97b1aeb",class:"title"},d("slot",{key:"c3accb74528dbd73140aa2b9b7c2e4e7f8013a6a",name:"title"}),d("xpl-button",{key:"ee486da9662bddb85e336edc01d878c2b4ade2cc",class:"close-button","icon-only":!0,variant:"tertiary",onClick:this.handleClose},d("xpl-icon",{key:"5e8b248e39e238e6ba2138641029bdde3160512e",icon:"xmark"}))),d("div",{key:"0bd2f149ba999ac0c8501d538298c2f5d4bfa687",class:"subtitle"},d("slot",{key:"0523c0ea9575ff905e78893723e7d6329befc9d9",name:"subtitle"})),d("div",{key:"d2de0a7b462fadfc9d80479db1153300abe0180f",class:"search"},d("slot",{key:"d0463af8f532856bdc273e306f06f7d837f41ffd",name:"search"}))),d("xpl-divider",{key:"9e3de6ccca99ab37bfeda29adbe343663f38ebef",tier:0,class:"divider top"}),d("article",{key:"0cf827d89aca95c2a0b0e5f037d12a00de651866",class:"content",tabIndex:0},d("slot",{key:"6738c288b5ccaa437efed62b8fd786cd58073b27",name:"content"})),this.showFooter&&d("footer",{key:"cf02d04cd0b1ce89e4783c5b4741e8b5fad739e8"},d("xpl-divider",{key:"9d79e51a52e5daed07bcb2ed7229f41926958594",tier:0,class:"divider bottom"}),d("div",{key:"fdbd1f126350e6b5b9bbad8a15bcc70cb9e562a3",class:"footer"},d("slot",{key:"994b27f63fab2d9ad45c50862c07239492a8404c",name:"tertiary"}),d("slot",{key:"ccd6bfc3f66e98dbb07a54a5e523b4365e8c1633",name:"secondary"}),d("slot",{key:"40dfa4f9fffecfd8a3c01be593de504b0d7e7f7e",name:"primary"})))))}get el(){return t(this)}static get watchers(){return{isOpen:[{watchPropHandler:0}]}}};export{s as xpl_slideout}
1
+ import{r as e,c as a,h as d,H as c,g as t}from"./p-CgJEmBQY.js";const s=class{constructor(d){e(this,d),this.isOpenChange=a(this,"isOpenChange",7),this.isOpen=!1,this.backdrop=!1,this.variant="default",this.showFooter=!0,this.handleClose=()=>{this.isOpen=!1}}watchPropHandler(e){this.isOpen=e,this.isOpenChange.emit(e)}handleScroll(){const e=this.el.querySelector(".content");e&&(e.scrollHeight>e.clientHeight?e.classList.add("has-shadow"):e.classList.remove("has-shadow"))}componentDidLoad(){this.handleScroll()}render(){return d(c,{key:"057b30a3213ae419e0a9bc94cae621cdf303d293",class:"xpl-slideout"},this.backdrop&&this.isOpen&&d("xpl-backdrop",{key:"940911dc6c07731fe40c0a4399cd81a3af7933ee",onClick:this.handleClose}),d("aside",{key:"b3432b92753b96999c528783cebfabd1488141be",class:`slideout slideout--${!this.isOpen&&"closed"}`},d("header",{key:"d87ec6cd3b3085131dd4bb6f2524e0ae39d36201",class:"header"},d("div",{key:"e2e3387ad686479d91810c022d657f44f97b1aeb",class:"title"},d("slot",{key:"c3accb74528dbd73140aa2b9b7c2e4e7f8013a6a",name:"title"}),d("xpl-button",{key:"ee486da9662bddb85e336edc01d878c2b4ade2cc",class:"close-button","icon-only":!0,variant:"tertiary",onClick:this.handleClose},d("xpl-icon",{key:"5e8b248e39e238e6ba2138641029bdde3160512e",icon:"xmark"}))),d("div",{key:"0bd2f149ba999ac0c8501d538298c2f5d4bfa687",class:"subtitle"},d("slot",{key:"0523c0ea9575ff905e78893723e7d6329befc9d9",name:"subtitle"})),d("div",{key:"d2de0a7b462fadfc9d80479db1153300abe0180f",class:"search"},d("slot",{key:"d0463af8f532856bdc273e306f06f7d837f41ffd",name:"search"}))),d("xpl-divider",{key:"9e3de6ccca99ab37bfeda29adbe343663f38ebef",tier:0,class:"divider top"}),d("article",{key:"0cf827d89aca95c2a0b0e5f037d12a00de651866",class:"content",tabIndex:0},d("slot",{key:"6738c288b5ccaa437efed62b8fd786cd58073b27",name:"content"})),this.showFooter&&d("footer",{key:"cf02d04cd0b1ce89e4783c5b4741e8b5fad739e8"},d("xpl-divider",{key:"9d79e51a52e5daed07bcb2ed7229f41926958594",tier:0,class:"divider bottom"}),d("div",{key:"fdbd1f126350e6b5b9bbad8a15bcc70cb9e562a3",class:"footer"},d("slot",{key:"994b27f63fab2d9ad45c50862c07239492a8404c",name:"tertiary"}),d("slot",{key:"ccd6bfc3f66e98dbb07a54a5e523b4365e8c1633",name:"secondary"}),d("slot",{key:"40dfa4f9fffecfd8a3c01be593de504b0d7e7f7e",name:"primary"})))))}get el(){return t(this)}static get watchers(){return{isOpen:[{watchPropHandler:0}]}}};export{s as xpl_slideout}
@@ -1 +1 @@
1
- import{r as t,c as i,h as s,H as e,g as h}from"./p-CJABLO_1.js";import{v as a}from"./p-CK3_k8jD.js";import{f as r}from"./p-CH4yJ6Qx.js";import{i as n}from"./p-Dqb1pIRo.js";const l=class{constructor(s){t(this,s),this.blurEvent=i(this,"blurEvent",7),this.focusEvent=i(this,"focusEvent",7),this.inputEvent=i(this,"inputEvent",7),this.search=i(this,"search",7),this.valueChange=i(this,"valueChange",7),this.multiline=!1,this.dateFormat="Y-m-d",this.timeFormat="24h",this.allowCustomOption=!1,this.mode="single",this.accept="",this.multiple=!1,this.hideTriggerOnSelect=!1,this.hideFileNames=!1,this.hideAcceptText=!1,this.defaultCountry="US",this.isInternational=!0,this.ariaLabel="",this.type="text",this.handleChildValueChange=t=>{t.stopPropagation(),this.valueChange.emit(t.detail)},this.valueChanged=t=>{this.valueChange.emit(t.target.value)},this.characterCount=0,this.passwordVisible=!1,this.hasPreSlotContent=!1,this.handleBlur=t=>{this.blurEvent.emit(t)},this.handleFocus=t=>{this.focusEvent.emit(t)},this.handleInput=t=>{this.multiline&&this.updateCharacterCount();const{value:i}=t.target;this.inputEvent.emit(i)},this.handleSearchBlurForward=t=>{const{detail:i}=t;i&&(t.stopPropagation(),this.blurEvent.emit(i))},this.handleSearchCommit=t=>{t.stopPropagation(),this.search.emit(t.detail)},this.handleSearchFocusForward=t=>{const{detail:i}=t;i&&(t.stopPropagation(),this.focusEvent.emit(i))}}connectedCallback(){this.syncPreSlotContent(),this.connectPreSlotObserver()}disconnectedCallback(){void 0!==this.preSlotSyncTimeoutId&&(clearTimeout(this.preSlotSyncTimeoutId),this.preSlotSyncTimeoutId=void 0),this.disconnectPreSlotObserver()}componentWillLoad(){null!=this._id&&""!==this._id||(this._id=a()),this.multiline&&void 0!==this.maxCharacterCount&&(this.characterCount=void 0!==this.value?this.value.length:0),this.syncPreSlotContent()}componentWillRender(){this.disconnectPreSlotObserver()}componentDidRender(){this.schedulePreSlotSync()}async setFocus(){"search"!==this.type?this.input?.focus():await(this.searchInputRef?.setFocus())}connectPreSlotObserver(){this.disconnectPreSlotObserver(),this.multiline||"search"===this.type||"undefined"==typeof MutationObserver||(this.preSlotObserver=new MutationObserver((()=>{this.schedulePreSlotSync()})),this.preSlotObserver.observe(this.el,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["slot"]}))}disconnectPreSlotObserver(){this.preSlotObserver?.disconnect(),this.preSlotObserver=void 0}schedulePreSlotSync(){void 0!==this.preSlotSyncTimeoutId&&clearTimeout(this.preSlotSyncTimeoutId),this.preSlotSyncTimeoutId=setTimeout((()=>{this.preSlotSyncTimeoutId=void 0,this.el.isConnected&&(this.syncPreSlotContent(),this.connectPreSlotObserver())}),0)}syncPreSlotContent(){if(this.multiline||"search"===this.type)return;const t=Array.from(this.el.querySelectorAll('[slot="pre"]')).some((t=>t.closest("xpl-input")===this.el));t!==this.hasPreSlotContent&&(this.hasPreSlotContent=t)}updateCharacterCount(){this.characterCount=this.input?.value.length??0}renderInput(){switch(this.type){case"file":return s("xpl-input-file",{accept:this.accept,disabled:this.disabled,hideAcceptText:this.hideAcceptText,hideFileNames:this.hideFileNames,hideTriggerOnSelect:this.hideTriggerOnSelect,multiple:this.multiple,name:this.name,onInputChange:this.handleChildValueChange,_id:this._id},s("slot",{name:"trigger"}));case"color":return s("xpl-input-color",{disabled:this.disabled,value:this.value,placeholder:this.placeholder,required:this.required,hideEyeDropper:this.hideEyeDropper,onInputChange:this.handleChildValueChange});case"date":return s("xpl-input-date",{inputId:this._id,disabled:this.disabled,name:this.name,required:this.required,readonly:this.readonly,value:this.value,placeholder:this.placeholder,post:this.post,pre:this.pre,max:this.max,min:this.min,dateFormat:this.dateFormat,mode:this.mode,onValueChange:this.handleChildValueChange});case"time":return s("xpl-input-time",{inputId:this._id,disabled:this.disabled,name:this.name,required:this.required,readonly:this.readonly,value:this.value,placeholder:this.placeholder,max:this.max,min:this.min,step:this.step,mode:this.mode,timeFormat:this.timeFormat,allowCustomOption:this.allowCustomOption,onValueChange:this.handleChildValueChange});case"phone":return s("xpl-input-phone",{inputId:this._id,disabled:this.disabled,error:void 0!==this.error,name:this.name,required:this.required,readonly:this.readonly,value:this.value,placeholder:this.placeholder,defaultCountry:this.defaultCountry,preferredCountries:this.preferredCountries,isInternational:this.isInternational,onValueChange:this.handleChildValueChange});case"search":{const t=Boolean((this.label??"").trim()),i=void 0!==this.error,e=i&&(this.error?.length??0)>0;return s("xpl-input-search",{ariaLabel:(this.ariaLabel??"").trim()||"Search",autocomplete:this.autocomplete??"off",disabled:this.disabled,errorMessageId:e?`${this._id}-error`:void 0,hasError:i,hasVisibleLabel:t,inputId:this._id??"",name:this.name,onBlurEvent:this.handleSearchBlurForward,onFocusEvent:this.handleSearchFocusForward,onSearch:this.handleSearchCommit,onValueChange:this.handleChildValueChange,placeholder:this.placeholder??"Search",readonly:this.readonly,ref:t=>{this.searchInputRef=t??void 0},required:this.required,shape:this.shape??"rounded",value:this.value??""})}default:return s("div",{class:"xpl-input-wrapper"},!this.multiline&&s("label",{class:{"xpl-input-pre":!0,"xpl-input-pre--hidden":!this.pre&&!this.hasPreSlotContent},htmlFor:this._id},s("slot",{name:"pre"},this.pre)),this.multiline?s("textarea",{disabled:this.disabled,id:this._id,name:this.name,placeholder:this.placeholder,readonly:this.readonly,ref:t=>{this.input=t??void 0},required:this.required,onChange:this.valueChanged,onFocus:this.handleFocus,onBlur:this.handleBlur,onInput:this.handleInput},this.value):s("input",{autocomplete:this.autocomplete,disabled:this.disabled,id:this._id,max:this.max,min:this.min,name:this.name,placeholder:this.placeholder,readonly:this.readonly,ref:t=>{this.input=t??void 0},required:this.required,step:this.step,type:this.type,value:this.value,onChange:this.valueChanged,onFocus:this.handleFocus,onBlur:this.handleBlur,onInput:this.handleInput}),"password"===this.type&&s("button",{"aria-label":"Toggle password visibility",class:"xpl-input-password",onClick:()=>{this.passwordVisible=!this.passwordVisible},role:"presentation"},s("xpl-icon",{icon:this.passwordVisible?"eye-closed":"eye",size:24})),this.post&&!this.multiline&&s("label",{class:"xpl-input-post",htmlFor:this._id},this.post),this.multiline&&void 0!==this.maxCharacterCount&&s("span",{class:"xpl-input-characters"},this.characterCount,"/",this.maxCharacterCount))}}render(){let t=!1;return(void 0!==this.error||this.multiline&&void 0!==this.maxCharacterCount&&this.characterCount>this.maxCharacterCount)&&(t=!0),s(e,{key:"d57ab7978ef701d4783f6780bbd807e8ee07ac7d",class:{"xpl-input":!0,"xpl-input--disabled":!!this.disabled,"xpl-input--error":t,"xpl-input--readonly":!!this.readonly,[`xpl-input--${this.type}`]:!0}},this.label&&s("label",{key:"cdc55154c334fcc2ed8049113d012e046e77fde7",class:"xpl-input-label",htmlFor:this._id},this.label,this.description&&s("small",{key:"37a1685a6e0b9b7da8abc6209df998154affbb79"},this.description)),this.renderInput(),(this.error?.length??0)>0&&s("label",{key:"c7a636a36d902543c9228a72c81db408912b3d58",class:"xpl-input-error",htmlFor:this._id,id:`${this._id}-error`},s("xpl-icon",{key:"e73b36e29ebe7812564e5d27710ebda1b9bf2185",icon:"circle-warning",size:16}),s("span",{key:"10149a258c81cbc439778e84f49bc6dfdc97d26d"},this.error)))}get el(){return h(this)}};function o(t){if(!n())return;let i=t.parentElement;for(;i&&i!==document.body&&i!==document.documentElement;){const t=getComputedStyle(i);if(/auto|scroll/.test(t.overflow+t.overflowX+t.overflowY))return i;i=i.parentElement}}const c=(t=!1)=>`<svg width="8" height="12" viewBox="0 0 8 12" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="${t?"M0.557948 5.6813L6.06209 0.132167C6.23831 -0.0440556 6.52327 -0.0440556 6.69949 0.132167L7.44187 0.874551C7.61809 1.05077 7.61809 1.33573 7.44187 1.51195L2.99882 6L7.44187 10.488C7.61809 10.6643 7.61809 10.9492 7.44187 11.1254L6.69949 11.8678C6.52327 12.0441 6.23831 12.0441 6.06209 11.8678L0.557948 6.3187C0.381726 6.14248 0.381726 5.85752 0.557948 5.6813Z":"M7.44187 6.3187L1.93773 11.8678C1.76151 12.0441 1.47655 12.0441 1.30033 11.8678L0.557948 11.1254C0.381726 10.9492 0.381726 10.6643 0.557948 10.488L5.001 6L0.557948 1.51195C0.381726 1.33573 0.381726 1.05077 0.557948 0.874551L1.30033 0.132167C1.47655 -0.0440556 1.76151 -0.0440556 1.93773 0.132167L7.44187 5.6813C7.6181 5.85752 7.6181 6.14248 7.44187 6.3187Z"}" /></svg>`,d=class{constructor(s){t(this,s),this.valueChange=i(this,"valueChange",7),this.hasErrorStateChanged=i(this,"hasErrorStateChanged",7),this.rangeSelected=i(this,"rangeSelected",7),this.dateFormat="Y-m-d",this.mode="single",this.flatpickrStaticLayout=!1,this.valueChanged=t=>{this.valueChange.emit(t.target.value)}}onHasErrorStateChanged(t){this.hasErrorStateChanged.emit(t)}onValueChanged(t){this.flatpickrInstance?.setDate(t)}connectedCallback(){queueMicrotask((()=>this.ensureFlatpickr()))}disconnectedCallback(){this.flatpickrInstance?.destroy(),this.flatpickrInstance=void 0,this.flatpickrStaticLayout=!1,this.unwrapStaleFlatpickrWrapper()}componentDidRender(){this.ensureFlatpickr()}ensureFlatpickr(){n()&&!this.flatpickrInstance&&this.input&&this.el.isConnected&&(this.unwrapStaleFlatpickrWrapper(),this.initFlatpickr())}initFlatpickr(){const{input:t}=this;if(!t)return;const i=function(t){if(!n())return!1;let i=t.parentElement;for(;i&&i!==document.body&&i!==document.documentElement;){if("fixed"===getComputedStyle(i).position)return!0;i=i.parentElement}return!1}(this.el);this.flatpickrInstance=r(t,{allowInput:!0,...i?{static:!0}:{appendTo:o(this.el)},dateFormat:this.dateFormat,defaultDate:this.value,maxDate:this.max,minDate:this.min,mode:this.mode,nextArrow:c(),prevArrow:c(!0),onClose:t=>{if(this.hasErrorState=t.length<(this.required?"single"===this.mode?1:2:0)?"required":null,2===t.length){const[i,s]=t;this.rangeSelected.emit({start:i,end:s})}}}),queueMicrotask((()=>{this.flatpickrStaticLayout!==i&&(this.flatpickrStaticLayout=i)}))}unwrapStaleFlatpickrWrapper(){const{input:t}=this,i=t?.parentElement;if(!i?.classList.contains("flatpickr-wrapper"))return;const s=i.parentElement;if(s){for(;i.firstChild;)s.insertBefore(i.firstChild,i);s.removeChild(i)}}render(){return s(e,{key:"f1b3189eb8ba737e5e96826042d8c3aadce9b0d1",class:{"xpl-input-date":!0,[`xpl-input-date--mode-${this.mode}`]:!0,"xpl-input-date--error":!!this.hasErrorState,"xpl-input-date--flatpickr-static":this.flatpickrStaticLayout}},s("div",{key:"1c292279aad8ae7f48358d5e42189d60ecd1d97d",class:"xpl-input-wrapper"},this.pre&&s("label",{key:"f8ed452f69f664fd4e3b83e428070f3f4b14d5c6",class:"xpl-input-pre",htmlFor:this.inputId},this.pre),s("input",{key:"e1659c6ad3cb2cb0a5d88a7635672917d2f58ebb",type:"date",id:this.inputId,disabled:this.disabled,name:this.name,required:this.required,readonly:this.readonly,placeholder:this.placeholder,max:this.max,min:this.min,ref:t=>{this.input=t??void 0},onChange:t=>{this.valueChanged(t)}}),s("xpl-icon",{key:"577c881edf4ef8dfd3c910c8bbdd268af7448e6c",class:"xpl-input-calendar",icon:"calendar",size:24}),this.post&&s("label",{key:"5acfeb3ea72d9c5a193116e305fd54d323276910",class:"xpl-input-post",htmlFor:this.inputId},this.post)))}get el(){return h(this)}static get watchers(){return{hasErrorState:[{onHasErrorStateChanged:0}],value:[{onValueChanged:0}]}}},p=class{constructor(s){t(this,s),this.inputChange=i(this,"inputChange",7),this.accept="",this.multiple=!1,this.hideTriggerOnSelect=!1,this.hideFileNames=!1,this.hideAcceptText=!1,this.files=null,this.openFileDialog=()=>{this.disabled||this.fileInput?.click()},this.handleFileChange=t=>{const i=t.target;this.files=i.files?Array.from(i.files):null},this.onRemoveFileByIndex=t=>{this.files=(this.files??[]).filter(((i,s)=>s!==t))}}onFilesChange(t){this.inputChange.emit({type:"file",value:t})}async removeFileByIndex(t){this.onRemoveFileByIndex(t)}render(){return s(e,{key:"87eead553435ce984945ccb72ca262bfd6123562",class:{"xpl-input-file":!0,"xpl-input-file--hide-trigger-on-select":!!this.hideTriggerOnSelect,"xpl-input-file--disabled":!!this.disabled}},s("span",{key:"f345204405d1bb784fc662fa3c29e9edaeca9c67",class:{"xpl-input-file__trigger-wrapper":!0,"xpl-input-file__trigger-wrapper--hidden":!!this.hideTriggerOnSelect&&(this.files?.length??0)>0},role:"button",tabIndex:0,onClick:this.openFileDialog},s("slot",{key:"46c4e817cb8f8b050b4de5c571757c7ed84698a7",name:"trigger"})),(this.files?.length??0)>0&&!this.hideFileNames&&s("ul",{key:"455af4a3cad84232464927efb880ce0a26cebf71",class:"xpl-input-file__file-list"},(this.files??[]).map(((t,i)=>s("li",{class:"xpl-input-file__file-item"},s("span",{class:"xpl-input-file__file-name"},t.name),s("xpl-icon",{icon:"x-circle",size:24,onClick:t=>{t.preventDefault(),t.stopPropagation(),this.onRemoveFileByIndex(i)},class:"xpl-input-file__remove-icon"}))))),this.accept&&!this.hideAcceptText&&s("span",{key:"77abc822d8d44b33f251d4ba9ef21cfc7dd6c287",class:"xpl-input-file__accept"},"Accepted file types: ",this.accept),s("input",{key:"d75ec23921943259d789b0f32828dca57864520e",onChange:this.handleFileChange,type:"file",ref:t=>{this.fileInput=t??void 0},hidden:!0,accept:this.accept,multiple:this.multiple,name:this.name}))}get el(){return h(this)}static get watchers(){return{files:[{onFilesChange:0}]}}},u=class{constructor(s){t(this,s),this.blurEvent=i(this,"blurEvent",7),this.focusEvent=i(this,"focusEvent",7),this.inputEvent=i(this,"inputEvent",7),this.search=i(this,"search",7),this.valueChange=i(this,"valueChange",7),this.hasAncestorForm=!1,this.ariaLabel="Search",this.autocomplete="off",this.disabled=!1,this.hasError=!1,this.hasVisibleLabel=!1,this.placeholder="Search",this.readonly=!1,this.required=!1,this.shape="rounded",this.value="",this.handleInnerFormSubmit=t=>{t.preventDefault(),this.disabled||this.readonly||this.emitSearchCommit(this.value.trim())},this.handleClear=t=>{t.preventDefault(),this.disabled||this.readonly||(this.value="",this.valueChange.emit(""),this.inputEvent.emit(""),this.inputEl?.focus())},this.handleInput=t=>{const i=t.target;this.value=i.value,this.valueChange.emit(i.value),this.inputEvent.emit(i.value)},this.handleKeyDown=t=>{"Enter"===t.key&&(this.disabled||this.readonly||t.target.form||(t.preventDefault(),this.emitSearchCommit(this.value.trim())))},this.handleFocus=t=>{this.focusEvent.emit(t)},this.handleBlur=t=>{this.blurEvent.emit(t)}}connectedCallback(){this.syncAncestorFormFlag()}async setFocus(){this.inputEl?.focus()}syncAncestorFormFlag(){const t=this.el,i=Boolean(t&&"function"==typeof t.closest&&t.closest("form"));this.hasAncestorForm!==i&&(this.hasAncestorForm=i)}get hasValue(){return void 0!==this.value&&this.value.length>0}get resolvedInputAriaLabel(){if(!this.hasVisibleLabel)return(this.ariaLabel??"").trim()||"Search"}get rendersInnerSearchForm(){return!this.hasAncestorForm}emitSearchCommit(t){this.search.emit(t)}renderShell(){const t=s("div",{class:"xpl-input-search__shell"},s("span",{class:"xpl-input-search__icon","aria-hidden":"true"},s("xpl-icon",{icon:"magnifier",size:20})),s("input",{"aria-describedby":this.hasError?this.errorMessageId:void 0,"aria-invalid":this.hasError?"true":void 0,"aria-label":this.resolvedInputAriaLabel,autocomplete:this.autocomplete,class:"xpl-input-search__input",disabled:this.disabled,id:this.inputId,name:this.name,onBlur:this.handleBlur,onFocus:this.handleFocus,onInput:this.handleInput,onKeyDown:this.handleKeyDown,placeholder:this.placeholder,readonly:this.readonly,ref:t=>{this.inputEl=t??void 0},required:this.required,role:"searchbox",type:"text",value:this.value}),s("button",{"aria-hidden":this.hasValue?void 0:"true","aria-label":"Clear search",class:"xpl-input-search__clear",disabled:this.disabled||this.readonly,onClick:this.handleClear,type:"button"},s("xpl-icon",{icon:"circle-xmark",size:16})));return this.rendersInnerSearchForm?s("form",{class:"xpl-input-search__form",onSubmit:this.handleInnerFormSubmit},t):t}render(){return s(e,{key:"90b29d51b36655d1dc5f7fa9b67edf6382cb90af",class:{"xpl-input-search":!0,"xpl-input-search--disabled":this.disabled,"xpl-input-search--error":this.hasError,"xpl-input-search--has-value":this.hasValue,"xpl-input-search--readonly":this.readonly,"xpl-input-search--shape-box":"box"===this.shape}},this.renderShell())}get el(){return h(this)}};export{l as xpl_input,d as xpl_input_date,p as xpl_input_file,u as xpl_input_search}
1
+ import{r as t,c as i,h as s,H as e,g as h}from"./p-CgJEmBQY.js";import{v as a}from"./p-CK3_k8jD.js";import{f as r}from"./p-CH4yJ6Qx.js";import{i as n}from"./p-Dqb1pIRo.js";const l=class{constructor(s){t(this,s),this.blurEvent=i(this,"blurEvent",7),this.focusEvent=i(this,"focusEvent",7),this.inputEvent=i(this,"inputEvent",7),this.search=i(this,"search",7),this.valueChange=i(this,"valueChange",7),this.multiline=!1,this.dateFormat="Y-m-d",this.timeFormat="24h",this.allowCustomOption=!1,this.mode="single",this.accept="",this.multiple=!1,this.hideTriggerOnSelect=!1,this.hideFileNames=!1,this.hideAcceptText=!1,this.defaultCountry="US",this.isInternational=!0,this.ariaLabel="",this.type="text",this.handleChildValueChange=t=>{t.stopPropagation(),this.valueChange.emit(t.detail)},this.valueChanged=t=>{this.valueChange.emit(t.target.value)},this.characterCount=0,this.passwordVisible=!1,this.hasPreSlotContent=!1,this.handleBlur=t=>{this.blurEvent.emit(t)},this.handleFocus=t=>{this.focusEvent.emit(t)},this.handleInput=t=>{this.multiline&&this.updateCharacterCount();const{value:i}=t.target;this.inputEvent.emit(i)},this.handleSearchBlurForward=t=>{const{detail:i}=t;i&&(t.stopPropagation(),this.blurEvent.emit(i))},this.handleSearchCommit=t=>{t.stopPropagation(),this.search.emit(t.detail)},this.handleSearchFocusForward=t=>{const{detail:i}=t;i&&(t.stopPropagation(),this.focusEvent.emit(i))}}connectedCallback(){this.syncPreSlotContent(),this.connectPreSlotObserver()}disconnectedCallback(){void 0!==this.preSlotSyncTimeoutId&&(clearTimeout(this.preSlotSyncTimeoutId),this.preSlotSyncTimeoutId=void 0),this.disconnectPreSlotObserver()}componentWillLoad(){null!=this._id&&""!==this._id||(this._id=a()),this.multiline&&void 0!==this.maxCharacterCount&&(this.characterCount=void 0!==this.value?this.value.length:0),this.syncPreSlotContent()}componentWillRender(){this.disconnectPreSlotObserver()}componentDidRender(){this.schedulePreSlotSync()}async setFocus(){"search"!==this.type?this.input?.focus():await(this.searchInputRef?.setFocus())}connectPreSlotObserver(){this.disconnectPreSlotObserver(),this.multiline||"search"===this.type||"undefined"==typeof MutationObserver||(this.preSlotObserver=new MutationObserver((()=>{this.schedulePreSlotSync()})),this.preSlotObserver.observe(this.el,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["slot"]}))}disconnectPreSlotObserver(){this.preSlotObserver?.disconnect(),this.preSlotObserver=void 0}schedulePreSlotSync(){void 0!==this.preSlotSyncTimeoutId&&clearTimeout(this.preSlotSyncTimeoutId),this.preSlotSyncTimeoutId=setTimeout((()=>{this.preSlotSyncTimeoutId=void 0,this.el.isConnected&&(this.syncPreSlotContent(),this.connectPreSlotObserver())}),0)}syncPreSlotContent(){if(this.multiline||"search"===this.type)return;const t=Array.from(this.el.querySelectorAll('[slot="pre"]')).some((t=>t.closest("xpl-input")===this.el));t!==this.hasPreSlotContent&&(this.hasPreSlotContent=t)}updateCharacterCount(){this.characterCount=this.input?.value.length??0}renderInput(){switch(this.type){case"file":return s("xpl-input-file",{accept:this.accept,disabled:this.disabled,hideAcceptText:this.hideAcceptText,hideFileNames:this.hideFileNames,hideTriggerOnSelect:this.hideTriggerOnSelect,multiple:this.multiple,name:this.name,onInputChange:this.handleChildValueChange,_id:this._id},s("slot",{name:"trigger"}));case"color":return s("xpl-input-color",{disabled:this.disabled,value:this.value,placeholder:this.placeholder,required:this.required,hideEyeDropper:this.hideEyeDropper,onInputChange:this.handleChildValueChange});case"date":return s("xpl-input-date",{inputId:this._id,disabled:this.disabled,name:this.name,required:this.required,readonly:this.readonly,value:this.value,placeholder:this.placeholder,post:this.post,pre:this.pre,max:this.max,min:this.min,dateFormat:this.dateFormat,mode:this.mode,onValueChange:this.handleChildValueChange});case"time":return s("xpl-input-time",{inputId:this._id,disabled:this.disabled,name:this.name,required:this.required,readonly:this.readonly,value:this.value,placeholder:this.placeholder,max:this.max,min:this.min,step:this.step,mode:this.mode,timeFormat:this.timeFormat,allowCustomOption:this.allowCustomOption,onValueChange:this.handleChildValueChange});case"phone":return s("xpl-input-phone",{inputId:this._id,disabled:this.disabled,error:void 0!==this.error,name:this.name,required:this.required,readonly:this.readonly,value:this.value,placeholder:this.placeholder,defaultCountry:this.defaultCountry,preferredCountries:this.preferredCountries,isInternational:this.isInternational,onValueChange:this.handleChildValueChange});case"search":{const t=Boolean((this.label??"").trim()),i=void 0!==this.error,e=i&&(this.error?.length??0)>0;return s("xpl-input-search",{ariaLabel:(this.ariaLabel??"").trim()||"Search",autocomplete:this.autocomplete??"off",disabled:this.disabled,errorMessageId:e?`${this._id}-error`:void 0,hasError:i,hasVisibleLabel:t,inputId:this._id??"",name:this.name,onBlurEvent:this.handleSearchBlurForward,onFocusEvent:this.handleSearchFocusForward,onSearch:this.handleSearchCommit,onValueChange:this.handleChildValueChange,placeholder:this.placeholder??"Search",readonly:this.readonly,ref:t=>{this.searchInputRef=t??void 0},required:this.required,shape:this.shape??"rounded",value:this.value??""})}default:return s("div",{class:"xpl-input-wrapper"},!this.multiline&&s("label",{class:{"xpl-input-pre":!0,"xpl-input-pre--hidden":!this.pre&&!this.hasPreSlotContent},htmlFor:this._id},s("slot",{name:"pre"},this.pre)),this.multiline?s("textarea",{disabled:this.disabled,id:this._id,name:this.name,placeholder:this.placeholder,readonly:this.readonly,ref:t=>{this.input=t??void 0},required:this.required,onChange:this.valueChanged,onFocus:this.handleFocus,onBlur:this.handleBlur,onInput:this.handleInput},this.value):s("input",{autocomplete:this.autocomplete,disabled:this.disabled,id:this._id,max:this.max,min:this.min,name:this.name,placeholder:this.placeholder,readonly:this.readonly,ref:t=>{this.input=t??void 0},required:this.required,step:this.step,type:this.type,value:this.value,onChange:this.valueChanged,onFocus:this.handleFocus,onBlur:this.handleBlur,onInput:this.handleInput}),"password"===this.type&&s("button",{"aria-label":"Toggle password visibility",class:"xpl-input-password",onClick:()=>{this.passwordVisible=!this.passwordVisible},role:"presentation"},s("xpl-icon",{icon:this.passwordVisible?"eye-closed":"eye",size:24})),this.post&&!this.multiline&&s("label",{class:"xpl-input-post",htmlFor:this._id},this.post),this.multiline&&void 0!==this.maxCharacterCount&&s("span",{class:"xpl-input-characters"},this.characterCount,"/",this.maxCharacterCount))}}render(){let t=!1;return(void 0!==this.error||this.multiline&&void 0!==this.maxCharacterCount&&this.characterCount>this.maxCharacterCount)&&(t=!0),s(e,{key:"d57ab7978ef701d4783f6780bbd807e8ee07ac7d",class:{"xpl-input":!0,"xpl-input--disabled":!!this.disabled,"xpl-input--error":t,"xpl-input--readonly":!!this.readonly,[`xpl-input--${this.type}`]:!0}},this.label&&s("label",{key:"cdc55154c334fcc2ed8049113d012e046e77fde7",class:"xpl-input-label",htmlFor:this._id},this.label,this.description&&s("small",{key:"37a1685a6e0b9b7da8abc6209df998154affbb79"},this.description)),this.renderInput(),(this.error?.length??0)>0&&s("label",{key:"c7a636a36d902543c9228a72c81db408912b3d58",class:"xpl-input-error",htmlFor:this._id,id:`${this._id}-error`},s("xpl-icon",{key:"e73b36e29ebe7812564e5d27710ebda1b9bf2185",icon:"circle-warning",size:16}),s("span",{key:"10149a258c81cbc439778e84f49bc6dfdc97d26d"},this.error)))}get el(){return h(this)}};function o(t){if(!n())return;let i=t.parentElement;for(;i&&i!==document.body&&i!==document.documentElement;){const t=getComputedStyle(i);if(/auto|scroll/.test(t.overflow+t.overflowX+t.overflowY))return i;i=i.parentElement}}const c=(t=!1)=>`<svg width="8" height="12" viewBox="0 0 8 12" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="${t?"M0.557948 5.6813L6.06209 0.132167C6.23831 -0.0440556 6.52327 -0.0440556 6.69949 0.132167L7.44187 0.874551C7.61809 1.05077 7.61809 1.33573 7.44187 1.51195L2.99882 6L7.44187 10.488C7.61809 10.6643 7.61809 10.9492 7.44187 11.1254L6.69949 11.8678C6.52327 12.0441 6.23831 12.0441 6.06209 11.8678L0.557948 6.3187C0.381726 6.14248 0.381726 5.85752 0.557948 5.6813Z":"M7.44187 6.3187L1.93773 11.8678C1.76151 12.0441 1.47655 12.0441 1.30033 11.8678L0.557948 11.1254C0.381726 10.9492 0.381726 10.6643 0.557948 10.488L5.001 6L0.557948 1.51195C0.381726 1.33573 0.381726 1.05077 0.557948 0.874551L1.30033 0.132167C1.47655 -0.0440556 1.76151 -0.0440556 1.93773 0.132167L7.44187 5.6813C7.6181 5.85752 7.6181 6.14248 7.44187 6.3187Z"}" /></svg>`,d=class{constructor(s){t(this,s),this.valueChange=i(this,"valueChange",7),this.hasErrorStateChanged=i(this,"hasErrorStateChanged",7),this.rangeSelected=i(this,"rangeSelected",7),this.dateFormat="Y-m-d",this.mode="single",this.flatpickrStaticLayout=!1,this.valueChanged=t=>{this.valueChange.emit(t.target.value)}}onHasErrorStateChanged(t){this.hasErrorStateChanged.emit(t)}onValueChanged(t){this.flatpickrInstance?.setDate(t)}connectedCallback(){queueMicrotask((()=>this.ensureFlatpickr()))}disconnectedCallback(){this.flatpickrInstance?.destroy(),this.flatpickrInstance=void 0,this.flatpickrStaticLayout=!1,this.unwrapStaleFlatpickrWrapper()}componentDidRender(){this.ensureFlatpickr()}ensureFlatpickr(){n()&&!this.flatpickrInstance&&this.input&&this.el.isConnected&&(this.unwrapStaleFlatpickrWrapper(),this.initFlatpickr())}initFlatpickr(){const{input:t}=this;if(!t)return;const i=function(t){if(!n())return!1;let i=t.parentElement;for(;i&&i!==document.body&&i!==document.documentElement;){if("fixed"===getComputedStyle(i).position)return!0;i=i.parentElement}return!1}(this.el);this.flatpickrInstance=r(t,{allowInput:!0,...i?{static:!0}:{appendTo:o(this.el)},dateFormat:this.dateFormat,defaultDate:this.value,maxDate:this.max,minDate:this.min,mode:this.mode,nextArrow:c(),prevArrow:c(!0),onClose:t=>{if(this.hasErrorState=t.length<(this.required?"single"===this.mode?1:2:0)?"required":null,2===t.length){const[i,s]=t;this.rangeSelected.emit({start:i,end:s})}}}),queueMicrotask((()=>{this.flatpickrStaticLayout!==i&&(this.flatpickrStaticLayout=i)}))}unwrapStaleFlatpickrWrapper(){const{input:t}=this,i=t?.parentElement;if(!i?.classList.contains("flatpickr-wrapper"))return;const s=i.parentElement;if(s){for(;i.firstChild;)s.insertBefore(i.firstChild,i);s.removeChild(i)}}render(){return s(e,{key:"db5a09f9a2ee0b813eddf841ea4ea3992e3e34c6",class:{"xpl-input-date":!0,[`xpl-input-date--mode-${this.mode}`]:!0,"xpl-input-date--error":!!this.hasErrorState,"xpl-input-date--flatpickr-static":this.flatpickrStaticLayout}},s("div",{key:"747c13852b950f0cc66eee49385c4b21e1d877f5",class:"xpl-input-wrapper"},this.pre&&s("label",{key:"b7701d8c9ddba763709f911393997178fd8ebe28",class:"xpl-input-pre",htmlFor:this.inputId},this.pre),s("input",{key:"fdacd352e22996be3f3edeceb570a6dc2c49728b",type:"date",id:this.inputId,disabled:this.disabled,name:this.name,required:this.required,readonly:this.readonly,placeholder:this.placeholder,max:this.max,min:this.min,ref:t=>{this.input=t??void 0},onChange:t=>{this.valueChanged(t)}}),s("xpl-icon",{key:"6eb3953655f7186648ab7602eb4aa6ce8a3e70cc",class:"xpl-input-calendar",icon:"calendar",size:24}),this.post&&s("label",{key:"4191049e3d4378d99b83bd6ebfd458953a70286e",class:"xpl-input-post",htmlFor:this.inputId},this.post)))}get el(){return h(this)}static get watchers(){return{hasErrorState:[{onHasErrorStateChanged:0}],value:[{onValueChanged:0}]}}},p=class{constructor(s){t(this,s),this.inputChange=i(this,"inputChange",7),this.accept="",this.multiple=!1,this.hideTriggerOnSelect=!1,this.hideFileNames=!1,this.hideAcceptText=!1,this.files=null,this.openFileDialog=()=>{this.disabled||this.fileInput?.click()},this.handleFileChange=t=>{const i=t.target;this.files=i.files?Array.from(i.files):null},this.onRemoveFileByIndex=t=>{this.files=(this.files??[]).filter(((i,s)=>s!==t))}}onFilesChange(t){this.inputChange.emit({type:"file",value:t})}async removeFileByIndex(t){this.onRemoveFileByIndex(t)}render(){return s(e,{key:"87eead553435ce984945ccb72ca262bfd6123562",class:{"xpl-input-file":!0,"xpl-input-file--hide-trigger-on-select":!!this.hideTriggerOnSelect,"xpl-input-file--disabled":!!this.disabled}},s("span",{key:"f345204405d1bb784fc662fa3c29e9edaeca9c67",class:{"xpl-input-file__trigger-wrapper":!0,"xpl-input-file__trigger-wrapper--hidden":!!this.hideTriggerOnSelect&&(this.files?.length??0)>0},role:"button",tabIndex:0,onClick:this.openFileDialog},s("slot",{key:"46c4e817cb8f8b050b4de5c571757c7ed84698a7",name:"trigger"})),(this.files?.length??0)>0&&!this.hideFileNames&&s("ul",{key:"455af4a3cad84232464927efb880ce0a26cebf71",class:"xpl-input-file__file-list"},(this.files??[]).map(((t,i)=>s("li",{class:"xpl-input-file__file-item"},s("span",{class:"xpl-input-file__file-name"},t.name),s("xpl-icon",{icon:"x-circle",size:24,onClick:t=>{t.preventDefault(),t.stopPropagation(),this.onRemoveFileByIndex(i)},class:"xpl-input-file__remove-icon"}))))),this.accept&&!this.hideAcceptText&&s("span",{key:"77abc822d8d44b33f251d4ba9ef21cfc7dd6c287",class:"xpl-input-file__accept"},"Accepted file types: ",this.accept),s("input",{key:"d75ec23921943259d789b0f32828dca57864520e",onChange:this.handleFileChange,type:"file",ref:t=>{this.fileInput=t??void 0},hidden:!0,accept:this.accept,multiple:this.multiple,name:this.name}))}get el(){return h(this)}static get watchers(){return{files:[{onFilesChange:0}]}}},u=class{constructor(s){t(this,s),this.blurEvent=i(this,"blurEvent",7),this.focusEvent=i(this,"focusEvent",7),this.inputEvent=i(this,"inputEvent",7),this.search=i(this,"search",7),this.valueChange=i(this,"valueChange",7),this.hasAncestorForm=!1,this.ariaLabel="Search",this.autocomplete="off",this.disabled=!1,this.hasError=!1,this.hasVisibleLabel=!1,this.placeholder="Search",this.readonly=!1,this.required=!1,this.shape="rounded",this.value="",this.handleInnerFormSubmit=t=>{t.preventDefault(),this.disabled||this.readonly||this.emitSearchCommit(this.value.trim())},this.handleClear=t=>{t.preventDefault(),this.disabled||this.readonly||(this.value="",this.valueChange.emit(""),this.inputEvent.emit(""),this.inputEl?.focus())},this.handleInput=t=>{const i=t.target;this.value=i.value,this.valueChange.emit(i.value),this.inputEvent.emit(i.value)},this.handleKeyDown=t=>{"Enter"===t.key&&(this.disabled||this.readonly||t.target.form||(t.preventDefault(),this.emitSearchCommit(this.value.trim())))},this.handleFocus=t=>{this.focusEvent.emit(t)},this.handleBlur=t=>{this.blurEvent.emit(t)}}connectedCallback(){this.syncAncestorFormFlag()}async setFocus(){this.inputEl?.focus()}syncAncestorFormFlag(){const t=this.el,i=Boolean(t&&"function"==typeof t.closest&&t.closest("form"));this.hasAncestorForm!==i&&(this.hasAncestorForm=i)}get hasValue(){return void 0!==this.value&&this.value.length>0}get resolvedInputAriaLabel(){if(!this.hasVisibleLabel)return(this.ariaLabel??"").trim()||"Search"}get rendersInnerSearchForm(){return!this.hasAncestorForm}emitSearchCommit(t){this.search.emit(t)}renderShell(){const t=s("div",{class:"xpl-input-search__shell"},s("span",{class:"xpl-input-search__icon","aria-hidden":"true"},s("xpl-icon",{icon:"magnifier",size:20})),s("input",{"aria-describedby":this.hasError?this.errorMessageId:void 0,"aria-invalid":this.hasError?"true":void 0,"aria-label":this.resolvedInputAriaLabel,autocomplete:this.autocomplete,class:"xpl-input-search__input",disabled:this.disabled,id:this.inputId,name:this.name,onBlur:this.handleBlur,onFocus:this.handleFocus,onInput:this.handleInput,onKeyDown:this.handleKeyDown,placeholder:this.placeholder,readonly:this.readonly,ref:t=>{this.inputEl=t??void 0},required:this.required,role:"searchbox",type:"text",value:this.value}),s("button",{"aria-hidden":this.hasValue?void 0:"true","aria-label":"Clear search",class:"xpl-input-search__clear",disabled:this.disabled||this.readonly,onClick:this.handleClear,type:"button"},s("xpl-icon",{icon:"circle-xmark",size:16})));return this.rendersInnerSearchForm?s("form",{class:"xpl-input-search__form",onSubmit:this.handleInnerFormSubmit},t):t}render(){return s(e,{key:"90b29d51b36655d1dc5f7fa9b67edf6382cb90af",class:{"xpl-input-search":!0,"xpl-input-search--disabled":this.disabled,"xpl-input-search--error":this.hasError,"xpl-input-search--has-value":this.hasValue,"xpl-input-search--readonly":this.readonly,"xpl-input-search--shape-box":"box"===this.shape}},this.renderShell())}get el(){return h(this)}};export{l as xpl_input,d as xpl_input_date,p as xpl_input_file,u as xpl_input_search}
@@ -1 +1 @@
1
- import{r as t,h as e,H as s}from"./p-CJABLO_1.js";const i=class{constructor(e){t(this,e),this.disabled=!1,this.selected=!1,this.isDisabled=!1}componentWillLoad(){this.isDisabled=this.disabled}componentDidLoad(){this.updateRowCellsDisabledState()}componentDidUpdate(){this.updateRowCellsDisabledState()}updateRowCellsDisabledState(){(this.hostElement?.querySelectorAll("xpl-dynamic-table-cell")??[]).forEach((t=>{t.disabled=this.isDisabled}))}render(){return e(s,{key:"94044631c91c393c734c437ff74f182fdeb950dd",role:"row",class:`xpl-dynamic-table-row\n ${this.isDisabled?"disabled":""}\n ${this.selected?"selected":""}`,ref:t=>{this.hostElement=t??void 0}},e("slot",{key:"182eabc2d78e66cd92cff945b814b32d734ef326"}))}};export{i as xpl_dynamic_table_row}
1
+ import{r as t,h as e,H as s}from"./p-CgJEmBQY.js";const i=class{constructor(e){t(this,e),this.disabled=!1,this.selected=!1,this.isDisabled=!1}componentWillLoad(){this.isDisabled=this.disabled}componentDidLoad(){this.updateRowCellsDisabledState()}componentDidUpdate(){this.updateRowCellsDisabledState()}updateRowCellsDisabledState(){(this.hostElement?.querySelectorAll("xpl-dynamic-table-cell")??[]).forEach((t=>{t.disabled=this.isDisabled}))}render(){return e(s,{key:"94044631c91c393c734c437ff74f182fdeb950dd",role:"row",class:`xpl-dynamic-table-row\n ${this.isDisabled?"disabled":""}\n ${this.selected?"selected":""}`,ref:t=>{this.hostElement=t??void 0}},e("slot",{key:"182eabc2d78e66cd92cff945b814b32d734ef326"}))}};export{i as xpl_dynamic_table_row}
@@ -1 +1 @@
1
- import{r as t,h as a,H as s,g as r,c as i}from"./p-CJABLO_1.js";import{v as e}from"./p-CK3_k8jD.js";const l={active:"green",inactive:"gray",warning:"red"};function h(t){if(!t||!t.trim())return"";const a=t.trim().split(/\s+/).filter(Boolean);return 0===a.length?"":1===a.length?a[0].slice(0,3).toUpperCase():((a[0][0]??"")+(a.length>2?a[1][0]??"":"")+(a[a.length-1][0]??"")).slice(0,3).toUpperCase()}const n=class{constructor(a){t(this,a),this.cachedGroupItems=[],this.cachedSlotContent="",this.disabled=!1}onGroupDataChange(t){this.cachedGroupItems=n.parseGroupData(t)}componentWillLoad(){this.cachedSlotContent=this.el?.textContent?.trim().slice(0,3)??"",this.onGroupDataChange(this.groupData)}static parseGroupData(t){if(null==t)return[];if("string"==typeof t)try{const a=JSON.parse(t);return Array.isArray(a)?a:[]}catch{return console.warn("[Apollo] xpl-avatar: groupData is not valid JSON; rendering no group items"),[]}return Array.isArray(t)?t:[]}get groupItems(){return this.cachedGroupItems}get statusBadgeVariant(){const t=this.status;if(void 0!==t)return l[t]??t}getPlaceholderText(){return this.cachedSlotContent.length>0?this.cachedSlotContent:h(this.name)}static getSingleAvatarClasses(t,a,s,r){return{"xpl-avatar":!0,[`xpl-avatar--${t}`]:!!t,[`xpl-avatar--${a}`]:!!a,"xpl-avatar--profile":!!s,"xpl-avatar--disabled":!!r}}getAnchorProps(t){return{href:this.href,target:this.target,rel:"_blank"===this.target?"noopener noreferrer":void 0,"aria-label":this.name??"Profile",class:t}}static renderAvatarMedia(t,s,r,i,e=!0){return t?a("img",{alt:s??"",src:t}):a("div",{class:"xpl-avatar__placeholder",role:"img","aria-label":s??i},r||(e?a("slot",null):null))}renderAvatarMediaWithStatusBadge(t){const s=this.getPlaceholderText();return a("div",{...t?{class:t}:{}},n.renderAvatarMedia(this.src,this.name,s,"Profile",!0),this.statusBadgeVariant&&a("xpl-badge",{dotOnly:!0,bordered:!0,variant:this.statusBadgeVariant,"aria-hidden":"true"}))}renderGroupItem(t,s){const r=t.name?h(t.name):"";return a("div",{class:{"xpl-avatar-group__item":!0,"xpl-avatar":!0,[`xpl-avatar--${this.size}`]:!!this.size,[`xpl-avatar--${t.color}`]:!!t.color}},a("div",null,n.renderAvatarMedia(t.src,t.name,r,`Member ${s+1}`,!1)))}renderWithTextContent(){return a("div",{class:"xpl-avatar__with-text-content"},a("div",{class:"xpl-avatar__with-text-name"},this.name),this.subText&&a("div",{class:"xpl-avatar__with-text-sub"},this.subText))}render(){const t=this.variant;if("group"===t){const t=this.groupItems,r=t.slice(0,4),i=t.length-4,e=i>0,l=e?function(t){if(t<=0)return"";if(t<=999)return`+${t}`;const a=500*Math.round(t/500)/1e3;return"+"+(a%1==0?`${a}k`:`${a.toFixed(1)}k`)}(i):"";return a(s,null,a("div",{class:{"xpl-avatar-group":!0,[`xpl-avatar-group--${this.size}`]:!!this.size},role:"group","aria-label":`${t.length} members`},r.map(((t,s)=>a("div",{key:s,class:"xpl-avatar-group__wrap"},this.renderGroupItem(t,s)))),e&&a("div",{class:{"xpl-avatar-group__count":!0,[`xpl-avatar-group__count--${this.size}`]:!!this.size},"aria-label":`${i} more`},l)))}if("with-text"===t){const t=this.renderAvatarMediaWithStatusBadge("xpl-avatar__with-text-avatar"),r={"xpl-avatar":!0,"xpl-avatar--with-text":!0,[`xpl-avatar--${this.color}`]:!!this.color,"xpl-avatar--disabled":!!this.disabled};return a(s,null,this.href&&!this.disabled?a("a",{...this.getAnchorProps("xpl-avatar__with-text-link")},a("div",{class:r},t,this.renderWithTextContent())):a("div",{class:r,"aria-disabled":this.disabled?"true":void 0},t,this.renderWithTextContent()))}const r="profile"===t,i=n.getSingleAvatarClasses(r&&"md"===this.size?void 0:this.size,this.color,r,this.disabled),e=this.renderAvatarMediaWithStatusBadge();return a(s,null,this.href&&!this.disabled?a("a",{...this.getAnchorProps(i)},e):a("div",{class:i,"aria-disabled":this.disabled?"true":void 0},e))}get el(){return r(this)}static get watchers(){return{groupData:[{onGroupDataChange:0}]}}},o=class{constructor(a){t(this,a)}render(){let t="xpl-divider";return t+=` xpl-divider--${this.tier}`,a(s,{key:"af5215db4c71b69c9dba81383bd9ae2fa318d7f1",class:t},a("span",{key:"de353b8dd0fa49490b93295a0da8c783a0b664f4"},a("slot",{key:"9a10da3760366b90059113530c7e1799d1a3a89c"})))}},d=class{constructor(a){t(this,a),this.radioChange=i(this,"radioChange",7),this.id=e(),this.onChange=t=>{this.radioChange.emit(this.value?this.value:t.target.checked)}}get isChecked(){return void 0!==this.selectedValue&&void 0!==this.value?this.selectedValue===this.value:Boolean(this.checked)}render(){return a(s,{key:"dec063c59a7fe6bd9680d0bfcec55eabfa782ee0",class:{"xpl-checkbox-radio-container":!0,styled:!!this.styled,disabled:!!this.disabled}},a("input",{key:"ff51ff9e164c663b1583409f37a075a3bb0c03e3",class:"xpl-radio",type:"radio",checked:this.isChecked,disabled:this.disabled,id:this.id,name:this.name,required:this.required,onChange:this.onChange,value:this.value}),a("label",{key:"3d82a7ee345008e237ea52064774b6d751031450",class:{"xpl-label":!0,"xpl-label--disabled":!!this.disabled},htmlFor:this.id},a("slot",{key:"a04ec7ab9149a61f88391bb37556f81e9e172b6e"}),this.description&&a("small",{key:"b03619c554d2438cc152ff37fcaa02be3ba7e0bd",class:{"xpl-description":!0,"xpl-description--disabled":!!this.disabled}},this.description)))}};export{n as xpl_avatar,o as xpl_divider,d as xpl_radio}
1
+ import{r as t,h as a,H as s,g as r,c as i}from"./p-CgJEmBQY.js";import{v as e}from"./p-CK3_k8jD.js";const l={active:"green",inactive:"gray",warning:"red"};function h(t){if(!t||!t.trim())return"";const a=t.trim().split(/\s+/).filter(Boolean);return 0===a.length?"":1===a.length?a[0].slice(0,3).toUpperCase():((a[0][0]??"")+(a.length>2?a[1][0]??"":"")+(a[a.length-1][0]??"")).slice(0,3).toUpperCase()}const n=class{constructor(a){t(this,a),this.cachedGroupItems=[],this.cachedSlotContent="",this.disabled=!1}onGroupDataChange(t){this.cachedGroupItems=n.parseGroupData(t)}componentWillLoad(){this.cachedSlotContent=this.el?.textContent?.trim().slice(0,3)??"",this.onGroupDataChange(this.groupData)}static parseGroupData(t){if(null==t)return[];if("string"==typeof t)try{const a=JSON.parse(t);return Array.isArray(a)?a:[]}catch{return console.warn("[Apollo] xpl-avatar: groupData is not valid JSON; rendering no group items"),[]}return Array.isArray(t)?t:[]}get groupItems(){return this.cachedGroupItems}get statusBadgeVariant(){const t=this.status;if(void 0!==t)return l[t]??t}getPlaceholderText(){return this.cachedSlotContent.length>0?this.cachedSlotContent:h(this.name)}static getSingleAvatarClasses(t,a,s,r){return{"xpl-avatar":!0,[`xpl-avatar--${t}`]:!!t,[`xpl-avatar--${a}`]:!!a,"xpl-avatar--profile":!!s,"xpl-avatar--disabled":!!r}}getAnchorProps(t){return{href:this.href,target:this.target,rel:"_blank"===this.target?"noopener noreferrer":void 0,"aria-label":this.name??"Profile",class:t}}static renderAvatarMedia(t,s,r,i,e=!0){return t?a("img",{alt:s??"",src:t}):a("div",{class:"xpl-avatar__placeholder",role:"img","aria-label":s??i},r||(e?a("slot",null):null))}renderAvatarMediaWithStatusBadge(t){const s=this.getPlaceholderText();return a("div",{...t?{class:t}:{}},n.renderAvatarMedia(this.src,this.name,s,"Profile",!0),this.statusBadgeVariant&&a("xpl-badge",{dotOnly:!0,bordered:!0,variant:this.statusBadgeVariant,"aria-hidden":"true"}))}renderGroupItem(t,s){const r=t.name?h(t.name):"";return a("div",{class:{"xpl-avatar-group__item":!0,"xpl-avatar":!0,[`xpl-avatar--${this.size}`]:!!this.size,[`xpl-avatar--${t.color}`]:!!t.color}},a("div",null,n.renderAvatarMedia(t.src,t.name,r,`Member ${s+1}`,!1)))}renderWithTextContent(){return a("div",{class:"xpl-avatar__with-text-content"},a("div",{class:"xpl-avatar__with-text-name"},this.name),this.subText&&a("div",{class:"xpl-avatar__with-text-sub"},this.subText))}render(){const t=this.variant;if("group"===t){const t=this.groupItems,r=t.slice(0,4),i=t.length-4,e=i>0,l=e?function(t){if(t<=0)return"";if(t<=999)return`+${t}`;const a=500*Math.round(t/500)/1e3;return"+"+(a%1==0?`${a}k`:`${a.toFixed(1)}k`)}(i):"";return a(s,null,a("div",{class:{"xpl-avatar-group":!0,[`xpl-avatar-group--${this.size}`]:!!this.size},role:"group","aria-label":`${t.length} members`},r.map(((t,s)=>a("div",{key:s,class:"xpl-avatar-group__wrap"},this.renderGroupItem(t,s)))),e&&a("div",{class:{"xpl-avatar-group__count":!0,[`xpl-avatar-group__count--${this.size}`]:!!this.size},"aria-label":`${i} more`},l)))}if("with-text"===t){const t=this.renderAvatarMediaWithStatusBadge("xpl-avatar__with-text-avatar"),r={"xpl-avatar":!0,"xpl-avatar--with-text":!0,[`xpl-avatar--${this.color}`]:!!this.color,"xpl-avatar--disabled":!!this.disabled};return a(s,null,this.href&&!this.disabled?a("a",{...this.getAnchorProps("xpl-avatar__with-text-link")},a("div",{class:r},t,this.renderWithTextContent())):a("div",{class:r,"aria-disabled":this.disabled?"true":void 0},t,this.renderWithTextContent()))}const r="profile"===t,i=n.getSingleAvatarClasses(r&&"md"===this.size?void 0:this.size,this.color,r,this.disabled),e=this.renderAvatarMediaWithStatusBadge();return a(s,null,this.href&&!this.disabled?a("a",{...this.getAnchorProps(i)},e):a("div",{class:i,"aria-disabled":this.disabled?"true":void 0},e))}get el(){return r(this)}static get watchers(){return{groupData:[{onGroupDataChange:0}]}}},o=class{constructor(a){t(this,a)}render(){let t="xpl-divider";return t+=` xpl-divider--${this.tier}`,a(s,{key:"af5215db4c71b69c9dba81383bd9ae2fa318d7f1",class:t},a("span",{key:"de353b8dd0fa49490b93295a0da8c783a0b664f4"},a("slot",{key:"9a10da3760366b90059113530c7e1799d1a3a89c"})))}},d=class{constructor(a){t(this,a),this.radioChange=i(this,"radioChange",7),this.id=e(),this.onChange=t=>{this.radioChange.emit(this.value?this.value:t.target.checked)}}get isChecked(){return void 0!==this.selectedValue&&void 0!==this.value?this.selectedValue===this.value:Boolean(this.checked)}render(){return a(s,{key:"dec063c59a7fe6bd9680d0bfcec55eabfa782ee0",class:{"xpl-checkbox-radio-container":!0,styled:!!this.styled,disabled:!!this.disabled}},a("input",{key:"ff51ff9e164c663b1583409f37a075a3bb0c03e3",class:"xpl-radio",type:"radio",checked:this.isChecked,disabled:this.disabled,id:this.id,name:this.name,required:this.required,onChange:this.onChange,value:this.value}),a("label",{key:"3d82a7ee345008e237ea52064774b6d751031450",class:{"xpl-label":!0,"xpl-label--disabled":!!this.disabled},htmlFor:this.id},a("slot",{key:"a04ec7ab9149a61f88391bb37556f81e9e172b6e"}),this.description&&a("small",{key:"b03619c554d2438cc152ff37fcaa02be3ba7e0bd",class:{"xpl-description":!0,"xpl-description--disabled":!!this.disabled}},this.description)))}};export{n as xpl_avatar,o as xpl_divider,d as xpl_radio}
@@ -1 +1 @@
1
- import{r as t,c as e,h as a,H as s}from"./p-CJABLO_1.js";const i=class{constructor(a){t(this,a),this.pageChange=e(this,"pageChange",7),this.rowsPerPageChange=e(this,"rowsPerPageChange",7),this.totalPages=1,this.withPageControl=!1,this.currentPage=1,this.rowsPerPageOptions="10,25,50,100,150",this.selectedRowsPerPage=10,this.rowsPerPageSelectRef=null,this.pageSelectRef=null,this.pageChoices=[],this.handleNextPage=()=>{this.currentPage<this.totalPages&&(this.currentPage+=1)},this.handlePrevPage=()=>{this.currentPage>1&&(this.currentPage-=1)},this.handlePageChange=t=>{const e=parseInt(t.detail,10);Number.isNaN(e)||(this.currentPage=e)},this.handleRowsChange=t=>{const e=parseInt(t.detail,10);Number.isNaN(e)||(this.selectedRowsPerPage=e)}}get rowsPerPageOptionsArray(){return this.rowsPerPageOptions.split(",").map(Number)}onPageUpdate(t){t<1?this.currentPage=1:t>this.totalPages&&(this.currentPage=this.totalPages),this.buildPageChoices(),this.pageChange.emit(this.currentPage)}onTotalPagesUpdate(){this.currentPage>this.totalPages?this.currentPage=this.totalPages:this.buildPageChoices()}onRowsPerPageUpdate(t){this.rowsPerPageChange.emit(t)}buildPageChoices(){this.pageChoices=Array.from({length:this.totalPages},((t,e)=>({label:`Page ${e+1}`,value:(e+1).toString(),isSelected:e+1===this.currentPage})))}componentWillLoad(){this.buildPageChoices()}componentDidLoad(){this.rowsPerPageSelectRef?.addEventListener("changeEvent",this.handleRowsChange),this.pageSelectRef?.addEventListener("changeEvent",this.handlePageChange)}disconnectedCallback(){this.rowsPerPageSelectRef?.removeEventListener("changeEvent",this.handleRowsChange),this.pageSelectRef?.removeEventListener("changeEvent",this.handlePageChange)}render(){const t=this.currentPage<=1,e=this.currentPage>=this.totalPages;return a(s,{key:"c1236f3a51a835bc7609f1871718535ad26c608c",class:{"xpl-pagination":!0,"xpl-pagination__with-page-control":this.withPageControl,"xpl-pagination__no-page-control":!this.withPageControl}},this.withPageControl&&a("div",{key:"b9a960512110e71ec4403a7440d9a56d2d25eb5a",class:"xpl-pagination__rows-per-page"},a("label",{key:"77d5c99067a80412b99fd7319a647fea67be9ae2",class:"xpl-pagination__rows-label"},"Rows per page:"),a("xpl-select",{key:"530bac1621b9901c52f895649f838ddd7919522f",class:"xpl-pagination__rows-per-page-select",dropdownFlipFallbackPlacements:["bottom-start"],dropdownPlacement:"top-start",choices:this.rowsPerPageOptionsArray.map((t=>({label:t.toString(),value:t.toString(),isSelected:t===this.selectedRowsPerPage}))),ref:t=>{this.rowsPerPageSelectRef=t??null}})),a("div",{key:"f610c71b562c73d1ef6ce81550ee9c5f5318b46a",class:"xpl-pagination__pager"},a("button",{key:"f507f26b1b3239c170c60568da2a068ffdc65def",class:"xpl-pagination__pager-button xpl-pagination__pager-button-prev",disabled:t,onClick:this.handlePrevPage,"aria-label":"Previous Page",tabindex:"0"},a("xpl-icon",{key:"c1079f632bb84a97bcb43ab7f39af19d2532e73c",icon:"arrow-left",size:20})),a("xpl-select",{key:"b50192f67d3e5b5c6723131d554d1dad41f8e2a3",class:"xpl-pagination__page-select",dropdownFlipFallbackPlacements:["bottom-start"],dropdownPlacement:"top-start",choices:this.pageChoices,"custom-display-value":!0,ref:t=>{this.pageSelectRef=t??null}},a("div",{key:"35cb95f79705633857df8ef3a48b479c85d6acdd",slot:"custom-display-value"},`${this.currentPage} of ${this.totalPages}`)),a("button",{key:"79a8b1f267fe675eb626d655a68ad5c72cd6c89f",class:"xpl-pagination__pager-button xpl-pagination__pager-button-next",disabled:e,onClick:this.handleNextPage,"aria-label":"Next Page",tabindex:"0"},a("xpl-icon",{key:"01ae55d805794de8fb9f332a37314e152fb1f5bb",icon:"arrow-right",size:20}))))}static get watchers(){return{currentPage:[{onPageUpdate:0}],totalPages:[{onTotalPagesUpdate:0}],selectedRowsPerPage:[{onRowsPerPageUpdate:0}]}}};export{i as xpl_pagination}
1
+ import{r as t,c as e,h as a,H as s}from"./p-CgJEmBQY.js";const i=class{constructor(a){t(this,a),this.pageChange=e(this,"pageChange",7),this.rowsPerPageChange=e(this,"rowsPerPageChange",7),this.totalPages=1,this.withPageControl=!1,this.currentPage=1,this.rowsPerPageOptions="10,25,50,100,150",this.selectedRowsPerPage=10,this.rowsPerPageSelectRef=null,this.pageSelectRef=null,this.pageChoices=[],this.handleNextPage=()=>{this.currentPage<this.totalPages&&(this.currentPage+=1)},this.handlePrevPage=()=>{this.currentPage>1&&(this.currentPage-=1)},this.handlePageChange=t=>{const e=parseInt(t.detail,10);Number.isNaN(e)||(this.currentPage=e)},this.handleRowsChange=t=>{const e=parseInt(t.detail,10);Number.isNaN(e)||(this.selectedRowsPerPage=e)}}get rowsPerPageOptionsArray(){return this.rowsPerPageOptions.split(",").map(Number)}onPageUpdate(t){t<1?this.currentPage=1:t>this.totalPages&&(this.currentPage=this.totalPages),this.buildPageChoices(),this.pageChange.emit(this.currentPage)}onTotalPagesUpdate(){this.currentPage>this.totalPages?this.currentPage=this.totalPages:this.buildPageChoices()}onRowsPerPageUpdate(t){this.rowsPerPageChange.emit(t)}buildPageChoices(){this.pageChoices=Array.from({length:this.totalPages},((t,e)=>({label:`Page ${e+1}`,value:(e+1).toString(),isSelected:e+1===this.currentPage})))}componentWillLoad(){this.buildPageChoices()}componentDidLoad(){this.rowsPerPageSelectRef?.addEventListener("changeEvent",this.handleRowsChange),this.pageSelectRef?.addEventListener("changeEvent",this.handlePageChange)}disconnectedCallback(){this.rowsPerPageSelectRef?.removeEventListener("changeEvent",this.handleRowsChange),this.pageSelectRef?.removeEventListener("changeEvent",this.handlePageChange)}render(){const t=this.currentPage<=1,e=this.currentPage>=this.totalPages;return a(s,{key:"c1236f3a51a835bc7609f1871718535ad26c608c",class:{"xpl-pagination":!0,"xpl-pagination__with-page-control":this.withPageControl,"xpl-pagination__no-page-control":!this.withPageControl}},this.withPageControl&&a("div",{key:"b9a960512110e71ec4403a7440d9a56d2d25eb5a",class:"xpl-pagination__rows-per-page"},a("label",{key:"77d5c99067a80412b99fd7319a647fea67be9ae2",class:"xpl-pagination__rows-label"},"Rows per page:"),a("xpl-select",{key:"530bac1621b9901c52f895649f838ddd7919522f",class:"xpl-pagination__rows-per-page-select",dropdownFlipFallbackPlacements:["bottom-start"],dropdownPlacement:"top-start",choices:this.rowsPerPageOptionsArray.map((t=>({label:t.toString(),value:t.toString(),isSelected:t===this.selectedRowsPerPage}))),ref:t=>{this.rowsPerPageSelectRef=t??null}})),a("div",{key:"f610c71b562c73d1ef6ce81550ee9c5f5318b46a",class:"xpl-pagination__pager"},a("button",{key:"f507f26b1b3239c170c60568da2a068ffdc65def",class:"xpl-pagination__pager-button xpl-pagination__pager-button-prev",disabled:t,onClick:this.handlePrevPage,"aria-label":"Previous Page",tabindex:"0"},a("xpl-icon",{key:"c1079f632bb84a97bcb43ab7f39af19d2532e73c",icon:"arrow-left",size:20})),a("xpl-select",{key:"b50192f67d3e5b5c6723131d554d1dad41f8e2a3",class:"xpl-pagination__page-select",dropdownFlipFallbackPlacements:["bottom-start"],dropdownPlacement:"top-start",choices:this.pageChoices,"custom-display-value":!0,ref:t=>{this.pageSelectRef=t??null}},a("div",{key:"35cb95f79705633857df8ef3a48b479c85d6acdd",slot:"custom-display-value"},`${this.currentPage} of ${this.totalPages}`)),a("button",{key:"79a8b1f267fe675eb626d655a68ad5c72cd6c89f",class:"xpl-pagination__pager-button xpl-pagination__pager-button-next",disabled:e,onClick:this.handleNextPage,"aria-label":"Next Page",tabindex:"0"},a("xpl-icon",{key:"01ae55d805794de8fb9f332a37314e152fb1f5bb",icon:"arrow-right",size:20}))))}static get watchers(){return{currentPage:[{onPageUpdate:0}],totalPages:[{onTotalPagesUpdate:0}],selectedRowsPerPage:[{onRowsPerPageUpdate:0}]}}};export{i as xpl_pagination}
@@ -1 +1 @@
1
- import{r as t,c as e,h as a,H as r}from"./p-CJABLO_1.js";import{i as s}from"./p-Dqb1pIRo.js";const i=(t,e,a)=>{const r=(a/=100)*(e/=100),s=r*(1-Math.abs(t/60%2-1)),i=a-r;let o=0,n=0,h=0;return t<60?(o=r,n=s,h=0):t<120?(o=s,n=r,h=0):t<180?(o=0,n=r,h=s):t<240?(o=0,n=s,h=r):t<300?(o=s,n=0,h=r):(o=r,n=0,h=s),{r:Math.round(255*(o+i)),g:Math.round(255*(n+i)),b:Math.round(255*(h+i))}},o=(t,e,a)=>[t,e,a].map((t=>t.toString(16).padStart(2,"0"))).join(""),n=t=>{if(t.startsWith("#")){if(!/^#([a-fA-F\d]{6})$/.test(t))throw new Error("xpl-input-color: Only 6-digit hex format supported (e.g. #aabbcc)");const e=t.toLowerCase().slice(1),a=parseInt(e.slice(0,2),16),r=parseInt(e.slice(2,4),16),s=parseInt(e.slice(4,6),16);return{hex:e,r:a,g:r,b:s,a:1}}if(t.startsWith("rgba")||t.startsWith("rgb")){const e=t.match(/[\d.]+/g)?.map(Number);if(!e||e.length<3)throw new Error("xpl-input-color: Invalid rgba/rgb format");const[a,r,s,i=1]=e,o=t=>t.toString(16).padStart(2,"0");return{hex:`${o(a)}${o(r)}${o(s)}`.toLowerCase(),r:a,g:r,b:s,a:i}}if(t.startsWith("hsla")||t.startsWith("hsl")){const e=t.match(/[\d.]+/g)?.map(Number);if(!e||e.length<3)throw new Error("xpl-input-color: Invalid hsla/hsl format");const[a,r,s,i=1]=e,n=((t,e,a,r)=>{a/=100;const s=e=>(e+t/30)%12,i=(e/=100)*Math.min(a,1-a),o=t=>a-i*Math.max(-1,Math.min(s(t)-3,Math.min(9-s(t),1)));return`rgba(${Math.round(255*o(0))}, ${Math.round(255*o(8))}, ${Math.round(255*o(4))}, ${r})`})(a,r,s,i),h=n.match(/[\d.]+/g)?.map(Number);if(!h||h.length<3)throw new Error("xpl-input-color: Invalid hsla/hsl format");const[l,c,d]=h;return{hex:o(l,c,d).toLowerCase(),r:l,g:c,b:d,a:i}}throw new Error("xpl-input-color: Unsupported color format")},h=t=>t.a&&1!==t.a?`rgba(${t.r}, ${t.g}, ${t.b}, ${t.a})`:`#${t.hex}`,l={hex:"",r:0,g:0,b:0,a:1},c=class{constructor(a){t(this,a),this.inputChange=e(this,"inputChange",7),this.hasErrorStateChanged=e(this,"hasErrorStateChanged",7),this.placeholder="Select color",this.eyeDropperSupported=!1,this.colorInputElements={},this.handleMove=t=>{const{slGrid:e}=this.colorInputElements;if(!e)return;const a=e.getBoundingClientRect(),r="touches"in t?t.touches[0].clientY:t.clientY,s=Math.max(0,Math.min(("touches"in t?t.touches[0].clientX:t.clientX)-a.left,a.width)),n=Math.max(0,Math.min(r-a.top,a.height)),h=s/a.width,l=n/a.height,c=i(this.hue,100,100),d=(255*(1-h)+h*c.r)*(1-l),p=(255*(1-h)+h*c.g)*(1-l),u=(255*(1-h)+h*c.b)*(1-l),b={r:Math.round(d),g:Math.round(p),b:Math.round(u),hex:o(Math.round(d),Math.round(p),Math.round(u)),a:this.colorValues.a};this.colorValues=b},this.startDrag=t=>{t.preventDefault(),this.handleMove(t),window.addEventListener("mousemove",this.handleMove),window.addEventListener("mouseup",this.stopDrag),window.addEventListener("touchmove",this.handleMove),window.addEventListener("touchend",this.stopDrag)},this.stopDrag=()=>{window.removeEventListener("mousemove",this.handleMove),window.removeEventListener("mouseup",this.stopDrag),window.removeEventListener("touchmove",this.handleMove),window.removeEventListener("touchend",this.stopDrag)},this.onHexInputChange=t=>{const e=t.detail?t.detail.trim().replace(/#/g,""):"";if(e){const[t,a,r]=(t=>{const e=t?.match(/\w\w/g);return e?e.map((t=>parseInt(t,16))):[0,0,0]})(e);this.colorValues={hex:e,r:t,g:a,b:r,a:this.colorValues.a??1}}else this.colorValues={...l}},this.onRgbaInputChange=(t,e)=>{const a=parseFloat(e.detail);if(Number.isNaN(a))return void(this.hasErrorState=`invalid value from ${t.name}: ${a}`);const r={...this.colorValues};switch(t.name){case"color-r-input":r.r=a;break;case"color-g-input":r.g=a;break;case"color-b-input":r.b=a;break;case"color-a-input":r.a=a;break;default:this.hasErrorState=`unhandled input: ${t.name}`}r.hex=o(r.r,r.g,r.b),this.colorValues=r},this.onSliderInputChange=t=>{const e=parseFloat(t.value);if(Number.isNaN(e))this.hasErrorState=`invalid value from ${t.name}: ${e}`;else switch(t.name){case"color-hue-slider":this.colorValues=n(`hsla(${e}, 100%, 50%, 1)`),this.hue=e;break;case"color-alpha-slider":this.colorValues={...this.colorValues,a:e};break;default:this.hasErrorState=`unhandled input: ${t.name}`}}}valueChanged(t){this.hasErrorState=this.required&&!t.hex?"required":null,this.inputChange.emit(t.hex?h(t):"")}onHasErrorStateChanged(t){this.hasErrorStateChanged.emit(t)}onValuePropChange(t){this.syncColorFromValue(t)}syncColorFromValue(t){if(t)try{this.colorValues=n(t),this.hue=(()=>{const t=this.colorValues.r/255,e=this.colorValues.g/255,a=this.colorValues.b/255,r=Math.max(t,e,a),s=Math.min(t,e,a),i=r-s;let o=0,n=0;const h=(r+s)/2;if(0!==i){switch(n=i/(1-Math.abs(2*h-1)),r){case t:o=(e-a)/i%6;break;case e:o=(a-t)/i+2;break;case a:o=(t-e)/i+4}o*=60,o<0&&(o+=360)}return{hue:Math.round(o),saturation:Math.round(100*n),lightness:Math.round(100*h)}})().hue}catch{this.hasErrorState="invalid color format",this.hue=0}else this.colorValues={...l},this.hasErrorState=null,this.hue=0}componentWillLoad(){this.syncColorFromValue(this.value)}componentDidLoad(){s()&&(this.eyeDropperSupported="EyeDropper"in window);const{r:t,g:e,b:a,a:r,hue:i,alpha:o,hex:n}=this.colorInputElements;n?.addEventListener("valueChange",(t=>{this.onHexInputChange(t),t.stopPropagation()})),[t,e,a,r].forEach((t=>{t?.addEventListener("valueChange",(e=>{this.onRgbaInputChange(t,e),e.stopPropagation()}))})),[i,o].forEach((t=>{t?.addEventListener("input",(()=>{this.onSliderInputChange(t)}))}))}async openEyeDropper(){try{const t=window.EyeDropper;if(!t)throw new Error("EyeDropper API is not available");const e=new t,a=await e.open();this.colorValues=n(a.sRGBHex)}catch(t){this.hasErrorState=`eyedropper cancelled or failed: ${t}`}}render(){const{r:t,g:e,b:s,a:o}=this.colorValues,n=i(this.hue,100,100),{x:l,y:c}=((t,e,a,r)=>{const{s,v:i}=((t,e,a,r)=>{t/=255,e/=255,a/=255;const s=Math.max(t,e,a),i=s-Math.min(t,e,a);let o=0;return o=0===i?0:s===t?(e-a)/i%6:s===e?(a-t)/i+2:(t-e)/i+4,o=Math.round(60*o),o<0&&(o+=360),{h:r??o,s:0===s?0:i/s,v:s}})(e.r,e.g,e.b,t);return{x:Math.round(s*a),y:Math.round((1-i)*r)}})(this.hue,{r:t,g:e,b:s},288,160),d={left:`${l}px`,top:`${c}px`,background:`rgb(${t}, ${e}, ${s})`};return a(r,{key:"baf8bd36a33134bff8b2e1ce1a5d81a567f232b2",class:"xpl-input-color"},a("xpl-popover",{key:"e5bfd446e4b900371ee8ca7c7c321692079c66fb",disabled:this.disabled,display:"menu"},a("div",{key:"9d40ccbf649ba0be2884bbc7dec84d7c1e9ddbb7",slot:"trigger"},a("div",{key:"6b4474af2dab4be116728135214403af7189d99f",class:{"xpl-input-color__display":!0,"xpl-input-color__display--disabled":!!this.disabled,"xpl-input-color__display--error":!!this.hasErrorState}},a("span",{key:"9372da25358b453c5b89f324886c986153b9386b",class:"xpl-input-color__color",style:{background:h(this.colorValues)}}),this.colorValues.hex?a("span",{class:"xpl-input-color__value"},h(this.colorValues)):a("span",{class:"xpl-input-color__placeholder"},this.placeholder),this.eyeDropperSupported&&!this.hideEyeDropper&&a("xpl-icon",{key:"a37bf00e4a70cda5e59cecfc7f108601bbb15e8e",size:20,icon:"eye-dropper",class:"xpl-input-color__icon",onClick:t=>{t.stopPropagation(),this.openEyeDropper()}}))),a("div",{key:"e95b3755b47802b446de5d7e9c25d2238dea23ef",class:"xpl-input-color__menu"},a("div",{key:"9ecc94c286d9cd0a5e25c92eaea3a2dd9ee4394b",class:"xpl-input-color__sl-grid",ref:t=>{this.colorInputElements.slGrid=t??void 0},style:{background:["linear-gradient(to top, #000, #0000)","linear-gradient(to right, #fff, #fff0)",`rgb(${n.r} ${n.g} ${n.b})`].join(", ")},onMouseDown:this.startDrag,onTouchStart:this.startDrag},a("div",{key:"85b2e591be85db2a2d3d1bbe65ee276a857b92fa",class:"xpl-input-color__sl-thumb",style:d})),a("div",{key:"b9d7f2fdc49d73db488d62f21433558b5b0a09a7",class:"xpl-input-color__grid"},a("input",{key:"3c260f54bde2c26a7b5980082cabf54e2d42340e",type:"range",min:"0",max:"360",value:this.hue,class:"xpl-input-color__slider xpl-input-color__hue",name:"color-hue-slider",ref:t=>{this.colorInputElements.hue=t??void 0}}),a("input",{key:"ef8ef568a1487b618aeeb986904a5eeefabba300",type:"range",min:"0",max:"1",step:"0.01",value:o,class:"xpl-input-color__slider xpl-input-color__alpha",name:"color-alpha-slider",ref:t=>{this.colorInputElements.alpha=t??void 0},style:{backgroundImage:[`linear-gradient(to right, rgb(${t} ${e} ${s} / 0) 0%, rgb(${t} ${e} ${s} / 1) 100%)`,"linear-gradient(45deg, #ccc 25%, transparent 25%)","linear-gradient(-45deg, #ccc 25%, transparent 25%)","linear-gradient(45deg, transparent 75%, #ccc 75%)","linear-gradient(-45deg, transparent 75%, #ccc 75%)"].join(", ")}}),a("div",{key:"b4953565664df14ad483f30c45b6ae5e717e6a63",class:"xpl-input-color__preview",style:{background:`rgba(${t}, ${e}, ${s}, ${o})`}})),a("div",{key:"731a00aa7075efc1a19849a58e5a81c8837ab199",class:"xpl-input-color__inputs"},["hex","r","g","b","a"].map((t=>a("xpl-input",{key:t,label:t.toLocaleUpperCase(),name:`color-${t}-input`,placeholder:"hex"===t?"793EF7":"0",value:String(this.colorValues[t]),ref:e=>{this.colorInputElements[t]=e??void 0}})))))))}static get watchers(){return{colorValues:[{valueChanged:0}],hasErrorState:[{onHasErrorStateChanged:0}],value:[{onValuePropChange:0}]}}};export{c as xpl_input_color}
1
+ import{r as t,c as e,h as a,H as r}from"./p-CgJEmBQY.js";import{i as s}from"./p-Dqb1pIRo.js";const i=(t,e,a)=>{const r=(a/=100)*(e/=100),s=r*(1-Math.abs(t/60%2-1)),i=a-r;let o=0,n=0,h=0;return t<60?(o=r,n=s,h=0):t<120?(o=s,n=r,h=0):t<180?(o=0,n=r,h=s):t<240?(o=0,n=s,h=r):t<300?(o=s,n=0,h=r):(o=r,n=0,h=s),{r:Math.round(255*(o+i)),g:Math.round(255*(n+i)),b:Math.round(255*(h+i))}},o=(t,e,a)=>[t,e,a].map((t=>t.toString(16).padStart(2,"0"))).join(""),n=t=>{if(t.startsWith("#")){if(!/^#([a-fA-F\d]{6})$/.test(t))throw new Error("xpl-input-color: Only 6-digit hex format supported (e.g. #aabbcc)");const e=t.toLowerCase().slice(1),a=parseInt(e.slice(0,2),16),r=parseInt(e.slice(2,4),16),s=parseInt(e.slice(4,6),16);return{hex:e,r:a,g:r,b:s,a:1}}if(t.startsWith("rgba")||t.startsWith("rgb")){const e=t.match(/[\d.]+/g)?.map(Number);if(!e||e.length<3)throw new Error("xpl-input-color: Invalid rgba/rgb format");const[a,r,s,i=1]=e,o=t=>t.toString(16).padStart(2,"0");return{hex:`${o(a)}${o(r)}${o(s)}`.toLowerCase(),r:a,g:r,b:s,a:i}}if(t.startsWith("hsla")||t.startsWith("hsl")){const e=t.match(/[\d.]+/g)?.map(Number);if(!e||e.length<3)throw new Error("xpl-input-color: Invalid hsla/hsl format");const[a,r,s,i=1]=e,n=((t,e,a,r)=>{a/=100;const s=e=>(e+t/30)%12,i=(e/=100)*Math.min(a,1-a),o=t=>a-i*Math.max(-1,Math.min(s(t)-3,Math.min(9-s(t),1)));return`rgba(${Math.round(255*o(0))}, ${Math.round(255*o(8))}, ${Math.round(255*o(4))}, ${r})`})(a,r,s,i),h=n.match(/[\d.]+/g)?.map(Number);if(!h||h.length<3)throw new Error("xpl-input-color: Invalid hsla/hsl format");const[l,c,d]=h;return{hex:o(l,c,d).toLowerCase(),r:l,g:c,b:d,a:i}}throw new Error("xpl-input-color: Unsupported color format")},h=t=>t.a&&1!==t.a?`rgba(${t.r}, ${t.g}, ${t.b}, ${t.a})`:`#${t.hex}`,l={hex:"",r:0,g:0,b:0,a:1},c=class{constructor(a){t(this,a),this.inputChange=e(this,"inputChange",7),this.hasErrorStateChanged=e(this,"hasErrorStateChanged",7),this.placeholder="Select color",this.eyeDropperSupported=!1,this.colorInputElements={},this.handleMove=t=>{const{slGrid:e}=this.colorInputElements;if(!e)return;const a=e.getBoundingClientRect(),r="touches"in t?t.touches[0].clientY:t.clientY,s=Math.max(0,Math.min(("touches"in t?t.touches[0].clientX:t.clientX)-a.left,a.width)),n=Math.max(0,Math.min(r-a.top,a.height)),h=s/a.width,l=n/a.height,c=i(this.hue,100,100),d=(255*(1-h)+h*c.r)*(1-l),p=(255*(1-h)+h*c.g)*(1-l),u=(255*(1-h)+h*c.b)*(1-l),b={r:Math.round(d),g:Math.round(p),b:Math.round(u),hex:o(Math.round(d),Math.round(p),Math.round(u)),a:this.colorValues.a};this.colorValues=b},this.startDrag=t=>{t.preventDefault(),this.handleMove(t),window.addEventListener("mousemove",this.handleMove),window.addEventListener("mouseup",this.stopDrag),window.addEventListener("touchmove",this.handleMove),window.addEventListener("touchend",this.stopDrag)},this.stopDrag=()=>{window.removeEventListener("mousemove",this.handleMove),window.removeEventListener("mouseup",this.stopDrag),window.removeEventListener("touchmove",this.handleMove),window.removeEventListener("touchend",this.stopDrag)},this.onHexInputChange=t=>{const e=t.detail?t.detail.trim().replace(/#/g,""):"";if(e){const[t,a,r]=(t=>{const e=t?.match(/\w\w/g);return e?e.map((t=>parseInt(t,16))):[0,0,0]})(e);this.colorValues={hex:e,r:t,g:a,b:r,a:this.colorValues.a??1}}else this.colorValues={...l}},this.onRgbaInputChange=(t,e)=>{const a=parseFloat(e.detail);if(Number.isNaN(a))return void(this.hasErrorState=`invalid value from ${t.name}: ${a}`);const r={...this.colorValues};switch(t.name){case"color-r-input":r.r=a;break;case"color-g-input":r.g=a;break;case"color-b-input":r.b=a;break;case"color-a-input":r.a=a;break;default:this.hasErrorState=`unhandled input: ${t.name}`}r.hex=o(r.r,r.g,r.b),this.colorValues=r},this.onSliderInputChange=t=>{const e=parseFloat(t.value);if(Number.isNaN(e))this.hasErrorState=`invalid value from ${t.name}: ${e}`;else switch(t.name){case"color-hue-slider":this.colorValues=n(`hsla(${e}, 100%, 50%, 1)`),this.hue=e;break;case"color-alpha-slider":this.colorValues={...this.colorValues,a:e};break;default:this.hasErrorState=`unhandled input: ${t.name}`}}}valueChanged(t){this.hasErrorState=this.required&&!t.hex?"required":null,this.inputChange.emit(t.hex?h(t):"")}onHasErrorStateChanged(t){this.hasErrorStateChanged.emit(t)}onValuePropChange(t){this.syncColorFromValue(t)}syncColorFromValue(t){if(t)try{this.colorValues=n(t),this.hue=(()=>{const t=this.colorValues.r/255,e=this.colorValues.g/255,a=this.colorValues.b/255,r=Math.max(t,e,a),s=Math.min(t,e,a),i=r-s;let o=0,n=0;const h=(r+s)/2;if(0!==i){switch(n=i/(1-Math.abs(2*h-1)),r){case t:o=(e-a)/i%6;break;case e:o=(a-t)/i+2;break;case a:o=(t-e)/i+4}o*=60,o<0&&(o+=360)}return{hue:Math.round(o),saturation:Math.round(100*n),lightness:Math.round(100*h)}})().hue}catch{this.hasErrorState="invalid color format",this.hue=0}else this.colorValues={...l},this.hasErrorState=null,this.hue=0}componentWillLoad(){this.syncColorFromValue(this.value)}componentDidLoad(){s()&&(this.eyeDropperSupported="EyeDropper"in window);const{r:t,g:e,b:a,a:r,hue:i,alpha:o,hex:n}=this.colorInputElements;n?.addEventListener("valueChange",(t=>{this.onHexInputChange(t),t.stopPropagation()})),[t,e,a,r].forEach((t=>{t?.addEventListener("valueChange",(e=>{this.onRgbaInputChange(t,e),e.stopPropagation()}))})),[i,o].forEach((t=>{t?.addEventListener("input",(()=>{this.onSliderInputChange(t)}))}))}async openEyeDropper(){try{const t=window.EyeDropper;if(!t)throw new Error("EyeDropper API is not available");const e=new t,a=await e.open();this.colorValues=n(a.sRGBHex)}catch(t){this.hasErrorState=`eyedropper cancelled or failed: ${t}`}}render(){const{r:t,g:e,b:s,a:o}=this.colorValues,n=i(this.hue,100,100),{x:l,y:c}=((t,e,a,r)=>{const{s,v:i}=((t,e,a,r)=>{t/=255,e/=255,a/=255;const s=Math.max(t,e,a),i=s-Math.min(t,e,a);let o=0;return o=0===i?0:s===t?(e-a)/i%6:s===e?(a-t)/i+2:(t-e)/i+4,o=Math.round(60*o),o<0&&(o+=360),{h:r??o,s:0===s?0:i/s,v:s}})(e.r,e.g,e.b,t);return{x:Math.round(s*a),y:Math.round((1-i)*r)}})(this.hue,{r:t,g:e,b:s},288,160),d={left:`${l}px`,top:`${c}px`,background:`rgb(${t}, ${e}, ${s})`};return a(r,{key:"f611b04be640ef01db089c007e7f25b8036c491d",class:"xpl-input-color"},a("xpl-popover",{key:"69543f023b1fac44519bdd4f0f05cc0cb80b9fa0",disabled:this.disabled,display:"menu"},a("div",{key:"6f375f07dfbd4071f0563dfd1f7b29179a8350f2",slot:"trigger"},a("div",{key:"17e69e5cc8e6ae1832ea553d853557e7ebe44203",class:{"xpl-input-color__display":!0,"xpl-input-color__display--disabled":!!this.disabled,"xpl-input-color__display--error":!!this.hasErrorState}},a("span",{key:"9947ea401899d66e7d2ce41c585a9833fa1ad0c7",class:"xpl-input-color__color",style:{background:h(this.colorValues)}}),this.colorValues.hex?a("span",{class:"xpl-input-color__value"},h(this.colorValues)):a("span",{class:"xpl-input-color__placeholder"},this.placeholder),this.eyeDropperSupported&&!this.hideEyeDropper&&a("xpl-icon",{key:"c30ba3d881ddb1949896ca5ff1ae6956c64348d0",size:20,icon:"eye-dropper",class:"xpl-input-color__icon",onClick:t=>{t.stopPropagation(),this.openEyeDropper()}}))),a("div",{key:"5239298cd97594a7d8d7ee5b059e62417757ba1f",class:"xpl-input-color__menu"},a("div",{key:"23552fc0d6cec74386c86b793b2c9ac3db71a0a0",class:"xpl-input-color__sl-grid",ref:t=>{this.colorInputElements.slGrid=t??void 0},style:{background:["linear-gradient(to top, #000, #0000)","linear-gradient(to right, #fff, #fff0)",`rgb(${n.r} ${n.g} ${n.b})`].join(", ")},onMouseDown:this.startDrag,onTouchStart:this.startDrag},a("div",{key:"c483d5d58c54cb6022584a6af5bfdbd761fd559b",class:"xpl-input-color__sl-thumb",style:d})),a("div",{key:"157a8c17341702a2488cf957b54cabef43d11b5d",class:"xpl-input-color__grid"},a("input",{key:"430e5aee2dff413469293bb7b2ce1cbd370cad43",type:"range",min:"0",max:"360",value:this.hue,class:"xpl-input-color__slider xpl-input-color__hue",name:"color-hue-slider",ref:t=>{this.colorInputElements.hue=t??void 0}}),a("input",{key:"d4b3043979ee22de697d61ee97f76743a138e961",type:"range",min:"0",max:"1",step:"0.01",value:o,class:"xpl-input-color__slider xpl-input-color__alpha",name:"color-alpha-slider",ref:t=>{this.colorInputElements.alpha=t??void 0},style:{backgroundImage:[`linear-gradient(to right, rgb(${t} ${e} ${s} / 0) 0%, rgb(${t} ${e} ${s} / 1) 100%)`,"linear-gradient(45deg, #ccc 25%, transparent 25%)","linear-gradient(-45deg, #ccc 25%, transparent 25%)","linear-gradient(45deg, transparent 75%, #ccc 75%)","linear-gradient(-45deg, transparent 75%, #ccc 75%)"].join(", ")}}),a("div",{key:"ed859b34986b4c65b29193d0362fa32fa91ad6db",class:"xpl-input-color__preview",style:{background:`rgba(${t}, ${e}, ${s}, ${o})`}})),a("div",{key:"6330ad3630f75f24b10117af3f98b39db6f6aecc",class:"xpl-input-color__inputs"},["hex","r","g","b","a"].map((t=>a("xpl-input",{key:t,label:t.toLocaleUpperCase(),name:`color-${t}-input`,placeholder:"hex"===t?"793EF7":"0",value:String(this.colorValues[t]),ref:e=>{this.colorInputElements[t]=e??void 0}})))))))}static get watchers(){return{colorValues:[{valueChanged:0}],hasErrorState:[{onHasErrorStateChanged:0}],value:[{onValuePropChange:0}]}}};export{c as xpl_input_color}
@@ -1 +1 @@
1
- import{r as a,c as t,h as i,H as s}from"./p-CJABLO_1.js";const l=class{constructor(i){a(this,i),this.navOpen=t(this,"navOpen",7),this.open=!0}onNavToggle(){this.open=!this.open,this.navOpen.emit(this.open)}componentWillLoad(){this.open=void 0!==this.isNavOpenAtStartup?this.isNavOpenAtStartup:this.open}render(){return i(s,{key:"68d645d450da9bb09ab698b865cdb90643276b04"},i("nav",{key:"7c8e37a3c7029af28eea94f8c4db4a681f903fb7","aria-label":"utility navigation bar",class:"xpl-utility-bar"},this.navControl?i("div",null,i("button",{class:"xpl-utility-bar__nav-control",onClick:()=>this.onNavToggle()},i("xpl-icon",{class:"xpl-utility-nav__bars",icon:"three-bars"})),i("slot",{name:"aside"})):i("slot",{name:"aside"}),i("slot",{key:"36fd1261aeafbdcb52cee2b19b3f29ce7c3f7539",name:"main"})))}};export{l as xpl_utility_bar}
1
+ import{r as a,c as t,h as i,H as s}from"./p-CgJEmBQY.js";const l=class{constructor(i){a(this,i),this.navOpen=t(this,"navOpen",7),this.open=!0}onNavToggle(){this.open=!this.open,this.navOpen.emit(this.open)}componentWillLoad(){this.open=void 0!==this.isNavOpenAtStartup?this.isNavOpenAtStartup:this.open}render(){return i(s,{key:"68d645d450da9bb09ab698b865cdb90643276b04"},i("nav",{key:"7c8e37a3c7029af28eea94f8c4db4a681f903fb7","aria-label":"utility navigation bar",class:"xpl-utility-bar"},this.navControl?i("div",null,i("button",{class:"xpl-utility-bar__nav-control",onClick:()=>this.onNavToggle()},i("xpl-icon",{class:"xpl-utility-nav__bars",icon:"three-bars"})),i("slot",{name:"aside"})):i("slot",{name:"aside"}),i("slot",{key:"36fd1261aeafbdcb52cee2b19b3f29ce7c3f7539",name:"main"})))}};export{l as xpl_utility_bar}
@@ -1 +1 @@
1
- import{r as e,h as o,H as c,g as t}from"./p-CJABLO_1.js";const n=class{constructor(o){e(this,o),this.initialExpanded=!1,this.size="3",this.borderType="none",this.expanded=this.initialExpanded,this.toggleAccordion=e=>{e.stopPropagation(),this.expanded=!this.expanded}}watchInitialExpanded(){this.expanded=this.initialExpanded}async parentCheckboxChange(e){return this.el.querySelectorAll(".xpl-accordion-content .xpl-checkbox:not([disabled])").forEach((o=>{o.checked=e})),null}handleChildCheckboxChange(){const e=this.el.querySelectorAll(".xpl-accordion-content .xpl-checkbox:not([disabled])"),o=Array.from(e).filter((e=>e.checked)).length,c=this.el.querySelector(".xpl-accordion-header xpl-checkbox")||this.el.querySelector(".xpl-accordion-header input");if(c)switch(o){case 0:c.checked=!1,c.indeterminate=!1;break;case e.length:c.checked=!0,c.indeterminate=!1;break;default:c.checked=!1,c.indeterminate=!0}}listenToChangeEvent(){this.handleChildCheckboxChange()}render(){return o(c,{key:"bef7707d1c7aaab18735fdb7b767b54a6cfd9805",class:`xpl-accordion ${{"":"",none:"",bordered:"xpl-accordion--border-bordered"+(this.expanded?"--expanded":""),bottom:"xpl-accordion--border-bottom"+(this.expanded?"--expanded":"")}[this.borderType]}`},o("button",{key:"053fb3d0a2bf253e02d491d26e3a82986352e00e","aria-expanded":this.expanded,"aria-controls":this.contentId,class:"xpl-accordion-toggle-area",onClick:this.toggleAccordion,type:"button"},o("header",{key:"884b58fd83f39537b00bdb932286254447996151",class:`xpl-accordion-header xpl-accordion-header--size-${this.size}`},o("slot",{key:"86ee5ae7cc2c28d5a3d5a273b5597d424e5f677c",name:"heading"},this.header),o("xpl-icon",{key:"e15037ad75519740e11bb4b2bf0ee83950cef3c4",size:16,icon:"chevron-down",class:"xpl-accordion-icon-chevron "+(this.expanded?"xpl-accordion-icon-chevron--rotate":"")})),o("div",{key:"553d3c1e14a5cd870a6f968133d1b3456d2a39dd",class:"xpl-accordion-description"},o("slot",{key:"b114db833bfb9407997b9e2e79e93b83ae9f081a",name:"description"},this.description))),o("section",{key:"92e987377515608b9c9d6ee9de77f32a05644de8",id:this.contentId,role:"region",class:`xpl-accordion-content xpl-accordion-content--${this.expanded?"shown":"hidden"} ${this.expanded?{"":"",none:"",bordered:"xpl-accordion-content--shown-bordered",bottom:"xpl-accordion-content--shown-border-bottom"}[this.borderType]:""}`},o("slot",{key:"0363c341f5554dc9b199c2ddfdc516fc758c46fc",name:"content"})))}get el(){return t(this)}static get watchers(){return{initialExpanded:[{watchInitialExpanded:0}]}}};export{n as xpl_accordion}
1
+ import{r as e,h as o,H as c,g as t}from"./p-CgJEmBQY.js";const n=class{constructor(o){e(this,o),this.initialExpanded=!1,this.size="3",this.borderType="none",this.expanded=this.initialExpanded,this.toggleAccordion=e=>{e.stopPropagation(),this.expanded=!this.expanded}}watchInitialExpanded(){this.expanded=this.initialExpanded}async parentCheckboxChange(e){return this.el.querySelectorAll(".xpl-accordion-content .xpl-checkbox:not([disabled])").forEach((o=>{o.checked=e})),null}handleChildCheckboxChange(){const e=this.el.querySelectorAll(".xpl-accordion-content .xpl-checkbox:not([disabled])"),o=Array.from(e).filter((e=>e.checked)).length,c=this.el.querySelector(".xpl-accordion-header xpl-checkbox")||this.el.querySelector(".xpl-accordion-header input");if(c)switch(o){case 0:c.checked=!1,c.indeterminate=!1;break;case e.length:c.checked=!0,c.indeterminate=!1;break;default:c.checked=!1,c.indeterminate=!0}}listenToChangeEvent(){this.handleChildCheckboxChange()}render(){return o(c,{key:"bef7707d1c7aaab18735fdb7b767b54a6cfd9805",class:`xpl-accordion ${{"":"",none:"",bordered:"xpl-accordion--border-bordered"+(this.expanded?"--expanded":""),bottom:"xpl-accordion--border-bottom"+(this.expanded?"--expanded":"")}[this.borderType]}`},o("button",{key:"053fb3d0a2bf253e02d491d26e3a82986352e00e","aria-expanded":this.expanded,"aria-controls":this.contentId,class:"xpl-accordion-toggle-area",onClick:this.toggleAccordion,type:"button"},o("header",{key:"884b58fd83f39537b00bdb932286254447996151",class:`xpl-accordion-header xpl-accordion-header--size-${this.size}`},o("slot",{key:"86ee5ae7cc2c28d5a3d5a273b5597d424e5f677c",name:"heading"},this.header),o("xpl-icon",{key:"e15037ad75519740e11bb4b2bf0ee83950cef3c4",size:16,icon:"chevron-down",class:"xpl-accordion-icon-chevron "+(this.expanded?"xpl-accordion-icon-chevron--rotate":"")})),o("div",{key:"553d3c1e14a5cd870a6f968133d1b3456d2a39dd",class:"xpl-accordion-description"},o("slot",{key:"b114db833bfb9407997b9e2e79e93b83ae9f081a",name:"description"},this.description))),o("section",{key:"92e987377515608b9c9d6ee9de77f32a05644de8",id:this.contentId,role:"region",class:`xpl-accordion-content xpl-accordion-content--${this.expanded?"shown":"hidden"} ${this.expanded?{"":"",none:"",bordered:"xpl-accordion-content--shown-bordered",bottom:"xpl-accordion-content--shown-border-bottom"}[this.borderType]:""}`},o("slot",{key:"0363c341f5554dc9b199c2ddfdc516fc758c46fc",name:"content"})))}get el(){return t(this)}static get watchers(){return{initialExpanded:[{watchInitialExpanded:0}]}}};export{n as xpl_accordion}
@@ -1 +1 @@
1
- import{r as c,h as a,H as e}from"./p-CJABLO_1.js";const r=class{constructor(a){c(this,a)}render(){return a(e,{key:"60cb6c9909d943691552665d71cb9fcf2e5fc190",class:"xpl-secondary-nav"},a("nav",{key:"0890f096dc8621b6890835594385c392e0ef9905","aria-label":"Secondary Nav"},a("slot",{key:"a9506445f06cc508969c1d6cff962b0553a01a5f"})))}};export{r as xpl_secondary_nav}
1
+ import{r as c,h as a,H as e}from"./p-CgJEmBQY.js";const r=class{constructor(a){c(this,a)}render(){return a(e,{key:"60cb6c9909d943691552665d71cb9fcf2e5fc190",class:"xpl-secondary-nav"},a("nav",{key:"0890f096dc8621b6890835594385c392e0ef9905","aria-label":"Secondary Nav"},a("slot",{key:"a9506445f06cc508969c1d6cff962b0553a01a5f"})))}};export{r as xpl_secondary_nav}
@@ -1 +1 @@
1
- import{r as e,h as t,H as l,g as s,c as i}from"./p-CJABLO_1.js";import{c as a,X as c,b as h}from"./p-O7gQjVdS.js";const r="data-xpl-table-cell-managed-disabled",n=class{constructor(t){e(this,t),this.align="left",this.bold=!1,this.disabled=!1,this.underline=!1}onDisabledChange(){this.propagateDisabledToSlotted()}componentDidLoad(){this.propagateDisabledToSlotted()}propagateDisabledToSlotted(){const e=e=>{if(!function(e){if("disabled"in e)return!0;switch(e.tagName){case"BUTTON":case"INPUT":case"SELECT":case"TEXTAREA":case"FIELDSET":case"OPTGROUP":case"OPTION":return!0;default:return!1}}(e))return;const t=e;if(this.disabled){if(t.disabled)return;return t.disabled=!0,t.setAttribute("disabled",""),void t.setAttribute(r,"")}t.hasAttribute(r)&&(t.disabled=!1,t.removeAttribute("disabled"),t.removeAttribute(r))},t=l=>{Array.from(l.children).forEach((l=>{"XPL-TABLE"!==l.tagName&&(e(l),t(l))}))};t(this.el)}render(){return t(l,{key:"f2b486b9dbab0c982fc3362e1775a99eebc1ac05",role:"gridcell",class:{"xpl-table-cell":!0,[`xpl-table-cell--align-${this.align}`]:!0,"xpl-table-cell--bold":this.bold,"xpl-table-cell--underline":this.underline,"xpl-table-cell--disabled":this.disabled}},t("slot",{key:"19c3a0f67b3eccdb3e6441ba74b8e9d5bb8d0ae6"}))}get el(){return s(this)}static get watchers(){return{disabled:[{onDisabledChange:0}]}}},o=class{constructor(t){e(this,t),this.align="left"}render(){return t(l,{key:"468d80c698b82031537d12584494bb8e42cc4a83",class:{"xpl-table-footer-cell":!0,[`xpl-table-footer-cell--align-${this.align}`]:!0},role:"gridcell"},t("slot",{key:"91674140e7e618b7ff40c58ebbdae79145318de9"}))}},d=class{constructor(t){e(this,t),this.headerCheckboxChange=i(this,"headerCheckboxChange",7),this.headerSortChange=i(this,"headerSortChange",7),this.align="left",this.checked=!1,this.indeterminate=!1,this.label="",this.sortable=!1,this.type="label",this.onHeaderInnerCheckboxChange=e=>{const{detail:t}=e,l="boolean"==typeof t?t:Boolean(t);this.headerCheckboxChange.emit(l)},this.onSortActivate=e=>{if(e.preventDefault(),e.stopPropagation(),!this.sortable||"label"!==this.type)return;const t=this.getColumnIndex0(),l=this.getSortKeySlug();this.el.closest("xpl-table")||(this.sortDirection=a(this.sortDirection)),this.headerSortChange.emit({columnIndex:t,sortKey:l})}}watchColumnWidth(){this.notifyColumnWidthsChange()}watchWidth(){this.notifyColumnWidthsChange()}componentDidLoad(){this.notifyColumnWidthsChange()}notifyColumnWidthsChange(){this.el.dispatchEvent(new CustomEvent(c,{bubbles:!0,composed:!0}))}getColumnIndex0(){return Array.from(this.el.parentElement?.children??[]).indexOf(this.el)}getSortKeySlug(){const e=(this.sortKey??this.label??"").trim();return e.length>0?e.replace(/ /g,"-").toLowerCase():`column-${this.getColumnIndex0()}`}renderLabelText(){return t("span",{class:"xpl-table-header-cell__text"},this.label,t("slot",null))}renderLabelContent(){if(this.sortable){const e=h(this.sortDirection),l="asc"===this.sortDirection||"desc"===this.sortDirection;return t("button",{type:"button",class:"xpl-table-header-cell__sort",onClick:this.onSortActivate},this.renderLabelText(),t("xpl-icon",{class:{"xpl-table-header-cell__sort-icon":!0,"xpl-table-header-cell__sort-icon--active":l,"xpl-table-header-cell__sort-icon--default":!l},icon:e,size:16}))}return this.renderLabelText()}render(){const e=this.getColumnIndex0()+1,s=`xpl-table-header-cell--align-${"checkbox"!==this.type&&"icon"!==this.type||"left"!==this.align?this.align:"center"}`,i="label"===this.type&&this.sortable?"asc"===this.sortDirection?"ascending":"desc"===this.sortDirection?"descending":"none":void 0;return t(l,{role:"columnheader","aria-colindex":e,class:{"xpl-table-header-cell":!0,[s]:!0,"xpl-table-header-cell--checkbox":"checkbox"===this.type,"xpl-table-header-cell--icon":"icon"===this.type,"xpl-table-header-cell--empty":"empty"===this.type,"xpl-table-header-cell--sortable":this.sortable&&"label"===this.type},"aria-checked":"checkbox"===this.type?this.indeterminate?"mixed":this.checked?"true":"false":void 0,"aria-sort":i},"empty"===this.type?null:(()=>{switch(this.type){case"label":return this.renderLabelContent();case"checkbox":return t("xpl-checkbox",{ariaLabel:this.checkboxAriaLabel??"Select all rows",checked:this.checked,indeterminate:this.indeterminate,onCheckboxChange:this.onHeaderInnerCheckboxChange});case"icon":return this.icon?t("xpl-icon",{icon:this.icon,size:20}):null;case"empty":return null;default:return""}})())}get el(){return s(this)}static get watchers(){return{columnWidth:[{watchColumnWidth:0}],width:[{watchWidth:0}]}}};export{n as xpl_table_cell,o as xpl_table_footer_cell,d as xpl_table_header_cell}
1
+ import{r as e,h as t,H as l,g as s,c as i}from"./p-CgJEmBQY.js";import{c as a,X as c,b as h}from"./p-O7gQjVdS.js";const r="data-xpl-table-cell-managed-disabled",n=class{constructor(t){e(this,t),this.align="left",this.bold=!1,this.disabled=!1,this.underline=!1}onDisabledChange(){this.propagateDisabledToSlotted()}componentDidLoad(){this.propagateDisabledToSlotted()}propagateDisabledToSlotted(){const e=e=>{if(!function(e){if("disabled"in e)return!0;switch(e.tagName){case"BUTTON":case"INPUT":case"SELECT":case"TEXTAREA":case"FIELDSET":case"OPTGROUP":case"OPTION":return!0;default:return!1}}(e))return;const t=e;if(this.disabled){if(t.disabled)return;return t.disabled=!0,t.setAttribute("disabled",""),void t.setAttribute(r,"")}t.hasAttribute(r)&&(t.disabled=!1,t.removeAttribute("disabled"),t.removeAttribute(r))},t=l=>{Array.from(l.children).forEach((l=>{"XPL-TABLE"!==l.tagName&&(e(l),t(l))}))};t(this.el)}render(){return t(l,{key:"f2b486b9dbab0c982fc3362e1775a99eebc1ac05",role:"gridcell",class:{"xpl-table-cell":!0,[`xpl-table-cell--align-${this.align}`]:!0,"xpl-table-cell--bold":this.bold,"xpl-table-cell--underline":this.underline,"xpl-table-cell--disabled":this.disabled}},t("slot",{key:"19c3a0f67b3eccdb3e6441ba74b8e9d5bb8d0ae6"}))}get el(){return s(this)}static get watchers(){return{disabled:[{onDisabledChange:0}]}}},o=class{constructor(t){e(this,t),this.align="left"}render(){return t(l,{key:"468d80c698b82031537d12584494bb8e42cc4a83",class:{"xpl-table-footer-cell":!0,[`xpl-table-footer-cell--align-${this.align}`]:!0},role:"gridcell"},t("slot",{key:"91674140e7e618b7ff40c58ebbdae79145318de9"}))}},d=class{constructor(t){e(this,t),this.headerCheckboxChange=i(this,"headerCheckboxChange",7),this.headerSortChange=i(this,"headerSortChange",7),this.align="left",this.checked=!1,this.indeterminate=!1,this.label="",this.sortable=!1,this.type="label",this.onHeaderInnerCheckboxChange=e=>{const{detail:t}=e,l="boolean"==typeof t?t:Boolean(t);this.headerCheckboxChange.emit(l)},this.onSortActivate=e=>{if(e.preventDefault(),e.stopPropagation(),!this.sortable||"label"!==this.type)return;const t=this.getColumnIndex0(),l=this.getSortKeySlug();this.el.closest("xpl-table")||(this.sortDirection=a(this.sortDirection)),this.headerSortChange.emit({columnIndex:t,sortKey:l})}}watchColumnWidth(){this.notifyColumnWidthsChange()}watchWidth(){this.notifyColumnWidthsChange()}componentDidLoad(){this.notifyColumnWidthsChange()}notifyColumnWidthsChange(){this.el.dispatchEvent(new CustomEvent(c,{bubbles:!0,composed:!0}))}getColumnIndex0(){return Array.from(this.el.parentElement?.children??[]).indexOf(this.el)}getSortKeySlug(){const e=(this.sortKey??this.label??"").trim();return e.length>0?e.replace(/ /g,"-").toLowerCase():`column-${this.getColumnIndex0()}`}renderLabelText(){return t("span",{class:"xpl-table-header-cell__text"},this.label,t("slot",null))}renderLabelContent(){if(this.sortable){const e=h(this.sortDirection),l="asc"===this.sortDirection||"desc"===this.sortDirection;return t("button",{type:"button",class:"xpl-table-header-cell__sort",onClick:this.onSortActivate},this.renderLabelText(),t("xpl-icon",{class:{"xpl-table-header-cell__sort-icon":!0,"xpl-table-header-cell__sort-icon--active":l,"xpl-table-header-cell__sort-icon--default":!l},icon:e,size:16}))}return this.renderLabelText()}render(){const e=this.getColumnIndex0()+1,s=`xpl-table-header-cell--align-${"checkbox"!==this.type&&"icon"!==this.type||"left"!==this.align?this.align:"center"}`,i="label"===this.type&&this.sortable?"asc"===this.sortDirection?"ascending":"desc"===this.sortDirection?"descending":"none":void 0;return t(l,{role:"columnheader","aria-colindex":e,class:{"xpl-table-header-cell":!0,[s]:!0,"xpl-table-header-cell--checkbox":"checkbox"===this.type,"xpl-table-header-cell--icon":"icon"===this.type,"xpl-table-header-cell--empty":"empty"===this.type,"xpl-table-header-cell--sortable":this.sortable&&"label"===this.type},"aria-checked":"checkbox"===this.type?this.indeterminate?"mixed":this.checked?"true":"false":void 0,"aria-sort":i},"empty"===this.type?null:(()=>{switch(this.type){case"label":return this.renderLabelContent();case"checkbox":return t("xpl-checkbox",{ariaLabel:this.checkboxAriaLabel??"Select all rows",checked:this.checked,indeterminate:this.indeterminate,onCheckboxChange:this.onHeaderInnerCheckboxChange});case"icon":return this.icon?t("xpl-icon",{icon:this.icon,size:20}):null;case"empty":return null;default:return""}})())}get el(){return s(this)}static get watchers(){return{columnWidth:[{watchColumnWidth:0}],width:[{watchWidth:0}]}}};export{n as xpl_table_cell,o as xpl_table_footer_cell,d as xpl_table_header_cell}
@@ -1 +1 @@
1
- import{r as a,c as e,h as d,H as c}from"./p-CJABLO_1.js";const n=class{constructor(d){a(this,d),this.navWidth=e(this,"navWidth",7),this.width="default"}navWidthHandler(){this.navWidth.emit(this.width)}connectedCallback(){this.navWidthHandler()}componentDidUpdate(){this.navWidthHandler()}render(){return d(c,{key:"ab352ff358657b1f3b463a84e7a40e18ae23df29",class:`xpl-main-nav xpl-main-nav--${this.width}`,"aria-label":"Sidebar"},d("nav",{key:"e62b52010f76c39078ceaa5085c4e5dcd03d45ce"},d("header",{key:"05cfd30654dcb4a6082ac97490c516d0b01ae791","aria-label":"Sidebar Header"},d("slot",{key:"e48cd7e5a01ae86ac1d50a9b5e46e93a902ae50f",name:"logo"}),d("slot",{key:"77a840ec7da01b757efaea8a0ffb4d590f97dc7d",name:"brand-name"})),d("div",{key:"fa9093094b5998901402d2b8a56b1e16cce648fc",class:"xpl-main-nav__main_section"},d("slot",{key:"5a13411ad2043e58b7d168216c15626be160e2dd",name:"navigation"})),d("footer",{key:"ee8cfafdc454ef56f66facf9ee894f6980419932",class:"xpl-main-nav__footer","aria-label":"Sidebar Footer"},d("slot",{key:"da7fc8d944121f0060acd579fc3a960571b1fd26",name:"footer"}))))}};export{n as xpl_main_nav}
1
+ import{r as a,c as e,h as d,H as c}from"./p-CgJEmBQY.js";const n=class{constructor(d){a(this,d),this.navWidth=e(this,"navWidth",7),this.width="default"}navWidthHandler(){this.navWidth.emit(this.width)}connectedCallback(){this.navWidthHandler()}componentDidUpdate(){this.navWidthHandler()}render(){return d(c,{key:"ab352ff358657b1f3b463a84e7a40e18ae23df29",class:`xpl-main-nav xpl-main-nav--${this.width}`,"aria-label":"Sidebar"},d("nav",{key:"e62b52010f76c39078ceaa5085c4e5dcd03d45ce"},d("header",{key:"05cfd30654dcb4a6082ac97490c516d0b01ae791","aria-label":"Sidebar Header"},d("slot",{key:"e48cd7e5a01ae86ac1d50a9b5e46e93a902ae50f",name:"logo"}),d("slot",{key:"77a840ec7da01b757efaea8a0ffb4d590f97dc7d",name:"brand-name"})),d("div",{key:"fa9093094b5998901402d2b8a56b1e16cce648fc",class:"xpl-main-nav__main_section"},d("slot",{key:"5a13411ad2043e58b7d168216c15626be160e2dd",name:"navigation"})),d("footer",{key:"ee8cfafdc454ef56f66facf9ee894f6980419932",class:"xpl-main-nav__footer","aria-label":"Sidebar Footer"},d("slot",{key:"da7fc8d944121f0060acd579fc3a960571b1fd26",name:"footer"}))))}};export{n as xpl_main_nav}
@@ -1 +1 @@
1
- import{r as t,c as s,h as i,H as e,g as a}from"./p-CJABLO_1.js";let n=0;function h(t){const s=t.querySelector("xpl-button button");if(s){const t=s.cloneNode(!0);if(t instanceof HTMLElement){t.querySelectorAll(".xpl-button__icon, xpl-icon, xpl-badge").forEach((t=>t.remove()));const s=t.textContent?.replace(/\s+/g," ").trim();if(s)return s}}const i=t.querySelector(".xpl-tab__button");if(i){const t=Array.from(i.childNodes).filter((t=>t.nodeType===Node.TEXT_NODE)).map((t=>(t.textContent??"").trim())).join(" ").replace(/\s+/g," ").trim();if(t)return t}return t.getAttribute("target")??""}const o=class{constructor(i){t(this,i),this.tabChange=s(this,"tabChange",7),this.tabHeadings=[],this.tabPanels=[],this.tablistKeydownBound=!1,this.activeBarPosition={left:0,width:0},this.choicesTick=1,this.isMobileSelectChange=!1,this.selectedValue="",this.disabled=!1,this.fullWidth=!1,this.type="tabs",this.handleTabChange=t=>{this.applySelection(t)},this.onTablistKeydown=async t=>{if(this.disabled)return;const s=t.target?.closest?.("xpl-tab");if(!s||!this.tabHeadings.includes(s))return;const{key:i}=t;let e=!1,a=!1;this.isTablistRtl()?"ArrowLeft"===i||"ArrowDown"===i?e=!0:"ArrowRight"!==i&&"ArrowUp"!==i||(a=!0):"ArrowRight"===i||"ArrowDown"===i?e=!0:"ArrowLeft"!==i&&"ArrowUp"!==i||(a=!0);const n=e||a,h="Home"===i;if(!n&&!h&&"End"!==i)return;const o=this.getEnabledTabHeadingsSync();if(0===o.length)return;const r=o.indexOf(s);if(-1===r)return;let c;c=n?e?(r+1)%o.length:(r-1+o.length)%o.length:h?0:o.length-1;const l=o[c],d=l?.getAttribute("target");if(!d)return;const b=s.getAttribute("target");t.preventDefault(),d!==b&&(this.applySelection(d),await l.focusTrigger(),this.tabChange.emit(d))}}onDisabledChanged(){this.syncGroupDisabledOnTabs(),this.disabled||this.syncRovingTabindex()}onFullWidthChanged(){this.syncFullWidthOnTabs()}onTypeChanged(){this.syncVariantOnTabs()}onValueChanged(t){this.applySelection(t)}connectedCallback(){this.el.hasAttribute("data-tabs-instance-id")||(n+=1,this.el.setAttribute("data-tabs-instance-id",`xpl-tg-${n}`)),"undefined"!=typeof MutationObserver&&(this.observer=new MutationObserver((()=>{this.collectTabs(!0)})),this.observer.observe(this.el,{childList:!0,subtree:!0}))}disconnectedCallback(){this.observer?.disconnect(),this.headingsContainerRef&&this.tablistKeydownBound&&(this.headingsContainerRef.removeEventListener("keydown",this.onTablistKeydown),this.tablistKeydownBound=!1),void 0!==this.rafId&&(cancelAnimationFrame(this.rafId),this.rafId=void 0)}componentWillLoad(){this.selectedValue=this.getDefaultValue()}componentDidLoad(){this.collectTabs(!1),this.attachTablistKeydown()}componentDidUpdate(){this.updateActiveBarPosition(),this.syncRovingTabindex()}componentDidRender(){!this.tablistKeydownBound&&this.headingsContainerRef&&this.attachTablistKeydown()}onWindowResize(){this.updateActiveBarPosition()}syncGroupDisabledOnTabs(){this.tabHeadings.forEach((t=>{this.disabled?t.setAttribute("data-group-disabled",""):t.removeAttribute("data-group-disabled")}))}applySelection(t){this.tabHeadings.forEach((s=>{t===s.getAttribute("target")?s.setAttribute("selected",""):s.removeAttribute("selected")})),this.tabPanels.forEach((s=>{t===s.getAttribute("target")?s.setAttribute("selected",""):s.removeAttribute("selected")})),this.syncGroupDisabledOnTabs(),void 0!==this.rafId&&cancelAnimationFrame(this.rafId),this.rafId=requestAnimationFrame((()=>{this.rafId=void 0,this.selectedValue=t,this.updateActiveBarPosition(),this.syncRovingTabindex()}))}isOwnedTabOrPanel(t){return t.closest("xpl-tabs")===this.el}collectTabs(t){this.tabHeadings=Array.from(this.el.querySelectorAll("xpl-tab")).filter((t=>this.isOwnedTabOrPanel(t))),this.tabPanels=Array.from(this.el.querySelectorAll("xpl-tab-panel")).filter((t=>this.isOwnedTabOrPanel(t))),this.syncVariantOnTabs(),this.syncFullWidthOnTabs(),this.applySelection(this.getDefaultValue()),t&&(this.choicesTick+=1)}syncVariantOnTabs(){this.tabHeadings.forEach((t=>{t.variant=this.type}))}syncFullWidthOnTabs(){this.tabHeadings.forEach((t=>{t.fullWidth=this.fullWidth}))}getDefaultValue(){return this.value||this.tabHeadings?.[0]?.getAttribute("target")||""}async syncRovingTabindex(){this.disabled||await Promise.all(this.tabHeadings.map((async t=>{const s=(t.getAttribute("target")??"")===this.selectedValue;await t.setTabIndex(s?0:-1)})))}getEnabledTabHeadingsSync(){return this.tabHeadings.filter((t=>{if(this.disabled||t.hasAttribute("disabled"))return!1;const s=t.querySelector("segment"===t.variant?"xpl-button button":".xpl-tab__button");return Boolean(s&&!s.disabled)}))}attachTablistKeydown(){const t=this.headingsContainerRef;t&&!this.tablistKeydownBound&&(t.addEventListener("keydown",this.onTablistKeydown),this.tablistKeydownBound=!0)}isTablistRtl(){const t=this.headingsContainerRef;return!!t&&"rtl"===getComputedStyle(t).direction}renderChoices(){return this.tabHeadings.map((t=>{const s=t.getAttribute("target")??"",i=this.disabled||t.hasAttribute("disabled"),e=t.getAttribute("icon")||void 0;return{label:h(t),value:s,isDisabled:i,...e?{icon:e}:{}}}))}updateActiveBarPosition(){if("segment"===this.type)return;const t=this.tabHeadings.find((t=>t.getAttribute("target")===this.selectedValue));if(!this.headingsContainerRef||!t)return;const s=t.getBoundingClientRect(),i=this.headingsContainerRef.getBoundingClientRect(),e=s.left-i.left,a=s.width;this.activeBarPosition.left===e&&this.activeBarPosition.width===a||(this.activeBarPosition={left:e,width:a})}mobileSelectClassNames(){const t="xpl-tabs__mobile-select";return"segment"===this.type?`${t} xpl-tabs__mobile-select--segment`:t}render(){const t="segment"===this.type;return i(e,{key:"0bb77237fce464cc536ce4efabb29249fa14ef4a",class:{"xpl-tabs":!0,"xpl-tabs--full-width":this.fullWidth,"xpl-tabs--segment":t},"data-choices-tick":this.choicesTick},i("xpl-select",{key:"fbcc113cc9a308df73bf99f6c941612725e49ddb",classNames:this.mobileSelectClassNames(),choices:this.renderChoices(),disabled:this.disabled,selectedValues:this.selectedValue,onDropdownStateChange:t=>{t.detail&&(this.isMobileSelectChange=!0)},onChangeEvent:t=>{if(this.isMobileSelectChange){const s=t.detail.toString();this.handleTabChange(s),this.tabChange.emit(s),this.isMobileSelectChange=!1}}}),i("nav",{key:"1b93068116c5ff0ac94d5139e147daffc1157c73","aria-orientation":"horizontal",class:"xpl-tabs__headings",role:"tablist",ref:t=>{this.headingsContainerRef=t},onTabChange:t=>{t.stopPropagation(),this.isMobileSelectChange=!1,this.handleTabChange(t.detail),this.tabChange.emit(t.detail)}},!t&&i("div",{key:"38a88df2520d308e3a22b4cd70ff274af7403616",class:"xpl-tabs__active-bar",style:{transform:`translateX(${this.activeBarPosition.left}px)`,width:`${this.activeBarPosition.width}px`}}),i("slot",{key:"dc30ab2123d7c1c8b6591ac0129af44da3795977",name:"heading"})),i("div",{key:"36c1fc45216499d4af87b8fc536df3ea6af666ab",class:"xpl-tabs__panels"},i("slot",{key:"a660913c7d2fce500da666490b600b4c7fc93746",name:"panel"})))}get el(){return a(this)}static get watchers(){return{disabled:[{onDisabledChanged:0}],fullWidth:[{onFullWidthChanged:0}],type:[{onTypeChanged:0}],value:[{onValueChanged:0}]}}};export{o as xpl_tabs}
1
+ import{r as t,c as s,h as i,H as e,g as a}from"./p-CgJEmBQY.js";let n=0;function h(t){const s=t.querySelector("xpl-button button");if(s){const t=s.cloneNode(!0);if(t instanceof HTMLElement){t.querySelectorAll(".xpl-button__icon, xpl-icon, xpl-badge").forEach((t=>t.remove()));const s=t.textContent?.replace(/\s+/g," ").trim();if(s)return s}}const i=t.querySelector(".xpl-tab__button");if(i){const t=Array.from(i.childNodes).filter((t=>t.nodeType===Node.TEXT_NODE)).map((t=>(t.textContent??"").trim())).join(" ").replace(/\s+/g," ").trim();if(t)return t}return t.getAttribute("target")??""}const o=class{constructor(i){t(this,i),this.tabChange=s(this,"tabChange",7),this.tabHeadings=[],this.tabPanels=[],this.tablistKeydownBound=!1,this.activeBarPosition={left:0,width:0},this.choicesTick=1,this.isMobileSelectChange=!1,this.selectedValue="",this.disabled=!1,this.fullWidth=!1,this.type="tabs",this.handleTabChange=t=>{this.applySelection(t)},this.onTablistKeydown=async t=>{if(this.disabled)return;const s=t.target?.closest?.("xpl-tab");if(!s||!this.tabHeadings.includes(s))return;const{key:i}=t;let e=!1,a=!1;this.isTablistRtl()?"ArrowLeft"===i||"ArrowDown"===i?e=!0:"ArrowRight"!==i&&"ArrowUp"!==i||(a=!0):"ArrowRight"===i||"ArrowDown"===i?e=!0:"ArrowLeft"!==i&&"ArrowUp"!==i||(a=!0);const n=e||a,h="Home"===i;if(!n&&!h&&"End"!==i)return;const o=this.getEnabledTabHeadingsSync();if(0===o.length)return;const r=o.indexOf(s);if(-1===r)return;let c;c=n?e?(r+1)%o.length:(r-1+o.length)%o.length:h?0:o.length-1;const l=o[c],d=l?.getAttribute("target");if(!d)return;const b=s.getAttribute("target");t.preventDefault(),d!==b&&(this.applySelection(d),await l.focusTrigger(),this.tabChange.emit(d))}}onDisabledChanged(){this.syncGroupDisabledOnTabs(),this.disabled||this.syncRovingTabindex()}onFullWidthChanged(){this.syncFullWidthOnTabs()}onTypeChanged(){this.syncVariantOnTabs()}onValueChanged(t){this.applySelection(t)}connectedCallback(){this.el.hasAttribute("data-tabs-instance-id")||(n+=1,this.el.setAttribute("data-tabs-instance-id",`xpl-tg-${n}`)),"undefined"!=typeof MutationObserver&&(this.observer=new MutationObserver((()=>{this.collectTabs(!0)})),this.observer.observe(this.el,{childList:!0,subtree:!0}))}disconnectedCallback(){this.observer?.disconnect(),this.headingsContainerRef&&this.tablistKeydownBound&&(this.headingsContainerRef.removeEventListener("keydown",this.onTablistKeydown),this.tablistKeydownBound=!1),void 0!==this.rafId&&(cancelAnimationFrame(this.rafId),this.rafId=void 0)}componentWillLoad(){this.selectedValue=this.getDefaultValue()}componentDidLoad(){this.collectTabs(!1),this.attachTablistKeydown()}componentDidUpdate(){this.updateActiveBarPosition(),this.syncRovingTabindex()}componentDidRender(){!this.tablistKeydownBound&&this.headingsContainerRef&&this.attachTablistKeydown()}onWindowResize(){this.updateActiveBarPosition()}syncGroupDisabledOnTabs(){this.tabHeadings.forEach((t=>{this.disabled?t.setAttribute("data-group-disabled",""):t.removeAttribute("data-group-disabled")}))}applySelection(t){this.tabHeadings.forEach((s=>{t===s.getAttribute("target")?s.setAttribute("selected",""):s.removeAttribute("selected")})),this.tabPanels.forEach((s=>{t===s.getAttribute("target")?s.setAttribute("selected",""):s.removeAttribute("selected")})),this.syncGroupDisabledOnTabs(),void 0!==this.rafId&&cancelAnimationFrame(this.rafId),this.rafId=requestAnimationFrame((()=>{this.rafId=void 0,this.selectedValue=t,this.updateActiveBarPosition(),this.syncRovingTabindex()}))}isOwnedTabOrPanel(t){return t.closest("xpl-tabs")===this.el}collectTabs(t){this.tabHeadings=Array.from(this.el.querySelectorAll("xpl-tab")).filter((t=>this.isOwnedTabOrPanel(t))),this.tabPanels=Array.from(this.el.querySelectorAll("xpl-tab-panel")).filter((t=>this.isOwnedTabOrPanel(t))),this.syncVariantOnTabs(),this.syncFullWidthOnTabs(),this.applySelection(this.getDefaultValue()),t&&(this.choicesTick+=1)}syncVariantOnTabs(){this.tabHeadings.forEach((t=>{t.variant=this.type}))}syncFullWidthOnTabs(){this.tabHeadings.forEach((t=>{t.fullWidth=this.fullWidth}))}getDefaultValue(){return this.value||this.tabHeadings?.[0]?.getAttribute("target")||""}async syncRovingTabindex(){this.disabled||await Promise.all(this.tabHeadings.map((async t=>{const s=(t.getAttribute("target")??"")===this.selectedValue;await t.setTabIndex(s?0:-1)})))}getEnabledTabHeadingsSync(){return this.tabHeadings.filter((t=>{if(this.disabled||t.hasAttribute("disabled"))return!1;const s=t.querySelector("segment"===t.variant?"xpl-button button":".xpl-tab__button");return Boolean(s&&!s.disabled)}))}attachTablistKeydown(){const t=this.headingsContainerRef;t&&!this.tablistKeydownBound&&(t.addEventListener("keydown",this.onTablistKeydown),this.tablistKeydownBound=!0)}isTablistRtl(){const t=this.headingsContainerRef;return!!t&&"rtl"===getComputedStyle(t).direction}renderChoices(){return this.tabHeadings.map((t=>{const s=t.getAttribute("target")??"",i=this.disabled||t.hasAttribute("disabled"),e=t.getAttribute("icon")||void 0;return{label:h(t),value:s,isDisabled:i,...e?{icon:e}:{}}}))}updateActiveBarPosition(){if("segment"===this.type)return;const t=this.tabHeadings.find((t=>t.getAttribute("target")===this.selectedValue));if(!this.headingsContainerRef||!t)return;const s=t.getBoundingClientRect(),i=this.headingsContainerRef.getBoundingClientRect(),e=s.left-i.left,a=s.width;this.activeBarPosition.left===e&&this.activeBarPosition.width===a||(this.activeBarPosition={left:e,width:a})}mobileSelectClassNames(){const t="xpl-tabs__mobile-select";return"segment"===this.type?`${t} xpl-tabs__mobile-select--segment`:t}render(){const t="segment"===this.type;return i(e,{key:"0bb77237fce464cc536ce4efabb29249fa14ef4a",class:{"xpl-tabs":!0,"xpl-tabs--full-width":this.fullWidth,"xpl-tabs--segment":t},"data-choices-tick":this.choicesTick},i("xpl-select",{key:"fbcc113cc9a308df73bf99f6c941612725e49ddb",classNames:this.mobileSelectClassNames(),choices:this.renderChoices(),disabled:this.disabled,selectedValues:this.selectedValue,onDropdownStateChange:t=>{t.detail&&(this.isMobileSelectChange=!0)},onChangeEvent:t=>{if(this.isMobileSelectChange){const s=t.detail.toString();this.handleTabChange(s),this.tabChange.emit(s),this.isMobileSelectChange=!1}}}),i("nav",{key:"1b93068116c5ff0ac94d5139e147daffc1157c73","aria-orientation":"horizontal",class:"xpl-tabs__headings",role:"tablist",ref:t=>{this.headingsContainerRef=t},onTabChange:t=>{t.stopPropagation(),this.isMobileSelectChange=!1,this.handleTabChange(t.detail),this.tabChange.emit(t.detail)}},!t&&i("div",{key:"38a88df2520d308e3a22b4cd70ff274af7403616",class:"xpl-tabs__active-bar",style:{transform:`translateX(${this.activeBarPosition.left}px)`,width:`${this.activeBarPosition.width}px`}}),i("slot",{key:"dc30ab2123d7c1c8b6591ac0129af44da3795977",name:"heading"})),i("div",{key:"36c1fc45216499d4af87b8fc536df3ea6af666ab",class:"xpl-tabs__panels"},i("slot",{key:"a660913c7d2fce500da666490b600b4c7fc93746",name:"panel"})))}get el(){return a(this)}static get watchers(){return{disabled:[{onDisabledChanged:0}],fullWidth:[{onFullWidthChanged:0}],type:[{onTypeChanged:0}],value:[{onValueChanged:0}]}}};export{o as xpl_tabs}
@@ -1 +1 @@
1
- import{r as e,h as a,H as c}from"./p-CJABLO_1.js";const s=class{constructor(a){e(this,a),this.accent="none",this.padding="default"}render(){const e="none"!==this.accent;return a(c,{key:"61852953ba87a556efaeff011546aecdd27bb6b1",class:{"xpl-panel":!0,[`xpl-panel--accent-${this.accent}`]:e,[`xpl-panel--padding-${this.padding}`]:!0}},e&&a("div",{key:"b4317b146c7759041d90b1a07ddd18f8dd3f2fd9","aria-hidden":"true",class:"xpl-panel__accent"}),a("div",{key:"b6d5634c93f921a002a3928884f54d3f8cce76cf",class:"xpl-panel__content"},a("slot",{key:"903c5e6f307ab7045b992f6b3bf3ec2c5b563455"})))}};export{s as xpl_panel}
1
+ import{r as e,h as a,H as c}from"./p-CgJEmBQY.js";const s=class{constructor(a){e(this,a),this.accent="none",this.padding="default"}render(){const e="none"!==this.accent;return a(c,{key:"61852953ba87a556efaeff011546aecdd27bb6b1",class:{"xpl-panel":!0,[`xpl-panel--accent-${this.accent}`]:e,[`xpl-panel--padding-${this.padding}`]:!0}},e&&a("div",{key:"b4317b146c7759041d90b1a07ddd18f8dd3f2fd9","aria-hidden":"true",class:"xpl-panel__accent"}),a("div",{key:"b6d5634c93f921a002a3928884f54d3f8cce76cf",class:"xpl-panel__content"},a("slot",{key:"903c5e6f307ab7045b992f6b3bf3ec2c5b563455"})))}};export{s as xpl_panel}
@@ -1 +1 @@
1
- import{r as s,h as t,H as e}from"./p-CJABLO_1.js";const i=class{constructor(t){s(this,t),this.shape="rectangle",this.size="custom"}render(){return t(e,{key:"faa4173a2910d1dc3943fca5e7efbf5d1805aa9b",class:{"xpl-skeleton":!0,[`xpl-skeleton--shape-${this.shape}`]:!0,[`xpl-skeleton--size-${this.size}`]:!0,[this.classNames??""]:!!this.classNames,"xpl-skeleton--full-width":!!this.fullWidth},style:{width:this.width||void 0,height:this.height||void 0,margin:this.margin||void 0}})}};export{i as xpl_skeleton}
1
+ import{r as s,h as t,H as e}from"./p-CgJEmBQY.js";const i=class{constructor(t){s(this,t),this.shape="rectangle",this.size="custom"}render(){return t(e,{key:"faa4173a2910d1dc3943fca5e7efbf5d1805aa9b",class:{"xpl-skeleton":!0,[`xpl-skeleton--shape-${this.shape}`]:!0,[`xpl-skeleton--size-${this.size}`]:!0,[this.classNames??""]:!!this.classNames,"xpl-skeleton--full-width":!!this.fullWidth},style:{width:this.width||void 0,height:this.height||void 0,margin:this.margin||void 0}})}};export{i as xpl_skeleton}
@@ -1 +1 @@
1
- import{r as e,c as t,h as n,H as i,g as a}from"./p-CJABLO_1.js";import{v as s}from"./p-CK3_k8jD.js";const o=[{countryCode:"US",dialCode:"+1",name:"United States"},{countryCode:"CA",dialCode:"+1",name:"Canada"},{countryCode:"GB",dialCode:"+44",name:"United Kingdom"},{countryCode:"AU",dialCode:"+61",name:"Australia"},{countryCode:"DE",dialCode:"+49",name:"Germany"},{countryCode:"FR",dialCode:"+33",name:"France"},{countryCode:"ES",dialCode:"+34",name:"Spain"},{countryCode:"IT",dialCode:"+39",name:"Italy"},{countryCode:"NL",dialCode:"+31",name:"Netherlands"},{countryCode:"BE",dialCode:"+32",name:"Belgium"},{countryCode:"AT",dialCode:"+43",name:"Austria"},{countryCode:"CH",dialCode:"+41",name:"Switzerland"},{countryCode:"PL",dialCode:"+48",name:"Poland"},{countryCode:"IE",dialCode:"+353",name:"Ireland"},{countryCode:"PT",dialCode:"+351",name:"Portugal"},{countryCode:"SE",dialCode:"+46",name:"Sweden"},{countryCode:"NO",dialCode:"+47",name:"Norway"},{countryCode:"DK",dialCode:"+45",name:"Denmark"},{countryCode:"FI",dialCode:"+358",name:"Finland"},{countryCode:"NZ",dialCode:"+64",name:"New Zealand"},{countryCode:"JP",dialCode:"+81",name:"Japan"},{countryCode:"CN",dialCode:"+86",name:"China"},{countryCode:"IN",dialCode:"+91",name:"India"},{countryCode:"BR",dialCode:"+55",name:"Brazil"},{countryCode:"MX",dialCode:"+52",name:"Mexico"},{countryCode:"ZA",dialCode:"+27",name:"South Africa"},{countryCode:"SG",dialCode:"+65",name:"Singapore"},{countryCode:"HK",dialCode:"+852",name:"Hong Kong"},{countryCode:"KR",dialCode:"+82",name:"South Korea"}];function r(e){return o.find((t=>t.countryCode===e))}function c(e){return(e||"").replace(/\D/g,"")}function d(e){switch(e){case"US":case"CA":case"MX":case"JP":case"IN":case"KR":return 10;case"GB":case"DE":case"AT":case"CH":case"BR":case"CN":return 11;case"AU":case"FR":return 9;default:return 15}}function h(e,t){if(!e)return"";const n=e.replace(/\D/g,"");switch(t){case"US":case"CA":return function(e){const t=Math.min(e.length,10);return t<=3?e.slice(0,t):t<=6?`${e.slice(0,3)} ${e.slice(3,t)}`:`${e.slice(0,3)} ${e.slice(3,6)} ${e.slice(6,t)}`}(n);case"GB":return function(e){const t=Math.min(e.length,11);return t<=4?e.slice(0,t):t<=7?`${e.slice(0,4)} ${e.slice(4,t)}`:`${e.slice(0,4)} ${e.slice(4,7)} ${e.slice(7,t)}`}(n);case"AU":return function(e){const t=Math.min(e.length,9);return t<=1?e.slice(0,t):t<=4?`${e.slice(0,1)} ${e.slice(1,t)}`:t<=7?`${e.slice(0,1)} ${e.slice(1,4)} ${e.slice(4,t)}`:`${e.slice(0,1)} ${e.slice(1,4)} ${e.slice(4,7)} ${e.slice(7,t)}`}(n);case"DE":case"AT":case"CH":return function(e){const t=Math.min(e.length,11);return t<=3?e.slice(0,t):`${e.slice(0,3)} ${e.slice(3,t)}`}(n);case"FR":return function(e){const t=Math.min(e.length,9),n=[];let i=0;for(t>0&&(n.push(e.slice(0,1)),i=1);i<t&&i+2<=t;)n.push(e.slice(i,i+2)),i+=2;return i<t&&n.push(e.slice(i)),n.join(" ")}(n);case"BR":return function(e){const t=Math.min(e.length,11);return t<=2?t?`(${e}`:"":t<=6||7===t?`(${e.slice(0,2)}) ${e.slice(2,t)}`:`(${e.slice(0,2)}) ${e.slice(2,7)}-${e.slice(7,t)}`}(n);case"MX":return function(e){const t=Math.min(e.length,10);return t<=3?e.slice(0,t):t<=6?`${e.slice(0,3)} ${e.slice(3,t)}`:`${e.slice(0,3)} ${e.slice(3,6)} ${e.slice(6,t)}`}(n);case"JP":return function(e){const t=Math.min(e.length,10);return t<=3?e.slice(0,t):t<=7?`${e.slice(0,3)}-${e.slice(3,t)}`:`${e.slice(0,3)}-${e.slice(3,7)}-${e.slice(7,t)}`}(n);case"CN":return function(e){const t=Math.min(e.length,11);return t<=3?e.slice(0,t):t<=7?`${e.slice(0,3)} ${e.slice(3,t)}`:`${e.slice(0,3)} ${e.slice(3,7)} ${e.slice(7,t)}`}(n);case"IN":return function(e){const t=Math.min(e.length,10);return t<=5?e.slice(0,t):`${e.slice(0,5)} ${e.slice(5,t)}`}(n);case"KR":return function(e){const t=Math.min(e.length,10);return t<=3?e.slice(0,t):t<=7?`${e.slice(0,3)} ${e.slice(3,t)}`:`${e.slice(0,3)} ${e.slice(3,7)} ${e.slice(7,t)}`}(n);default:return function(e){const t=e.length;if(t<=3)return e;const n=[];let i=0;for(;i<t;){const a=t-i>=4?4:3;n.push(e.slice(i,i+a)),i+=a}return n.join(" ")}(n)}}function u(e){return e.toLowerCase().replace(/ /g,"-")}const l=class{constructor(n){e(this,n),this.hasErrorStateChanged=t(this,"hasErrorStateChanged",7),this.valueChange=t(this,"valueChange",7),this.lastCursorRef=0,this.lastFormattedRef="",this.dropdownOpen=!1,this.hasErrorState=null,this.nationalNumber="",this.searchQuery="",this.triggerId=`xpl-input-phone-trigger-${s()}`,this.defaultCountry="US",this.isInternational=!0,this.handleTriggerClick=()=>{this.isEditable&&(this.dropdownOpen=!this.dropdownOpen)},this.handleNumberInput=e=>{const t=e.target,n=t.value||"";let i;if(this.lastCursorRef=t.selectionStart??0,this.lastFormattedRef=n,this.isInternational&&n.startsWith("+")){const e=c(n),t=this.effectiveDialCode.slice(1).replace(/\D/g,"");i=t&&e.startsWith(t)?e.slice(t.length):e}else i=c(n);const a=d(this.effectiveCountryCode);i.length>a&&(i=i.slice(0,a)),this.nationalNumber=i,this.emitValue(),t.value=this.displayValue},this.handleClear=()=>{this.nationalNumber="",this.emitValue(),this.inputEl?.focus()},this.handleDropdownUpdate=(e,{component:t})=>{const n=t??this.dropdownRef;if(!n)return;const{options:i}=n;if(i?.length){const e=i.reduce(((e,t)=>[...e,...t.groupName?t.options??[]:[t]]),[]).find((e=>e.isSelected));if(e?.value){const t=r(e.value);t&&(this.selectedCountry=t,this.emitValue(),this.inputEl?.focus())}}}}onDropdownOpenChange(e){e&&(this.searchQuery="")}onHasErrorStateChanged(e){this.hasErrorStateChanged.emit(e)}onValueChange(e){if(null==e||""===e){const e=r(this.defaultCountry??"US")||o[0];return this.selectedCountry=e,void(this.nationalNumber="")}const t=function(e){if(!e||!e.startsWith("+"))return null;const t=e.slice(1).replace(/\D/g,"");if(!t.length)return null;const n=[...o].sort(((e,t)=>t.dialCode.replace(/\D/g,"").length-e.dialCode.replace(/\D/g,"").length)).find((e=>{const n=e.dialCode.slice(1).replace(/\D/g,"");return t.startsWith(n)}));if(!n)return null;const i=n.dialCode.slice(1).replace(/\D/g,""),a=t.slice(i.length);return{dialCode:n.dialCode,nationalNumber:a}}(e);if(t)if(this.selectedCountry?.dialCode===t.dialCode)this.nationalNumber=t.nationalNumber;else{const e=r(this.defaultCountry??"US"),i=(e?.dialCode===t.dialCode?e:void 0)??(n=t.dialCode,o.find((e=>e.dialCode===n)));i&&(this.selectedCountry=i,this.nationalNumber=t.nationalNumber)}else this.selectedCountry||(this.selectedCountry=r(this.defaultCountry??"US")||o[0]);var n}componentWillLoad(){this.value?this.onValueChange(this.value):this.selectedCountry=r(this.defaultCountry??"US")||o[0]}componentDidUpdate(){if(this.inputEl&&this.lastFormattedRef&&"function"==typeof this.inputEl.setSelectionRange){const e=function(e,t,n){if(n>=e.length)return t.length;const i=c(e.slice(0,n)).length;let a=0,s=0;for(let e=0;e<t.length;e+=1){if(/\d/.test(t[e])&&(s+=1,s>=i)){a=e+(s===i?1:0);break}a=e+1}return Math.min(a,t.length)}(this.lastFormattedRef,this.displayValue,this.lastCursorRef);this.inputEl.setSelectionRange(e,e),this.lastFormattedRef=""}else this.inputEl&&this.lastFormattedRef&&(this.lastFormattedRef="")}get effectiveCountryCode(){return this.selectedCountry?.countryCode??this.defaultCountry??"US"}get effectiveDialCode(){return this.selectedCountry?.dialCode??"+1"}get isEditable(){return!this.disabled&&!this.readonly}get orderedCountries(){const e=this.preferredCountries||[],t=o.filter((t=>!e.includes(t.countryCode)));return[...e.map((e=>r(e))).filter((e=>void 0!==e)),...t]}get filteredCountries(){const e=this.searchQuery.trim().toLowerCase();return e?this.orderedCountries.filter((t=>t.name.toLowerCase().includes(e)||t.dialCode.includes(e)||t.countryCode.toLowerCase().includes(e))):this.orderedCountries}get displayValue(){return this.nationalNumber?h(this.nationalNumber,this.effectiveCountryCode):""}get effectivePlaceholder(){if(this.placeholder)return this.placeholder;const e=this.selectedCountry;return e?function(e){switch(e){case"US":case"CA":case"MX":default:return"000 000 0000";case"GB":return"0000 000 0000";case"AU":return"0 000 000 000";case"DE":case"AT":case"CH":return"000 0000000";case"FR":return"0 00 00 00 00";case"BR":return"00 00000 0000";case"JP":case"CN":case"KR":return"000 0000 0000";case"IN":return"00000 00000"}}(e.countryCode):""}get dropdownOptions(){return this.filteredCountries.map((e=>({icon:u(e.name),label:`${e.name} (${e.dialCode})`,value:e.countryCode,isSelected:this.selectedCountry?.countryCode===e.countryCode})))}get maxInputLength(){const e=d(this.effectiveCountryCode);return h("9".repeat(e),this.effectiveCountryCode).length}emitValue(){const e=this.nationalNumber?function(e,t){const n=(e.slice(1)+t).replace(/\D/g,"");return n.length?`+${n}`:""}(this.effectiveDialCode,this.nationalNumber):"";this.value=e||void 0,this.valueChange.emit(e||""),this.validate()}validate(){this.hasErrorState=!this.required||this.nationalNumber.trim()?null:"required"}render(){return n(i,{key:"c78f7ab5d5c6f6982356d7610fe32855d7f214c5",class:{"xpl-input-phone":!0,"xpl-input-phone--error":!!this.hasErrorState||!!this.error,"xpl-input-phone--open":this.dropdownOpen,"xpl-input-phone--domestic":!this.isInternational}},n("div",{key:"3b30f8755836376728336f769afeb714b9a3dfa9",class:"xpl-input-wrapper"},this.isInternational&&n("button",{key:"c83ff2255a465d7d5d233ce02a816845858594be",type:"button",id:this.triggerId,class:"xpl-input-phone__trigger",disabled:this.disabled,"aria-haspopup":"listbox","aria-expanded":this.dropdownOpen?"true":"false","aria-label":"Select country",onClick:this.handleTriggerClick},this.selectedCountry?.name&&n("xpl-icon",{key:"f0a62a5052b940f4a2212ed77929696e62b4825f",class:"xpl-input-phone__flag",icon:u(this.selectedCountry.name),size:24,"aria-hidden":"true"}),n("xpl-icon",{key:"68782b949fd1cf41a8b0883ad6caba18d9aa1ac5",class:"xpl-input-phone__trigger-icon",icon:"chevron-down",size:20,"aria-hidden":"true"})),n("div",{key:"6aa5f75f34b413bd8939d46c55b7cc42128db247",class:"xpl-input-phone__input-wrap"},this.isInternational&&n("span",{key:"81dc5727f8dca528f34994736c1a8a2223e8fe63",class:"xpl-input-phone__dial-code"},this.effectiveDialCode),n("input",{key:"d0faecadd4216bf6a7b79fc9623052e194900c15",ref:e=>{this.inputEl=e??void 0},type:"tel",id:this.inputId,class:"xpl-input-phone__input",name:this.name,disabled:this.disabled,readonly:this.readonly,required:this.required,"aria-invalid":this.hasErrorState||this.error?"true":"false",placeholder:this.effectivePlaceholder,autocomplete:this.isInternational?"tel-national":"tel",inputmode:"numeric",maxlength:this.maxInputLength,value:this.displayValue,onInput:this.handleNumberInput}),this.nationalNumber&&this.isEditable&&n("button",{key:"12a2e4ce8adb80ca4d6fca1c706c54db01d22101",type:"button",class:"xpl-input-phone__clear","aria-label":"Clear phone number",onClick:this.handleClear},n("xpl-icon",{key:"f1ae5e69258654e8ba5bf511755020e0d7d91088",icon:"x-circle",size:16})))),this.isInternational&&this.isEditable&&n("xpl-dropdown",{key:"d8a75cf0b95d9affae6e03292c011a73dcff98b4",ref:e=>{this.dropdownRef=e??void 0},isOpen:this.dropdownOpen,triggerId:this.triggerId,anchorToTrigger:!0,closeOnSelect:!0,mode:"single",options:this.dropdownOptions,update:this.handleDropdownUpdate,onIsOpenChange:e=>{this.dropdownOpen=e.detail},"aria-label":"Country"},n("div",{key:"b46a4a9985604720099c3212714804aee5a1f58b",slot:"header",class:"xpl-input-phone__search-wrap"},n("xpl-input",{key:"55bdc0f6ff4b1a1a2d17b5ba10849bcab472d7d8",class:"xpl-input-phone__search",type:"text",label:"",placeholder:"Search",value:this.searchQuery,autocomplete:"off",onInputEvent:e=>{this.searchQuery=e.detail??""}},n("xpl-icon",{key:"af0fd388d39e6d9bcac5a032c7c0cf5f192cc4d3",slot:"pre",class:"xpl-input-phone__search-icon",icon:"magnifier",size:20})))))}get el(){return a(this)}static get watchers(){return{dropdownOpen:[{onDropdownOpenChange:0}],hasErrorState:[{onHasErrorStateChanged:0}],value:[{onValueChange:0}]}}};export{l as xpl_input_phone}
1
+ import{r as e,c as t,h as n,H as i,g as a}from"./p-CgJEmBQY.js";import{v as s}from"./p-CK3_k8jD.js";const o=[{countryCode:"US",dialCode:"+1",name:"United States"},{countryCode:"CA",dialCode:"+1",name:"Canada"},{countryCode:"GB",dialCode:"+44",name:"United Kingdom"},{countryCode:"AU",dialCode:"+61",name:"Australia"},{countryCode:"DE",dialCode:"+49",name:"Germany"},{countryCode:"FR",dialCode:"+33",name:"France"},{countryCode:"ES",dialCode:"+34",name:"Spain"},{countryCode:"IT",dialCode:"+39",name:"Italy"},{countryCode:"NL",dialCode:"+31",name:"Netherlands"},{countryCode:"BE",dialCode:"+32",name:"Belgium"},{countryCode:"AT",dialCode:"+43",name:"Austria"},{countryCode:"CH",dialCode:"+41",name:"Switzerland"},{countryCode:"PL",dialCode:"+48",name:"Poland"},{countryCode:"IE",dialCode:"+353",name:"Ireland"},{countryCode:"PT",dialCode:"+351",name:"Portugal"},{countryCode:"SE",dialCode:"+46",name:"Sweden"},{countryCode:"NO",dialCode:"+47",name:"Norway"},{countryCode:"DK",dialCode:"+45",name:"Denmark"},{countryCode:"FI",dialCode:"+358",name:"Finland"},{countryCode:"NZ",dialCode:"+64",name:"New Zealand"},{countryCode:"JP",dialCode:"+81",name:"Japan"},{countryCode:"CN",dialCode:"+86",name:"China"},{countryCode:"IN",dialCode:"+91",name:"India"},{countryCode:"BR",dialCode:"+55",name:"Brazil"},{countryCode:"MX",dialCode:"+52",name:"Mexico"},{countryCode:"ZA",dialCode:"+27",name:"South Africa"},{countryCode:"SG",dialCode:"+65",name:"Singapore"},{countryCode:"HK",dialCode:"+852",name:"Hong Kong"},{countryCode:"KR",dialCode:"+82",name:"South Korea"}];function r(e){return o.find((t=>t.countryCode===e))}function c(e){return(e||"").replace(/\D/g,"")}function d(e){switch(e){case"US":case"CA":case"MX":case"JP":case"IN":case"KR":return 10;case"GB":case"DE":case"AT":case"CH":case"BR":case"CN":return 11;case"AU":case"FR":return 9;default:return 15}}function h(e,t){if(!e)return"";const n=e.replace(/\D/g,"");switch(t){case"US":case"CA":return function(e){const t=Math.min(e.length,10);return t<=3?e.slice(0,t):t<=6?`${e.slice(0,3)} ${e.slice(3,t)}`:`${e.slice(0,3)} ${e.slice(3,6)} ${e.slice(6,t)}`}(n);case"GB":return function(e){const t=Math.min(e.length,11);return t<=4?e.slice(0,t):t<=7?`${e.slice(0,4)} ${e.slice(4,t)}`:`${e.slice(0,4)} ${e.slice(4,7)} ${e.slice(7,t)}`}(n);case"AU":return function(e){const t=Math.min(e.length,9);return t<=1?e.slice(0,t):t<=4?`${e.slice(0,1)} ${e.slice(1,t)}`:t<=7?`${e.slice(0,1)} ${e.slice(1,4)} ${e.slice(4,t)}`:`${e.slice(0,1)} ${e.slice(1,4)} ${e.slice(4,7)} ${e.slice(7,t)}`}(n);case"DE":case"AT":case"CH":return function(e){const t=Math.min(e.length,11);return t<=3?e.slice(0,t):`${e.slice(0,3)} ${e.slice(3,t)}`}(n);case"FR":return function(e){const t=Math.min(e.length,9),n=[];let i=0;for(t>0&&(n.push(e.slice(0,1)),i=1);i<t&&i+2<=t;)n.push(e.slice(i,i+2)),i+=2;return i<t&&n.push(e.slice(i)),n.join(" ")}(n);case"BR":return function(e){const t=Math.min(e.length,11);return t<=2?t?`(${e}`:"":t<=6||7===t?`(${e.slice(0,2)}) ${e.slice(2,t)}`:`(${e.slice(0,2)}) ${e.slice(2,7)}-${e.slice(7,t)}`}(n);case"MX":return function(e){const t=Math.min(e.length,10);return t<=3?e.slice(0,t):t<=6?`${e.slice(0,3)} ${e.slice(3,t)}`:`${e.slice(0,3)} ${e.slice(3,6)} ${e.slice(6,t)}`}(n);case"JP":return function(e){const t=Math.min(e.length,10);return t<=3?e.slice(0,t):t<=7?`${e.slice(0,3)}-${e.slice(3,t)}`:`${e.slice(0,3)}-${e.slice(3,7)}-${e.slice(7,t)}`}(n);case"CN":return function(e){const t=Math.min(e.length,11);return t<=3?e.slice(0,t):t<=7?`${e.slice(0,3)} ${e.slice(3,t)}`:`${e.slice(0,3)} ${e.slice(3,7)} ${e.slice(7,t)}`}(n);case"IN":return function(e){const t=Math.min(e.length,10);return t<=5?e.slice(0,t):`${e.slice(0,5)} ${e.slice(5,t)}`}(n);case"KR":return function(e){const t=Math.min(e.length,10);return t<=3?e.slice(0,t):t<=7?`${e.slice(0,3)} ${e.slice(3,t)}`:`${e.slice(0,3)} ${e.slice(3,7)} ${e.slice(7,t)}`}(n);default:return function(e){const t=e.length;if(t<=3)return e;const n=[];let i=0;for(;i<t;){const a=t-i>=4?4:3;n.push(e.slice(i,i+a)),i+=a}return n.join(" ")}(n)}}function u(e){return e.toLowerCase().replace(/ /g,"-")}const l=class{constructor(n){e(this,n),this.hasErrorStateChanged=t(this,"hasErrorStateChanged",7),this.valueChange=t(this,"valueChange",7),this.lastCursorRef=0,this.lastFormattedRef="",this.dropdownOpen=!1,this.hasErrorState=null,this.nationalNumber="",this.searchQuery="",this.triggerId=`xpl-input-phone-trigger-${s()}`,this.defaultCountry="US",this.isInternational=!0,this.handleTriggerClick=()=>{this.isEditable&&(this.dropdownOpen=!this.dropdownOpen)},this.handleNumberInput=e=>{const t=e.target,n=t.value||"";let i;if(this.lastCursorRef=t.selectionStart??0,this.lastFormattedRef=n,this.isInternational&&n.startsWith("+")){const e=c(n),t=this.effectiveDialCode.slice(1).replace(/\D/g,"");i=t&&e.startsWith(t)?e.slice(t.length):e}else i=c(n);const a=d(this.effectiveCountryCode);i.length>a&&(i=i.slice(0,a)),this.nationalNumber=i,this.emitValue(),t.value=this.displayValue},this.handleClear=()=>{this.nationalNumber="",this.emitValue(),this.inputEl?.focus()},this.handleDropdownUpdate=(e,{component:t})=>{const n=t??this.dropdownRef;if(!n)return;const{options:i}=n;if(i?.length){const e=i.reduce(((e,t)=>[...e,...t.groupName?t.options??[]:[t]]),[]).find((e=>e.isSelected));if(e?.value){const t=r(e.value);t&&(this.selectedCountry=t,this.emitValue(),this.inputEl?.focus())}}}}onDropdownOpenChange(e){e&&(this.searchQuery="")}onHasErrorStateChanged(e){this.hasErrorStateChanged.emit(e)}onValueChange(e){if(null==e||""===e){const e=r(this.defaultCountry??"US")||o[0];return this.selectedCountry=e,void(this.nationalNumber="")}const t=function(e){if(!e||!e.startsWith("+"))return null;const t=e.slice(1).replace(/\D/g,"");if(!t.length)return null;const n=[...o].sort(((e,t)=>t.dialCode.replace(/\D/g,"").length-e.dialCode.replace(/\D/g,"").length)).find((e=>{const n=e.dialCode.slice(1).replace(/\D/g,"");return t.startsWith(n)}));if(!n)return null;const i=n.dialCode.slice(1).replace(/\D/g,""),a=t.slice(i.length);return{dialCode:n.dialCode,nationalNumber:a}}(e);if(t)if(this.selectedCountry?.dialCode===t.dialCode)this.nationalNumber=t.nationalNumber;else{const e=r(this.defaultCountry??"US"),i=(e?.dialCode===t.dialCode?e:void 0)??(n=t.dialCode,o.find((e=>e.dialCode===n)));i&&(this.selectedCountry=i,this.nationalNumber=t.nationalNumber)}else this.selectedCountry||(this.selectedCountry=r(this.defaultCountry??"US")||o[0]);var n}componentWillLoad(){this.value?this.onValueChange(this.value):this.selectedCountry=r(this.defaultCountry??"US")||o[0]}componentDidUpdate(){if(this.inputEl&&this.lastFormattedRef&&"function"==typeof this.inputEl.setSelectionRange){const e=function(e,t,n){if(n>=e.length)return t.length;const i=c(e.slice(0,n)).length;let a=0,s=0;for(let e=0;e<t.length;e+=1){if(/\d/.test(t[e])&&(s+=1,s>=i)){a=e+(s===i?1:0);break}a=e+1}return Math.min(a,t.length)}(this.lastFormattedRef,this.displayValue,this.lastCursorRef);this.inputEl.setSelectionRange(e,e),this.lastFormattedRef=""}else this.inputEl&&this.lastFormattedRef&&(this.lastFormattedRef="")}get effectiveCountryCode(){return this.selectedCountry?.countryCode??this.defaultCountry??"US"}get effectiveDialCode(){return this.selectedCountry?.dialCode??"+1"}get isEditable(){return!this.disabled&&!this.readonly}get orderedCountries(){const e=this.preferredCountries||[],t=o.filter((t=>!e.includes(t.countryCode)));return[...e.map((e=>r(e))).filter((e=>void 0!==e)),...t]}get filteredCountries(){const e=this.searchQuery.trim().toLowerCase();return e?this.orderedCountries.filter((t=>t.name.toLowerCase().includes(e)||t.dialCode.includes(e)||t.countryCode.toLowerCase().includes(e))):this.orderedCountries}get displayValue(){return this.nationalNumber?h(this.nationalNumber,this.effectiveCountryCode):""}get effectivePlaceholder(){if(this.placeholder)return this.placeholder;const e=this.selectedCountry;return e?function(e){switch(e){case"US":case"CA":case"MX":default:return"000 000 0000";case"GB":return"0000 000 0000";case"AU":return"0 000 000 000";case"DE":case"AT":case"CH":return"000 0000000";case"FR":return"0 00 00 00 00";case"BR":return"00 00000 0000";case"JP":case"CN":case"KR":return"000 0000 0000";case"IN":return"00000 00000"}}(e.countryCode):""}get dropdownOptions(){return this.filteredCountries.map((e=>({icon:u(e.name),label:`${e.name} (${e.dialCode})`,value:e.countryCode,isSelected:this.selectedCountry?.countryCode===e.countryCode})))}get maxInputLength(){const e=d(this.effectiveCountryCode);return h("9".repeat(e),this.effectiveCountryCode).length}emitValue(){const e=this.nationalNumber?function(e,t){const n=(e.slice(1)+t).replace(/\D/g,"");return n.length?`+${n}`:""}(this.effectiveDialCode,this.nationalNumber):"";this.value=e||void 0,this.valueChange.emit(e||""),this.validate()}validate(){this.hasErrorState=!this.required||this.nationalNumber.trim()?null:"required"}render(){return n(i,{key:"c78f7ab5d5c6f6982356d7610fe32855d7f214c5",class:{"xpl-input-phone":!0,"xpl-input-phone--error":!!this.hasErrorState||!!this.error,"xpl-input-phone--open":this.dropdownOpen,"xpl-input-phone--domestic":!this.isInternational}},n("div",{key:"3b30f8755836376728336f769afeb714b9a3dfa9",class:"xpl-input-wrapper"},this.isInternational&&n("button",{key:"c83ff2255a465d7d5d233ce02a816845858594be",type:"button",id:this.triggerId,class:"xpl-input-phone__trigger",disabled:this.disabled,"aria-haspopup":"listbox","aria-expanded":this.dropdownOpen?"true":"false","aria-label":"Select country",onClick:this.handleTriggerClick},this.selectedCountry?.name&&n("xpl-icon",{key:"f0a62a5052b940f4a2212ed77929696e62b4825f",class:"xpl-input-phone__flag",icon:u(this.selectedCountry.name),size:24,"aria-hidden":"true"}),n("xpl-icon",{key:"68782b949fd1cf41a8b0883ad6caba18d9aa1ac5",class:"xpl-input-phone__trigger-icon",icon:"chevron-down",size:20,"aria-hidden":"true"})),n("div",{key:"6aa5f75f34b413bd8939d46c55b7cc42128db247",class:"xpl-input-phone__input-wrap"},this.isInternational&&n("span",{key:"81dc5727f8dca528f34994736c1a8a2223e8fe63",class:"xpl-input-phone__dial-code"},this.effectiveDialCode),n("input",{key:"d0faecadd4216bf6a7b79fc9623052e194900c15",ref:e=>{this.inputEl=e??void 0},type:"tel",id:this.inputId,class:"xpl-input-phone__input",name:this.name,disabled:this.disabled,readonly:this.readonly,required:this.required,"aria-invalid":this.hasErrorState||this.error?"true":"false",placeholder:this.effectivePlaceholder,autocomplete:this.isInternational?"tel-national":"tel",inputmode:"numeric",maxlength:this.maxInputLength,value:this.displayValue,onInput:this.handleNumberInput}),this.nationalNumber&&this.isEditable&&n("button",{key:"12a2e4ce8adb80ca4d6fca1c706c54db01d22101",type:"button",class:"xpl-input-phone__clear","aria-label":"Clear phone number",onClick:this.handleClear},n("xpl-icon",{key:"f1ae5e69258654e8ba5bf511755020e0d7d91088",icon:"x-circle",size:16})))),this.isInternational&&this.isEditable&&n("xpl-dropdown",{key:"d8a75cf0b95d9affae6e03292c011a73dcff98b4",ref:e=>{this.dropdownRef=e??void 0},isOpen:this.dropdownOpen,triggerId:this.triggerId,anchorToTrigger:!0,closeOnSelect:!0,mode:"single",options:this.dropdownOptions,update:this.handleDropdownUpdate,onIsOpenChange:e=>{this.dropdownOpen=e.detail},"aria-label":"Country"},n("div",{key:"b46a4a9985604720099c3212714804aee5a1f58b",slot:"header",class:"xpl-input-phone__search-wrap"},n("xpl-input",{key:"55bdc0f6ff4b1a1a2d17b5ba10849bcab472d7d8",class:"xpl-input-phone__search",type:"text",label:"",placeholder:"Search",value:this.searchQuery,autocomplete:"off",onInputEvent:e=>{this.searchQuery=e.detail??""}},n("xpl-icon",{key:"af0fd388d39e6d9bcac5a032c7c0cf5f192cc4d3",slot:"pre",class:"xpl-input-phone__search-icon",icon:"magnifier",size:20})))))}get el(){return a(this)}static get watchers(){return{dropdownOpen:[{onDropdownOpenChange:0}],hasErrorState:[{onHasErrorStateChanged:0}],value:[{onValueChange:0}]}}};export{l as xpl_input_phone}
@@ -1 +1 @@
1
- import{r as i,c as s,h as t,H as e,g as n}from"./p-CJABLO_1.js";import{h}from"./p-C_PEOQWj.js";const a=class{constructor(t){i(this,t),this.expandedChange=s(this,"expandedChange",7),this.navigate=s(this,"navigate",7),this.hasTrailingSlot=!1,this.disabled=!1,this.expanded=!1,this.hasChildren=!1,this.hidden=!1,this.link=!1,this.selected=!1,this.handleClick=()=>{this.disabled||(this.hasChildren?(this.expanded=!this.expanded,this.expandedChange.emit(this.expanded)):this.navigate.emit())}}syncLinkHasChildrenExclusivity(){this.enforceLinkExcludesHasChildren()}connectedCallback(){this.syncTrailingSlot(),this.connectTrailingSlotObserver()}disconnectedCallback(){void 0!==this.trailingSlotSyncTimeoutId&&(clearTimeout(this.trailingSlotSyncTimeoutId),this.trailingSlotSyncTimeoutId=void 0),this.disconnectTrailingSlotObserver()}componentWillLoad(){this.syncLinkHasChildrenExclusivity(),this.syncTrailingSlot()}componentWillRender(){this.syncLinkHasChildrenExclusivity(),this.disconnectTrailingSlotObserver()}componentDidRender(){this.scheduleTrailingSlotSync()}connectTrailingSlotObserver(){this.disconnectTrailingSlotObserver(),"undefined"!=typeof MutationObserver&&(this.trailingSlotObserver=new MutationObserver((()=>{this.scheduleTrailingSlotSync()})),this.trailingSlotObserver.observe(this.el,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["slot"]}))}disconnectTrailingSlotObserver(){this.trailingSlotObserver?.disconnect(),this.trailingSlotObserver=void 0}scheduleTrailingSlotSync(){void 0!==this.trailingSlotSyncTimeoutId&&clearTimeout(this.trailingSlotSyncTimeoutId),this.trailingSlotSyncTimeoutId=setTimeout((()=>{this.trailingSlotSyncTimeoutId=void 0,this.el.isConnected&&(this.syncTrailingSlot(),this.connectTrailingSlotObserver())}),0)}syncTrailingSlot(){const i=h(this.el,"trailing","xpl-side-nav-item");i!==this.hasTrailingSlot&&(this.hasTrailingSlot=i)}enforceLinkExcludesHasChildren(){this.link&&(this.hasChildren&&(this.hasChildren=!1),this.el.hasAttribute("has-children")&&this.el.removeAttribute("has-children"))}render(){const i=this.hasChildren&&!this.hasTrailingSlot,s={"xpl-side-nav-item__link":!0,expanded:this.expanded,selected:this.selected};return t(e,{key:"fe0796a361383d97010699b710fe61a0cf17289a",class:{"xpl-side-nav-item":!0,"xpl-side-nav-item--link-disabled":this.link&&this.disabled}},this.link?t("slot",null):t("button",{type:"button",class:s,"aria-current":this.selected?"page":void 0,"aria-expanded":this.hasChildren?this.expanded?"true":"false":void 0,onClick:this.handleClick,disabled:this.disabled},t("span",{class:"xpl-side-nav-item__leading"},t("slot",{name:"leading"},this.icon?t("xpl-icon",{icon:this.icon,size:16}):null)),t("span",{class:"xpl-side-nav-item__label"},this.label??""),(this.hasTrailingSlot||this.hasChildren)&&t("span",{class:{"xpl-side-nav-item__trailing":!0,"xpl-side-nav-item__trailing--chevron":i,expanded:i&&this.expanded},"aria-hidden":i?"true":void 0},t("slot",{name:"trailing"},i?t("xpl-icon",{icon:this.expanded?"chevron-up":"chevron-down",size:16}):null))),this.hasChildren&&!this.link&&t("div",{key:"c3f38b679aef2d66ad477bf9fb04ff8228740ebd",class:"xpl-side-nav-item__children "+(this.expanded?"expanded":""),inert:!this.expanded||void 0},t("div",{key:"7b51bf6ca02febd7e3b63a1bccbbb79b3554db03",class:"xpl-side-nav-item__children-inner"},t("slot",{key:"7d9d16628cb60480199b6eda497fccb931eb72e9"}))))}get el(){return n(this)}static get watchers(){return{hasChildren:[{syncLinkHasChildrenExclusivity:0}],link:[{syncLinkHasChildrenExclusivity:0}]}}};export{a as xpl_side_nav_item}
1
+ import{r as i,c as s,h as t,H as e,g as n}from"./p-CgJEmBQY.js";import{h}from"./p-C_PEOQWj.js";const a=class{constructor(t){i(this,t),this.expandedChange=s(this,"expandedChange",7),this.navigate=s(this,"navigate",7),this.hasTrailingSlot=!1,this.disabled=!1,this.expanded=!1,this.hasChildren=!1,this.hidden=!1,this.link=!1,this.selected=!1,this.handleClick=()=>{this.disabled||(this.hasChildren?(this.expanded=!this.expanded,this.expandedChange.emit(this.expanded)):this.navigate.emit())}}syncLinkHasChildrenExclusivity(){this.enforceLinkExcludesHasChildren()}connectedCallback(){this.syncTrailingSlot(),this.connectTrailingSlotObserver()}disconnectedCallback(){void 0!==this.trailingSlotSyncTimeoutId&&(clearTimeout(this.trailingSlotSyncTimeoutId),this.trailingSlotSyncTimeoutId=void 0),this.disconnectTrailingSlotObserver()}componentWillLoad(){this.syncLinkHasChildrenExclusivity(),this.syncTrailingSlot()}componentWillRender(){this.syncLinkHasChildrenExclusivity(),this.disconnectTrailingSlotObserver()}componentDidRender(){this.scheduleTrailingSlotSync()}connectTrailingSlotObserver(){this.disconnectTrailingSlotObserver(),"undefined"!=typeof MutationObserver&&(this.trailingSlotObserver=new MutationObserver((()=>{this.scheduleTrailingSlotSync()})),this.trailingSlotObserver.observe(this.el,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["slot"]}))}disconnectTrailingSlotObserver(){this.trailingSlotObserver?.disconnect(),this.trailingSlotObserver=void 0}scheduleTrailingSlotSync(){void 0!==this.trailingSlotSyncTimeoutId&&clearTimeout(this.trailingSlotSyncTimeoutId),this.trailingSlotSyncTimeoutId=setTimeout((()=>{this.trailingSlotSyncTimeoutId=void 0,this.el.isConnected&&(this.syncTrailingSlot(),this.connectTrailingSlotObserver())}),0)}syncTrailingSlot(){const i=h(this.el,"trailing","xpl-side-nav-item");i!==this.hasTrailingSlot&&(this.hasTrailingSlot=i)}enforceLinkExcludesHasChildren(){this.link&&(this.hasChildren&&(this.hasChildren=!1),this.el.hasAttribute("has-children")&&this.el.removeAttribute("has-children"))}render(){const i=this.hasChildren&&!this.hasTrailingSlot,s={"xpl-side-nav-item__link":!0,expanded:this.expanded,selected:this.selected};return t(e,{key:"fe0796a361383d97010699b710fe61a0cf17289a",class:{"xpl-side-nav-item":!0,"xpl-side-nav-item--link-disabled":this.link&&this.disabled}},this.link?t("slot",null):t("button",{type:"button",class:s,"aria-current":this.selected?"page":void 0,"aria-expanded":this.hasChildren?this.expanded?"true":"false":void 0,onClick:this.handleClick,disabled:this.disabled},t("span",{class:"xpl-side-nav-item__leading"},t("slot",{name:"leading"},this.icon?t("xpl-icon",{icon:this.icon,size:16}):null)),t("span",{class:"xpl-side-nav-item__label"},this.label??""),(this.hasTrailingSlot||this.hasChildren)&&t("span",{class:{"xpl-side-nav-item__trailing":!0,"xpl-side-nav-item__trailing--chevron":i,expanded:i&&this.expanded},"aria-hidden":i?"true":void 0},t("slot",{name:"trailing"},i?t("xpl-icon",{icon:this.expanded?"chevron-up":"chevron-down",size:16}):null))),this.hasChildren&&!this.link&&t("div",{key:"c3f38b679aef2d66ad477bf9fb04ff8228740ebd",class:"xpl-side-nav-item__children "+(this.expanded?"expanded":""),inert:!this.expanded||void 0},t("div",{key:"7b51bf6ca02febd7e3b63a1bccbbb79b3554db03",class:"xpl-side-nav-item__children-inner"},t("slot",{key:"7d9d16628cb60480199b6eda497fccb931eb72e9"}))))}get el(){return n(this)}static get watchers(){return{hasChildren:[{syncLinkHasChildrenExclusivity:0}],link:[{syncLinkHasChildrenExclusivity:0}]}}};export{a as xpl_side_nav_item}