@adyen/bento-vue3 1.78.2 → 1.79.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 (266) hide show
  1. package/dist/@types/index.d.ts +79 -30
  2. package/dist/accordion.js +1 -1
  3. package/dist/action-bar.js +1 -1
  4. package/dist/assets/accordion-item.css +1 -1
  5. package/dist/assets/action-bar.css +1 -1
  6. package/dist/assets/ai-button.css +1 -1
  7. package/dist/assets/base-modal.css +1 -1
  8. package/dist/assets/button-actions.css +1 -1
  9. package/dist/assets/button.css +1 -1
  10. package/dist/assets/calendar.css +1 -1
  11. package/dist/assets/card.css +1 -1
  12. package/dist/assets/checkbox-group.css +1 -1
  13. package/dist/assets/dashboard-section.css +1 -1
  14. package/dist/assets/data-grid.css +1 -1
  15. package/dist/assets/date-range-picker.css +1 -1
  16. package/dist/assets/dialog-page.css +1 -1
  17. package/dist/assets/file-uploader.css +1 -1
  18. package/dist/assets/filter-bar.css +1 -1
  19. package/dist/assets/form-layout-title.css +1 -1
  20. package/dist/assets/header-with-views.css +1 -1
  21. package/dist/assets/index.css +1 -1
  22. package/dist/assets/input-field-password.css +1 -1
  23. package/dist/assets/input-field-phone-number.css +1 -1
  24. package/dist/assets/input-field.css +1 -1
  25. package/dist/assets/inspector.css +1 -1
  26. package/dist/assets/layout-row.css +1 -1
  27. package/dist/assets/modal-fullscreen.css +1 -1
  28. package/dist/assets/search-bar.css +1 -1
  29. package/dist/assets/secondary-nav.css +1 -1
  30. package/dist/assets/sidepanel.css +1 -1
  31. package/dist/assets/step.css +1 -1
  32. package/dist/assets/structured-list-item.css +1 -1
  33. package/dist/assets/summary-grid.css +1 -1
  34. package/dist/assets/tab.css +1 -1
  35. package/dist/assets/teleport.css +1 -0
  36. package/dist/assets/toast.css +1 -1
  37. package/dist/assets/tooltip.css +1 -1
  38. package/dist/assets/tutorial.css +1 -1
  39. package/dist/assets/use-cached-selected-values.css +1 -1
  40. package/dist/button.js +1 -1
  41. package/dist/card.js +1 -1
  42. package/dist/checkbox.js +2 -2
  43. package/dist/chunks/{accordion-item.Bd3v6erb.js → accordion-item.DHyAfeAu.js} +2 -2
  44. package/dist/chunks/{accordion-item.Bd3v6erb.js.map → accordion-item.DHyAfeAu.js.map} +1 -1
  45. package/dist/chunks/{action-bar.BZ04Y7Yi.js → action-bar.QX16Mu4L.js} +3 -3
  46. package/dist/chunks/{action-bar.BZ04Y7Yi.js.map → action-bar.QX16Mu4L.js.map} +1 -1
  47. package/dist/chunks/{base-modal.UA93s_8c.js → base-modal.CHYvJ_xU.js} +17 -17
  48. package/dist/chunks/{base-modal.UA93s_8c.js.map → base-modal.CHYvJ_xU.js.map} +1 -1
  49. package/dist/chunks/{button-actions-with-menu.BeQ-j1bv.js → button-actions-with-menu.B8qBBN82.js} +2 -2
  50. package/dist/chunks/{button-actions-with-menu.BeQ-j1bv.js.map → button-actions-with-menu.B8qBBN82.js.map} +1 -1
  51. package/dist/chunks/button-actions.Bg38lywL.js +1234 -0
  52. package/dist/chunks/button-actions.Bg38lywL.js.map +1 -0
  53. package/dist/chunks/{calendar.Tm7Cvpwu.js → calendar.CyJXcMz2.js} +4 -43
  54. package/dist/chunks/{calendar.Tm7Cvpwu.js.map → calendar.CyJXcMz2.js.map} +1 -1
  55. package/dist/chunks/{card.GxkxfBoV.js → card.BqkufnQe.js} +2 -2
  56. package/dist/chunks/{card.GxkxfBoV.js.map → card.BqkufnQe.js.map} +1 -1
  57. package/dist/chunks/{checkbox-group.D56nUmre.js → checkbox-group.BRQiuU3y.js} +51 -50
  58. package/dist/chunks/checkbox-group.BRQiuU3y.js.map +1 -0
  59. package/dist/chunks/{checkbox.SffuKyNj.js → checkbox.BRTK_DHj.js} +3 -3
  60. package/dist/chunks/{checkbox.SffuKyNj.js.map → checkbox.BRTK_DHj.js.map} +1 -1
  61. package/dist/chunks/{code-snippet.B5NUDrZ-.js → code-snippet.YxZ3_4ye.js} +5 -5
  62. package/dist/chunks/{code-snippet.B5NUDrZ-.js.map → code-snippet.YxZ3_4ye.js.map} +1 -1
  63. package/dist/chunks/{codemirror.Zv80n3Z2.js → codemirror.Cy7iSLbd.js} +12 -12
  64. package/dist/chunks/{codemirror.Zv80n3Z2.js.map → codemirror.Cy7iSLbd.js.map} +1 -1
  65. package/dist/chunks/constructNow.BhymNmy5.js +8 -0
  66. package/dist/chunks/{constructNow.CHWWeLPc.js.map → constructNow.BhymNmy5.js.map} +1 -1
  67. package/dist/chunks/{controls-group.cbGiHr7n.js → controls-group.CJe5J84d.js} +2 -2
  68. package/dist/chunks/{controls-group.cbGiHr7n.js.map → controls-group.CJe5J84d.js.map} +1 -1
  69. package/dist/chunks/{copy.ClKnDjMI.js → copy.mq0o1Rag.js} +2 -2
  70. package/dist/chunks/{copy.ClKnDjMI.js.map → copy.mq0o1Rag.js.map} +1 -1
  71. package/dist/chunks/{country.DmnN9YIW.js → country.D484ezGU.js} +2 -2
  72. package/dist/chunks/{country.DmnN9YIW.js.map → country.D484ezGU.js.map} +1 -1
  73. package/dist/chunks/{dashboard-section.Cqi0PWeJ.js → dashboard-section.CNCqp74F.js} +4 -4
  74. package/dist/chunks/{dashboard-section.Cqi0PWeJ.js.map → dashboard-section.CNCqp74F.js.map} +1 -1
  75. package/dist/chunks/{dashed-underline.r62L_XBr.js → dashed-underline.CtTu1AOE.js} +26 -25
  76. package/dist/chunks/{dashed-underline.r62L_XBr.js.map → dashed-underline.CtTu1AOE.js.map} +1 -1
  77. package/dist/chunks/{data-grid-template.D7kB3S1u.js → data-grid-template.CLpaJvTj.js} +4 -4
  78. package/dist/chunks/{data-grid-template.D7kB3S1u.js.map → data-grid-template.CLpaJvTj.js.map} +1 -1
  79. package/dist/chunks/data-grid-template.keys.VezYtHtM.js +5 -0
  80. package/dist/chunks/{data-grid-template.keys.2_AkxuNT.js.map → data-grid-template.keys.VezYtHtM.js.map} +1 -1
  81. package/dist/chunks/{data-grid.jC1eKDzq.js → data-grid.CD3Nb4pg.js} +18 -18
  82. package/dist/chunks/{data-grid.jC1eKDzq.js.map → data-grid.CD3Nb4pg.js.map} +1 -1
  83. package/dist/chunks/{date-picker.x9GeC_UO.js → date-picker.C3BH0Bsr.js} +13 -13
  84. package/dist/chunks/{date-picker.x9GeC_UO.js.map → date-picker.C3BH0Bsr.js.map} +1 -1
  85. package/dist/chunks/date-range-picker.BPZE6r01.js +1108 -0
  86. package/dist/chunks/date-range-picker.BPZE6r01.js.map +1 -0
  87. package/dist/chunks/{dialog-page.zWrBSgBD.js → dialog-page.BY6T1jYZ.js} +2 -2
  88. package/dist/chunks/{dialog-page.zWrBSgBD.js.map → dialog-page.BY6T1jYZ.js.map} +1 -1
  89. package/dist/chunks/{differenceInMonths.C8FyCrav.js → differenceInMonths.Cab3nOsb.js} +2 -2
  90. package/dist/chunks/{differenceInMonths.C8FyCrav.js.map → differenceInMonths.Cab3nOsb.js.map} +1 -1
  91. package/dist/chunks/{divider.DnKNNyWB.js → divider.Dho4_hQ7.js} +2 -2
  92. package/dist/chunks/{divider.DnKNNyWB.js.map → divider.Dho4_hQ7.js.map} +1 -1
  93. package/dist/chunks/{dropdown-default-textbox._KEBXjKT.js → dropdown-default-textbox.CNrsjXUU.js} +2 -2
  94. package/dist/chunks/{dropdown-default-textbox._KEBXjKT.js.map → dropdown-default-textbox.CNrsjXUU.js.map} +1 -1
  95. package/dist/chunks/{dropdown-tag.DIlF7mOi.js → dropdown-tag.B0LtUuUk.js} +4 -4
  96. package/dist/chunks/{dropdown-tag.DIlF7mOi.js.map → dropdown-tag.B0LtUuUk.js.map} +1 -1
  97. package/dist/chunks/{dropdown.CdsjtT9_.js → dropdown.B5tPWVxg.js} +9 -9
  98. package/dist/chunks/{dropdown.CdsjtT9_.js.map → dropdown.B5tPWVxg.js.map} +1 -1
  99. package/dist/chunks/es6.MoTTyETW.js.map +1 -1
  100. package/dist/chunks/{events.CMzGybJJ.js → events.BQOQSSb7.js} +2 -5
  101. package/dist/chunks/{events.CMzGybJJ.js.map → events.BQOQSSb7.js.map} +1 -1
  102. package/dist/chunks/{field-label.C97CrBI_.js → field-label.B1rMWIWY.js} +2 -2
  103. package/dist/chunks/{field-label.C97CrBI_.js.map → field-label.B1rMWIWY.js.map} +1 -1
  104. package/dist/chunks/{file-uploader.R0NZXIsS.js → file-uploader.BwmQdkmz.js} +367 -350
  105. package/dist/chunks/file-uploader.BwmQdkmz.js.map +1 -0
  106. package/dist/chunks/{filter-bar.DAYxD7wi.js → filter-bar.B9yGivxl.js} +118 -122
  107. package/dist/chunks/filter-bar.B9yGivxl.js.map +1 -0
  108. package/dist/chunks/{footer-actions.BO52wpv-.js → footer-actions.pC1mxLQm.js} +2 -2
  109. package/dist/chunks/{footer-actions.BO52wpv-.js.map → footer-actions.pC1mxLQm.js.map} +1 -1
  110. package/dist/chunks/{form-layout-title.61ESsGAY.js → form-layout-title.sxPU_lB_.js} +2 -2
  111. package/dist/chunks/{form-layout-title.61ESsGAY.js.map → form-layout-title.sxPU_lB_.js.map} +1 -1
  112. package/dist/chunks/form-layout.types.bZW9iR6_.js +5 -0
  113. package/dist/chunks/{form-layout.types.D3EKzbE7.js.map → form-layout.types.bZW9iR6_.js.map} +1 -1
  114. package/dist/chunks/get-slot-text.CQRAP2_q.js.map +1 -1
  115. package/dist/chunks/{getTimezoneOffsetInMilliseconds.BW7U6PxE.js → getTimezoneOffsetInMilliseconds.B7sxiukN.js} +2 -2
  116. package/dist/chunks/{getTimezoneOffsetInMilliseconds.BW7U6PxE.js.map → getTimezoneOffsetInMilliseconds.B7sxiukN.js.map} +1 -1
  117. package/dist/chunks/{header-meta.BE6QfUNi.js → header-meta.DZ8Gx4XE.js} +17 -17
  118. package/dist/chunks/{header-meta.BE6QfUNi.js.map → header-meta.DZ8Gx4XE.js.map} +1 -1
  119. package/dist/chunks/{header-with-views.CzLcYeW5.js → header-with-views.b1gt2wud.js} +109 -109
  120. package/dist/chunks/{header-with-views.CzLcYeW5.js.map → header-with-views.b1gt2wud.js.map} +1 -1
  121. package/dist/chunks/{header.3It50Clh.js → header.BQAAmjUF.js} +3 -3
  122. package/dist/chunks/{header.3It50Clh.js.map → header.BQAAmjUF.js.map} +1 -1
  123. package/dist/chunks/{info-icon.BhOm72U4.js → info-icon.DB0MI-dH.js} +2 -2
  124. package/dist/chunks/{info-icon.BhOm72U4.js.map → info-icon.DB0MI-dH.js.map} +1 -1
  125. package/dist/chunks/{input-field-password.-xEY2VB8.js → input-field-password.noxsH61p.js} +154 -146
  126. package/dist/chunks/input-field-password.noxsH61p.js.map +1 -0
  127. package/dist/chunks/{input-field-phone-number.DcxhP_qK.js → input-field-phone-number.B_uFvUXP.js} +587 -585
  128. package/dist/chunks/{input-field-phone-number.DcxhP_qK.js.map → input-field-phone-number.B_uFvUXP.js.map} +1 -1
  129. package/dist/chunks/{input-field.B6nL7d8O.js → input-field.C9ABE4cI.js} +118 -110
  130. package/dist/chunks/input-field.C9ABE4cI.js.map +1 -0
  131. package/dist/chunks/{keyboard-navigation.pB8weElW.js → keyboard-navigation.DWmhelVv.js} +2 -2
  132. package/dist/chunks/{keyboard-navigation.pB8weElW.js.map → keyboard-navigation.DWmhelVv.js.map} +1 -1
  133. package/dist/chunks/{layout-row.DVf7wNSB.js → layout-row.BxP9SxrL.js} +2 -2
  134. package/dist/chunks/{layout-row.DVf7wNSB.js.map → layout-row.BxP9SxrL.js.map} +1 -1
  135. package/dist/chunks/{listbox-option-tag.Cwe9Bn-R.js → listbox-option-tag.C1cZs38g.js} +2 -2
  136. package/dist/chunks/{listbox-option-tag.Cwe9Bn-R.js.map → listbox-option-tag.C1cZs38g.js.map} +1 -1
  137. package/dist/chunks/{modal-fullscreen.DTT-5rQX.js → modal-fullscreen.B69QJ8D6.js} +23 -21
  138. package/dist/chunks/modal-fullscreen.B69QJ8D6.js.map +1 -0
  139. package/dist/chunks/{modal.vue_vue_type_script_setup_true_lang.c3Ma1oAL.js → modal.vue_vue_type_script_setup_true_lang.BYqbdsty.js} +4 -4
  140. package/dist/chunks/{modal.vue_vue_type_script_setup_true_lang.c3Ma1oAL.js.map → modal.vue_vue_type_script_setup_true_lang.BYqbdsty.js.map} +1 -1
  141. package/dist/chunks/{pagination.DCn_tenp.js → pagination.Dst8Y6DD.js} +2 -2
  142. package/dist/chunks/{pagination.DCn_tenp.js.map → pagination.Dst8Y6DD.js.map} +1 -1
  143. package/dist/chunks/{payment-method.D6PeTYWq.js → payment-method.CExDsirg.js} +2 -2
  144. package/dist/chunks/{payment-method.D6PeTYWq.js.map → payment-method.CExDsirg.js.map} +1 -1
  145. package/dist/chunks/promo-banner.B-TLTLEd.js.map +1 -1
  146. package/dist/chunks/{radio-group.Br-N309Y.js → radio-group.CVDDBCP4.js} +5 -5
  147. package/dist/chunks/{radio-group.Br-N309Y.js.map → radio-group.CVDDBCP4.js.map} +1 -1
  148. package/dist/chunks/{rich-text-editor.B6Ftqv55.js → rich-text-editor.DyC-Nnc8.js} +12 -12
  149. package/dist/chunks/{rich-text-editor.B6Ftqv55.js.map → rich-text-editor.DyC-Nnc8.js.map} +1 -1
  150. package/dist/chunks/{search-bar.BmNEcy0L.js → search-bar.BwrFcw9L.js} +28 -28
  151. package/dist/chunks/search-bar.BwrFcw9L.js.map +1 -0
  152. package/dist/chunks/{secondary-nav.CPosCncv.js → secondary-nav.D7l9h0_t.js} +3 -3
  153. package/dist/chunks/{secondary-nav.CPosCncv.js.map → secondary-nav.D7l9h0_t.js.map} +1 -1
  154. package/dist/chunks/{segmented-control.BCHGDSrf.js → segmented-control.CwDOwDIu.js} +2 -2
  155. package/dist/chunks/{segmented-control.BCHGDSrf.js.map → segmented-control.CwDOwDIu.js.map} +1 -1
  156. package/dist/chunks/{selection-card-group.DBdwqWsH.js → selection-card-group.CZfusjo0.js} +4 -4
  157. package/dist/chunks/{selection-card-group.DBdwqWsH.js.map → selection-card-group.CZfusjo0.js.map} +1 -1
  158. package/dist/chunks/{sidepanel.CS9CfAWZ.js → sidepanel.BFz_7DKg.js} +4 -4
  159. package/dist/chunks/{sidepanel.CS9CfAWZ.js.map → sidepanel.BFz_7DKg.js.map} +1 -1
  160. package/dist/chunks/{step.CoSuGK16.js → step.CxnmaTMe.js} +3 -3
  161. package/dist/chunks/{step.CoSuGK16.js.map → step.CxnmaTMe.js.map} +1 -1
  162. package/dist/chunks/structured-list-item.DjbvVIwI.js +111 -0
  163. package/dist/chunks/{structured-list-item.BTPh7SPj.js.map → structured-list-item.DjbvVIwI.js.map} +1 -1
  164. package/dist/chunks/summary-grid.keys.Xx-W5a2w.js +6 -0
  165. package/dist/chunks/{summary-grid.keys.CxTf_FOc.js.map → summary-grid.keys.Xx-W5a2w.js.map} +1 -1
  166. package/dist/chunks/{summary-grid.types.cE1fyLvC.js → summary-grid.types.KVqau_I-.js} +74 -68
  167. package/dist/chunks/summary-grid.types.KVqau_I-.js.map +1 -0
  168. package/dist/chunks/{tab.CD5Eu6ql.js → tab.BAwuVDsV.js} +2 -2
  169. package/dist/chunks/{tab.CD5Eu6ql.js.map → tab.BAwuVDsV.js.map} +1 -1
  170. package/dist/chunks/tabs.keys.B4qGhjp2.js +7 -0
  171. package/dist/chunks/{tabs.keys.Cb4Vw5Jh.js.map → tabs.keys.B4qGhjp2.js.map} +1 -1
  172. package/dist/chunks/{tag.CjaB9DxL.js → tag.BmMnGJMp.js} +2 -2
  173. package/dist/chunks/{tag.CjaB9DxL.js.map → tag.BmMnGJMp.js.map} +1 -1
  174. package/dist/chunks/teleport.CHhznja1.js +129 -0
  175. package/dist/chunks/teleport.CHhznja1.js.map +1 -0
  176. package/dist/chunks/{textarea.XRETLCSj.js → textarea.BZjnJf5q.js} +3 -3
  177. package/dist/chunks/{textarea.XRETLCSj.js.map → textarea.BZjnJf5q.js.map} +1 -1
  178. package/dist/chunks/{timeline-item.19zg_gBi.js → timeline-item.YjC_8BBB.js} +7 -7
  179. package/dist/chunks/{timeline-item.19zg_gBi.js.map → timeline-item.YjC_8BBB.js.map} +1 -1
  180. package/dist/chunks/toast.e1-BCZks.js +229 -0
  181. package/dist/chunks/toast.e1-BCZks.js.map +1 -0
  182. package/dist/chunks/{tooltip.Dp9_ESm_.js → tooltip.CeX5eGnw.js} +2 -2
  183. package/dist/chunks/{tooltip.Dp9_ESm_.js.map → tooltip.CeX5eGnw.js.map} +1 -1
  184. package/dist/chunks/{tutorial.vue_vue_type_script_setup_true_lang.KvlJ_dl9.js → tutorial.vue_vue_type_script_setup_true_lang.Cqimmacx.js} +2 -2
  185. package/dist/chunks/{tutorial.vue_vue_type_script_setup_true_lang.KvlJ_dl9.js.map → tutorial.vue_vue_type_script_setup_true_lang.Cqimmacx.js.map} +1 -1
  186. package/dist/chunks/{use-bento-toast-controller.Kri_h7jS.js → use-bento-toast-controller.DK1PV3YW.js} +2 -2
  187. package/dist/chunks/{use-bento-toast-controller.Kri_h7jS.js.map → use-bento-toast-controller.DK1PV3YW.js.map} +1 -1
  188. package/dist/chunks/{use-cached-selected-values.8MdrR9wt.js → use-cached-selected-values.os3Yp7Tw.js} +3 -3
  189. package/dist/chunks/{use-cached-selected-values.8MdrR9wt.js.map → use-cached-selected-values.os3Yp7Tw.js.map} +1 -1
  190. package/dist/chunks/{use-form-layout-loading.D3lALhtC.js → use-form-layout-loading.CWbjZiwP.js} +2 -2
  191. package/dist/chunks/{use-form-layout-loading.D3lALhtC.js.map → use-form-layout-loading.CWbjZiwP.js.map} +1 -1
  192. package/dist/code-snippet.js +1 -1
  193. package/dist/country.js +1 -1
  194. package/dist/dashboard-template.js +1 -1
  195. package/dist/dashed-underline.js +1 -1
  196. package/dist/data-grid-template.js +1 -1
  197. package/dist/data-grid.js +1 -1
  198. package/dist/date-picker.js +2 -2
  199. package/dist/date-range-picker.js +2 -2
  200. package/dist/divider.js +1 -1
  201. package/dist/dropdown.js +4 -4
  202. package/dist/file-uploader.js +1 -1
  203. package/dist/filter-bar.js +1 -1
  204. package/dist/form-layout.js +1 -1
  205. package/dist/header-with-views.js +1 -1
  206. package/dist/header.js +1 -1
  207. package/dist/index.js +288 -287
  208. package/dist/index.js.map +1 -1
  209. package/dist/info-icon.js +1 -1
  210. package/dist/input-field-password.js +1 -1
  211. package/dist/input-field-phone-number.js +1 -1
  212. package/dist/input-field.js +1 -1
  213. package/dist/internal.js +27 -26
  214. package/dist/internal.js.map +1 -1
  215. package/dist/layout.js +1 -1
  216. package/dist/menu.js +1 -1
  217. package/dist/modal-fullscreen.js +1 -1
  218. package/dist/modal.js +2 -2
  219. package/dist/pagination.js +1 -1
  220. package/dist/payment-method.js +1 -1
  221. package/dist/popover.js +1 -1
  222. package/dist/radio-group.js +1 -1
  223. package/dist/rich-text-editor.js +1 -1
  224. package/dist/search-bar.js +2 -2
  225. package/dist/secondary-nav.js +1 -1
  226. package/dist/segmented-control.js +1 -1
  227. package/dist/selection-card.js +1 -1
  228. package/dist/sidepanel.js +1 -1
  229. package/dist/stepper.js +1 -1
  230. package/dist/structured-list.js +1 -1
  231. package/dist/styles/bento-dark.css +4 -1
  232. package/dist/styles/bento-light.css +4 -1
  233. package/dist/styles/bento.css +4 -1
  234. package/dist/styles/legacy.css +4 -1
  235. package/dist/styles/styleguide.css +4 -1
  236. package/dist/summary-grid.js +1 -1
  237. package/dist/tabs.js +1 -1
  238. package/dist/tag.js +1 -1
  239. package/dist/textarea.js +1 -1
  240. package/dist/timeline.js +1 -1
  241. package/dist/toast.js +1 -1
  242. package/dist/tutorial.js +1 -1
  243. package/dist/use-form-v4.js +8 -8
  244. package/dist/use-form-v4.js.map +1 -1
  245. package/dist/web-types.json +1 -1
  246. package/package.json +11 -10
  247. package/dist/chunks/button-actions.BQ3AFQqt.js +0 -1355
  248. package/dist/chunks/button-actions.BQ3AFQqt.js.map +0 -1
  249. package/dist/chunks/checkbox-group.D56nUmre.js.map +0 -1
  250. package/dist/chunks/constructNow.CHWWeLPc.js +0 -8
  251. package/dist/chunks/data-grid-template.keys.2_AkxuNT.js +0 -5
  252. package/dist/chunks/date-range-picker.CXeFdxAA.js +0 -1100
  253. package/dist/chunks/date-range-picker.CXeFdxAA.js.map +0 -1
  254. package/dist/chunks/file-uploader.R0NZXIsS.js.map +0 -1
  255. package/dist/chunks/filter-bar.DAYxD7wi.js.map +0 -1
  256. package/dist/chunks/form-layout.types.D3EKzbE7.js +0 -5
  257. package/dist/chunks/input-field-password.-xEY2VB8.js.map +0 -1
  258. package/dist/chunks/input-field.B6nL7d8O.js.map +0 -1
  259. package/dist/chunks/modal-fullscreen.DTT-5rQX.js.map +0 -1
  260. package/dist/chunks/search-bar.BmNEcy0L.js.map +0 -1
  261. package/dist/chunks/structured-list-item.BTPh7SPj.js +0 -111
  262. package/dist/chunks/summary-grid.keys.CxTf_FOc.js +0 -6
  263. package/dist/chunks/summary-grid.types.cE1fyLvC.js.map +0 -1
  264. package/dist/chunks/tabs.keys.Cb4Vw5Jh.js +0 -7
  265. package/dist/chunks/toast.6oJx7SNq.js +0 -221
  266. package/dist/chunks/toast.6oJx7SNq.js.map +0 -1
@@ -1,6 +1,6 @@
1
1
  import { defineComponent as K, ref as i, computed as s, watch as O, provide as U, readonly as ne, createElementBlock as T, openBlock as y, withDirectives as Z, createVNode as B, mergeProps as se, toHandlers as ae, unref as p, renderSlot as P, withCtx as g, createTextVNode as j, toDisplayString as G, useSlots as oe, inject as le, onMounted as ue, onBeforeUnmount as re, normalizeClass as ie, createBlock as F, Fragment as pe, createElementVNode as ce, vShow as ve } from "vue";
2
2
  import { B as w } from "./typography.yBEME_Gu.js";
3
- import { B as R, a as de } from "./keyboard-navigation.pB8weElW.js";
3
+ import { B as R, a as de } from "./keyboard-navigation.DWmhelVv.js";
4
4
  import { u as me } from "./index.pdBj0KQU.js";
5
5
  import { _ as M } from "./_plugin-vue_export-helper.CHgC5LLL.js";
6
6
  import { B as be } from "./base-button.BYhf0xf3.js";
@@ -38,7 +38,7 @@ const _e = (t) => {
38
38
  t.value.findIndex((v) => v.buttonElement === o.buttonElement.value),
39
39
  1
40
40
  );
41
- } }), H = Symbol("stepper state");
41
+ } }), H = /* @__PURE__ */ Symbol("stepper state");
42
42
  var W = /* @__PURE__ */ ((t) => (t.LINEAR = "linear", t.NON_LINEAR = "non-linear", t))(W || {}), z = /* @__PURE__ */ ((t) => (t.HORIZONTAL = "horizontal", t.VERTICAL = "vertical", t))(z || {});
43
43
  const J = {
44
44
  "en-US": {
@@ -264,4 +264,4 @@ export {
264
264
  z as b,
265
265
  Ve as s
266
266
  };
267
- //# sourceMappingURL=step.CoSuGK16.js.map
267
+ //# sourceMappingURL=step.CxnmaTMe.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"step.CoSuGK16.js","sources":["../../../vue2/src/components/stepper/composables/use-keyboard-navigation/use-keyboard-navigation.ts","../../../vue2/src/components/stepper/composables/use-step-register/use-step-register.ts","../../../vue2/src/components/stepper/stepper.keys.ts","../../../vue2/src/components/stepper/stepper.types.ts","../../../vue2/src/components/stepper/stepper.vue","../../../vue2/src/components/stepper/components/step/step.vue"],"sourcesContent":["import { type Ref, type UnwrapRef } from 'vue';\n\nimport { BentoKeyboardNavigationKeyDownEvent } from '@/types/keyboard-navigation';\n\n/**\n * Returns keyboard navigation's event handlers to navigate through the steps\n *\n * @param steps the list of bento-steps DOM elements to focus on the navigation\n * @returns\n */\nexport const useKeyboardNavigation = (steps: Ref<UnwrapRef<Array<HTMLButtonElement>>>) => {\n // Returns the event handler that moves the focus on a given step offset\n function focusOnStep(indexOffset: number) {\n return ({ detail: event }) => {\n event.preventDefault();\n\n const currentIndex = steps.value.indexOf(document.activeElement as HTMLButtonElement);\n if (currentIndex < 0) {\n return;\n }\n\n steps.value[currentIndex + indexOffset]?.focus();\n };\n }\n\n const focusOnPreviousStep = focusOnStep(-1);\n const focusOnNextStep = focusOnStep(1);\n\n return {\n [BentoKeyboardNavigationKeyDownEvent.ARROW_DOWN]: focusOnNextStep,\n [BentoKeyboardNavigationKeyDownEvent.ARROW_RIGHT]: focusOnNextStep,\n [BentoKeyboardNavigationKeyDownEvent.ARROW_UP]: focusOnPreviousStep,\n [BentoKeyboardNavigationKeyDownEvent.ARROW_LEFT]: focusOnPreviousStep,\n };\n};\n","import type { Ref, UnwrapRef } from 'vue';\nimport type { BentoStepperStepExposeState } from '../../stepper.types';\n\n/**\n * Gets the position of a `bento-step` element within its `bento-stepper` parent.\n * @param stepState The `bento-step` state.\n * @returns The index of the element.\n */\nconst getStepPosition = (stepState: BentoStepperStepExposeState) => {\n // Button is wrapped by <li> element\n const listItemElement = (stepState.buttonElement as Ref<UnwrapRef<HTMLButtonElement>>).value.parentElement;\n const listElement = listItemElement.parentElement;\n return Array.from(listElement.children).indexOf(listItemElement);\n};\n\n/**\n * Provides methods to register/unregister `bento-step` elements to/from the `bento-stepper` step state.\n * These methods allow for tracking the child step elements, including their position in the DOM tree.\n * @param childrenSteps The `bento-stepper` (or `bento-step` if substeps) step state.\n */\nexport const useStepRegister = (childrenSteps: Ref<Array<BentoStepperStepExposeState>>) => {\n /**\n * Registers a step's HTML element in the stepper state.\n * Should be called by a `bento-step` when it is mounted.\n * @param stepState The `bento-step` state.\n */\n const registerStep = (stepState: BentoStepperStepExposeState) => {\n const position = getStepPosition(stepState);\n childrenSteps.value.splice(position, 0, {\n stepContent: stepState.stepContent as string,\n buttonElement: stepState.buttonElement as HTMLButtonElement,\n substeps: stepState.substeps as Array<BentoStepperStepExposeState>,\n });\n };\n\n /**\n * Unregisters a step's HTML element in the stepper state.\n * Should be called by a `bento-step` before it is unmounted.\n * @param stepState The `bento-step` state.\n */\n const removeStep = (stepState: BentoStepperStepExposeState) => {\n childrenSteps.value.splice(\n childrenSteps.value.findIndex(step => step.buttonElement === stepState.buttonElement.value),\n 1\n );\n };\n\n return { registerStep, removeStep };\n};\n","export const STEPPER_STATE = Symbol('stepper state');\n","import type { ComputedRef, Ref, UnwrapRef } from 'vue';\n\nexport enum BentoStepperTypeOption {\n LINEAR = 'linear',\n NON_LINEAR = 'non-linear',\n}\n\nexport enum BentoStepperVariantOption {\n HORIZONTAL = 'horizontal',\n VERTICAL = 'vertical',\n}\n\nexport interface BentoStepperStepExposeState {\n buttonElement: HTMLButtonElement | Ref<UnwrapRef<HTMLButtonElement>>;\n substeps: Array<BentoStepperStepExposeState> | Ref<Array<BentoStepperStepExposeState>>;\n stepContent: string | ComputedRef<string>;\n}\n\nexport type BentoStepperState = Ref<{\n activeStepIndex: number;\n latestActiveStep: number;\n type: `${BentoStepperTypeOption}`;\n variant: `${BentoStepperVariantOption}`;\n steps: Array<HTMLElement>;\n isParentStep?: boolean;\n navigateToStep: (index: number) => void;\n registerStep: (stepState: BentoStepperStepExposeState) => void;\n removeStep: (stepState: BentoStepperStepExposeState) => void;\n}>;\n","<template>\n <nav class=\"b-stepper\">\n <ol\n v-bento-keyboard-navigation-directive\n class=\"b-stepper__list\"\n :class=\"conditionalClasses\"\n v-on=\"keyboardNavigationListeners\"\n >\n <slot></slot>\n </ol>\n\n <bento-typography el=\"span\" variant=\"body\" stronger class=\"b-stepper__text-stepper\"\n >{{\n t('step', {\n currentIndex: n(activeStepIndex + 1),\n totalSteps: n(stepsAmount),\n content: currentStepContent,\n })\n }}\n </bento-typography>\n </nav>\n</template>\n\n<script setup lang=\"ts\">\n import { BentoTypography } from '@/components/typography';\n\n import { computed, type DeepReadonly, type PropType, provide, readonly, ref, watch } from 'vue';\n import { BentoKeyboardNavigationDirective as vBentoKeyboardNavigationDirective } from '@/directives';\n\n import { useKeyboardNavigation, useStepRegister } from './composables';\n import { useI18n } from '@/utils/ts/i18n';\n\n import { STEPPER_STATE } from './stepper.keys';\n import {\n type BentoStepperState,\n type BentoStepperStepExposeState,\n type BentoStepperTypeOption,\n BentoStepperVariantOption,\n } from './stepper.types';\n\n import messages from './messages.json';\n\n const props = defineProps({\n /**\n * Type of stepper; defines how the stepper should behave. Default: linear\n * @values linear, non-linear\n */\n type: {\n type: String as PropType<`${BentoStepperTypeOption}`>,\n default: 'linear',\n },\n /**\n * Stepper variant; defines how the stepper should be displayed. Default: vertical\n * @values vertical, horizontal\n */\n variant: {\n type: String as PropType<`${BentoStepperVariantOption}`>,\n default: 'vertical',\n },\n /**\n * Active step index\n */\n index: {\n type: Number,\n default: 0,\n },\n });\n\n const emit = defineEmits<{\n /**\n * Event triggered when step is updated by the stepper\n */\n (e: 'update:index', index: number): void;\n }>();\n\n type MessageSchema = (typeof messages)['en-US'];\n const { t, n } = useI18n<{ message: MessageSchema }>({ messages });\n\n const childrenSteps = ref<Array<BentoStepperStepExposeState>>([]);\n const activeStepIndex = ref(props.index);\n const latestActiveStep = ref(activeStepIndex.value);\n\n const navigateToStep = (index: number) => {\n // Stores latest active step index so users can navigate backwards and forwards on linear stepper\n if (index > latestActiveStep.value) {\n latestActiveStep.value = index;\n }\n activeStepIndex.value = index;\n };\n\n const currentStepContent = computed(() => childrenSteps.value[activeStepIndex.value]?.stepContent);\n const stepsAmount = computed(() => childrenSteps.value.length);\n const childrenStepsElements = computed(() => childrenSteps.value.map(({ buttonElement }) => buttonElement));\n const isHorizontalVariant = computed(() => props.variant === BentoStepperVariantOption.HORIZONTAL);\n\n // List of all visible steps nested on the stepper, including the substeps of the children steps\n // Flattening the steps on a single list makes the keyboard navigation easier to be handled\n const allVisibleStepsElements = computed(() =>\n childrenSteps.value\n .map(({ buttonElement, substeps }, index) => {\n const isStepActive = activeStepIndex.value === index;\n const isSubstepsVisible = !isHorizontalVariant.value && isStepActive;\n\n if (!isSubstepsVisible) {\n return [buttonElement];\n }\n\n return [buttonElement].concat(substeps.map(step => step.buttonElement));\n })\n .flat()\n );\n\n const { registerStep, removeStep } = useStepRegister(childrenSteps);\n\n const stepperState: BentoStepperState = ref({\n activeStepIndex,\n latestActiveStep,\n steps: childrenStepsElements,\n type: props.type,\n variant: props.variant,\n navigateToStep,\n registerStep,\n removeStep,\n });\n\n const conditionalClasses = computed(() => ({\n 'b-stepper__list--horizontal': isHorizontalVariant.value,\n }));\n\n watch(() => props.index, navigateToStep);\n watch(activeStepIndex, index => {\n emit('update:index', index);\n });\n\n const keyboardNavigationListeners = useKeyboardNavigation(allVisibleStepsElements);\n\n // Provides stepper state to BentoStep children components\n provide<DeepReadonly<BentoStepperState>>(STEPPER_STATE, readonly(stepperState));\n</script>\n\n<script lang=\"ts\">\n /**\n * Steppers break down complex processes into manageable steps to guide users through a sequential or multi-step process.\n *\n * @example\n * import { BentoStep, BentoStepper } from '@adyen/bento-vue2';\n *\n * export default {\n * components: { BentoStep, BentoStepper },\n * template: `\n * <bento-stepper :index=\"1\">\n * <bento-step>Step 1</bento-step>\n * <bento-step>Step 2</bento-step>\n * <bento-step>Step 3</bento-step>\n * </bento-stepper>\n * `\n * }\n */\n\n export default {\n i18n: { messages },\n name: 'stepper',\n };\n</script>\n\n<style scoped src=\"./stepper.scss\" />\n","<template>\n <li :class=\"conditionalClasses\" class=\"b-step\">\n <base-button\n ref=\"buttonComponent\"\n :aria-current=\"ariaCurrentValue\"\n :aria-disabled=\"ariaDisabledValue\"\n class=\"b-step__button\"\n type=\"button\"\n :tabindex=\"tabIndexValue\"\n :disabled=\"isDisabled\"\n @click=\"navigateToStep\"\n @focus=\"isFocused = true\"\n @blur=\"isFocused = false\"\n >\n <template #iconLeft>\n <bento-typography el=\"span\" variant=\"body\" stronger class=\"b-step__index\" aria-hidden=\"true\">\n <checkmark-small-icon v-if=\"isCompleted\" />\n <template v-else-if=\"!isSubstep\">{{ index + 1 }}</template>\n <dot-icon v-else />\n </bento-typography>\n </template>\n\n <bento-typography ref=\"stepContent\" el=\"span\" variant=\"body\" :stronger=\"isActive\" class=\"b-step__content\">\n <slot></slot>\n </bento-typography>\n </base-button>\n\n <ul v-show=\"isSubstepsVisible\" ref=\"substepList\" class=\"b-step__substep-list\">\n <slot name=\"substeps\"></slot>\n </ul>\n </li>\n</template>\n\n<script setup lang=\"ts\">\n import { computed, inject, onBeforeUnmount, onMounted, provide, ref, useSlots, watch } from 'vue';\n import { BaseButton } from '@/components/internal/base-button';\n import { BentoTypography } from '@/components/typography';\n import CheckmarkSmallIcon from '@adyen/ui-assets-icons-16/vue/checkmark-small';\n import DotIcon from '@adyen/ui-assets-icons-16/vue/dot';\n\n import { useStepRegister } from '../../composables';\n import { STEPPER_STATE } from '../../stepper.keys';\n import {\n type BentoStepperState,\n type BentoStepperStepExposeState,\n BentoStepperTypeOption,\n BentoStepperVariantOption,\n } from '../../stepper.types';\n import { type Booleanish } from '@/types/prop-types';\n\n const slots = useSlots();\n\n const props = defineProps({\n /**\n * Completed status. Used on non-linear steppers to indicate if the step is completed.\n */\n completed: {\n type: Boolean,\n default: false,\n },\n /**\n * Active substep index\n */\n substepIndex: {\n type: Number,\n default: 0,\n },\n });\n\n const emit = defineEmits<{\n /**\n * Event triggered when substep is updated by the parent step\n */\n (e: 'update:substep-index', index: number): void;\n }>();\n\n // Element refs\n const buttonComponent = ref<InstanceType<typeof BaseButton> | null>(null);\n const stepContent = ref<InstanceType<typeof BentoTypography> | null>(null);\n const substeps = ref<Array<BentoStepperStepExposeState>>([]);\n\n // Injects parent BentoStepper state data\n const stepper = inject<BentoStepperState>(STEPPER_STATE);\n\n const buttonElement = computed(() => buttonComponent.value?.$el as HTMLButtonElement);\n const index = computed(() => stepper?.value.steps.indexOf(buttonElement.value));\n\n const stepContentValue = computed(() => stepContent.value?.$el.textContent);\n\n // Substep logic\n const substepsButtonElements = computed(() => substeps.value.map(({ buttonElement }) => buttonElement));\n\n const activeSubStepIndex = ref(props.substepIndex);\n const latestActiveSubStepIndex = ref(activeSubStepIndex.value);\n\n const navigateToSubstep = (value: number) => {\n if (value > latestActiveSubStepIndex.value) {\n latestActiveSubStepIndex.value = value;\n }\n\n activeSubStepIndex.value = value;\n };\n\n const { registerStep, removeStep } = useStepRegister(substeps);\n\n const stepState: BentoStepperState = ref({\n activeStepIndex: activeSubStepIndex,\n latestActiveStep: latestActiveSubStepIndex,\n type: stepper.value.type,\n variant: stepper.value.variant,\n steps: substepsButtonElements,\n isParentStep: true,\n navigateToStep: navigateToSubstep,\n registerStep,\n removeStep,\n });\n\n provide(STEPPER_STATE, stepState);\n\n watch(() => props.substepIndex, navigateToSubstep);\n watch(activeSubStepIndex, value => {\n emit('update:substep-index', value);\n });\n\n onMounted(() => {\n if (!stepper) {\n throw new Error(\n 'BentoStep components should only be used inside BentoStepper or other BentoStep components.'\n );\n }\n\n stepper.value.registerStep({\n buttonElement,\n stepContent: stepContentValue,\n substeps,\n });\n });\n\n onBeforeUnmount(() => {\n stepper.value.removeStep({\n buttonElement,\n stepContent: stepContentValue,\n substeps,\n });\n });\n\n // Step states\n const isSubstep = computed(() => stepper.value.isParentStep);\n const isFocused = ref(false);\n const isActive = computed(() => stepper?.value.activeStepIndex === index.value);\n const isSubstepsVisible = computed(\n () =>\n isActive.value &&\n stepper.value.variant !== BentoStepperVariantOption.HORIZONTAL &&\n !isSubstep.value &&\n slots.substeps\n );\n const isCompleted = computed(() => {\n if (stepper?.value.type === BentoStepperTypeOption.NON_LINEAR) {\n return props.completed;\n }\n\n return stepper?.value.latestActiveStep > index.value;\n });\n const isDisabled = computed(\n () => stepper?.value.type === BentoStepperTypeOption.LINEAR && index.value > stepper?.value.latestActiveStep\n );\n\n const navigateToStep = () => {\n if (isDisabled.value) {\n return;\n }\n\n stepper.value.navigateToStep(index.value);\n };\n\n // Styling and a11y\n const ariaCurrentValue = computed(() => (isActive.value ? 'step' : ('false' as Booleanish)));\n const ariaDisabledValue = computed(() => isDisabled.value.toString() as Booleanish);\n const tabIndexValue = computed(() => (isFocused.value || (index.value === 0 && !isSubstep.value) ? '0' : '-1'));\n\n const conditionalClasses = computed(() => ({\n 'b-step--active': isActive.value,\n 'b-step--completed': isCompleted.value,\n 'b-step--substep': isSubstep.value,\n }));\n</script>\n\n<script lang=\"ts\">\n /**\n * Steps are components placed inside BentoSteppers to break down complex processes\n *\n * @example\n * import { BentoStep } from '@adyen/bento-vue2';\n *\n * export default {\n * components: { BentoStep },\n * template: `\n * <bento-stepper>\n * <bento-step>Step 1</bento-step>\n * <bento-step>\n * Step 2\n * <template #substeps>\n * <bento-step>Substep 1</bento-step>\n * <bento-step>Substep 2</bento-step>\n * </template>\n * </bento-step>\n * </bento-stepper>\n * `\n * }\n */\n\n export default {\n name: 'step',\n };\n</script>\n\n<style lang=\"scss\" scoped src=\"./step.scss\" />\n"],"names":["useKeyboardNavigation","steps","focusOnStep","indexOffset","event","currentIndex","_a","focusOnPreviousStep","focusOnNextStep","BentoKeyboardNavigationKeyDownEvent","getStepPosition","stepState","listItemElement","listElement","useStepRegister","childrenSteps","position","step","STEPPER_STATE","BentoStepperTypeOption","BentoStepperTypeOption2","BentoStepperVariantOption","BentoStepperVariantOption2","__default__$1","messages","props","__props","emit","__emit","t","n","useI18n","ref","activeStepIndex","latestActiveStep","navigateToStep","index","currentStepContent","computed","stepsAmount","childrenStepsElements","buttonElement","isHorizontalVariant","allVisibleStepsElements","substeps","isStepActive","registerStep","removeStep","stepperState","conditionalClasses","watch","keyboardNavigationListeners","provide","readonly","__default__","slots","useSlots","buttonComponent","stepContent","stepper","inject","stepContentValue","substepsButtonElements","buttonElement2","activeSubStepIndex","latestActiveSubStepIndex","navigateToSubstep","value","onMounted","onBeforeUnmount","isSubstep","isFocused","isActive","isSubstepsVisible","isCompleted","isDisabled","ariaCurrentValue","ariaDisabledValue","tabIndexValue"],"mappings":";;;;;;;;;AAUa,MAAAA,KAAA,CAAAC,MAAA;AAET,WAAAC,EAAAC,GAAA;AACI,WAAA,CAAA,EAAA,QAAAC,EAAA,MAAA;;AACI,MAAAA,EAAA,eAAA;AAEA,YAAAC,IAAAJ,EAAA,MAAA,QAAA,SAAA,aAAA;AACA,MAAAI,IAAA,MAIAC,IAAAL,EAAA,MAAAI,IAAAF,CAAA,MAAA,QAAAG,EAAA;AAAA,IAA+C;AAAA,EACnD;AAGJ,QAAAC,IAAAL,EAAA,EAAA,GACAM,IAAAN,EAAA,CAAA;AAEA,SAAA;AAAA,IAAO,CAAAO,EAAA,UAAA,GAAAD;AAAA,IAC+C,CAAAC,EAAA,WAAA,GAAAD;AAAA,IACC,CAAAC,EAAA,QAAA,GAAAF;AAAA,IACH,CAAAE,EAAA,UAAA,GAAAF;AAA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;AAAA,MACZ,qBAAAE,EAAA;AAAA,MACM,mBAAAJ,EAAA;AAAA,IACJ,EAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"step.CxnmaTMe.js","sources":["../../../vue2/src/components/stepper/composables/use-keyboard-navigation/use-keyboard-navigation.ts","../../../vue2/src/components/stepper/composables/use-step-register/use-step-register.ts","../../../vue2/src/components/stepper/stepper.keys.ts","../../../vue2/src/components/stepper/stepper.types.ts","../../../vue2/src/components/stepper/stepper.vue","../../../vue2/src/components/stepper/components/step/step.vue"],"sourcesContent":["import { type Ref, type UnwrapRef } from 'vue';\n\nimport { BentoKeyboardNavigationKeyDownEvent } from '@/types/keyboard-navigation';\n\n/**\n * Returns keyboard navigation's event handlers to navigate through the steps\n *\n * @param steps the list of bento-steps DOM elements to focus on the navigation\n * @returns\n */\nexport const useKeyboardNavigation = (steps: Ref<UnwrapRef<Array<HTMLButtonElement>>>) => {\n // Returns the event handler that moves the focus on a given step offset\n function focusOnStep(indexOffset: number) {\n return ({ detail: event }) => {\n event.preventDefault();\n\n const currentIndex = steps.value.indexOf(document.activeElement as HTMLButtonElement);\n if (currentIndex < 0) {\n return;\n }\n\n steps.value[currentIndex + indexOffset]?.focus();\n };\n }\n\n const focusOnPreviousStep = focusOnStep(-1);\n const focusOnNextStep = focusOnStep(1);\n\n return {\n [BentoKeyboardNavigationKeyDownEvent.ARROW_DOWN]: focusOnNextStep,\n [BentoKeyboardNavigationKeyDownEvent.ARROW_RIGHT]: focusOnNextStep,\n [BentoKeyboardNavigationKeyDownEvent.ARROW_UP]: focusOnPreviousStep,\n [BentoKeyboardNavigationKeyDownEvent.ARROW_LEFT]: focusOnPreviousStep,\n };\n};\n","import type { Ref, UnwrapRef } from 'vue';\nimport type { BentoStepperStepExposeState } from '../../stepper.types';\n\n/**\n * Gets the position of a `bento-step` element within its `bento-stepper` parent.\n * @param stepState The `bento-step` state.\n * @returns The index of the element.\n */\nconst getStepPosition = (stepState: BentoStepperStepExposeState) => {\n // Button is wrapped by <li> element\n const listItemElement = (stepState.buttonElement as Ref<UnwrapRef<HTMLButtonElement>>).value.parentElement;\n const listElement = listItemElement.parentElement;\n return Array.from(listElement.children).indexOf(listItemElement);\n};\n\n/**\n * Provides methods to register/unregister `bento-step` elements to/from the `bento-stepper` step state.\n * These methods allow for tracking the child step elements, including their position in the DOM tree.\n * @param childrenSteps The `bento-stepper` (or `bento-step` if substeps) step state.\n */\nexport const useStepRegister = (childrenSteps: Ref<Array<BentoStepperStepExposeState>>) => {\n /**\n * Registers a step's HTML element in the stepper state.\n * Should be called by a `bento-step` when it is mounted.\n * @param stepState The `bento-step` state.\n */\n const registerStep = (stepState: BentoStepperStepExposeState) => {\n const position = getStepPosition(stepState);\n childrenSteps.value.splice(position, 0, {\n stepContent: stepState.stepContent as string,\n buttonElement: stepState.buttonElement as HTMLButtonElement,\n substeps: stepState.substeps as Array<BentoStepperStepExposeState>,\n });\n };\n\n /**\n * Unregisters a step's HTML element in the stepper state.\n * Should be called by a `bento-step` before it is unmounted.\n * @param stepState The `bento-step` state.\n */\n const removeStep = (stepState: BentoStepperStepExposeState) => {\n childrenSteps.value.splice(\n childrenSteps.value.findIndex(step => step.buttonElement === stepState.buttonElement.value),\n 1\n );\n };\n\n return { registerStep, removeStep };\n};\n","export const STEPPER_STATE = Symbol('stepper state');\n","import type { ComputedRef, Ref, UnwrapRef } from 'vue';\n\nexport enum BentoStepperTypeOption {\n LINEAR = 'linear',\n NON_LINEAR = 'non-linear',\n}\n\nexport enum BentoStepperVariantOption {\n HORIZONTAL = 'horizontal',\n VERTICAL = 'vertical',\n}\n\nexport interface BentoStepperStepExposeState {\n buttonElement: HTMLButtonElement | Ref<UnwrapRef<HTMLButtonElement>>;\n substeps: Array<BentoStepperStepExposeState> | Ref<Array<BentoStepperStepExposeState>>;\n stepContent: string | ComputedRef<string>;\n}\n\nexport type BentoStepperState = Ref<{\n activeStepIndex: number;\n latestActiveStep: number;\n type: `${BentoStepperTypeOption}`;\n variant: `${BentoStepperVariantOption}`;\n steps: Array<HTMLElement>;\n isParentStep?: boolean;\n navigateToStep: (index: number) => void;\n registerStep: (stepState: BentoStepperStepExposeState) => void;\n removeStep: (stepState: BentoStepperStepExposeState) => void;\n}>;\n","<template>\n <nav class=\"b-stepper\">\n <ol\n v-bento-keyboard-navigation-directive\n class=\"b-stepper__list\"\n :class=\"conditionalClasses\"\n v-on=\"keyboardNavigationListeners\"\n >\n <slot></slot>\n </ol>\n\n <bento-typography el=\"span\" variant=\"body\" stronger class=\"b-stepper__text-stepper\"\n >{{\n t('step', {\n currentIndex: n(activeStepIndex + 1),\n totalSteps: n(stepsAmount),\n content: currentStepContent,\n })\n }}\n </bento-typography>\n </nav>\n</template>\n\n<script setup lang=\"ts\">\n import { BentoTypography } from '@/components/typography';\n\n import { computed, type DeepReadonly, type PropType, provide, readonly, ref, watch } from 'vue';\n import { BentoKeyboardNavigationDirective as vBentoKeyboardNavigationDirective } from '@/directives';\n\n import { useKeyboardNavigation, useStepRegister } from './composables';\n import { useI18n } from '@/utils/ts/i18n';\n\n import { STEPPER_STATE } from './stepper.keys';\n import {\n type BentoStepperState,\n type BentoStepperStepExposeState,\n type BentoStepperTypeOption,\n BentoStepperVariantOption,\n } from './stepper.types';\n\n import messages from './messages.json';\n\n const props = defineProps({\n /**\n * Type of stepper; defines how the stepper should behave. Default: linear\n * @values linear, non-linear\n */\n type: {\n type: String as PropType<`${BentoStepperTypeOption}`>,\n default: 'linear',\n },\n /**\n * Stepper variant; defines how the stepper should be displayed. Default: vertical\n * @values vertical, horizontal\n */\n variant: {\n type: String as PropType<`${BentoStepperVariantOption}`>,\n default: 'vertical',\n },\n /**\n * Active step index\n */\n index: {\n type: Number,\n default: 0,\n },\n });\n\n const emit = defineEmits<{\n /**\n * Event triggered when step is updated by the stepper\n */\n (e: 'update:index', index: number): void;\n }>();\n\n type MessageSchema = (typeof messages)['en-US'];\n const { t, n } = useI18n<{ message: MessageSchema }>({ messages });\n\n const childrenSteps = ref<Array<BentoStepperStepExposeState>>([]);\n const activeStepIndex = ref(props.index);\n const latestActiveStep = ref(activeStepIndex.value);\n\n const navigateToStep = (index: number) => {\n // Stores latest active step index so users can navigate backwards and forwards on linear stepper\n if (index > latestActiveStep.value) {\n latestActiveStep.value = index;\n }\n activeStepIndex.value = index;\n };\n\n const currentStepContent = computed(() => childrenSteps.value[activeStepIndex.value]?.stepContent);\n const stepsAmount = computed(() => childrenSteps.value.length);\n const childrenStepsElements = computed(() => childrenSteps.value.map(({ buttonElement }) => buttonElement));\n const isHorizontalVariant = computed(() => props.variant === BentoStepperVariantOption.HORIZONTAL);\n\n // List of all visible steps nested on the stepper, including the substeps of the children steps\n // Flattening the steps on a single list makes the keyboard navigation easier to be handled\n const allVisibleStepsElements = computed(() =>\n childrenSteps.value\n .map(({ buttonElement, substeps }, index) => {\n const isStepActive = activeStepIndex.value === index;\n const isSubstepsVisible = !isHorizontalVariant.value && isStepActive;\n\n if (!isSubstepsVisible) {\n return [buttonElement];\n }\n\n return [buttonElement].concat(substeps.map(step => step.buttonElement));\n })\n .flat()\n );\n\n const { registerStep, removeStep } = useStepRegister(childrenSteps);\n\n const stepperState: BentoStepperState = ref({\n activeStepIndex,\n latestActiveStep,\n steps: childrenStepsElements,\n type: props.type,\n variant: props.variant,\n navigateToStep,\n registerStep,\n removeStep,\n });\n\n const conditionalClasses = computed(() => ({\n 'b-stepper__list--horizontal': isHorizontalVariant.value,\n }));\n\n watch(() => props.index, navigateToStep);\n watch(activeStepIndex, index => {\n emit('update:index', index);\n });\n\n const keyboardNavigationListeners = useKeyboardNavigation(allVisibleStepsElements);\n\n // Provides stepper state to BentoStep children components\n provide<DeepReadonly<BentoStepperState>>(STEPPER_STATE, readonly(stepperState));\n</script>\n\n<script lang=\"ts\">\n /**\n * Steppers break down complex processes into manageable steps to guide users through a sequential or multi-step process.\n *\n * @example\n * import { BentoStep, BentoStepper } from '@adyen/bento-vue2';\n *\n * export default {\n * components: { BentoStep, BentoStepper },\n * template: `\n * <bento-stepper :index=\"1\">\n * <bento-step>Step 1</bento-step>\n * <bento-step>Step 2</bento-step>\n * <bento-step>Step 3</bento-step>\n * </bento-stepper>\n * `\n * }\n */\n\n export default {\n i18n: { messages },\n name: 'stepper',\n };\n</script>\n\n<style scoped src=\"./stepper.scss\" />\n","<template>\n <li :class=\"conditionalClasses\" class=\"b-step\">\n <base-button\n ref=\"buttonComponent\"\n :aria-current=\"ariaCurrentValue\"\n :aria-disabled=\"ariaDisabledValue\"\n class=\"b-step__button\"\n type=\"button\"\n :tabindex=\"tabIndexValue\"\n :disabled=\"isDisabled\"\n @click=\"navigateToStep\"\n @focus=\"isFocused = true\"\n @blur=\"isFocused = false\"\n >\n <template #iconLeft>\n <bento-typography el=\"span\" variant=\"body\" stronger class=\"b-step__index\" aria-hidden=\"true\">\n <checkmark-small-icon v-if=\"isCompleted\" />\n <template v-else-if=\"!isSubstep\">{{ index + 1 }}</template>\n <dot-icon v-else />\n </bento-typography>\n </template>\n\n <bento-typography ref=\"stepContent\" el=\"span\" variant=\"body\" :stronger=\"isActive\" class=\"b-step__content\">\n <slot></slot>\n </bento-typography>\n </base-button>\n\n <ul v-show=\"isSubstepsVisible\" ref=\"substepList\" class=\"b-step__substep-list\">\n <slot name=\"substeps\"></slot>\n </ul>\n </li>\n</template>\n\n<script setup lang=\"ts\">\n import { computed, inject, onBeforeUnmount, onMounted, provide, ref, useSlots, watch } from 'vue';\n import { BaseButton } from '@/components/internal/base-button';\n import { BentoTypography } from '@/components/typography';\n import CheckmarkSmallIcon from '@adyen/ui-assets-icons-16/vue/checkmark-small';\n import DotIcon from '@adyen/ui-assets-icons-16/vue/dot';\n\n import { useStepRegister } from '../../composables';\n import { STEPPER_STATE } from '../../stepper.keys';\n import {\n type BentoStepperState,\n type BentoStepperStepExposeState,\n BentoStepperTypeOption,\n BentoStepperVariantOption,\n } from '../../stepper.types';\n import { type Booleanish } from '@/types/prop-types';\n\n const slots = useSlots();\n\n const props = defineProps({\n /**\n * Completed status. Used on non-linear steppers to indicate if the step is completed.\n */\n completed: {\n type: Boolean,\n default: false,\n },\n /**\n * Active substep index\n */\n substepIndex: {\n type: Number,\n default: 0,\n },\n });\n\n const emit = defineEmits<{\n /**\n * Event triggered when substep is updated by the parent step\n */\n (e: 'update:substep-index', index: number): void;\n }>();\n\n // Element refs\n const buttonComponent = ref<InstanceType<typeof BaseButton> | null>(null);\n const stepContent = ref<InstanceType<typeof BentoTypography> | null>(null);\n const substeps = ref<Array<BentoStepperStepExposeState>>([]);\n\n // Injects parent BentoStepper state data\n const stepper = inject<BentoStepperState>(STEPPER_STATE);\n\n const buttonElement = computed(() => buttonComponent.value?.$el as HTMLButtonElement);\n const index = computed(() => stepper?.value.steps.indexOf(buttonElement.value));\n\n const stepContentValue = computed(() => stepContent.value?.$el.textContent);\n\n // Substep logic\n const substepsButtonElements = computed(() => substeps.value.map(({ buttonElement }) => buttonElement));\n\n const activeSubStepIndex = ref(props.substepIndex);\n const latestActiveSubStepIndex = ref(activeSubStepIndex.value);\n\n const navigateToSubstep = (value: number) => {\n if (value > latestActiveSubStepIndex.value) {\n latestActiveSubStepIndex.value = value;\n }\n\n activeSubStepIndex.value = value;\n };\n\n const { registerStep, removeStep } = useStepRegister(substeps);\n\n const stepState: BentoStepperState = ref({\n activeStepIndex: activeSubStepIndex,\n latestActiveStep: latestActiveSubStepIndex,\n type: stepper.value.type,\n variant: stepper.value.variant,\n steps: substepsButtonElements,\n isParentStep: true,\n navigateToStep: navigateToSubstep,\n registerStep,\n removeStep,\n });\n\n provide(STEPPER_STATE, stepState);\n\n watch(() => props.substepIndex, navigateToSubstep);\n watch(activeSubStepIndex, value => {\n emit('update:substep-index', value);\n });\n\n onMounted(() => {\n if (!stepper) {\n throw new Error(\n 'BentoStep components should only be used inside BentoStepper or other BentoStep components.'\n );\n }\n\n stepper.value.registerStep({\n buttonElement,\n stepContent: stepContentValue,\n substeps,\n });\n });\n\n onBeforeUnmount(() => {\n stepper.value.removeStep({\n buttonElement,\n stepContent: stepContentValue,\n substeps,\n });\n });\n\n // Step states\n const isSubstep = computed(() => stepper.value.isParentStep);\n const isFocused = ref(false);\n const isActive = computed(() => stepper?.value.activeStepIndex === index.value);\n const isSubstepsVisible = computed(\n () =>\n isActive.value &&\n stepper.value.variant !== BentoStepperVariantOption.HORIZONTAL &&\n !isSubstep.value &&\n slots.substeps\n );\n const isCompleted = computed(() => {\n if (stepper?.value.type === BentoStepperTypeOption.NON_LINEAR) {\n return props.completed;\n }\n\n return stepper?.value.latestActiveStep > index.value;\n });\n const isDisabled = computed(\n () => stepper?.value.type === BentoStepperTypeOption.LINEAR && index.value > stepper?.value.latestActiveStep\n );\n\n const navigateToStep = () => {\n if (isDisabled.value) {\n return;\n }\n\n stepper.value.navigateToStep(index.value);\n };\n\n // Styling and a11y\n const ariaCurrentValue = computed(() => (isActive.value ? 'step' : ('false' as Booleanish)));\n const ariaDisabledValue = computed(() => isDisabled.value.toString() as Booleanish);\n const tabIndexValue = computed(() => (isFocused.value || (index.value === 0 && !isSubstep.value) ? '0' : '-1'));\n\n const conditionalClasses = computed(() => ({\n 'b-step--active': isActive.value,\n 'b-step--completed': isCompleted.value,\n 'b-step--substep': isSubstep.value,\n }));\n</script>\n\n<script lang=\"ts\">\n /**\n * Steps are components placed inside BentoSteppers to break down complex processes\n *\n * @example\n * import { BentoStep } from '@adyen/bento-vue2';\n *\n * export default {\n * components: { BentoStep },\n * template: `\n * <bento-stepper>\n * <bento-step>Step 1</bento-step>\n * <bento-step>\n * Step 2\n * <template #substeps>\n * <bento-step>Substep 1</bento-step>\n * <bento-step>Substep 2</bento-step>\n * </template>\n * </bento-step>\n * </bento-stepper>\n * `\n * }\n */\n\n export default {\n name: 'step',\n };\n</script>\n\n<style lang=\"scss\" scoped src=\"./step.scss\" />\n"],"names":["useKeyboardNavigation","steps","focusOnStep","indexOffset","event","currentIndex","_a","focusOnPreviousStep","focusOnNextStep","BentoKeyboardNavigationKeyDownEvent","getStepPosition","stepState","listItemElement","listElement","useStepRegister","childrenSteps","position","step","STEPPER_STATE","BentoStepperTypeOption","BentoStepperTypeOption2","BentoStepperVariantOption","BentoStepperVariantOption2","__default__$1","messages","props","__props","emit","__emit","t","n","useI18n","ref","activeStepIndex","latestActiveStep","navigateToStep","index","currentStepContent","computed","stepsAmount","childrenStepsElements","buttonElement","isHorizontalVariant","allVisibleStepsElements","substeps","isStepActive","registerStep","removeStep","stepperState","conditionalClasses","watch","keyboardNavigationListeners","provide","readonly","__default__","slots","useSlots","buttonComponent","stepContent","stepper","inject","stepContentValue","substepsButtonElements","buttonElement2","activeSubStepIndex","latestActiveSubStepIndex","navigateToSubstep","value","onMounted","onBeforeUnmount","isSubstep","isFocused","isActive","isSubstepsVisible","isCompleted","isDisabled","ariaCurrentValue","ariaDisabledValue","tabIndexValue"],"mappings":";;;;;;;;;AAUa,MAAAA,KAAA,CAAAC,MAAA;AAET,WAAAC,EAAAC,GAAA;AACI,WAAA,CAAA,EAAA,QAAAC,EAAA,MAAA;;AACI,MAAAA,EAAA,eAAA;AAEA,YAAAC,IAAAJ,EAAA,MAAA,QAAA,SAAA,aAAA;AACA,MAAAI,IAAA,MAIAC,IAAAL,EAAA,MAAAI,IAAAF,CAAA,MAAA,QAAAG,EAAA;AAAA,IAA+C;AAAA,EACnD;AAGJ,QAAAC,IAAAL,EAAA,EAAA,GACAM,IAAAN,EAAA,CAAA;AAEA,SAAA;AAAA,IAAO,CAAAO,EAAA,UAAA,GAAAD;AAAA,IAC+C,CAAAC,EAAA,WAAA,GAAAD;AAAA,IACC,CAAAC,EAAA,QAAA,GAAAF;AAAA,IACH,CAAAE,EAAA,UAAA,GAAAF;AAAA,EACE;AAE1D,GC1BAG,KAAA,CAAAC,MAAA;AAEI,QAAAC,IAAAD,EAAA,cAAA,MAAA,eACAE,IAAAD,EAAA;AACA,SAAA,MAAA,KAAAC,EAAA,QAAA,EAAA,QAAAD,CAA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0 +1,111 @@
1
+ import { defineComponent as h, inject as p, computed as o, provide as U, createElementBlock as v, openBlock as r, renderSlot as S, ref as $, normalizeClass as _, createElementVNode as f, normalizeStyle as g, createVNode as y, createBlock as u, createCommentVNode as d, unref as e, withCtx as b, createTextVNode as A, toDisplayString as R, withDirectives as V } from "vue";
2
+ import { _ as B } from "./_plugin-vue_export-helper.CHgC5LLL.js";
3
+ import { B as j } from "./button.DhcxX2GJ.js";
4
+ import { B as O } from "./info-icon.DB0MI-dH.js";
5
+ import { B as w } from "./typography.yBEME_Gu.js";
6
+ import { C as F } from "./copy.mq0o1Rag.js";
7
+ import { S as H } from "./search.PczW-onY.js";
8
+ import { u as J } from "./index.pdBj0KQU.js";
9
+ import { b as x } from "./tooltip.CeX5eGnw.js";
10
+ import "../assets/structured-list-item.css";
11
+ const C = /* @__PURE__ */ Symbol("structured list condensed style injection key"), T = /* @__PURE__ */ Symbol("structured list labels width injection key"), z = ["25-75", "33-66", "42-58", "50-50", "75-25", "66-33", "58-42"], K = { class: "b-structured-list" }, Y = {}, P = /* @__PURE__ */ h({
12
+ ...Y,
13
+ __name: "structured-list",
14
+ props: {
15
+ labelsWidth: { default: null },
16
+ layout: { default: "33-66" }
17
+ },
18
+ setup(n) {
19
+ const s = n, m = p(C, !1), a = o(
20
+ () => z.includes(s.layout) ? s.layout : "33-66"
21
+ ), c = o(() => m ? "130px" : s.labelsWidth ? `${s.labelsWidth}px` : `${a.value.split("-")[0]}%`);
22
+ return U(T, c), (l, i) => (r(), v("dl", K, [
23
+ S(l.$slots, "default", {}, void 0, !0)
24
+ ]));
25
+ }
26
+ }), lt = /* @__PURE__ */ B(P, [["__scopeId", "data-v-04bc4474"]]), I = {
27
+ "en-US": {
28
+ search: "Search"
29
+ },
30
+ "ja-JP": {
31
+ search: "検索"
32
+ },
33
+ "pt-BR": {
34
+ search: "Buscar"
35
+ }
36
+ }, q = {
37
+ i18n: { messages: I }
38
+ }, G = /* @__PURE__ */ h({
39
+ ...q,
40
+ __name: "structured-list-item",
41
+ props: {
42
+ label: {},
43
+ labelInfo: {},
44
+ copy: {},
45
+ search: { type: Function },
46
+ searchTooltip: {},
47
+ truncate: { type: Boolean }
48
+ },
49
+ emits: ["copy"],
50
+ setup(n, { emit: s }) {
51
+ const a = n, c = s, { t: l } = J({ messages: I }), i = p(C, !1), L = p(T, $("33%")), E = o(() => `flex-basis:${L.value}`), D = o(() => ({
52
+ "b-structured-list-item--condensed": i
53
+ })), k = o(() => ({
54
+ "b-structured-list-item__value--truncate": a.truncate
55
+ })), N = () => {
56
+ c("copy", a.copy);
57
+ }, W = o(() => i ? "caption" : "body");
58
+ return (t, M) => (r(), v("div", {
59
+ class: _(["b-structured-list-item", D.value])
60
+ }, [
61
+ f("dt", {
62
+ class: "b-structured-list-item__label",
63
+ style: g(E.value)
64
+ }, [
65
+ y(e(w), { variant: W.value }, {
66
+ default: b(() => [
67
+ A(R(t.label), 1)
68
+ ]),
69
+ _: 1
70
+ }, 8, ["variant"]),
71
+ t.labelInfo ? (r(), u(e(O), {
72
+ key: 0,
73
+ class: "b-structured-list-item__icon",
74
+ "tooltip-text": t.labelInfo
75
+ }, null, 8, ["tooltip-text"])) : d("", !0)
76
+ ], 4),
77
+ f("dd", {
78
+ class: _(["b-structured-list-item__value", k.value])
79
+ }, [
80
+ S(t.$slots, "default", {}, void 0, !0),
81
+ t.copy ? (r(), u(F, {
82
+ key: 0,
83
+ class: "b-structured-list-item__icon",
84
+ text: t.copy,
85
+ onClick: N
86
+ }, null, 8, ["text"])) : d("", !0),
87
+ t.search ? V((r(), u(e(j), {
88
+ key: 1,
89
+ class: "b-structured-list-item__icon",
90
+ variant: "tertiary",
91
+ onClick: t.search
92
+ }, {
93
+ iconLeft: b(() => [
94
+ y(e(H), {
95
+ "svg-title": e(l)("search")
96
+ }, null, 8, ["svg-title"])
97
+ ]),
98
+ _: 1
99
+ }, 8, ["onClick"])), [
100
+ [e(x), t.searchTooltip ? t.searchTooltip : e(l)("search"), "top"]
101
+ ]) : d("", !0)
102
+ ], 2)
103
+ ], 2));
104
+ }
105
+ }), nt = /* @__PURE__ */ B(G, [["__scopeId", "data-v-f3ee58a1"]]);
106
+ export {
107
+ lt as B,
108
+ C as S,
109
+ nt as a
110
+ };
111
+ //# sourceMappingURL=structured-list-item.DjbvVIwI.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"structured-list-item.BTPh7SPj.js","sources":["../../../vue2/src/components/structured-list/structured-list.keys.ts","../../../vue2/src/components/structured-list/structured-list.types.ts","../../../vue2/src/components/structured-list/structured-list.vue","../../../vue2/src/components/structured-list/components/structered-list-item/structured-list-item.vue"],"sourcesContent":["export const STRUCTURED_LIST_CONDENSED_INJECTION_KEY = Symbol('structured list condensed style injection key');\nexport const STRUCTURED_LIST_LABELS_WIDTH_INJECTION_KEY = Symbol('structured list labels width injection key');\n","export type BentoStructuredListLayoutOptions = '25-75' | '33-66' | '42-58' | '50-50' | '75-25' | '66-33' | '58-42';\nexport const BentoStructuredListLayoutOptions = ['25-75', '33-66', '42-58', '50-50', '75-25', '66-33', '58-42'];\n","<template>\n <dl class=\"b-structured-list\">\n <slot />\n </dl>\n</template>\n\n<script setup lang=\"ts\">\n import { computed, inject, provide } from 'vue';\n import {\n STRUCTURED_LIST_CONDENSED_INJECTION_KEY,\n STRUCTURED_LIST_LABELS_WIDTH_INJECTION_KEY,\n } from '@/components/structured-list/structured-list.keys';\n import { BentoStructuredListLayoutOptions } from './structured-list.types';\n\n const props = withDefaults(\n defineProps<{\n /**\n * Width of the labels container, in pixels. Overrides layout prop.\n */\n labelsWidth?: number;\n /**\n * The layout of the label value pair in percentage.\n * If labelsWidth is set, layout will be overriden by the static pixel value.\n *\n * If the value entered is not listed in the example\n * list below '33-66' will be applied\n * @example\n * '25-75'\n * '33-66'\n * '42-58'\n * '50-50'\n * '75-25'\n * '66-33'\n * '58-42'\n */\n layout?: BentoStructuredListLayoutOptions;\n }>(),\n {\n labelsWidth: null,\n layout: '33-66',\n }\n );\n\n const isCondensed = inject(STRUCTURED_LIST_CONDENSED_INJECTION_KEY, false);\n\n const computedLayout = computed(() =>\n BentoStructuredListLayoutOptions.includes(props.layout) ? props.layout : '33-66'\n );\n\n const computedLabelsWidth = computed(() => {\n if (isCondensed) {\n return '130px';\n }\n\n if (props.labelsWidth) {\n return `${props.labelsWidth}px`;\n }\n\n return `${computedLayout.value.split('-')[0]}%`;\n });\n\n provide(STRUCTURED_LIST_LABELS_WIDTH_INJECTION_KEY, computedLabelsWidth);\n</script>\n\n<script lang=\"ts\">\n /**\n * This is a list used to display pairs of information in a clear and organized manner.\n * `BentoStructureListItem` should be used to pass the label/value pairs to the list.\n *\n * @example\n * import { BentoStructuredListItem, BentoStructuredListItem } from '@adyen/bento-vue2';\n *\n * export default {\n * components: { BentoStructuredList, BentoStructuredListItem },\n * template: `\n * <bento-structured-list>\n * <bento-structured-list-item label=\"Payment\">\n * <bento-payment-method label=\"Klarna\" type=\"Klarna\" />\n * </bento-structured-list-item>\n * <bento-structured-list-item label=\"Amount\">\n * <bento-currency :currency=\"BentoCurrencyISOCode.USD\" :value=\"123456\" />\n * </bento-structured-list-item>\n * </bento-structured-list>\n * `\n * }\n */\n export default {};\n</script>\n\n<style lang=\"scss\" scoped src=\"./structured-list.scss\" />\n","<template>\n <div class=\"b-structured-list-item\" :class=\"conditionalClasses\">\n <dt class=\"b-structured-list-item__label\" :style=\"computedLabelStyle\">\n <bento-typography :variant=\"labelTypographyVariant\">{{ label }}</bento-typography>\n <bento-info-icon v-if=\"labelInfo\" class=\"b-structured-list-item__icon\" :tooltip-text=\"labelInfo\" />\n </dt>\n <dd class=\"b-structured-list-item__value\" :class=\"valueConditionalClasses\">\n <slot />\n <copy v-if=\"copy\" class=\"b-structured-list-item__icon\" :text=\"copy\" @click=\"emitCopy\" />\n <bento-button\n v-if=\"search\"\n v-bento-tooltip-directive:top=\"searchTooltip ? searchTooltip : t('search')\"\n class=\"b-structured-list-item__icon\"\n variant=\"tertiary\"\n @click=\"search\"\n >\n <template #iconLeft>\n <search-icon :svg-title=\"t('search')\" />\n </template>\n </bento-button>\n </dd>\n </div>\n</template>\n\n<script setup lang=\"ts\">\n import { computed, inject, ref, type Ref } from 'vue';\n\n // Components\n import { BentoButton } from '@/components/button';\n import { BentoInfoIcon } from '@/components/info-icon';\n import { BentoTypography } from '@/components/typography';\n import Copy from '@/components/internal/copy/copy.vue';\n import SearchIcon from '@adyen/ui-assets-icons-16/vue/search';\n\n // Utils\n import { useI18n } from '@/utils/ts/i18n';\n\n // Directives\n import { BentoTooltipDirective as vBentoTooltipDirective } from '@/directives';\n\n // Keys\n import {\n STRUCTURED_LIST_CONDENSED_INJECTION_KEY,\n STRUCTURED_LIST_LABELS_WIDTH_INJECTION_KEY,\n } from '../../structured-list.keys';\n\n import messages from '../../messages.json';\n\n type MessageSchema = (typeof messages)['en-US'];\n\n const DEFAULT_LABELS_WIDTH = '33%';\n\n const props = defineProps<{\n /**\n * Label to display for the value\n */\n label: string;\n /**\n * Text to display in info icon tooltip in the label to display for the value\n */\n labelInfo?: string;\n /**\n * Text to copy when the user clicks `Copy` icon\n */\n copy?: string;\n /**\n * Function to trigger when user clicks `Search` icon\n */\n search?: (event: Event) => void;\n /**\n * Text to display when the user hovers over `Search` icon\n */\n searchTooltip?: string;\n /**\n * Truncates the value of the item\n */\n truncate?: boolean;\n }>();\n\n const emit = defineEmits<{\n /**\n * Emits copy event and value when copy button is clicked\n */\n (e: 'copy', value: string): void;\n }>();\n\n const { t } = useI18n<{ message: MessageSchema }>({ messages });\n const isCondensed = inject(STRUCTURED_LIST_CONDENSED_INJECTION_KEY, false);\n const labelsWidth = inject<Ref<string>>(STRUCTURED_LIST_LABELS_WIDTH_INJECTION_KEY, ref(DEFAULT_LABELS_WIDTH));\n const computedLabelStyle = computed(() => `flex-basis:${labelsWidth.value}`);\n const conditionalClasses = computed(() => ({\n 'b-structured-list-item--condensed': isCondensed,\n }));\n\n const valueConditionalClasses = computed(() => ({\n 'b-structured-list-item__value--truncate': props.truncate,\n }));\n\n const emitCopy = () => {\n emit('copy', props.copy);\n };\n\n const labelTypographyVariant = computed(() => (isCondensed ? 'caption' : 'body'));\n</script>\n\n<script lang=\"ts\">\n /**\n * This is an item of the `BentoStructuredList` meant to be used only with that component.\n * It consists of a label/value pair, and also the optional copy and search modifiers.\n *\n * @example\n * import { BentoCurrencyISOCode, BentoStructuredListItem, BentoStructuredListItem } from '@adyen/bento-vue2';\n *\n * export default {\n * components: { BentoStructuredListItem, BentoStructuredListItem },\n * template: `\n * <bento-structured-list>\n * <bento-structured-list-item label=\"Shopper\" search='searchShopper' search-tooltip='Find shopper'>\n * <bento-typography>\n * 143442642\n * </bento-status>\n * </bento-structured-list-item>\n * <bento-structured-list-item label=\"Amount\" copy='123456'>\n * <bento-currency :currency=\"BentoCurrencyISOCode.USD\" :value=\"123456\" />\n * </bento-structured-list-item>\n * </bento-structured-list>\n * `\n * }\n */\n export default {\n i18n: { messages },\n };\n</script>\n\n<style lang=\"scss\" scoped src=\"./structured-list-item.scss\" />\n"],"names":["STRUCTURED_LIST_CONDENSED_INJECTION_KEY","STRUCTURED_LIST_LABELS_WIDTH_INJECTION_KEY","BentoStructuredListLayoutOptions","__default__$1","props","__props","isCondensed","inject","computedLayout","computed","computedLabelsWidth","provide","__default__","messages","DEFAULT_LABELS_WIDTH","emit","__emit","t","useI18n","labelsWidth","ref","computedLabelStyle","conditionalClasses","valueConditionalClasses","emitCopy","labelTypographyVariant"],"mappings":";;;;;;;;;;AAAa,MAAAA,IAAA,OAAA,+CAAA,GACAC,IAAA,OAAA,4CAAA,GCAAC,IAAA,CAAA,SAAA,SAAA,SAAA,SAAA,SAAA,SAAA,OAAA,uCCqFTC,IAAA,CAAA;;;;;;;;AAxEA,UAAAC,IAAAC,GA6BAC,IAAAC,EAAAP,GAAA,EAAA,GAEAQ,IAAAC;AAAA,MAAuB,MAAAP,EAAA,SAAAE,EAAA,MAAA,IAAAA,EAAA,SAAA;AAAA,IACsD,GAG7EM,IAAAD,EAAA,MACIH,IACI,UAGJF,EAAA,cACI,GAAAA,EAAA,WAAA,OAGJ,GAAAI,EAAA,MAAA,MAAA,GAAA,EAAA,CAAA,CAAA,GAA4C;AAGhD,WAAAG,EAAAV,GAAAS,CAAA;;;;;;;;;;;;;;GCoEAE,IAAA;AAAA,EAAe,MAAA,EAAA,UAAAC,EAAA;AAEf;;;;;;;;;;;;;AAjFA,UAAAC,IAAA,OAEAV,IAAAC,GA2BAU,IAAAC,GAOA,EAAA,GAAAC,EAAA,IAAAC,EAAA,EAAA,UAAAL,EAAA,CAAA,GACAP,IAAAC,EAAAP,GAAA,EAAA,GACAmB,IAAAZ,EAAAN,GAAAmB,EAAAN,CAAA,CAAA,GACAO,IAAAZ,EAAA,MAAA,cAAAU,EAAA,KAAA,EAAA,GACAG,IAAAb,EAAA,OAAA;AAAA,MAA2C,qCAAAH;AAAA,IACF,EAAA,GAGzCiB,IAAAd,EAAA,OAAA;AAAA,MAAgD,2CAAAL,EAAA;AAAA,IACK,EAAA,GAGrDoB,IAAA,MAAA;AACI,MAAAT,EAAA,QAAAX,EAAA,IAAA;AAAA,IAAuB,GAG3BqB,IAAAhB,EAAA,MAAAH,IAAA,YAAA,MAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"structured-list-item.DjbvVIwI.js","sources":["../../../vue2/src/components/structured-list/structured-list.keys.ts","../../../vue2/src/components/structured-list/structured-list.types.ts","../../../vue2/src/components/structured-list/structured-list.vue","../../../vue2/src/components/structured-list/components/structered-list-item/structured-list-item.vue"],"sourcesContent":["export const STRUCTURED_LIST_CONDENSED_INJECTION_KEY = Symbol('structured list condensed style injection key');\nexport const STRUCTURED_LIST_LABELS_WIDTH_INJECTION_KEY = Symbol('structured list labels width injection key');\n","export type BentoStructuredListLayoutOptions = '25-75' | '33-66' | '42-58' | '50-50' | '75-25' | '66-33' | '58-42';\nexport const BentoStructuredListLayoutOptions = ['25-75', '33-66', '42-58', '50-50', '75-25', '66-33', '58-42'];\n","<template>\n <dl class=\"b-structured-list\">\n <slot />\n </dl>\n</template>\n\n<script setup lang=\"ts\">\n import { computed, inject, provide } from 'vue';\n import {\n STRUCTURED_LIST_CONDENSED_INJECTION_KEY,\n STRUCTURED_LIST_LABELS_WIDTH_INJECTION_KEY,\n } from '@/components/structured-list/structured-list.keys';\n import { BentoStructuredListLayoutOptions } from './structured-list.types';\n\n const props = withDefaults(\n defineProps<{\n /**\n * Width of the labels container, in pixels. Overrides layout prop.\n */\n labelsWidth?: number;\n /**\n * The layout of the label value pair in percentage.\n * If labelsWidth is set, layout will be overriden by the static pixel value.\n *\n * If the value entered is not listed in the example\n * list below '33-66' will be applied\n * @example\n * '25-75'\n * '33-66'\n * '42-58'\n * '50-50'\n * '75-25'\n * '66-33'\n * '58-42'\n */\n layout?: BentoStructuredListLayoutOptions;\n }>(),\n {\n labelsWidth: null,\n layout: '33-66',\n }\n );\n\n const isCondensed = inject(STRUCTURED_LIST_CONDENSED_INJECTION_KEY, false);\n\n const computedLayout = computed(() =>\n BentoStructuredListLayoutOptions.includes(props.layout) ? props.layout : '33-66'\n );\n\n const computedLabelsWidth = computed(() => {\n if (isCondensed) {\n return '130px';\n }\n\n if (props.labelsWidth) {\n return `${props.labelsWidth}px`;\n }\n\n return `${computedLayout.value.split('-')[0]}%`;\n });\n\n provide(STRUCTURED_LIST_LABELS_WIDTH_INJECTION_KEY, computedLabelsWidth);\n</script>\n\n<script lang=\"ts\">\n /**\n * This is a list used to display pairs of information in a clear and organized manner.\n * `BentoStructureListItem` should be used to pass the label/value pairs to the list.\n *\n * @example\n * import { BentoStructuredListItem, BentoStructuredListItem } from '@adyen/bento-vue2';\n *\n * export default {\n * components: { BentoStructuredList, BentoStructuredListItem },\n * template: `\n * <bento-structured-list>\n * <bento-structured-list-item label=\"Payment\">\n * <bento-payment-method label=\"Klarna\" type=\"Klarna\" />\n * </bento-structured-list-item>\n * <bento-structured-list-item label=\"Amount\">\n * <bento-currency :currency=\"BentoCurrencyISOCode.USD\" :value=\"123456\" />\n * </bento-structured-list-item>\n * </bento-structured-list>\n * `\n * }\n */\n export default {};\n</script>\n\n<style lang=\"scss\" scoped src=\"./structured-list.scss\" />\n","<template>\n <div class=\"b-structured-list-item\" :class=\"conditionalClasses\">\n <dt class=\"b-structured-list-item__label\" :style=\"computedLabelStyle\">\n <bento-typography :variant=\"labelTypographyVariant\">{{ label }}</bento-typography>\n <bento-info-icon v-if=\"labelInfo\" class=\"b-structured-list-item__icon\" :tooltip-text=\"labelInfo\" />\n </dt>\n <dd class=\"b-structured-list-item__value\" :class=\"valueConditionalClasses\">\n <slot />\n <copy v-if=\"copy\" class=\"b-structured-list-item__icon\" :text=\"copy\" @click=\"emitCopy\" />\n <bento-button\n v-if=\"search\"\n v-bento-tooltip-directive:top=\"searchTooltip ? searchTooltip : t('search')\"\n class=\"b-structured-list-item__icon\"\n variant=\"tertiary\"\n @click=\"search\"\n >\n <template #iconLeft>\n <search-icon :svg-title=\"t('search')\" />\n </template>\n </bento-button>\n </dd>\n </div>\n</template>\n\n<script setup lang=\"ts\">\n import { computed, inject, ref, type Ref } from 'vue';\n\n // Components\n import { BentoButton } from '@/components/button';\n import { BentoInfoIcon } from '@/components/info-icon';\n import { BentoTypography } from '@/components/typography';\n import Copy from '@/components/internal/copy/copy.vue';\n import SearchIcon from '@adyen/ui-assets-icons-16/vue/search';\n\n // Utils\n import { useI18n } from '@/utils/ts/i18n';\n\n // Directives\n import { BentoTooltipDirective as vBentoTooltipDirective } from '@/directives';\n\n // Keys\n import {\n STRUCTURED_LIST_CONDENSED_INJECTION_KEY,\n STRUCTURED_LIST_LABELS_WIDTH_INJECTION_KEY,\n } from '../../structured-list.keys';\n\n import messages from '../../messages.json';\n\n type MessageSchema = (typeof messages)['en-US'];\n\n const DEFAULT_LABELS_WIDTH = '33%';\n\n const props = defineProps<{\n /**\n * Label to display for the value\n */\n label: string;\n /**\n * Text to display in info icon tooltip in the label to display for the value\n */\n labelInfo?: string;\n /**\n * Text to copy when the user clicks `Copy` icon\n */\n copy?: string;\n /**\n * Function to trigger when user clicks `Search` icon\n */\n search?: (event: Event) => void;\n /**\n * Text to display when the user hovers over `Search` icon\n */\n searchTooltip?: string;\n /**\n * Truncates the value of the item\n */\n truncate?: boolean;\n }>();\n\n const emit = defineEmits<{\n /**\n * Emits copy event and value when copy button is clicked\n */\n (e: 'copy', value: string): void;\n }>();\n\n const { t } = useI18n<{ message: MessageSchema }>({ messages });\n const isCondensed = inject(STRUCTURED_LIST_CONDENSED_INJECTION_KEY, false);\n const labelsWidth = inject<Ref<string>>(STRUCTURED_LIST_LABELS_WIDTH_INJECTION_KEY, ref(DEFAULT_LABELS_WIDTH));\n const computedLabelStyle = computed(() => `flex-basis:${labelsWidth.value}`);\n const conditionalClasses = computed(() => ({\n 'b-structured-list-item--condensed': isCondensed,\n }));\n\n const valueConditionalClasses = computed(() => ({\n 'b-structured-list-item__value--truncate': props.truncate,\n }));\n\n const emitCopy = () => {\n emit('copy', props.copy);\n };\n\n const labelTypographyVariant = computed(() => (isCondensed ? 'caption' : 'body'));\n</script>\n\n<script lang=\"ts\">\n /**\n * This is an item of the `BentoStructuredList` meant to be used only with that component.\n * It consists of a label/value pair, and also the optional copy and search modifiers.\n *\n * @example\n * import { BentoCurrencyISOCode, BentoStructuredListItem, BentoStructuredListItem } from '@adyen/bento-vue2';\n *\n * export default {\n * components: { BentoStructuredListItem, BentoStructuredListItem },\n * template: `\n * <bento-structured-list>\n * <bento-structured-list-item label=\"Shopper\" search='searchShopper' search-tooltip='Find shopper'>\n * <bento-typography>\n * 143442642\n * </bento-status>\n * </bento-structured-list-item>\n * <bento-structured-list-item label=\"Amount\" copy='123456'>\n * <bento-currency :currency=\"BentoCurrencyISOCode.USD\" :value=\"123456\" />\n * </bento-structured-list-item>\n * </bento-structured-list>\n * `\n * }\n */\n export default {\n i18n: { messages },\n };\n</script>\n\n<style lang=\"scss\" scoped src=\"./structured-list-item.scss\" />\n"],"names":["STRUCTURED_LIST_CONDENSED_INJECTION_KEY","STRUCTURED_LIST_LABELS_WIDTH_INJECTION_KEY","BentoStructuredListLayoutOptions","__default__$1","props","__props","isCondensed","inject","computedLayout","computed","computedLabelsWidth","provide","__default__","messages","emit","__emit","t","useI18n","labelsWidth","ref","computedLabelStyle","conditionalClasses","valueConditionalClasses","emitCopy","labelTypographyVariant"],"mappings":";;;;;;;;;;AAAa,MAAAA,IAAA,uBAAA,+CAAA,GACAC,IAAA,uBAAA,4CAAA,GCAAC,IAAA,CAAA,SAAA,SAAA,SAAA,SAAA,SAAA,SAAA,OAAA,uCCqFTC,IAAA,CAAA;;;;;;;;AAxEA,UAAAC,IAAAC,GA6BAC,IAAAC,EAAAP,GAAA,EAAA,GAEAQ,IAAAC;AAAA,MAAuB,MAAAP,EAAA,SAAAE,EAAA,MAAA,IAAAA,EAAA,SAAA;AAAA,IACsD,GAG7EM,IAAAD,EAAA,MACIH,IACI,UAGJF,EAAA,cACI,GAAAA,EAAA,WAAA,OAGJ,GAAAI,EAAA,MAAA,MAAA,GAAA,EAAA,CAAA,CAAA,GAA4C;AAGhD,WAAAG,EAAAV,GAAAS,CAAA;;;;;;;;;;;;;;GCoEAE,IAAA;AAAA,EAAe,MAAA,EAAA,UAAAC,EAAA;AAEf;;;;;;;;;;;;;AA/EA,UAAAT,IAAAC,GA2BAS,IAAAC,GAOA,EAAA,GAAAC,EAAA,IAAAC,EAAA,EAAA,UAAAJ,EAAA,CAAA,GACAP,IAAAC,EAAAP,GAAA,EAAA,GACAkB,IAAAX,EAAAN,GAAAkB,EAAA,KAAA,CAAA,GACAC,IAAAX,EAAA,MAAA,cAAAS,EAAA,KAAA,EAAA,GACAG,IAAAZ,EAAA,OAAA;AAAA,MAA2C,qCAAAH;AAAA,IACF,EAAA,GAGzCgB,IAAAb,EAAA,OAAA;AAAA,MAAgD,2CAAAL,EAAA;AAAA,IACK,EAAA,GAGrDmB,IAAA,MAAA;AACI,MAAAT,EAAA,QAAAV,EAAA,IAAA;AAAA,IAAuB,GAG3BoB,IAAAf,EAAA,MAAAH,IAAA,YAAA,MAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -0,0 +1,6 @@
1
+ const o = /* @__PURE__ */ Symbol("summary-grid layout injection key"), s = /* @__PURE__ */ Symbol("summary-grid slashed zero key");
2
+ export {
3
+ o as S,
4
+ s as a
5
+ };
6
+ //# sourceMappingURL=summary-grid.keys.Xx-W5a2w.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"summary-grid.keys.CxTf_FOc.js","sources":["../../../vue2/src/components/summary-grid/summary-grid.keys.ts"],"sourcesContent":["export const SUMMARY_GRID_LAYOUT_INJECTION_KEY = Symbol('summary-grid layout injection key');\nexport const SUMMARY_GRID_SLASHED_ZERO = Symbol('summary-grid slashed zero key');\n"],"names":["SUMMARY_GRID_LAYOUT_INJECTION_KEY","SUMMARY_GRID_SLASHED_ZERO"],"mappings":"AAAa,MAAAA,IAAoC,OAAO,mCAAmC,GAC9EC,IAA4B,OAAO,+BAA+B;"}
1
+ {"version":3,"file":"summary-grid.keys.Xx-W5a2w.js","sources":["../../../vue2/src/components/summary-grid/summary-grid.keys.ts"],"sourcesContent":["export const SUMMARY_GRID_LAYOUT_INJECTION_KEY = Symbol('summary-grid layout injection key');\nexport const SUMMARY_GRID_SLASHED_ZERO = Symbol('summary-grid slashed zero key');\n"],"names":["SUMMARY_GRID_LAYOUT_INJECTION_KEY","SUMMARY_GRID_SLASHED_ZERO"],"mappings":"AAAa,MAAAA,2BAA2C,mCAAmC,GAC9EC,2BAAmC,+BAA+B;"}