@adyen/bento-vue2 1.89.2 → 1.90.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.
- package/dist/@types/components.d.ts +2 -0
- package/dist/@types/index.d.ts +198 -80
- package/dist/accordion.js +1 -1
- package/dist/action-bar.js +1 -1
- package/dist/ai-tag.js +1 -1
- package/dist/alert.js +1 -1
- package/dist/anchor-scroller.js +1 -1
- package/dist/assets/accordion-item.css +1 -1
- package/dist/assets/action-bar.css +1 -1
- package/dist/assets/base-modal.css +1 -1
- package/dist/assets/button-actions.css +1 -1
- package/dist/assets/card.css +1 -1
- package/dist/assets/data-grid.css +1 -1
- package/dist/assets/date-range-picker.css +1 -1
- package/dist/assets/dialog-page.css +1 -1
- package/dist/assets/file-uploader.css +1 -1
- package/dist/assets/input-time.css +1 -0
- package/dist/assets/inspector.css +1 -1
- package/dist/assets/modal-fullscreen.css +1 -1
- package/dist/assets/secondary-nav.css +1 -1
- package/dist/assets/sidepanel.css +1 -1
- package/dist/button.js +3 -3
- package/dist/card.js +1 -1
- package/dist/checkbox.js +2 -2
- package/dist/chip.js +1 -1
- package/dist/chunks/accordion-item.D0WVCLec.js +145 -0
- package/dist/chunks/{accordion-item.BZDSJamR.js.map → accordion-item.D0WVCLec.js.map} +1 -1
- package/dist/chunks/action-bar.B63qIiiH.js +334 -0
- package/dist/chunks/{action-bar.CYGUYI0V.js.map → action-bar.B63qIiiH.js.map} +1 -1
- package/dist/chunks/{ai-button.CR_ePQRR.js → ai-button.7L9bANlk.js} +2 -2
- package/dist/chunks/{ai-button.CR_ePQRR.js.map → ai-button.7L9bANlk.js.map} +1 -1
- package/dist/chunks/ai-tag.CCJCOdXu.js +110 -0
- package/dist/chunks/{ai-tag.Cjf38mjR.js.map → ai-tag.CCJCOdXu.js.map} +1 -1
- package/dist/chunks/alert.CXRb-Smf.js +160 -0
- package/dist/chunks/{alert.QVQ6Zjbm.js.map → alert.CXRb-Smf.js.map} +1 -1
- package/dist/chunks/{anchor-scroller.CjJ26PJS.js → anchor-scroller.DWaykZQj.js} +66 -39
- package/dist/chunks/{anchor-scroller.CjJ26PJS.js.map → anchor-scroller.DWaykZQj.js.map} +1 -1
- package/dist/chunks/{base-modal.DmWkavtf.js → base-modal.DpmeDmq-.js} +103 -66
- package/dist/chunks/{base-modal.DmWkavtf.js.map → base-modal.DpmeDmq-.js.map} +1 -1
- package/dist/chunks/{button-actions-with-menu.Bi_HXopk.js → button-actions-with-menu.ChTUOsZl.js} +2 -2
- package/dist/chunks/{button-actions-with-menu.Bi_HXopk.js.map → button-actions-with-menu.ChTUOsZl.js.map} +1 -1
- package/dist/chunks/{button-actions.BLk114As.js → button-actions.BmU1DngD.js} +221 -147
- package/dist/chunks/{button-actions.BLk114As.js.map → button-actions.BmU1DngD.js.map} +1 -1
- package/dist/chunks/{button.DxhJNOtr.js → button.C9b2AC9w.js} +2 -2
- package/dist/chunks/{button.DxhJNOtr.js.map → button.C9b2AC9w.js.map} +1 -1
- package/dist/chunks/{calendar.CXKhBF2f.js → calendar.uvIGF_jU.js} +283 -209
- package/dist/chunks/{calendar.CXKhBF2f.js.map → calendar.uvIGF_jU.js.map} +1 -1
- package/dist/chunks/card.WWUfBkqf.js +165 -0
- package/dist/chunks/{card.GjhsXOT0.js.map → card.WWUfBkqf.js.map} +1 -1
- package/dist/chunks/{checkbox-group.B2BjU3ZN.js → checkbox-group.CI0xDnql.js} +4 -4
- package/dist/chunks/{checkbox-group.B2BjU3ZN.js.map → checkbox-group.CI0xDnql.js.map} +1 -1
- package/dist/chunks/{checkbox.CIv8WgGp.js → checkbox.TsWA6O3Z.js} +93 -56
- package/dist/chunks/{checkbox.CIv8WgGp.js.map → checkbox.TsWA6O3Z.js.map} +1 -1
- package/dist/chunks/chip.BFY_-VCz.js +84 -0
- package/dist/chunks/{chip.DTpENaGC.js.map → chip.BFY_-VCz.js.map} +1 -1
- package/dist/chunks/{code-snippet.YIm2oO_o.js → code-snippet.4DX9iUV8.js} +133 -76
- package/dist/chunks/{code-snippet.YIm2oO_o.js.map → code-snippet.4DX9iUV8.js.map} +1 -1
- package/dist/chunks/{controls-group.CqotnNEF.js → controls-group.D_KE99mg.js} +2 -2
- package/dist/chunks/{controls-group.CqotnNEF.js.map → controls-group.D_KE99mg.js.map} +1 -1
- package/dist/chunks/copy.qqGYFbKJ.js +133 -0
- package/dist/chunks/{copy.BVGQcf22.js.map → copy.qqGYFbKJ.js.map} +1 -1
- package/dist/chunks/{country.D20NCLLG.js → country.BEwW8TQo.js} +3 -3
- package/dist/chunks/{country.D20NCLLG.js.map → country.BEwW8TQo.js.map} +1 -1
- package/dist/chunks/country.types.jjXwaoMl.js +2537 -0
- package/dist/chunks/country.types.jjXwaoMl.js.map +1 -0
- package/dist/chunks/{dashboard-section.BubZyu8i.js → dashboard-section.TWlLdQHG.js} +3 -3
- package/dist/chunks/{dashboard-section.BubZyu8i.js.map → dashboard-section.TWlLdQHG.js.map} +1 -1
- package/dist/chunks/{dashed-underline.pjYTS0m1.js → dashed-underline.CpDuQ3Fo.js} +3 -3
- package/dist/chunks/{dashed-underline.pjYTS0m1.js.map → dashed-underline.CpDuQ3Fo.js.map} +1 -1
- package/dist/chunks/{data-grid-template.D8RhngPj.js → data-grid-template.DZaE-kOS.js} +4 -4
- package/dist/chunks/{data-grid-template.D8RhngPj.js.map → data-grid-template.DZaE-kOS.js.map} +1 -1
- package/dist/chunks/data-grid.x6cEW0az.js +4069 -0
- package/dist/chunks/data-grid.x6cEW0az.js.map +1 -0
- package/dist/chunks/date-picker.Dln8ocL4.js +222 -0
- package/dist/chunks/{date-picker.CnazYcSX.js.map → date-picker.Dln8ocL4.js.map} +1 -1
- package/dist/chunks/date-range-picker.DPGy2h-9.js +1068 -0
- package/dist/chunks/date-range-picker.DPGy2h-9.js.map +1 -0
- package/dist/chunks/dialog-page.EdejG53a.js +143 -0
- package/dist/chunks/{dialog-page.oyG153fC.js.map → dialog-page.EdejG53a.js.map} +1 -1
- package/dist/chunks/{dropdown-default-textbox.Dvzg0StF.js → dropdown-default-textbox.CjhLIxVq.js} +63 -36
- package/dist/chunks/{dropdown-default-textbox.Dvzg0StF.js.map → dropdown-default-textbox.CjhLIxVq.js.map} +1 -1
- package/dist/chunks/{dropdown-tag.BRB-emd1.js → dropdown-tag.t3FlJUSy.js} +5 -5
- package/dist/chunks/{dropdown-tag.BRB-emd1.js.map → dropdown-tag.t3FlJUSy.js.map} +1 -1
- package/dist/chunks/{dropdown.Ct7uhPr6.js → dropdown.CvNI2V33.js} +329 -235
- package/dist/chunks/{dropdown.Ct7uhPr6.js.map → dropdown.CvNI2V33.js.map} +1 -1
- package/dist/chunks/{empty-state.D_Ac-XXH.js → empty-state.DMV23IZy.js} +2 -2
- package/dist/chunks/{empty-state.D_Ac-XXH.js.map → empty-state.DMV23IZy.js.map} +1 -1
- package/dist/chunks/error-message.BUNKRa_w.js +160 -0
- package/dist/chunks/{error-message.RxdStT3S.js.map → error-message.BUNKRa_w.js.map} +1 -1
- package/dist/chunks/{file-uploader.D5Rjsx4k.js → file-uploader.Cig5gDXT.js} +749 -468
- package/dist/chunks/{file-uploader.D5Rjsx4k.js.map → file-uploader.Cig5gDXT.js.map} +1 -1
- package/dist/chunks/{filter-bar.zD_ctViU.js → filter-bar.x445KK3y.js} +1301 -761
- package/dist/chunks/{filter-bar.zD_ctViU.js.map → filter-bar.x445KK3y.js.map} +1 -1
- package/dist/chunks/fixed-scroller.DR2E_No4.js +148 -0
- package/dist/chunks/{fixed-scroller.MerESbd_.js.map → fixed-scroller.DR2E_No4.js.map} +1 -1
- package/dist/chunks/{footer-actions.CiPj7hZG.js → footer-actions.CIkul1OD.js} +3 -3
- package/dist/chunks/{footer-actions.CiPj7hZG.js.map → footer-actions.CIkul1OD.js.map} +1 -1
- package/dist/chunks/{form-layout-title.Bw7VgOO5.js → form-layout-title.DR5M7GP3.js} +77 -48
- package/dist/chunks/{form-layout-title.Bw7VgOO5.js.map → form-layout-title.DR5M7GP3.js.map} +1 -1
- package/dist/chunks/{header-meta.Dq6TlNPw.js → header-meta.BC5fdpD1.js} +127 -73
- package/dist/chunks/{header-meta.Dq6TlNPw.js.map → header-meta.BC5fdpD1.js.map} +1 -1
- package/dist/chunks/{header-with-views.DaEhkSS8.js → header-with-views.-cvdi9-L.js} +1120 -679
- package/dist/chunks/{header-with-views.DaEhkSS8.js.map → header-with-views.-cvdi9-L.js.map} +1 -1
- package/dist/chunks/{header.DkC-KKWa.js → header.DtmZjxiU.js} +3 -3
- package/dist/chunks/{header.DkC-KKWa.js.map → header.DtmZjxiU.js.map} +1 -1
- package/dist/chunks/{info-icon.BF8KxU-k.js → info-icon.DCR42Kvm.js} +2 -2
- package/dist/chunks/{info-icon.BF8KxU-k.js.map → info-icon.DCR42Kvm.js.map} +1 -1
- package/dist/chunks/input-field-password.Bdlw4dzr.js +381 -0
- package/dist/chunks/{input-field-password.BKT1mYUw.js.map → input-field-password.Bdlw4dzr.js.map} +1 -1
- package/dist/chunks/{input-field-phone-number.BjRKjQOQ.js → input-field-phone-number.DPuWxBBz.js} +98 -71
- package/dist/chunks/{input-field-phone-number.BjRKjQOQ.js.map → input-field-phone-number.DPuWxBBz.js.map} +1 -1
- package/dist/chunks/input-field.DH25CU_G.js +207 -0
- package/dist/chunks/{input-field.m1PMwa4C.js.map → input-field.DH25CU_G.js.map} +1 -1
- package/dist/chunks/input-time.6eJ4-QdU.js +92 -0
- package/dist/chunks/input-time.6eJ4-QdU.js.map +1 -0
- package/dist/chunks/inspector.BzBPlz-5.js +172 -0
- package/dist/chunks/{inspector.Bnm0hl_D.js.map → inspector.BzBPlz-5.js.map} +1 -1
- package/dist/chunks/{link.MhoM3zQj.js → link.DB5g6d48.js} +56 -29
- package/dist/chunks/{link.MhoM3zQj.js.map → link.DB5g6d48.js.map} +1 -1
- package/dist/chunks/{list-item.BnzU1LIu.js → list-item.DqTHh8-Z.js} +2 -2
- package/dist/chunks/{list-item.BnzU1LIu.js.map → list-item.DqTHh8-Z.js.map} +1 -1
- package/dist/chunks/{listbox-option-tag.BhPVuAjJ.js → listbox-option-tag.CvbE-EuG.js} +2 -2
- package/dist/chunks/{listbox-option-tag.BhPVuAjJ.js.map → listbox-option-tag.CvbE-EuG.js.map} +1 -1
- package/dist/chunks/{modal-fullscreen.CXOq6_Cv.js → modal-fullscreen.CaxuXW-H.js} +63 -36
- package/dist/chunks/{modal-fullscreen.CXOq6_Cv.js.map → modal-fullscreen.CaxuXW-H.js.map} +1 -1
- package/dist/chunks/{modal.o0KddMiG.js → modal.Brif0vAy.js} +63 -36
- package/dist/chunks/{modal.o0KddMiG.js.map → modal.Brif0vAy.js.map} +1 -1
- package/dist/chunks/{pagination.ZISqB4M_.js → pagination.BmrU_sn_.js} +221 -99
- package/dist/chunks/{pagination.ZISqB4M_.js.map → pagination.BmrU_sn_.js.map} +1 -1
- package/dist/chunks/promo-banner.Dc_kK1x9.js +91 -0
- package/dist/chunks/{promo-banner.Db2kh2qK.js.map → promo-banner.Dc_kK1x9.js.map} +1 -1
- package/dist/chunks/{radio-group.DnMy7brs.js → radio-group.5oS-AeYN.js} +4 -4
- package/dist/chunks/{radio-group.DnMy7brs.js.map → radio-group.5oS-AeYN.js.map} +1 -1
- package/dist/chunks/{rich-text-editor.Cbv1DxXn.js → rich-text-editor.DSGTe8Zt.js} +1781 -1731
- package/dist/chunks/{rich-text-editor.Cbv1DxXn.js.map → rich-text-editor.DSGTe8Zt.js.map} +1 -1
- package/dist/chunks/search-bar.CNfoeLLt.js +126 -0
- package/dist/chunks/{search-bar.DPjYDhja.js.map → search-bar.CNfoeLLt.js.map} +1 -1
- package/dist/chunks/secondary-nav.IF5CgeIP.js +226 -0
- package/dist/chunks/secondary-nav.IF5CgeIP.js.map +1 -0
- package/dist/chunks/{segmented-control.BqIiX9hv.js → segmented-control.DDtjX-V5.js} +2 -2
- package/dist/chunks/{segmented-control.BqIiX9hv.js.map → segmented-control.DDtjX-V5.js.map} +1 -1
- package/dist/chunks/{selection-card-group.IPiouuot.js → selection-card-group.DZjFeQKR.js} +10 -10
- package/dist/chunks/{selection-card-group.IPiouuot.js.map → selection-card-group.DZjFeQKR.js.map} +1 -1
- package/dist/chunks/{sidepanel.BGMjjB3F.js → sidepanel.DZDXuyzg.js} +66 -39
- package/dist/chunks/{sidepanel.BGMjjB3F.js.map → sidepanel.DZDXuyzg.js.map} +1 -1
- package/dist/chunks/{step.QFER3tSj.js → step.TDm_ts1S.js} +92 -63
- package/dist/chunks/{step.QFER3tSj.js.map → step.TDm_ts1S.js.map} +1 -1
- package/dist/chunks/{structured-list-item.BDJKRC_8.js → structured-list-item.BBBtie1s.js} +58 -31
- package/dist/chunks/{structured-list-item.BDJKRC_8.js.map → structured-list-item.BBBtie1s.js.map} +1 -1
- package/dist/chunks/{summary-grid.types.CIkArZf5.js → summary-grid.types.CrPNQbX0.js} +5 -5
- package/dist/chunks/{summary-grid.types.CIkArZf5.js.map → summary-grid.types.CrPNQbX0.js.map} +1 -1
- package/dist/chunks/{tab.CaXF0dho.js → tab.CNIZyfZt.js} +2 -2
- package/dist/chunks/{tab.CaXF0dho.js.map → tab.CNIZyfZt.js.map} +1 -1
- package/dist/chunks/{tag.CocLKztJ.js → tag.D2xagTJv.js} +2 -2
- package/dist/chunks/{tag.CocLKztJ.js.map → tag.D2xagTJv.js.map} +1 -1
- package/dist/chunks/textarea.Bi53QF5Q.js +218 -0
- package/dist/chunks/{textarea.D4X6Ss9q.js.map → textarea.Bi53QF5Q.js.map} +1 -1
- package/dist/chunks/timeline-item.C6Bi0eam.js +322 -0
- package/dist/chunks/{timeline-item.C8BxWdy1.js.map → timeline-item.C6Bi0eam.js.map} +1 -1
- package/dist/chunks/{toast.BRI3G7TL.js → toast.d8vg71CB.js} +81 -54
- package/dist/chunks/{toast.BRI3G7TL.js.map → toast.d8vg71CB.js.map} +1 -1
- package/dist/chunks/{tooltip.CbsNGnhw.js → tooltip.BxtnF3is.js} +38 -36
- package/dist/chunks/tooltip.BxtnF3is.js.map +1 -0
- package/dist/chunks/{tutorial.BzV6bHQJ.js → tutorial.BCiZMLJE.js} +190 -103
- package/dist/chunks/{tutorial.BzV6bHQJ.js.map → tutorial.BCiZMLJE.js.map} +1 -1
- package/dist/chunks/{use-cached-selected-values.DqX2qsMC.js → use-cached-selected-values.Bn3Y8Iuq.js} +490 -359
- package/dist/chunks/{use-cached-selected-values.DqX2qsMC.js.map → use-cached-selected-values.Bn3Y8Iuq.js.map} +1 -1
- package/dist/chunks/{use-country-items.CI8C7MLU.js → use-country-items.B4j8pAvW.js} +3 -3
- package/dist/chunks/{use-country-items.CI8C7MLU.js.map → use-country-items.B4j8pAvW.js.map} +1 -1
- package/dist/chunks/use-country-phon-code.ByqnuIni.js +6386 -0
- package/dist/chunks/use-country-phon-code.ByqnuIni.js.map +1 -0
- package/dist/chunks/{use-date-input-formatter.BYaTO3vz.js → use-date-input-formatter.DRMt9yR2.js} +2 -2
- package/dist/chunks/{use-date-input-formatter.BYaTO3vz.js.map → use-date-input-formatter.DRMt9yR2.js.map} +1 -1
- package/dist/code-snippet.js +1 -1
- package/dist/country.js +3 -3
- package/dist/dashboard-template.js +1 -1
- package/dist/dashed-underline.js +1 -1
- package/dist/data-grid-template.js +1 -1
- package/dist/data-grid.js +1 -1
- package/dist/date-picker.js +2 -2
- package/dist/date-range-picker.js +2 -2
- package/dist/draggable-handle.js +160 -73
- package/dist/draggable-handle.js.map +1 -1
- package/dist/dropdown.js +4 -4
- package/dist/empty-state.js +1 -1
- package/dist/file-uploader.js +1 -1
- package/dist/filter-bar.js +1 -1
- package/dist/form-layout.js +1 -1
- package/dist/header-with-views.js +1 -1
- package/dist/header.js +1 -1
- package/dist/index.js +215 -213
- package/dist/index.js.map +1 -1
- package/dist/info-icon.js +1 -1
- package/dist/input-field-password.js +1 -1
- package/dist/input-field-phone-number.js +1 -1
- package/dist/input-field.js +1 -1
- package/dist/input-time.js +5 -0
- package/dist/input-time.js.map +1 -0
- package/dist/inspector.js +1 -1
- package/dist/internal.js +12 -12
- package/dist/link.js +1 -1
- package/dist/list.js +1 -1
- package/dist/menu.js +1 -1
- package/dist/modal-fullscreen.js +1 -1
- package/dist/modal.js +2 -2
- package/dist/pagination.js +1 -1
- package/dist/popover.js +1 -1
- package/dist/promo-banner.js +1 -1
- package/dist/radio-group.js +1 -1
- package/dist/rich-text-editor.js +1 -1
- package/dist/search-bar.js +2 -2
- package/dist/secondary-nav.js +1 -1
- package/dist/segmented-control.js +1 -1
- package/dist/selection-card.js +1 -1
- package/dist/sidepanel.js +1 -1
- package/dist/stepper.js +1 -1
- package/dist/structured-list.js +1 -1
- package/dist/summary-grid.js +1 -1
- package/dist/tabs.js +1 -1
- package/dist/tag.js +1 -1
- package/dist/textarea.js +1 -1
- package/dist/timeline.js +1 -1
- package/dist/toast.js +1 -1
- package/dist/tutorial.js +1 -1
- package/dist/web-types.json +198 -1
- package/package.json +9 -9
- package/dist/chunks/accordion-item.BZDSJamR.js +0 -108
- package/dist/chunks/action-bar.CYGUYI0V.js +0 -207
- package/dist/chunks/ai-tag.Cjf38mjR.js +0 -73
- package/dist/chunks/alert.QVQ6Zjbm.js +0 -93
- package/dist/chunks/card.GjhsXOT0.js +0 -128
- package/dist/chunks/chip.DTpENaGC.js +0 -57
- package/dist/chunks/copy.BVGQcf22.js +0 -86
- package/dist/chunks/country.types.DxKjyd0S.js +0 -20
- package/dist/chunks/country.types.DxKjyd0S.js.map +0 -1
- package/dist/chunks/data-grid.DJG8Ty0A.js +0 -3194
- package/dist/chunks/data-grid.DJG8Ty0A.js.map +0 -1
- package/dist/chunks/date-picker.CnazYcSX.js +0 -155
- package/dist/chunks/date-range-picker.Bf9pRNL7.js +0 -811
- package/dist/chunks/date-range-picker.Bf9pRNL7.js.map +0 -1
- package/dist/chunks/dialog-page.oyG153fC.js +0 -116
- package/dist/chunks/error-message.RxdStT3S.js +0 -106
- package/dist/chunks/fixed-scroller.MerESbd_.js +0 -111
- package/dist/chunks/input-field-password.BKT1mYUw.js +0 -234
- package/dist/chunks/input-field.m1PMwa4C.js +0 -170
- package/dist/chunks/inspector.Bnm0hl_D.js +0 -105
- package/dist/chunks/promo-banner.Db2kh2qK.js +0 -64
- package/dist/chunks/search-bar.DPjYDhja.js +0 -89
- package/dist/chunks/secondary-nav.CwJjkJkj.js +0 -112
- package/dist/chunks/secondary-nav.CwJjkJkj.js.map +0 -1
- package/dist/chunks/textarea.D4X6Ss9q.js +0 -169
- package/dist/chunks/timeline-item.C8BxWdy1.js +0 -238
- package/dist/chunks/tooltip.CbsNGnhw.js.map +0 -1
- package/dist/chunks/use-country-phon-code.C6orQNnM.js +0 -291
- package/dist/chunks/use-country-phon-code.C6orQNnM.js.map +0 -1
|
@@ -1,108 +1,108 @@
|
|
|
1
|
-
import { computed as
|
|
2
|
-
import { B as
|
|
1
|
+
import { computed as n, ref as x, onMounted as Ne, onUnmounted as we, watch as X, defineComponent as G, nextTick as _e, toRef as H, useSlots as Ge, useAttrs as Pe } from "vue";
|
|
2
|
+
import { B as M, a as se } from "./keyboard-navigation.DWmhelVv.js";
|
|
3
3
|
import { B as j } from "./typography.C8lPlsbD.js";
|
|
4
4
|
import { B as Fe } from "./loading-indicator.PxbRzshH.js";
|
|
5
|
-
import { B as Ye } from "./empty-state.
|
|
5
|
+
import { B as Ye } from "./empty-state.DMV23IZy.js";
|
|
6
6
|
import { u as le } from "./index.B6WW_F-J.js";
|
|
7
|
-
import { d as
|
|
8
|
-
import { o as
|
|
7
|
+
import { d as ze } from "./debounce.DUTu11PS.js";
|
|
8
|
+
import { o as Ue } from "./resize.Bqks3WUm.js";
|
|
9
9
|
import "./index.Cl4_42j5.js";
|
|
10
|
-
import { C as
|
|
10
|
+
import { C as J, N as Ve } from "./minus-small.DJacLGTw.js";
|
|
11
11
|
import { C as We } from "./checkmark-small.DVDtD4HQ.js";
|
|
12
12
|
/* empty css */
|
|
13
|
-
import { n as
|
|
14
|
-
import { B as Ke } from "./chip.
|
|
13
|
+
import { n as N } from "./_plugin-vue2_normalizer.CeySl7Fu.js";
|
|
14
|
+
import { B as Ke } from "./chip.BFY_-VCz.js";
|
|
15
15
|
import { C as je } from "./chevron-down.eYtgv5ly.js";
|
|
16
16
|
import { C as qe } from "./chevron-up.d8cwIlA_.js";
|
|
17
17
|
import { g as be } from "./generate-uid.NJ8tVoha.js";
|
|
18
|
-
import { a as He, b as fe } from "./button-actions.
|
|
18
|
+
import { a as He, b as fe } from "./button-actions.BmU1DngD.js";
|
|
19
19
|
import "../assets/use-cached-selected-values.css";
|
|
20
20
|
const pe = (s, e, l, t) => {
|
|
21
|
-
const
|
|
21
|
+
const o = n(
|
|
22
22
|
() => {
|
|
23
|
-
var f,
|
|
24
|
-
return !!((f = s.value) != null && f.length) && ((
|
|
23
|
+
var f, A;
|
|
24
|
+
return !!((f = s.value) != null && f.length) && ((A = s.value) == null ? void 0 : A.length) === e.value.length;
|
|
25
25
|
}
|
|
26
|
-
),
|
|
26
|
+
), a = n(() => {
|
|
27
27
|
var f;
|
|
28
28
|
return s.value == null || s.value.length === 0 ? !1 : ((f = s.value) == null ? void 0 : f.length) !== e.value.length;
|
|
29
29
|
});
|
|
30
30
|
return {
|
|
31
|
-
isAllSelected:
|
|
32
|
-
isIndeterminate:
|
|
31
|
+
isAllSelected: o,
|
|
32
|
+
isIndeterminate: a,
|
|
33
33
|
toggleSelectAll: (f) => {
|
|
34
34
|
f ? l() : t();
|
|
35
35
|
}
|
|
36
36
|
};
|
|
37
37
|
};
|
|
38
|
-
function
|
|
39
|
-
const
|
|
38
|
+
function Xe(s, { disabled: e, itemHeight: l, overscan: t = 5, prefixHeight: o }) {
|
|
39
|
+
const a = x(null), r = x([]), f = x(0), A = x(0), d = x(0);
|
|
40
40
|
let b;
|
|
41
|
-
const T =
|
|
42
|
-
const I = typeof l == "number" ? s.value.length * l : s.value.reduce((
|
|
41
|
+
const T = n(() => {
|
|
42
|
+
const I = typeof l == "number" ? s.value.length * l : s.value.reduce((S, v, y) => S + l(y), 0), O = typeof l == "number" ? f.value * l : s.value.slice(0, f.value).reduce((S, v, y) => S + l(y), 0);
|
|
43
43
|
return {
|
|
44
44
|
style: {
|
|
45
45
|
marginTop: `${O}px`,
|
|
46
46
|
height: `${I - O}px`
|
|
47
47
|
}
|
|
48
48
|
};
|
|
49
|
-
}),
|
|
50
|
-
const I = (
|
|
49
|
+
}), _ = () => {
|
|
50
|
+
const I = (o == null ? void 0 : o.value) ?? 0, O = Math.max(a.value.scrollTop - I, 0);
|
|
51
51
|
if (typeof l == "number")
|
|
52
52
|
return Math.floor(O / l);
|
|
53
|
-
let
|
|
53
|
+
let S = 0, v = 0;
|
|
54
54
|
for (let y = 0; y < s.value.length; y += 1) {
|
|
55
55
|
const D = l(y);
|
|
56
|
-
if (
|
|
57
|
-
|
|
56
|
+
if (S += D, S >= O) {
|
|
57
|
+
v = y;
|
|
58
58
|
break;
|
|
59
59
|
}
|
|
60
60
|
}
|
|
61
|
-
return
|
|
61
|
+
return v;
|
|
62
62
|
}, p = () => {
|
|
63
|
-
if (d.value =
|
|
63
|
+
if (d.value = a.value.clientHeight, typeof l == "number")
|
|
64
64
|
return Math.ceil(d.value / l);
|
|
65
65
|
const I = f.value ?? 0;
|
|
66
|
-
let O = 0,
|
|
67
|
-
for (let
|
|
68
|
-
const y = l(
|
|
69
|
-
if (O += y,
|
|
66
|
+
let O = 0, S = 0;
|
|
67
|
+
for (let v = I; v < s.value.length; v += 1) {
|
|
68
|
+
const y = l(v);
|
|
69
|
+
if (O += y, S = v, O > d.value)
|
|
70
70
|
break;
|
|
71
71
|
}
|
|
72
|
-
return
|
|
73
|
-
},
|
|
74
|
-
if (
|
|
72
|
+
return S - I;
|
|
73
|
+
}, C = () => {
|
|
74
|
+
if (a.value) {
|
|
75
75
|
const I = p();
|
|
76
|
-
f.value =
|
|
76
|
+
f.value = _(), A.value = Math.min(f.value + I + t, s.value.length), r.value = s.value.slice(f.value, A.value);
|
|
77
77
|
}
|
|
78
78
|
}, R = () => {
|
|
79
|
-
|
|
79
|
+
C();
|
|
80
80
|
};
|
|
81
|
-
e || (
|
|
82
|
-
|
|
83
|
-
d.value = I,
|
|
84
|
-
}),
|
|
81
|
+
e || (Ne(() => {
|
|
82
|
+
a.value && (d.value = a.value.clientHeight, b = Ue(a.value, ({ clientHeight: I }) => {
|
|
83
|
+
d.value = I, C();
|
|
84
|
+
}), C());
|
|
85
85
|
}), we(() => {
|
|
86
86
|
b == null || b.disconnect();
|
|
87
|
-
}),
|
|
87
|
+
}), X(
|
|
88
88
|
() => s.value,
|
|
89
89
|
() => {
|
|
90
|
-
|
|
90
|
+
C();
|
|
91
91
|
}
|
|
92
92
|
));
|
|
93
93
|
const B = {
|
|
94
|
-
ref:
|
|
94
|
+
ref: a,
|
|
95
95
|
style: { overflowY: "auto" }
|
|
96
96
|
};
|
|
97
97
|
return e ? {
|
|
98
|
-
containerRef:
|
|
98
|
+
containerRef: a,
|
|
99
99
|
containerProps: B,
|
|
100
100
|
// eslint-disable-next-line @typescript-eslint/no-empty-function
|
|
101
101
|
onScroll: () => {
|
|
102
102
|
},
|
|
103
103
|
list: s
|
|
104
104
|
} : {
|
|
105
|
-
containerRef:
|
|
105
|
+
containerRef: a,
|
|
106
106
|
containerProps: B,
|
|
107
107
|
onScroll: R,
|
|
108
108
|
list: r,
|
|
@@ -110,7 +110,7 @@ function Je(s, { disabled: e, itemHeight: l, overscan: t = 5, prefixHeight: a })
|
|
|
110
110
|
};
|
|
111
111
|
}
|
|
112
112
|
var c = /* @__PURE__ */ ((s) => (s.SELECT = "select", s.SHOW_MORE = "show-more", s.ESCAPE = "escape-pressed", s.CLICK = "click", s.ENTER = "enter-pressed", s.SPACE = "space-pressed", s.TAB = "tab-pressed", s.CLOSE_DROPDOWN = "close-dropdown", s))(c || {}), K = /* @__PURE__ */ ((s) => (s.AUTOMATIC = "automatic", s.BUTTON = "button", s.NONE = "none", s))(K || {});
|
|
113
|
-
const
|
|
113
|
+
const Je = G({
|
|
114
114
|
name: "bento-listbox-static-category",
|
|
115
115
|
components: {
|
|
116
116
|
BentoTypography: j
|
|
@@ -128,8 +128,8 @@ const Xe = G({
|
|
|
128
128
|
var Ze = function() {
|
|
129
129
|
var e = this, l = e._self._c;
|
|
130
130
|
return e._self._setupProxy, l("div", { staticClass: "b-listbox-single-select-category", attrs: { role: "group", "aria-label": e.categoryLabel } }, [l("bento-typography", { staticClass: "b-listbox-single-select-category__label-text", attrs: { variant: "caption", el: "span", "aria-hidden": "true" } }, [e._v(" " + e._s(e.categoryLabel) + " ")]), l("div", [e._t("default")], 2)], 1);
|
|
131
|
-
}, Qe = [], et = /* @__PURE__ */
|
|
132
|
-
|
|
131
|
+
}, Qe = [], et = /* @__PURE__ */ N(
|
|
132
|
+
Je,
|
|
133
133
|
Ze,
|
|
134
134
|
Qe,
|
|
135
135
|
!1,
|
|
@@ -150,22 +150,22 @@ const tt = et.exports, st = G({
|
|
|
150
150
|
},
|
|
151
151
|
emits: [c.CLICK, c.ENTER, c.SPACE, c.TAB],
|
|
152
152
|
setup(s, { emit: e }) {
|
|
153
|
-
const l =
|
|
153
|
+
const l = n(() => ({
|
|
154
154
|
"b-listbox-option--disabled": s.disabled,
|
|
155
155
|
"b-listbox-option--selected": s.selected
|
|
156
156
|
}));
|
|
157
157
|
return {
|
|
158
158
|
// Enums
|
|
159
|
-
BentoKeyboardNavigationKeyDownEvent:
|
|
159
|
+
BentoKeyboardNavigationKeyDownEvent: M,
|
|
160
160
|
BentoListboxEvent: c,
|
|
161
161
|
// Values
|
|
162
162
|
conditionalClasses: l,
|
|
163
163
|
// Events
|
|
164
|
-
onClick: (
|
|
165
|
-
e(c.CLICK,
|
|
164
|
+
onClick: (a) => {
|
|
165
|
+
e(c.CLICK, a);
|
|
166
166
|
},
|
|
167
|
-
onOptionSelected: (
|
|
168
|
-
e(
|
|
167
|
+
onOptionSelected: (a, r) => {
|
|
168
|
+
e(a, r);
|
|
169
169
|
}
|
|
170
170
|
};
|
|
171
171
|
}
|
|
@@ -179,26 +179,26 @@ var lt = function() {
|
|
|
179
179
|
}, function(t) {
|
|
180
180
|
return !t.type.indexOf("key") && e._k(t.keyCode, "tab", 9, t.key, "Tab") ? null : e.onOptionSelected(e.BentoListboxEvent.TAB, t);
|
|
181
181
|
}] } }, "div", e.$attrs, !1), [e._t("default")], 2);
|
|
182
|
-
},
|
|
182
|
+
}, ot = [], at = /* @__PURE__ */ N(
|
|
183
183
|
st,
|
|
184
184
|
lt,
|
|
185
|
-
|
|
185
|
+
ot,
|
|
186
186
|
!1,
|
|
187
187
|
null,
|
|
188
188
|
"c345b6c0"
|
|
189
189
|
);
|
|
190
|
-
const Z =
|
|
191
|
-
let
|
|
192
|
-
const
|
|
190
|
+
const Z = at.exports;
|
|
191
|
+
let me = 0;
|
|
192
|
+
const nt = {
|
|
193
193
|
beforeCreate() {
|
|
194
|
-
this.uuid =
|
|
194
|
+
this.uuid = me.toString(), me += 1;
|
|
195
195
|
}
|
|
196
196
|
};
|
|
197
197
|
var it = function() {
|
|
198
198
|
var e = this, l = e._self._c;
|
|
199
199
|
return l("svg", e._b({ staticClass: "ui-assets-icons-16", attrs: { role: "img", xmlns: "http://www.w3.org/2000/svg", width: "16", height: "16", fill: "none" } }, "svg", e.$attrs, !1), [e.$attrs["svg-title"] ? l("title", [e._v(e._s(e.$attrs["svg-title"]))]) : e._e(), l("path", { attrs: { fill: "#001222", d: "M15.0608 4.00011L14.0001 2.93945L6.00011 10.9395L2.00011 6.93945L0.939453 8.00011L6.00011 13.0608L15.0608 4.00011Z" } })]);
|
|
200
|
-
}, ct = [], rt = /* @__PURE__ */
|
|
201
|
-
|
|
200
|
+
}, ct = [], rt = /* @__PURE__ */ N(
|
|
201
|
+
nt,
|
|
202
202
|
it,
|
|
203
203
|
ct,
|
|
204
204
|
!1,
|
|
@@ -234,12 +234,12 @@ const ut = rt.exports, dt = G({
|
|
|
234
234
|
setup(s, { emit: e }) {
|
|
235
235
|
const l = (r) => {
|
|
236
236
|
s.disabled || e(r, s.option);
|
|
237
|
-
}, t =
|
|
237
|
+
}, t = n(() => s.disabled ? !0 : null), o = n(() => s.selected ? !0 : null), a = n(() => s.disabled ? -1 : 0);
|
|
238
238
|
return {
|
|
239
239
|
// Values
|
|
240
240
|
ariaDisabled: t,
|
|
241
|
-
ariaSelected:
|
|
242
|
-
tabIndex:
|
|
241
|
+
ariaSelected: o,
|
|
242
|
+
tabIndex: a,
|
|
243
243
|
// Enums
|
|
244
244
|
BentoListboxEvent: c,
|
|
245
245
|
// Events
|
|
@@ -260,7 +260,7 @@ var bt = function() {
|
|
|
260
260
|
} } }, [e._t("default", function() {
|
|
261
261
|
return [l("span", { staticClass: "b-listbox-single-select-option__text" }, [l("bento-typography", { attrs: { el: "span" } }, [e._v(e._s(e.option.label))]), e.option.description ? l("bento-typography", { staticClass: "b-listbox-single-select-option__description", attrs: { el: "span" } }, [e._v(" " + e._s(e.option.description) + " ")]) : e._e()], 1)];
|
|
262
262
|
}, null, e.option), l("span", { staticClass: "b-listbox-single-select-option__check-icon" }, [l("checkmark-icon", { directives: [{ name: "show", rawName: "v-show", value: e.selected, expression: "selected" }], attrs: { "svg-title": "selected" } })], 1)], 2);
|
|
263
|
-
}, ft = [],
|
|
263
|
+
}, ft = [], mt = /* @__PURE__ */ N(
|
|
264
264
|
dt,
|
|
265
265
|
bt,
|
|
266
266
|
ft,
|
|
@@ -268,9 +268,9 @@ var bt = function() {
|
|
|
268
268
|
null,
|
|
269
269
|
"bb14d75a"
|
|
270
270
|
);
|
|
271
|
-
const
|
|
272
|
-
const l =
|
|
273
|
-
switch (
|
|
271
|
+
const vt = mt.exports, ye = ({ items: s }, e) => {
|
|
272
|
+
const l = n(() => s.value.length - 1), t = x(0), o = (_) => {
|
|
273
|
+
switch (_) {
|
|
274
274
|
case "increase":
|
|
275
275
|
t.value += 1;
|
|
276
276
|
break;
|
|
@@ -278,36 +278,36 @@ const mt = vt.exports, ye = ({ items: s }, e) => {
|
|
|
278
278
|
t.value -= 1;
|
|
279
279
|
break;
|
|
280
280
|
}
|
|
281
|
-
},
|
|
282
|
-
t.value !==
|
|
283
|
-
}, r = (
|
|
284
|
-
T(
|
|
281
|
+
}, a = ({ edgeCaseItem: _ }, p) => {
|
|
282
|
+
t.value !== _ && (o(p), e(t.value));
|
|
283
|
+
}, r = (_) => {
|
|
284
|
+
T(_), a(
|
|
285
285
|
{
|
|
286
286
|
edgeCaseItem: l.value
|
|
287
287
|
},
|
|
288
288
|
"increase"
|
|
289
289
|
/* INCREASE */
|
|
290
290
|
);
|
|
291
|
-
}, f = (
|
|
292
|
-
T(
|
|
291
|
+
}, f = (_) => {
|
|
292
|
+
T(_), a(
|
|
293
293
|
{
|
|
294
294
|
edgeCaseItem: 0
|
|
295
295
|
},
|
|
296
296
|
"decrease"
|
|
297
297
|
/* DECREASE */
|
|
298
298
|
);
|
|
299
|
-
},
|
|
299
|
+
}, A = () => {
|
|
300
300
|
t.value = 0, e(t.value);
|
|
301
301
|
}, d = () => {
|
|
302
302
|
t.value = l.value, e(t.value);
|
|
303
|
-
}, b = (
|
|
304
|
-
t.value =
|
|
305
|
-
}, T = (
|
|
303
|
+
}, b = (_) => {
|
|
304
|
+
t.value = _;
|
|
305
|
+
}, T = (_) => {
|
|
306
306
|
var p;
|
|
307
|
-
(p =
|
|
307
|
+
(p = _ == null ? void 0 : _.detail) == null || p.preventDefault();
|
|
308
308
|
};
|
|
309
309
|
return {
|
|
310
|
-
moveToFirstElement:
|
|
310
|
+
moveToFirstElement: A,
|
|
311
311
|
moveToLastElement: d,
|
|
312
312
|
moveToNextElement: r,
|
|
313
313
|
moveToPreviousElement: f,
|
|
@@ -315,30 +315,30 @@ const mt = vt.exports, ye = ({ items: s }, e) => {
|
|
|
315
315
|
preventDefault: T,
|
|
316
316
|
focusedIndex: t
|
|
317
317
|
};
|
|
318
|
-
}, he = (s, e, l =
|
|
319
|
-
const
|
|
318
|
+
}, he = (s, e, l = x("option"), t = !0) => {
|
|
319
|
+
const o = x([]), a = async () => {
|
|
320
320
|
if (!s.value || s.value.nodeType === Node.COMMENT_NODE)
|
|
321
321
|
return;
|
|
322
322
|
const r = Array.from(s.value.querySelectorAll(`[role="${l.value}"]`));
|
|
323
|
-
|
|
323
|
+
o.value = t ? r.filter((f) => f.checkVisibility()) : r;
|
|
324
324
|
};
|
|
325
|
-
return
|
|
325
|
+
return X(
|
|
326
326
|
e,
|
|
327
327
|
() => {
|
|
328
|
-
|
|
329
|
-
|
|
328
|
+
_e(() => {
|
|
329
|
+
a();
|
|
330
330
|
});
|
|
331
331
|
},
|
|
332
332
|
{ immediate: !0 }
|
|
333
333
|
), {
|
|
334
|
-
visibleDomOptions:
|
|
335
|
-
updateVisibleDomOptions:
|
|
334
|
+
visibleDomOptions: o,
|
|
335
|
+
updateVisibleDomOptions: a
|
|
336
336
|
};
|
|
337
|
-
},
|
|
337
|
+
}, gt = G({
|
|
338
338
|
name: "bento-listbox-single-select",
|
|
339
339
|
components: {
|
|
340
340
|
BentoListboxSingleSelectCategory: tt,
|
|
341
|
-
BentoListboxSingleSelectOption:
|
|
341
|
+
BentoListboxSingleSelectOption: vt
|
|
342
342
|
},
|
|
343
343
|
directives: { BentoKeyboardNavigationDirective: se },
|
|
344
344
|
inheritAttrs: !1,
|
|
@@ -382,28 +382,28 @@ const mt = vt.exports, ye = ({ items: s }, e) => {
|
|
|
382
382
|
staticCategories: { type: Boolean, default: !1 }
|
|
383
383
|
},
|
|
384
384
|
emits: [c.SELECT, c.ENTER, c.SPACE, c.TAB],
|
|
385
|
-
setup(s, { emit: e, expose: l, slots: t, attrs:
|
|
386
|
-
const
|
|
387
|
-
var
|
|
388
|
-
return !!((
|
|
389
|
-
}),
|
|
385
|
+
setup(s, { emit: e, expose: l, slots: t, attrs: o }) {
|
|
386
|
+
const a = x(null), r = x([]), f = n(() => {
|
|
387
|
+
var v;
|
|
388
|
+
return !!((v = s.selectedValue) != null && v.length) && s.selectedValue.at(0);
|
|
389
|
+
}), A = n(
|
|
390
390
|
() => {
|
|
391
|
-
var
|
|
391
|
+
var v, y, D, P;
|
|
392
392
|
return {
|
|
393
|
-
"aria-label": (
|
|
394
|
-
"aria-busy": (y =
|
|
395
|
-
"aria-atomic": (D =
|
|
396
|
-
"aria-live": (P =
|
|
393
|
+
"aria-label": (v = o["aria-label"]) == null ? void 0 : v.toString(),
|
|
394
|
+
"aria-busy": (y = o["aria-busy"]) == null ? void 0 : y.toString(),
|
|
395
|
+
"aria-atomic": (D = o["aria-atomic"]) == null ? void 0 : D.toString(),
|
|
396
|
+
"aria-live": (P = o["aria-live"]) == null ? void 0 : P.toString()
|
|
397
397
|
};
|
|
398
398
|
}
|
|
399
|
-
), d =
|
|
400
|
-
e(
|
|
401
|
-
}, { visibleDomOptions: T } = he(
|
|
399
|
+
), d = n(() => !!s.items.some(({ items: v }) => !!v)), b = (v) => (y) => {
|
|
400
|
+
e(v, [y]);
|
|
401
|
+
}, { visibleDomOptions: T } = he(a, H(s, "items"), x("option"), !1), _ = (v) => {
|
|
402
402
|
var y;
|
|
403
|
-
(y = T.value[
|
|
403
|
+
(y = T.value[v]) == null || y.focus();
|
|
404
404
|
}, {
|
|
405
405
|
moveToNextElement: p,
|
|
406
|
-
moveToPreviousElement:
|
|
406
|
+
moveToPreviousElement: C,
|
|
407
407
|
moveToFirstElement: R,
|
|
408
408
|
moveToLastElement: B,
|
|
409
409
|
setListboxFocusedIndex: I
|
|
@@ -411,13 +411,13 @@ const mt = vt.exports, ye = ({ items: s }, e) => {
|
|
|
411
411
|
{
|
|
412
412
|
items: T
|
|
413
413
|
},
|
|
414
|
-
|
|
414
|
+
_
|
|
415
415
|
), O = {
|
|
416
|
-
[
|
|
417
|
-
[
|
|
418
|
-
[
|
|
419
|
-
[
|
|
420
|
-
},
|
|
416
|
+
[M.ARROW_UP]: C,
|
|
417
|
+
[M.ARROW_DOWN]: p,
|
|
418
|
+
[M.HOME]: R,
|
|
419
|
+
[M.END]: B
|
|
420
|
+
}, S = {
|
|
421
421
|
[c.SELECT]: b(c.SELECT),
|
|
422
422
|
[c.SPACE]: b(c.SPACE),
|
|
423
423
|
[c.TAB]: b(c.TAB),
|
|
@@ -438,60 +438,60 @@ const mt = vt.exports, ye = ({ items: s }, e) => {
|
|
|
438
438
|
// Enums
|
|
439
439
|
BentoListboxEvent: c,
|
|
440
440
|
// Values
|
|
441
|
-
listboxRef:
|
|
441
|
+
listboxRef: a,
|
|
442
442
|
listboxItemRef: r,
|
|
443
443
|
selectedItem: f,
|
|
444
444
|
slots: t,
|
|
445
|
-
ariaAttributes:
|
|
445
|
+
ariaAttributes: A,
|
|
446
446
|
// Computed
|
|
447
447
|
hasCategories: d,
|
|
448
448
|
// Methods
|
|
449
449
|
onOptionSelected: b,
|
|
450
450
|
// Keyboard navigation
|
|
451
451
|
listboxListeners: O,
|
|
452
|
-
listboxOptionListeners:
|
|
452
|
+
listboxOptionListeners: S
|
|
453
453
|
};
|
|
454
454
|
}
|
|
455
455
|
});
|
|
456
|
-
var
|
|
456
|
+
var _t = function() {
|
|
457
457
|
var e = this, l = e._self._c;
|
|
458
458
|
return e._self._setupProxy, l("div", e._g(e._b({ directives: [{ name: "bento-keyboard-navigation-directive", rawName: "v-bento-keyboard-navigation-directive" }], ref: "listboxRef", attrs: { role: "listbox" } }, "div", e.ariaAttributes, !1), e.listboxListeners), [e.hasCategories && e.staticCategories ? e._l(e.items, function(t) {
|
|
459
|
-
return l("bento-listbox-single-select-category", { key: t.value, attrs: { "category-label": t.label } }, e._l(t.items, function(
|
|
460
|
-
return l("bento-listbox-single-select-option", e._g({ key:
|
|
459
|
+
return l("bento-listbox-single-select-category", { key: t.value, attrs: { "category-label": t.label } }, e._l(t.items, function(o) {
|
|
460
|
+
return l("bento-listbox-single-select-option", e._g({ key: o.value, ref: "listboxItemRef", refInFor: !0, attrs: { role: "option", option: o, disabled: e.isOptionDisabled ? e.isOptionDisabled(o) : null, selected: o.value === e.selectedItem.value }, scopedSlots: e._u([e._l(e.slots, function(a, r) {
|
|
461
461
|
return { key: r, fn: function(f) {
|
|
462
462
|
return [e._t(r, null, null, f)];
|
|
463
463
|
} };
|
|
464
464
|
})], null, !0) }, e.listboxOptionListeners));
|
|
465
465
|
}), 1);
|
|
466
466
|
}) : e._l(e.items, function(t) {
|
|
467
|
-
return l("bento-listbox-single-select-option", e._g({ key: t.value, ref: "listboxItemRef", refInFor: !0, attrs: { role: "option", option: t, disabled: e.isOptionDisabled ? e.isOptionDisabled(t) : null, selected: t.value === e.selectedItem.value }, scopedSlots: e._u([e._l(e.slots, function(
|
|
468
|
-
return { key:
|
|
469
|
-
return [e._t(
|
|
467
|
+
return l("bento-listbox-single-select-option", e._g({ key: t.value, ref: "listboxItemRef", refInFor: !0, attrs: { role: "option", option: t, disabled: e.isOptionDisabled ? e.isOptionDisabled(t) : null, selected: t.value === e.selectedItem.value }, scopedSlots: e._u([e._l(e.slots, function(o, a) {
|
|
468
|
+
return { key: a, fn: function(r) {
|
|
469
|
+
return [e._t(a, null, null, r)];
|
|
470
470
|
} };
|
|
471
471
|
})], null, !0) }, e.listboxOptionListeners));
|
|
472
472
|
})], 2);
|
|
473
|
-
}, pt = [], yt = /* @__PURE__ */
|
|
474
|
-
_t,
|
|
473
|
+
}, pt = [], yt = /* @__PURE__ */ N(
|
|
475
474
|
gt,
|
|
475
|
+
_t,
|
|
476
476
|
pt,
|
|
477
477
|
!1,
|
|
478
478
|
null,
|
|
479
479
|
null
|
|
480
480
|
);
|
|
481
481
|
const ht = yt.exports;
|
|
482
|
-
let
|
|
483
|
-
const
|
|
482
|
+
let ve = 0;
|
|
483
|
+
const St = {
|
|
484
484
|
beforeCreate() {
|
|
485
|
-
this.uuid =
|
|
485
|
+
this.uuid = ve.toString(), ve += 1;
|
|
486
486
|
}
|
|
487
487
|
};
|
|
488
|
-
var
|
|
488
|
+
var Ct = function() {
|
|
489
489
|
var e = this, l = e._self._c;
|
|
490
490
|
return l("svg", e._b({ staticClass: "ui-assets-icons-16", attrs: { role: "img", xmlns: "http://www.w3.org/2000/svg", width: "16", height: "16", fill: "none" } }, "svg", e.$attrs, !1), [e.$attrs["svg-title"] ? l("title", [e._v(e._s(e.$attrs["svg-title"]))]) : e._e(), l("path", { attrs: { fill: "#001222", d: "M9.69043 5.75L4.62988 10.8105L1.56934 7.75L2.62988 6.68945L4.62988 8.68945L8.62988 4.68945L9.69043 5.75Z" } }), l("path", { attrs: { fill: "#001222", d: "M13.9307 5.75L8.87012 10.8105L7.80957 9.75L12.8701 4.68945L13.9307 5.75Z" } })]);
|
|
491
|
-
},
|
|
491
|
+
}, xt = [], Ot = /* @__PURE__ */ N(
|
|
492
|
+
St,
|
|
492
493
|
Ct,
|
|
493
494
|
xt,
|
|
494
|
-
St,
|
|
495
495
|
!1,
|
|
496
496
|
null,
|
|
497
497
|
null
|
|
@@ -506,33 +506,70 @@ const Et = Ot.exports, Tt = {}, It = /* @__PURE__ */ G({
|
|
|
506
506
|
allSelected: { type: Boolean, default: !1 }
|
|
507
507
|
},
|
|
508
508
|
setup(s) {
|
|
509
|
-
const e = s, l =
|
|
510
|
-
[`b-checkbox-input--${
|
|
511
|
-
})), t =
|
|
512
|
-
[`b-checkbox-input__outline--${
|
|
513
|
-
[`b-checkbox-input__outline--${
|
|
514
|
-
[`b-checkbox-input__outline--${
|
|
509
|
+
const e = s, l = n(() => ({
|
|
510
|
+
[`b-checkbox-input--${J.DISABLED}`]: e.disabled
|
|
511
|
+
})), t = n(() => ({
|
|
512
|
+
[`b-checkbox-input__outline--${J.UNCHECKED}`]: !e.checked && !e.indeterminate && !e.allSelected,
|
|
513
|
+
[`b-checkbox-input__outline--${J.CHECKED}`]: (e.checked || e.allSelected) && !e.indeterminate,
|
|
514
|
+
[`b-checkbox-input__outline--${J.INDETERMINATE}`]: e.indeterminate
|
|
515
515
|
}));
|
|
516
516
|
return { __sfc: !0, props: e, conditionalClasses: l, outlineConditionalClasses: t, CheckmarkSmallIcon: We, MinusSmallIcon: Ve, DoubleCheckmarkSmallIcon: Et };
|
|
517
517
|
}
|
|
518
518
|
});
|
|
519
|
-
var
|
|
519
|
+
var At = function() {
|
|
520
520
|
var e = this, l = e._self._c, t = e._self._setupProxy;
|
|
521
521
|
return l("div", { staticClass: "b-checkbox-input", class: t.conditionalClasses, attrs: { role: "presentation" } }, [e.indeterminate ? l(t.MinusSmallIcon, { staticClass: "b-checkbox-input__icon", attrs: { "svg-title": "", "aria-hidden": "true" } }) : e.allSelected ? l(t.DoubleCheckmarkSmallIcon, { staticClass: "b-checkbox-input__icon", attrs: { "svg-title": "", "aria-hidden": "true", "data-testid": "decorative-checkbox-double-checkmark-icon" } }) : e.checked ? l(t.CheckmarkSmallIcon, { staticClass: "b-checkbox-input__icon", attrs: { "svg-title": "", "aria-hidden": "true" } }) : e._e(), l("div", { staticClass: "b-checkbox-input__outline", class: t.outlineConditionalClasses })], 1);
|
|
522
|
-
},
|
|
522
|
+
}, Lt = [], kt = /* @__PURE__ */ N(
|
|
523
523
|
It,
|
|
524
|
-
Lt,
|
|
525
524
|
At,
|
|
525
|
+
Lt,
|
|
526
526
|
!1,
|
|
527
527
|
null,
|
|
528
528
|
"b87bbaf9"
|
|
529
529
|
);
|
|
530
|
-
const
|
|
531
|
-
var
|
|
530
|
+
const oe = kt.exports;
|
|
531
|
+
var Se = /* @__PURE__ */ ((s) => (s.DISABLED = "disabled", s.STATIC_CATEGORY = "static-category", s))(Se || {}), U = /* @__PURE__ */ ((s) => (s.SELECT_CATEGORY = "select-category", s.UNSELECT_CATEGORY = "unselect-category", s.TOGGLE_CATEGORY_VISIBILITY = "toggle-category-visibility", s))(U || {});
|
|
532
532
|
const Rt = {
|
|
533
|
-
"
|
|
534
|
-
|
|
535
|
-
|
|
533
|
+
"de-DE": {
|
|
534
|
+
categoryClosed: "{category} geschlossen",
|
|
535
|
+
categoryOpened: "{category} geöffnet"
|
|
536
|
+
},
|
|
537
|
+
"en-GB": {
|
|
538
|
+
categoryClosed: "{category} closed",
|
|
539
|
+
categoryOpened: "{category} opened"
|
|
540
|
+
},
|
|
541
|
+
"en-US": {
|
|
542
|
+
categoryClosed: "{category} closed",
|
|
543
|
+
categoryOpened: "{category} opened"
|
|
544
|
+
},
|
|
545
|
+
"es-ES": {
|
|
546
|
+
categoryClosed: "{category} cerrado",
|
|
547
|
+
categoryOpened: "{category} abierto"
|
|
548
|
+
},
|
|
549
|
+
"es-MX": {
|
|
550
|
+
categoryClosed: "{category} cerrado",
|
|
551
|
+
categoryOpened: "{category} abierto"
|
|
552
|
+
},
|
|
553
|
+
"fr-FR": {
|
|
554
|
+
categoryClosed: "{category} fermée",
|
|
555
|
+
categoryOpened: "{category} ouverte"
|
|
556
|
+
},
|
|
557
|
+
"it-IT": {
|
|
558
|
+
categoryClosed: "{category} chiuso",
|
|
559
|
+
categoryOpened: "{category} aperto"
|
|
560
|
+
},
|
|
561
|
+
"ja-JP": {
|
|
562
|
+
categoryClosed: "{category}を閉じました",
|
|
563
|
+
categoryOpened: "{category}を開きました"
|
|
564
|
+
},
|
|
565
|
+
"pt-BR": {
|
|
566
|
+
categoryClosed: "{category} fechada",
|
|
567
|
+
categoryOpened: "{categoria} aberta"
|
|
568
|
+
},
|
|
569
|
+
"zh-CN": {
|
|
570
|
+
categoryClosed: "{category} 已关闭",
|
|
571
|
+
categoryOpened: "{category} 已打开"
|
|
572
|
+
}
|
|
536
573
|
}, Dt = G({
|
|
537
574
|
i18n: { messages: Rt },
|
|
538
575
|
name: "bento-listbox-multi-select-category",
|
|
@@ -541,7 +578,7 @@ const Rt = {
|
|
|
541
578
|
BentoListboxOption: Z,
|
|
542
579
|
ChevronDownIcon: je,
|
|
543
580
|
ChevronUpIcon: qe,
|
|
544
|
-
DecorativeCheckbox:
|
|
581
|
+
DecorativeCheckbox: oe
|
|
545
582
|
},
|
|
546
583
|
props: {
|
|
547
584
|
/**
|
|
@@ -587,52 +624,52 @@ const Rt = {
|
|
|
587
624
|
tabindex: { type: Number, default: -1 }
|
|
588
625
|
},
|
|
589
626
|
emits: [
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
627
|
+
U.SELECT_CATEGORY,
|
|
628
|
+
U.UNSELECT_CATEGORY,
|
|
629
|
+
U.TOGGLE_CATEGORY_VISIBILITY
|
|
593
630
|
],
|
|
594
631
|
setup(s, { emit: e }) {
|
|
595
|
-
const l =
|
|
632
|
+
const l = x(!1), { t } = le(), o = be("category-group"), a = be("category-name"), r = (E) => s.isOptionDisabled ? s.isOptionDisabled(E) : !1, f = n(
|
|
596
633
|
() => s.category.items.every((E) => r(E))
|
|
597
|
-
),
|
|
598
|
-
[`b-listbox-multi-select-category--${
|
|
599
|
-
})), T = (E,
|
|
600
|
-
E.preventDefault(), l.value =
|
|
601
|
-
},
|
|
634
|
+
), A = H(s, "staticCategories"), d = n(() => l.value || s.staticCategories), b = n(() => ({
|
|
635
|
+
[`b-listbox-multi-select-category--${Se.DISABLED}`]: f.value
|
|
636
|
+
})), T = (E, L) => {
|
|
637
|
+
E.preventDefault(), l.value = L !== void 0 ? L : !l.value, e(U.TOGGLE_CATEGORY_VISIBILITY, s.category.value);
|
|
638
|
+
}, _ = (E) => {
|
|
602
639
|
var Y;
|
|
603
|
-
const
|
|
604
|
-
return { isDisabled:
|
|
605
|
-
}, p =
|
|
640
|
+
const L = r(E), $ = ((Y = s.selectedItemsList) == null ? void 0 : Y.includes(E.value)) || !1;
|
|
641
|
+
return { isDisabled: L, isPreSelected: $ };
|
|
642
|
+
}, p = n(
|
|
606
643
|
() => s.category.items.filter((E) => {
|
|
607
|
-
const { isDisabled:
|
|
608
|
-
return
|
|
644
|
+
const { isDisabled: L, isPreSelected: $ } = _(E);
|
|
645
|
+
return L && $ || !L;
|
|
609
646
|
})
|
|
610
|
-
),
|
|
647
|
+
), C = n(
|
|
611
648
|
() => {
|
|
612
649
|
var E;
|
|
613
650
|
return (E = p.value) == null ? void 0 : E.filter(
|
|
614
|
-
({ value:
|
|
615
|
-
var
|
|
616
|
-
return (
|
|
651
|
+
({ value: L }) => {
|
|
652
|
+
var $;
|
|
653
|
+
return ($ = s.selectedItemsList) == null ? void 0 : $.includes(L);
|
|
617
654
|
}
|
|
618
655
|
);
|
|
619
656
|
}
|
|
620
|
-
), R =
|
|
657
|
+
), R = n(() => {
|
|
621
658
|
const E = l.value ? "categoryOpened" : "categoryClosed";
|
|
622
659
|
return t(E, { category: s.category.label });
|
|
623
660
|
}), B = () => {
|
|
624
|
-
e(
|
|
661
|
+
e(U.SELECT_CATEGORY);
|
|
625
662
|
}, I = () => {
|
|
626
|
-
e(
|
|
627
|
-
}, { isAllSelected: O, isIndeterminate:
|
|
628
|
-
|
|
663
|
+
e(U.UNSELECT_CATEGORY);
|
|
664
|
+
}, { isAllSelected: O, isIndeterminate: S, toggleSelectAll: v } = pe(
|
|
665
|
+
C,
|
|
629
666
|
p,
|
|
630
667
|
B,
|
|
631
668
|
I
|
|
632
|
-
), y =
|
|
633
|
-
D.value = !D.value,
|
|
669
|
+
), y = n(() => S.value ? "mixed" : `${O.value}`), D = x(O.value), P = () => {
|
|
670
|
+
D.value = !D.value, v(D.value);
|
|
634
671
|
};
|
|
635
|
-
return
|
|
672
|
+
return X(O, () => {
|
|
636
673
|
D.value = O.value;
|
|
637
674
|
}), {
|
|
638
675
|
// Values
|
|
@@ -641,17 +678,17 @@ const Rt = {
|
|
|
641
678
|
hasAllPropsDisabled: f,
|
|
642
679
|
isOpen: l,
|
|
643
680
|
isAllSelected: O,
|
|
644
|
-
isIndeterminate:
|
|
645
|
-
isStaticCategory:
|
|
646
|
-
categoryGroupId:
|
|
647
|
-
categoryNameId:
|
|
681
|
+
isIndeterminate: S,
|
|
682
|
+
isStaticCategory: A,
|
|
683
|
+
categoryGroupId: o,
|
|
684
|
+
categoryNameId: a,
|
|
648
685
|
// Computed
|
|
649
686
|
showItemChildren: d,
|
|
650
687
|
ariaCheckedComputed: y,
|
|
651
688
|
// Methods
|
|
652
689
|
handleSelectAll: P,
|
|
653
690
|
toggleOpen: T,
|
|
654
|
-
toggleSelectAll:
|
|
691
|
+
toggleSelectAll: v
|
|
655
692
|
};
|
|
656
693
|
}
|
|
657
694
|
});
|
|
@@ -666,23 +703,23 @@ var Bt = function() {
|
|
|
666
703
|
}] } }, [l("decorative-checkbox", { attrs: { indeterminate: e.isIndeterminate, disabled: e.hasAllPropsDisabled, checked: e.isAllSelected } }), l("span", { staticClass: "b-listbox-multi-select-category__label" }, [l("bento-typography", { staticClass: "b-listbox-multi-select-category__label-text", attrs: { id: e.categoryNameId, el: "span" } }, [e._v(" " + e._s(e.category.label) + " ")]), l("div", { staticClass: "b-listbox-multi-select-category__label-chevron", attrs: { "aria-hidden": "true", "data-testid": "toggle-listbox" }, on: { "!click": function(t) {
|
|
667
704
|
return t.stopPropagation(), e.toggleOpen.apply(null, arguments);
|
|
668
705
|
} } }, [e.isOpen ? l("chevron-up-icon", { attrs: { "svg-title": e.chevronTitle } }) : l("chevron-down-icon", { attrs: { "svg-title": e.chevronTitle } })], 1)], 1)], 1), l("div", { directives: [{ name: "show", rawName: "v-show", value: e.showItemChildren, expression: "showItemChildren" }], attrs: { id: e.categoryGroupId, role: "group", "aria-label": e.category.label } }, [e._t("default")], 2)], 1);
|
|
669
|
-
},
|
|
706
|
+
}, Mt = [], $t = /* @__PURE__ */ N(
|
|
670
707
|
Dt,
|
|
671
708
|
Bt,
|
|
672
|
-
|
|
709
|
+
Mt,
|
|
673
710
|
!1,
|
|
674
711
|
null,
|
|
675
712
|
"00ccd708"
|
|
676
713
|
);
|
|
677
|
-
const
|
|
714
|
+
const Nt = $t.exports;
|
|
678
715
|
var w = /* @__PURE__ */ ((s) => (s.SELECT_CATEGORY = "select-category", s.TOGGLE_CHECKBOX_SELECTION = "toggle-checkbox-selection", s.UNSELECT_CATEGORY = "unselect-category", s.TOGGLE_CATEGORY_VISIBILITY = "toggle-category-visibility", s))(w || {});
|
|
679
716
|
const wt = G({
|
|
680
717
|
name: "listbox-multi-select-options",
|
|
681
718
|
components: {
|
|
682
719
|
BentoListboxOption: Z,
|
|
683
720
|
BentoTypography: j,
|
|
684
|
-
ListboxMultiSelectCategory:
|
|
685
|
-
DecorativeCheckbox:
|
|
721
|
+
ListboxMultiSelectCategory: Nt,
|
|
722
|
+
DecorativeCheckbox: oe
|
|
686
723
|
},
|
|
687
724
|
inheritAttrs: !1,
|
|
688
725
|
props: {
|
|
@@ -760,25 +797,25 @@ const wt = G({
|
|
|
760
797
|
setup(s, { emit: e }) {
|
|
761
798
|
const l = (d) => {
|
|
762
799
|
s.isOptionDisabled(d) || e(w.TOGGLE_CHECKBOX_SELECTION, d);
|
|
763
|
-
}, t = (d) => !!d.items,
|
|
800
|
+
}, t = (d) => !!d.items, o = (d) => {
|
|
764
801
|
const b = s.isMultiLevel && s.searching;
|
|
765
802
|
return d.description && (!s.isMultiLevel || b);
|
|
766
|
-
},
|
|
803
|
+
}, a = (d) => d.items ? !!d.items.find((b) => s.selectedItemsList.includes(b.value)) : s.selectedItemsList.includes(d.value), r = (d) => {
|
|
767
804
|
if (t(d)) {
|
|
768
|
-
const b =
|
|
805
|
+
const b = a(d) ? w.UNSELECT_CATEGORY : w.SELECT_CATEGORY;
|
|
769
806
|
e(b, d);
|
|
770
807
|
} else
|
|
771
808
|
l(d);
|
|
772
809
|
};
|
|
773
810
|
return {
|
|
774
811
|
// Values
|
|
775
|
-
conditionalClasses:
|
|
812
|
+
conditionalClasses: n(() => ({
|
|
776
813
|
"b-listbox-multi-select-options__static-category-option": s.staticCategories,
|
|
777
814
|
"b-listbox-multi-select-options__category-option": s.categoryItems
|
|
778
815
|
})),
|
|
779
816
|
// Methods
|
|
780
|
-
isOptionSelected:
|
|
781
|
-
shouldShowDescription:
|
|
817
|
+
isOptionSelected: a,
|
|
818
|
+
shouldShowDescription: o,
|
|
782
819
|
toggleCheckboxSelection: l,
|
|
783
820
|
toggleSearchOption: r,
|
|
784
821
|
computedTabindex: (d) => s.itemsIndex[d] === s.focusedIndex ? 0 : -1,
|
|
@@ -791,31 +828,31 @@ const wt = G({
|
|
|
791
828
|
var Gt = function() {
|
|
792
829
|
var e = this, l = e._self._c;
|
|
793
830
|
return e._self._setupProxy, l("div", e._l(e.items, function(t) {
|
|
794
|
-
return l("div", { key: `selected-${t.value}` }, [e.searching && e.isMultiLevel ? [l("bento-listbox-option", { staticClass: "b-listbox-multi-select-options", class: e.conditionalClasses, attrs: { disabled: e.isOptionDisabled ? e.isOptionDisabled(t) : null, tabindex: e.computedTabindex(t.value), "aria-selected": `${e.isOptionSelected(t)}`, "aria-checked": `${e.isOptionSelected(t)}`, "aria-disabled": e.isOptionDisabled ? e.isOptionDisabled(t) : null, role: e.$attrs.role || "option" }, on: { click: function(
|
|
831
|
+
return l("div", { key: `selected-${t.value}` }, [e.searching && e.isMultiLevel ? [l("bento-listbox-option", { staticClass: "b-listbox-multi-select-options", class: e.conditionalClasses, attrs: { disabled: e.isOptionDisabled ? e.isOptionDisabled(t) : null, tabindex: e.computedTabindex(t.value), "aria-selected": `${e.isOptionSelected(t)}`, "aria-checked": `${e.isOptionSelected(t)}`, "aria-disabled": e.isOptionDisabled ? e.isOptionDisabled(t) : null, role: e.$attrs.role || "option" }, on: { click: function(o) {
|
|
795
832
|
return e.toggleSearchOption(t);
|
|
796
|
-
}, "enter-pressed": function(
|
|
833
|
+
}, "enter-pressed": function(o) {
|
|
797
834
|
return e.toggleSearchOption(t);
|
|
798
|
-
}, "space-pressed": function(
|
|
799
|
-
return
|
|
835
|
+
}, "space-pressed": function(o) {
|
|
836
|
+
return o.preventDefault(), e.toggleSearchOption(t);
|
|
800
837
|
} } }, [l("decorative-checkbox", { attrs: { disabled: e.isOptionDisabled ? e.isOptionDisabled(t) : null, checked: e.isOptionSelected(t) } }), e._t("default", function() {
|
|
801
838
|
return [l("span", { staticClass: "b-listbox-multi-select__option-text" }, [l("bento-typography", { attrs: { el: "span" } }, [e._v(e._s(t.label))]), e.shouldShowDescription(t) ? l("bento-typography", { staticClass: "b-listbox-multi-select__option-description", attrs: { el: "span" } }, [e._v(" " + e._s(t.description) + " ")]) : e._e()], 1)];
|
|
802
|
-
}, null, t)], 2)] : [t.items ? [l("listbox-multi-select-category", { attrs: { category: t, "static-categories": e.staticCategories, "is-option-disabled": e.isOptionDisabled, "selected-items-list": e.selectedItemsList, tabindex: e.computedTabindex(t.value) }, on: { "select-category": function(
|
|
839
|
+
}, null, t)], 2)] : [t.items ? [l("listbox-multi-select-category", { attrs: { category: t, "static-categories": e.staticCategories, "is-option-disabled": e.isOptionDisabled, "selected-items-list": e.selectedItemsList, tabindex: e.computedTabindex(t.value) }, on: { "select-category": function(o) {
|
|
803
840
|
return e.$emit(e.ListboxMultiSelectOptionsEvent.SELECT_CATEGORY, t);
|
|
804
|
-
}, "unselect-category": function(
|
|
841
|
+
}, "unselect-category": function(o) {
|
|
805
842
|
return e.$emit(e.ListboxMultiSelectOptionsEvent.UNSELECT_CATEGORY, t);
|
|
806
|
-
}, "toggle-category-visibility": function(
|
|
807
|
-
return e.$emit(e.ListboxMultiSelectOptionsEvent.TOGGLE_CATEGORY_VISIBILITY,
|
|
808
|
-
} } }, [l("listbox-multi-select-options", { attrs: { "category-items": "", items: t.items, "is-option-disabled": e.isOptionDisabled, "items-index": e.itemsIndex, "focused-index": e.focusedIndex, "is-multi-level": e.isMultiLevel, "static-categories": e.staticCategories, "selected-items-list": e.selectedItemsList, searching: e.searching, role: e.$attrs.role || "option" }, on: { "toggle-checkbox-selection": (
|
|
843
|
+
}, "toggle-category-visibility": function(o) {
|
|
844
|
+
return e.$emit(e.ListboxMultiSelectOptionsEvent.TOGGLE_CATEGORY_VISIBILITY, o);
|
|
845
|
+
} } }, [l("listbox-multi-select-options", { attrs: { "category-items": "", items: t.items, "is-option-disabled": e.isOptionDisabled, "items-index": e.itemsIndex, "focused-index": e.focusedIndex, "is-multi-level": e.isMultiLevel, "static-categories": e.staticCategories, "selected-items-list": e.selectedItemsList, searching: e.searching, role: e.$attrs.role || "option" }, on: { "toggle-checkbox-selection": (o) => e.toggleCheckboxSelection(o) } })], 1)] : l("bento-listbox-option", { staticClass: "b-listbox-multi-select-options", class: e.conditionalClasses, attrs: { disabled: e.isOptionDisabled ? e.isOptionDisabled(t) : null, tabindex: e.computedTabindex(t.value), "aria-selected": `${e.isOptionSelected(t)}`, "aria-checked": `${e.isOptionSelected(t)}`, "aria-disabled": e.isOptionDisabled ? e.isOptionDisabled(t) : null, role: e.$attrs.role || "option" }, on: { click: function(o) {
|
|
809
846
|
return e.toggleCheckboxSelection(t);
|
|
810
|
-
}, "enter-pressed": function(
|
|
847
|
+
}, "enter-pressed": function(o) {
|
|
811
848
|
return e.toggleCheckboxSelection(t);
|
|
812
|
-
}, "space-pressed": function(
|
|
813
|
-
return
|
|
849
|
+
}, "space-pressed": function(o) {
|
|
850
|
+
return o.preventDefault(), e.toggleCheckboxSelection(t);
|
|
814
851
|
} } }, [l("decorative-checkbox", { attrs: { disabled: e.isOptionDisabled ? e.isOptionDisabled(t) : null, checked: e.isOptionSelected(t) } }), e._t("default", function() {
|
|
815
852
|
return [l("span", { staticClass: "b-listbox-multi-select__option-text" }, [l("bento-typography", { attrs: { el: "span" } }, [e._v(e._s(t.label))]), e.shouldShowDescription(t) ? l("bento-typography", { staticClass: "b-listbox-multi-select__option-description", attrs: { el: "span" } }, [e._v(" " + e._s(t.description) + " ")]) : e._e()], 1)];
|
|
816
853
|
}, null, t)], 2)]], 2);
|
|
817
854
|
}), 0);
|
|
818
|
-
}, Pt = [], Ft = /* @__PURE__ */
|
|
855
|
+
}, Pt = [], Ft = /* @__PURE__ */ N(
|
|
819
856
|
wt,
|
|
820
857
|
Gt,
|
|
821
858
|
Pt,
|
|
@@ -823,23 +860,80 @@ var Gt = function() {
|
|
|
823
860
|
null,
|
|
824
861
|
"0985e0a4"
|
|
825
862
|
);
|
|
826
|
-
const Yt = Ft.exports,
|
|
827
|
-
const e =
|
|
863
|
+
const Yt = Ft.exports, zt = (s) => {
|
|
864
|
+
const e = n(() => {
|
|
828
865
|
var t;
|
|
829
|
-
return !!((t = s.value) != null && t.find(({ items:
|
|
830
|
-
}), l =
|
|
866
|
+
return !!((t = s.value) != null && t.find(({ items: o }) => !!o));
|
|
867
|
+
}), l = n(() => {
|
|
831
868
|
var t;
|
|
832
|
-
return e.value ? (t = s.value) == null ? void 0 : t.reduce((
|
|
869
|
+
return e.value ? (t = s.value) == null ? void 0 : t.reduce((o, a) => (a.items ? o.push(...a.items.flat()) : o.push(a), o), []) : s.value;
|
|
833
870
|
});
|
|
834
871
|
return {
|
|
835
872
|
isMultiLevelSelect: e,
|
|
836
873
|
flattenedItemsList: l
|
|
837
874
|
};
|
|
838
|
-
},
|
|
839
|
-
"
|
|
840
|
-
|
|
841
|
-
|
|
842
|
-
|
|
875
|
+
}, Ut = {
|
|
876
|
+
"de-DE": {
|
|
877
|
+
allSelected: "Alle ausgewählt ({total})",
|
|
878
|
+
numberOfTotalSelected: "{number} von {total} ausgewählt",
|
|
879
|
+
numbersSelected: "{number} ausgewählt",
|
|
880
|
+
selectAll: "Alle auswählen ({total})"
|
|
881
|
+
},
|
|
882
|
+
"en-GB": {
|
|
883
|
+
allSelected: "All selected ({total})",
|
|
884
|
+
numberOfTotalSelected: "{number} of {total} selected",
|
|
885
|
+
numbersSelected: "{number} selected",
|
|
886
|
+
selectAll: "Select all ({total})"
|
|
887
|
+
},
|
|
888
|
+
"en-US": {
|
|
889
|
+
allSelected: "All selected ({total})",
|
|
890
|
+
numberOfTotalSelected: "{number} of {total} selected",
|
|
891
|
+
numbersSelected: "{number} selected",
|
|
892
|
+
selectAll: "Select all ({total})"
|
|
893
|
+
},
|
|
894
|
+
"es-ES": {
|
|
895
|
+
allSelected: "Todos seleccionados ({total})",
|
|
896
|
+
numberOfTotalSelected: "{number} de {total} seleccionados",
|
|
897
|
+
numbersSelected: "{number} seleccionado",
|
|
898
|
+
selectAll: "Seleccionar todo ({total})"
|
|
899
|
+
},
|
|
900
|
+
"es-MX": {
|
|
901
|
+
allSelected: "Todos seleccionados ({total})",
|
|
902
|
+
numberOfTotalSelected: "{number} de {total} seleccionados",
|
|
903
|
+
numbersSelected: "{número} seleccionado",
|
|
904
|
+
selectAll: "Seleccionar todo ({total})"
|
|
905
|
+
},
|
|
906
|
+
"fr-FR": {
|
|
907
|
+
allSelected: "Tous sélectionnés ({total})",
|
|
908
|
+
numberOfTotalSelected: "{number} sélectionné(s) sur {total}",
|
|
909
|
+
numbersSelected: "{number} sélectionné(s)",
|
|
910
|
+
selectAll: "Tout sélectionner ({total})"
|
|
911
|
+
},
|
|
912
|
+
"it-IT": {
|
|
913
|
+
allSelected: "Tutti i selezionati ({total})",
|
|
914
|
+
numberOfTotalSelected: "{numero} su {totale} selezionati",
|
|
915
|
+
numbersSelected: "{numero} selezionati",
|
|
916
|
+
selectAll: "Seleziona tutto ({total})"
|
|
917
|
+
},
|
|
918
|
+
"ja-JP": {
|
|
919
|
+
allSelected: "すべて選択 ({total})",
|
|
920
|
+
numberOfTotalSelected: "{number}/{total}件が選択されました",
|
|
921
|
+
numbersSelected: "{number}件選択済み",
|
|
922
|
+
selectAll: "すべて選択 ({total})"
|
|
923
|
+
},
|
|
924
|
+
"pt-BR": {
|
|
925
|
+
allSelected: "Todos os selecionados ({total})",
|
|
926
|
+
numberOfTotalSelected: "{number} de {total} selecionados",
|
|
927
|
+
numbersSelected: "{number} selecionados",
|
|
928
|
+
selectAll: "Selecionar tudo ({total})"
|
|
929
|
+
},
|
|
930
|
+
"zh-CN": {
|
|
931
|
+
allSelected: "全部已选 ({total})",
|
|
932
|
+
numberOfTotalSelected: "已选择 {number} 个,共 {total} 个",
|
|
933
|
+
numbersSelected: "已选择 {number} 个",
|
|
934
|
+
selectAll: "选择全部({total})个"
|
|
935
|
+
}
|
|
936
|
+
}, Vt = { i18n: { messages: Ut } }, Wt = /* @__PURE__ */ G({
|
|
843
937
|
...Vt,
|
|
844
938
|
__name: "listbox-multi-select",
|
|
845
939
|
props: {
|
|
@@ -853,100 +947,100 @@ const Yt = Ft.exports, Ut = (s) => {
|
|
|
853
947
|
},
|
|
854
948
|
emits: ["select"],
|
|
855
949
|
setup(s, { expose: e, emit: l }) {
|
|
856
|
-
const t = s, { t:
|
|
950
|
+
const t = s, { t: o, n: a } = le(), r = Ge(), f = Pe(), A = n(
|
|
857
951
|
() => {
|
|
858
|
-
var i, u,
|
|
952
|
+
var i, u, m, h;
|
|
859
953
|
return {
|
|
860
954
|
"aria-label": (i = f["aria-label"]) == null ? void 0 : i.toString(),
|
|
861
955
|
"aria-busy": (u = f["aria-busy"]) == null ? void 0 : u.toString(),
|
|
862
|
-
"aria-atomic": (
|
|
956
|
+
"aria-atomic": (m = f["aria-atomic"]) == null ? void 0 : m.toString(),
|
|
863
957
|
"aria-live": (h = f["aria-live"]) == null ? void 0 : h.toString(),
|
|
864
958
|
"aria-multiselectable": !0
|
|
865
959
|
};
|
|
866
960
|
}
|
|
867
|
-
), d =
|
|
961
|
+
), d = x(null), b = x(null), T = x(null), _ = x(null), p = n(() => t.selectedValues.map(({ value: i }) => i)), { isMultiLevelSelect: C, flattenedItemsList: R } = zt(H(t, "items")), B = n(() => C.value && !t.staticCategories), I = n(() => B.value ? "tree" : "listbox"), O = n(() => B.value ? "treeitem" : "option"), S = (i) => {
|
|
868
962
|
var h;
|
|
869
|
-
const u = t.isOptionDisabled(i),
|
|
870
|
-
return { isDisabled: u, isPreSelected:
|
|
871
|
-
},
|
|
872
|
-
if (t.searching &&
|
|
963
|
+
const u = t.isOptionDisabled(i), m = ((h = p.value) == null ? void 0 : h.includes(i.value)) || !1;
|
|
964
|
+
return { isDisabled: u, isPreSelected: m };
|
|
965
|
+
}, v = n(() => {
|
|
966
|
+
if (t.searching && C)
|
|
873
967
|
return t.items;
|
|
874
968
|
const i = R.value.filter((u) => {
|
|
875
|
-
const { isDisabled:
|
|
876
|
-
return
|
|
969
|
+
const { isDisabled: m, isPreSelected: h } = S(u);
|
|
970
|
+
return m && h || !m;
|
|
877
971
|
});
|
|
878
972
|
return t.selectedValues.forEach((u) => {
|
|
879
|
-
i.find((
|
|
973
|
+
i.find((m) => m.value === u.value) || i.push(u);
|
|
880
974
|
}), i;
|
|
881
|
-
}), y =
|
|
975
|
+
}), y = n(
|
|
882
976
|
() => {
|
|
883
977
|
var i;
|
|
884
|
-
return (i =
|
|
885
|
-
var
|
|
886
|
-
return u.items &&
|
|
887
|
-
(
|
|
888
|
-
).length === u.items.length : (
|
|
978
|
+
return (i = v.value) == null ? void 0 : i.filter((u) => {
|
|
979
|
+
var m;
|
|
980
|
+
return u.items && C.value && t.searching ? u.items.filter(
|
|
981
|
+
(g) => (t.selectedValues ?? []).includes(g.value)
|
|
982
|
+
).length === u.items.length : (m = p.value) == null ? void 0 : m.includes(u.value);
|
|
889
983
|
});
|
|
890
984
|
}
|
|
891
|
-
), D = () =>
|
|
985
|
+
), D = () => C.value && !t.searching ? R.value.length : t.items.length, P = n(() => {
|
|
892
986
|
var h;
|
|
893
|
-
const i =
|
|
894
|
-
return
|
|
987
|
+
const i = v.value.length, u = D(), m = ((h = y.value) == null ? void 0 : h.length) || 0;
|
|
988
|
+
return m === 0 ? o("selectAll", { total: a(i) }) : m === u ? o("allSelected", { total: a(u) }) : m <= u ? o("numberOfTotalSelected", { number: a(m), total: a(u) }) : o("numbersSelected", { number: a(m) });
|
|
895
989
|
}), E = (i) => {
|
|
896
990
|
const u = (h) => {
|
|
897
|
-
const { isDisabled:
|
|
898
|
-
return
|
|
899
|
-
},
|
|
900
|
-
l("select", [...t.selectedValues, ...
|
|
901
|
-
},
|
|
902
|
-
const u = (
|
|
903
|
-
const { isDisabled: F, isPreSelected:
|
|
904
|
-
return !(F &&
|
|
905
|
-
},
|
|
991
|
+
const { isDisabled: g, isPreSelected: F } = S(h);
|
|
992
|
+
return g && F || !g;
|
|
993
|
+
}, m = i.filter(u).filter((h) => !p.value.includes(h.value));
|
|
994
|
+
l("select", [...t.selectedValues, ...m]);
|
|
995
|
+
}, L = (i) => {
|
|
996
|
+
const u = (g) => {
|
|
997
|
+
const { isDisabled: F, isPreSelected: $e } = S(g);
|
|
998
|
+
return !(F && $e);
|
|
999
|
+
}, m = i.filter(u).map(({ value: g }) => g), h = t.selectedValues.filter((g) => !(m != null && m.includes(g.value)));
|
|
906
1000
|
l("select", h);
|
|
907
|
-
},
|
|
1001
|
+
}, $ = () => {
|
|
908
1002
|
E(R.value);
|
|
909
1003
|
}, Y = () => {
|
|
910
|
-
|
|
911
|
-
}, { isAllSelected:
|
|
1004
|
+
L(R.value);
|
|
1005
|
+
}, { isAllSelected: z, isIndeterminate: k, toggleSelectAll: V } = pe(
|
|
912
1006
|
y,
|
|
913
|
-
|
|
914
|
-
|
|
1007
|
+
v,
|
|
1008
|
+
$,
|
|
915
1009
|
Y
|
|
916
|
-
),
|
|
1010
|
+
), Ce = n(() => k.value ? "mixed" : `${z.value}`), q = x(z.value), xe = () => {
|
|
917
1011
|
q.value = !q.value, V(q.value);
|
|
918
1012
|
};
|
|
919
|
-
|
|
920
|
-
q.value =
|
|
1013
|
+
X(z, () => {
|
|
1014
|
+
q.value = z.value;
|
|
921
1015
|
});
|
|
922
1016
|
const Oe = (i) => {
|
|
923
1017
|
E(i.items);
|
|
924
1018
|
}, Ee = (i) => {
|
|
925
|
-
|
|
1019
|
+
L(i.items);
|
|
926
1020
|
}, Te = (i, u) => {
|
|
927
|
-
let
|
|
928
|
-
const h = t.selectedValues.filter(({ value:
|
|
929
|
-
|
|
930
|
-
}, Ie =
|
|
931
|
-
if (!
|
|
1021
|
+
let m = !1;
|
|
1022
|
+
const h = t.selectedValues.filter(({ value: g }) => u.value === g ? (m = !0, !1) : !0);
|
|
1023
|
+
m || h.push(u), l(i, h);
|
|
1024
|
+
}, Ie = n(() => {
|
|
1025
|
+
if (!C.value)
|
|
932
1026
|
return t.selectedValues;
|
|
933
|
-
const i = (
|
|
1027
|
+
const i = (g) => p.value.includes(g.value), u = (g) => !t.staticCategories && g.every((F) => i(F));
|
|
934
1028
|
return t.items.flatMap(
|
|
935
|
-
(
|
|
936
|
-
).filter((
|
|
937
|
-
}),
|
|
938
|
-
var
|
|
939
|
-
const i = ["automatic", "button"].includes(t.lazyLoadType), u = ((
|
|
1029
|
+
(g) => g.items && !u(g.items) ? g.items : g
|
|
1030
|
+
).filter((g) => g.items ? !0 : i(g));
|
|
1031
|
+
}), Ae = n(() => {
|
|
1032
|
+
var m, h, g, F;
|
|
1033
|
+
const i = ["automatic", "button"].includes(t.lazyLoadType), u = ((m = t.selectedValues) == null ? void 0 : m.length) > 0 && ((h = y.value) == null ? void 0 : h.length) !== ((g = R.value) == null ? void 0 : g.length);
|
|
940
1034
|
return i && t.hasMoreItems ? !!((F = t.selectedValues) != null && F.length) : u;
|
|
941
|
-
}),
|
|
1035
|
+
}), Le = n(() => ["automatic", "button"].includes(t.lazyLoadType) ? !t.hasMoreItems : !0), W = x([]), { visibleDomOptions: Q, updateVisibleDomOptions: ae } = he(
|
|
942
1036
|
d,
|
|
943
1037
|
H(t, "items"),
|
|
944
1038
|
O
|
|
945
1039
|
), ke = (i) => {
|
|
946
|
-
W.value.includes(i) ? W.value = W.value.filter((u) => u !== i) : W.value.push(i),
|
|
947
|
-
|
|
1040
|
+
W.value.includes(i) ? W.value = W.value.filter((u) => u !== i) : W.value.push(i), _e(() => {
|
|
1041
|
+
ae();
|
|
948
1042
|
});
|
|
949
|
-
},
|
|
1043
|
+
}, ne = (i) => {
|
|
950
1044
|
var u;
|
|
951
1045
|
(u = Q.value[i]) == null || u.focus();
|
|
952
1046
|
}, {
|
|
@@ -961,12 +1055,12 @@ const Yt = Ft.exports, Ut = (s) => {
|
|
|
961
1055
|
{
|
|
962
1056
|
items: Q
|
|
963
1057
|
},
|
|
964
|
-
|
|
1058
|
+
ne
|
|
965
1059
|
), De = {
|
|
966
|
-
[
|
|
967
|
-
[
|
|
968
|
-
[
|
|
969
|
-
[
|
|
1060
|
+
[M.ARROW_UP]: (i) => ce(i),
|
|
1061
|
+
[M.ARROW_DOWN]: (i) => ie(i),
|
|
1062
|
+
[M.HOME]: re,
|
|
1063
|
+
[M.END]: ue
|
|
970
1064
|
};
|
|
971
1065
|
e({
|
|
972
1066
|
/**
|
|
@@ -976,41 +1070,41 @@ const Yt = Ft.exports, Ut = (s) => {
|
|
|
976
1070
|
setListboxFocusedIndex: de
|
|
977
1071
|
});
|
|
978
1072
|
const Be = {
|
|
979
|
-
[
|
|
980
|
-
[
|
|
981
|
-
},
|
|
1073
|
+
[M.ARROW_UP]: ee,
|
|
1074
|
+
[M.ARROW_DOWN]: ee
|
|
1075
|
+
}, Me = n(() => {
|
|
982
1076
|
let i = 1;
|
|
983
1077
|
const u = {};
|
|
984
|
-
return t.items.forEach((
|
|
985
|
-
let h = W.value.includes(
|
|
986
|
-
|
|
1078
|
+
return t.items.forEach((m) => {
|
|
1079
|
+
let h = W.value.includes(m.value);
|
|
1080
|
+
m.items ? (t.staticCategories ? h = !0 : u[m.value] = i++, h && m.items.forEach((g) => u[g.value] = i++)) : u[m.value] = i++;
|
|
987
1081
|
}), u;
|
|
988
1082
|
});
|
|
989
|
-
return { __sfc: !0, props: t, emit: l, t:
|
|
1083
|
+
return { __sfc: !0, props: t, emit: l, t: o, n: a, slots: r, attrs: f, ariaAttributes: A, listboxRef: d, selectAllListboxItemsRef: b, selectedListboxItemsRef: T, listboxItemsRef: _, selectedItemsList: p, isMultiLevelSelect: C, flattenedItemsList: R, isTreePattern: B, computedRole: I, computedOptionRole: O, optionStates: S, enabledItems: v, visibleSelectedList: y, calculateTotalItems: D, selectAllCheckboxText: P, selectAll: E, unselectAll: L, selectAllItems: $, unselectAllItems: Y, isAllSelected: z, isIndeterminate: k, toggleSelectAll: V, ariaCheckedComputed: Ce, isSelectAllOn: q, handleSelectAll: xe, selectAllCategory: Oe, unselectAllCategory: Ee, toggleCheckboxSelection: Te, selectedOptions: Ie, showSelectedItems: Ae, showSelectAllCheckbox: Le, expandedCategories: W, visibleDomOptions: Q, updateVisibleDomOptions: ae, toggleCategoryVisibility: ke, focusItem: ne, moveToNextElement: ie, moveToPreviousElement: ce, moveToFirstElement: re, moveToLastElement: ue, preventDefault: ee, focusedIndex: Re, setListboxFocusedIndex: de, listboxListeners: De, chipsSectionListeners: Be, computedItemsIndex: Me, DecorativeCheckbox: oe, BentoTypography: j, BentoChip: Ke, BentoListboxOption: Z, ListboxMultiSelectOptions: Yt, vBentoKeyboardNavigationDirective: se, BentoListboxEvent: c };
|
|
990
1084
|
}
|
|
991
1085
|
});
|
|
992
1086
|
var Kt = function() {
|
|
993
1087
|
var e = this, l = e._self._c, t = e._self._setupProxy;
|
|
994
|
-
return l("div", { ref: "listboxRef", staticClass: "b-listbox-multi-select" }, [t.showSelectedItems ? l("div", [l("ul", e._g({ directives: [{ name: "bento-keyboard-navigation-directive", rawName: "v-bento-keyboard-navigation-directive" }], staticClass: "b-listbox-multi-select__chips" }, t.chipsSectionListeners), e._l(t.selectedOptions, function(
|
|
995
|
-
return l("li", { key:
|
|
996
|
-
|
|
1088
|
+
return l("div", { ref: "listboxRef", staticClass: "b-listbox-multi-select" }, [t.showSelectedItems ? l("div", [l("ul", e._g({ directives: [{ name: "bento-keyboard-navigation-directive", rawName: "v-bento-keyboard-navigation-directive" }], staticClass: "b-listbox-multi-select__chips" }, t.chipsSectionListeners), e._l(t.selectedOptions, function(o) {
|
|
1089
|
+
return l("li", { key: o.value }, [l(t.BentoChip, { ref: "selectedListboxItemsRef", refInFor: !0, attrs: { disabled: e.isOptionDisabled(o), label: o.label, condensed: "" }, on: { click: function(a) {
|
|
1090
|
+
o.items ? t.unselectAllCategory(o) : t.toggleCheckboxSelection("select", o);
|
|
997
1091
|
} } })], 1);
|
|
998
|
-
}), 0), l("hr", { staticClass: "b-listbox-multi-select__divider", attrs: { "aria-hidden": "true" } })]) : e._e(), l("div", e._g(e._b({ directives: [{ name: "bento-keyboard-navigation-directive", rawName: "v-bento-keyboard-navigation-directive" }], attrs: { role: t.computedRole } }, "div", t.ariaAttributes, !1), t.listboxListeners), [t.showSelectAllCheckbox ? l(t.BentoListboxOption, { ref: "selectAllListboxItemsRef", staticClass: "b-listbox-multi-select__option", attrs: { tabindex: t.focusedIndex === 0 ? 0 : -1, "aria-selected": t.ariaCheckedComputed !== "false", "aria-checked": t.ariaCheckedComputed, role: t.computedOptionRole }, on: { click: t.handleSelectAll, "enter-pressed": t.handleSelectAll, "space-pressed": function(
|
|
999
|
-
return
|
|
1000
|
-
} } }, [l(t.DecorativeCheckbox, { attrs: { checked: t.isAllSelected, indeterminate: t.isIndeterminate } }), l(t.BentoTypography, { attrs: { el: "span" } }, [e._v(" " + e._s(t.selectAllCheckboxText) + " ")])], 1) : e._e(), t.showSelectAllCheckbox ? l("hr", { staticClass: "b-listbox-multi-select__divider", attrs: { "aria-hidden": "true" } }) : e._e(), l(t.ListboxMultiSelectOptions, { ref: "listboxItemsRef", attrs: { items: e.items, "is-option-disabled": e.isOptionDisabled, "is-multi-level": t.isMultiLevelSelect, "static-categories": e.staticCategories, searching: e.searching, "selected-items-list": t.selectedItemsList, "focused-index": t.focusedIndex, "items-index": t.computedItemsIndex, role: t.computedOptionRole }, on: { "toggle-checkbox-selection": function(
|
|
1001
|
-
return t.toggleCheckboxSelection("select",
|
|
1002
|
-
}, "select-category": t.selectAllCategory, "unselect-category": t.unselectAllCategory, "toggle-category-visibility": t.toggleCategoryVisibility, "space-pressed": function(
|
|
1003
|
-
return t.toggleCheckboxSelection(t.BentoListboxEvent.SPACE,
|
|
1004
|
-
}, "tab-pressed": function(
|
|
1005
|
-
return t.toggleCheckboxSelection(t.BentoListboxEvent.TAB,
|
|
1006
|
-
}, "enter-pressed": function(
|
|
1007
|
-
return t.toggleCheckboxSelection(t.BentoListboxEvent.ENTER,
|
|
1008
|
-
} }, scopedSlots: e._u([e._l(t.slots, function(
|
|
1009
|
-
return { key:
|
|
1010
|
-
return [e._t(
|
|
1092
|
+
}), 0), l("hr", { staticClass: "b-listbox-multi-select__divider", attrs: { "aria-hidden": "true" } })]) : e._e(), l("div", e._g(e._b({ directives: [{ name: "bento-keyboard-navigation-directive", rawName: "v-bento-keyboard-navigation-directive" }], attrs: { role: t.computedRole } }, "div", t.ariaAttributes, !1), t.listboxListeners), [t.showSelectAllCheckbox ? l(t.BentoListboxOption, { ref: "selectAllListboxItemsRef", staticClass: "b-listbox-multi-select__option", attrs: { tabindex: t.focusedIndex === 0 ? 0 : -1, "aria-selected": t.ariaCheckedComputed !== "false", "aria-checked": t.ariaCheckedComputed, role: t.computedOptionRole }, on: { click: t.handleSelectAll, "enter-pressed": t.handleSelectAll, "space-pressed": function(o) {
|
|
1093
|
+
return o.preventDefault(), t.handleSelectAll.apply(null, arguments);
|
|
1094
|
+
} } }, [l(t.DecorativeCheckbox, { attrs: { checked: t.isAllSelected, indeterminate: t.isIndeterminate } }), l(t.BentoTypography, { attrs: { el: "span" } }, [e._v(" " + e._s(t.selectAllCheckboxText) + " ")])], 1) : e._e(), t.showSelectAllCheckbox ? l("hr", { staticClass: "b-listbox-multi-select__divider", attrs: { "aria-hidden": "true" } }) : e._e(), l(t.ListboxMultiSelectOptions, { ref: "listboxItemsRef", attrs: { items: e.items, "is-option-disabled": e.isOptionDisabled, "is-multi-level": t.isMultiLevelSelect, "static-categories": e.staticCategories, searching: e.searching, "selected-items-list": t.selectedItemsList, "focused-index": t.focusedIndex, "items-index": t.computedItemsIndex, role: t.computedOptionRole }, on: { "toggle-checkbox-selection": function(o) {
|
|
1095
|
+
return t.toggleCheckboxSelection("select", o);
|
|
1096
|
+
}, "select-category": t.selectAllCategory, "unselect-category": t.unselectAllCategory, "toggle-category-visibility": t.toggleCategoryVisibility, "space-pressed": function(o) {
|
|
1097
|
+
return t.toggleCheckboxSelection(t.BentoListboxEvent.SPACE, o);
|
|
1098
|
+
}, "tab-pressed": function(o) {
|
|
1099
|
+
return t.toggleCheckboxSelection(t.BentoListboxEvent.TAB, o);
|
|
1100
|
+
}, "enter-pressed": function(o) {
|
|
1101
|
+
return t.toggleCheckboxSelection(t.BentoListboxEvent.ENTER, o);
|
|
1102
|
+
} }, scopedSlots: e._u([e._l(t.slots, function(o, a) {
|
|
1103
|
+
return { key: a, fn: function(r) {
|
|
1104
|
+
return [e._t(a, null, null, r)];
|
|
1011
1105
|
} };
|
|
1012
1106
|
})], null, !0) })], 1)]);
|
|
1013
|
-
}, jt = [], qt = /* @__PURE__ */
|
|
1107
|
+
}, jt = [], qt = /* @__PURE__ */ N(
|
|
1014
1108
|
Wt,
|
|
1015
1109
|
Kt,
|
|
1016
1110
|
jt,
|
|
@@ -1018,16 +1112,53 @@ var Kt = function() {
|
|
|
1018
1112
|
null,
|
|
1019
1113
|
"efcc8ad5"
|
|
1020
1114
|
);
|
|
1021
|
-
const
|
|
1022
|
-
"
|
|
1023
|
-
|
|
1024
|
-
|
|
1025
|
-
},
|
|
1115
|
+
const ge = qt.exports, Ht = {
|
|
1116
|
+
"de-DE": {
|
|
1117
|
+
loading: "Laden",
|
|
1118
|
+
showMore: "Mehr anzeigen"
|
|
1119
|
+
},
|
|
1120
|
+
"en-GB": {
|
|
1121
|
+
loading: "Loading",
|
|
1122
|
+
showMore: "Show more"
|
|
1123
|
+
},
|
|
1124
|
+
"en-US": {
|
|
1125
|
+
loading: "Loading",
|
|
1126
|
+
showMore: "Show more"
|
|
1127
|
+
},
|
|
1128
|
+
"es-ES": {
|
|
1129
|
+
loading: "Cargando",
|
|
1130
|
+
showMore: "Mostrar más"
|
|
1131
|
+
},
|
|
1132
|
+
"es-MX": {
|
|
1133
|
+
loading: "Cargando",
|
|
1134
|
+
showMore: "Mostrar más"
|
|
1135
|
+
},
|
|
1136
|
+
"fr-FR": {
|
|
1137
|
+
loading: "Chargement",
|
|
1138
|
+
showMore: "Afficher plus"
|
|
1139
|
+
},
|
|
1140
|
+
"it-IT": {
|
|
1141
|
+
loading: "Caricamento",
|
|
1142
|
+
showMore: "Mostra di più"
|
|
1143
|
+
},
|
|
1144
|
+
"ja-JP": {
|
|
1145
|
+
loading: "読み込み中",
|
|
1146
|
+
showMore: "さらに表示"
|
|
1147
|
+
},
|
|
1148
|
+
"pt-BR": {
|
|
1149
|
+
loading: "Carregando",
|
|
1150
|
+
showMore: "Mostrar mais"
|
|
1151
|
+
},
|
|
1152
|
+
"zh-CN": {
|
|
1153
|
+
loading: "正在加载",
|
|
1154
|
+
showMore: "显示更多"
|
|
1155
|
+
}
|
|
1156
|
+
}, Xt = 36, Jt = G({
|
|
1026
1157
|
name: "bento-listbox",
|
|
1027
1158
|
components: {
|
|
1028
1159
|
BentoEmptyState: Ye,
|
|
1029
1160
|
BentoListboxSingleSelect: ht,
|
|
1030
|
-
BentoListboxMultiSelect:
|
|
1161
|
+
BentoListboxMultiSelect: ge,
|
|
1031
1162
|
BentoTypography: j,
|
|
1032
1163
|
BentoLoadingIndicator: Fe,
|
|
1033
1164
|
BentoLoadingButton: He
|
|
@@ -1114,7 +1245,7 @@ const _e = qt.exports, Ht = {
|
|
|
1114
1245
|
*
|
|
1115
1246
|
* If enabled, hides the "Select all" checkbox in "multiple" mode.
|
|
1116
1247
|
*/
|
|
1117
|
-
searching:
|
|
1248
|
+
searching: ge.props.searching,
|
|
1118
1249
|
/**
|
|
1119
1250
|
* The `input` value.
|
|
1120
1251
|
* Providing an empty string or empty array will select no options.
|
|
@@ -1142,64 +1273,64 @@ const _e = qt.exports, Ht = {
|
|
|
1142
1273
|
c.TAB
|
|
1143
1274
|
],
|
|
1144
1275
|
setup(s, { emit: e, slots: l }) {
|
|
1145
|
-
const t =
|
|
1276
|
+
const t = x([]), o = H(s, "items"), { t: a } = le(), r = n(() => s.lazyLoadType !== K.AUTOMATIC), f = n(() => s.lazyLoadType === K.AUTOMATIC), A = () => {
|
|
1146
1277
|
var k;
|
|
1147
|
-
return typeof (s == null ? void 0 : s.virtualScroll) == "object" && ((k = s == null ? void 0 : s.virtualScroll) != null && k.itemHeight) ? s.virtualScroll.itemHeight :
|
|
1278
|
+
return typeof (s == null ? void 0 : s.virtualScroll) == "object" && ((k = s == null ? void 0 : s.virtualScroll) != null && k.itemHeight) ? s.virtualScroll.itemHeight : Xt;
|
|
1148
1279
|
}, {
|
|
1149
1280
|
containerRef: d,
|
|
1150
1281
|
containerProps: b,
|
|
1151
1282
|
onScroll: T,
|
|
1152
|
-
list:
|
|
1283
|
+
list: _,
|
|
1153
1284
|
wrapperProps: p
|
|
1154
|
-
} =
|
|
1155
|
-
itemHeight:
|
|
1285
|
+
} = Xe(o, {
|
|
1286
|
+
itemHeight: A(),
|
|
1156
1287
|
// Disable virtual scrolling if not enabled or if lazy loading is enabled or if multi-select
|
|
1157
1288
|
disabled: (s == null ? void 0 : s.multiple) || (s == null ? void 0 : s.virtualScroll) === !1 || (s == null ? void 0 : s.lazyLoadType) !== "none"
|
|
1158
|
-
}),
|
|
1289
|
+
}), C = n(
|
|
1159
1290
|
() => s.componentLoading !== void 0 || r.value ? "true" : void 0
|
|
1160
|
-
), R =
|
|
1291
|
+
), R = n(
|
|
1161
1292
|
() => r.value && s.loading || s.componentLoading ? "true" : "false"
|
|
1162
|
-
), B =
|
|
1293
|
+
), B = n(
|
|
1163
1294
|
() => r.value || s.componentLoading !== void 0 ? "polite" : void 0
|
|
1164
|
-
), I =
|
|
1295
|
+
), I = n(
|
|
1165
1296
|
() => ({
|
|
1166
1297
|
"aria-label": s.ariaLabel,
|
|
1167
1298
|
"aria-busy": R.value,
|
|
1168
|
-
"aria-atomic":
|
|
1299
|
+
"aria-atomic": C.value,
|
|
1169
1300
|
"aria-live": B.value
|
|
1170
1301
|
})
|
|
1171
|
-
), O =
|
|
1302
|
+
), O = n(
|
|
1172
1303
|
() => s.componentLoading ? {
|
|
1173
1304
|
...I.value,
|
|
1174
1305
|
role: "alert"
|
|
1175
1306
|
} : {}
|
|
1176
|
-
),
|
|
1307
|
+
), S = (k) => (V) => {
|
|
1177
1308
|
e(k, V);
|
|
1178
|
-
},
|
|
1309
|
+
}, v = () => {
|
|
1179
1310
|
e(c.SHOW_MORE);
|
|
1180
|
-
}, y =
|
|
1311
|
+
}, y = ze(() => {
|
|
1181
1312
|
const k = d.value;
|
|
1182
1313
|
if (!k)
|
|
1183
1314
|
return;
|
|
1184
1315
|
const V = Math.round(k.scrollTop) + k.clientHeight >= k.scrollHeight;
|
|
1185
|
-
s.hasMoreItems && V && !s.loading &&
|
|
1316
|
+
s.hasMoreItems && V && !s.loading && v();
|
|
1186
1317
|
}), D = () => {
|
|
1187
1318
|
f.value ? y() : T();
|
|
1188
|
-
}, P =
|
|
1319
|
+
}, P = n(() => {
|
|
1189
1320
|
var k;
|
|
1190
1321
|
return ((k = s.items) == null ? void 0 : k.length) === 0;
|
|
1191
|
-
}), E =
|
|
1322
|
+
}), E = n(
|
|
1192
1323
|
() => s.lazyLoadType === K.BUTTON && s.hasMoreItems
|
|
1193
|
-
),
|
|
1324
|
+
), L = n(
|
|
1194
1325
|
() => s.loading ? fe.LOADING : fe.START
|
|
1195
|
-
),
|
|
1326
|
+
), $ = n(() => s.loading ? a("loading") : a("showMore")), Y = n(() => ({
|
|
1196
1327
|
...s.emptyState,
|
|
1197
1328
|
variant: "condensed"
|
|
1198
|
-
})),
|
|
1199
|
-
[c.SELECT]:
|
|
1200
|
-
[c.SPACE]:
|
|
1201
|
-
[c.TAB]:
|
|
1202
|
-
[c.ENTER]:
|
|
1329
|
+
})), z = {
|
|
1330
|
+
[c.SELECT]: S(c.SELECT),
|
|
1331
|
+
[c.SPACE]: S(c.SPACE),
|
|
1332
|
+
[c.TAB]: S(c.TAB),
|
|
1333
|
+
[c.ENTER]: S(c.ENTER)
|
|
1203
1334
|
};
|
|
1204
1335
|
return {
|
|
1205
1336
|
// Refs
|
|
@@ -1212,39 +1343,39 @@ const _e = qt.exports, Ht = {
|
|
|
1212
1343
|
containerProps: b,
|
|
1213
1344
|
isSearchResultEmpty: P,
|
|
1214
1345
|
limitedEmptyStateProps: Y,
|
|
1215
|
-
loadingButtonState:
|
|
1346
|
+
loadingButtonState: L,
|
|
1216
1347
|
slots: l,
|
|
1217
1348
|
shouldDisplayShowMoreButton: E,
|
|
1218
|
-
showMoreButtonText:
|
|
1219
|
-
virtualisedItems:
|
|
1349
|
+
showMoreButtonText: $,
|
|
1350
|
+
virtualisedItems: _,
|
|
1220
1351
|
wrapperProps: p,
|
|
1221
1352
|
// Enums
|
|
1222
|
-
BentoKeyboardNavigationKeyDownEvent:
|
|
1353
|
+
BentoKeyboardNavigationKeyDownEvent: M,
|
|
1223
1354
|
BentoListboxEvent: c,
|
|
1224
1355
|
// Methods
|
|
1225
1356
|
onListboxContainerScroll: D,
|
|
1226
|
-
onOptionSelected:
|
|
1227
|
-
emitShowMore:
|
|
1228
|
-
listboxListeners:
|
|
1357
|
+
onOptionSelected: S,
|
|
1358
|
+
emitShowMore: v,
|
|
1359
|
+
listboxListeners: z
|
|
1229
1360
|
};
|
|
1230
1361
|
}
|
|
1231
1362
|
});
|
|
1232
1363
|
var Zt = function() {
|
|
1233
1364
|
var t;
|
|
1234
1365
|
var e = this, l = e._self._c;
|
|
1235
|
-
return e._self._setupProxy, l("div", e._b({ directives: [{ name: "bento-keyboard-navigation-directive", rawName: "v-bento-keyboard-navigation-directive" }], ref: "listboxRef", staticClass: "b-listbox", style: (t = e.containerProps) == null ? void 0 : t.style, attrs: { id: e.id, tabindex: "-1", "data-testid": "listbox-container" }, on: { scroll: e.onListboxContainerScroll } }, "div", e.listboxContainerAttributes, !1), [l("div", e._b({}, "div", e.wrapperProps, !1), [e.componentLoading ? l("div", { staticClass: "b-listbox__loading-filtered-items" }, [l("bento-loading-indicator")], 1) : e.isSearchResultEmpty ? l("div", { staticClass: "b-listbox__empty-search-message" }, [e.emptyState ? l("bento-empty-state", e._b({}, "bento-empty-state", e.limitedEmptyStateProps, !1)) : l("bento-typography", { attrs: { el: "span" } }, [e._v(e._s(e.noResultsMessage))])], 1) : [e.multiple ? [l("bento-listbox-multi-select", e._g(e._b({ ref: "listboxItemRef", attrs: { "has-more-items": e.hasMoreItems, items: e.items, "lazy-load-type": e.lazyLoadType, "static-categories": e.staticCategories, "selected-values": e.selectedValue, searching: e.searching, "is-option-disabled": e.isOptionDisabled }, scopedSlots: e._u([e._l(e.slots, function(
|
|
1236
|
-
return { key:
|
|
1237
|
-
return [e._t(
|
|
1366
|
+
return e._self._setupProxy, l("div", e._b({ directives: [{ name: "bento-keyboard-navigation-directive", rawName: "v-bento-keyboard-navigation-directive" }], ref: "listboxRef", staticClass: "b-listbox", style: (t = e.containerProps) == null ? void 0 : t.style, attrs: { id: e.id, tabindex: "-1", "data-testid": "listbox-container" }, on: { scroll: e.onListboxContainerScroll } }, "div", e.listboxContainerAttributes, !1), [l("div", e._b({}, "div", e.wrapperProps, !1), [e.componentLoading ? l("div", { staticClass: "b-listbox__loading-filtered-items" }, [l("bento-loading-indicator")], 1) : e.isSearchResultEmpty ? l("div", { staticClass: "b-listbox__empty-search-message" }, [e.emptyState ? l("bento-empty-state", e._b({}, "bento-empty-state", e.limitedEmptyStateProps, !1)) : l("bento-typography", { attrs: { el: "span" } }, [e._v(e._s(e.noResultsMessage))])], 1) : [e.multiple ? [l("bento-listbox-multi-select", e._g(e._b({ ref: "listboxItemRef", attrs: { "has-more-items": e.hasMoreItems, items: e.items, "lazy-load-type": e.lazyLoadType, "static-categories": e.staticCategories, "selected-values": e.selectedValue, searching: e.searching, "is-option-disabled": e.isOptionDisabled }, scopedSlots: e._u([e._l(e.slots, function(o, a) {
|
|
1367
|
+
return { key: a, fn: function(r) {
|
|
1368
|
+
return [e._t(a, null, null, r)];
|
|
1238
1369
|
} };
|
|
1239
|
-
})], null, !0) }, "bento-listbox-multi-select", e.ariaAttributes, !1), e.listboxListeners))] : [l("bento-listbox-single-select", e._g(e._b({ ref: "listboxItemRef", attrs: { items: e.virtualisedItems, "selected-value": e.selectedValue, "static-categories": e.staticCategories, "is-option-disabled": e.isOptionDisabled }, scopedSlots: e._u([e._l(e.slots, function(
|
|
1240
|
-
return { key:
|
|
1241
|
-
return [e._t(
|
|
1370
|
+
})], null, !0) }, "bento-listbox-multi-select", e.ariaAttributes, !1), e.listboxListeners))] : [l("bento-listbox-single-select", e._g(e._b({ ref: "listboxItemRef", attrs: { items: e.virtualisedItems, "selected-value": e.selectedValue, "static-categories": e.staticCategories, "is-option-disabled": e.isOptionDisabled }, scopedSlots: e._u([e._l(e.slots, function(o, a) {
|
|
1371
|
+
return { key: a, fn: function(r) {
|
|
1372
|
+
return [e._t(a, null, null, r)];
|
|
1242
1373
|
} };
|
|
1243
|
-
})], null, !0) }, "bento-listbox-single-select", e.ariaAttributes, !1), e.listboxListeners))], e.shouldDisplayShowMoreButton ? l("div", { staticClass: "b-listbox__lazy-load" }, [l("bento-loading-button", { attrs: { state: e.loadingButtonState, variant: "secondary" }, on: { "!click": function(
|
|
1374
|
+
})], null, !0) }, "bento-listbox-single-select", e.ariaAttributes, !1), e.listboxListeners))], e.shouldDisplayShowMoreButton ? l("div", { staticClass: "b-listbox__lazy-load" }, [l("bento-loading-button", { attrs: { state: e.loadingButtonState, variant: "secondary" }, on: { "!click": function(o) {
|
|
1244
1375
|
return e.emitShowMore.apply(null, arguments);
|
|
1245
1376
|
} } }, [e._v(" " + e._s(e.showMoreButtonText) + " ")])], 1) : e.loading ? l("div", { staticClass: "b-listbox__lazy-load" }, [l("bento-loading-indicator")], 1) : e._e()]], 2)]);
|
|
1246
|
-
}, Qt = [], es = /* @__PURE__ */
|
|
1247
|
-
|
|
1377
|
+
}, Qt = [], es = /* @__PURE__ */ N(
|
|
1378
|
+
Jt,
|
|
1248
1379
|
Zt,
|
|
1249
1380
|
Qt,
|
|
1250
1381
|
!1,
|
|
@@ -1262,58 +1393,58 @@ const hs = es.exports, te = (s, e) => {
|
|
|
1262
1393
|
}
|
|
1263
1394
|
}
|
|
1264
1395
|
return null;
|
|
1265
|
-
}, ts = (s) => typeof s == "object" && s !== null && "value" in s && "label" in s,
|
|
1266
|
-
const
|
|
1267
|
-
l.value ?
|
|
1396
|
+
}, ts = (s) => typeof s == "object" && s !== null && "value" in s && "label" in s, Ss = (s, e, l, t) => {
|
|
1397
|
+
const o = x([]), a = x(), r = (b) => {
|
|
1398
|
+
l.value ? a.value = b.map(({ value: T }) => T) : a.value = b.length > 0 ? b[0].value : null;
|
|
1268
1399
|
}, f = (b) => {
|
|
1269
|
-
l.value ?
|
|
1270
|
-
},
|
|
1271
|
-
|
|
1400
|
+
l.value ? a.value = b.map(({ value: T, label: _ }) => ({ value: T, label: _ })) : a.value = b.length > 0 ? { value: b[0].value, label: b[0].label } : null;
|
|
1401
|
+
}, A = (b) => {
|
|
1402
|
+
o.value = b, t != null && t.value ? f(b) : r(b);
|
|
1272
1403
|
}, d = () => {
|
|
1273
|
-
|
|
1404
|
+
o.value = [], a.value = null;
|
|
1274
1405
|
};
|
|
1275
|
-
return
|
|
1406
|
+
return X(
|
|
1276
1407
|
() => e.value,
|
|
1277
1408
|
() => {
|
|
1278
1409
|
if (!e.value && e.value !== 0) {
|
|
1279
1410
|
d();
|
|
1280
1411
|
return;
|
|
1281
1412
|
}
|
|
1282
|
-
const b = !Array.isArray(e.value), T = [...
|
|
1413
|
+
const b = !Array.isArray(e.value), T = [...o.value];
|
|
1283
1414
|
d();
|
|
1284
|
-
const
|
|
1415
|
+
const _ = (p) => {
|
|
1285
1416
|
if (ts(p))
|
|
1286
|
-
|
|
1417
|
+
o.value.push(p);
|
|
1287
1418
|
else {
|
|
1288
|
-
let
|
|
1289
|
-
|
|
1419
|
+
let C = te(s.value, p);
|
|
1420
|
+
C || (C = te(T, p)), C || (C = { value: p, label: p.toString() }), o.value.push(C);
|
|
1290
1421
|
}
|
|
1291
1422
|
};
|
|
1292
1423
|
if (b) {
|
|
1293
1424
|
const p = e.value;
|
|
1294
|
-
|
|
1425
|
+
_(p), t != null && t.value ? f(o.value) : r(o.value);
|
|
1295
1426
|
return;
|
|
1296
1427
|
}
|
|
1297
|
-
e.value.forEach(
|
|
1428
|
+
e.value.forEach(_), t != null && t.value ? f(o.value) : r(o.value);
|
|
1298
1429
|
},
|
|
1299
1430
|
{ immediate: !0 }
|
|
1300
1431
|
), {
|
|
1301
1432
|
// Values
|
|
1302
|
-
cachedSelectedListboxOptions:
|
|
1303
|
-
cachedListboxSelectedValues:
|
|
1433
|
+
cachedSelectedListboxOptions: o,
|
|
1434
|
+
cachedListboxSelectedValues: a,
|
|
1304
1435
|
// Methods
|
|
1305
1436
|
resetCache: d,
|
|
1306
|
-
setCachedValues:
|
|
1437
|
+
setCachedValues: A
|
|
1307
1438
|
};
|
|
1308
1439
|
};
|
|
1309
1440
|
export {
|
|
1310
1441
|
c as B,
|
|
1311
1442
|
ut as C,
|
|
1312
|
-
|
|
1443
|
+
oe as D,
|
|
1313
1444
|
K as a,
|
|
1314
1445
|
hs as b,
|
|
1315
|
-
|
|
1446
|
+
zt as c,
|
|
1316
1447
|
he as d,
|
|
1317
|
-
|
|
1448
|
+
Ss as u
|
|
1318
1449
|
};
|
|
1319
|
-
//# sourceMappingURL=use-cached-selected-values.
|
|
1450
|
+
//# sourceMappingURL=use-cached-selected-values.Bn3Y8Iuq.js.map
|