@adyen/bento-vue3 2.0.1 → 2.1.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 (325) hide show
  1. package/dist/@types/bento-translation-keys.generated.d.ts +908 -0
  2. package/dist/@types/index.d.ts +136 -82
  3. package/dist/accordion.js +1 -1
  4. package/dist/action-bar.js +1 -1
  5. package/dist/ai-tag.js +1 -1
  6. package/dist/alert.js +1 -1
  7. package/dist/anchor-scroller.js +1 -1
  8. package/dist/assets/accordion-item.css +1 -1
  9. package/dist/assets/action-bar.css +1 -1
  10. package/dist/assets/base-modal.css +1 -1
  11. package/dist/assets/button-actions.css +1 -1
  12. package/dist/assets/button.css +1 -1
  13. package/dist/assets/calendar.css +1 -1
  14. package/dist/assets/card.css +1 -1
  15. package/dist/assets/checkbox.css +1 -1
  16. package/dist/assets/chip.css +1 -1
  17. package/dist/assets/currency.css +1 -1
  18. package/dist/assets/data-grid.css +1 -1
  19. package/dist/assets/date-range-picker.css +1 -1
  20. package/dist/assets/dialog-page.css +1 -1
  21. package/dist/assets/draggable.css +1 -1
  22. package/dist/assets/dropdown.css +1 -1
  23. package/dist/assets/file-uploader.css +1 -1
  24. package/dist/assets/filter-bar.css +1 -1
  25. package/dist/assets/header-with-views.css +1 -1
  26. package/dist/assets/input-field.css +1 -1
  27. package/dist/assets/input-time.css +1 -1
  28. package/dist/assets/inspector.css +1 -1
  29. package/dist/assets/modal-fullscreen.css +1 -1
  30. package/dist/assets/navigation-menu-group.css +1 -1
  31. package/dist/assets/pagination.css +1 -1
  32. package/dist/assets/rich-text-editor.css +1 -1
  33. package/dist/assets/search-bar.css +1 -1
  34. package/dist/assets/secondary-nav.css +1 -1
  35. package/dist/assets/selection-card-group.css +1 -1
  36. package/dist/assets/sidepanel.css +1 -1
  37. package/dist/assets/step.css +1 -1
  38. package/dist/assets/structured-list-item.css +1 -1
  39. package/dist/assets/tab.css +1 -1
  40. package/dist/assets/textarea.css +1 -1
  41. package/dist/assets/toggle.css +1 -1
  42. package/dist/assets/typography.css +1 -1
  43. package/dist/avatar.js +1 -1
  44. package/dist/button.js +3 -3
  45. package/dist/card.js +1 -1
  46. package/dist/checkbox.js +2 -2
  47. package/dist/chip.js +1 -1
  48. package/dist/chunks/{accordion-item.BMxeTYDy.js → accordion-item.BbMoC7Rn.js} +6 -6
  49. package/dist/chunks/{accordion-item.BMxeTYDy.js.map → accordion-item.BbMoC7Rn.js.map} +1 -1
  50. package/dist/chunks/{action-bar.CWjLoeOU.js → action-bar.C6XFuiE0.js} +20 -20
  51. package/dist/chunks/{action-bar.CWjLoeOU.js.map → action-bar.C6XFuiE0.js.map} +1 -1
  52. package/dist/chunks/{ai-button.CYaCMWFk.js → ai-button.M2xaszNl.js} +3 -3
  53. package/dist/chunks/{ai-button.CYaCMWFk.js.map → ai-button.M2xaszNl.js.map} +1 -1
  54. package/dist/chunks/{ai-tag.CjrOE5yl.js → ai-tag.BLDTP7fs.js} +4 -4
  55. package/dist/chunks/{ai-tag.CjrOE5yl.js.map → ai-tag.BLDTP7fs.js.map} +1 -1
  56. package/dist/chunks/{alert.C8Pe1-OO.js → alert.BYmn1ewo.js} +4 -4
  57. package/dist/chunks/{alert.C8Pe1-OO.js.map → alert.BYmn1ewo.js.map} +1 -1
  58. package/dist/chunks/{anchor-scroller.C3zkcfPH.js → anchor-scroller.B35-JMuH.js} +6 -6
  59. package/dist/chunks/{anchor-scroller.C3zkcfPH.js.map → anchor-scroller.B35-JMuH.js.map} +1 -1
  60. package/dist/chunks/{avatar.DcXyOCS4.js → avatar.Bes5Qw12.js} +2 -2
  61. package/dist/chunks/{avatar.DcXyOCS4.js.map → avatar.Bes5Qw12.js.map} +1 -1
  62. package/dist/chunks/{base-button.Bi5JR_6k.js → base-button.Dg_u0f2_.js} +3 -3
  63. package/dist/chunks/{base-button.Bi5JR_6k.js.map → base-button.Dg_u0f2_.js.map} +1 -1
  64. package/dist/chunks/{base-modal.Bn4ZXwv6.js → base-modal.CulokESn.js} +7 -7
  65. package/dist/chunks/{base-modal.Bn4ZXwv6.js.map → base-modal.CulokESn.js.map} +1 -1
  66. package/dist/chunks/{button-actions-with-menu.CrbF2BSQ.js → button-actions-with-menu.BsCmJeKU.js} +2 -2
  67. package/dist/chunks/{button-actions-with-menu.CrbF2BSQ.js.map → button-actions-with-menu.BsCmJeKU.js.map} +1 -1
  68. package/dist/chunks/{button-actions.uIjzze43.js → button-actions.DvuGEQxM.js} +9 -9
  69. package/dist/chunks/button-actions.DvuGEQxM.js.map +1 -0
  70. package/dist/chunks/button-actions.types.BptAXjD8.js.map +1 -1
  71. package/dist/chunks/{button.Ciflfide.js → button.DAcwNdtP.js} +3 -3
  72. package/dist/chunks/{button.Ciflfide.js.map → button.DAcwNdtP.js.map} +1 -1
  73. package/dist/chunks/{calendar.Dtba7fcs.js → calendar.EuBZ9HoM.js} +325 -322
  74. package/dist/chunks/calendar.EuBZ9HoM.js.map +1 -0
  75. package/dist/chunks/{card.a8QL14dy.js → card.OErI_R47.js} +8 -8
  76. package/dist/chunks/{card.a8QL14dy.js.map → card.OErI_R47.js.map} +1 -1
  77. package/dist/chunks/{checkbox-group.BCzNXT1-.js → checkbox-group.Deb5pHjj.js} +4 -4
  78. package/dist/chunks/{checkbox-group.BCzNXT1-.js.map → checkbox-group.Deb5pHjj.js.map} +1 -1
  79. package/dist/chunks/{checkbox.0RmIkniU.js → checkbox.YBhv3GCJ.js} +17 -17
  80. package/dist/chunks/{checkbox.0RmIkniU.js.map → checkbox.YBhv3GCJ.js.map} +1 -1
  81. package/dist/chunks/{chip.Bv6IGch0.js → chip.D4OozULC.js} +13 -11
  82. package/dist/chunks/{chip.Bv6IGch0.js.map → chip.D4OozULC.js.map} +1 -1
  83. package/dist/chunks/{code-snippet.BbswO6TU.js → code-snippet.DNDXr7t6.js} +7 -7
  84. package/dist/chunks/{code-snippet.BbswO6TU.js.map → code-snippet.DNDXr7t6.js.map} +1 -1
  85. package/dist/chunks/{controls-group.KarFHKUT.js → controls-group.CC3yZiTT.js} +3 -3
  86. package/dist/chunks/{controls-group.KarFHKUT.js.map → controls-group.CC3yZiTT.js.map} +1 -1
  87. package/dist/chunks/{copy.C92qFRaR.js → copy.YBeE8V9S.js} +4 -4
  88. package/dist/chunks/{copy.C92qFRaR.js.map → copy.YBeE8V9S.js.map} +1 -1
  89. package/dist/chunks/{country.BN34hLpN.js → country.PHJgPzKU.js} +7 -7
  90. package/dist/chunks/{country.BN34hLpN.js.map → country.PHJgPzKU.js.map} +1 -1
  91. package/dist/chunks/country.types.BCOrkmVK.js.map +1 -1
  92. package/dist/chunks/{currency.DS4-apvT.js → currency.Y6BqUzYE.js} +5 -5
  93. package/dist/chunks/{currency.DS4-apvT.js.map → currency.Y6BqUzYE.js.map} +1 -1
  94. package/dist/chunks/{dashboard-section.Bv-SveGN.js → dashboard-section.CjC3fVU6.js} +3 -3
  95. package/dist/chunks/{dashboard-section.Bv-SveGN.js.map → dashboard-section.CjC3fVU6.js.map} +1 -1
  96. package/dist/chunks/{dashed-underline.C3lSC1_R.js → dashed-underline.DAtZOaad.js} +4 -4
  97. package/dist/chunks/{dashed-underline.C3lSC1_R.js.map → dashed-underline.DAtZOaad.js.map} +1 -1
  98. package/dist/chunks/{data-grid-template.DqZmPeze.js → data-grid-template.bPjGSga2.js} +4 -4
  99. package/dist/chunks/{data-grid-template.DqZmPeze.js.map → data-grid-template.bPjGSga2.js.map} +1 -1
  100. package/dist/chunks/{data-grid.vBDlLHOW.js → data-grid.o5MQdWnJ.js} +26 -26
  101. package/dist/chunks/{data-grid.vBDlLHOW.js.map → data-grid.o5MQdWnJ.js.map} +1 -1
  102. package/dist/chunks/{date-picker.Dnr2HuxA.js → date-picker.DyB8XkiY.js} +10 -10
  103. package/dist/chunks/{date-picker.Dnr2HuxA.js.map → date-picker.DyB8XkiY.js.map} +1 -1
  104. package/dist/chunks/date-picker.types.Ckt7zxGy.js.map +1 -1
  105. package/dist/chunks/{date-range-picker.CuBygd3O.js → date-range-picker.BcQUUVcW.js} +567 -525
  106. package/dist/chunks/date-range-picker.BcQUUVcW.js.map +1 -0
  107. package/dist/chunks/date-range-picker.types.Ckt7zxGy.js.map +1 -1
  108. package/dist/chunks/{date.ojGAujAt.js → date.SUOSxkTe.js} +4 -4
  109. package/dist/chunks/{date.ojGAujAt.js.map → date.SUOSxkTe.js.map} +1 -1
  110. package/dist/chunks/{dialog-page.D60pjDsQ.js → dialog-page.CHpFuDd9.js} +4 -4
  111. package/dist/chunks/{dialog-page.D60pjDsQ.js.map → dialog-page.CHpFuDd9.js.map} +1 -1
  112. package/dist/chunks/{draggable-handle.Cvc8gHzx.js → draggable-handle.CKkSJP0K.js} +3 -3
  113. package/dist/chunks/{draggable-handle.Cvc8gHzx.js.map → draggable-handle.CKkSJP0K.js.map} +1 -1
  114. package/dist/chunks/{draggable.BZsgR26I.js → draggable.jzTSFcM7.js} +38 -35
  115. package/dist/chunks/draggable.jzTSFcM7.js.map +1 -0
  116. package/dist/chunks/{drawer.D3j-d3q5.js → drawer.De-jDVb2.js} +2 -2
  117. package/dist/chunks/{drawer.D3j-d3q5.js.map → drawer.De-jDVb2.js.map} +1 -1
  118. package/dist/chunks/{dropdown-tag.Bn5FPeEL.js → dropdown-tag.BvXqllkv.js} +8 -8
  119. package/dist/chunks/{dropdown-tag.Bn5FPeEL.js.map → dropdown-tag.BvXqllkv.js.map} +1 -1
  120. package/dist/chunks/{dropdown.D_jkFrMd.js → dropdown.BoSI-Rre.js} +20 -20
  121. package/dist/chunks/{dropdown.D_jkFrMd.js.map → dropdown.BoSI-Rre.js.map} +1 -1
  122. package/dist/chunks/{empty-state.DpUC-3wv.js → empty-state.BuK12EGe.js} +4 -4
  123. package/dist/chunks/{empty-state.DpUC-3wv.js.map → empty-state.BuK12EGe.js.map} +1 -1
  124. package/dist/chunks/{error-message.Bt0CznQM.js → error-message.DJ5l0EUH.js} +3 -3
  125. package/dist/chunks/{error-message.Bt0CznQM.js.map → error-message.DJ5l0EUH.js.map} +1 -1
  126. package/dist/chunks/es6.yPcTMnSH.js.map +1 -1
  127. package/dist/chunks/{field-label.Cz11fn_F.js → field-label.vrUwhoOg.js} +4 -4
  128. package/dist/chunks/{field-label.Cz11fn_F.js.map → field-label.vrUwhoOg.js.map} +1 -1
  129. package/dist/chunks/{file-uploader.BglImnqw.js → file-uploader.Cv8sm0Jd.js} +12 -12
  130. package/dist/chunks/{file-uploader.BglImnqw.js.map → file-uploader.Cv8sm0Jd.js.map} +1 -1
  131. package/dist/chunks/{filter-bar.DG4GTi8L.js → filter-bar.6ElVHgFA.js} +34 -31
  132. package/dist/chunks/filter-bar.6ElVHgFA.js.map +1 -0
  133. package/dist/chunks/{fixed-scroller.DoOR83iH.js → fixed-scroller.C0nVzRBU.js} +3 -3
  134. package/dist/chunks/{fixed-scroller.DoOR83iH.js.map → fixed-scroller.C0nVzRBU.js.map} +1 -1
  135. package/dist/chunks/{footer-actions.Dl20Q1WX.js → footer-actions.BJif4sIk.js} +4 -4
  136. package/dist/chunks/{footer-actions.Dl20Q1WX.js.map → footer-actions.BJif4sIk.js.map} +1 -1
  137. package/dist/chunks/{form-layout-group.iAwbiI_S.js → form-layout-group.B9Kzae5F.js} +2 -2
  138. package/dist/chunks/{form-layout-group.iAwbiI_S.js.map → form-layout-group.B9Kzae5F.js.map} +1 -1
  139. package/dist/chunks/{form-layout-title.BZFh_nGD.js → form-layout-title.C7f1ByNh.js} +4 -4
  140. package/dist/chunks/{form-layout-title.BZFh_nGD.js.map → form-layout-title.C7f1ByNh.js.map} +1 -1
  141. package/dist/chunks/{header-with-views.WJlXgGI5.js → header-with-views.Dl6bfk_7.js} +17 -17
  142. package/dist/chunks/{header-with-views.WJlXgGI5.js.map → header-with-views.Dl6bfk_7.js.map} +1 -1
  143. package/dist/chunks/{header.Bi3MPZKE.js → header.E-KFjIG7.js} +5 -5
  144. package/dist/chunks/{header.Bi3MPZKE.js.map → header.E-KFjIG7.js.map} +1 -1
  145. package/dist/chunks/index.CGBfMQdv.js +38 -0
  146. package/dist/chunks/index.CGBfMQdv.js.map +1 -0
  147. package/dist/chunks/{info-icon-with-popover.uSr6-jzR.js → info-icon-with-popover.DqnQnwMI.js} +4 -4
  148. package/dist/chunks/{info-icon-with-popover.uSr6-jzR.js.map → info-icon-with-popover.DqnQnwMI.js.map} +1 -1
  149. package/dist/chunks/{info-icon.Zlg6Sgz0.js → info-icon.D_zu5SYT.js} +2 -2
  150. package/dist/chunks/{info-icon.Zlg6Sgz0.js.map → info-icon.D_zu5SYT.js.map} +1 -1
  151. package/dist/chunks/{input-field-password.CJZxudne.js → input-field-password.BXptrVTT.js} +7 -7
  152. package/dist/chunks/{input-field-password.CJZxudne.js.map → input-field-password.BXptrVTT.js.map} +1 -1
  153. package/dist/chunks/{input-field-phone-number.OJ4MG9Gf.js → input-field-phone-number.Crxi8Wm7.js} +4 -4
  154. package/dist/chunks/{input-field-phone-number.OJ4MG9Gf.js.map → input-field-phone-number.Crxi8Wm7.js.map} +1 -1
  155. package/dist/chunks/{input-field.IyNujUZt.js → input-field._keU91LW.js} +24 -24
  156. package/dist/chunks/{input-field.IyNujUZt.js.map → input-field._keU91LW.js.map} +1 -1
  157. package/dist/chunks/input-time.D7UW_ww_.js +193 -0
  158. package/dist/chunks/input-time.D7UW_ww_.js.map +1 -0
  159. package/dist/chunks/{inspector-page.D42_PXHM.js → inspector-page.DNsc0lK1.js} +4 -4
  160. package/dist/chunks/{inspector-page.D42_PXHM.js.map → inspector-page.DNsc0lK1.js.map} +1 -1
  161. package/dist/chunks/{inspector.BBgrupfO.js → inspector.BLAqbhmV.js} +6 -6
  162. package/dist/chunks/{inspector.BBgrupfO.js.map → inspector.BLAqbhmV.js.map} +1 -1
  163. package/dist/chunks/{layout-row.DijjweVX.js → layout-row.X6mPrUu8.js} +2 -2
  164. package/dist/chunks/{layout-row.DijjweVX.js.map → layout-row.X6mPrUu8.js.map} +1 -1
  165. package/dist/chunks/{link.types.BGj7apK3.js → link.types.BZ1u_6CS.js} +2 -2
  166. package/dist/chunks/{link.types.BGj7apK3.js.map → link.types.BZ1u_6CS.js.map} +1 -1
  167. package/dist/chunks/{list-item.CT7dyMQH.js → list-item.RuGQ8Y4T.js} +6 -6
  168. package/dist/chunks/{list-item.CT7dyMQH.js.map → list-item.RuGQ8Y4T.js.map} +1 -1
  169. package/dist/chunks/{listbox-option-tag.CwrFdsY1.js → listbox-option-tag.71rmQvG8.js} +3 -3
  170. package/dist/chunks/{listbox-option-tag.CwrFdsY1.js.map → listbox-option-tag.71rmQvG8.js.map} +1 -1
  171. package/dist/chunks/{modal-fullscreen.I5bjqzfd.js → modal-fullscreen.jXJnaueu.js} +10 -10
  172. package/dist/chunks/modal-fullscreen.jXJnaueu.js.map +1 -0
  173. package/dist/chunks/{modal.vue_vue_type_script_setup_true_lang.CrsIyU7A.js → modal.vue_vue_type_script_setup_true_lang.BwmYlzFm.js} +8 -8
  174. package/dist/chunks/{modal.vue_vue_type_script_setup_true_lang.CrsIyU7A.js.map → modal.vue_vue_type_script_setup_true_lang.BwmYlzFm.js.map} +1 -1
  175. package/dist/chunks/{navigation-menu-group.BJ9ZsXEn.js → navigation-menu-group.BnS0isK8.js} +32 -32
  176. package/dist/chunks/navigation-menu-group.BnS0isK8.js.map +1 -0
  177. package/dist/chunks/{pagination.C5gZxtZY.js → pagination.C-kvJ-XK.js} +9 -8
  178. package/dist/chunks/{pagination.C5gZxtZY.js.map → pagination.C-kvJ-XK.js.map} +1 -1
  179. package/dist/chunks/{payment-method.q2yow5VR.js → payment-method.B69Mu88z.js} +2 -2
  180. package/dist/chunks/{payment-method.q2yow5VR.js.map → payment-method.B69Mu88z.js.map} +1 -1
  181. package/dist/chunks/payment-method.types.BqtH7RM2.js.map +1 -1
  182. package/dist/chunks/popover.types.dhllh3NP.js.map +1 -1
  183. package/dist/chunks/popper-container.Rfj8UdMD.js.map +1 -1
  184. package/dist/chunks/{promo-banner.kE1-WkzI.js → promo-banner.3d1DHWas.js} +4 -4
  185. package/dist/chunks/{promo-banner.kE1-WkzI.js.map → promo-banner.3d1DHWas.js.map} +1 -1
  186. package/dist/chunks/{radio-group.XmRPh03c.js → radio-group.BTI_2U11.js} +5 -5
  187. package/dist/chunks/{radio-group.XmRPh03c.js.map → radio-group.BTI_2U11.js.map} +1 -1
  188. package/dist/chunks/{rich-text-editor.Cv_Vwt-6.js → rich-text-editor.ClUU1zPM.js} +12 -12
  189. package/dist/chunks/{rich-text-editor.Cv_Vwt-6.js.map → rich-text-editor.ClUU1zPM.js.map} +1 -1
  190. package/dist/chunks/{scroll-to-section.CJorrxQT.js → scroll-to-section.BRr4Vwi7.js} +2 -2
  191. package/dist/chunks/{scroll-to-section.CJorrxQT.js.map → scroll-to-section.BRr4Vwi7.js.map} +1 -1
  192. package/dist/chunks/{search-bar.5tObtLfW.js → search-bar.D1Jz7hdd.js} +13 -13
  193. package/dist/chunks/{search-bar.5tObtLfW.js.map → search-bar.D1Jz7hdd.js.map} +1 -1
  194. package/dist/chunks/{secondary-nav.DApIImQ0.js → secondary-nav.D32VFDTi.js} +26 -26
  195. package/dist/chunks/{secondary-nav.DApIImQ0.js.map → secondary-nav.D32VFDTi.js.map} +1 -1
  196. package/dist/chunks/{segmented-control.CEt2dz4n.js → segmented-control.CarI0i3p.js} +3 -3
  197. package/dist/chunks/{segmented-control.CEt2dz4n.js.map → segmented-control.CarI0i3p.js.map} +1 -1
  198. package/dist/chunks/segmented-control.types.BHRLV8KU.js.map +1 -1
  199. package/dist/chunks/{selection-card-group.DHXtJpoB.js → selection-card-group.CQsS8-H9.js} +109 -108
  200. package/dist/chunks/{selection-card-group.DHXtJpoB.js.map → selection-card-group.CQsS8-H9.js.map} +1 -1
  201. package/dist/chunks/{sidepanel._30g8POM.js → sidepanel.CYWPV9dE.js} +13 -13
  202. package/dist/chunks/{sidepanel._30g8POM.js.map → sidepanel.CYWPV9dE.js.map} +1 -1
  203. package/dist/chunks/{status.Nss4P5OU.js → status.BJ48Isyh.js} +2 -2
  204. package/dist/chunks/{status.Nss4P5OU.js.map → status.BJ48Isyh.js.map} +1 -1
  205. package/dist/chunks/status.types.Dx8MDhEH.js.map +1 -1
  206. package/dist/chunks/{step.5_ZukVqJ.js → step.CRVu8HPR.js} +6 -6
  207. package/dist/chunks/step.CRVu8HPR.js.map +1 -0
  208. package/dist/chunks/{structured-list-item.CBzznwcF.js → structured-list-item.C6SAUS9a.js} +11 -10
  209. package/dist/chunks/structured-list-item.C6SAUS9a.js.map +1 -0
  210. package/dist/chunks/{summary-grid.types.BR_EGvRg.js → summary-grid.types.FTWeUNFh.js} +7 -7
  211. package/dist/chunks/{summary-grid.types.BR_EGvRg.js.map → summary-grid.types.FTWeUNFh.js.map} +1 -1
  212. package/dist/chunks/{tab.D_k5AVHk.js → tab.CwXAsp9E.js} +44 -43
  213. package/dist/chunks/tab.CwXAsp9E.js.map +1 -0
  214. package/dist/chunks/{table-of-contents.CJ2yMbAG.js → table-of-contents.Bnyua5hb.js} +4 -4
  215. package/dist/chunks/{table-of-contents.CJ2yMbAG.js.map → table-of-contents.Bnyua5hb.js.map} +1 -1
  216. package/dist/chunks/{tag.BE1j0Oid.js → tag.BYxa556o.js} +3 -3
  217. package/dist/chunks/{tag.BE1j0Oid.js.map → tag.BYxa556o.js.map} +1 -1
  218. package/dist/chunks/{textarea.BYshPd98.js → textarea.D4aMdmDx.js} +8 -8
  219. package/dist/chunks/textarea.D4aMdmDx.js.map +1 -0
  220. package/dist/chunks/{timeline-item.Sy_DSw6p.js → timeline-item.De8HCoYw.js} +11 -11
  221. package/dist/chunks/{timeline-item.Sy_DSw6p.js.map → timeline-item.De8HCoYw.js.map} +1 -1
  222. package/dist/chunks/{title-details.C4ZvxPMu.js → title-details.8cyCeaLf.js} +5 -5
  223. package/dist/chunks/{title-details.C4ZvxPMu.js.map → title-details.8cyCeaLf.js.map} +1 -1
  224. package/dist/chunks/{toast.u5Y_CGe_.js → toast.BI2PD8Oj.js} +5 -5
  225. package/dist/chunks/{toast.u5Y_CGe_.js.map → toast.BI2PD8Oj.js.map} +1 -1
  226. package/dist/chunks/{toggle.BW8ww0Ih.js → toggle.BbCqV953.js} +4 -4
  227. package/dist/chunks/{toggle.BW8ww0Ih.js.map → toggle.BbCqV953.js.map} +1 -1
  228. package/dist/chunks/{tooltip.TFOGHOO0.js → tooltip.0QqJo2sa.js} +2 -2
  229. package/dist/chunks/{tooltip.TFOGHOO0.js.map → tooltip.0QqJo2sa.js.map} +1 -1
  230. package/dist/chunks/{tutorial.vue_vue_type_script_setup_true_lang.BIP-heAH.js → tutorial.vue_vue_type_script_setup_true_lang.Dn4toWHY.js} +4 -4
  231. package/dist/chunks/{tutorial.vue_vue_type_script_setup_true_lang.BIP-heAH.js.map → tutorial.vue_vue_type_script_setup_true_lang.Dn4toWHY.js.map} +1 -1
  232. package/dist/chunks/{typography.wIM07Hbl.js → typography.B6elnWpr.js} +35 -35
  233. package/dist/chunks/{typography.wIM07Hbl.js.map → typography.B6elnWpr.js.map} +1 -1
  234. package/dist/chunks/{use-bento-toast-controller.BAoPbtq7.js → use-bento-toast-controller.CkpBtweL.js} +2 -2
  235. package/dist/chunks/{use-bento-toast-controller.BAoPbtq7.js.map → use-bento-toast-controller.CkpBtweL.js.map} +1 -1
  236. package/dist/chunks/{use-country-items.CYnYzs7x.js → use-country-items.CAYJt6XS.js} +3 -3
  237. package/dist/chunks/{use-country-items.CYnYzs7x.js.map → use-country-items.CAYJt6XS.js.map} +1 -1
  238. package/dist/chunks/{use-date-input-formatter._ik1DYYV.js → use-date-input-formatter.BIVkaB1k.js} +2 -2
  239. package/dist/chunks/{use-date-input-formatter._ik1DYYV.js.map → use-date-input-formatter.BIVkaB1k.js.map} +1 -1
  240. package/dist/chunks/{use-dynamic-date-fns-locale.BMO9rsEh.js → use-dynamic-date-fns-locale._EtEeU3i.js} +2 -2
  241. package/dist/chunks/{use-dynamic-date-fns-locale.BMO9rsEh.js.map → use-dynamic-date-fns-locale._EtEeU3i.js.map} +1 -1
  242. package/dist/code-snippet.js +1 -1
  243. package/dist/country.js +1 -1
  244. package/dist/currency.js +1 -1
  245. package/dist/dashboard-template.js +1 -1
  246. package/dist/dashed-underline.js +1 -1
  247. package/dist/data-grid-template.js +1 -1
  248. package/dist/data-grid.js +1 -1
  249. package/dist/date-picker.js +2 -2
  250. package/dist/date-range-picker.js +2 -2
  251. package/dist/date-time-picker.js +6 -6
  252. package/dist/date.js +1 -1
  253. package/dist/draggable.js +2 -2
  254. package/dist/drawer.js +1 -1
  255. package/dist/dropdown.js +2 -2
  256. package/dist/empty-state.js +1 -1
  257. package/dist/file-uploader.js +1 -1
  258. package/dist/filter-bar.js +1 -1
  259. package/dist/form-layout.js +2 -2
  260. package/dist/header-with-views.js +1 -1
  261. package/dist/header.js +1 -1
  262. package/dist/index.js +382 -353
  263. package/dist/index.js.map +1 -1
  264. package/dist/info-icon.js +1 -1
  265. package/dist/input-field-password.js +1 -1
  266. package/dist/input-field-phone-number.js +1 -1
  267. package/dist/input-field.js +1 -1
  268. package/dist/input-time.js +1 -1
  269. package/dist/inspector.js +2 -2
  270. package/dist/internal.js +14 -14
  271. package/dist/layout.js +1 -1
  272. package/dist/link.js +1 -1
  273. package/dist/list.js +1 -1
  274. package/dist/menu.js +1 -1
  275. package/dist/modal-fullscreen.js +1 -1
  276. package/dist/modal.js +2 -2
  277. package/dist/navigation-menu.js +1 -1
  278. package/dist/pagination.js +1 -1
  279. package/dist/payment-method.js +1 -1
  280. package/dist/popover.js +1 -1
  281. package/dist/progress-bar.js +4 -4
  282. package/dist/promo-banner.js +1 -1
  283. package/dist/radio-group.js +1 -1
  284. package/dist/rich-text-editor.js +1 -1
  285. package/dist/search-bar.js +2 -2
  286. package/dist/secondary-nav.js +1 -1
  287. package/dist/segmented-control.js +1 -1
  288. package/dist/selection-card.js +1 -1
  289. package/dist/sidepanel.js +1 -1
  290. package/dist/status.js +1 -1
  291. package/dist/stepper.js +1 -1
  292. package/dist/structured-list.js +1 -1
  293. package/dist/styles/bento-dark.css +3 -0
  294. package/dist/styles/bento-light.css +3 -0
  295. package/dist/styles/bento.css +3 -0
  296. package/dist/styles/legacy.css +3 -0
  297. package/dist/styles/styleguide.css +3 -0
  298. package/dist/styles/utility.css +9 -0
  299. package/dist/summary-grid.js +1 -1
  300. package/dist/table-of-contents.js +1 -1
  301. package/dist/tabs.js +1 -1
  302. package/dist/tag.js +1 -1
  303. package/dist/textarea.js +1 -1
  304. package/dist/timeline.js +1 -1
  305. package/dist/toast.js +1 -1
  306. package/dist/toggle.js +1 -1
  307. package/dist/tutorial.js +1 -1
  308. package/dist/typography.js +1 -1
  309. package/dist/web-types.json +1 -1
  310. package/package.json +9 -5
  311. package/dist/chunks/button-actions.uIjzze43.js.map +0 -1
  312. package/dist/chunks/calendar.Dtba7fcs.js.map +0 -1
  313. package/dist/chunks/date-range-picker.CuBygd3O.js.map +0 -1
  314. package/dist/chunks/draggable.BZsgR26I.js.map +0 -1
  315. package/dist/chunks/filter-bar.DG4GTi8L.js.map +0 -1
  316. package/dist/chunks/index.B875RXHM.js +0 -15
  317. package/dist/chunks/index.B875RXHM.js.map +0 -1
  318. package/dist/chunks/input-time.BJ6YqkFi.js +0 -122
  319. package/dist/chunks/input-time.BJ6YqkFi.js.map +0 -1
  320. package/dist/chunks/modal-fullscreen.I5bjqzfd.js.map +0 -1
  321. package/dist/chunks/navigation-menu-group.BJ9ZsXEn.js.map +0 -1
  322. package/dist/chunks/step.5_ZukVqJ.js.map +0 -1
  323. package/dist/chunks/structured-list-item.CBzznwcF.js.map +0 -1
  324. package/dist/chunks/tab.D_k5AVHk.js.map +0 -1
  325. package/dist/chunks/textarea.BYshPd98.js.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"inspector.BBgrupfO.js","sources":["../../../vue2/src/components/inspector/composables/use-focus-history/use-focus-history.ts","../../../vue2/src/components/inspector/inspector.vue"],"sourcesContent":["import { ref, type Ref } from 'vue';\nimport { useActiveElement } from '@vueuse/core';\nimport { watch } from 'vue';\n\n/**\n * A composable to track the focus history within a target element.\n * @param targetEl The stable parent element to monitor for focus changes.\n */\nexport function useFocusHistory(targetEl: Ref<HTMLElement | null>) {\n const MAX_HISTORY_LENGTH = 3;\n\n const focusHistory = ref<Array<Element>>([]);\n\n const currentActiveElement = useActiveElement();\n\n // Edge case 1:\n // While the inspector is opened, if user tabs through the data-grid to the inspector, and closes it,\n // it returns to the last element on the data grid regardless if it is a data-grid-cell.\n //\n // Edge case 2:\n // Buttons or actions teleported out of the data-grid may have the focus shifted into a different context.\n watch(currentActiveElement, newlyFocusedElement => {\n // Check if the newly focused element is a child of our target container.\n if (!targetEl.value || !newlyFocusedElement || !targetEl.value.contains(newlyFocusedElement)) {\n return;\n }\n\n // Add the focused element to the history\n focusHistory.value.unshift(newlyFocusedElement);\n\n if (focusHistory.value.length > MAX_HISTORY_LENGTH) {\n focusHistory.value.pop();\n }\n });\n\n /**\n * Iterates through the focus history to find the first valid element\n * that is still present in the DOM.\n * @returns The first valid historical element, or null if none are found.\n */\n const findValidFocusFallback = (): HTMLElement | null => {\n for (const el of focusHistory.value) {\n if (el && document.body.contains(el as Node)) {\n return el as HTMLElement;\n }\n }\n\n return null; // No valid fallback found\n };\n\n return {\n findValidFocusFallback,\n };\n}\n","<template>\n <div ref=\"wrapper\" class=\"b-inspector\" :class=\"conditionalClass\" @keydown=\"handleSectionFocus\">\n <div ref=\"page\" class=\"b-inspector__page-wrapper\">\n <div class=\"b-inspector__page\">\n <slot name=\"page\"></slot>\n </div>\n </div>\n <Transition name=\"b-inspector__animation\" mode=\"out-in\" @before-enter=\"setFocus\" @after-leave=\"setFocus\">\n <aside\n v-if=\"isOpen\"\n ref=\"inspector\"\n class=\"b-inspector__container-wrapper\"\n :aria-label=\"inspectorAriaLabel\"\n @keydown.tab=\"handleTabNavigation\"\n >\n <bento-focus-trap :disabled=\"!isCompact\" class=\"b-inspector__focus-trap\">\n <div class=\"b-inspector__container\" :class=\"computedContainerClasses\">\n <template v-if=\"!isCompact\">\n <bento-button\n ref=\"returnContentButton\"\n class=\"b-inspector__return-content\"\n variant=\"secondary\"\n condensed\n :aria-describedby=\"returnToMainContentDescriptionId\"\n @click=\"moveFocusBetweenSections\"\n >\n {{ t('returnToMainContent') }}\n </bento-button>\n <span\n :id=\"returnToMainContentDescriptionId\"\n class=\"b-inspector__return-content-description\"\n >\n {{ t('returnToMainContentDescription') }}\n </span>\n </template>\n <div v-if=\"pages.length === 0\" class=\"b-inspector__header\">\n <bento-typography el=\"h2\" variant=\"title\" class=\"b-inspector__title\">\n {{ title }}\n </bento-typography>\n </div>\n <div class=\"b-inspector__content\">\n <bento-loading-indicator v-if=\"loading\" large class=\"b-inspector__loading-indicator\" />\n <slot v-else name=\"content\"></slot>\n </div>\n <div class=\"b-inspector__icons\">\n <bento-button\n v-if=\"expandable\"\n ref=\"expandButton\"\n variant=\"tertiary\"\n :aria-label=\"t('expand')\"\n @click=\"emit('expand')\"\n >\n <template #iconLeft>\n <expand-icon aria-hidden=\"true\" />\n </template>\n </bento-button>\n <bento-button\n ref=\"closeButton\"\n :aria-label=\"t('close')\"\n variant=\"tertiary\"\n @click=\"emit('update:is-open', false)\"\n >\n <template #iconLeft>\n <cross-icon aria-hidden=\"true\" />\n </template>\n </bento-button>\n </div>\n </div>\n </bento-focus-trap>\n </aside>\n </Transition>\n </div>\n</template>\n\n<script setup lang=\"ts\">\n import { computed, nextTick, provide, ref, toRef, watch } from 'vue';\n import { BentoTypography } from '@/components/typography';\n import { BentoButton } from '@/components/button';\n import { BentoLoadingIndicator } from '@/components/loading-indicator';\n import { BentoFocusTrap } from '@/components/focus-trap';\n import ExpandIcon from '@adyen/ui-assets-icons-16/vue/expand';\n import CrossIcon from '@adyen/ui-assets-icons-16/vue/cross';\n\n import { generateUid } from '@/utils/ts/generate-uid';\n import { useI18n } from '@/utils/ts/i18n';\n import { deprecate } from '@/utils/ts/deprecate';\n import { useElementSize } from '@vueuse/core';\n import moveFocusInside, { focusInside, getActiveElement, getFocusableIn } from 'focus-lock';\n\n import { type BentoInspectorProps } from './inspector.types';\n import { useFocusHistory } from './composables/use-focus-history/use-focus-history';\n import {\n DIALOG_PAGE_CONFIG_INJECTION_KEY,\n DIALOG_PAGE_REGISTER_PAGE_INJECTION_KEY,\n } from '@/internal/dialog-page/dialog-page.keys';\n import {\n BentoDialogPageAnimation,\n type BentoDialogPageConfigData,\n type BentoDialogPageRegisterPage,\n } from '@/internal/dialog-page/dialog-page.types';\n\n import messages from './messages.json';\n\n type MessageSchema = (typeof messages)['en-US'];\n\n const props = withDefaults(defineProps<BentoInspectorProps>(), {\n activePage: '',\n expandable: false,\n isOpen: false,\n loading: false,\n size: 'small',\n relativeLayout: 'push-content',\n pageFocusAnchor: null,\n });\n\n const emit = defineEmits<{\n /**\n * Emits update to keep isOpen prop in sync\n */\n (e: 'update:is-open', value: boolean): void;\n /**\n * Emits update to keep activePage prop in sync\n */\n (e: 'update:active-page', value: string): void;\n /**\n * Emits event when user click expand button\n */\n (e: 'expand'): void;\n }>();\n\n const { t } = useI18n<{ message: MessageSchema }>({ messages });\n const returnToMainContentDescriptionId = generateUid('returnToMainContentDescription');\n const wrapper = ref<HTMLElement>(null);\n const inspector = ref<HTMLElement>(null);\n const page = ref<HTMLElement>(null);\n // These refs allow keyboard navigation to follow the intended order independently of the DOM order.\n const returnContentButton = ref(null);\n const expandButton = ref(null);\n const closeButton = ref(null);\n const inspectorLastFocusedElement = ref<HTMLElement>(null);\n const internalActivePage = ref(props.activePage);\n\n // Multiple page navigation\n const pages = ref<Array<string>>([]);\n const previousPages = ref([]);\n const animation = ref(BentoDialogPageAnimation.TRANSITION_LEVEL_DEEPER);\n const isAnimationActive = ref(false);\n\n const { width: wrapperWidth } = useElementSize(wrapper);\n const computedContainerClasses = computed(() => {\n return {\n 'b-inspector__container--padded': pages.value.length === 0, // No pages are registered\n };\n });\n\n const isCompact = computed(() => {\n const COMPACT_THRESHOLD_SMALL = 740;\n const COMPACT_THRESHOLD_LARGE = 915;\n\n // small inspector to occupy full screen if < 740px\n // large inspector to occupy full screen if < 915px\n const threshold = props.size === 'small' ? COMPACT_THRESHOLD_SMALL : COMPACT_THRESHOLD_LARGE;\n\n return wrapperWidth.value > 0 && wrapperWidth.value < threshold;\n });\n\n const computedPageLastFocusedElement = computed(() => props.pageFocusAnchor);\n\n const conditionalClass = computed(() => ({\n [`b-inspector--${props.size}`]: true,\n [`b-inspector--${props.relativeLayout}`]: true,\n [`b-inspector--is-compact`]: isCompact.value,\n [`b-inspector--multi-paged`]: pages.value.length,\n }));\n\n const inspectorAriaLabel = computed(() => `${t('inspector')}, ${props.title}`);\n\n const { findValidFocusFallback } = useFocusHistory(page);\n\n /**\n * Returns the Inspector's intended tab order.\n *\n * The content must remain before the icon buttons in the DOM for the Inspector animations,\n * so the keyboard order is managed separately. The return button is omitted automatically in compact mode.\n */\n const getOrderedFocusableElements = () => {\n const navigationButtons = [\n returnContentButton.value?.$el,\n expandButton.value?.$el,\n closeButton.value?.$el,\n ].filter(Boolean) as Array<HTMLElement>;\n const contentFocusableElements = getFocusableIn(inspector.value)\n .map(({ node }) => node)\n .filter(element => !navigationButtons.includes(element));\n\n return [...navigationButtons, ...contentFocusableElements];\n };\n\n const setFocus = async () => {\n if (props.isOpen) {\n await nextTick();\n if (isCompact.value) {\n // The compact focus trap uses DOM order when it initially moves focus.\n // Explicitly focus the first ordered control so content does not skip the icon buttons.\n focusElement(getOrderedFocusableElements()[0]);\n } else {\n moveFocusInside(inspector.value, computedPageLastFocusedElement.value);\n }\n } else {\n // This doesn't work with data grid cell actions, as the button gets destroyed once is not being hovered.\n // To be reviewed after LevelAccess revision\n focusElement(computedPageLastFocusedElement.value ?? findValidFocusFallback());\n }\n };\n\n const handleTabNavigation = (event: KeyboardEvent) => {\n // Prevent the browser's DOM-based tab order and use the Inspector-specific order instead.\n const direction = event.shiftKey ? -1 : 1;\n const focusableElements = getOrderedFocusableElements();\n const currentIndex = focusableElements.indexOf(getActiveElement());\n const nextIndex = currentIndex + direction;\n\n // Compact inspectors trap focus, so navigation should wrap around instead of returning focus to the page.\n if (isCompact.value && focusableElements.length > 0) {\n event.preventDefault();\n focusableElements[(nextIndex + focusableElements.length) % focusableElements.length].focus();\n return;\n }\n\n const focusableEl = focusableElements[nextIndex];\n\n // At either end of the Inspector, return focus to the page.\n if (!focusableEl) {\n event.preventDefault();\n inspectorLastFocusedElement.value = document.activeElement as HTMLElement;\n focusElement(computedPageLastFocusedElement.value ?? findValidFocusFallback());\n // Set active-page as undefined when focus is not on page\n emit('update:active-page', undefined);\n return;\n }\n\n event.preventDefault();\n focusableEl.focus();\n };\n\n const handleSectionFocus = event => {\n const sectionShortcut = event.shiftKey && event.ctrlKey && event.key === 'S';\n if (props.isOpen && !isCompact.value && sectionShortcut) {\n moveFocusBetweenSections();\n }\n };\n\n const moveFocusBetweenSections = () => {\n if (focusInside(inspector.value)) {\n inspectorLastFocusedElement.value = document.activeElement as HTMLElement;\n focusElement(computedPageLastFocusedElement.value ?? findValidFocusFallback());\n // Set active-page as undefined when focus is not on page\n emit('update:active-page', undefined);\n } else {\n focusElement(inspectorLastFocusedElement.value);\n }\n };\n\n const focusElement = (element: HTMLElement) => {\n if (!element) {\n return;\n }\n element?.focus();\n if (document.activeElement !== element) {\n focusElement(element.parentElement);\n }\n };\n\n /**\n * Multiple page navigation and page registration\n */\n\n const updatePage = page => emit('update:active-page', page);\n\n // unregister page if removed / destroyed\n const unregisterPage = (pageIdToRemove: string) => () => {\n pages.value = pages.value?.filter(pageId => pageId !== pageIdToRemove);\n };\n\n const registerPage: BentoDialogPageRegisterPage = pageId => {\n pages.value.push(pageId);\n\n return { unregisterPage: unregisterPage(pageId) };\n };\n\n provide<BentoDialogPageConfigData>(DIALOG_PAGE_CONFIG_INJECTION_KEY, {\n activePage: internalActivePage,\n animation,\n isAnimationActive,\n isOpen: toRef(props, 'isOpen'),\n pages,\n previousPages,\n updatePage,\n });\n\n provide(DIALOG_PAGE_REGISTER_PAGE_INJECTION_KEY, registerPage);\n\n watch(\n () => props.activePage,\n () => {\n if (props.activePage) {\n internalActivePage.value = props.activePage;\n setFocus();\n }\n }\n );\n\n if (!props.activePage) {\n deprecate(\n 'BentoInspector \"active-page\" as optional',\n `Make sure to set the \"active-page\" prop and keep it in sync with \"update:active-page\".\n \"active-page\" prop will be required in the next version`,\n '2.0.0'\n );\n }\n</script>\n\n<script lang=\"ts\">\n /**\n * Inspector allows users to access additional information or details of an object/item. The inspector opens adjacent to the main content, pushing it aside to maintain visibility and accessibility to both the main content and inspector.\n *\n * @example\n * import { BentoInspector } from '@adyen/bento-vue2';\n *\n * export default {\n * components: { BentoInspector },\n * template: `\n * <bento-inspector\n * title=\"Inspector\"\n * size=\"large\"\n * :is-open=\"isOpen\"\n * :active-page=\"activePage\"\n * expandable\n * @update:is-open=\"isOpen = $event\"\n * @update:active-page=\"activePage = $event\"\n * >\n * <template #page>Content of the page</template>\n * <template #content>Content of the inspector</template>\n * </bento-inspector>\n * `\n * }\n */\n export default { i18n: { messages } };\n</script>\n\n<style lang=\"scss\" scoped src=\"./inspector.scss\" />\n"],"names":["useFocusHistory","targetEl","focusHistory","ref","currentActiveElement","useActiveElement","watch","newlyFocusedElement","el","__default__","messages","props","__props","emit","__emit","t","useI18n","returnToMainContentDescriptionId","generateUid","wrapper","inspector","page","returnContentButton","expandButton","closeButton","inspectorLastFocusedElement","internalActivePage","pages","previousPages","animation","BentoDialogPageAnimation","isAnimationActive","wrapperWidth","useElementSize","computedContainerClasses","computed","isCompact","threshold","computedPageLastFocusedElement","conditionalClass","inspectorAriaLabel","findValidFocusFallback","getOrderedFocusableElements","navigationButtons","contentFocusableElements","getFocusableIn","node","element","setFocus$1","nextTick","focusElement","setFocus","handleTabNavigation","event","direction","focusableElements","nextIndex","getActiveElement","focusableEl","handleSectionFocus","sectionShortcut","moveFocusBetweenSections","focusInside","updatePage","page2","unregisterPage","pageIdToRemove","pageId","registerPage","provide","DIALOG_PAGE_CONFIG_INJECTION_KEY","toRef","DIALOG_PAGE_REGISTER_PAGE_INJECTION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;AAAA,MACA,YAAAmC;AAAA,IACA,CAAA,GAGJM,EAAAG,IAAAJ,EAAA,GAEA9D;AAAA,MAAA,MAAAK,EAAA;AAAA,MACgB,MAAA;AAER,QAAAA,EAAA,eACIe,EAAA,QAAAf,EAAA,YACAqC,EAAA;AAAA,MACJ;AAAA,IACJ,GAGJrC,EAAA,cACI8D;AAAA,MAAA;AAAA,MACI;AAAA;AAAA,MACA;AAAA,IAEA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"inspector.BLAqbhmV.js","sources":["../../../vue2/src/components/inspector/composables/use-focus-history/use-focus-history.ts","../../../vue2/src/components/inspector/inspector.vue"],"sourcesContent":["import { ref, type Ref } from 'vue';\nimport { useActiveElement } from '@vueuse/core';\nimport { watch } from 'vue';\n\n/**\n * A composable to track the focus history within a target element.\n * @param targetEl The stable parent element to monitor for focus changes.\n */\nexport function useFocusHistory(targetEl: Ref<HTMLElement | null>) {\n const MAX_HISTORY_LENGTH = 3;\n\n const focusHistory = ref<Array<Element>>([]);\n\n const currentActiveElement = useActiveElement();\n\n // Edge case 1:\n // While the inspector is opened, if user tabs through the data-grid to the inspector, and closes it,\n // it returns to the last element on the data grid regardless if it is a data-grid-cell.\n //\n // Edge case 2:\n // Buttons or actions teleported out of the data-grid may have the focus shifted into a different context.\n watch(currentActiveElement, newlyFocusedElement => {\n // Check if the newly focused element is a child of our target container.\n if (!targetEl.value || !newlyFocusedElement || !targetEl.value.contains(newlyFocusedElement)) {\n return;\n }\n\n // Add the focused element to the history\n focusHistory.value.unshift(newlyFocusedElement);\n\n if (focusHistory.value.length > MAX_HISTORY_LENGTH) {\n focusHistory.value.pop();\n }\n });\n\n /**\n * Iterates through the focus history to find the first valid element\n * that is still present in the DOM.\n * @returns The first valid historical element, or null if none are found.\n */\n const findValidFocusFallback = (): HTMLElement | null => {\n for (const el of focusHistory.value) {\n if (el && document.body.contains(el as Node)) {\n return el as HTMLElement;\n }\n }\n\n return null; // No valid fallback found\n };\n\n return {\n findValidFocusFallback,\n };\n}\n","<template>\n <div ref=\"wrapper\" class=\"b-inspector\" :class=\"conditionalClass\" @keydown=\"handleSectionFocus\">\n <div ref=\"page\" class=\"b-inspector__page-wrapper\">\n <div class=\"b-inspector__page\">\n <slot name=\"page\"></slot>\n </div>\n </div>\n <Transition name=\"b-inspector__animation\" mode=\"out-in\" @before-enter=\"setFocus\" @after-leave=\"setFocus\">\n <aside\n v-if=\"isOpen\"\n ref=\"inspector\"\n class=\"b-inspector__container-wrapper\"\n :aria-label=\"inspectorAriaLabel\"\n @keydown.tab=\"handleTabNavigation\"\n >\n <bento-focus-trap :disabled=\"!isCompact\" class=\"b-inspector__focus-trap\">\n <div class=\"b-inspector__container\" :class=\"computedContainerClasses\">\n <template v-if=\"!isCompact\">\n <bento-button\n ref=\"returnContentButton\"\n class=\"b-inspector__return-content\"\n variant=\"secondary\"\n condensed\n :aria-describedby=\"returnToMainContentDescriptionId\"\n @click=\"moveFocusBetweenSections\"\n >\n {{ t('returnToMainContent') }}\n </bento-button>\n <span\n :id=\"returnToMainContentDescriptionId\"\n class=\"b-inspector__return-content-description\"\n >\n {{ t('returnToMainContentDescription') }}\n </span>\n </template>\n <div v-if=\"pages.length === 0\" class=\"b-inspector__header\">\n <bento-typography el=\"h2\" variant=\"title\" class=\"b-inspector__title\">\n {{ title }}\n </bento-typography>\n </div>\n <div class=\"b-inspector__content\">\n <bento-loading-indicator v-if=\"loading\" large class=\"b-inspector__loading-indicator\" />\n <slot v-else name=\"content\"></slot>\n </div>\n <div class=\"b-inspector__icons\">\n <bento-button\n v-if=\"expandable\"\n ref=\"expandButton\"\n variant=\"tertiary\"\n :aria-label=\"t('expand')\"\n @click=\"emit('expand')\"\n >\n <template #iconLeft>\n <expand-icon aria-hidden=\"true\" />\n </template>\n </bento-button>\n <bento-button\n ref=\"closeButton\"\n :aria-label=\"t('close')\"\n variant=\"tertiary\"\n @click=\"emit('update:is-open', false)\"\n >\n <template #iconLeft>\n <cross-icon aria-hidden=\"true\" />\n </template>\n </bento-button>\n </div>\n </div>\n </bento-focus-trap>\n </aside>\n </Transition>\n </div>\n</template>\n\n<script setup lang=\"ts\">\n import { computed, nextTick, provide, ref, toRef, watch } from 'vue';\n import { BentoTypography } from '@/components/typography';\n import { BentoButton } from '@/components/button';\n import { BentoLoadingIndicator } from '@/components/loading-indicator';\n import { BentoFocusTrap } from '@/components/focus-trap';\n import ExpandIcon from '@adyen/ui-assets-icons-16/vue/expand';\n import CrossIcon from '@adyen/ui-assets-icons-16/vue/cross';\n\n import { generateUid } from '@/utils/ts/generate-uid';\n import { useI18n } from '@/utils/ts/i18n';\n import { deprecate } from '@/utils/ts/deprecate';\n import { useElementSize } from '@vueuse/core';\n import moveFocusInside, { focusInside, getActiveElement, getFocusableIn } from 'focus-lock';\n\n import { type BentoInspectorProps } from './inspector.types';\n import { useFocusHistory } from './composables/use-focus-history/use-focus-history';\n import {\n DIALOG_PAGE_CONFIG_INJECTION_KEY,\n DIALOG_PAGE_REGISTER_PAGE_INJECTION_KEY,\n } from '@/internal/dialog-page/dialog-page.keys';\n import {\n BentoDialogPageAnimation,\n type BentoDialogPageConfigData,\n type BentoDialogPageRegisterPage,\n } from '@/internal/dialog-page/dialog-page.types';\n\n import messages from './messages.json';\n\n type MessageSchema = (typeof messages)['en-US'];\n\n const props = withDefaults(defineProps<BentoInspectorProps>(), {\n activePage: '',\n expandable: false,\n isOpen: false,\n loading: false,\n size: 'small',\n relativeLayout: 'push-content',\n pageFocusAnchor: null,\n });\n\n const emit = defineEmits<{\n /**\n * Emits update to keep isOpen prop in sync\n */\n (e: 'update:is-open', value: boolean): void;\n /**\n * Emits update to keep activePage prop in sync\n */\n (e: 'update:active-page', value: string): void;\n /**\n * Emits event when user click expand button\n */\n (e: 'expand'): void;\n }>();\n\n const { t } = useI18n<{ message: MessageSchema }>({ messages });\n const returnToMainContentDescriptionId = generateUid('returnToMainContentDescription');\n const wrapper = ref<HTMLElement>(null);\n const inspector = ref<HTMLElement>(null);\n const page = ref<HTMLElement>(null);\n // These refs allow keyboard navigation to follow the intended order independently of the DOM order.\n const returnContentButton = ref(null);\n const expandButton = ref(null);\n const closeButton = ref(null);\n const inspectorLastFocusedElement = ref<HTMLElement>(null);\n const internalActivePage = ref(props.activePage);\n\n // Multiple page navigation\n const pages = ref<Array<string>>([]);\n const previousPages = ref([]);\n const animation = ref(BentoDialogPageAnimation.TRANSITION_LEVEL_DEEPER);\n const isAnimationActive = ref(false);\n\n const { width: wrapperWidth } = useElementSize(wrapper);\n const computedContainerClasses = computed(() => {\n return {\n 'b-inspector__container--padded': pages.value.length === 0, // No pages are registered\n };\n });\n\n const isCompact = computed(() => {\n const COMPACT_THRESHOLD_SMALL = 740;\n const COMPACT_THRESHOLD_LARGE = 915;\n\n // small inspector to occupy full screen if < 740px\n // large inspector to occupy full screen if < 915px\n const threshold = props.size === 'small' ? COMPACT_THRESHOLD_SMALL : COMPACT_THRESHOLD_LARGE;\n\n return wrapperWidth.value > 0 && wrapperWidth.value < threshold;\n });\n\n const computedPageLastFocusedElement = computed(() => props.pageFocusAnchor);\n\n const conditionalClass = computed(() => ({\n [`b-inspector--${props.size}`]: true,\n [`b-inspector--${props.relativeLayout}`]: true,\n [`b-inspector--is-compact`]: isCompact.value,\n [`b-inspector--multi-paged`]: pages.value.length,\n }));\n\n const inspectorAriaLabel = computed(() => `${t('inspector')}, ${props.title}`);\n\n const { findValidFocusFallback } = useFocusHistory(page);\n\n /**\n * Returns the Inspector's intended tab order.\n *\n * The content must remain before the icon buttons in the DOM for the Inspector animations,\n * so the keyboard order is managed separately. The return button is omitted automatically in compact mode.\n */\n const getOrderedFocusableElements = () => {\n const navigationButtons = [\n returnContentButton.value?.$el,\n expandButton.value?.$el,\n closeButton.value?.$el,\n ].filter(Boolean) as Array<HTMLElement>;\n const contentFocusableElements = getFocusableIn(inspector.value)\n .map(({ node }) => node)\n .filter(element => !navigationButtons.includes(element));\n\n return [...navigationButtons, ...contentFocusableElements];\n };\n\n const setFocus = async () => {\n if (props.isOpen) {\n await nextTick();\n if (isCompact.value) {\n // The compact focus trap uses DOM order when it initially moves focus.\n // Explicitly focus the first ordered control so content does not skip the icon buttons.\n focusElement(getOrderedFocusableElements()[0]);\n } else {\n moveFocusInside(inspector.value, computedPageLastFocusedElement.value);\n }\n } else {\n // This doesn't work with data grid cell actions, as the button gets destroyed once is not being hovered.\n // To be reviewed after LevelAccess revision\n focusElement(computedPageLastFocusedElement.value ?? findValidFocusFallback());\n }\n };\n\n const handleTabNavigation = (event: KeyboardEvent) => {\n // Prevent the browser's DOM-based tab order and use the Inspector-specific order instead.\n const direction = event.shiftKey ? -1 : 1;\n const focusableElements = getOrderedFocusableElements();\n const currentIndex = focusableElements.indexOf(getActiveElement());\n const nextIndex = currentIndex + direction;\n\n // Compact inspectors trap focus, so navigation should wrap around instead of returning focus to the page.\n if (isCompact.value && focusableElements.length > 0) {\n event.preventDefault();\n focusableElements[(nextIndex + focusableElements.length) % focusableElements.length].focus();\n return;\n }\n\n const focusableEl = focusableElements[nextIndex];\n\n // At either end of the Inspector, return focus to the page.\n if (!focusableEl) {\n event.preventDefault();\n inspectorLastFocusedElement.value = document.activeElement as HTMLElement;\n focusElement(computedPageLastFocusedElement.value ?? findValidFocusFallback());\n // Set active-page as undefined when focus is not on page\n emit('update:active-page', undefined);\n return;\n }\n\n event.preventDefault();\n focusableEl.focus();\n };\n\n const handleSectionFocus = event => {\n const sectionShortcut = event.shiftKey && event.ctrlKey && event.key === 'S';\n if (props.isOpen && !isCompact.value && sectionShortcut) {\n moveFocusBetweenSections();\n }\n };\n\n const moveFocusBetweenSections = () => {\n if (focusInside(inspector.value)) {\n inspectorLastFocusedElement.value = document.activeElement as HTMLElement;\n focusElement(computedPageLastFocusedElement.value ?? findValidFocusFallback());\n // Set active-page as undefined when focus is not on page\n emit('update:active-page', undefined);\n } else {\n focusElement(inspectorLastFocusedElement.value);\n }\n };\n\n const focusElement = (element: HTMLElement) => {\n if (!element) {\n return;\n }\n element?.focus();\n if (document.activeElement !== element) {\n focusElement(element.parentElement);\n }\n };\n\n /**\n * Multiple page navigation and page registration\n */\n\n const updatePage = page => emit('update:active-page', page);\n\n // unregister page if removed / destroyed\n const unregisterPage = (pageIdToRemove: string) => () => {\n pages.value = pages.value?.filter(pageId => pageId !== pageIdToRemove);\n };\n\n const registerPage: BentoDialogPageRegisterPage = pageId => {\n pages.value.push(pageId);\n\n return { unregisterPage: unregisterPage(pageId) };\n };\n\n provide<BentoDialogPageConfigData>(DIALOG_PAGE_CONFIG_INJECTION_KEY, {\n activePage: internalActivePage,\n animation,\n isAnimationActive,\n isOpen: toRef(props, 'isOpen'),\n pages,\n previousPages,\n updatePage,\n });\n\n provide(DIALOG_PAGE_REGISTER_PAGE_INJECTION_KEY, registerPage);\n\n watch(\n () => props.activePage,\n () => {\n if (props.activePage) {\n internalActivePage.value = props.activePage;\n setFocus();\n }\n }\n );\n\n if (!props.activePage) {\n deprecate(\n 'BentoInspector \"active-page\" as optional',\n `Make sure to set the \"active-page\" prop and keep it in sync with \"update:active-page\".\n \"active-page\" prop will be required in the next version`,\n '3.0.0'\n );\n }\n</script>\n\n<script lang=\"ts\">\n /**\n * Inspector allows users to access additional information or details of an object/item. The inspector opens adjacent to the main content, pushing it aside to maintain visibility and accessibility to both the main content and inspector.\n *\n * @example\n * import { BentoInspector } from '@adyen/bento-vue2';\n *\n * export default {\n * components: { BentoInspector },\n * template: `\n * <bento-inspector\n * title=\"Inspector\"\n * size=\"large\"\n * :is-open=\"isOpen\"\n * :active-page=\"activePage\"\n * expandable\n * @update:is-open=\"isOpen = $event\"\n * @update:active-page=\"activePage = $event\"\n * >\n * <template #page>Content of the page</template>\n * <template #content>Content of the inspector</template>\n * </bento-inspector>\n * `\n * }\n */\n export default { i18n: { messages } };\n</script>\n\n<style lang=\"scss\" scoped src=\"./inspector.scss\" />\n"],"names":["useFocusHistory","targetEl","focusHistory","ref","currentActiveElement","useActiveElement","watch","newlyFocusedElement","el","__default__","messages","props","__props","emit","__emit","t","useI18n","returnToMainContentDescriptionId","generateUid","wrapper","inspector","page","returnContentButton","expandButton","closeButton","inspectorLastFocusedElement","internalActivePage","pages","previousPages","animation","BentoDialogPageAnimation","isAnimationActive","wrapperWidth","useElementSize","computedContainerClasses","computed","isCompact","threshold","computedPageLastFocusedElement","conditionalClass","inspectorAriaLabel","findValidFocusFallback","getOrderedFocusableElements","navigationButtons","contentFocusableElements","getFocusableIn","node","element","setFocus$1","nextTick","focusElement","setFocus","handleTabNavigation","event","direction","focusableElements","nextIndex","getActiveElement","focusableEl","handleSectionFocus","sectionShortcut","moveFocusBetweenSections","focusInside","updatePage","page2","unregisterPage","pageIdToRemove","pageId","registerPage","provide","DIALOG_PAGE_CONFIG_INJECTION_KEY","toRef","DIALOG_PAGE_REGISTER_PAGE_INJECTION_KEY","deprecate"],"mappings":";;;;;;;;;;;;;AAQO,SAAAA,GAAAC,GAAA;AAGH,QAAAC,IAAAC,EAAA,CAAA,CAAA,GAEAC,IAAAC,GAAA;AAQA,SAAAC,EAAAF,GAAA,CAAAG,MAAA;AAEI,IAAA,CAAAN,EAAA,SAAA,CAAAM,KAAA,CAAAN,EAAA,MAAA,SAAAM,CAAA,MAKAL,EAAA,MAAA,QAAAK,CAAA,GAEAL,EAAA,MAAA,SAAA,KACIA,EAAA,MAAA,IAAA;AAAA,EACJ,CAAA,GAkBJ;AAAA,IAAO,wBAVP,MAAA;AACI,iBAAAM,KAAAN,EAAA;AACI,YAAAM,KAAA,SAAA,KAAA,SAAAA,CAAA;AACI,iBAAAA;AAIR,aAAA;AAAA,IAAO;AAAA,EAIP;AAER;;;;;;;;;;;;;;;;iFCsSIC,KAAA,EAAA,MAAA,EAAA,UAAAC,EAAA,EAAA;;;;;;;;;;;;;;;AAlPA,UAAAC,IAAAC,GAUAC,IAA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EA5B,EAAA,sBAAA,MAAA,KAEAqC,EAAAzB,EAAA,KAAA;AAAA,IACJ,GAGJyB,IAAA,CAAAH,MAAA;AACI,MAAAA,MAGAA,GAAA,MAAA,GACA,SAAA,kBAAAA,KACIG,EAAAH,EAAA,aAAA;AAAA,IACJ,GAOJgB,KAAA,CAAAC,MAAAnD,EAAA,sBAAAmD,CAAA,GAGAC,KAAA,CAAAC,MAAA,MAAA;AACI,MAAAvC,EAAA,QAAAA,EAAA,OAAA,OAAA,CAAAwC,MAAAA,MAAAD,CAAA;AAAA,IAAqE,GAGzEE,KAAA,CAAAD,OACIxC,EAAA,MAAA,KAAAwC,CAAA,GAEA,EAAA,gBAAAF,GAAAE,CAAA,EAAA;AAGJ,WAAAE,EAAAC,IAAA;AAAA,MAAqE,YAAA5C;AAAA,MACrD,WAAAG;AAAA,MACZ,mBAAAE;AAAA,MACA,QAAAwC,GAAA5D,GAAA,QAAA;AAAA,MAC6B,OAAAgB;AAAA,MAC7B,eAAAC;AAAA,MACA,YAAAmC;AAAA,IACA,CAAA,GAGJM,EAAAG,IAAAJ,EAAA,GAEA9D;AAAA,MAAA,MAAAK,EAAA;AAAA,MACgB,MAAA;AAER,QAAAA,EAAA,eACIe,EAAA,QAAAf,EAAA,YACAqC,EAAA;AAAA,MACJ;AAAA,IACJ,GAGJrC,EAAA,cACI8D;AAAA,MAAA;AAAA,MACI;AAAA;AAAA,MACA;AAAA,IAEA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -1,6 +1,6 @@
1
1
  import { defineComponent as b, provide as I, toRef as R, computed as l, openBlock as i, createBlock as k, resolveDynamicComponent as S, unref as u, normalizeClass as c, withCtx as L, renderSlot as d, useSlots as T, inject as N, ref as r, watch as O, nextTick as x, onMounted as H, createElementBlock as h, createElementVNode as C, createCommentVNode as M } from "vue";
2
2
  import { _ as $ } from "./_plugin-vue_export-helper.CHgC5LLL.js";
3
- import { B as V } from "./typography.wIM07Hbl.js";
3
+ import { B as V } from "./typography.B6elnWpr.js";
4
4
  import { u as j } from "./use-has-slot.CyMiImRQ.js";
5
5
  import { k as P } from "./index.DCpihRYV.js";
6
6
  import "../assets/layout-row.css";
@@ -103,4 +103,4 @@ export {
103
103
  X as a,
104
104
  G as l
105
105
  };
106
- //# sourceMappingURL=layout-row.DijjweVX.js.map
106
+ //# sourceMappingURL=layout-row.X6mPrUu8.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"layout-row.DijjweVX.js","sources":["../../../vue2/src/components/layout/layout.keys.ts","../../../vue2/src/components/layout/layout.vue","../../../vue2/src/components/layout/layout.internal.types.ts","../../../vue2/src/components/layout/components/layout-row/layout-row.vue"],"sourcesContent":["export const LAYOUT_SIZE_INJECTION_KEY = Symbol('Layout size inject key');\n","<template>\n <component :is=\"wrapperElement\" class=\"b-layout\" :class=\"conditionalClasses\">\n <slot />\n </component>\n</template>\n\n<script setup lang=\"ts\">\n import { computed, provide, toRef } from 'vue';\n import { type BentoLayoutProps } from './layout.types';\n import { LAYOUT_SIZE_INJECTION_KEY } from '@/components/layout/layout.keys';\n\n const props = withDefaults(defineProps<BentoLayoutProps>(), {\n size: 'full-width',\n variant: 'page',\n });\n\n provide(LAYOUT_SIZE_INJECTION_KEY, toRef(props, 'size'));\n\n const conditionalClasses = computed(() => ({\n 'b-layout--component': props.variant === 'component',\n }));\n\n const wrapperElement = props.variant === 'page' ? 'main' : 'div';\n</script>\n\n<script lang=\"ts\">\n /**\n * Layout is a basic scaffolding of a page that defines spacing, some functionality and responsive behavior of its top level sections.\n *\n * @example\n * import { BentoLayout, BentoLayoutRow } from '@adyen/bento-vue2';\n *\n * export default {\n * components: { BentoLayout, BentoLayoutRow },\n * template: `\n * <bento-layout size=\"narrow\">\n * <bento-layout-row>\n * Row 1\n * </bento-layout-row>\n * <bento-layout-row>\n * Row 2\n * </bento-layout-row>\n * </bento-layout>\n * `\n * }\n */\n export default {};\n</script>\n\n<style lang=\"scss\" scoped src=\"./layout.scss\" />\n","export const BentoLayoutVariantOptions = ['page', 'component'] as const;\nexport const BentoLayoutSizeOptions = ['full-width', 'narrow', 'half-width'] as const;\nexport const BentoLayoutRowColumnLayoutOptions = ['3-9', '9-3', '4-8', '8-4', '6-6'] as const;\n","<template>\n <bento-typography el=\"div\" class=\"b-layout-row\" :class=\"conditionalRowClass\">\n <div v-if=\"hasSlot('default')\" class=\"b-layout-row__wrapper\">\n <slot />\n </div>\n <div v-else-if=\"hasSlot('col-1') && hasSlot('col-2')\" ref=\"row\" :class=\"conditionalRowWithColumnsClass\">\n <div ref=\"col1\" :class=\"conditionalColumnClass.col1\">\n <slot name=\"col-1\"></slot>\n </div>\n <div ref=\"col2\" :class=\"conditionalColumnClass.col2\">\n <slot name=\"col-2\"></slot>\n </div>\n </div>\n </bento-typography>\n</template>\n\n<script setup lang=\"ts\">\n import { computed, inject, nextTick, onMounted, ref, type Ref, useSlots, watch } from 'vue';\n import { BentoTypography } from '@/components/typography';\n import { useHasSlot } from '@/composables';\n import { BentoLayoutRowColumnLayoutOptions } from '../../layout.internal.types';\n import { type BentoLayoutRowProps, type BentoLayoutSize } from '../../layout.types';\n import { useMediaQuery } from '@vueuse/core';\n\n import { LAYOUT_SIZE_INJECTION_KEY } from '@/components/layout/layout.keys';\n\n const props = withDefaults(defineProps<BentoLayoutRowProps>(), {\n columnsLayout: '6-6',\n fullHeight: false,\n });\n\n const slots = useSlots();\n const hasSlot = useHasSlot(slots);\n const size = inject<Ref<BentoLayoutSize>>(LAYOUT_SIZE_INJECTION_KEY, ref('full-width'));\n\n const row = ref<HTMLElement>(null);\n const col1 = ref<HTMLElement>(null);\n const col2 = ref<HTMLElement>(null);\n\n const isFullWidth = computed(() => size.value === 'full-width');\n const isValidColumnLayout = computed(() => BentoLayoutRowColumnLayoutOptions.includes(props.columnsLayout));\n\n const conditionalRowClass = computed(() => ({\n [`b-layout-row--${size.value}`]: true,\n 'b-layout-row--full-height': props.fullHeight,\n }));\n\n const conditionalRowWithColumnsClass = computed(() => ({\n 'b-layout-row__column-wrapper': isFullWidth.value,\n }));\n\n const conditionalColumnClass = computed(() => {\n const columns = isValidColumnLayout.value ? props.columnsLayout.split('-') : [6, 6];\n const getColumnModifier = index => (isFullWidth.value ? columns[index] : size.value);\n\n return {\n col1: `b-layout-row__column--${getColumnModifier(0)}`,\n col2: `b-layout-row__column--${getColumnModifier(1)}`,\n };\n });\n\n watch(\n useMediaQuery('(min-width: 768px)'),\n async isLargeScreen => {\n await nextTick();\n const areColumnsInTheRightOrder = row.value?.firstChild === col1.value;\n if (isLargeScreen && !areColumnsInTheRightOrder) {\n row.value?.prepend(col1.value);\n } else if (!isLargeScreen && (props.columnsLayout === '3-9' || props.columnsLayout === '4-8')) {\n row.value?.prepend(col2.value);\n }\n },\n { immediate: true }\n );\n\n onMounted(() => {\n if (!isFullWidth.value && (hasSlot('col-1') || hasSlot('col-2'))) {\n throw new Error(\n 'Column slots can only be used with the `full-width` size. Please check documentation for more info.'\n );\n }\n\n if (!isValidColumnLayout.value) {\n throw new Error(\n `${props.columnsLayout} is not a valid column layout. Please refer to the documentation for the list of available column layouts.`\n );\n }\n });\n</script>\n\n<script lang=\"ts\">\n /**\n * Page row is subcomponent of Layout meant to be used to generate the row layout.\n *\n * @example\n * import { BentoLayout, BentoLayoutRow } from '@adyen/bento-vue2';\n *\n * export default {\n * components: { BentoLayout, BentoLayoutRow },\n * template: `\n * <bento-layout>\n * <bento-layout-row columns-layout=\"3-9\">\n * <template #col-1>Narrow 3-9</template>\n * <template #col-2>Wide 3-9</template>\n * </bento-layout-row>\n * <bento-layout-row>\n * <template #col-1>6-6</template>\n * <template #col-2>6-6</template>\n * </bento-layout-row>\n * </bento-layout>\n * `\n * }\n */\n export default {};\n</script>\n\n<style lang=\"scss\" scoped src=\"./layout-row.scss\" />\n"],"names":["LAYOUT_SIZE_INJECTION_KEY","__default__$1","props","__props","provide","toRef","conditionalClasses","computed","wrapperElement","BentoLayoutRowColumnLayoutOptions","__default__","slots","useSlots","hasSlot","useHasSlot","size","inject","ref","row","col1","col2","isFullWidth","isValidColumnLayout","conditionalRowClass","conditionalRowWithColumnsClass","conditionalColumnClass","columns","getColumnModifier","index","watch","useMediaQuery","isLargeScreen","nextTick","areColumnsInTheRightOrder","onMounted"],"mappings":";;;;;;AAAO,MAAAA,IAAA,uBAAA,wBAAA,GC8CHC,IAAA,CAAA;;;;;;;;AAnCA,UAAAC,IAAAC;AAKA,IAAAC,EAAAJ,GAAAK,EAAAH,GAAA,MAAA,CAAA;AAEA,UAAAI,IAAAC,EAAA,OAAA;AAAA,MAA2C,uBAAAL,EAAA,YAAA;AAAA,IACE,EAAA,GAG7CM,IAAAN,EAAA,YAAA,SAAA,SAAA;;;;;;;;;;kECpBGO,IAAA,CAAA,OAAA,OAAA,OAAA,OAAA,KAAA;;;GC+GHC,IAAA,CAAA;;;;;;;;AAvFA,UAAAR,IAAAC,GAKAQ,IAAAC,EAAA,GACAC,IAAAC,EAAAH,CAAA,GACAI,IAAAC,EAAAhB,GAAAiB,EAAA,YAAA,CAAA,GAEAC,IAAAD,EAAA,IAAA,GACAE,IAAAF,EAAA,IAAA,GACAG,IAAAH,EAAA,IAAA,GAEAI,IAAAd,EAAA,MAAAQ,EAAA,UAAA,YAAA,GACAO,IAAAf,EAAA,MAAAE,EAAA,SAAAP,EAAA,aAAA,CAAA,GAEAqB,IAAAhB,EAAA,OAAA;AAAA,MAA4C,CAAA,iBAAAQ,EAAA,KAAA,EAAA,GAAA;AAAA,MACP,6BAAAb,EAAA;AAAA,IACE,EAAA,GAGvCsB,IAAAjB,EAAA,OAAA;AAAA,MAAuD,gCAAAc,EAAA;AAAA,IACP,EAAA,GAGhDI,IAAAlB,EAAA,MAAA;AACI,YAAAmB,IAAAJ,EAAA,QAAApB,EAAA,cAAA,MAAA,GAAA,IAAA,CAAA,GAAA,CAAA,GACAyB,IAAA,CAAAC,MAAAP,EAAA,QAAAK,EAAAE,CAAA,IAAAb,EAAA;AAEA,aAAA;AAAA,QAAO,MAAA,yBAAAY,EAAA,CAAA,CAAA;AAAA,QACgD,MAAA,yBAAAA,EAAA,CAAA,CAAA;AAAA,MACA;AAAA,IACvD,CAAA;AAGJ,WAAAE;AAAA,MAAAC,EAAA,oBAAA;AAAA,MACsC,OAAAC,MAAA;AAE9B,cAAAC,EAAA;AACA,cAAAC,IAAAf,EAAA,OAAA,eAAAC,EAAA;AACA,QAAAY,KAAA,CAAAE,IACIf,EAAA,OAAA,QAAAC,EAAA,KAAA,IAA6B,CAAAY,MAAA7B,EAAA,kBAAA,SAAAA,EAAA,kBAAA,UAE7BgB,EAAA,OAAA,QAAAE,EAAA,KAAA;AAAA,MACJ;AAAA,MACJ,EAAA,WAAA,GAAA;AAAA,IACkB,GAGtBc,EAAA,MAAA;AACI,UAAA,CAAAb,EAAA,UAAAR,EAAA,OAAA,KAAAA,EAAA,OAAA;AACI,cAAA,IAAA;AAAA,UAAU;AAAA,QACN;AAIR,UAAA,CAAAS,EAAA;AACI,cAAA,IAAA;AAAA,UAAU,GAAApB,EAAA,aAAA;AAAA,QACgB;AAAA,IAE9B,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"layout-row.X6mPrUu8.js","sources":["../../../vue2/src/components/layout/layout.keys.ts","../../../vue2/src/components/layout/layout.vue","../../../vue2/src/components/layout/layout.internal.types.ts","../../../vue2/src/components/layout/components/layout-row/layout-row.vue"],"sourcesContent":["export const LAYOUT_SIZE_INJECTION_KEY = Symbol('Layout size inject key');\n","<template>\n <component :is=\"wrapperElement\" class=\"b-layout\" :class=\"conditionalClasses\">\n <slot />\n </component>\n</template>\n\n<script setup lang=\"ts\">\n import { computed, provide, toRef } from 'vue';\n import { type BentoLayoutProps } from './layout.types';\n import { LAYOUT_SIZE_INJECTION_KEY } from '@/components/layout/layout.keys';\n\n const props = withDefaults(defineProps<BentoLayoutProps>(), {\n size: 'full-width',\n variant: 'page',\n });\n\n provide(LAYOUT_SIZE_INJECTION_KEY, toRef(props, 'size'));\n\n const conditionalClasses = computed(() => ({\n 'b-layout--component': props.variant === 'component',\n }));\n\n const wrapperElement = props.variant === 'page' ? 'main' : 'div';\n</script>\n\n<script lang=\"ts\">\n /**\n * Layout is a basic scaffolding of a page that defines spacing, some functionality and responsive behavior of its top level sections.\n *\n * @example\n * import { BentoLayout, BentoLayoutRow } from '@adyen/bento-vue2';\n *\n * export default {\n * components: { BentoLayout, BentoLayoutRow },\n * template: `\n * <bento-layout size=\"narrow\">\n * <bento-layout-row>\n * Row 1\n * </bento-layout-row>\n * <bento-layout-row>\n * Row 2\n * </bento-layout-row>\n * </bento-layout>\n * `\n * }\n */\n export default {};\n</script>\n\n<style lang=\"scss\" scoped src=\"./layout.scss\" />\n","export const BentoLayoutVariantOptions = ['page', 'component'] as const;\nexport const BentoLayoutSizeOptions = ['full-width', 'narrow', 'half-width'] as const;\nexport const BentoLayoutRowColumnLayoutOptions = ['3-9', '9-3', '4-8', '8-4', '6-6'] as const;\n","<template>\n <bento-typography el=\"div\" class=\"b-layout-row\" :class=\"conditionalRowClass\">\n <div v-if=\"hasSlot('default')\" class=\"b-layout-row__wrapper\">\n <slot />\n </div>\n <div v-else-if=\"hasSlot('col-1') && hasSlot('col-2')\" ref=\"row\" :class=\"conditionalRowWithColumnsClass\">\n <div ref=\"col1\" :class=\"conditionalColumnClass.col1\">\n <slot name=\"col-1\"></slot>\n </div>\n <div ref=\"col2\" :class=\"conditionalColumnClass.col2\">\n <slot name=\"col-2\"></slot>\n </div>\n </div>\n </bento-typography>\n</template>\n\n<script setup lang=\"ts\">\n import { computed, inject, nextTick, onMounted, ref, type Ref, useSlots, watch } from 'vue';\n import { BentoTypography } from '@/components/typography';\n import { useHasSlot } from '@/composables';\n import { BentoLayoutRowColumnLayoutOptions } from '../../layout.internal.types';\n import { type BentoLayoutRowProps, type BentoLayoutSize } from '../../layout.types';\n import { useMediaQuery } from '@vueuse/core';\n\n import { LAYOUT_SIZE_INJECTION_KEY } from '@/components/layout/layout.keys';\n\n const props = withDefaults(defineProps<BentoLayoutRowProps>(), {\n columnsLayout: '6-6',\n fullHeight: false,\n });\n\n const slots = useSlots();\n const hasSlot = useHasSlot(slots);\n const size = inject<Ref<BentoLayoutSize>>(LAYOUT_SIZE_INJECTION_KEY, ref('full-width'));\n\n const row = ref<HTMLElement>(null);\n const col1 = ref<HTMLElement>(null);\n const col2 = ref<HTMLElement>(null);\n\n const isFullWidth = computed(() => size.value === 'full-width');\n const isValidColumnLayout = computed(() => BentoLayoutRowColumnLayoutOptions.includes(props.columnsLayout));\n\n const conditionalRowClass = computed(() => ({\n [`b-layout-row--${size.value}`]: true,\n 'b-layout-row--full-height': props.fullHeight,\n }));\n\n const conditionalRowWithColumnsClass = computed(() => ({\n 'b-layout-row__column-wrapper': isFullWidth.value,\n }));\n\n const conditionalColumnClass = computed(() => {\n const columns = isValidColumnLayout.value ? props.columnsLayout.split('-') : [6, 6];\n const getColumnModifier = index => (isFullWidth.value ? columns[index] : size.value);\n\n return {\n col1: `b-layout-row__column--${getColumnModifier(0)}`,\n col2: `b-layout-row__column--${getColumnModifier(1)}`,\n };\n });\n\n watch(\n useMediaQuery('(min-width: 768px)'),\n async isLargeScreen => {\n await nextTick();\n const areColumnsInTheRightOrder = row.value?.firstChild === col1.value;\n if (isLargeScreen && !areColumnsInTheRightOrder) {\n row.value?.prepend(col1.value);\n } else if (!isLargeScreen && (props.columnsLayout === '3-9' || props.columnsLayout === '4-8')) {\n row.value?.prepend(col2.value);\n }\n },\n { immediate: true }\n );\n\n onMounted(() => {\n if (!isFullWidth.value && (hasSlot('col-1') || hasSlot('col-2'))) {\n throw new Error(\n 'Column slots can only be used with the `full-width` size. Please check documentation for more info.'\n );\n }\n\n if (!isValidColumnLayout.value) {\n throw new Error(\n `${props.columnsLayout} is not a valid column layout. Please refer to the documentation for the list of available column layouts.`\n );\n }\n });\n</script>\n\n<script lang=\"ts\">\n /**\n * Page row is subcomponent of Layout meant to be used to generate the row layout.\n *\n * @example\n * import { BentoLayout, BentoLayoutRow } from '@adyen/bento-vue2';\n *\n * export default {\n * components: { BentoLayout, BentoLayoutRow },\n * template: `\n * <bento-layout>\n * <bento-layout-row columns-layout=\"3-9\">\n * <template #col-1>Narrow 3-9</template>\n * <template #col-2>Wide 3-9</template>\n * </bento-layout-row>\n * <bento-layout-row>\n * <template #col-1>6-6</template>\n * <template #col-2>6-6</template>\n * </bento-layout-row>\n * </bento-layout>\n * `\n * }\n */\n export default {};\n</script>\n\n<style lang=\"scss\" scoped src=\"./layout-row.scss\" />\n"],"names":["LAYOUT_SIZE_INJECTION_KEY","__default__$1","props","__props","provide","toRef","conditionalClasses","computed","wrapperElement","BentoLayoutRowColumnLayoutOptions","__default__","slots","useSlots","hasSlot","useHasSlot","size","inject","ref","row","col1","col2","isFullWidth","isValidColumnLayout","conditionalRowClass","conditionalRowWithColumnsClass","conditionalColumnClass","columns","getColumnModifier","index","watch","useMediaQuery","isLargeScreen","nextTick","areColumnsInTheRightOrder","onMounted"],"mappings":";;;;;;AAAO,MAAAA,IAAA,uBAAA,wBAAA,GC8CHC,IAAA,CAAA;;;;;;;;AAnCA,UAAAC,IAAAC;AAKA,IAAAC,EAAAJ,GAAAK,EAAAH,GAAA,MAAA,CAAA;AAEA,UAAAI,IAAAC,EAAA,OAAA;AAAA,MAA2C,uBAAAL,EAAA,YAAA;AAAA,IACE,EAAA,GAG7CM,IAAAN,EAAA,YAAA,SAAA,SAAA;;;;;;;;;;kECpBGO,IAAA,CAAA,OAAA,OAAA,OAAA,OAAA,KAAA;;;GC+GHC,IAAA,CAAA;;;;;;;;AAvFA,UAAAR,IAAAC,GAKAQ,IAAAC,EAAA,GACAC,IAAAC,EAAAH,CAAA,GACAI,IAAAC,EAAAhB,GAAAiB,EAAA,YAAA,CAAA,GAEAC,IAAAD,EAAA,IAAA,GACAE,IAAAF,E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;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -1,5 +1,5 @@
1
1
  import { getCurrentInstance as B, openBlock as o, createElementBlock as l, mergeProps as g, toDisplayString as b, createCommentVNode as f, createElementVNode as $, defineComponent as w, computed as d, createBlock as p, unref as r, withCtx as c, renderSlot as i, createVNode as C } from "vue";
2
- import { B as v } from "./typography.wIM07Hbl.js";
2
+ import { B as v } from "./typography.B6elnWpr.js";
3
3
  import { RouterLink as T } from "vue-router";
4
4
  /* empty css */
5
5
  import { _ as N } from "./_plugin-vue_export-helper.CHgC5LLL.js";
@@ -107,4 +107,4 @@ export {
107
107
  V as _,
108
108
  S as a
109
109
  };
110
- //# sourceMappingURL=link.types.BGj7apK3.js.map
110
+ //# sourceMappingURL=link.types.BZ1u_6CS.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"link.types.BGj7apK3.js","sources":["../../../ui-assets/icons-16/dist/vue/external-link.vue","../../src/components/link/link.vue","../../../vue2/src/components/link/link.types.ts"],"sourcesContent":["\n<template>\n <svg role=\"img\" v-bind=\"$attrs\" class=\"ui-assets-icons-16\" xmlns=\"http://www.w3.org/2000/svg\" width=\"16\" height=\"16\" fill=\"none\"><title v-if=\"$attrs['svg-title']\">{{ $attrs['svg-title'] }}</title><path fill=\"#001222\" d=\"M2.93933 11.9999L10.1893 4.74989H5.24999V3.24989H12.75V10.7499H11.25V5.81055L3.99999 13.0605L2.93933 11.9999Z\"/></svg>\n</template>\n<script setup>\n import { getCurrentInstance } from 'vue';\n import '../css/main.css';\n\n const instance = getCurrentInstance();\n const uuid = String(instance?.uid ?? instance?.proxy?._uid);\n</script>\n","<template>\n <a\n v-if=\"external || isNotRouting\"\n v-bind=\"$attrs\"\n :href=\"to?.toString()\"\n :target=\"computedTarget\"\n :class=\"conditionalClasses\"\n @click=\"onClick\"\n >\n <bento-typography v-if=\"!disableTypography\" class=\"b-link__text\" el=\"span\" variant=\"body\">\n <slot />\n </bento-typography>\n <slot v-else />\n <span v-if=\"showExternalLinkIcon\" class=\"b-link__external-link-icon\">\n <external-link-icon aria-hidden=\"true\" />\n </span>\n </a>\n <router-link\n v-else\n v-bind=\"{ ...props, ...$attrs, ...nonForwardedProps }\"\n :to=\"props.to\"\n :class=\"conditionalClasses\"\n :target=\"target\"\n @click=\"onClick\"\n >\n <bento-typography v-if=\"!disableTypography\" class=\"b-link__text\" el=\"span\" variant=\"body\">\n <slot />\n </bento-typography>\n <slot v-else />\n </router-link>\n</template>\n\n<script setup lang=\"ts\">\n import { BentoTypography } from '@/components/typography';\n import { computed } from 'vue';\n import { RouterLink } from 'vue-router';\n import type { BentoLinkProps } from './link.types';\n\n import ExternalLinkIcon from '@adyen/ui-assets-icons-16/vue/external-link';\n\n const props = withDefaults(defineProps<BentoLinkProps>(), {\n target: null,\n variant: 'default',\n });\n\n // Props that should not be forwarded to the underlying anchor element\n const nonForwardedProps = {\n variant: undefined,\n isButton: undefined,\n truncate: undefined,\n disableTypography: undefined,\n external: undefined,\n isNotRouting: undefined,\n };\n\n const emit = defineEmits(['click']);\n const conditionalClasses = computed(() => ({\n 'b-link': !props.isButton,\n [`b-link--quiet`]: props.variant === 'quiet',\n [`b-link--truncate`]: props.truncate,\n }));\n const computedTarget = computed(() => (props.external ? (props.target ?? '_blank') : props.target));\n const showExternalLinkIcon = computed(() => !(props.isButton || props.isNotRouting));\n\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n const onClick = (e: MouseEvent, navigateCallback?: any) => {\n emit('click', e);\n if (navigateCallback) {\n navigateCallback();\n }\n };\n</script>\n\n<style lang=\"scss\" scoped src=\"@/bento/components/link/link.scss\" />\n","import type { Location } from 'vue-router/types/router.d.ts';\n// TODO: revert to import once fully migrated to Vue 3\n// import type { RouterLinkProps } from 'vue-router/types/router.d.ts';\n\n/**\n * Manually defined RouterLinkProps to ensure compatibility\n * with Vue Macros and Vue 2.7 / 3 monorepos.\n */\nexport interface RouterLinkProps {\n /**\n * Denotes the target route of the link. When clicked, the value of the `to` prop will be passed to\n * `router.push()` internally, so the value can be either a string or a location descriptor object.\n */\n to: string | Location;\n /**\n * Setting `replace` prop will call `router.replace()` instead of `router.push()` when clicked, so the navigation will\n * not create a new history record.\n *\n * @default false\n */\n replace?: boolean;\n /**\n * Setting `append` prop always appends the relative path to the current path. For example, assuming we are navigating\n * from `/a` to a relative link `b`, without `append` we will end up at `/b`, but with append we will end up at\n * `/a/b`.\n *\n * @default false\n */\n append?: boolean;\n /**\n * Sometimes we want <RouterLink> to render as another tag, e.g <li>. Then we can use tag prop to specify which tag to\n * render to, and it will still listen to click events for navigation.\n *\n * @default \"a\"\n */\n tag?: string;\n /**\n * Configure the active CSS class applied when the link is active. Note the default value can also be configured\n * globally via the `linkActiveClass` router constructor option.\n *\n * @default \"router-link-active\"\n */\n activeClass?: string;\n /**\n * The default active class matching behavior is **inclusive match**. For example, `<RouterLink to=\"/a\">` will get\n * this class applied as long as the current path starts with `/a/` or is `/a`.\n *\n * @default false\n */\n exact?: boolean;\n /**\n * Allows matching only using the `path` section of the url, effectively ignoring the `query` and the `hash` sections.\n *\n * @default false\n */\n exactPath?: boolean;\n /**\n * Configure the active CSS class applied when the link is active with exact path match. Note the default value can\n * also be configured globally via the `linkExactPathActiveClass` router constructor option.\n *\n * @default \"router-link-exact-path-active\"\n */\n exactPathActiveClass?: string;\n\n /**\n * Specify the event(s) that can trigger the link navigation.\n *\n * @default 'click'\n */\n event?: string | ReadonlyArray<string>;\n /**\n * Configure the active CSS class applied when the link is active with exact match. Note the default value can also be\n * configured globally via the `linkExactActiveClass` router constructor option.\n *\n * @default \"router-link-exact-active\"\n */\n exactActiveClass?: string;\n /**\n * Configure the value of `aria-current` when the link is active with exact match. It must be one of the allowed\n * values for [aria-current](https://www.w3.org/TR/wai-aria-1.2/#aria-current) in the ARIA spec. In most cases, the\n * default of page should be the best fit.\n *\n * @default \"page\"\n */\n ariaCurrentValue?: 'page' | 'step' | 'location' | 'date' | 'time' | 'true' | 'false';\n}\n\n/**\n * @deprecated Since v2.0.0. Use string literal instead.\n */\nexport enum BentoLinkVariant {\n DEFAULT = 'default',\n QUIET = 'quiet',\n}\n\nexport interface LinkProps {\n /**\n * Disable the default typography for the component. Only use this when the component is inside another typography component.\n */\n disableTypography?: boolean;\n\n /**\n * Set the rendered link to a regular external anchor link and renders an external link icon.\n */\n external?: boolean;\n\n /**\n * Set to true if used inside a `BentoButton` component.\n */\n isButton?: boolean;\n\n /**\n * Set the rendered link to a regular external anchor link.\n */\n isNotRouting?: boolean;\n\n /**\n * Sets the target of the rendered link.\n */\n target?: string;\n\n /**\n * Set to true to truncate link. Doesn't work with disableTypography.\n */\n truncate?: boolean;\n\n /**\n * Link variant type affecting visual style.\n * @values default, quiet\n */\n variant?: BentoLinkVariant | `${BentoLinkVariant}`;\n}\n\nexport type BentoLinkProps = RouterLinkProps & LinkProps;\n"],"names":["instance","getCurrentInstance","props","__props","nonForwardedProps","emit","__emit","conditionalClasses","computed","computedTarget","showExternalLinkIcon","onClick","navigateCallback","BentoLinkVariant","BentoLinkVariant2"],"mappings":";;;;;;;;;AAKA,UAAAA,IAAAC,EAAA;AAIA,kBAAAD,GAAA,OAAAA,GAAA,OAAA,IAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AC+BI,UAAAE,IAAAC,GAMAC,IAAA;AAAA,MAA0B,SAAA;AAAA,MACb,UAAA;AAAA,MACC,UAAA;AAAA,MACA,mBAAA;AAAA,MACS,UAAA;AAAA,MACT,cAAA;AAAA,IACI,GAGlBC,IAAAC,GACAC,IAAAC,EAAA,OAAA;AAAA,MAA2C,UAAA,CAAAN,EAAA;AAAA,MACtB,iBAAAA,EAAA,YAAA;AAAA,MACoB,oBAAAA,EAAA;AAAA,IACT,EAAA,GAEhCO,IAAAD,EAAA,MAAAN,EAAA,WAAAA,EAAA,UAAA,WAAAA,EAAA,MAAA,GACAQ,IAAAF,EAAA,MAAA,EAAAN,EAAA,YAAAA,EAAA,aAAA,GAGAS,IAAA,CAAA,GAAAC,MAAA;AACI,MAAAP,EAAA,SAAA,CAAA,GACAO,KACIA,EAAA;AAAA,IACJ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;ACqBD,IAAAC,IAAA,kBAAAC,OACHA,EAAA,UAAA,WACAA,EAAA,QAAA,SAFQA,IAAAD,KAAA,CAAA,CAAA;"}
1
+ {"version":3,"file":"link.types.BZ1u_6CS.js","sources":["../../../ui-assets/icons-16/dist/vue/external-link.vue","../../src/components/link/link.vue","../../../vue2/src/components/link/link.types.ts"],"sourcesContent":["\n<template>\n <svg role=\"img\" v-bind=\"$attrs\" class=\"ui-assets-icons-16\" xmlns=\"http://www.w3.org/2000/svg\" width=\"16\" height=\"16\" fill=\"none\"><title v-if=\"$attrs['svg-title']\">{{ $attrs['svg-title'] }}</title><path fill=\"#001222\" d=\"M2.93933 11.9999L10.1893 4.74989H5.24999V3.24989H12.75V10.7499H11.25V5.81055L3.99999 13.0605L2.93933 11.9999Z\"/></svg>\n</template>\n<script setup>\n import { getCurrentInstance } from 'vue';\n import '../css/main.css';\n\n const instance = getCurrentInstance();\n const uuid = String(instance?.uid ?? instance?.proxy?._uid);\n</script>\n","<template>\n <a\n v-if=\"external || isNotRouting\"\n v-bind=\"$attrs\"\n :href=\"to?.toString()\"\n :target=\"computedTarget\"\n :class=\"conditionalClasses\"\n @click=\"onClick\"\n >\n <bento-typography v-if=\"!disableTypography\" class=\"b-link__text\" el=\"span\" variant=\"body\">\n <slot />\n </bento-typography>\n <slot v-else />\n <span v-if=\"showExternalLinkIcon\" class=\"b-link__external-link-icon\">\n <external-link-icon aria-hidden=\"true\" />\n </span>\n </a>\n <router-link\n v-else\n v-bind=\"{ ...props, ...$attrs, ...nonForwardedProps }\"\n :to=\"props.to\"\n :class=\"conditionalClasses\"\n :target=\"target\"\n @click=\"onClick\"\n >\n <bento-typography v-if=\"!disableTypography\" class=\"b-link__text\" el=\"span\" variant=\"body\">\n <slot />\n </bento-typography>\n <slot v-else />\n </router-link>\n</template>\n\n<script setup lang=\"ts\">\n import { BentoTypography } from '@/components/typography';\n import { computed } from 'vue';\n import { RouterLink } from 'vue-router';\n import type { BentoLinkProps } from './link.types';\n\n import ExternalLinkIcon from '@adyen/ui-assets-icons-16/vue/external-link';\n\n const props = withDefaults(defineProps<BentoLinkProps>(), {\n target: null,\n variant: 'default',\n });\n\n // Props that should not be forwarded to the underlying anchor element\n const nonForwardedProps = {\n variant: undefined,\n isButton: undefined,\n truncate: undefined,\n disableTypography: undefined,\n external: undefined,\n isNotRouting: undefined,\n };\n\n const emit = defineEmits(['click']);\n const conditionalClasses = computed(() => ({\n 'b-link': !props.isButton,\n [`b-link--quiet`]: props.variant === 'quiet',\n [`b-link--truncate`]: props.truncate,\n }));\n const computedTarget = computed(() => (props.external ? (props.target ?? '_blank') : props.target));\n const showExternalLinkIcon = computed(() => !(props.isButton || props.isNotRouting));\n\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n const onClick = (e: MouseEvent, navigateCallback?: any) => {\n emit('click', e);\n if (navigateCallback) {\n navigateCallback();\n }\n };\n</script>\n\n<style lang=\"scss\" scoped src=\"@/bento/components/link/link.scss\" />\n","import type { Location } from 'vue-router/types/router.d.ts';\n// TODO: revert to import once fully migrated to Vue 3\n// import type { RouterLinkProps } from 'vue-router/types/router.d.ts';\n\n/**\n * Manually defined RouterLinkProps to ensure compatibility\n * with Vue Macros and Vue 2.7 / 3 monorepos.\n */\nexport interface RouterLinkProps {\n /**\n * Denotes the target route of the link. When clicked, the value of the `to` prop will be passed to\n * `router.push()` internally, so the value can be either a string or a location descriptor object.\n */\n to: string | Location;\n /**\n * Setting `replace` prop will call `router.replace()` instead of `router.push()` when clicked, so the navigation will\n * not create a new history record.\n *\n * @default false\n */\n replace?: boolean;\n /**\n * Setting `append` prop always appends the relative path to the current path. For example, assuming we are navigating\n * from `/a` to a relative link `b`, without `append` we will end up at `/b`, but with append we will end up at\n * `/a/b`.\n *\n * @default false\n */\n append?: boolean;\n /**\n * Sometimes we want <RouterLink> to render as another tag, e.g <li>. Then we can use tag prop to specify which tag to\n * render to, and it will still listen to click events for navigation.\n *\n * @default \"a\"\n */\n tag?: string;\n /**\n * Configure the active CSS class applied when the link is active. Note the default value can also be configured\n * globally via the `linkActiveClass` router constructor option.\n *\n * @default \"router-link-active\"\n */\n activeClass?: string;\n /**\n * The default active class matching behavior is **inclusive match**. For example, `<RouterLink to=\"/a\">` will get\n * this class applied as long as the current path starts with `/a/` or is `/a`.\n *\n * @default false\n */\n exact?: boolean;\n /**\n * Allows matching only using the `path` section of the url, effectively ignoring the `query` and the `hash` sections.\n *\n * @default false\n */\n exactPath?: boolean;\n /**\n * Configure the active CSS class applied when the link is active with exact path match. Note the default value can\n * also be configured globally via the `linkExactPathActiveClass` router constructor option.\n *\n * @default \"router-link-exact-path-active\"\n */\n exactPathActiveClass?: string;\n\n /**\n * Specify the event(s) that can trigger the link navigation.\n *\n * @default 'click'\n */\n event?: string | ReadonlyArray<string>;\n /**\n * Configure the active CSS class applied when the link is active with exact match. Note the default value can also be\n * configured globally via the `linkExactActiveClass` router constructor option.\n *\n * @default \"router-link-exact-active\"\n */\n exactActiveClass?: string;\n /**\n * Configure the value of `aria-current` when the link is active with exact match. It must be one of the allowed\n * values for [aria-current](https://www.w3.org/TR/wai-aria-1.2/#aria-current) in the ARIA spec. In most cases, the\n * default of page should be the best fit.\n *\n * @default \"page\"\n */\n ariaCurrentValue?: 'page' | 'step' | 'location' | 'date' | 'time' | 'true' | 'false';\n}\n\n/**\n * @deprecated Since v3.0.0. Use string literal instead.\n */\nexport enum BentoLinkVariant {\n DEFAULT = 'default',\n QUIET = 'quiet',\n}\n\nexport interface LinkProps {\n /**\n * Disable the default typography for the component. Only use this when the component is inside another typography component.\n */\n disableTypography?: boolean;\n\n /**\n * Set the rendered link to a regular external anchor link and renders an external link icon.\n */\n external?: boolean;\n\n /**\n * Set to true if used inside a `BentoButton` component.\n */\n isButton?: boolean;\n\n /**\n * Set the rendered link to a regular external anchor link.\n */\n isNotRouting?: boolean;\n\n /**\n * Sets the target of the rendered link.\n */\n target?: string;\n\n /**\n * Set to true to truncate link. Doesn't work with disableTypography.\n */\n truncate?: boolean;\n\n /**\n * Link variant type affecting visual style.\n * @values default, quiet\n */\n variant?: BentoLinkVariant | `${BentoLinkVariant}`;\n}\n\nexport type BentoLinkProps = RouterLinkProps & LinkProps;\n"],"names":["instance","getCurrentInstance","props","__props","nonForwardedProps","emit","__emit","conditionalClasses","computed","computedTarget","showExternalLinkIcon","onClick","navigateCallback","BentoLinkVariant","BentoLinkVariant2"],"mappings":";;;;;;;;;AAKA,UAAAA,IAAAC,EAAA;AAIA,kBAAAD,GAAA,OAAAA,GAAA,OAAA,IAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AC+BI,UAAAE,IAAAC,GAMAC,IAAA;AAAA,MAA0B,SAAA;AAAA,MACb,UAAA;AAAA,MACC,UAAA;AAAA,MACA,mBAAA;AAAA,MACS,UAAA;AAAA,MACT,cAAA;AAAA,IACI,GAGlBC,IAAAC,GACAC,IAAAC,EAAA,OAAA;AAAA,MAA2C,UAAA,CAAAN,EAAA;AAAA,MACtB,iBAAAA,EAAA,YAAA;AAAA,MACoB,oBAAAA,EAAA;AAAA,IACT,EAAA,GAEhCO,IAAAD,EAAA,MAAAN,EAAA,WAAAA,EAAA,UAAA,WAAAA,EAAA,MAAA,GACAQ,IAAAF,EAAA,MAAA,EAAAN,EAAA,YAAAA,EAAA,aAAA,GAGAS,IAAA,CAAA,GAAAC,MAAA;AACI,MAAAP,EAAA,SAAA,CAAA,GACAO,KACIA,EAAA;AAAA,IACJ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;ACqBD,IAAAC,IAAA,kBAAAC,OACHA,EAAA,UAAA,WACAA,EAAA,QAAA,SAFQA,IAAAD,KAAA,CAAA,CAAA;"}
@@ -1,13 +1,13 @@
1
1
  import { defineComponent as U, computed as v, ref as T, watch as F, provide as J, openBlock as o, createElementBlock as c, createBlock as p, resolveDynamicComponent as P, mergeProps as H, withCtx as E, renderSlot as f, toDisplayString as $, unref as s, createCommentVNode as n, useSlots as q, inject as X, createVNode as Y, normalizeClass as Q, createElementVNode as R, Fragment as W, createTextVNode as Z } from "vue";
2
2
  import { l as ee } from "./index.DCpihRYV.js";
3
- import { d as te, u as oe, a as se, B as le } from "./draggable-handle.Cvc8gHzx.js";
3
+ import { d as te, u as oe, a as se, B as le } from "./draggable-handle.CKkSJP0K.js";
4
4
  import { _ as V } from "./_plugin-vue_export-helper.CHgC5LLL.js";
5
5
  import { _ as ae } from "./chevron-right-small.B8-YvBnS.js";
6
- import { B as ie } from "./status.Nss4P5OU.js";
7
- import { B as ne } from "./tag.BE1j0Oid.js";
8
- import { B as A } from "./typography.wIM07Hbl.js";
6
+ import { B as ie } from "./status.BJ48Isyh.js";
7
+ import { B as ne } from "./tag.BYxa556o.js";
8
+ import { B as A } from "./typography.B6elnWpr.js";
9
9
  import { u as re } from "./use-has-slot.CyMiImRQ.js";
10
- import { u as me } from "./index.B875RXHM.js";
10
+ import { u as me } from "./index.CGBfMQdv.js";
11
11
  import "../assets/list-item.css";
12
12
  const j = /* @__PURE__ */ Symbol("list draggable injection key"), de = { class: "b-list" }, ce = {
13
13
  key: 0,
@@ -229,4 +229,4 @@ export {
229
229
  xe as a,
230
230
  Le as l
231
231
  };
232
- //# sourceMappingURL=list-item.CT7dyMQH.js.map
232
+ //# sourceMappingURL=list-item.RuGQ8Y4T.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"list-item.CT7dyMQH.js","sources":["../../../vue2/src/components/list/list.keys.ts","../../../vue2/src/components/list/list.vue","../../../vue2/src/components/list/components/list-item/list-item.vue"],"sourcesContent":["import type { ComputedRef } from 'vue';\nimport type { BentoDraggableDisabledMenus } from '@/components/draggable/composables/use-bento-draggable/use-bento-draggable';\n\nexport interface BentoListDraggableContext {\n isDraggable: ComputedRef<boolean>;\n moveItemUp: (element: HTMLElement | null) => void;\n moveItemDown: (element: HTMLElement | null) => void;\n moveItemTop: (element: HTMLElement | null) => void;\n moveItemBottom: (element: HTMLElement | null) => void;\n getDisabledMenus: (element: HTMLElement | null) => BentoDraggableDisabledMenus;\n}\n\nexport const BENTO_LIST_DRAGGABLE_INJECTION_KEY = Symbol('list draggable injection key');\n","<template>\n <div class=\"b-list\">\n <component :is=\"listElement\" ref=\"listRef\" v-bind=\"$attrs\" class=\"b-list__list\">\n <slot />\n </component>\n\n <div v-if=\"isDraggable\" class=\"b-list__announcement\" role=\"status\" aria-live=\"polite\">\n {{ announcementMessage }}\n </div>\n </div>\n</template>\n\n<script setup lang=\"ts\">\n import { useMutationObserver } from '@vueuse/core';\n import { computed, provide, ref, watch } from 'vue';\n import { useBentoDraggable } from '@/components/draggable/composables/use-bento-draggable/use-bento-draggable';\n import { useDraggableAnnouncement } from '@/components/draggable/composables/use-draggable-announcement/use-draggable-announcement';\n import type { BentoDraggableOptions, BentoDraggableSortableEvent } from '@/components/draggable/draggable.types';\n import { BENTO_LIST_DRAGGABLE_INJECTION_KEY } from './list.keys';\n import type { BentoListDraggableContext } from './list.keys';\n import type { BentoListProps } from './list.types';\n\n // used for announcement composable\n import draggableMessages from '@/components/draggable/composables/use-draggable-announcement/messages.json';\n\n const ITEM_SELECTOR = '.b-list-item';\n\n const props = withDefaults(defineProps<BentoListProps>(), {\n type: 'unordered',\n draggable: false,\n draggableOptions: () => ({}),\n });\n\n const emit = defineEmits<{\n /**\n * Emitted after items are reordered, with the old and new indices.\n */\n (e: 'reorder', value: { oldIndex: number; newIndex: number }): void;\n }>();\n\n const listElement = computed(() => (props.type === 'ordered' ? 'ol' : 'ul'));\n const listRef = ref<HTMLElement | null>(null);\n const listItems = ref<Array<HTMLElement>>([]);\n const isDraggable = computed(() => props.draggable);\n\n const getListItems = (): Array<HTMLElement> =>\n listRef.value\n ? (Array.from(listRef.value.children).filter(child => child.matches(ITEM_SELECTOR)) as Array<HTMLElement>)\n : [];\n\n const syncListItems = () => {\n listItems.value = getListItems();\n };\n\n watch(\n listRef,\n newElement => {\n if (!newElement) {\n listItems.value = [];\n return;\n }\n\n syncListItems();\n },\n { immediate: true }\n );\n\n useMutationObserver(listRef, syncListItems, { childList: true });\n\n const getItemIndex = (el: HTMLElement | null) => (el ? listItems.value.indexOf(el) : -1);\n\n const getItemLabel = (el: HTMLElement | null, fallbackIndex: number) =>\n el?.querySelector('[data-list-item-label]')?.textContent?.trim() || `List item ${fallbackIndex + 1}`;\n\n const announceMoveAt = (fromIndex: number, toIndex: number) => {\n if (!isDraggable.value) {\n return;\n }\n\n const items = getListItems();\n announceMove({\n itemLabel: getItemLabel(items[toIndex] ?? null, toIndex),\n fromIndex,\n toIndex,\n total: items.length,\n announcement: props.draggableOptions?.dragAnnouncement,\n });\n };\n\n const moveItemDOM = (fromIndex: number, toIndex: number) => {\n const items = getListItems();\n const itemToMove = items[fromIndex];\n const targetItem = items[toIndex];\n\n if (fromIndex < toIndex) {\n listRef.value!.insertBefore(itemToMove, targetItem.nextSibling);\n } else {\n listRef.value!.insertBefore(itemToMove, targetItem);\n }\n\n syncListItems();\n announceMoveAt(fromIndex, toIndex);\n emit('reorder', { oldIndex: fromIndex, newIndex: toIndex });\n };\n\n const computedDraggableOptions = computed<BentoDraggableOptions>(() => ({\n ...props.draggableOptions,\n onSort: (event: BentoDraggableSortableEvent) => {\n syncListItems();\n if (event.oldIndex !== undefined && event.newIndex !== undefined) {\n announceMoveAt(event.oldIndex, event.newIndex);\n emit('reorder', { oldIndex: event.oldIndex, newIndex: event.newIndex });\n }\n props.draggableOptions?.onSort?.(event);\n },\n }));\n\n const { announcementMessage, announceMove } = useDraggableAnnouncement();\n\n const { moveItemUp, moveItemDown, moveItemTop, moveItemBottom, getDisabledMenus } = useBentoDraggable(\n listRef,\n computedDraggableOptions,\n {\n getItemCount: () => listItems.value.length,\n getItemIndex,\n onMoveItem: moveItemDOM,\n }\n );\n\n provide<BentoListDraggableContext>(BENTO_LIST_DRAGGABLE_INJECTION_KEY, {\n isDraggable,\n moveItemUp,\n moveItemDown,\n moveItemTop,\n moveItemBottom,\n getDisabledMenus,\n });\n</script>\n\n<script lang=\"ts\">\n /**\n * `BentoList` renders an ordered or unordered list container for `BentoListItem` rows.\n *\n * @example\n * import { BentoList, BentoListItem } from '@adyen/bento-vue2';\n *\n * export default {\n * components: { BentoList, BentoListItem },\n * template: `\n * <bento-list>\n * <bento-list-item\n * label=\"Payment details\"\n * description=\"Updated 2 hours ago\"\n * :tag=\"{ label: 'Live', variant: 'green' }\"\n * show-bottom-divider\n * />\n * <bento-list-item\n * label=\"Risk configuration\"\n * description=\"Updated yesterday\"\n * :tag=\"{ label: 'Review', variant: 'orange' }\"\n * />\n * </bento-list>\n * `\n * }\n */\n\n export default {\n name: 'bento-list',\n inheritAttrs: false,\n i18n: { messages: draggableMessages },\n };\n</script>\n\n<style lang=\"scss\" scoped src=\"./list.scss\" />\n","<template>\n <li ref=\"itemRef\" class=\"b-list-item\" @click=\"onItemClick\" @keydown=\"onItemKeydown\">\n <bento-typography\n class=\"b-list-item__inner\"\n :class=\"conditionalClasses\"\n el=\"div\"\n :role=\"props.withChevron ? 'button' : undefined\"\n :tabindex=\"props.withChevron ? 0 : undefined\"\n >\n <div v-if=\"hasSlot('image')\" class=\"b-list-item__image\">\n <slot name=\"image\" />\n </div>\n\n <bento-draggable-handle\n v-if=\"showDragHandle\"\n condensed\n :label=\"dragHandleLabel\"\n :disabled-menus=\"disabledMenus\"\n :disabled=\"draggableOptions?.disabled\"\n @move-up=\"moveItemUp\"\n @move-down=\"moveItemDown\"\n @move-top=\"moveItemTop\"\n @move-bottom=\"moveItemBottom\"\n />\n\n <div v-if=\"hasSlot('start')\" class=\"b-list-item__start\">\n <slot v-if=\"hasSlot('start')\" name=\"start\" />\n </div>\n\n <div class=\"b-list-item__content\">\n <div v-if=\"hasSlot('content')\" class=\"b-list-item__label\" data-list-item-label>\n <slot name=\"content\" />\n </div>\n\n <template v-else>\n <div class=\"b-list-item__header\">\n <bento-typography\n v-if=\"props.label\"\n class=\"b-list-item__label\"\n data-list-item-label\n el=\"span\"\n stronger\n >\n {{ props.label }}\n </bento-typography>\n <bento-status\n v-if=\"props.showStatus\"\n class=\"b-list-item__status\"\n :variant=\"props.statusColor\"\n aria-hidden=\"true\"\n />\n <bento-tag v-if=\"props.tag\" v-bind=\"props.tag\" class=\"b-list-item__tag\" />\n </div>\n <span v-if=\"props.description\" class=\"b-list-item__description\">\n {{ props.description }}\n </span>\n </template>\n </div>\n\n <div v-if=\"hasSlot('end')\" class=\"b-list-item__end\">\n <slot name=\"end\" />\n </div>\n\n <chevron-right-icon v-if=\"props.withChevron\" class=\"b-list-item__chevron\" aria-hidden=\"true\" />\n </bento-typography>\n </li>\n</template>\n\n<script setup lang=\"ts\">\n import { computed, inject, ref, useSlots } from 'vue';\n import ChevronRightIcon from '@adyen/ui-assets-icons-16/vue/chevron-right-small';\n import { BentoDraggableHandle } from '@/components/draggable/components/draggable-handle';\n import { BentoStatus } from '@/components/status';\n import { BentoTag } from '@/components/tag';\n import { BentoTypography } from '@/components/typography';\n import { useHasSlot } from '@/composables';\n import { useI18n } from '@/utils/ts/i18n';\n import { BENTO_LIST_DRAGGABLE_INJECTION_KEY } from '../../list.keys';\n import type { BentoListDraggableContext } from '../../list.keys';\n import type { BentoListItemProps } from './list-item.types';\n import messages from './messages.json';\n\n type MessageSchema = (typeof messages)['en-US'];\n\n const slots = useSlots();\n const hasSlot = useHasSlot(slots);\n const itemRef = ref<HTMLElement | null>(null);\n const draggableContext = inject<BentoListDraggableContext | null>(BENTO_LIST_DRAGGABLE_INJECTION_KEY, null);\n const { t } = useI18n<{ message: MessageSchema }>({ messages });\n\n const props = withDefaults(defineProps<BentoListItemProps>(), {\n draggableOptions: null,\n showStatus: false,\n statusColor: 'blue',\n tag: undefined,\n withChevron: false,\n showTopDivider: false,\n showBottomDivider: false,\n });\n\n const emit = defineEmits<{\n /**\n * Emitted when a clickable list item is triggered.\n */\n (e: 'click'): void;\n /**\n * Emitted when the item is moved up via the drag handle menu.\n */\n (e: 'move-up'): void;\n /**\n * Emitted when the item is moved down via the drag handle menu.\n */\n (e: 'move-down'): void;\n /**\n * Emitted when the item is moved to the top via the drag handle menu.\n */\n (e: 'move-top'): void;\n /**\n * Emitted when the item is moved to the bottom via the drag handle menu.\n */\n (e: 'move-bottom'): void;\n }>();\n\n const onItemClick = (): void => {\n if (!props.withChevron) {\n return;\n }\n emit('click');\n };\n\n const onItemKeydown = (event: KeyboardEvent): void => {\n if (!props.withChevron) {\n return;\n }\n if (event.key === 'Enter' || event.key === ' ') {\n event.preventDefault();\n emit('click');\n }\n };\n\n const conditionalClasses = computed(() => ({\n 'b-list-item__inner--clickable': props.withChevron,\n 'b-list-item__inner--top-divider': props.showTopDivider,\n 'b-list-item__inner--bottom-divider': props.showBottomDivider,\n }));\n\n const showDragHandle = computed(() => Boolean(draggableContext?.isDraggable.value));\n const dragHandleLabel = computed(() => props.draggableOptions?.label || props.label || t('listItem'));\n const disabledMenus = computed(() => {\n if (props.draggableOptions?.disabledMenus) {\n return props.draggableOptions.disabledMenus;\n }\n\n return draggableContext?.getDisabledMenus(itemRef.value);\n });\n\n const moveItemUp = () => {\n emit('move-up');\n (props.draggableOptions?.moveUp ?? (() => draggableContext?.moveItemUp(itemRef.value)))();\n };\n\n const moveItemDown = () => {\n emit('move-down');\n (props.draggableOptions?.moveDown ?? (() => draggableContext?.moveItemDown(itemRef.value)))();\n };\n\n const moveItemTop = () => {\n emit('move-top');\n (props.draggableOptions?.moveTop ?? (() => draggableContext?.moveItemTop(itemRef.value)))();\n };\n\n const moveItemBottom = () => {\n emit('move-bottom');\n (props.draggableOptions?.moveBottom ?? (() => draggableContext?.moveItemBottom(itemRef.value)))();\n };\n</script>\n\n<script lang=\"ts\">\n /**\n * `BentoListItem` renders an item to be used inside `BentoList`.\n *\n * @example\n * import { BentoList, BentoListItem, BentoButton, BentoToggle } from '@adyen/bento-vue2';\n *\n * export default {\n * components: { BentoList, BentoListItem, BentoButton, BentoToggle },\n * template: `\n * <bento-list>\n * <bento-list-item\n * label=\"Payment details\"\n * description=\"Updated 2 hours ago\"\n * :tag=\"{ label: 'Live', variant: 'green' }\"\n * show-bottom-divider\n * >\n * <template #start>\n * <bento-toggle />\n * </template>\n * <template #end>\n * <bento-button variant=\"secondary\">Edit</bento-button>\n * </template>\n * </bento-list-item>\n * </bento-list>\n * `\n * }\n */\n\n export default {\n name: 'bento-list-item',\n i18n: { messages },\n };\n</script>\n\n<style lang=\"scss\" scoped src=\"./list-item.scss\" />\n"],"names":["BENTO_LIST_DRAGGABLE_INJECTION_KEY","__default__$1","draggableMessages","ITEM_SELECTOR","props","__props","emit","__emit","listElement","computed","listRef","ref","listItems","isDraggable","getListItems","child","syncListItems","watch","newElement","useMutationObserver","getItemIndex","el","getItemLabel","fallbackIndex","announceMoveAt","fromIndex","toIndex","items","announceMove","moveItemDOM","itemToMove","targetItem","computedDraggableOptions","event","announcementMessage","useDraggableAnnouncement","moveItemUp","moveItemDown","moveItemTop","moveItemBottom","getDisabledMenus","useBentoDraggable","provide","__default__","messages","slots","useSlots","hasSlot","useHasSlot","itemRef","draggableContext","inject","t","useI18n","onItemClick","onItemKeydown","conditionalClasses","showDragHandle","dragHandleLabel","disabledMenus"],"mappings":";;;;;;;;;;;AAYO,MAAAA,IAAA,uBAAA,8BAAA;;;;;GC0JHC,KAAA;AAAA,EAAe,MAAA;AAAA,EACL,cAAA;AAAA,EACQ,MAAA,EAAA,UAAAC,GAAA;AAElB;;;;;;;;;AAjJA,UAAAC,IAAA,gBAEAC,IAAAC,GAMAC,IAAAC,GAOAC,IAAAC,EAAA,MAAAL,EAAA,SAAA,YAAA,OAAA,IAAA,GACAM,IAAAC,EAAA,IAAA,GACAC,IAAAD,EAAA,CAAA,CAAA,GACAE,IAAAJ,EAAA,MAAAL,EAAA,SAAA,GAEAU,IAAA,MAAAJ,EAAA,QAAA,MAAA,KAAAA,EAAA,MAAA,QAAA,EAAA,OAAA,CAAAK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GACA3B,EAAA,OAAA;AAAA,IACJ,GAGJkD,IAAA/C,EAAA,OAAA;AAAA,MAA2C,iCAAAL,EAAA;AAAA,MACA,mCAAAA,EAAA;AAAA,MACE,sCAAAA,EAAA;AAAA,IACG,EAAA,GAGhDqD,IAAAhD,EAAA,MAAA,EAAAyC,GAAA,YAAA,KAAA,GACAQ,IAAAjD,EAAA,MAAAL,EAAA,kBAAA,SAAAA,EAAA,SAAAgD,EAAA,UAAA,CAAA,GACAO,IAAAlD,EAAA,MACIL,EAAA,kBAAA,gBACIA,EAAA,iBAAA,gBAGJ8C,GAAA,iBAAAD,EAAA,KAAA,CAAuD,GAG3Db,IAAA,MAAA;AACI,MAAA9B,EAAA,SAAA,IACAF,EAAA,kBAAA,WAAA,MAAA8C,GAAA,WAAAD,EAAA,KAAA,IAAA;AAAA,IAAwF,GAG5FZ,IAAA,MAAA;AACI,MAAA/B,EAAA,WAAA,IACAF,EAAA,kBAAA,aAAA,MAAA8C,GAAA,aAAAD,EAAA,KAAA,IAAA;AAAA,IAA4F,GAGhGX,IAAA,MAAA;AACI,MAAAhC,EAAA,UAAA,IACAF,EAAA,kBAAA,YAAA,MAAA8C,GAAA,YAAAD,EAAA,KAAA,IAAA;AAAA,IAA0F,GAG9FV,IAAA,MAAA;AACI,MAAAjC,EAAA,aAAA,IACAF,EAAA,kBAAA,eAAA,MAAA8C,GAAA,eAAAD,EAAA,KAAA,IAAA;AAAA,IAAgG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"list-item.RuGQ8Y4T.js","sources":["../../../vue2/src/components/list/list.keys.ts","../../../vue2/src/components/list/list.vue","../../../vue2/src/components/list/components/list-item/list-item.vue"],"sourcesContent":["import type { ComputedRef } from 'vue';\nimport type { BentoDraggableDisabledMenus } from '@/components/draggable/composables/use-bento-draggable/use-bento-draggable';\n\nexport interface BentoListDraggableContext {\n isDraggable: ComputedRef<boolean>;\n moveItemUp: (element: HTMLElement | null) => void;\n moveItemDown: (element: HTMLElement | null) => void;\n moveItemTop: (element: HTMLElement | null) => void;\n moveItemBottom: (element: HTMLElement | null) => void;\n getDisabledMenus: (element: HTMLElement | null) => BentoDraggableDisabledMenus;\n}\n\nexport const BENTO_LIST_DRAGGABLE_INJECTION_KEY = Symbol('list draggable injection key');\n","<template>\n <div class=\"b-list\">\n <component :is=\"listElement\" ref=\"listRef\" v-bind=\"$attrs\" class=\"b-list__list\">\n <slot />\n </component>\n\n <div v-if=\"isDraggable\" class=\"b-list__announcement\" role=\"status\" aria-live=\"polite\">\n {{ announcementMessage }}\n </div>\n </div>\n</template>\n\n<script setup lang=\"ts\">\n import { useMutationObserver } from '@vueuse/core';\n import { computed, provide, ref, watch } from 'vue';\n import { useBentoDraggable } from '@/components/draggable/composables/use-bento-draggable/use-bento-draggable';\n import { useDraggableAnnouncement } from '@/components/draggable/composables/use-draggable-announcement/use-draggable-announcement';\n import type { BentoDraggableOptions, BentoDraggableSortableEvent } from '@/components/draggable/draggable.types';\n import { BENTO_LIST_DRAGGABLE_INJECTION_KEY } from './list.keys';\n import type { BentoListDraggableContext } from './list.keys';\n import type { BentoListProps } from './list.types';\n\n // used for announcement composable\n import draggableMessages from '@/components/draggable/composables/use-draggable-announcement/messages.json';\n\n const ITEM_SELECTOR = '.b-list-item';\n\n const props = withDefaults(defineProps<BentoListProps>(), {\n type: 'unordered',\n draggable: false,\n draggableOptions: () => ({}),\n });\n\n const emit = defineEmits<{\n /**\n * Emitted after items are reordered, with the old and new indices.\n */\n (e: 'reorder', value: { oldIndex: number; newIndex: number }): void;\n }>();\n\n const listElement = computed(() => (props.type === 'ordered' ? 'ol' : 'ul'));\n const listRef = ref<HTMLElement | null>(null);\n const listItems = ref<Array<HTMLElement>>([]);\n const isDraggable = computed(() => props.draggable);\n\n const getListItems = (): Array<HTMLElement> =>\n listRef.value\n ? (Array.from(listRef.value.children).filter(child => child.matches(ITEM_SELECTOR)) as Array<HTMLElement>)\n : [];\n\n const syncListItems = () => {\n listItems.value = getListItems();\n };\n\n watch(\n listRef,\n newElement => {\n if (!newElement) {\n listItems.value = [];\n return;\n }\n\n syncListItems();\n },\n { immediate: true }\n );\n\n useMutationObserver(listRef, syncListItems, { childList: true });\n\n const getItemIndex = (el: HTMLElement | null) => (el ? listItems.value.indexOf(el) : -1);\n\n const getItemLabel = (el: HTMLElement | null, fallbackIndex: number) =>\n el?.querySelector('[data-list-item-label]')?.textContent?.trim() || `List item ${fallbackIndex + 1}`;\n\n const announceMoveAt = (fromIndex: number, toIndex: number) => {\n if (!isDraggable.value) {\n return;\n }\n\n const items = getListItems();\n announceMove({\n itemLabel: getItemLabel(items[toIndex] ?? null, toIndex),\n fromIndex,\n toIndex,\n total: items.length,\n announcement: props.draggableOptions?.dragAnnouncement,\n });\n };\n\n const moveItemDOM = (fromIndex: number, toIndex: number) => {\n const items = getListItems();\n const itemToMove = items[fromIndex];\n const targetItem = items[toIndex];\n\n if (fromIndex < toIndex) {\n listRef.value!.insertBefore(itemToMove, targetItem.nextSibling);\n } else {\n listRef.value!.insertBefore(itemToMove, targetItem);\n }\n\n syncListItems();\n announceMoveAt(fromIndex, toIndex);\n emit('reorder', { oldIndex: fromIndex, newIndex: toIndex });\n };\n\n const computedDraggableOptions = computed<BentoDraggableOptions>(() => ({\n ...props.draggableOptions,\n onSort: (event: BentoDraggableSortableEvent) => {\n syncListItems();\n if (event.oldIndex !== undefined && event.newIndex !== undefined) {\n announceMoveAt(event.oldIndex, event.newIndex);\n emit('reorder', { oldIndex: event.oldIndex, newIndex: event.newIndex });\n }\n props.draggableOptions?.onSort?.(event);\n },\n }));\n\n const { announcementMessage, announceMove } = useDraggableAnnouncement();\n\n const { moveItemUp, moveItemDown, moveItemTop, moveItemBottom, getDisabledMenus } = useBentoDraggable(\n listRef,\n computedDraggableOptions,\n {\n getItemCount: () => listItems.value.length,\n getItemIndex,\n onMoveItem: moveItemDOM,\n }\n );\n\n provide<BentoListDraggableContext>(BENTO_LIST_DRAGGABLE_INJECTION_KEY, {\n isDraggable,\n moveItemUp,\n moveItemDown,\n moveItemTop,\n moveItemBottom,\n getDisabledMenus,\n });\n</script>\n\n<script lang=\"ts\">\n /**\n * `BentoList` renders an ordered or unordered list container for `BentoListItem` rows.\n *\n * @example\n * import { BentoList, BentoListItem } from '@adyen/bento-vue2';\n *\n * export default {\n * components: { BentoList, BentoListItem },\n * template: `\n * <bento-list>\n * <bento-list-item\n * label=\"Payment details\"\n * description=\"Updated 2 hours ago\"\n * :tag=\"{ label: 'Live', variant: 'green' }\"\n * show-bottom-divider\n * />\n * <bento-list-item\n * label=\"Risk configuration\"\n * description=\"Updated yesterday\"\n * :tag=\"{ label: 'Review', variant: 'orange' }\"\n * />\n * </bento-list>\n * `\n * }\n */\n\n export default {\n name: 'bento-list',\n inheritAttrs: false,\n i18n: { messages: draggableMessages },\n };\n</script>\n\n<style lang=\"scss\" scoped src=\"./list.scss\" />\n","<template>\n <li ref=\"itemRef\" class=\"b-list-item\" @click=\"onItemClick\" @keydown=\"onItemKeydown\">\n <bento-typography\n class=\"b-list-item__inner\"\n :class=\"conditionalClasses\"\n el=\"div\"\n :role=\"props.withChevron ? 'button' : undefined\"\n :tabindex=\"props.withChevron ? 0 : undefined\"\n >\n <div v-if=\"hasSlot('image')\" class=\"b-list-item__image\">\n <slot name=\"image\" />\n </div>\n\n <bento-draggable-handle\n v-if=\"showDragHandle\"\n condensed\n :label=\"dragHandleLabel\"\n :disabled-menus=\"disabledMenus\"\n :disabled=\"draggableOptions?.disabled\"\n @move-up=\"moveItemUp\"\n @move-down=\"moveItemDown\"\n @move-top=\"moveItemTop\"\n @move-bottom=\"moveItemBottom\"\n />\n\n <div v-if=\"hasSlot('start')\" class=\"b-list-item__start\">\n <slot v-if=\"hasSlot('start')\" name=\"start\" />\n </div>\n\n <div class=\"b-list-item__content\">\n <div v-if=\"hasSlot('content')\" class=\"b-list-item__label\" data-list-item-label>\n <slot name=\"content\" />\n </div>\n\n <template v-else>\n <div class=\"b-list-item__header\">\n <bento-typography\n v-if=\"props.label\"\n class=\"b-list-item__label\"\n data-list-item-label\n el=\"span\"\n stronger\n >\n {{ props.label }}\n </bento-typography>\n <bento-status\n v-if=\"props.showStatus\"\n class=\"b-list-item__status\"\n :variant=\"props.statusColor\"\n aria-hidden=\"true\"\n />\n <bento-tag v-if=\"props.tag\" v-bind=\"props.tag\" class=\"b-list-item__tag\" />\n </div>\n <span v-if=\"props.description\" class=\"b-list-item__description\">\n {{ props.description }}\n </span>\n </template>\n </div>\n\n <div v-if=\"hasSlot('end')\" class=\"b-list-item__end\">\n <slot name=\"end\" />\n </div>\n\n <chevron-right-icon v-if=\"props.withChevron\" class=\"b-list-item__chevron\" aria-hidden=\"true\" />\n </bento-typography>\n </li>\n</template>\n\n<script setup lang=\"ts\">\n import { computed, inject, ref, useSlots } from 'vue';\n import ChevronRightIcon from '@adyen/ui-assets-icons-16/vue/chevron-right-small';\n import { BentoDraggableHandle } from '@/components/draggable/components/draggable-handle';\n import { BentoStatus } from '@/components/status';\n import { BentoTag } from '@/components/tag';\n import { BentoTypography } from '@/components/typography';\n import { useHasSlot } from '@/composables';\n import { useI18n } from '@/utils/ts/i18n';\n import { BENTO_LIST_DRAGGABLE_INJECTION_KEY } from '../../list.keys';\n import type { BentoListDraggableContext } from '../../list.keys';\n import type { BentoListItemProps } from './list-item.types';\n import messages from './messages.json';\n\n type MessageSchema = (typeof messages)['en-US'];\n\n const slots = useSlots();\n const hasSlot = useHasSlot(slots);\n const itemRef = ref<HTMLElement | null>(null);\n const draggableContext = inject<BentoListDraggableContext | null>(BENTO_LIST_DRAGGABLE_INJECTION_KEY, null);\n const { t } = useI18n<{ message: MessageSchema }>({ messages });\n\n const props = withDefaults(defineProps<BentoListItemProps>(), {\n draggableOptions: null,\n showStatus: false,\n statusColor: 'blue',\n tag: undefined,\n withChevron: false,\n showTopDivider: false,\n showBottomDivider: false,\n });\n\n const emit = defineEmits<{\n /**\n * Emitted when a clickable list item is triggered.\n */\n (e: 'click'): void;\n /**\n * Emitted when the item is moved up via the drag handle menu.\n */\n (e: 'move-up'): void;\n /**\n * Emitted when the item is moved down via the drag handle menu.\n */\n (e: 'move-down'): void;\n /**\n * Emitted when the item is moved to the top via the drag handle menu.\n */\n (e: 'move-top'): void;\n /**\n * Emitted when the item is moved to the bottom via the drag handle menu.\n */\n (e: 'move-bottom'): void;\n }>();\n\n const onItemClick = (): void => {\n if (!props.withChevron) {\n return;\n }\n emit('click');\n };\n\n const onItemKeydown = (event: KeyboardEvent): void => {\n if (!props.withChevron) {\n return;\n }\n if (event.key === 'Enter' || event.key === ' ') {\n event.preventDefault();\n emit('click');\n }\n };\n\n const conditionalClasses = computed(() => ({\n 'b-list-item__inner--clickable': props.withChevron,\n 'b-list-item__inner--top-divider': props.showTopDivider,\n 'b-list-item__inner--bottom-divider': props.showBottomDivider,\n }));\n\n const showDragHandle = computed(() => Boolean(draggableContext?.isDraggable.value));\n const dragHandleLabel = computed(() => props.draggableOptions?.label || props.label || t('listItem'));\n const disabledMenus = computed(() => {\n if (props.draggableOptions?.disabledMenus) {\n return props.draggableOptions.disabledMenus;\n }\n\n return draggableContext?.getDisabledMenus(itemRef.value);\n });\n\n const moveItemUp = () => {\n emit('move-up');\n (props.draggableOptions?.moveUp ?? (() => draggableContext?.moveItemUp(itemRef.value)))();\n };\n\n const moveItemDown = () => {\n emit('move-down');\n (props.draggableOptions?.moveDown ?? (() => draggableContext?.moveItemDown(itemRef.value)))();\n };\n\n const moveItemTop = () => {\n emit('move-top');\n (props.draggableOptions?.moveTop ?? (() => draggableContext?.moveItemTop(itemRef.value)))();\n };\n\n const moveItemBottom = () => {\n emit('move-bottom');\n (props.draggableOptions?.moveBottom ?? (() => draggableContext?.moveItemBottom(itemRef.value)))();\n };\n</script>\n\n<script lang=\"ts\">\n /**\n * `BentoListItem` renders an item to be used inside `BentoList`.\n *\n * @example\n * import { BentoList, BentoListItem, BentoButton, BentoToggle } from '@adyen/bento-vue2';\n *\n * export default {\n * components: { BentoList, BentoListItem, BentoButton, BentoToggle },\n * template: `\n * <bento-list>\n * <bento-list-item\n * label=\"Payment details\"\n * description=\"Updated 2 hours ago\"\n * :tag=\"{ label: 'Live', variant: 'green' }\"\n * show-bottom-divider\n * >\n * <template #start>\n * <bento-toggle />\n * </template>\n * <template #end>\n * <bento-button variant=\"secondary\">Edit</bento-button>\n * </template>\n * </bento-list-item>\n * </bento-list>\n * `\n * }\n */\n\n export default {\n name: 'bento-list-item',\n i18n: { messages },\n };\n</script>\n\n<style lang=\"scss\" scoped src=\"./list-item.scss\" />\n"],"names":["BENTO_LIST_DRAGGABLE_INJECTION_KEY","__default__$1","draggableMessages","ITEM_SELECTOR","props","__props","emit","__emit","listElement","computed","listRef","ref","listItems","isDraggable","getListItems","child","syncListItems","watch","newElement","useMutationObserver","getItemIndex","el","getItemLabel","fallbackIndex","announceMoveAt","fromIndex","toIndex","items","announceMove","moveItemDOM","itemToMove","targetItem","computedDraggableOptions","event","announcementMessage","useDraggableAnnouncement","moveItemUp","moveItemDown","moveItemTop","moveItemBottom","getDisabledMenus","useBentoDraggable","provide","__default__","messages","slots","useSlots","hasSlot","useHasSlot","itemRef","draggableContext","inject","t","useI18n","onItemClick","onItemKeydown","conditionalClasses","showDragHandle","dragHandleLabel","disabledMenus"],"mappings":";;;;;;;;;;;AAYO,MAAAA,IAAA,uBAAA,8BAAA;;;;;GC0JHC,KAAA;AAAA,EAAe,MAAA;AAAA,EACL,cAAA;AAAA,EACQ,MAAA,EAAA,UAAAC,GAAA;AAElB;;;;;;;;;AAjJA,UAAAC,IAAA,gBAEAC,IAAAC,GAMAC,IAAAC,GAOAC,IAAAC,EAAA,MAAAL,EAAA,SAAA,YAAA,OAAA,IAAA,GACAM,IAAAC,EAAA,IAAA,GACAC,IAAAD,EAAA,CAAA,CAAA,GACAE,IAAAJ,EAAA,MAAAL,EAAA,SAAA,GAEAU,IAAA,MAAAJ,EAAA,Q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A6B,EAAA,QAAA,WAAAA,EAAA,QAAA,SACIA,EAAA,eAAA,GACA3B,EAAA,OAAA;AAAA,IACJ,GAGJkD,IAAA/C,EAAA,OAAA;AAAA,MAA2C,iCAAAL,EAAA;AAAA,MACA,mCAAAA,EAAA;AAAA,MACE,sCAAAA,EAAA;AAAA,IACG,EAAA,GAGhDqD,IAAAhD,EAAA,MAAA,EAAAyC,GAAA,YAAA,KAAA,GACAQ,IAAAjD,EAAA,MAAAL,EAAA,kBAAA,SAAAA,EAAA,SAAAgD,EAAA,UAAA,CAAA,GACAO,IAAAlD,EAAA,MACIL,EAAA,kBAAA,gBACIA,EAAA,iBAAA,gBAGJ8C,GAAA,iBAAAD,EAAA,KAAA,CAAuD,GAG3Db,IAAA,MAAA;AACI,MAAA9B,EAAA,SAAA,IACAF,EAAA,kBAAA,WAAA,MAAA8C,GAAA,WAAAD,EAAA,KAAA,IAAA;AAAA,IAAwF,GAG5FZ,IAAA,MAAA;AACI,MAAA/B,EAAA,WAAA,IACAF,EAAA,kBAAA,aAAA,MAAA8C,GAAA,aAAAD,EAAA,KAAA,IAAA;AAAA,IAA4F,GAGhGX,IAAA,MAAA;AACI,MAAAhC,EAAA,UAAA,IACAF,EAAA,kBAAA,YAAA,MAAA8C,GAAA,YAAAD,EAAA,KAAA,IAAA;AAAA,IAA0F,GAG9FV,IAAA,MAAA;AACI,MAAAjC,EAAA,aAAA,IACAF,EAAA,kBAAA,eAAA,MAAA8C,GAAA,eAAAD,EAAA,KAAA,IAAA;AAAA,IAAgG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -1,6 +1,6 @@
1
1
  import { defineComponent as r, computed as i, resolveComponent as t, openBlock as e, createElementBlock as s, createElementVNode as l, createVNode as c, createBlock as m, withCtx as _, createTextVNode as b, toDisplayString as d, createCommentVNode as g } from "vue";
2
- import { B as f } from "./tag.BE1j0Oid.js";
3
- import { B as u } from "./typography.wIM07Hbl.js";
2
+ import { B as f } from "./tag.BYxa556o.js";
3
+ import { B as u } from "./typography.B6elnWpr.js";
4
4
  import { _ as h } from "./_plugin-vue_export-helper.CHgC5LLL.js";
5
5
  import "../assets/listbox-option-tag.css";
6
6
  const y = r({
@@ -54,4 +54,4 @@ const O = /* @__PURE__ */ h(y, [["render", x], ["__scopeId", "data-v-f55ef3b1"]]
54
54
  export {
55
55
  O as L
56
56
  };
57
- //# sourceMappingURL=listbox-option-tag.CwrFdsY1.js.map
57
+ //# sourceMappingURL=listbox-option-tag.71rmQvG8.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"listbox-option-tag.CwrFdsY1.js","sources":["../../../vue2/src/components/internal/listbox/components/listbox-option-tag/listbox-option-tag.vue"],"sourcesContent":["<template>\n <span class=\"b-listbox-tag-option\">\n <span :aria-hidden=\"!!option.label\">\n <bento-tag class=\"b-listbox-tag-option__tag\" :label=\"option.value.toString()\" :variant=\"variant\" />\n </span>\n <bento-typography v-if=\"option.label\" el=\"span\" class=\"b-listbox-tag-option__label\">\n {{ option.label }}\n </bento-typography>\n </span>\n</template>\n<script lang=\"ts\">\n import { computed, defineComponent, type PropType } from 'vue';\n import type { BentoListboxOptionItem } from '@/types/listbox';\n import { BentoTag, type BentoTagVariant } from '@/components/tag';\n import { BentoTypography } from '@/components/typography';\n\n /**\n * A Tag Dropdown option item used in the Dropdown and Filter components.\n */\n export default defineComponent({\n name: 'listbox-tag-option',\n components: {\n BentoTag,\n BentoTypography,\n },\n props: {\n /**\n * The option item that contains all the option item's data.\n * @type {BentoListboxOptionItem}\n */\n option: {\n type: Object as PropType<BentoListboxOptionItem>,\n required: true,\n },\n },\n setup(props) {\n const variant = computed(() => props.option.data as BentoTagVariant);\n\n return {\n // Values\n variant,\n };\n },\n });\n</script>\n<style lang=\"scss\" scoped src=\"./listbox-option-tag.scss\" />\n"],"names":["_sfc_main","defineComponent","BentoTag","BentoTypography","props","computed","openBlock","createElementBlock","_hoisted_1","createElementVNode","_ctx","_hoisted_2","createTextVNode","toDisplayString","createCommentVNode"],"mappings":";;;;;AAmBI,MAAAA,IAAAC,EAAA;AAAA,EAA+B,MAAA;AAAA,EACrB,YAAA;AAAA,IACM,UAAAC;AAAA,IACR,iBAAAC;AAAA,EACA;AAAA,EACJ,OAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IACO,QAAA;AAAA,MAKK,MAAA;AAAA,MACE,UAAA;AAAA,IACI;AAAA,EACd;AAAA,EACJ,MAAAC,GAAA;AAII,WAAA;AAAA;AAAA,MAAO,SAFPC,EAAA,MAAAD,EAAA,OAAA,IAAA;AAAA,IAII;AAAA,EACJ;AAER,CAAA;;;AAzCW,SAAAE,EAAA,GAAAC,EAAA,QAAAC,GAAA;AAAA,IAA2BC,EAAA,QAAA;AAAA;IACqE,GAAA;AAAA;QAAzB,OAAA;AAAA,QAAY,OAAAC,EAAA,OAAA,MAAA,SAAA;AAAA,QAHlG,SAAAA,EAAA;AAAA,MAAA,GAAA,MAAA,GAAA,CAAA,SAAA,SAAA,CAAA;AAAA,IAK4C,GAAA,GAAAC,CAAA;AAAA;MAAW,KAAA;AAAA,MAAM,IAAA;AAAA,MAL7D,OAAA;AAAA,IAAA,GAAA;AAAA;QAAAC,EAAAC,EAAAH,EAAA,OAAA,KAAA,GAAA,CAAA;AAAA,MAAA,CAAA;AAAA,MAAA,GAAA;AAAA,IAAA,CAAA,KAAAI,EAAA,IAAA,EAAA;AAAA;;;"}
1
+ {"version":3,"file":"listbox-option-tag.71rmQvG8.js","sources":["../../../vue2/src/components/internal/listbox/components/listbox-option-tag/listbox-option-tag.vue"],"sourcesContent":["<template>\n <span class=\"b-listbox-tag-option\">\n <span :aria-hidden=\"!!option.label\">\n <bento-tag class=\"b-listbox-tag-option__tag\" :label=\"option.value.toString()\" :variant=\"variant\" />\n </span>\n <bento-typography v-if=\"option.label\" el=\"span\" class=\"b-listbox-tag-option__label\">\n {{ option.label }}\n </bento-typography>\n </span>\n</template>\n<script lang=\"ts\">\n import { computed, defineComponent, type PropType } from 'vue';\n import type { BentoListboxOptionItem } from '@/types/listbox';\n import { BentoTag, type BentoTagVariant } from '@/components/tag';\n import { BentoTypography } from '@/components/typography';\n\n /**\n * A Tag Dropdown option item used in the Dropdown and Filter components.\n */\n export default defineComponent({\n name: 'listbox-tag-option',\n components: {\n BentoTag,\n BentoTypography,\n },\n props: {\n /**\n * The option item that contains all the option item's data.\n * @type {BentoListboxOptionItem}\n */\n option: {\n type: Object as PropType<BentoListboxOptionItem>,\n required: true,\n },\n },\n setup(props) {\n const variant = computed(() => props.option.data as BentoTagVariant);\n\n return {\n // Values\n variant,\n };\n },\n });\n</script>\n<style lang=\"scss\" scoped src=\"./listbox-option-tag.scss\" />\n"],"names":["_sfc_main","defineComponent","BentoTag","BentoTypography","props","computed","openBlock","createElementBlock","_hoisted_1","createElementVNode","_ctx","_hoisted_2","createTextVNode","toDisplayString","createCommentVNode"],"mappings":";;;;;AAmBI,MAAAA,IAAAC,EAAA;AAAA,EAA+B,MAAA;AAAA,EACrB,YAAA;AAAA,IACM,UAAAC;AAAA,IACR,iBAAAC;AAAA,EACA;AAAA,EACJ,OAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IACO,QAAA;AAAA,MAKK,MAAA;AAAA,MACE,UAAA;AAAA,IACI;AAAA,EACd;AAAA,EACJ,MAAAC,GAAA;AAII,WAAA;AAAA;AAAA,MAAO,SAFPC,EAAA,MAAAD,EAAA,OAAA,IAAA;AAAA,IAII;AAAA,EACJ;AAER,CAAA;;;AAzCW,SAAAE,EAAA,GAAAC,EAAA,QAAAC,GAAA;AAAA,IAA2BC,EAAA,QAAA;AAAA;IACqE,GAAA;AAAA;QAAzB,OAAA;AAAA,QAAY,OAAAC,EAAA,OAAA,MAAA,SAAA;AAAA,QAHlG,SAAAA,EAAA;AAAA,MAAA,GAAA,MAAA,GAAA,CAAA,SAAA,SAAA,CAAA;AAAA,IAK4C,GAAA,GAAAC,CAAA;AAAA;MAAW,KAAA;AAAA,MAAM,IAAA;AAAA,MAL7D,OAAA;AAAA,IAAA,GAAA;AAAA;QAAAC,EAAAC,EAAAH,EAAA,OAAA,KAAA,GAAA,CAAA;AAAA,MAAA,CAAA;AAAA,MAAA,GAAA;AAAA,IAAA,CAAA,KAAAI,EAAA,IAAA,EAAA;AAAA;;;"}
@@ -1,13 +1,13 @@
1
1
  import { defineComponent as M, useSlots as x, inject as A, onMounted as R, openBlock as l, createBlock as c, unref as e, withCtx as n, renderSlot as h, createElementVNode as v, createTextVNode as O, toDisplayString as T, createCommentVNode as p, createElementBlock as w, createVNode as k, getCurrentInstance as X, toRefs as q, ref as r, computed as Q, onUnmounted as W, watch as Z, provide as g, withKeys as ee, withModifiers as te, normalizeClass as ae, createSlots as le } from "vue";
2
- import { B as oe } from "./toast.u5Y_CGe_.js";
2
+ import { B as oe } from "./toast.BI2PD8Oj.js";
3
3
  import { B as se } from "./focus-trap.Co-S6goa.js";
4
- import { B as ne } from "./button.Ciflfide.js";
5
- import { B as D } from "./typography.wIM07Hbl.js";
4
+ import { B as ne } from "./button.DAcwNdtP.js";
5
+ import { B as D } from "./typography.B6elnWpr.js";
6
6
  import { u as G } from "./use-has-slot.CyMiImRQ.js";
7
- import { u as ie } from "./index.B875RXHM.js";
8
- import { i as $, j as K, B as re, k as ce } from "./button-actions.uIjzze43.js";
7
+ import { u as ie } from "./index.CGBfMQdv.js";
8
+ import { i as $, j as K, B as re, k as ce } from "./button-actions.DvuGEQxM.js";
9
9
  import { _ as ue } from "./cross.Daa8LxjC.js";
10
- import { D as de } from "./dialog-page.D60pjDsQ.js";
10
+ import { D as de } from "./dialog-page.CHpFuDd9.js";
11
11
  import { _ as J } from "./_plugin-vue_export-helper.CHgC5LLL.js";
12
12
  import { g as F } from "./generate-uid.DBWe4g6T.js";
13
13
  import { B as fe, D as me, a as pe } from "./dialog-page.keys.Dym9e6k3.js";
@@ -28,10 +28,10 @@ const U = {
28
28
  key: 0,
29
29
  class: "b-modal-fullscreen-page__header-section b-modal-fullscreen-page__header-section--slot"
30
30
  }, he = { class: "b-modal-fullscreen-page__header-section b-modal-fullscreen-page__header-section--actions" }, be = { class: "b-modal-fullscreen-page__close-button" }, ye = {
31
- i18n: { messages: U }
31
+ i18n: { messages: U },
32
+ name: "bento-modal-fullscreen-page"
32
33
  }, Ee = /* @__PURE__ */ M({
33
34
  ...ye,
34
- __name: "modal-fullscreen-page",
35
35
  props: {
36
36
  /**
37
37
  * List of actions that will be used to render the buttons.
@@ -158,7 +158,7 @@ const U = {
158
158
  _: 3
159
159
  }, 8, ["page-id", "previous-page"]));
160
160
  }
161
- }), Ie = /* @__PURE__ */ J(Ee, [["__scopeId", "data-v-8579bda1"]]);
161
+ }), Ie = /* @__PURE__ */ J(Ee, [["__scopeId", "data-v-5fbd3730"]]);
162
162
  function Ce() {
163
163
  return X()?.vnode.props ?? {};
164
164
  }
@@ -299,4 +299,4 @@ export {
299
299
  Je as B,
300
300
  Ie as a
301
301
  };
302
- //# sourceMappingURL=modal-fullscreen.I5bjqzfd.js.map
302
+ //# sourceMappingURL=modal-fullscreen.jXJnaueu.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"modal-fullscreen.jXJnaueu.js","sources":["../../../vue2/src/components/modal-fullscreen/components/modal-fullscreen-page.vue","../../src/composables/use-listeners/index.ts","../../../vue2/src/components/modal-fullscreen/modal-fullscreen.vue"],"sourcesContent":["<template>\n <dialog-page class=\"b-modal-fullscreen-page\" :page-id=\"pageId\" :previous-page=\"previousPage\" always-show-border>\n <template #header>\n <div class=\"b-modal-fullscreen-page__header\">\n <div class=\"b-modal-fullscreen-page__header-section b-modal-fullscreen-page__header-section--title\">\n <bento-typography\n v-if=\"title\"\n :id=\"computedTitleId\"\n el=\"h2\"\n variant=\"title\"\n class=\"b-modal-fullscreen-page__title\"\n :title=\"title\"\n >{{ title }}</bento-typography\n >\n </div>\n <div\n v-if=\"hasSlot('header')\"\n class=\"b-modal-fullscreen-page__header-section b-modal-fullscreen-page__header-section--slot\"\n >\n <slot name=\"header\" />\n </div>\n <div class=\"b-modal-fullscreen-page__header-section b-modal-fullscreen-page__header-section--actions\">\n <bento-typography\n v-if=\"contextualLabel\"\n class=\"b-modal-fullscreen-page__contextual-label\"\n el=\"span\"\n :title=\"contextualLabel\"\n >{{ contextualLabel }}</bento-typography\n >\n <bento-button-actions v-if=\"actions\" class=\"b-modal-fullscreen-page__actions\" :actions=\"actions\" />\n\n <div class=\"b-modal-fullscreen-page__separator\"></div>\n <div class=\"b-modal-fullscreen-page__close-button\">\n <bento-button variant=\"tertiary\" :aria-label=\"t('close')\" @click=\"handleClose\">\n <template #iconLeft><cross-icon :aria-hidden=\"true\" /></template>\n </bento-button>\n </div>\n </div>\n </div>\n </template>\n <template #content>\n <slot />\n </template>\n </dialog-page>\n</template>\n\n<script setup lang=\"ts\">\n import { inject, onMounted, type PropType, useSlots } from 'vue';\n\n import { BentoButton, BentoButtonActions, type BentoButtonActionsList } from '@/components/button';\n import { BentoTypography } from '@/components/typography';\n import { DialogPage } from '@/internal';\n\n import { useHasSlot } from '@/composables';\n import { useI18n } from '@/utils/ts/i18n';\n import {\n MODAL_FULLSCREEN_CLOSE_INJECTION_KEY,\n MODAL_FULLSCREEN_TITLE_ID_INJECTION_KEY,\n } from '@/components/modal-fullscreen/modal-fullscreen.keys';\n import CrossIcon from '@adyen/ui-assets-icons-16/vue/cross';\n import messages from './messages.json';\n\n type MessageSchema = (typeof messages)['en-US'];\n\n const { t } = useI18n<{ message: MessageSchema }>({ messages });\n const props = defineProps({\n /**\n * List of actions that will be used to render the buttons.\n * First element in the list will be rendered as \"primary\".\n * All elements after the first will be rendered as \"secondary\".\n *\n * Each object in the list should have a `title`, an `event` and\n * (optional) a Vue `icon` from the library `@adyen/ui-assets-icons-16`.\n *\n * @see BentoButton for a list of all the other props supported by each button action.\n */\n actions: {\n type: Array as PropType<BentoButtonActionsList>,\n default: null,\n },\n\n /**\n * Label shown next to the modal actions\n */\n contextualLabel: {\n type: String,\n default: null,\n },\n\n /**\n * Identifier of the page, used with activePage prop to handle sidepanel navigation\n */\n pageId: {\n type: String,\n default: undefined,\n },\n\n /**\n * ID of the page for the back button to navigate to. Only use it to overwrite the default back behavior\n * Used when the back button should not take the user to the natural previous page\n * Set to `null` to hide back button in the page\n */\n previousPage: {\n type: String,\n default: undefined,\n },\n\n /**\n * Title of the modal\n */\n title: {\n type: String,\n default: null,\n },\n\n /**\n * ID to be applied to the title to be used with aria-labelledby\n */\n titleId: {\n type: String,\n default: undefined,\n },\n });\n const emit = defineEmits<{\n /**\n * Emits event when close button is clicked\n */\n (e: 'close');\n }>();\n\n const slots = useSlots();\n const hasSlot = useHasSlot(slots);\n\n const injectedTitleId = inject(MODAL_FULLSCREEN_TITLE_ID_INJECTION_KEY, undefined);\n const computedTitleId = props.titleId ?? injectedTitleId;\n\n const closeModal = inject(MODAL_FULLSCREEN_CLOSE_INJECTION_KEY, undefined);\n\n const handleClose = () => {\n emit('close');\n closeModal?.();\n };\n\n onMounted(() => {\n if (props.actions && props.actions.length > 2) {\n throw new Error('Not more than 2 action buttons may be provided in Bento Modal Fullscreen');\n }\n });\n</script>\n\n<script lang=\"ts\">\n /**\n * ModalFullscreenPage is used to render different pages of ModalFullscreen component\n *\n * @example\n * import { BentoModalFullscreen, BentoModalFullscreenPage } from '@adyen/bento-vue2';\n *\n * export default {\n * components: { BentoModalFullscreen, BentoModalFullscreenPage },\n * template: `\n * <bento-modal-fullscreen active-page='page1' is-open='true'>\n * <bento-modal-fullscreen-page\n * title='Page 1'\n * pageId='page1'\n * contextual-label='Move to next page'\n * :actions=\"[\n * {\n * title: 'Next page',\n * event: () => {\n * activePage.value = 'page2';\n * },\n * }]\">\n * Page 1 info\n * </bento-modal-fullscreen-page>\n * <bento-modal-fullscreen-page\n * title='Page 2'\n * pageId='page2'\n * :actions=\"[\n * {\n * title: 'Save',\n * event: () => {},\n * }]\">\n * Page 2 info\n * </bento-modal-fullscreen-page>\n * </bento-modal-fullscreen>\n * `\n * }\n */\n export default {\n i18n: { messages },\n name: 'bento-modal-fullscreen-page',\n };\n</script>\n\n<style lang=\"scss\" scoped src=\"./modal-fullscreen-page.scss\" />\n","import { getCurrentInstance } from 'vue';\n\n/**\n * A composable that provides access to the component's listeners.\n * The listeners are prefixed with \"on\" in camelCase and the colons are removed (e.g. \"onClick\", \"onUpdateValue\").\n * @returns The component's listeners.\n */\nexport function useListeners() {\n return getCurrentInstance()?.vnode.props ?? {};\n}\n","<template>\n <dialog\n :id=\"modalFullscreenId\"\n ref=\"modal\"\n class=\"b-modal-fullscreen\"\n :class=\"conditionalClasses\"\n data-dialog-element=\"modal-fullscreen\"\n :aria-labelledby=\"titleId\"\n @animationend=\"closeModalAfterAnimation\"\n @keydown.esc.prevent=\"closeModal\"\n >\n <bento-focus-trap v-if=\"internalIsOpen\" class=\"b-modal-fullscreen__wrapper\">\n <template v-if=\"props.activePage\">\n <slot />\n </template>\n <bento-modal-fullscreen-page\n v-else\n :actions=\"actions\"\n :contextual-label=\"contextualLabel\"\n :title=\"title\"\n :title-id=\"titleId\"\n @close=\"closeModal\"\n >\n <template v-if=\"hasSlot('default')\" #default>\n <slot name=\"default\"></slot>\n </template>\n <template v-if=\"hasSlot('header')\" #header>\n <slot name=\"header\"></slot>\n </template>\n </bento-modal-fullscreen-page>\n </bento-focus-trap>\n\n <!-- Enable the toast inside the fullscreen-modal -->\n <template v-if=\"isOpen\">\n <bento-toast />\n </template>\n </dialog>\n</template>\n\n<script setup lang=\"ts\">\n import { computed, onMounted, onUnmounted, type PropType, provide, ref, toRefs, useSlots, watch } from 'vue';\n import { isVue2 } from 'vue-demi';\n\n import { BentoToast } from '@/components/toast';\n import { type BentoButtonActionsList } from '@/components/button';\n import { BentoFocusTrap } from '@/components/focus-trap';\n import BentoModalFullscreenPage from './components/modal-fullscreen-page.vue';\n\n import { generateUid } from '@/utils/ts/generate-uid';\n import { useHasSlot } from '@/composables';\n import { useListeners } from '@/composables/use-listeners';\n import {\n MODAL_FULLSCREEN_CLOSE_INJECTION_KEY,\n MODAL_FULLSCREEN_DIALOG_ID_INJECTION_KEY,\n MODAL_FULLSCREEN_TITLE_ID_INJECTION_KEY,\n } from '@/components/modal-fullscreen/modal-fullscreen.keys';\n\n import {\n BentoDialogPageAnimation,\n type BentoDialogPageConfigData,\n type BentoDialogPageRegisterPage,\n DIALOG_PAGE_CONFIG_INJECTION_KEY,\n DIALOG_PAGE_REGISTER_PAGE_INJECTION_KEY,\n } from '@/internal';\n\n const props = defineProps({\n /**\n * List of actions that will be used to render the buttons.\n * First element in the list will be rendered as \"primary\".\n * All elements after the first will be rendered as \"secondary\".\n *\n * Each object in the list should have a `title`, an `event` and\n * (optional) a Vue `icon` from the library `@adyen/ui-assets-icons-16`.\n *\n * @see BentoButton for a list of all the other props supported by each button action.\n */\n actions: {\n type: Array as PropType<BentoButtonActionsList>,\n default: null,\n },\n\n /**\n * The id of the current active page\n * Should be the same as the pageId of the BentoModalFullscreenPage to be displayed\n */\n activePage: {\n type: String,\n default: null,\n },\n\n /**\n * Label shown next to the modal actions\n */\n contextualLabel: {\n type: String,\n default: null,\n },\n /**\n * Controls the modal's state from the outside. Set it to true to open the modal\n */\n isOpen: {\n type: Boolean,\n default: null,\n },\n /**\n * Title of the modal\n */\n title: {\n type: String,\n default: null,\n },\n });\n\n const emit = defineEmits<{\n /**\n * Handles closing the modal. The behavior changes depending on whether a `before-close` event listener is present.\n *\n * - **When listening for the `before-close` event:**\n * The `before-close` event is emitted immediately, skipping the animation. This allows for logic to run before the modal closes.\n * The `isOpen` prop must then be set to `false` to trigger the closing animation.\n *\n * - **When not listening for the `before-close` event:**\n * The closing animation plays, then `update:is-open` is emitted with `false`.\n * This is the default behavior, compatible with `v-model` or `.sync` on the `isOpen` prop.\n */\n (e: 'before-close'): void;\n /**\n * Emits update event when page is changed internally\n */\n (e: 'update:active-page', page: string): void;\n /**\n * Emits 'update:is-open' event when the modal is closed\n */\n (e: 'update:is-open', isOpen: boolean): void;\n }>();\n\n // Refs\n const { activePage, isOpen } = toRefs(props);\n const modal = ref(null);\n const isClosing = ref(false);\n const modalFullscreenId = generateUid('modal-fullscreen');\n const titleId = generateUid('modal-fullscreen-title');\n const internalIsOpen = ref(false);\n const isMounted = ref(false);\n\n const listeners = useListeners();\n const slots = useSlots();\n const hasSlot = useHasSlot(slots);\n\n // Animation styling\n const conditionalClasses = computed(() => ({\n 'b-modal-fullscreen--hide': isClosing.value,\n }));\n\n // Handle closing and closing animation for dialog element\n const closeModalAfterAnimation = () => {\n if (isClosing.value && modal.value) {\n modal.value.close();\n if (previousPages.value[0]) {\n emit('update:active-page', previousPages.value[0]);\n }\n previousPages.value = [];\n isClosing.value = false;\n internalIsOpen.value = false;\n emit('update:is-open', false);\n }\n };\n\n /**\n * Emits the `beforeClose` event, if it is being listened to,\n * before closing the modal and omits the closing animation.\n * The animation will be triggered by the change of the `isOpen` prop instead.\n *\n * If no listener for the `before-close`, then the animation will be triggered,\n * which will close the modal and emit the `update:is-open` event instead, after it was closed.\n */\n function closeModal() {\n /**\n * Vue3 appends the prefix \"on\" and changes to camelCase\n */\n const eventName = isVue2 ? 'before-close' : 'onBeforeClose';\n if (listeners[eventName]) {\n emit('before-close');\n return;\n }\n startCloseModalAnimation();\n }\n\n const startCloseModalAnimation = () => {\n if (!modal.value || !modal.value.open) {\n return;\n }\n isClosing.value = true;\n };\n\n onMounted(() => {\n isMounted.value = true;\n });\n\n onUnmounted(() => {\n isMounted.value = false;\n });\n\n // Watching isOpen prop to toggle open/close the dialog element\n watch(\n [() => isOpen.value, modal],\n ([newIsOpen, newModalValue]) => {\n if (!isMounted.value || !newModalValue) {\n return;\n }\n\n if (newIsOpen) {\n internalIsOpen.value = true;\n if (!newModalValue.open) {\n newModalValue.showModal();\n }\n if (!previousPages.value.length) {\n previousPages.value.push(activePage.value);\n }\n } else if (newModalValue.open) {\n startCloseModalAnimation();\n }\n },\n { immediate: true, flush: 'post' }\n );\n\n // lets children components know they are inside a Modal (dialog element)\n provide(MODAL_FULLSCREEN_DIALOG_ID_INJECTION_KEY, modalFullscreenId);\n provide(MODAL_FULLSCREEN_TITLE_ID_INJECTION_KEY, titleId);\n provide(MODAL_FULLSCREEN_CLOSE_INJECTION_KEY, closeModal);\n\n // Pages\n const animation = ref(BentoDialogPageAnimation.TRANSITION_LEVEL_DEEPER);\n const pages = ref<Array<string>>([]);\n const previousPages = ref([]);\n const updatePage = page => emit('update:active-page', page);\n\n provide<BentoDialogPageConfigData>(DIALOG_PAGE_CONFIG_INJECTION_KEY, {\n activePage,\n animation,\n isOpen: internalIsOpen,\n pages,\n previousPages,\n updatePage,\n });\n\n // unregister page if removed / destroyed\n const unregisterPage = (pageIdToRemove: string) => () => {\n pages.value = pages.value?.filter(pageId => pageId !== pageIdToRemove);\n };\n\n // Provide data and function to register page to subcomponent\n const registerPage: BentoDialogPageRegisterPage = pageId => {\n if (pageId) {\n pages.value.push(pageId);\n }\n\n return { unregisterPage: unregisterPage(pageId) };\n };\n\n provide(DIALOG_PAGE_REGISTER_PAGE_INJECTION_KEY, registerPage);\n</script>\n\n<script lang=\"ts\">\n /**\n * Fullscreen modal takes full available space (no content underneath is visible) and focuses the user's attention exclusively on one complex task or piece of complex information.\n *\n * @example\n * import { BentoModalFullscreen } from '@adyen/bento-vue2';\n *\n * export default {\n * components: { BentoModalFullscreen },\n * template: `\n * <bento-modal-fullscreen\n * :is-open=\"isOpen\"\n * @update:is-open=\"isOpen = $event\"\n * title='Fullscreen modal title'\n * contextual-label='Contextual label'\n * :actions=\"[{ title: 'Action', event: () => {}]\"\n * >\n * <template #header>{{ header slot }}</template>\n * {{ content }}\n * </bento-modal-fullscreen>\n * `\n * }\n */\n export default {};\n</script>\n\n<style lang=\"scss\" scoped src=\"./modal-fullscreen.scss\" />\n"],"names":["__default__$1","messages","t","useI18n","props","__props","emit","__emit","slots","useSlots","hasSlot","useHasSlot","injectedTitleId","inject","MODAL_FULLSCREEN_TITLE_ID_INJECTION_KEY","computedTitleId","closeModal","MODAL_FULLSCREEN_CLOSE_INJECTION_KEY","handleClose","onMounted","useListeners","getCurrentInstance","__default__","activePage","isOpen","toRefs","modal","ref","isClosing","modalFullscreenId","generateUid","titleId","internalIsOpen","isMounted","listeners","conditionalClasses","computed","closeModalAfterAnimation","previousPages","startCloseModalAnimation","onUnmounted","watch","newIsOpen","newModalValue","provide","MODAL_FULLSCREEN_DIALOG_ID_INJECTION_KEY","animation","BentoDialogPageAnimation","pages","DIALOG_PAGE_CONFIG_INJECTION_KEY","page","unregisterPage","pageIdToRemove","pageId","DIALOG_PAGE_REGISTER_PAGE_INJECTION_KEY"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;wKA4LIA,KAAA;AAAA,EAAe,MAAA,EAAA,UAAAC,EAAA;AAAA,EACM,MAAA;AAErB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA/HA,UAAA,EAAA,GAAAC,EAAA,IAAAC,GAAA,EAAA,UAAAF,EAAA,CAAA,GACAG,IAAAC,GA0DAC,IAAAC,GAOAC,IAAAC,EAAA,GACAC,IAAAC,EAAAH,CAAA,GAEAI,IAAAC,EAAAC,GAAA,MAAA,GACAC,IAAAX,EAAA,WAAAQ,GAEAI,IAAAH,EAAAI,GAAA,MAAA,GAEAC,IAAA,MAAA;AACI,MAAAZ,EAAA,OAAA,GACAU,IAAA;AAAA,IAAa;AAGjB,WAAAG,EAAA,MAAA;AACI,UAAAf,EAAA,WAAAA,EAAA,QAAA,SAAA;AACI,cAAA,IAAA,MAAA,0EAAA;AAAA,IACJ,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AC3ID,SAAAgB,KAAA;AACH,SAAAC,EAAA,GAAA,MAAA,SAAA,CAAA;AACJ;mDCqRIC,KAAA,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA7NA,UA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A,KAAAf,EAAA,KAAA,KACJoB,EAAA,QAEAJ,EAAA;AAAA,MACJ;AAAA,MACJ,EAAA,WAAA,IAAA,OAAA,OAAA;AAAA,IACiC,GAIrCK,EAAAC,IAAAhB,CAAA,GACAe,EAAA9B,GAAAiB,CAAA,GACAa,EAAA3B,GAAAD,CAAA;AAGA,UAAA8B,IAAAnB,EAAAoB,GAAA,uBAAA,GACAC,IAAArB,EAAA,CAAA,CAAA,GACAW,IAAAX,EAAA,CAAA,CAAA;AAGA,IAAAiB,EAAAK,IAAA;AAAA,MAAqE,YAAA1B;AAAA,MACjE,WAAAuB;AAAA,MACA,QAAAd;AAAA,MACQ,OAAAgB;AAAA,MACR,eAAAV;AAAA,MACA,YAPJ,CAAAY,MAAA5C,EAAA,sBAAA4C,CAAA;AAAA,IAQI,CAAA;AAIJ,UAAAC,IAAA,CAAAC,MAAA,MAAA;AACI,MAAAJ,EAAA,QAAAA,EAAA,OAAA,OAAA,CAAAK,MAAAA,MAAAD,CAAA;AAAA,IAAqE;AAYzE,WAAAR,EAAAU,IARA,CAAAD,OACIA,KACIL,EAAA,MAAA,KAAAK,CAAA,GAGJ,EAAA,gBAAAF,EAAAE,CAAA,EAAA,EAGJ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -1,11 +1,11 @@
1
1
  import { defineComponent as p, useSlots as k, onMounted as P, openBlock as b, createBlock as B, mergeProps as w, createSlots as z, unref as a, withCtx as i, renderSlot as s, createVNode as K, toRefs as j, ref as q, computed as O, createTextVNode as V, toDisplayString as I, useAttrs as U, resolveDynamicComponent as F } from "vue";
2
- import { B as C, h as $, a as f, d as G, e as D, g as h, f as W } from "./base-modal.Bn4ZXwv6.js";
2
+ import { B as C, h as $, a as f, d as G, e as D, g as h, f as W } from "./base-modal.CulokESn.js";
3
3
  import { u as A } from "./use-has-slot.CyMiImRQ.js";
4
- import { F as Y } from "./footer-actions.Dl20Q1WX.js";
5
- import { b as E } from "./button.Ciflfide.js";
6
- import { u as H } from "./index.B875RXHM.js";
7
- import { B as L } from "./button-actions.uIjzze43.js";
8
- import { d as J } from "./typography.wIM07Hbl.js";
4
+ import { F as Y } from "./footer-actions.BJif4sIk.js";
5
+ import { b as E } from "./button.DAcwNdtP.js";
6
+ import { u as H } from "./index.CGBfMQdv.js";
7
+ import { B as L } from "./button-actions.DvuGEQxM.js";
8
+ import { d as J } from "./typography.B6elnWpr.js";
9
9
  const X = p({
10
10
  name: "bento-modal-default"
11
11
  }), Q = /* @__PURE__ */ p({
@@ -448,7 +448,7 @@ const X = p({
448
448
  'BentoModal "overflow-visible" property',
449
449
  `"overflow-visible" property was made redundant. BentoModal can work correctly without the need to pass the propery.
450
450
  Remove the "overflow-visible" prop from BentoModal to remove this error.`,
451
- "2.0.0"
451
+ "3.0.0"
452
452
  ), (r, g) => (b(), B(F(n.value), w({
453
453
  class: "b-modal",
454
454
  "is-open": e.isOpen,
@@ -492,4 +492,4 @@ const X = p({
492
492
  export {
493
493
  ce as _
494
494
  };
495
- //# sourceMappingURL=modal.vue_vue_type_script_setup_true_lang.CrsIyU7A.js.map
495
+ //# sourceMappingURL=modal.vue_vue_type_script_setup_true_lang.BwmYlzFm.js.map