@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,89 +0,0 @@
|
|
|
1
|
-
import { defineComponent as h, provide as _, toRef as b, useAttrs as v, ref as u, watch as C } from "vue";
|
|
2
|
-
import { d as y } from "./debounce.DUTu11PS.js";
|
|
3
|
-
import { u as I } from "./index.B6WW_F-J.js";
|
|
4
|
-
import { I as S } from "./dropdown.Ct7uhPr6.js";
|
|
5
|
-
import { B as k } from "./input-field.m1PMwa4C.js";
|
|
6
|
-
import { S as T } from "./search.D53Ia3rC.js";
|
|
7
|
-
import { C as E } from "./cross-circle-fill.DTDtgLMf.js";
|
|
8
|
-
import { n as A } from "./_plugin-vue2_normalizer.CeySl7Fu.js";
|
|
9
|
-
import "../assets/search-bar.css";
|
|
10
|
-
var i = /* @__PURE__ */ ((r) => (r.CLEAR = "clear", r.ESCAPE = "escape-pressed", r.INPUT = "input", r.UPDATE = "update:search-term", r))(i || {}), F = /* @__PURE__ */ ((r) => (r.CLEAR = "search-clear", r.INPUT = "search-input", r.UPDATE = "update:search-term", r))(F || {});
|
|
11
|
-
const P = {
|
|
12
|
-
"en-US": { clearSearch: "Clear search", search: "Search" },
|
|
13
|
-
"ja-JP": { clearSearch: "検索をクリア", search: "検索" },
|
|
14
|
-
"pt-BR": { clearSearch: "Limpar busca", search: "Buscar" }
|
|
15
|
-
}, x = {
|
|
16
|
-
i18n: { messages: P }
|
|
17
|
-
}, L = /* @__PURE__ */ h({
|
|
18
|
-
...x,
|
|
19
|
-
__name: "search-bar",
|
|
20
|
-
props: {
|
|
21
|
-
inputFieldAriaLabel: null,
|
|
22
|
-
condensed: { type: Boolean, default: !1 },
|
|
23
|
-
debounceTime: { default: 300 },
|
|
24
|
-
disabled: { type: Boolean, default: !1 },
|
|
25
|
-
hint: { default: "" },
|
|
26
|
-
placeholder: { default: "" },
|
|
27
|
-
value: { default: void 0 }
|
|
28
|
-
},
|
|
29
|
-
emits: ["input", "clear", "escape-pressed", "blur", "focus"],
|
|
30
|
-
setup(r, { expose: a, emit: n }) {
|
|
31
|
-
const e = r, { t } = I();
|
|
32
|
-
_(S, b(e, "hint"));
|
|
33
|
-
const p = v(), s = u(e.value), c = u();
|
|
34
|
-
C(
|
|
35
|
-
() => e.value,
|
|
36
|
-
() => {
|
|
37
|
-
s.value = e.value;
|
|
38
|
-
},
|
|
39
|
-
{ immediate: !0 }
|
|
40
|
-
);
|
|
41
|
-
const d = () => {
|
|
42
|
-
s.value = "", n("clear"), n("input", "");
|
|
43
|
-
}, o = y(() => {
|
|
44
|
-
n("input", s.value);
|
|
45
|
-
}, e.debounceTime), f = (m) => {
|
|
46
|
-
s.value = m, o();
|
|
47
|
-
}, l = () => {
|
|
48
|
-
c.value.focusInput();
|
|
49
|
-
};
|
|
50
|
-
return a({
|
|
51
|
-
/**
|
|
52
|
-
* Focus on the input field when called.
|
|
53
|
-
*/
|
|
54
|
-
focus: l
|
|
55
|
-
}), { __sfc: !0, t, props: e, emit: n, attrs: p, searchTerm: s, bentoInputField: c, onClearSearch: d, debouncedEmit: o, onInputEvent: f, focus: l, BentoSearchBarInternalEvent: i, BentoInputField: k, SearchIcon: T, CrossCircleFillIcon: E };
|
|
56
|
-
}
|
|
57
|
-
});
|
|
58
|
-
var N = function() {
|
|
59
|
-
var a = this, n = a._self._c, e = a._self._setupProxy;
|
|
60
|
-
return n("div", { staticClass: "b-search-bar" }, [n(e.BentoInputField, a._b({ ref: "bentoInputField", attrs: { "model-value": e.searchTerm, type: "search", condensed: a.condensed, "aria-label": a.inputFieldAriaLabel, "aria-hidden": !1, disabled: a.disabled, placeholder: a.placeholder }, on: { "update:model-value": e.onInputEvent, focus: function(t) {
|
|
61
|
-
return e.emit("focus");
|
|
62
|
-
}, blur: function(t) {
|
|
63
|
-
return e.emit("blur");
|
|
64
|
-
}, "escape-pressed": function(t) {
|
|
65
|
-
return e.emit(e.BentoSearchBarInternalEvent.ESCAPE);
|
|
66
|
-
} }, scopedSlots: a._u([{ key: "iconBefore", fn: function() {
|
|
67
|
-
return [n(e.SearchIcon, { attrs: { "svg-title": e.t("search"), "aria-hidden": "true" } })];
|
|
68
|
-
}, proxy: !0 }, e.searchTerm ? { key: "iconAfter", fn: function() {
|
|
69
|
-
return [n("div", { staticClass: "b-search-bar__clear-search", attrs: { tabindex: "0", "data-testid": "b-search-bar-clear-search-button" }, on: { click: e.onClearSearch, keypress: function(t) {
|
|
70
|
-
return !t.type.indexOf("key") && a._k(t.keyCode, "enter", 13, t.key, "Enter") ? null : e.onClearSearch.apply(null, arguments);
|
|
71
|
-
}, keyup: function(t) {
|
|
72
|
-
return !t.type.indexOf("key") && a._k(t.keyCode, "space", 32, t.key, [" ", "Spacebar"]) ? null : e.onClearSearch.apply(null, arguments);
|
|
73
|
-
} } }, [n(e.CrossCircleFillIcon, { attrs: { "svg-title": e.t("clearSearch") } })], 1)];
|
|
74
|
-
}, proxy: !0 } : null], null, !0) }, "bento-input-field", e.attrs, !1))], 1);
|
|
75
|
-
}, U = [], g = /* @__PURE__ */ A(
|
|
76
|
-
L,
|
|
77
|
-
N,
|
|
78
|
-
U,
|
|
79
|
-
!1,
|
|
80
|
-
null,
|
|
81
|
-
"e7a2bf17"
|
|
82
|
-
);
|
|
83
|
-
const H = g.exports;
|
|
84
|
-
export {
|
|
85
|
-
H as B,
|
|
86
|
-
F as a,
|
|
87
|
-
i as b
|
|
88
|
-
};
|
|
89
|
-
//# sourceMappingURL=search-bar.DPjYDhja.js.map
|
|
@@ -1,112 +0,0 @@
|
|
|
1
|
-
import { defineComponent as v, inject as g, computed as r, ref as C, readonly as I, watch as h, provide as w } from "vue";
|
|
2
|
-
import { B as S } from "./dropdown.Ct7uhPr6.js";
|
|
3
|
-
import { j as k } from "./index.CwzYJHw2.js";
|
|
4
|
-
import { u as A } from "./index.B6WW_F-J.js";
|
|
5
|
-
import { a as B } from "./es6.C1DXQV6f.js";
|
|
6
|
-
import { B as b } from "./typography.C8lPlsbD.js";
|
|
7
|
-
import { n as p } from "./_plugin-vue2_normalizer.CeySl7Fu.js";
|
|
8
|
-
import "../assets/secondary-nav.css";
|
|
9
|
-
const f = /* @__PURE__ */ Symbol("secondary nav state"), $ = {}, N = /* @__PURE__ */ v({
|
|
10
|
-
...$,
|
|
11
|
-
__name: "secondary-nav-item",
|
|
12
|
-
props: {
|
|
13
|
-
label: null,
|
|
14
|
-
value: null
|
|
15
|
-
},
|
|
16
|
-
emits: ["click"],
|
|
17
|
-
setup(o, { emit: e }) {
|
|
18
|
-
const a = o, { activeItemValue: t, updateActiveItemValue: s } = g(f), l = r(() => t.value === a.value), _ = r(() => ({
|
|
19
|
-
"b-secondary-nav-item--active": l.value
|
|
20
|
-
}));
|
|
21
|
-
return { __sfc: !0, activeItemValue: t, updateActiveItemValue: s, props: a, isItemSelected: l, conditionalClasses: _, emit: e, onClick: (c) => {
|
|
22
|
-
e("click", c), s(a.value);
|
|
23
|
-
}, BentoTypography: b };
|
|
24
|
-
}
|
|
25
|
-
});
|
|
26
|
-
var V = function() {
|
|
27
|
-
var e = this, a = e._self._c, t = e._self._setupProxy;
|
|
28
|
-
return a("button", { staticClass: "b-secondary-nav-item", class: t.conditionalClasses, attrs: { "aria-current": t.isItemSelected ? "page" : void 0 }, on: { click: t.onClick } }, [a(t.BentoTypography, { staticClass: "b-secondary-nav-item__title", attrs: { variant: "body", stronger: "" } }, [e._v(" " + e._s(e.label) + " ")])], 1);
|
|
29
|
-
}, x = [], D = /* @__PURE__ */ p(
|
|
30
|
-
N,
|
|
31
|
-
V,
|
|
32
|
-
x,
|
|
33
|
-
!1,
|
|
34
|
-
null,
|
|
35
|
-
"2ddb108a"
|
|
36
|
-
);
|
|
37
|
-
const y = D.exports, M = {}, R = /* @__PURE__ */ v({
|
|
38
|
-
...M,
|
|
39
|
-
__name: "secondary-nav-category",
|
|
40
|
-
props: {
|
|
41
|
-
label: null,
|
|
42
|
-
items: null
|
|
43
|
-
},
|
|
44
|
-
setup(o) {
|
|
45
|
-
return { __sfc: !0, BentoTypography: b, SecondaryNavItem: y };
|
|
46
|
-
}
|
|
47
|
-
});
|
|
48
|
-
var T = function() {
|
|
49
|
-
var e = this, a = e._self._c, t = e._self._setupProxy;
|
|
50
|
-
return a("section", { staticClass: "b-secondary-nav-category", attrs: { "aria-label": e.label } }, [a(t.BentoTypography, { staticClass: "b-secondary-nav-category__label", attrs: { el: "h1", variant: "caption", stronger: "" } }, [e._v(e._s(e.label))]), a("ul", { staticClass: "b-secondary-nav__list" }, e._l(e.items, function(s) {
|
|
51
|
-
return a("li", { key: s.value }, [a(t.SecondaryNavItem, { attrs: { label: s.label, value: s.value } })], 1);
|
|
52
|
-
}), 0)], 1);
|
|
53
|
-
}, j = [], F = /* @__PURE__ */ p(
|
|
54
|
-
R,
|
|
55
|
-
T,
|
|
56
|
-
j,
|
|
57
|
-
!1,
|
|
58
|
-
null,
|
|
59
|
-
"a7c2cab3"
|
|
60
|
-
);
|
|
61
|
-
const L = F.exports, O = {
|
|
62
|
-
"en-US": { mobileDropdownAriaLabel: "Navigation options dropdown" },
|
|
63
|
-
"ja-JP": { mobileDropdownAriaLabel: "ナビゲーションオプションのドロップダウン" },
|
|
64
|
-
"pt-BR": { mobileDropdownAriaLabel: "Menu suspenso de opções de navegação" }
|
|
65
|
-
}, P = {
|
|
66
|
-
i18n: { messages: O }
|
|
67
|
-
}, E = /* @__PURE__ */ v({
|
|
68
|
-
...P,
|
|
69
|
-
__name: "secondary-nav",
|
|
70
|
-
props: {
|
|
71
|
-
items: null,
|
|
72
|
-
value: null
|
|
73
|
-
},
|
|
74
|
-
emits: ["change"],
|
|
75
|
-
setup(o, { emit: e }) {
|
|
76
|
-
const a = o, { t } = A(), s = k({
|
|
77
|
-
s: B
|
|
78
|
-
}), l = s.smallerOrEqual("s"), _ = r(() => a.items.some((n) => Object.hasOwn(n, "items"))), u = r(() => a.items), c = r(() => {
|
|
79
|
-
const n = u.value[0];
|
|
80
|
-
return "items" in n ? n.items[0].value : n.value;
|
|
81
|
-
}), i = C(a.value ?? c.value), m = (n) => {
|
|
82
|
-
i.value = n, e("change", n);
|
|
83
|
-
}, d = {
|
|
84
|
-
activeItemValue: I(i),
|
|
85
|
-
updateActiveItemValue: m
|
|
86
|
-
};
|
|
87
|
-
return h(
|
|
88
|
-
() => a.value,
|
|
89
|
-
(n) => {
|
|
90
|
-
i.value = n;
|
|
91
|
-
}
|
|
92
|
-
), w(f, d), { __sfc: !0, t, breakpoints: s, isMobile: l, props: a, emit: e, hasCategories: _, dropdownItems: u, activeItemValueFallback: c, activeItemValue: i, updateActiveItemValue: m, state: d, SecondaryNavItem: y, SecondaryNavCategory: L, BentoDropdown: S };
|
|
93
|
-
}
|
|
94
|
-
});
|
|
95
|
-
var q = function() {
|
|
96
|
-
var e = this, a = e._self._c, t = e._self._setupProxy;
|
|
97
|
-
return a("nav", { staticClass: "b-secondary-nav" }, [t.isMobile ? a(t.BentoDropdown, { attrs: { "aria-label": t.t("mobileDropdownAriaLabel"), items: t.dropdownItems, "static-categories": t.hasCategories, "model-value": t.activeItemValue }, on: { "update:model-value": t.updateActiveItemValue } }) : a("ul", { staticClass: "b-secondary-nav__list" }, e._l(e.items, function(s) {
|
|
98
|
-
return a("li", { key: s.label }, ["items" in s ? a(t.SecondaryNavCategory, { attrs: { label: s.label, items: s.items } }) : a(t.SecondaryNavItem, { attrs: { label: s.label, value: s.value } })], 1);
|
|
99
|
-
}), 0)], 1);
|
|
100
|
-
}, z = [], J = /* @__PURE__ */ p(
|
|
101
|
-
E,
|
|
102
|
-
q,
|
|
103
|
-
z,
|
|
104
|
-
!1,
|
|
105
|
-
null,
|
|
106
|
-
"8517eb6e"
|
|
107
|
-
);
|
|
108
|
-
const X = J.exports;
|
|
109
|
-
export {
|
|
110
|
-
X as s
|
|
111
|
-
};
|
|
112
|
-
//# sourceMappingURL=secondary-nav.CwJjkJkj.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"secondary-nav.CwJjkJkj.js","sources":["../../src/components/secondary-nav/secondary-nav.keys.ts","../../src/components/secondary-nav/components/secondary-nav-item/secondary-nav-item.vue","../../src/components/secondary-nav/components/secondary-nav-category/secondary-nav-category.vue","../../src/components/secondary-nav/secondary-nav.vue"],"sourcesContent":["import { type InjectionKey } from 'vue';\nimport { type BentoSecondaryNavState } from './secondary-nav.types';\n\nexport const SECONDARY_NAV_STATE = Symbol('secondary nav state') as InjectionKey<BentoSecondaryNavState>;\n","<template>\n <button\n class=\"b-secondary-nav-item\"\n :class=\"conditionalClasses\"\n :aria-current=\"isItemSelected ? 'page' : undefined\"\n @click=\"onClick\"\n >\n <bento-typography class=\"b-secondary-nav-item__title\" variant=\"body\" stronger>\n {{ label }}\n </bento-typography>\n </button>\n</template>\n\n<script lang=\"ts\" setup>\n import { SECONDARY_NAV_STATE } from '../../secondary-nav.keys';\n import { BentoTypography } from '@/components/typography';\n import { computed, inject } from 'vue';\n\n const { activeItemValue, updateActiveItemValue } = inject(SECONDARY_NAV_STATE);\n\n const props = defineProps({\n label: null,\n value: null\n});\n\n const isItemSelected = computed(() => activeItemValue.value === props.value);\n\n const conditionalClasses = computed(() => ({\n 'b-secondary-nav-item--active': isItemSelected.value,\n }));\n\n const emit = defineEmits([\"click\"]);\n\n const onClick = (e: MouseEvent) => {\n emit('click', e);\n updateActiveItemValue(props.value);\n };\n</script>\n\n<script lang=\"ts\">\n /**\n * This component shouldn't be used directly. It is internally used by {@see BentoSecondaryNav}\n */\n export default {};\n</script>\n\n<style lang=\"scss\" scoped src=\"./secondary-nav-item.scss\" />\n","<template>\n <section class=\"b-secondary-nav-category\" :aria-label=\"label\">\n <bento-typography el=\"h1\" class=\"b-secondary-nav-category__label\" variant=\"caption\" stronger>{{\n label\n }}</bento-typography>\n <ul class=\"b-secondary-nav__list\">\n <li v-for=\"item in items\" :key=\"item.value\">\n <secondary-nav-item :label=\"item.label\" :value=\"item.value\" />\n </li>\n </ul>\n </section>\n</template>\n\n<script lang=\"ts\" setup>\n import { BentoTypography } from '@/components/typography';\n import { SecondaryNavItem } from '../secondary-nav-item';\n import { type BentoSecondaryNavItemsItem } from '../../secondary-nav.types';\n\n defineProps({\n label: null,\n items: null\n});\n</script>\n\n<script lang=\"ts\">\n /**\n * This component shouldn't be used directly. It is internally used by {@see BentoSecondaryNav}\n */\n export default {};\n</script>\n\n<style lang=\"scss\" scoped src=\"./secondary-nav-category.scss\" />\n","<template>\n <nav class=\"b-secondary-nav\">\n <bento-dropdown\n v-if=\"isMobile\"\n :aria-label=\"t('mobileDropdownAriaLabel')\"\n :items=\"dropdownItems\"\n :static-categories=\"hasCategories\"\n :model-value=\"activeItemValue\"\n @update:model-value=\"updateActiveItemValue\"\n />\n <ul v-else class=\"b-secondary-nav__list\">\n <li v-for=\"item in items\" :key=\"item.label\">\n <secondary-nav-category v-if=\"'items' in item\" :label=\"item.label\" :items=\"item.items\" />\n <secondary-nav-item v-else :label=\"item.label\" :value=\"item.value\" />\n </li>\n </ul>\n </nav>\n</template>\n\n<script setup lang=\"ts\">\n import { computed, provide, readonly, ref, watch } from 'vue';\n import { SecondaryNavItem } from './components/secondary-nav-item';\n import { SecondaryNavCategory } from './components/secondary-nav-category';\n import { SECONDARY_NAV_STATE } from './secondary-nav.keys';\n import { type BentoSecondaryNavItems, type BentoSecondaryNavState } from './secondary-nav.types';\n import { BentoDropdown } from '@/components/dropdown';\n import { useBreakpoints } from '@vueuse/core';\n import { useI18n } from '@/utils/ts/i18n';\n import { type BentoListboxOptions } from '@/types/listbox';\n import { BMediaQuerySMax } from '@adyen/bento-design-tokens/dist/js/bento/es6';\n\n import messages from './messages.json';\n\n type MessageSchema = (typeof messages)['en-US'];\n\n const { t } = useI18n<{ message: MessageSchema }>({ messages });\n\n const breakpoints = useBreakpoints({\n s: BMediaQuerySMax,\n });\n\n const isMobile = breakpoints.smallerOrEqual('s');\n const props = defineProps({\n items: null,\n value: null\n});\n\n const emit = defineEmits([\"change\"]);\n\n const hasCategories = computed(() => props.items.some(item => Object.hasOwn(item, 'items')));\n const dropdownItems = computed(() => props.items as BentoListboxOptions);\n\n const activeItemValueFallback = computed(() => {\n const firstDropdownItem = (dropdownItems.value as BentoSecondaryNavItems)[0];\n\n if ('items' in firstDropdownItem) {\n return firstDropdownItem.items[0].value;\n } else {\n return firstDropdownItem.value;\n }\n });\n const activeItemValue = ref(props.value ?? activeItemValueFallback.value);\n const updateActiveItemValue = (value: string) => {\n activeItemValue.value = value;\n emit('change', value);\n };\n\n // The component's state is inject on `secondary-nav-item` to determine the\n // current active item and to change its value\n const state: BentoSecondaryNavState = {\n activeItemValue: readonly(activeItemValue),\n updateActiveItemValue,\n };\n\n watch(\n () => props.value,\n value => {\n activeItemValue.value = value;\n }\n );\n\n provide(SECONDARY_NAV_STATE, state);\n</script>\n\n<script lang=\"ts\">\n /**\n * Secondary Nav offers users a structured way to access information.\n * It also provides a clear hierarchy for users to understand and navigate through various information.\n *\n * @example\n * import { BentoSecondaryNav } from '@adyen/bento-vue2';\n *\n * export default {\n * components: { BentoSecondaryNav },\n * template: `\n * <bento-secondary-nav :value=\"value\" :items=\"items\" />\n * `,\n * setup() {\n * const value = ref(2) // Active item value\n * const items: BentoSecondaryNavItemInfo[] = [\n * { label: 'Option 1', value: 1 },\n * { label: 'Option 2', value: 2 },\n * ];\n * return { items, value };\n * }\n * }\n */\n export default {\n i18n: { messages },\n };\n</script>\n\n<style lang=\"scss\" scoped src=\"./secondary-nav.scss\" />\n"],"names":["SECONDARY_NAV_STATE","__default__$2","activeItemValue","updateActiveItemValue","inject","isItemSelected","computed","props","conditionalClasses","e","emit","__default__$1","__default__","messages","useI18n","breakpoints","useBreakpoints","BMediaQuerySMax","isMobile","hasCategories","item","dropdownItems","activeItemValueFallback","firstDropdownItem","ref","value","state","readonly","watch","provide"],"mappings":";;;;;;;;AAGO,MAAAA,IAAA,uBAAA,qBAAA,GCwCHC,IAAA,CAAA;;;;;;;;;iBAzBA,EAAA,iBAAAC,GAAA,uBAAAC,EAAA,IAAAC,EAAAJ,CAAA,GAOAK,IAAAC,EAAA,MAAAJ,EAAA,UAAAK,EAAA,KAAA,GAEAC,IAAAF,EAAA,OAAA;AAAA,MAA2C,gCAAAD,EAAA;AAAA,IACQ,EAAA;4IAKnD,CAAAI,MAAA;AACI,MAAAC,EAAA,SAAAD,CAAA,GACAN,EAAAI,EAAA,KAAA;AAAA,IAAiC;;;;;;;;;;;;;;qBCPrCI,IAAA,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;GC+EAC,IAAA;AAAA,EAAe,MAAA,EAAA,UAAAC,EAAA;AAEf;;;;;;;;;iBA1EA,EAAA,EAAA,IAAAC,EAAA,GAEAC,IAAAC,EAAA;AAAA,MAAmC,GAAAC;AAAA,IAC5B,CAAA,GAGPC,IAAAH,EAAA,eAAA,GAAA,GAQAI,IAAAb,EAAA,MAAAC,EAAA,MAAA,KAAA,CAAAa,MAAA,OAAA,OAAAA,GAAA,OAAA,CAAA,CAAA,GACAC,IAAAf,EAAA,MAAAC,EAAA,KAAA,GAEAe,IAAAhB,EAAA,MAAA;AACI,YAAAiB,IAAAF,EAAA,MAAA,CAAA;AAEA,aAAA,WAAAE,IACIA,EAAA,MAAA,CAAA,EAAA,QAEAA,EAAA;AAAA,IACJ,CAAA,GAEJrB,IAAAsB,EAAAjB,EAAA,SAAAe,EAAA,KAAA,GACAnB,IAAA,CAAAsB,MAAA;AACI,MAAAvB,EAAA,QAAAuB,GACAf,EAAA,UAAAe,CAAA;AAAA,IAAoB,GAKxBC,IAAA;AAAA,MAAsC,iBAAAC,EAAAzB,CAAA;AAAA,MACO,uBAAAC;AAAA,IACzC;AAGJ,WAAAyB;AAAA,MAAA,MAAArB,EAAA;AAAA,MACgB,CAAAkB,MAAA;AAER,QAAAvB,EAAA,QAAAuB;AAAA,MAAwB;AAAA,IAC5B,GAGJI,EAAA7B,GAAA0B,CAAA;;;;;;;;;;;;;;;;;"}
|
|
@@ -1,169 +0,0 @@
|
|
|
1
|
-
import { defineComponent as se, useAttrs as ne, toRefs as w, ref as u, toRef as ie, computed as i, watch as I, nextTick as ue, onMounted as ce, onUnmounted as de } from "vue";
|
|
2
|
-
import { B as pe } from "./button.DxhJNOtr.js";
|
|
3
|
-
import { d as fe, B as me } from "./typography.C8lPlsbD.js";
|
|
4
|
-
import { C as be } from "./cross-circle-fill-small.DfxDedRr.js";
|
|
5
|
-
import { g as _e } from "./generate-uid.NJ8tVoha.js";
|
|
6
|
-
import { o as T } from "./resize.Bqks3WUm.js";
|
|
7
|
-
import { u as he } from "./aria-label.CaUURpnB.js";
|
|
8
|
-
import { u as ve } from "./index.B6WW_F-J.js";
|
|
9
|
-
import { u as ye } from "./form-field.D_2g7vaP.js";
|
|
10
|
-
import { u as ge } from "./use-form-layout-loading.CWbjZiwP.js";
|
|
11
|
-
import { B as xe } from "./es6.C1DXQV6f.js";
|
|
12
|
-
import { F as Ce, E as Le } from "./error-message.RxdStT3S.js";
|
|
13
|
-
import { n as Ee } from "./_plugin-vue2_normalizer.CeySl7Fu.js";
|
|
14
|
-
import "../assets/textarea.css";
|
|
15
|
-
var p = /* @__PURE__ */ ((l) => (l.CLEARABLE = "clearable", l.DISABLED = "disabled", l.ERROR = "error", l.READONLY = "readonly", l))(p || {}), c = /* @__PURE__ */ ((l) => (l.BLUR = "blur", l.CHANGE = "change", l.CLEAR = "clear", l.ESCAPE_PRESSED = "escape-pressed", l.FOCUS = "focus", l.INPUT = "input", l.UPDATE_MODEL_VALUE = "update:model-value", l.KEYDOWN = "keydown", l.KEYUP = "keyup", l))(c || {});
|
|
16
|
-
const Re = {
|
|
17
|
-
"en-US": { clearText: "Clear text", textarea: "textarea", yourTextCanBenAtMost: "Your text can be at most {characterLimit} characters" }
|
|
18
|
-
}, H = parseFloat(xe), Ae = {
|
|
19
|
-
i18n: { messages: Re },
|
|
20
|
-
name: "bento-textarea",
|
|
21
|
-
model: { prop: "modelValue" }
|
|
22
|
-
}, Be = /* @__PURE__ */ se({
|
|
23
|
-
...Ae,
|
|
24
|
-
props: {
|
|
25
|
-
description: { default: "" },
|
|
26
|
-
disabled: { type: Boolean, default: !1 },
|
|
27
|
-
errorMessage: { default: "" },
|
|
28
|
-
label: { default: "" },
|
|
29
|
-
optional: { type: Boolean, default: !1 },
|
|
30
|
-
placeholder: { default: "" },
|
|
31
|
-
readonly: { type: Boolean, default: !1 },
|
|
32
|
-
required: { type: Boolean, default: !1 },
|
|
33
|
-
tooltipText: { default: null },
|
|
34
|
-
ariaLabel: { default: void 0 },
|
|
35
|
-
characterLimit: { default: void 0 },
|
|
36
|
-
clearable: { type: Boolean, default: !1 },
|
|
37
|
-
height: { default: null },
|
|
38
|
-
resizable: { default: "both" },
|
|
39
|
-
value: { default: "" },
|
|
40
|
-
modelValue: { default: "" }
|
|
41
|
-
},
|
|
42
|
-
emits: [],
|
|
43
|
-
setup(l, { expose: a, emit: t }) {
|
|
44
|
-
const e = l, o = ne(), { height: v } = w(e), W = _e("textarea"), s = u(null), f = u(null), n = u(e.modelValue || e.value), d = 44, m = u(e.height || `${d}px`), L = u(0), E = u("100%"), y = u(!1);
|
|
45
|
-
let b = null, _ = null;
|
|
46
|
-
const { t: D, n: R } = ve(), { isReadOnly: g } = ge(ie(e, "readonly")), { emitValue: A } = ye(t), K = i(() => {
|
|
47
|
-
var r;
|
|
48
|
-
return `${R(((r = n == null ? void 0 : n.value) == null ? void 0 : r.length) ?? 0)} / ${R(e.characterLimit)}`;
|
|
49
|
-
}), h = i(() => !v.value), B = i(
|
|
50
|
-
() => e.characterLimit && n.value.length > e.characterLimit
|
|
51
|
-
), x = () => {
|
|
52
|
-
if (s.value) {
|
|
53
|
-
const r = Math.max(
|
|
54
|
-
s.value.scrollHeight <= d ? d : s.value.scrollHeight + H * 2,
|
|
55
|
-
L.value,
|
|
56
|
-
d
|
|
57
|
-
);
|
|
58
|
-
m.value = `${r}px`;
|
|
59
|
-
}
|
|
60
|
-
};
|
|
61
|
-
I(v, () => {
|
|
62
|
-
h.value ? x() : m.value = v.value;
|
|
63
|
-
}), I(
|
|
64
|
-
() => [e.value, e.modelValue],
|
|
65
|
-
() => {
|
|
66
|
-
n.value = e.modelValue || e.value;
|
|
67
|
-
},
|
|
68
|
-
{ immediate: !0 }
|
|
69
|
-
), I(
|
|
70
|
-
() => n.value,
|
|
71
|
-
async () => {
|
|
72
|
-
if (h.value) {
|
|
73
|
-
if (m.value = `${d}px`, !n.value)
|
|
74
|
-
return;
|
|
75
|
-
await ue(), x();
|
|
76
|
-
}
|
|
77
|
-
},
|
|
78
|
-
{ immediate: !0 }
|
|
79
|
-
);
|
|
80
|
-
const U = i(() => !!e.errorMessage || B.value), q = i(() => ({
|
|
81
|
-
[`b-textarea--${p.DISABLED}`]: e.disabled
|
|
82
|
-
})), z = i(() => ({
|
|
83
|
-
[`b-textarea__input--${p.CLEARABLE}`]: e.clearable,
|
|
84
|
-
[`b-textarea__input--${p.READONLY}`]: g.value,
|
|
85
|
-
[`b-textarea__input--${p.ERROR}`]: U.value,
|
|
86
|
-
"b-textarea__input--dynamic-height": h.value
|
|
87
|
-
})), N = i(() => ({
|
|
88
|
-
"b-textarea__label-box--no-label": !e.label
|
|
89
|
-
})), V = i(() => ({
|
|
90
|
-
[`b-textarea__label-item--${p.ERROR}`]: B.value
|
|
91
|
-
})), Y = i(() => D("yourTextCanBenAtMost", { characterLimit: e.characterLimit })), O = u(o["aria-label"]), { ariaLabel: F, label: M } = w(e), $ = he({
|
|
92
|
-
ariaLabel: O.value,
|
|
93
|
-
// TODO: take this line away when the aria-label props is removed
|
|
94
|
-
label: F,
|
|
95
|
-
defaultFallback: M
|
|
96
|
-
}), G = i(
|
|
97
|
-
() => e.clearable && n.value && !e.disabled && !g.value
|
|
98
|
-
), X = () => {
|
|
99
|
-
n.value = "", t(c.CLEAR), A("");
|
|
100
|
-
}, j = (r) => {
|
|
101
|
-
r.stopImmediatePropagation(), !e.disabled && !g.value && (n.value = r.target.value, A(n.value));
|
|
102
|
-
}, J = () => {
|
|
103
|
-
s.value.scrollTop = 0, t(c.BLUR);
|
|
104
|
-
}, Q = () => {
|
|
105
|
-
s.value.focus(), t(c.FOCUS);
|
|
106
|
-
}, Z = () => {
|
|
107
|
-
t(c.CHANGE);
|
|
108
|
-
}, ee = () => {
|
|
109
|
-
t(c.ESCAPE_PRESSED);
|
|
110
|
-
}, ae = (r) => {
|
|
111
|
-
r.stopPropagation(), t(c.KEYDOWN, r);
|
|
112
|
-
}, te = (r) => {
|
|
113
|
-
r.stopPropagation(), t(c.KEYUP, r);
|
|
114
|
-
}, le = () => {
|
|
115
|
-
y.value = !0;
|
|
116
|
-
}, re = () => {
|
|
117
|
-
y.value = !1;
|
|
118
|
-
}, k = (r = !1) => {
|
|
119
|
-
var S;
|
|
120
|
-
const C = s.value.style.width;
|
|
121
|
-
if (s.value.style.height && (y.value && (L.value = parseInt(s.value.style.height, 10)), m.value = s.value.style.height), r && !C)
|
|
122
|
-
return;
|
|
123
|
-
const oe = (S = f == null ? void 0 : f.value) == null ? void 0 : S.offsetWidth;
|
|
124
|
-
!C || parseInt(C, 10) > oe ? E.value = "100%" : E.value = C;
|
|
125
|
-
}, P = () => {
|
|
126
|
-
s.value.focus();
|
|
127
|
-
};
|
|
128
|
-
return a({
|
|
129
|
-
focus: P
|
|
130
|
-
}), ce(() => {
|
|
131
|
-
b = T(s.value, () => {
|
|
132
|
-
k(!0);
|
|
133
|
-
}), _ = T(f.value, () => {
|
|
134
|
-
k();
|
|
135
|
-
}), h.value && x(), e.value && fe(
|
|
136
|
-
'BentoTextarea "value" property',
|
|
137
|
-
`The use of "value" prop in "BentoTextarea" is no longer supported.
|
|
138
|
-
Use the "v-model" or "model-value" property instead.`,
|
|
139
|
-
"2.0.0"
|
|
140
|
-
);
|
|
141
|
-
}), de(() => {
|
|
142
|
-
b == null || b.disconnect(), _ == null || _.disconnect();
|
|
143
|
-
}), { __sfc: !0, TEXTAREA_BORDER_WIDTH: H, attrs: o, props: e, emit: t, height: v, textareaId: W, textareaElement: s, textareaComponent: f, textareaValue: n, defaultTextareaHeight: d, textareaHeight: m, userSetHeight: L, textareaWrapperWidth: E, isUserResizing: y, textareaElementObserver: b, textareaComponentObserver: _, t: D, n: R, isReadOnly: g, emitValue: A, counter: K, isDynamicHeight: h, isOverCharacterLimit: B, calculateHeight: x, invalidInput: U, conditionalClasses: q, conditionalClassesInput: z, conditionalClassesLabelBox: N, conditionalClassesLabelItem: V, counterErrorText: Y, ariaLabelAttribute: O, ariaLabel: F, label: M, computedAriaLabel: $, showClearButton: G, onClear: X, onInput: j, onBlur: J, onFocus: Q, onChange: Z, onPressEscape: ee, onKeyDown: ae, onKeyUp: te, onMouseDown: le, onMouseUp: re, resizeTextareaWrapper: k, focus: P, BentoButton: pe, BentoTypography: me, ErrorMessage: Le, FieldLabel: Ce, CrossCircleFillSmallIcon: be };
|
|
144
|
-
}
|
|
145
|
-
});
|
|
146
|
-
var ke = function() {
|
|
147
|
-
var a = this, t = a._self._c, e = a._self._setupProxy;
|
|
148
|
-
return t("div", { ref: "textareaComponent", staticClass: "b-textarea", class: e.conditionalClasses }, [t("div", { style: { width: e.textareaWrapperWidth } }, [t("div", { staticClass: "b-textarea__label-box", class: e.conditionalClassesLabelBox }, [e.label ? t(e.FieldLabel, { attrs: { for: e.textareaId, label: e.label, "tooltip-text": a.tooltipText, optional: a.optional, required: a.required } }) : a._e(), a.characterLimit ? t(e.BentoTypography, { staticClass: "b-textarea__label-item", class: e.conditionalClassesLabelItem, attrs: { el: "span" } }, [a._v(" " + a._s(e.counter) + " ")]) : a._e()], 1), t(e.BentoTypography, { staticClass: "b-textarea__input-box", attrs: { el: "div", "aria-disabled": a.disabled } }, [t("textarea", { ref: "textareaElement", staticClass: "b-textarea__input", class: e.conditionalClassesInput, style: { resize: a.resizable, height: e.textareaHeight }, attrs: { id: e.textareaId, "aria-label": e.computedAriaLabel, "aria-invalid": e.invalidInput, readonly: e.isReadOnly, required: a.required, "aria-required": a.required, disabled: a.disabled, placeholder: a.placeholder }, domProps: { value: e.textareaValue }, on: { blur: e.onBlur, change: e.onChange, focus: e.onFocus, input: e.onInput, keydown: [function(o) {
|
|
149
|
-
return !o.type.indexOf("key") && a._k(o.keyCode, "esc", 27, o.key, ["Esc", "Escape"]) ? null : e.onPressEscape.apply(null, arguments);
|
|
150
|
-
}, e.onKeyDown], keyup: e.onKeyUp, mousedown: e.onMouseDown, mouseup: e.onMouseUp } }), e.showClearButton ? t("div", { staticClass: "b-textarea__clear-button" }, [t(e.BentoButton, { attrs: { variant: "tertiary", disabled: a.disabled }, on: { click: e.onClear, keypress: function(o) {
|
|
151
|
-
return !o.type.indexOf("key") && a._k(o.keyCode, "enter", 13, o.key, "Enter") ? null : e.onClear.apply(null, arguments);
|
|
152
|
-
}, keyup: function(o) {
|
|
153
|
-
return !o.type.indexOf("key") && a._k(o.keyCode, "space", 32, o.key, [" ", "Spacebar"]) ? null : e.onClear.apply(null, arguments);
|
|
154
|
-
} }, scopedSlots: a._u([{ key: "iconLeft", fn: function() {
|
|
155
|
-
return [t(e.CrossCircleFillSmallIcon, { attrs: { "svg-title": e.t("clearText") } })];
|
|
156
|
-
}, proxy: !0 }], null, !1, 3119266621) })], 1) : a._e()]), e.isOverCharacterLimit ? t(e.ErrorMessage, { attrs: { "error-message": e.counterErrorText } }) : a._e(), a.errorMessage ? t(e.ErrorMessage, { attrs: { "error-message": a.errorMessage } }) : a._e(), a.description ? t(e.BentoTypography, { staticClass: "b-textarea__description", attrs: { el: "span" } }, [a._v(" " + a._s(a.description) + " ")]) : a._e()], 1)]);
|
|
157
|
-
}, Ie = [], De = /* @__PURE__ */ Ee(
|
|
158
|
-
Be,
|
|
159
|
-
ke,
|
|
160
|
-
Ie,
|
|
161
|
-
!1,
|
|
162
|
-
null,
|
|
163
|
-
"a10ed22b"
|
|
164
|
-
);
|
|
165
|
-
const Ne = De.exports;
|
|
166
|
-
export {
|
|
167
|
-
Ne as B
|
|
168
|
-
};
|
|
169
|
-
//# sourceMappingURL=textarea.D4X6Ss9q.js.map
|
|
@@ -1,238 +0,0 @@
|
|
|
1
|
-
import { defineComponent as L, computed as o, ref as N, toRefs as G, watch as Q, provide as x, nextTick as X, useSlots as ee, inject as k, onUnmounted as te } from "vue";
|
|
2
|
-
import { B as H } from "./button.DxhJNOtr.js";
|
|
3
|
-
import { B as se } from "./textarea.D4X6Ss9q.js";
|
|
4
|
-
import { u as J } from "./index.B6WW_F-J.js";
|
|
5
|
-
import { B as ae } from "./button-actions.BLk114As.js";
|
|
6
|
-
import { n as R } from "./_plugin-vue2_normalizer.CeySl7Fu.js";
|
|
7
|
-
import { B as ie } from "./dashed-underline.pjYTS0m1.js";
|
|
8
|
-
import { B as ne } from "./date.B0m0sFP6.js";
|
|
9
|
-
import { B as oe } from "./link.MhoM3zQj.js";
|
|
10
|
-
import { B as le } from "./tag.CocLKztJ.js";
|
|
11
|
-
import { d as re, B as ce } from "./typography.C8lPlsbD.js";
|
|
12
|
-
import { S as me, a as de, B as ue } from "./structured-list-item.BDJKRC_8.js";
|
|
13
|
-
/* empty css */
|
|
14
|
-
import { g as _e } from "./generate-uid.NJ8tVoha.js";
|
|
15
|
-
import { u as fe } from "./use-has-slot.C9lQZ6nz.js";
|
|
16
|
-
import { j as ve, d as pe, n as he, k as $, o as U, p as F, q as Y, g as ge, r as j } from "./en-US.YeSsZuOc.js";
|
|
17
|
-
import { g as be } from "./getRoundingMethod.C3eaeGLR.js";
|
|
18
|
-
import "../assets/timeline-item.css";
|
|
19
|
-
function P(a, e, t) {
|
|
20
|
-
const s = ge(), r = (t == null ? void 0 : t.locale) ?? s.locale ?? ve, p = pe(a, e);
|
|
21
|
-
if (isNaN(p))
|
|
22
|
-
throw new RangeError("Invalid time value");
|
|
23
|
-
const c = Object.assign({}, t, {
|
|
24
|
-
addSuffix: t == null ? void 0 : t.addSuffix,
|
|
25
|
-
comparison: p
|
|
26
|
-
}), [y, b] = he(
|
|
27
|
-
t == null ? void 0 : t.in,
|
|
28
|
-
...p > 0 ? [e, a] : [a, e]
|
|
29
|
-
), d = be((t == null ? void 0 : t.roundingMethod) ?? "round"), f = b.getTime() - y.getTime(), m = f / j, T = $(b) - $(y), i = (f - T) / j, h = t == null ? void 0 : t.unit;
|
|
30
|
-
let l;
|
|
31
|
-
if (h ? l = h : m < 1 ? l = "second" : m < 60 ? l = "minute" : m < U ? l = "hour" : i < F ? l = "day" : i < Y ? l = "month" : l = "year", l === "second") {
|
|
32
|
-
const n = d(f / 1e3);
|
|
33
|
-
return r.formatDistance("xSeconds", n, c);
|
|
34
|
-
} else if (l === "minute") {
|
|
35
|
-
const n = d(m);
|
|
36
|
-
return r.formatDistance("xMinutes", n, c);
|
|
37
|
-
} else if (l === "hour") {
|
|
38
|
-
const n = d(m / 60);
|
|
39
|
-
return r.formatDistance("xHours", n, c);
|
|
40
|
-
} else if (l === "day") {
|
|
41
|
-
const n = d(i / U);
|
|
42
|
-
return r.formatDistance("xDays", n, c);
|
|
43
|
-
} else if (l === "month") {
|
|
44
|
-
const n = d(i / F);
|
|
45
|
-
return n === 12 && h !== "month" ? r.formatDistance("xYears", 1, c) : r.formatDistance("xMonths", n, c);
|
|
46
|
-
} else {
|
|
47
|
-
const n = d(i / Y);
|
|
48
|
-
return r.formatDistance("xYears", n, c);
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
|
-
var I = /* @__PURE__ */ ((a) => (a.BOTTOM = "bottom", a.AFTER_FIRST = "after-first", a.BEFORE_LAST = "before-last", a))(I || {}), ye = /* @__PURE__ */ ((a) => (a.SECOND = "second", a.MINUTE = "minute", a.HOUR = "hour", a.DAY = "day", a.MONTH = "month", a.YEAR = "year", a))(ye || {}), A = /* @__PURE__ */ ((a) => (a.DEFAULT = "SquareSmallIcon", a.SUCCESS = "CheckedCircleIcon", a.CRITICAL = "CrossCircleIcon", a))(A || {}), Te = /* @__PURE__ */ ((a) => (a.BLACK = "black", a.BLUE = "blue", a.GREEN = "green", a.GREY = "grey", a.ORANGE = "orange", a.RED = "red", a.YELLOW = "yellow", a))(Te || {});
|
|
52
|
-
const q = /* @__PURE__ */ Symbol("timeline register entry injection key"), K = /* @__PURE__ */ Symbol("timeline config obj injection key"), Ce = {
|
|
53
|
-
"en-US": { addNote: "Add note", cancel: "Cancel" },
|
|
54
|
-
"ja-JP": { addNote: "メモを追加", cancel: "キャンセル" },
|
|
55
|
-
"pt-BR": { addNote: "Adicionar anotação", cancel: "Cancelar" }
|
|
56
|
-
}, we = L({
|
|
57
|
-
i18n: { messages: Ce },
|
|
58
|
-
name: "bento-timeline"
|
|
59
|
-
}), Ne = /* @__PURE__ */ L({
|
|
60
|
-
...we,
|
|
61
|
-
props: {
|
|
62
|
-
addNote: { type: Boolean, default: !1 },
|
|
63
|
-
showMore: { default: null },
|
|
64
|
-
timegapLimit: { default: null }
|
|
65
|
-
},
|
|
66
|
-
emits: ["add-timeline-note"],
|
|
67
|
-
setup(a, { emit: e }) {
|
|
68
|
-
const t = a, { t: s } = J(), r = o(() => s("addNote")), p = o(() => s("cancel")), c = N(), y = (u) => {
|
|
69
|
-
c.value = u;
|
|
70
|
-
}, b = N(null), d = N(null), f = N(!1), m = async () => {
|
|
71
|
-
var u, g;
|
|
72
|
-
f.value = !f.value, await X(), f.value ? (u = b.value.$refs.textareaElement) == null || u.focus() : (g = d.value.$el) == null || g.focus();
|
|
73
|
-
}, T = () => {
|
|
74
|
-
e("add-timeline-note", {
|
|
75
|
-
description: c.value,
|
|
76
|
-
timestamp: { date: /* @__PURE__ */ new Date() },
|
|
77
|
-
type: "note"
|
|
78
|
-
}), m();
|
|
79
|
-
}, i = N([]), h = o(
|
|
80
|
-
() => t.showMore && i.value.length > t.showMore.limit ? i.value.length - t.showMore.limit : null
|
|
81
|
-
), l = N(!1), { timegapLimit: n } = G(t), _ = o(() => Array.from(i.value.keys())), v = o(() => t.showMore ? t.showMore.placement === I.BEFORE_LAST ? [
|
|
82
|
-
..._.value.slice(0, t.showMore.limit - 1),
|
|
83
|
-
_.value[_.value.length - 1]
|
|
84
|
-
] : t.showMore.placement === I.AFTER_FIRST ? [_.value[0], ..._.value.slice(-(t.showMore.limit - 1))] : _.value.slice(0, t.showMore.limit) : null), C = o(() => {
|
|
85
|
-
if (!t.showMore)
|
|
86
|
-
return null;
|
|
87
|
-
switch (t.showMore.placement) {
|
|
88
|
-
case I.BEFORE_LAST:
|
|
89
|
-
return t.showMore.limit - 2;
|
|
90
|
-
case I.AFTER_FIRST:
|
|
91
|
-
return 0;
|
|
92
|
-
case I.BOTTOM:
|
|
93
|
-
default:
|
|
94
|
-
return t.showMore.limit - 1;
|
|
95
|
-
}
|
|
96
|
-
}), E = () => {
|
|
97
|
-
i.value.sort((u, g) => new Date(g.date).getTime() - new Date(u.date).getTime());
|
|
98
|
-
}, B = (u) => () => {
|
|
99
|
-
const g = i.value.indexOf(u);
|
|
100
|
-
g > -1 && i.value.splice(g, 1);
|
|
101
|
-
}, S = (u) => (i.value.push(u), { timelineEntries: i, unregisterTimelineEntry: B(u) });
|
|
102
|
-
Q(
|
|
103
|
-
() => i.value.length,
|
|
104
|
-
() => E()
|
|
105
|
-
);
|
|
106
|
-
const w = {
|
|
107
|
-
showAll: l,
|
|
108
|
-
showMoreIndex: C,
|
|
109
|
-
hiddenItems: h,
|
|
110
|
-
visibleIndexes: v,
|
|
111
|
-
timegapLimit: n,
|
|
112
|
-
timelineEntries: i
|
|
113
|
-
};
|
|
114
|
-
return x(q, S), x(K, w), { __sfc: !0, props: t, emit: e, t: s, addNoteLabel: r, cancelLabel: p, newNoteContent: c, updateNoteContent: y, addNoteTextareaRef: b, addNoteButtonRef: d, showAddNoteTextArea: f, toggleAddNote: m, addNoteToTimeline: T, timelineEntries: i, hiddenItems: h, showAll: l, timegapLimit: n, timelineIndexes: _, visibleIndexes: v, showMoreIndex: C, sortEntries: E, unregisterTimelineEntry: B, registerTimelineEntry: S, configData: w, BentoButton: H, BentoButtonActions: ae, BentoTextarea: se };
|
|
115
|
-
}
|
|
116
|
-
});
|
|
117
|
-
var Ie = function() {
|
|
118
|
-
var e = this, t = e._self._c, s = e._self._setupProxy;
|
|
119
|
-
return t("div", { staticClass: "b-timeline" }, [e.addNote ? t("div", { staticClass: "b-timeline__add-note-section" }, [s.showAddNoteTextArea ? e._e() : t(s.BentoButton, { ref: "addNoteButtonRef", attrs: { variant: "tertiary" }, on: { click: s.toggleAddNote } }, [e._v(e._s(s.addNoteLabel))]), s.showAddNoteTextArea ? t("div", [t(s.BentoTextarea, { ref: "addNoteTextareaRef", attrs: { label: s.addNoteLabel, "character-limit": 150, resizable: "vertical" }, on: { "update:model-value": s.updateNoteContent } }), t(s.BentoButtonActions, { attrs: { actions: [
|
|
120
|
-
{ title: s.addNoteLabel, event: s.addNoteToTimeline },
|
|
121
|
-
{ title: s.cancelLabel, event: s.toggleAddNote }
|
|
122
|
-
] } })], 1) : e._e()], 1) : e._e(), t("ol", { staticClass: "b-timeline__items" }, [e._t("default")], 2)]);
|
|
123
|
-
}, Ee = [], Be = /* @__PURE__ */ R(
|
|
124
|
-
Ne,
|
|
125
|
-
Ie,
|
|
126
|
-
Ee,
|
|
127
|
-
!1,
|
|
128
|
-
null,
|
|
129
|
-
"4acaf49e"
|
|
130
|
-
);
|
|
131
|
-
const st = Be.exports;
|
|
132
|
-
let z = 0;
|
|
133
|
-
const Se = {
|
|
134
|
-
beforeCreate() {
|
|
135
|
-
this.uuid = z.toString(), z += 1;
|
|
136
|
-
}
|
|
137
|
-
};
|
|
138
|
-
var Le = function() {
|
|
139
|
-
var e = this, t = e._self._c;
|
|
140
|
-
return t("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"] ? t("title", [e._v(e._s(e.$attrs["svg-title"]))]) : e._e(), t("path", { attrs: { fill: "#001222", d: "M10 3.25C11.5188 3.25 12.75 4.48122 12.75 6V10C12.75 11.5188 11.5188 12.75 10 12.75H6C4.48122 12.75 3.25 11.5188 3.25 10V6C3.25 4.48122 4.48122 3.25 6 3.25H10Z" } })]);
|
|
141
|
-
}, Me = [], xe = /* @__PURE__ */ R(
|
|
142
|
-
Se,
|
|
143
|
-
Le,
|
|
144
|
-
Me,
|
|
145
|
-
!1,
|
|
146
|
-
null,
|
|
147
|
-
null
|
|
148
|
-
);
|
|
149
|
-
const Ae = xe.exports, Re = {
|
|
150
|
-
"en-US": { showLess: "Show less", showMore: "Show {items} more", timegap: "{timegap} passed between the timeline events" },
|
|
151
|
-
"ja-JP": { showLess: "表示内容を減らす" },
|
|
152
|
-
"pt-BR": { showLess: "Mostrar menos" }
|
|
153
|
-
}, De = L({
|
|
154
|
-
name: "bento-timeline-item",
|
|
155
|
-
i18n: { messages: Re }
|
|
156
|
-
}), Oe = /* @__PURE__ */ L({
|
|
157
|
-
...De,
|
|
158
|
-
props: {
|
|
159
|
-
additionalTimestamp: { default: null },
|
|
160
|
-
dataList: { default: null },
|
|
161
|
-
description: { default: null },
|
|
162
|
-
status: { default: "black" },
|
|
163
|
-
tag: { default: void 0 },
|
|
164
|
-
timestamp: null,
|
|
165
|
-
title: { default: null },
|
|
166
|
-
type: { default: "milestone" },
|
|
167
|
-
variant: { default: null }
|
|
168
|
-
},
|
|
169
|
-
setup(a) {
|
|
170
|
-
const e = a, { t } = J(), s = ee(), r = fe(s), p = o(() => e.type === "note"), c = o(() => e.variant === A.CRITICAL ? "red" : e.variant === A.SUCCESS ? "green" : e.status);
|
|
171
|
-
e.variant && re(
|
|
172
|
-
'BentoTimelineItem "variant" property',
|
|
173
|
-
`Use the BentoTimelineItem "status" modifier instead to modify the color of the timeline icon.
|
|
174
|
-
<bento-timeline-item status="red" />`,
|
|
175
|
-
"2.0.0"
|
|
176
|
-
);
|
|
177
|
-
const y = o(() => ({
|
|
178
|
-
[`b-timeline-item__icon--${c.value}`]: c.value && !p.value
|
|
179
|
-
})), b = o(() => ({
|
|
180
|
-
"b-timeline-item--note": p.value
|
|
181
|
-
}));
|
|
182
|
-
x(me, !0);
|
|
183
|
-
const d = {
|
|
184
|
-
title: e.title,
|
|
185
|
-
date: e.timestamp.date
|
|
186
|
-
}, f = k(q), { timelineEntries: m, unregisterTimelineEntry: T } = f(d);
|
|
187
|
-
te(() => T());
|
|
188
|
-
const { showAll: i, showMoreIndex: h, hiddenItems: l, visibleIndexes: n, timegapLimit: _ } = k(K), v = o(() => m.value.indexOf(d)), C = o(() => i.value || !n.value), E = o(() => C.value ? !0 : n.value.includes(v.value)), B = o(() => typeof e.title == "object"), S = o(() => e.title), w = o(() => {
|
|
189
|
-
var O;
|
|
190
|
-
if (!_.value)
|
|
191
|
-
return null;
|
|
192
|
-
const M = (O = m.value[v.value - 1]) == null ? void 0 : O.date, W = C.value || n.value.includes(v.value - 1);
|
|
193
|
-
if (!M || !W)
|
|
194
|
-
return null;
|
|
195
|
-
const { date: D } = m.value[v.value], Z = parseInt(
|
|
196
|
-
P(M, D, { unit: _.value.unit }),
|
|
197
|
-
10
|
|
198
|
-
);
|
|
199
|
-
return _.value.amount < Z ? P(M, D, { roundingMethod: "floor" }) : null;
|
|
200
|
-
}), u = o(() => w.value ? t("timegap", { timegap: w.value }) : ""), g = o(() => l.value && h.value === v.value), V = o(() => v.value !== -1 && v.value === m.value.length - 1);
|
|
201
|
-
return { __sfc: !0, props: e, t, slots: s, hasSlot: r, isNoteType: p, computedStatus: c, iconConditionalClasses: y, conditionalClasses: b, entry: d, registerTimelineEntry: f, timelineEntries: m, unregisterTimelineEntry: T, showAll: i, showMoreIndex: h, hiddenItems: l, visibleIndexes: n, timegapLimit: _, index: v, allItemsShowing: C, isVisible: E, isLinkTitle: B, linkTitleProps: S, timegap: w, timegapAriaLabel: u, displayShowMoreButton: g, isLastItem: V, BentoButton: H, BentoDashedUnderline: ie, BentoDate: ne, BentoLink: oe, BentoTag: le, BentoTypography: ce, BentoStructuredList: ue, BentoStructuredListItem: de, SquareSmallIcon: Ae, generateUid: _e };
|
|
202
|
-
}
|
|
203
|
-
});
|
|
204
|
-
var ke = function() {
|
|
205
|
-
var e = this, t = e._self._c, s = e._self._setupProxy;
|
|
206
|
-
return s.isVisible ? t("li", { staticClass: "b-timeline-item", class: s.conditionalClasses }, [s.timegap ? t("div", { staticClass: "b-timeline-item__row" }, [e._m(0), t("div", { staticClass: "b-timeline-item__content" }, [t(s.BentoTypography, { staticClass: "b-timeline-item__timegap", attrs: { "aria-label": s.timegapAriaLabel } }, [e._v(" " + e._s(s.timegap) + " ")])], 1)]) : e._e(), t("div", { staticClass: "b-timeline-item__row" }, [t("div", { staticClass: "b-timeline-item__marker", attrs: { "aria-hidden": "true" } }, [t(s.SquareSmallIcon, { staticClass: "b-timeline-item__icon", class: s.iconConditionalClasses }), s.isLastItem ? e._e() : t("div", { staticClass: "b-timeline-item__separator", attrs: { "data-testid": "last-timeline-item-separator" } })], 1), t("div", { staticClass: "b-timeline-item__content" }, [s.isNoteType ? e._e() : t(s.BentoTypography, { staticClass: "b-timeline-item__title", attrs: { el: "div", variant: "body", strongest: "", role: "heading", "aria-level": "2" } }, [s.isLinkTitle ? t(s.BentoLink, e._b({ attrs: { "disable-typography": "" } }, "bento-link", s.linkTitleProps, !1), [e._v(e._s(s.linkTitleProps.title))]) : t("span", [e._v(e._s(e.title))])], 1), s.isNoteType && (e.description || s.hasSlot("default")) ? t(s.BentoTypography, { staticClass: "b-timeline-item__description", attrs: { el: "div", variant: "body" } }, [e._t("default", function() {
|
|
207
|
-
return [e._v(e._s(e.description))];
|
|
208
|
-
})], 2) : e._e(), e.timestamp ? t(s.BentoTypography, { staticClass: "b-timeline-item__timestamp", attrs: { el: "div", variant: "caption" } }, [t(s.BentoDate, { attrs: { date: e.timestamp.date, format: e.timestamp.format, "disable-typography": "" } }), e.timestamp.description ? t(s.BentoDashedUnderline, e._b({}, "bento-dashed-underline", e.timestamp.description, !1), [e._v(" " + e._s(e.timestamp.value) + " ")]) : t("span", [e._v(e._s(e.timestamp.value))])], 1) : e._e(), !s.isNoteType && e.additionalTimestamp ? t(s.BentoTypography, { staticClass: "b-timeline-item__timestamp", attrs: { el: "div", variant: "caption" } }, [t(s.BentoDate, { attrs: { date: e.additionalTimestamp.date, format: e.additionalTimestamp.format, "disable-typography": "" } }), e.additionalTimestamp.description ? t(s.BentoDashedUnderline, e._b({}, "bento-dashed-underline", e.additionalTimestamp.description, !1), [e._v(" " + e._s(e.additionalTimestamp.value) + " ")]) : t("span", [e._v(" " + e._s(e.additionalTimestamp.value) + " ")])], 1) : e._e(), !s.isNoteType && (e.description || s.hasSlot("default")) ? t(s.BentoTypography, { staticClass: "b-timeline-item__description", attrs: { el: "div", variant: "body" } }, [e._t("default", function() {
|
|
209
|
-
return [e._v(e._s(e.description))];
|
|
210
|
-
})], 2) : e._e(), !s.isNoteType && e.dataList ? t("div", { staticClass: "b-timeline-item__data-list" }, [t(s.BentoStructuredList, e._l(e.dataList, function(r) {
|
|
211
|
-
return t(s.BentoStructuredListItem, { key: s.generateUid(r.label), attrs: { label: r.label } }, [t(s.BentoTypography, { attrs: { variant: "caption" } }, [e._v(e._s(r.value))])], 1);
|
|
212
|
-
}), 1)], 1) : e._e(), !s.isNoteType && e.tag ? t(s.BentoTag, e._b({ staticClass: "b-timeline-item__tag" }, "bento-tag", e.tag, !1)) : e._e()], 1)]), s.displayShowMoreButton ? t("div", { staticClass: "b-timeline-item__row" }, [e._m(1), t("div", { staticClass: "b-timeline-item__content" }, [t(s.BentoButton, { staticClass: "b-timeline__show-more", attrs: { variant: "tertiary" }, on: { click: function(r) {
|
|
213
|
-
s.showAll = !s.showAll;
|
|
214
|
-
} } }, [s.showAll ? [e._v(e._s(s.t("showLess")))] : [e._v(e._s(s.t("showMore", { items: s.hiddenItems })))]], 2)], 1)]) : e._e()]) : e._e();
|
|
215
|
-
}, $e = [function() {
|
|
216
|
-
var a = this, e = a._self._c;
|
|
217
|
-
return a._self._setupProxy, e("div", { staticClass: "b-timeline-item__marker", attrs: { "aria-hidden": "true" } }, [e("div", { staticClass: "b-timeline-item__icon b-timeline-item__icon--timegap" }), e("div", { staticClass: "b-timeline-item__separator" })]);
|
|
218
|
-
}, function() {
|
|
219
|
-
var a = this, e = a._self._c;
|
|
220
|
-
return a._self._setupProxy, e("div", { staticClass: "b-timeline-item__marker", attrs: { "aria-hidden": "true" } }, [e("div", { staticClass: "b-timeline-item__separator" })]);
|
|
221
|
-
}], Ue = /* @__PURE__ */ R(
|
|
222
|
-
Oe,
|
|
223
|
-
ke,
|
|
224
|
-
$e,
|
|
225
|
-
!1,
|
|
226
|
-
null,
|
|
227
|
-
"ee733813"
|
|
228
|
-
);
|
|
229
|
-
const at = Ue.exports;
|
|
230
|
-
export {
|
|
231
|
-
ye as B,
|
|
232
|
-
at as a,
|
|
233
|
-
A as b,
|
|
234
|
-
I as c,
|
|
235
|
-
Te as d,
|
|
236
|
-
st as t
|
|
237
|
-
};
|
|
238
|
-
//# sourceMappingURL=timeline-item.C8BxWdy1.js.map
|