@adyen/bento-vue3 1.3.0 → 1.4.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/@types/components.d.ts +8 -4
- package/dist/@types/packages/core/src/components/button/button.types.d.ts +8 -0
- package/dist/@types/packages/vue2/src/components/accordion/accordion.keys.d.ts +1 -1
- package/dist/@types/packages/vue2/src/components/accordion/accordion.types.d.ts +1 -24
- package/dist/@types/packages/vue2/src/components/accordion/accordion.vue.d.ts +17 -57
- package/dist/@types/packages/vue2/src/components/accordion/components/accordion-item.vue.d.ts +27 -29
- package/dist/@types/packages/vue2/src/components/accordion/index.d.ts +2 -3
- package/dist/@types/packages/vue2/src/components/alert/alert.vue.d.ts +0 -4
- package/dist/@types/packages/vue2/src/components/avatar-image/avatar-image.vue.d.ts +1 -4
- package/dist/@types/packages/vue2/src/components/button/button.vue.d.ts +136 -128
- package/dist/@types/packages/vue2/src/components/button/components/button-actions/button-actions.types.d.ts +3 -5
- package/dist/@types/packages/vue2/src/components/button/components/button-actions/button-actions.vue.d.ts +3 -3
- package/dist/@types/packages/vue2/src/components/button/components/loading-button/loading-button.vue.d.ts +2 -2
- package/dist/@types/packages/vue2/src/components/card/card.vue.d.ts +46 -15
- package/dist/@types/packages/vue2/src/components/checkbox/checkbox.types.d.ts +2 -1
- package/dist/@types/packages/vue2/src/components/checkbox/checkbox.vue.d.ts +6 -7
- package/dist/@types/packages/vue2/src/components/checkbox/components/checkbox-group/checkbox-group.vue.d.ts +4 -3
- package/dist/@types/packages/vue2/src/components/code-snippet/code-snippet.types.d.ts +2 -1
- package/dist/@types/packages/vue2/src/components/code-snippet/code-snippet.vue.d.ts +37 -11
- package/dist/@types/packages/vue2/src/components/country/country.vue.d.ts +0 -2
- package/dist/@types/packages/vue2/src/components/currency/currency.vue.d.ts +0 -3
- package/dist/@types/packages/vue2/src/components/data-grid/components/data-grid-columns/data-grid-columns.vue.d.ts +3 -22
- package/dist/@types/packages/vue2/src/components/data-grid/components/data-grid-config-settings/components/data-grid-config-settings-column-row/data-grid-config-settings-column-row.vue.d.ts +0 -5
- package/dist/@types/packages/vue2/src/components/data-grid/components/data-grid-config-settings/data-grid-config-settings.vue.d.ts +0 -24
- package/dist/@types/packages/vue2/src/components/data-grid/data-grid.types.d.ts +2 -0
- package/dist/@types/packages/vue2/src/components/data-grid/data-grid.vue.d.ts +277 -16
- package/dist/@types/packages/vue2/src/components/date/date.vue.d.ts +2 -5
- package/dist/@types/packages/vue2/src/components/date-picker/date-picker.vue.d.ts +0 -20
- package/dist/@types/packages/vue2/src/components/date-range-picker/components/date-range-picker-calendar/date-range-picker-calendar.vue.d.ts +0 -2
- package/dist/@types/packages/vue2/src/components/date-range-picker/date-range-picker.vue.d.ts +0 -20
- package/dist/@types/packages/vue2/src/components/dropdown/components/dropdown-base-textbox/dropdown-base-textbox.vue.d.ts +3 -6
- package/dist/@types/packages/vue2/src/components/dropdown/components/dropdown-default-textbox/dropdown-default-textbox.vue.d.ts +3 -3
- package/dist/@types/packages/vue2/src/components/dropdown/components/dropdown-options-container/dropdown-options-container.vue.d.ts +164 -104
- package/dist/@types/packages/vue2/src/components/dropdown/components/dropdown-small-textbox/dropdown-small-textbox.vue.d.ts +2 -2
- package/dist/@types/packages/vue2/src/components/dropdown/components/variants/dropdown-country/dropdown-country.types.d.ts +1 -1
- package/dist/@types/packages/vue2/src/components/dropdown/components/variants/dropdown-country/dropdown-country.vue.d.ts +0 -2
- package/dist/@types/packages/vue2/src/components/dropdown/components/variants/dropdown-currency/dropdown-currency.types.d.ts +1 -1
- package/dist/@types/packages/vue2/src/components/dropdown/components/variants/dropdown-payment-method/dropdown-payment-method.types.d.ts +1 -1
- package/dist/@types/packages/vue2/src/components/dropdown/components/variants/dropdown-tag/dropdown-tag.types.d.ts +1 -1
- package/dist/@types/packages/vue2/src/components/dropdown/dropdown.vue.d.ts +7 -9
- package/dist/@types/packages/vue2/src/components/empty-state/empty-state.types.d.ts +27 -0
- package/dist/@types/packages/vue2/src/components/empty-state/empty-state.vue.d.ts +76 -0
- package/dist/@types/packages/vue2/src/components/empty-state/index.d.ts +2 -0
- package/dist/@types/packages/vue2/src/components/filter-bar/components/all-filters-modal/all-filters-modal.vue.d.ts +19 -25
- package/dist/@types/packages/vue2/src/components/filter-bar/components/all-filters-modal/components/all-filters-modal-button/all-filters-modal-button.vue.d.ts +1 -1
- package/dist/@types/packages/vue2/src/components/filter-bar/components/base-filter/base-filter.vue.d.ts +1 -27
- package/dist/@types/packages/vue2/src/components/filter-bar/components/base-filter-button/base-filter-button.vue.d.ts +1 -4
- package/dist/@types/packages/vue2/src/components/filter-bar/components/date-filter/date-filter.vue.d.ts +1 -1
- package/dist/@types/packages/vue2/src/components/filter-bar/components/date-range-filter/date-range-filter.vue.d.ts +1 -11
- package/dist/@types/packages/vue2/src/components/filter-bar/components/filter-bar-button/filter-bar-button.vue.d.ts +53 -0
- package/dist/@types/packages/vue2/src/components/filter-bar/components/filter-bar-button/index.d.ts +1 -0
- package/dist/@types/packages/vue2/src/components/filter-bar/components/input-filter/input-filter.vue.d.ts +1 -0
- package/dist/@types/packages/vue2/src/components/filter-bar/components/range-filter/range-filter.vue.d.ts +0 -2
- package/dist/@types/packages/vue2/src/components/filter-bar/components/select-filter/select-filter.vue.d.ts +1 -1
- package/dist/@types/packages/vue2/src/components/filter-bar/components/select-filter/variants/select-country-filter/select-country-filter.vue.d.ts +0 -2
- package/dist/@types/packages/vue2/src/components/filter-bar/components/select-filter/variants/select-tag-filter/select-tag-filter.vue.d.ts +0 -2
- package/dist/@types/packages/vue2/src/components/filter-bar/filter-bar.vue.d.ts +0 -2
- package/dist/@types/packages/vue2/src/components/focus-trap/focus-trap.vue.d.ts +7 -0
- package/dist/@types/packages/vue2/src/components/header/header.vue.d.ts +0 -2
- package/dist/@types/packages/vue2/src/components/image/const.d.ts +1 -0
- package/dist/@types/packages/vue2/src/components/image/image.types.d.ts +19 -0
- package/dist/@types/packages/vue2/src/components/image/image.vue.d.ts +50 -0
- package/dist/@types/packages/vue2/src/components/image/index.d.ts +1 -0
- package/dist/@types/packages/vue2/src/components/info-icon/info-icon.vue.d.ts +3 -3
- package/dist/@types/packages/vue2/src/components/input-field/input-field.types.d.ts +1 -0
- package/dist/@types/packages/vue2/src/components/input-field/input-field.vue.d.ts +61 -58
- package/dist/@types/packages/vue2/src/components/internal/avatar/avatar.vue.d.ts +0 -3
- package/dist/@types/packages/vue2/src/components/internal/base-button/base-button.vue.d.ts +1 -4
- package/dist/@types/packages/vue2/src/components/internal/calendar/components/calendar-month/calendar-month.vue.d.ts +0 -5
- package/dist/@types/packages/vue2/src/components/internal/calendar/components/calendar-month/components/calendar-month-day/calendar-month-day.vue.d.ts +2 -2
- package/dist/@types/packages/vue2/src/components/internal/copy/copy.vue.d.ts +0 -2
- package/dist/@types/packages/vue2/src/components/internal/listbox/components/listbox-multi-select/components/listbox-multi-select-options/components/listbox-multi-select-category/listbox-multi-select-category.vue.d.ts +0 -2
- package/dist/@types/packages/vue2/src/components/internal/listbox/components/listbox-multi-select/components/listbox-multi-select-options/listbox-multi-select-options.vue.d.ts +0 -2
- package/dist/@types/packages/vue2/src/components/internal/listbox/components/listbox-multi-select/listbox-multi-select.vue.d.ts +0 -2
- package/dist/@types/packages/vue2/src/components/internal/listbox/components/listbox-option-tag/listbox-option-tag.vue.d.ts +0 -2
- package/dist/@types/packages/vue2/src/components/internal/listbox/components/listbox-single-select-option/listbox-single-select-option.vue.d.ts +0 -2
- package/dist/@types/packages/vue2/src/components/internal/listbox/listbox.vue.d.ts +3 -7
- package/dist/@types/packages/vue2/src/components/link/link.vue.d.ts +4 -0
- package/dist/@types/packages/vue2/src/components/menu/components/menu-item/menu-item.vue.d.ts +2 -5
- package/dist/@types/packages/vue2/src/components/menu/menu.vue.d.ts +6 -31
- package/dist/@types/packages/vue2/src/components/modal/components/base-modal/__mocks__/base-modal.vue.d.ts +0 -5
- package/dist/@types/packages/vue2/src/components/modal/components/base-modal/base-modal.vue.d.ts +14 -9
- package/dist/@types/packages/vue2/src/components/modal/components/modal-default/modal-default.vue.d.ts +2 -2
- package/dist/@types/packages/vue2/src/components/modal/components/modal-dialog/modal-dialog.vue.d.ts +4 -14
- package/dist/@types/packages/vue2/src/components/modal/modal.vue.d.ts +7 -6
- package/dist/@types/packages/vue2/src/components/pagination/components/pagination-context/pagination-context.vue.d.ts +0 -2
- package/dist/@types/packages/vue2/src/components/pagination/components/pagination-controls/pagination-controls.vue.d.ts +0 -2
- package/dist/@types/packages/vue2/src/components/pagination/components/pagination-results-per-page/pagination-results-per-page.vue.d.ts +0 -2
- package/dist/@types/packages/vue2/src/components/pagination/pagination.vue.d.ts +2 -1
- package/dist/@types/packages/vue2/src/components/payment-method/payment-method.vue.d.ts +0 -2
- package/dist/@types/packages/vue2/src/components/popover/components/popover-dismiss-button/popover-dismiss-button.vue.d.ts +0 -2
- package/dist/@types/packages/vue2/src/components/popover/components/popover-title/popover-title.vue.d.ts +1 -2
- package/dist/@types/packages/vue2/src/components/popover/popover.vue.d.ts +9 -9
- package/dist/@types/packages/vue2/src/components/popper-container/popper-container.vue.d.ts +5 -14
- package/dist/@types/packages/vue2/src/components/radio-group/components/radio-button/radio-button.vue.d.ts +4 -6
- package/dist/@types/packages/vue2/src/components/radio-group/radio-group.types.d.ts +2 -1
- package/dist/@types/packages/vue2/src/components/radio-group/radio-group.vue.d.ts +4 -3
- package/dist/@types/packages/vue2/src/components/search-bar/search-bar.vue.d.ts +19 -390
- package/dist/@types/packages/vue2/src/components/segmented-control/components/segmented-control-button/segmented-control-button.vue.d.ts +0 -3
- package/dist/@types/packages/vue2/src/components/segmented-control/segmented-control.vue.d.ts +1 -0
- package/dist/@types/packages/vue2/src/components/sidepanel/sidepanel.types.d.ts +3 -1
- package/dist/@types/packages/vue2/src/components/status/status.vue.d.ts +2 -5
- package/dist/@types/packages/vue2/src/components/structured-list/components/structered-list-item/structured-list-item.vue.d.ts +0 -2
- package/dist/@types/packages/vue2/src/components/summary-grid/components/summary-grid-item/summary-grid-item.vue.d.ts +2 -23
- package/dist/@types/packages/vue2/src/components/summary-grid/components/summary-grid-item-amount/summary-grid-item-amount.vue.d.ts +2 -5
- package/dist/@types/packages/vue2/src/components/summary-grid/components/summary-grid-item-numeric/summary-grid-item-numeric.vue.d.ts +2 -5
- package/dist/@types/packages/vue2/src/components/summary-grid/components/summary-grid-item-percentage/summary-grid-item-percentage.vue.d.ts +2 -5
- package/dist/@types/packages/vue2/src/components/summary-grid/components/summary-grid-item-text/summary-grid-item-text.vue.d.ts +1 -4
- package/dist/@types/packages/vue2/src/components/tabs/components/tab.types.d.ts +3 -1
- package/dist/@types/packages/vue2/src/components/tabs/components/tab.vue.d.ts +1 -0
- package/dist/@types/packages/vue2/src/components/tabs/tabs.keys.d.ts +1 -0
- package/dist/@types/packages/vue2/src/components/tabs/tabs.types.d.ts +6 -2
- package/dist/@types/packages/vue2/src/components/tabs/tabs.vue.d.ts +4 -9
- package/dist/@types/packages/vue2/src/components/tag/tag.vue.d.ts +6 -9
- package/dist/@types/packages/vue2/src/components/textarea/textarea.vue.d.ts +6 -10
- package/dist/@types/packages/vue2/src/components/timeline/components/timeline-item/timeline-item.vue.d.ts +4 -10
- package/dist/@types/packages/vue2/src/components/timeline/timeline.types.d.ts +1 -0
- package/dist/@types/packages/vue2/src/components/toast/components/toast-item/toast-item.vue.d.ts +0 -5
- package/dist/@types/packages/vue2/src/components/toggle/toggle.vue.d.ts +4 -6
- package/dist/@types/packages/vue2/src/components/tooltip/tooltip.vue.d.ts +24 -40
- package/dist/@types/packages/vue2/src/composables/use-default-slot-validator/use-default-slot-validator.d.ts +2 -1
- package/dist/@types/packages/vue2/src/composables/use-has-slot/use-has-slot.d.ts +8 -1
- package/dist/@types/packages/vue2/src/index.d.ts +3 -0
- package/dist/@types/packages/vue2/src/templates/data-grid-template/data-grid-template.vue.d.ts +9 -0
- package/dist/@types/packages/vue2/src/utils/ts/get-slot-text/get-slot-text.d.ts +1 -1
- package/dist/@types/packages/vue2/src/utils/ts/print-development-warning.d.ts +1 -0
- package/dist/accordion.js +104 -254
- package/dist/accordion.js.map +1 -1
- package/dist/alert.js +61 -64
- package/dist/alert.js.map +1 -1
- package/dist/assets/base-button.css +1 -1
- package/dist/assets/base-modal.css +1 -0
- package/dist/assets/button.css +1 -1
- package/dist/assets/calendar.css +1 -1
- package/dist/assets/checkbox.css +1 -1
- package/dist/assets/chevron-up.css +1 -0
- package/dist/assets/controls-group.css +1 -1
- package/dist/assets/copy.css +1 -1
- package/dist/assets/dropdown-default-textbox.css +1 -1
- package/dist/assets/dropdown.css +1 -1
- package/dist/assets/error-message.css +1 -1
- package/dist/assets/footer-actions.css +1 -1
- package/dist/assets/index.css +1 -1
- package/dist/assets/index10.css +1 -1
- package/dist/assets/index11.css +1 -1
- package/dist/assets/index12.css +1 -1
- package/dist/assets/index13.css +1 -1
- package/dist/assets/index14.css +1 -1
- package/dist/assets/index15.css +1 -1
- package/dist/assets/index16.css +1 -1
- package/dist/assets/index17.css +1 -1
- package/dist/assets/index18.css +1 -1
- package/dist/assets/index19.css +1 -1
- package/dist/assets/index2.css +1 -1
- package/dist/assets/index20.css +1 -1
- package/dist/assets/index21.css +1 -1
- package/dist/assets/index22.css +1 -1
- package/dist/assets/index24.css +1 -1
- package/dist/assets/index25.css +1 -1
- package/dist/assets/index26.css +1 -1
- package/dist/assets/index27.css +1 -1
- package/dist/assets/index28.css +1 -1
- package/dist/assets/index29.css +1 -1
- package/dist/assets/index3.css +1 -1
- package/dist/assets/index30.css +1 -1
- package/dist/assets/index31.css +1 -1
- package/dist/assets/index32.css +1 -1
- package/dist/assets/index33.css +1 -1
- package/dist/assets/index34.css +1 -1
- package/dist/assets/index35.css +1 -1
- package/dist/assets/index36.css +1 -1
- package/dist/assets/index37.css +1 -1
- package/dist/assets/index38.css +1 -1
- package/dist/assets/index39.css +1 -1
- package/dist/assets/index4.css +1 -1
- package/dist/assets/index40.css +1 -1
- package/dist/assets/index41.css +1 -1
- package/dist/assets/index42.css +1 -1
- package/dist/assets/index43.css +1 -0
- package/dist/assets/index5.css +1 -1
- package/dist/assets/index6.css +1 -1
- package/dist/assets/index7.css +1 -1
- package/dist/assets/index8.css +1 -1
- package/dist/assets/index9.css +1 -1
- package/dist/assets/listbox-option-tag.css +1 -1
- package/dist/assets/listbox.css +1 -1
- package/dist/assets/loading-button.css +1 -1
- package/dist/assets/tooltip.css +1 -1
- package/dist/avatar-image.js +1 -1
- package/dist/badge.js +2 -2
- package/dist/button.js +143 -12
- package/dist/button.js.map +1 -1
- package/dist/card.js +99 -94
- package/dist/card.js.map +1 -1
- package/dist/checkbox.js +40 -39
- package/dist/checkbox.js.map +1 -1
- package/dist/chunks/base-button.6d2843c2.js +108 -0
- package/dist/chunks/base-button.6d2843c2.js.map +1 -0
- package/dist/chunks/base-modal.3ccb9eb5.js +291 -0
- package/dist/chunks/base-modal.3ccb9eb5.js.map +1 -0
- package/dist/chunks/{button.e1c39f66.js → button.a8462029.js} +39 -42
- package/dist/chunks/button.a8462029.js.map +1 -0
- package/dist/chunks/{calendar.09b683b3.js → calendar.3f930683.js} +237 -240
- package/dist/chunks/calendar.3f930683.js.map +1 -0
- package/dist/chunks/checkbox.5e1e05ae.js +235 -0
- package/dist/chunks/checkbox.5e1e05ae.js.map +1 -0
- package/dist/chunks/{chevron-down.69bedf14.js → chevron-up.c03b58f8.js} +8 -8
- package/dist/chunks/chevron-up.c03b58f8.js.map +1 -0
- package/dist/chunks/controls-group.3b0dfb94.js +136 -0
- package/dist/chunks/controls-group.3b0dfb94.js.map +1 -0
- package/dist/chunks/{copy.2cf5e6c3.js → copy.1d14b783.js} +49 -50
- package/dist/chunks/copy.1d14b783.js.map +1 -0
- package/dist/chunks/{dropdown-default-textbox.203e747f.js → dropdown-default-textbox.a90e84f9.js} +88 -90
- package/dist/chunks/dropdown-default-textbox.a90e84f9.js.map +1 -0
- package/dist/chunks/{dropdown.8b415aac.js → dropdown.b798a82e.js} +348 -330
- package/dist/chunks/dropdown.b798a82e.js.map +1 -0
- package/dist/chunks/{error-message.ddfe8ea5.js → error-message.9acead25.js} +16 -16
- package/dist/chunks/error-message.9acead25.js.map +1 -0
- package/dist/chunks/footer-actions.9537d0df.js +111 -0
- package/dist/chunks/footer-actions.9537d0df.js.map +1 -0
- package/dist/chunks/get-slot-text.bead058f.js +9 -0
- package/dist/chunks/get-slot-text.bead058f.js.map +1 -0
- package/dist/chunks/{grid-layout.a30855ff.js → grid-layout.984317d7.js} +2 -2
- package/dist/chunks/{grid-layout.a30855ff.js.map → grid-layout.984317d7.js.map} +1 -1
- package/dist/chunks/index.228ecda0.js +101 -0
- package/dist/chunks/index.228ecda0.js.map +1 -0
- package/dist/chunks/index.89b00b94.js +124 -0
- package/dist/chunks/index.89b00b94.js.map +1 -0
- package/dist/chunks/{index.3da90517.js → index.9d8273fc.js} +38 -40
- package/dist/chunks/index.9d8273fc.js.map +1 -0
- package/dist/chunks/{index.c9225c3b.js → index.c2a80208.js} +195 -201
- package/dist/chunks/index.c2a80208.js.map +1 -0
- package/dist/chunks/{index.13949709.js → index.d26fdf71.js} +116 -113
- package/dist/chunks/{index.13949709.js.map → index.d26fdf71.js.map} +1 -1
- package/dist/chunks/{index.d27367cd.js → index.e84dbeae.js} +80 -83
- package/dist/chunks/{index.d27367cd.js.map → index.e84dbeae.js.map} +1 -1
- package/dist/chunks/listbox-option-tag.0c9c571e.js +129 -0
- package/dist/chunks/listbox-option-tag.0c9c571e.js.map +1 -0
- package/dist/chunks/{listbox.0c7c4e5e.js → listbox.6b52af1a.js} +315 -334
- package/dist/chunks/listbox.6b52af1a.js.map +1 -0
- package/dist/chunks/{loading-button.61d8ebe5.js → loading-button.081adbf3.js} +33 -33
- package/dist/chunks/loading-button.081adbf3.js.map +1 -0
- package/dist/chunks/tabs.keys.358742f2.js +7 -0
- package/dist/chunks/tabs.keys.358742f2.js.map +1 -0
- package/dist/chunks/{tooltip.835d9b52.js → tooltip.e4e34b86.js} +56 -59
- package/dist/chunks/tooltip.e4e34b86.js.map +1 -0
- package/dist/chunks/use-default-slot-validator.1169c221.js +16 -0
- package/dist/chunks/use-default-slot-validator.1169c221.js.map +1 -0
- package/dist/chunks/use-has-slot.9fac7123.js +16 -0
- package/dist/chunks/use-has-slot.9fac7123.js.map +1 -0
- package/dist/code-snippet.js +548 -463
- package/dist/code-snippet.js.map +1 -1
- package/dist/country.js +501 -505
- package/dist/country.js.map +1 -1
- package/dist/currency.js +38 -41
- package/dist/currency.js.map +1 -1
- package/dist/data-grid.js +837 -833
- package/dist/data-grid.js.map +1 -1
- package/dist/date-picker.js +83 -87
- package/dist/date-picker.js.map +1 -1
- package/dist/date-range-picker.js +2 -2
- package/dist/date.js +1 -1
- package/dist/dropdown.js +30 -32
- package/dist/dropdown.js.map +1 -1
- package/dist/empty-state.js +166 -0
- package/dist/empty-state.js.map +1 -0
- package/dist/filter-bar.js +986 -935
- package/dist/filter-bar.js.map +1 -1
- package/dist/focus-trap.js +1 -1
- package/dist/form-layout.js +72 -72
- package/dist/form-layout.js.map +1 -1
- package/dist/header.js +50 -52
- package/dist/header.js.map +1 -1
- package/dist/image.js +76 -0
- package/dist/image.js.map +1 -0
- package/dist/index.js +239 -232
- package/dist/index.js.map +1 -1
- package/dist/info-icon.js +2 -2
- package/dist/input-field.js +241 -269
- package/dist/input-field.js.map +1 -1
- package/dist/internal.js +7 -7
- package/dist/link.js +38 -36
- package/dist/link.js.map +1 -1
- package/dist/loading-indicator.js +1 -1
- package/dist/menu.js +131 -139
- package/dist/menu.js.map +1 -1
- package/dist/modal.js +121 -356
- package/dist/modal.js.map +1 -1
- package/dist/pagination.js +182 -185
- package/dist/pagination.js.map +1 -1
- package/dist/payment-method.js +19 -23
- package/dist/payment-method.js.map +1 -1
- package/dist/popover.js +56 -52
- package/dist/popover.js.map +1 -1
- package/dist/popper-container.js +36 -41
- package/dist/popper-container.js.map +1 -1
- package/dist/radio-group.js +112 -113
- package/dist/radio-group.js.map +1 -1
- package/dist/search-bar.js +77 -91
- package/dist/search-bar.js.map +1 -1
- package/dist/segmented-control.js +88 -75
- package/dist/segmented-control.js.map +1 -1
- package/dist/sidepanel.js +122 -121
- package/dist/sidepanel.js.map +1 -1
- package/dist/status.js +18 -21
- package/dist/status.js.map +1 -1
- package/dist/structured-list.js +1 -1
- package/dist/summary-grid.js +129 -162
- package/dist/summary-grid.js.map +1 -1
- package/dist/tabs.js +83 -75
- package/dist/tabs.js.map +1 -1
- package/dist/tag.js +32 -35
- package/dist/tag.js.map +1 -1
- package/dist/textarea.js +156 -155
- package/dist/textarea.js.map +1 -1
- package/dist/timeline.js +212 -213
- package/dist/timeline.js.map +1 -1
- package/dist/toast.js +68 -72
- package/dist/toast.js.map +1 -1
- package/dist/toggle.js +75 -73
- package/dist/toggle.js.map +1 -1
- package/dist/typography.js +1 -1
- package/dist/web-types.json +1 -1
- package/package.json +11 -10
- package/dist/@types/packages/vue2/src/components/data-grid/composables/useCalculateBodyFitContentDynamicStyles/useCalculateBodyFitContentDynamicStyles.d.ts +0 -2
- package/dist/@types/packages/vue2/src/components/data-grid/composables/useCalculateBodyFitContentDynamicStyles/useCalculateBodyFitContentDynamicStyles.types.d.ts +0 -8
- package/dist/@types/packages/vue2/src/components/filter-bar/components/base-filter/components/filter-bar-filter-button/filter-bar-filter-button.vue.d.ts +0 -58
- package/dist/@types/packages/vue2/src/components/filter-bar/components/base-filter/components/index.d.ts +0 -1
- package/dist/assets/button-actions.css +0 -1
- package/dist/assets/chevron-down.css +0 -1
- package/dist/chunks/base-button.20be08da.js +0 -111
- package/dist/chunks/base-button.20be08da.js.map +0 -1
- package/dist/chunks/button-actions.54e28e75.js +0 -124
- package/dist/chunks/button-actions.54e28e75.js.map +0 -1
- package/dist/chunks/button.e1c39f66.js.map +0 -1
- package/dist/chunks/calendar.09b683b3.js.map +0 -1
- package/dist/chunks/checkbox.a404069b.js +0 -226
- package/dist/chunks/checkbox.a404069b.js.map +0 -1
- package/dist/chunks/chevron-down.69bedf14.js.map +0 -1
- package/dist/chunks/controls-group.60fb2a86.js +0 -136
- package/dist/chunks/controls-group.60fb2a86.js.map +0 -1
- package/dist/chunks/copy.2cf5e6c3.js.map +0 -1
- package/dist/chunks/dropdown-default-textbox.203e747f.js.map +0 -1
- package/dist/chunks/dropdown.8b415aac.js.map +0 -1
- package/dist/chunks/error-message.ddfe8ea5.js.map +0 -1
- package/dist/chunks/footer-actions.0f640f87.js +0 -106
- package/dist/chunks/footer-actions.0f640f87.js.map +0 -1
- package/dist/chunks/get-slot-text.2db867f8.js +0 -9
- package/dist/chunks/get-slot-text.2db867f8.js.map +0 -1
- package/dist/chunks/index.222d29b0.js +0 -120
- package/dist/chunks/index.222d29b0.js.map +0 -1
- package/dist/chunks/index.3da90517.js.map +0 -1
- package/dist/chunks/index.aa34e363.js +0 -104
- package/dist/chunks/index.aa34e363.js.map +0 -1
- package/dist/chunks/index.c9225c3b.js.map +0 -1
- package/dist/chunks/listbox-option-tag.5ae8b79b.js +0 -133
- package/dist/chunks/listbox-option-tag.5ae8b79b.js.map +0 -1
- package/dist/chunks/listbox.0c7c4e5e.js.map +0 -1
- package/dist/chunks/loading-button.61d8ebe5.js.map +0 -1
- package/dist/chunks/tooltip.835d9b52.js.map +0 -1
- package/dist/chunks/use-default-slot-validator.83d977a1.js +0 -11
- package/dist/chunks/use-default-slot-validator.83d977a1.js.map +0 -1
- package/dist/chunks/use-has-slot.068222e6.js +0 -5
- package/dist/chunks/use-has-slot.068222e6.js.map +0 -1
package/dist/focus-trap.js
CHANGED
package/dist/form-layout.js
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { defineComponent as d, useSlots as
|
|
2
|
-
import { BentoAlert as
|
|
3
|
-
import { u as C } from "./chunks/use-has-slot.
|
|
4
|
-
import { F as
|
|
5
|
-
import { _ as
|
|
6
|
-
import { B as y,
|
|
7
|
-
import "./assets/
|
|
8
|
-
const
|
|
1
|
+
import { defineComponent as d, useSlots as L, computed as i, provide as F, toRef as h, openBlock as _, createBlock as v, resolveDynamicComponent as T, unref as a, withCtx as u, renderSlot as n, createCommentVNode as b, createElementBlock as m, createElementVNode as g, createVNode as $, onMounted as I, ref as S, normalizeClass as k } from "vue";
|
|
2
|
+
import { BentoAlert as B } from "./alert.js";
|
|
3
|
+
import { u as C } from "./chunks/use-has-slot.9fac7123.js";
|
|
4
|
+
import { F as E } from "./chunks/form-layout.types.a7a1438d.js";
|
|
5
|
+
import { _ as p } from "./chunks/_plugin-vue_export-helper.dad06003.js";
|
|
6
|
+
import { B as y, c as N } from "./chunks/index.89b00b94.js";
|
|
7
|
+
import "./assets/index15.css";
|
|
8
|
+
const G = {
|
|
9
9
|
key: 1,
|
|
10
10
|
class: "b-form-layout__actions-container"
|
|
11
|
-
},
|
|
12
|
-
...
|
|
11
|
+
}, A = { class: "b-form-layout__actions" }, O = { class: "b-form-layout__actions" }, V = {}, w = /* @__PURE__ */ d({
|
|
12
|
+
...V,
|
|
13
13
|
__name: "form-layout",
|
|
14
14
|
props: {
|
|
15
15
|
/**
|
|
@@ -22,68 +22,68 @@ const V = {
|
|
|
22
22
|
*/
|
|
23
23
|
loading: { type: Boolean, default: !1 }
|
|
24
24
|
},
|
|
25
|
-
setup(
|
|
26
|
-
const
|
|
27
|
-
return
|
|
25
|
+
setup(o) {
|
|
26
|
+
const t = o, r = L(), l = C(r), e = i(() => t.form ? "form" : "div"), c = i(() => l("actions-left") || l("actions-right"));
|
|
27
|
+
return F(E, h(t, "loading")), (s, f) => (_(), v(T(a(e)), {
|
|
28
28
|
class: "b-form-layout",
|
|
29
29
|
role: "form"
|
|
30
30
|
}, {
|
|
31
31
|
default: u(() => [
|
|
32
|
-
|
|
32
|
+
a(l)("error-message") ? (_(), v(a(B), {
|
|
33
33
|
key: 0,
|
|
34
34
|
class: "b-form-layout__error-message",
|
|
35
|
-
type:
|
|
35
|
+
type: "critical"
|
|
36
36
|
}, {
|
|
37
37
|
description: u(() => [
|
|
38
|
-
|
|
38
|
+
n(s.$slots, "error-message", {}, void 0, !0)
|
|
39
39
|
]),
|
|
40
40
|
_: 3
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
g("div",
|
|
45
|
-
|
|
41
|
+
})) : b("", !0),
|
|
42
|
+
n(s.$slots, "default", {}, void 0, !0),
|
|
43
|
+
a(c) ? (_(), m("div", G, [
|
|
44
|
+
g("div", A, [
|
|
45
|
+
n(s.$slots, "actions-left", {}, void 0, !0)
|
|
46
46
|
]),
|
|
47
|
-
g("div",
|
|
48
|
-
|
|
47
|
+
g("div", O, [
|
|
48
|
+
n(s.$slots, "actions-right", {}, void 0, !0)
|
|
49
49
|
])
|
|
50
|
-
])) :
|
|
50
|
+
])) : b("", !0)
|
|
51
51
|
]),
|
|
52
52
|
_: 3
|
|
53
53
|
}));
|
|
54
54
|
}
|
|
55
55
|
});
|
|
56
|
-
const
|
|
57
|
-
...
|
|
56
|
+
const W = /* @__PURE__ */ p(w, [["__scopeId", "data-v-f0c8b741"]]), q = { class: "b-form-layout-field-tip" }, x = {}, D = /* @__PURE__ */ d({
|
|
57
|
+
...x,
|
|
58
58
|
__name: "form-layout-field-tip",
|
|
59
|
-
setup(
|
|
60
|
-
return (
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
variant:
|
|
64
|
-
type:
|
|
59
|
+
setup(o) {
|
|
60
|
+
return (t, r) => (_(), m("div", q, [
|
|
61
|
+
n(t.$slots, "default", {}, void 0, !0),
|
|
62
|
+
$(a(B), {
|
|
63
|
+
variant: "tip",
|
|
64
|
+
type: "warning"
|
|
65
65
|
}, {
|
|
66
66
|
description: u(() => [
|
|
67
|
-
|
|
67
|
+
n(t.$slots, "message", {}, void 0, !0)
|
|
68
68
|
]),
|
|
69
69
|
_: 3
|
|
70
|
-
}
|
|
70
|
+
})
|
|
71
71
|
]));
|
|
72
72
|
}
|
|
73
73
|
});
|
|
74
|
-
const
|
|
75
|
-
const r = (
|
|
76
|
-
var
|
|
77
|
-
return (
|
|
78
|
-
},
|
|
79
|
-
|
|
80
|
-
const
|
|
81
|
-
|
|
82
|
-
|
|
74
|
+
const X = /* @__PURE__ */ p(D, [["__scopeId", "data-v-80229079"]]), M = (o, t) => {
|
|
75
|
+
const r = (e) => {
|
|
76
|
+
var c;
|
|
77
|
+
return (c = e.split) == null ? void 0 : c.call(e, "-").map((s) => parseInt(s, 10));
|
|
78
|
+
}, l = i(() => r(o.value));
|
|
79
|
+
I(() => {
|
|
80
|
+
const e = t.value.classList[0];
|
|
81
|
+
t.value.querySelectorAll(`.${e} > *`).forEach((s, f) => {
|
|
82
|
+
s.classList.add(`${e}--${l.value[f] || "100"}`);
|
|
83
83
|
});
|
|
84
84
|
});
|
|
85
|
-
},
|
|
86
|
-
...
|
|
85
|
+
}, Y = {}, j = /* @__PURE__ */ d({
|
|
86
|
+
...Y,
|
|
87
87
|
__name: "form-layout-group",
|
|
88
88
|
props: {
|
|
89
89
|
/**
|
|
@@ -113,19 +113,19 @@ const ot = /* @__PURE__ */ m(M, [["__scopeId", "data-v-9031784f"]]), Y = (e, o)
|
|
|
113
113
|
default: "100"
|
|
114
114
|
}
|
|
115
115
|
},
|
|
116
|
-
setup(
|
|
117
|
-
const
|
|
118
|
-
return
|
|
116
|
+
setup(o) {
|
|
117
|
+
const t = o, r = S(null);
|
|
118
|
+
return M(h(t, "layout"), r), (l, e) => (_(), m("div", {
|
|
119
119
|
ref_key: "formLayoutGroup",
|
|
120
120
|
ref: r,
|
|
121
121
|
class: "b-form-layout-group"
|
|
122
122
|
}, [
|
|
123
|
-
l
|
|
123
|
+
n(l.$slots, "default", {}, void 0, !0)
|
|
124
124
|
], 512));
|
|
125
125
|
}
|
|
126
126
|
});
|
|
127
|
-
const
|
|
128
|
-
...
|
|
127
|
+
const Z = /* @__PURE__ */ p(j, [["__scopeId", "data-v-a76530eb"]]), z = {}, H = /* @__PURE__ */ d({
|
|
128
|
+
...z,
|
|
129
129
|
__name: "form-layout-title",
|
|
130
130
|
props: {
|
|
131
131
|
/**
|
|
@@ -144,45 +144,45 @@ const et = /* @__PURE__ */ m(z, [["__scopeId", "data-v-a76530eb"]]), H = {}, J =
|
|
|
144
144
|
el: {
|
|
145
145
|
type: y.props.el.type,
|
|
146
146
|
required: !0,
|
|
147
|
-
validator: (
|
|
147
|
+
validator: (o) => Object.values(N).includes(o)
|
|
148
148
|
}
|
|
149
149
|
},
|
|
150
|
-
setup(
|
|
151
|
-
const
|
|
152
|
-
"b-form-layout-title--subsection":
|
|
150
|
+
setup(o) {
|
|
151
|
+
const t = o, r = L(), l = i(() => !t.subsection), e = C(r), c = i(() => ({
|
|
152
|
+
"b-form-layout-title--subsection": t.subsection
|
|
153
153
|
}));
|
|
154
|
-
return (
|
|
155
|
-
class:
|
|
154
|
+
return (s, f) => (_(), m("div", {
|
|
155
|
+
class: k(["b-form-layout-title", a(c)])
|
|
156
156
|
}, [
|
|
157
|
-
|
|
158
|
-
el:
|
|
159
|
-
variant:
|
|
160
|
-
medium:
|
|
157
|
+
$(a(y), {
|
|
158
|
+
el: o.el,
|
|
159
|
+
variant: "title",
|
|
160
|
+
medium: a(l)
|
|
161
161
|
}, {
|
|
162
162
|
default: u(() => [
|
|
163
|
-
|
|
163
|
+
n(s.$slots, "default", {}, void 0, !0)
|
|
164
164
|
]),
|
|
165
165
|
_: 3
|
|
166
|
-
}, 8, ["el", "
|
|
167
|
-
|
|
166
|
+
}, 8, ["el", "medium"]),
|
|
167
|
+
a(e)("description") ? (_(), v(a(y), {
|
|
168
168
|
key: 0,
|
|
169
169
|
class: "b-form-layout-title__description",
|
|
170
|
-
el:
|
|
170
|
+
el: "span",
|
|
171
171
|
wide: ""
|
|
172
172
|
}, {
|
|
173
173
|
default: u(() => [
|
|
174
|
-
|
|
174
|
+
n(s.$slots, "description", {}, void 0, !0)
|
|
175
175
|
]),
|
|
176
176
|
_: 3
|
|
177
|
-
}
|
|
177
|
+
})) : b("", !0)
|
|
178
178
|
], 2));
|
|
179
179
|
}
|
|
180
180
|
});
|
|
181
|
-
const
|
|
181
|
+
const tt = /* @__PURE__ */ p(H, [["__scopeId", "data-v-fbc939de"]]);
|
|
182
182
|
export {
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
183
|
+
W as BentoFormLayout,
|
|
184
|
+
X as BentoFormLayoutFieldTip,
|
|
185
|
+
Z as BentoFormLayoutGroup,
|
|
186
|
+
tt as BentoFormLayoutTitle
|
|
187
187
|
};
|
|
188
188
|
//# sourceMappingURL=form-layout.js.map
|
package/dist/form-layout.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"form-layout.js","sources":["../../vue2/src/components/form-layout/form-layout.vue","../../vue2/src/components/form-layout/components/form-layout-field-tip/form-layout-field-tip.vue","../../vue2/src/components/form-layout/components/form-layout-group/composable/use-form-layout-group-percentage.ts","../../vue2/src/components/form-layout/components/form-layout-group/form-layout-group.vue","../../vue2/src/components/form-layout/components/form-layout-title/form-layout-title.vue"],"sourcesContent":["<template>\n <component :is=\"formLayoutElement\" class=\"b-form-layout\" role=\"form\">\n <bento-alert\n v-if=\"hasSlot('error-message')\"\n class=\"b-form-layout__error-message\"\n :type=\"BentoAlertTypeOption.CRITICAL\"\n >\n <template #description>\n <slot name=\"error-message\" />\n </template>\n </bento-alert>\n\n <slot />\n\n <div v-if=\"hasActions\" class=\"b-form-layout__actions-container\">\n <div class=\"b-form-layout__actions\">\n <slot name=\"actions-left\" />\n </div>\n\n <div class=\"b-form-layout__actions\">\n <slot name=\"actions-right\" />\n </div>\n </div>\n </component>\n</template>\n\n<script setup lang=\"ts\">\n import { computed, provide, toRef, useSlots } from 'vue';\n import { BentoAlert, BentoAlertTypeOption } from '@/components/alert';\n import { useHasSlot } from '@/composables';\n import { FORM_LAYOUT_LOADING_INJECTION_KEY } from './form-layout.types';\n\n const slots = useSlots();\n const hasSlot = useHasSlot(slots);\n\n const props = defineProps({\n /**\n * Renders the form layout as an HTML `form`\n */\n form: { type: Boolean, default: false },\n\n /**\n * Sets the state of the form and its fields to\n * a read only status.\n */\n loading: { type: Boolean, default: false },\n });\n\n const formLayoutElement = computed(() => (props.form ? 'form' : 'div'));\n const hasActions = computed(() => hasSlot('actions-left') || hasSlot('actions-right'));\n\n provide(FORM_LAYOUT_LOADING_INJECTION_KEY, toRef(props, 'loading'));\n</script>\n\n<script lang=\"ts\">\n /**\n * Form layout component is a pre-designed layout that serves\n * as a starting point for creating a form.\n *\n * It can include various common form components:\n * input field, dropdown, date picker, checkbox group, radio group,\n * textarea, etc.\n *\n * Form layout is context agnostic and can be dropped in different\n * places, for example in modals, side panels or pages.\n *\n * @example\n * import { BentoFormLayout, BentoFormLayoutFieldTip } from '@adyen/bento-vue2';\n *\n * export default {\n * components: { BentoFormLayout, BentoFormLayoutFieldTip },\n * template: `\n * <bento-form-layout>\n * <template #error-message>There is an error. Correct the highlighted field.</template>\n *\n * <bento-input-field>Input field</bento-input-field>\n *\n * <bento-form-layout-field-tip>\n * <bento-dropdown label=\"Dropdown\" :items=\"dropdownItems\" placeholder=\"Select an animal\" />\n * <template #message>This is a small tip that can be used in small spaces</template>\n * </bento-form-layout-field-tip>\n *\n * <bento-form-layout-title subsection>\n * Section title\n * <template #description>Optional section description</template>\n * </bento-form-layout-title>\n * </bento-form-layout>\n * `\n * }\n */\n export default {};\n</script>\n\n<style lang=\"scss\" scoped src=\"./form-layout.scss\" />\n","<template>\n <div class=\"b-form-layout-field-tip\">\n <slot />\n <bento-alert :variant=\"BentoAlertVariant.TIP\" :type=\"BentoAlertTypeOption.WARNING\">\n <template #description>\n <slot name=\"message\" />\n </template>\n </bento-alert>\n </div>\n</template>\n\n<script setup lang=\"ts\">\n import { BentoAlert, BentoAlertTypeOption, BentoAlertVariant } from '@/components/alert';\n</script>\n\n<script lang=\"ts\">\n /**\n * You can help users provide accurate and well formatted information\n * by using various elements that come with an input field.\n *\n * Use description/supporting text to add additional context to the\n * field or guidance how to format the input correctly.\n * Because description is always visible it should be the first\n * choice in providing guidance.\n *\n * @example\n * import { BentoFormLayoutFieldTip } from '@adyen/bento-vue2';\n *\n * export default {\n * components: { BentoFormLayoutFieldTip },\n * template: `\n * <bento-form-layout-field-tip>\n * <bento-dropdown label=\"Dropdown\" :items=\"dropdownItems\" placeholder=\"Select an animal\" />\n *\n * <template #message>This is a small tip that can be used in small spaces</template>\n * </bento-form-layout-field-tip>\n * `\n */\n export default {};\n</script>\n\n<style lang=\"scss\" scoped src=\"./form-layout-field-tip.scss\" />\n","import { computed, onMounted, Ref } from 'vue';\nimport { BentoLayoutGroupProportions } from '../form-layout-group.types';\n\n/**\n * Calculates the CSS classes based on the percentage\n * for each one of the layouts in format `##-##` or `##`.\n *\n * It receives a layout of type @see BentoLayoutGroupProportions to\n * generate the class and apply it to the children of the @see BentoFormLayoutGroup component\n *\n * @param {Ref<BentoLayoutGroupProportions>} layoutProp Layout string in the format `##` or `##-##`\n * @param {Ref<HTMLElement>} formLayoutGroupRef Reference to an HTML element of type BentoFormLayoutGroup\n */\nexport const useFormLayoutGroupPercentage = (\n layoutProp: Ref<BentoLayoutGroupProportions>,\n formLayoutGroupRef: Ref<HTMLElement>\n) => {\n // Split the `##-##` format into individual values [##, ##]\n const getLayoutValues = layout => layout.split?.('-').map(value => parseInt(value, 10));\n const layout = computed(() => getLayoutValues(layoutProp.value));\n\n onMounted(() => {\n // Apply class to every immediate child\n const layoutClassName = formLayoutGroupRef.value.classList[0];\n const immediateChildren = formLayoutGroupRef.value.querySelectorAll(`.${layoutClassName} > *`); // Get immediate children\n immediateChildren.forEach((child, index) => {\n child.classList.add(`${layoutClassName}--${layout.value[index] || '100'}`); // 100% default\n });\n });\n};\n","<template>\n <div ref=\"formLayoutGroup\" class=\"b-form-layout-group\">\n <slot></slot>\n </div>\n</template>\n\n<script setup lang=\"ts\">\n import { defineProps, PropType, ref, toRef } from 'vue';\n import { useFormLayoutGroupPercentage } from './composable/use-form-layout-group-percentage';\n import { BentoLayoutGroupProportions } from './form-layout-group.types';\n\n const props = defineProps({\n /**\n * The layout of the pair group of components.\n * This will render the components within the width of the proportions.\n * Only two colums are available.\n *\n * If only one value is entered, then it will assume there's only one child in the group.\n * If two values are entered, the first value will be use for the first child and the second\n * value for the second child.\n *\n * If the value entered is not listed in the example\n * list below it will use 100% by default.\n * @example\n * '50-50'\n * '25-75'\n * '75-25'\n * '33-66'\n * '66-33'\n * '25'\n * '33'\n * '50'\n * '100'\n */\n layout: {\n type: String as PropType<BentoLayoutGroupProportions>,\n default: '100',\n },\n });\n\n const formLayoutGroup = ref(null);\n useFormLayoutGroupPercentage(toRef(props, 'layout'), formLayoutGroup);\n</script>\n\n<script lang=\"ts\">\n /**\n * Use to provide horizontal layouts to build forms\n * with two fields per line.\n *\n * These can be used for field combinations,\n * such as post code and city or title and first name.\n *\n * @example\n * import { BentoFormLayoutGroup } from '@adyen/bento-vue2';\n *\n * export default {\n * components: { BentoFormLayoutGroup },\n * template: `\n * <bento-form-layout-group>\n * <first-element />\n * <second-element />\n * </bento-form-layout-group>\n * `\n * }\n */\n export default {};\n</script>\n\n<style lang=\"scss\" scoped src=\"./form-layout-group.scss\" />\n","<template>\n <div class=\"b-form-layout-title\" :class=\"conditionalClasses\">\n <bento-typography :el=\"el\" :variant=\"BentoTypographyVariant.TITLE\" :medium=\"isSection\">\n <slot />\n </bento-typography>\n\n <bento-typography\n v-if=\"hasSlot('description')\"\n class=\"b-form-layout-title__description\"\n :el=\"BentoTypographyElement.SPAN\"\n wide\n >\n <slot name=\"description\" />\n </bento-typography>\n </div>\n</template>\n\n<script setup lang=\"ts\">\n import { computed, useSlots } from 'vue';\n import { BentoTypography, BentoTypographyElement, BentoTypographyVariant } from '@/components/typography';\n import { useHasSlot } from '@/composables';\n\n const slots = useSlots();\n\n const props = defineProps({\n /**\n * Defines if the Form Layout title is\n * a \"section\" or a \"subsection\".\n * Default is \"section\" (false). Turn into \"true\" for \"subsection\"\n */\n subsection: {\n type: Boolean,\n default: false,\n },\n\n /**\n * Sets the HTML DOM element.\n * @values h1, h2, h3, h4, h5, h6, div, p, span\n */\n el: {\n type: BentoTypography.props.el.type,\n required: true,\n validator: (value: BentoTypographyElement) => Object.values(BentoTypographyElement).includes(value),\n },\n });\n\n // Uses \"medium\" typography if it is a section title\n const isSection = computed(() => !props.subsection);\n const hasSlot = useHasSlot(slots);\n const conditionalClasses = computed(() => ({\n 'b-form-layout-title--subsection': props.subsection,\n }));\n</script>\n\n<script lang=\"ts\">\n /**\n * If you’re building a lengthy form, organise related\n * fields into sections and, if needed, subsections.\n *\n * A form can have a \"Section Title\" and multiple \"Subsection titles\".\n *\n * An element of type @see BentoTypographyElement must always be provided\n * to define correct HTML sementic from the application's context\n *\n * @example\n * import { BentoFormLayoutTitle } from '@adyen/bento-vue2';\n *\n * export default {\n * components: { BentoFormLayoutTitle },\n * template: `\n * <bento-form-layout-title subsection :el=\"BentoTypographyElement.H2\">\n * Title\n * <template #description>Description text</template>\n * </bento-form-layout-title>\n * `\n * }\n */\n export default {};\n</script>\n\n<style lang=\"scss\" scoped src=\"./form-layout-title.scss\" />\n"],"names":["__default__$3","slots","useSlots","hasSlot","useHasSlot","formLayoutElement","computed","props","hasActions","provide","FORM_LAYOUT_LOADING_INJECTION_KEY","toRef","__default__$2","useFormLayoutGroupPercentage","layoutProp","formLayoutGroupRef","getLayoutValues","layout2","_a","value","layout","onMounted","layoutClassName","child","index","__default__$1","formLayoutGroup","ref","__default__","isSection","conditionalClasses"],"mappings":";;;;;;;;;;qFA0FIA,IAAA,CAAA;;;;;;;;;;;;;;;iBA1DAC,IAAAC,EAAA,GACAC,IAAAC,EAAAH,CAAA,GAeAI,IAAAC,EAAA,MAAAC,EAAA,OAAA,SAAA,KAAA,GACAC,IAAAF,EAAA,MAAAH,EAAA,cAAA,KAAAA,EAAA,eAAA,CAAA;AAEA,WAAAM,EAAAC,GAAAC,EAAAJ,GAAA,SAAA,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;+GCbAK,IAAA,CAAA;;;;;;;;;;;;;;;;;;qECzBSC,IAAA,CAAAC,GAAAC,MAAA;AAKT,QAAAC,IAAA,CAAAC,MAAA;;AAAA,YAAAC,IAAAD,EAAA,UAAA,gBAAAC,EAAA,KAAAD,GAAA,KAAA,IAAA,CAAAE,MAAA,SAAAA,GAAA,EAAA;AAAA,KACAC,IAAAd,EAAA,MAAAU,EAAAF,EAAA,KAAA,CAAA;AAEA,EAAAO,EAAA,MAAA;AAEI,UAAAC,IAAAP,EAAA,MAAA,UAAA,CAAA;AAEA,IADAA,EAAA,MAAA,iBAAA,IAAAO,OAAA,EACA,QAAA,CAAAC,GAAAC,MAAA;AACI,MAAAD,EAAA,UAAA,IAAA,GAAAD,MAAAF,EAAA,MAAAI,CAAA,KAAA,OAAA;AAAA,IAAyE,CAAA;AAAA,EAC5E,CAAA;AAET,GCoCIC,IAAA,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAzBAC,IAAAC,EAAA,IAAA;AACA,WAAAd,EAAAF,EAAAJ,GAAA,QAAA,GAAAmB,CAAA;;;;;;;;;qECoCAE,IAAA,CAAA;;;;;;;;;;;;;;;;;;;;;;;;iBAvDA3B,IAAAC,EAAA,GAyBA2B,IAAAvB,EAAA,MAAA,CAAAC,EAAA,UAAA,GACAJ,IAAAC,EAAAH,CAAA,GACA6B,IAAAxB,EAAA,OAAA;AAAA,MAA2C,mCAAAC,EAAA;AAAA,IACE,EAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
1
|
+
{"version":3,"file":"form-layout.js","sources":["../../vue2/src/components/form-layout/form-layout.vue","../../vue2/src/components/form-layout/components/form-layout-field-tip/form-layout-field-tip.vue","../../vue2/src/components/form-layout/components/form-layout-group/composable/use-form-layout-group-percentage.ts","../../vue2/src/components/form-layout/components/form-layout-group/form-layout-group.vue","../../vue2/src/components/form-layout/components/form-layout-title/form-layout-title.vue"],"sourcesContent":["<template>\n <component :is=\"formLayoutElement\" class=\"b-form-layout\" role=\"form\">\n <bento-alert v-if=\"hasSlot('error-message')\" class=\"b-form-layout__error-message\" type=\"critical\">\n <template #description>\n <slot name=\"error-message\" />\n </template>\n </bento-alert>\n\n <slot />\n\n <div v-if=\"hasActions\" class=\"b-form-layout__actions-container\">\n <div class=\"b-form-layout__actions\">\n <slot name=\"actions-left\" />\n </div>\n\n <div class=\"b-form-layout__actions\">\n <slot name=\"actions-right\" />\n </div>\n </div>\n </component>\n</template>\n\n<script setup lang=\"ts\">\n import { computed, provide, toRef, useSlots } from 'vue';\n import { BentoAlert } from '@/components/alert';\n import { useHasSlot } from '@/composables';\n import { FORM_LAYOUT_LOADING_INJECTION_KEY } from './form-layout.types';\n\n const slots = useSlots();\n const hasSlot = useHasSlot(slots);\n\n const props = defineProps({\n /**\n * Renders the form layout as an HTML `form`\n */\n form: { type: Boolean, default: false },\n\n /**\n * Sets the state of the form and its fields to\n * a read only status.\n */\n loading: { type: Boolean, default: false },\n });\n\n const formLayoutElement = computed(() => (props.form ? 'form' : 'div'));\n const hasActions = computed(() => hasSlot('actions-left') || hasSlot('actions-right'));\n\n provide(FORM_LAYOUT_LOADING_INJECTION_KEY, toRef(props, 'loading'));\n</script>\n\n<script lang=\"ts\">\n /**\n * Form layout component is a pre-designed layout that serves\n * as a starting point for creating a form.\n *\n * It can include various common form components:\n * input field, dropdown, date picker, checkbox group, radio group,\n * textarea, etc.\n *\n * Form layout is context agnostic and can be dropped in different\n * places, for example in modals, side panels or pages.\n *\n * @example\n * import { BentoFormLayout, BentoFormLayoutFieldTip } from '@adyen/bento-vue2';\n *\n * export default {\n * components: { BentoFormLayout, BentoFormLayoutFieldTip },\n * template: `\n * <bento-form-layout>\n * <template #error-message>There is an error. Correct the highlighted field.</template>\n *\n * <bento-input-field>Input field</bento-input-field>\n *\n * <bento-form-layout-field-tip>\n * <bento-dropdown label=\"Dropdown\" :items=\"dropdownItems\" placeholder=\"Select an animal\" />\n * <template #message>This is a small tip that can be used in small spaces</template>\n * </bento-form-layout-field-tip>\n *\n * <bento-form-layout-title subsection>\n * Section title\n * <template #description>Optional section description</template>\n * </bento-form-layout-title>\n * </bento-form-layout>\n * `\n * }\n */\n export default {};\n</script>\n\n<style lang=\"scss\" scoped src=\"./form-layout.scss\" />\n","<template>\n <div class=\"b-form-layout-field-tip\">\n <slot />\n <bento-alert variant=\"tip\" type=\"warning\">\n <template #description>\n <slot name=\"message\" />\n </template>\n </bento-alert>\n </div>\n</template>\n\n<script setup lang=\"ts\">\n import { BentoAlert } from '@/components/alert';\n</script>\n\n<script lang=\"ts\">\n /**\n * You can help users provide accurate and well formatted information\n * by using various elements that come with an input field.\n *\n * Use description/supporting text to add additional context to the\n * field or guidance how to format the input correctly.\n * Because description is always visible it should be the first\n * choice in providing guidance.\n *\n * @example\n * import { BentoFormLayoutFieldTip } from '@adyen/bento-vue2';\n *\n * export default {\n * components: { BentoFormLayoutFieldTip },\n * template: `\n * <bento-form-layout-field-tip>\n * <bento-dropdown label=\"Dropdown\" :items=\"dropdownItems\" placeholder=\"Select an animal\" />\n *\n * <template #message>This is a small tip that can be used in small spaces</template>\n * </bento-form-layout-field-tip>\n * `\n */\n export default {};\n</script>\n\n<style lang=\"scss\" scoped src=\"./form-layout-field-tip.scss\" />\n","import { computed, onMounted, Ref } from 'vue';\nimport { BentoLayoutGroupProportions } from '../form-layout-group.types';\n\n/**\n * Calculates the CSS classes based on the percentage\n * for each one of the layouts in format `##-##` or `##`.\n *\n * It receives a layout of type @see BentoLayoutGroupProportions to\n * generate the class and apply it to the children of the @see BentoFormLayoutGroup component\n *\n * @param {Ref<BentoLayoutGroupProportions>} layoutProp Layout string in the format `##` or `##-##`\n * @param {Ref<HTMLElement>} formLayoutGroupRef Reference to an HTML element of type BentoFormLayoutGroup\n */\nexport const useFormLayoutGroupPercentage = (\n layoutProp: Ref<BentoLayoutGroupProportions>,\n formLayoutGroupRef: Ref<HTMLElement>\n) => {\n // Split the `##-##` format into individual values [##, ##]\n const getLayoutValues = layout => layout.split?.('-').map(value => parseInt(value, 10));\n const layout = computed(() => getLayoutValues(layoutProp.value));\n\n onMounted(() => {\n // Apply class to every immediate child\n const layoutClassName = formLayoutGroupRef.value.classList[0];\n const immediateChildren = formLayoutGroupRef.value.querySelectorAll(`.${layoutClassName} > *`); // Get immediate children\n immediateChildren.forEach((child, index) => {\n child.classList.add(`${layoutClassName}--${layout.value[index] || '100'}`); // 100% default\n });\n });\n};\n","<template>\n <div ref=\"formLayoutGroup\" class=\"b-form-layout-group\">\n <slot></slot>\n </div>\n</template>\n\n<script setup lang=\"ts\">\n import { defineProps, PropType, ref, toRef } from 'vue';\n import { useFormLayoutGroupPercentage } from './composable/use-form-layout-group-percentage';\n import { BentoLayoutGroupProportions } from './form-layout-group.types';\n\n const props = defineProps({\n /**\n * The layout of the pair group of components.\n * This will render the components within the width of the proportions.\n * Only two colums are available.\n *\n * If only one value is entered, then it will assume there's only one child in the group.\n * If two values are entered, the first value will be use for the first child and the second\n * value for the second child.\n *\n * If the value entered is not listed in the example\n * list below it will use 100% by default.\n * @example\n * '50-50'\n * '25-75'\n * '75-25'\n * '33-66'\n * '66-33'\n * '25'\n * '33'\n * '50'\n * '100'\n */\n layout: {\n type: String as PropType<BentoLayoutGroupProportions>,\n default: '100',\n },\n });\n\n const formLayoutGroup = ref(null);\n useFormLayoutGroupPercentage(toRef(props, 'layout'), formLayoutGroup);\n</script>\n\n<script lang=\"ts\">\n /**\n * Use to provide horizontal layouts to build forms\n * with two fields per line.\n *\n * These can be used for field combinations,\n * such as post code and city or title and first name.\n *\n * @example\n * import { BentoFormLayoutGroup } from '@adyen/bento-vue2';\n *\n * export default {\n * components: { BentoFormLayoutGroup },\n * template: `\n * <bento-form-layout-group>\n * <first-element />\n * <second-element />\n * </bento-form-layout-group>\n * `\n * }\n */\n export default {};\n</script>\n\n<style lang=\"scss\" scoped src=\"./form-layout-group.scss\" />\n","<template>\n <div class=\"b-form-layout-title\" :class=\"conditionalClasses\">\n <bento-typography :el=\"el\" variant=\"title\" :medium=\"isSection\">\n <slot />\n </bento-typography>\n\n <bento-typography v-if=\"hasSlot('description')\" class=\"b-form-layout-title__description\" el=\"span\" wide>\n <slot name=\"description\" />\n </bento-typography>\n </div>\n</template>\n\n<script setup lang=\"ts\">\n import { computed, useSlots } from 'vue';\n import { BentoTypography, BentoTypographyElement } from '@/components/typography';\n import { useHasSlot } from '@/composables';\n\n const slots = useSlots();\n\n const props = defineProps({\n /**\n * Defines if the Form Layout title is\n * a \"section\" or a \"subsection\".\n * Default is \"section\" (false). Turn into \"true\" for \"subsection\"\n */\n subsection: {\n type: Boolean,\n default: false,\n },\n\n /**\n * Sets the HTML DOM element.\n * @values h1, h2, h3, h4, h5, h6, div, p, span\n */\n el: {\n type: BentoTypography.props.el.type,\n required: true,\n validator: (value: BentoTypographyElement) => Object.values(BentoTypographyElement).includes(value),\n },\n });\n\n // Uses \"medium\" typography if it is a section title\n const isSection = computed(() => !props.subsection);\n const hasSlot = useHasSlot(slots);\n const conditionalClasses = computed(() => ({\n 'b-form-layout-title--subsection': props.subsection,\n }));\n</script>\n\n<script lang=\"ts\">\n /**\n * If you’re building a lengthy form, organise related\n * fields into sections and, if needed, subsections.\n *\n * A form can have a \"Section Title\" and multiple \"Subsection titles\".\n *\n * One of the values provided in @see BentoTypographyElement must always be provided as a string\n * to define correct HTML sementic from the application's context\n *\n * @example\n * import { BentoFormLayoutTitle } from '@adyen/bento-vue2';\n *\n * export default {\n * components: { BentoFormLayoutTitle },\n * template: `\n * <bento-form-layout-title subsection el=\"h2\">\n * Title\n * <template #description>Description text</template>\n * </bento-form-layout-title>\n * `\n * }\n */\n export default {};\n</script>\n\n<style lang=\"scss\" scoped src=\"./form-layout-title.scss\" />\n"],"names":["__default__$3","slots","useSlots","hasSlot","useHasSlot","formLayoutElement","computed","props","hasActions","provide","FORM_LAYOUT_LOADING_INJECTION_KEY","toRef","__default__$2","useFormLayoutGroupPercentage","layoutProp","formLayoutGroupRef","getLayoutValues","layout2","_a","value","layout","onMounted","layoutClassName","child","index","__default__$1","formLayoutGroup","ref","__default__","isSection","conditionalClasses"],"mappings":";;;;;;;;;;qFAsFIA,IAAA,CAAA;;;;;;;;;;;;;;;iBA1DAC,IAAAC,EAAA,GACAC,IAAAC,EAAAH,CAAA,GAeAI,IAAAC,EAAA,MAAAC,EAAA,OAAA,SAAA,KAAA,GACAC,IAAAF,EAAA,MAAAH,EAAA,cAAA,KAAAA,EAAA,eAAA,CAAA;AAEA,WAAAM,EAAAC,GAAAC,EAAAJ,GAAA,SAAA,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;8GCTAK,IAAA,CAAA;;;;;;;;;;;;;;;;;;oECzBSC,IAAA,CAAAC,GAAAC,MAAA;AAKT,QAAAC,IAAA,CAAAC,MAAA;;AAAA,YAAAC,IAAAD,EAAA,UAAA,gBAAAC,EAAA,KAAAD,GAAA,KAAA,IAAA,CAAAE,MAAA,SAAAA,GAAA,EAAA;AAAA,KACAC,IAAAd,EAAA,MAAAU,EAAAF,EAAA,KAAA,CAAA;AAEA,EAAAO,EAAA,MAAA;AAEI,UAAAC,IAAAP,EAAA,MAAA,UAAA,CAAA;AAEA,IADAA,EAAA,MAAA,iBAAA,IAAAO,OAAA,EACA,QAAA,CAAAC,GAAAC,MAAA;AACI,MAAAD,EAAA,UAAA,IAAA,GAAAD,MAAAF,EAAA,MAAAI,CAAA,KAAA,OAAA;AAAA,IAAyE,CAAA;AAAA,EAC5E,CAAA;AAET,GCoCIC,IAAA,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAzBAC,IAAAC,EAAA,IAAA;AACA,WAAAd,EAAAF,EAAAJ,GAAA,QAAA,GAAAmB,CAAA;;;;;;;;;oEC+BAE,IAAA,CAAA;;;;;;;;;;;;;;;;;;;;;;;;iBAvDA3B,IAAAC,EAAA,GAyBA2B,IAAAvB,EAAA,MAAA,CAAAC,EAAA,UAAA,GACAJ,IAAAC,EAAAH,CAAA,GACA6B,IAAAxB,EAAA,OAAA;AAAA,MAA2C,mCAAAC,EAAA;AAAA,IACE,EAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
package/dist/header.js
CHANGED
|
@@ -1,23 +1,23 @@
|
|
|
1
|
-
import { defineComponent as
|
|
1
|
+
import { defineComponent as C, computed as I, resolveComponent as v, openBlock as p, createElementBlock as P, createElementVNode as _, createVNode as R, mergeProps as k, withCtx as N, createTextVNode as S, toDisplayString as E, createBlock as M, createCommentVNode as T } from "vue";
|
|
2
2
|
import { BentoInfoIcon as G } from "./info-icon.js";
|
|
3
|
-
import { u as L } from "./chunks/use-has-slot.
|
|
4
|
-
import { B as
|
|
3
|
+
import { u as L } from "./chunks/use-has-slot.9fac7123.js";
|
|
4
|
+
import { B as V, c as O, a as $ } from "./chunks/index.89b00b94.js";
|
|
5
5
|
import { u as F } from "./chunks/i18n.6c402773.js";
|
|
6
6
|
import { c as h, a as j } from "./chunks/index.86453263.js";
|
|
7
|
-
import { r as
|
|
7
|
+
import { r as f, t as i, e as b, g as x, d as q, f as z } from "./chunks/index.f55fdc32.js";
|
|
8
8
|
import { e as W } from "./chunks/index.fdf12170.js";
|
|
9
|
-
import {
|
|
9
|
+
import { BentoButtonActions as J } from "./button.js";
|
|
10
10
|
import { _ as K } from "./chunks/_plugin-vue_export-helper.dad06003.js";
|
|
11
11
|
import "./assets/index16.css";
|
|
12
12
|
function Q(e, a) {
|
|
13
|
-
|
|
13
|
+
f(2, arguments);
|
|
14
14
|
var r = i(e), t = i(a), l = r.getFullYear() - t.getFullYear(), n = r.getMonth() - t.getMonth();
|
|
15
15
|
return l * 12 + n;
|
|
16
16
|
}
|
|
17
17
|
function Z(e, a) {
|
|
18
|
-
return
|
|
18
|
+
return f(2, arguments), i(e).getTime() - i(a).getTime();
|
|
19
19
|
}
|
|
20
|
-
var
|
|
20
|
+
var A = {
|
|
21
21
|
ceil: Math.ceil,
|
|
22
22
|
round: Math.round,
|
|
23
23
|
floor: Math.floor,
|
|
@@ -27,20 +27,20 @@ var U = {
|
|
|
27
27
|
// Math.trunc is not supported by IE
|
|
28
28
|
}, ee = "trunc";
|
|
29
29
|
function te(e) {
|
|
30
|
-
return e ?
|
|
30
|
+
return e ? A[e] : A[ee];
|
|
31
31
|
}
|
|
32
32
|
function ne(e) {
|
|
33
|
-
|
|
33
|
+
f(1, arguments);
|
|
34
34
|
var a = i(e), r = a.getMonth();
|
|
35
35
|
return a.setFullYear(a.getFullYear(), r + 1, 0), a.setHours(23, 59, 59, 999), a;
|
|
36
36
|
}
|
|
37
37
|
function ae(e) {
|
|
38
|
-
|
|
38
|
+
f(1, arguments);
|
|
39
39
|
var a = i(e);
|
|
40
40
|
return W(a).getTime() === ne(a).getTime();
|
|
41
41
|
}
|
|
42
42
|
function re(e, a) {
|
|
43
|
-
|
|
43
|
+
f(2, arguments);
|
|
44
44
|
var r = i(e), t = i(a), l = h(r, t), n = Math.abs(Q(r, t)), o;
|
|
45
45
|
if (n < 1)
|
|
46
46
|
o = 0;
|
|
@@ -52,14 +52,14 @@ function re(e, a) {
|
|
|
52
52
|
return o === 0 ? 0 : o;
|
|
53
53
|
}
|
|
54
54
|
function oe(e, a, r) {
|
|
55
|
-
|
|
55
|
+
f(2, arguments);
|
|
56
56
|
var t = Z(e, a) / 1e3;
|
|
57
57
|
return te(r == null ? void 0 : r.roundingMethod)(t);
|
|
58
58
|
}
|
|
59
|
-
var
|
|
59
|
+
var U = 1440, se = 2520, D = 43200, ie = 86400;
|
|
60
60
|
function le(e, a) {
|
|
61
61
|
var r = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {};
|
|
62
|
-
|
|
62
|
+
f(2, arguments);
|
|
63
63
|
var t = r.locale || b;
|
|
64
64
|
if (!t.formatDistance)
|
|
65
65
|
throw new RangeError("locale must contain formatDistance property");
|
|
@@ -70,46 +70,46 @@ function le(e, a) {
|
|
|
70
70
|
n.addSuffix = !!r.addSuffix, n.comparison = l;
|
|
71
71
|
var o, u;
|
|
72
72
|
l > 0 ? (o = i(a), u = i(e)) : (o = i(e), u = i(a));
|
|
73
|
-
var
|
|
73
|
+
var c = oe(u, o), B = (x(u) - x(o)) / 1e3, s = Math.round((c - B) / 60), d;
|
|
74
74
|
if (s < 2)
|
|
75
|
-
return r.includeSeconds ?
|
|
75
|
+
return r.includeSeconds ? c < 5 ? t.formatDistance("lessThanXSeconds", 5, n) : c < 10 ? t.formatDistance("lessThanXSeconds", 10, n) : c < 20 ? t.formatDistance("lessThanXSeconds", 20, n) : c < 40 ? t.formatDistance("halfAMinute", null, n) : c < 60 ? t.formatDistance("lessThanXMinutes", 1, n) : t.formatDistance("xMinutes", 1, n) : s === 0 ? t.formatDistance("lessThanXMinutes", 1, n) : t.formatDistance("xMinutes", s, n);
|
|
76
76
|
if (s < 45)
|
|
77
77
|
return t.formatDistance("xMinutes", s, n);
|
|
78
78
|
if (s < 90)
|
|
79
79
|
return t.formatDistance("aboutXHours", 1, n);
|
|
80
|
-
if (s <
|
|
81
|
-
var
|
|
82
|
-
return t.formatDistance("aboutXHours",
|
|
80
|
+
if (s < U) {
|
|
81
|
+
var w = Math.round(s / 60);
|
|
82
|
+
return t.formatDistance("aboutXHours", w, n);
|
|
83
83
|
} else {
|
|
84
84
|
if (s < se)
|
|
85
85
|
return t.formatDistance("xDays", 1, n);
|
|
86
|
-
if (s <
|
|
87
|
-
var H = Math.round(s /
|
|
86
|
+
if (s < D) {
|
|
87
|
+
var H = Math.round(s / U);
|
|
88
88
|
return t.formatDistance("xDays", H, n);
|
|
89
89
|
} else if (s < ie)
|
|
90
|
-
return d = Math.round(s /
|
|
90
|
+
return d = Math.round(s / D), t.formatDistance("aboutXMonths", d, n);
|
|
91
91
|
}
|
|
92
92
|
if (d = re(u, o), d < 12) {
|
|
93
|
-
var
|
|
94
|
-
return t.formatDistance("xMonths",
|
|
93
|
+
var Y = Math.round(s / D);
|
|
94
|
+
return t.formatDistance("xMonths", Y, n);
|
|
95
95
|
} else {
|
|
96
|
-
var
|
|
97
|
-
return
|
|
96
|
+
var y = d % 12, g = Math.floor(d / 12);
|
|
97
|
+
return y < 3 ? t.formatDistance("aboutXYears", g, n) : y < 9 ? t.formatDistance("overXYears", g, n) : t.formatDistance("almostXYears", g + 1, n);
|
|
98
98
|
}
|
|
99
99
|
}
|
|
100
100
|
function ue(e, a) {
|
|
101
|
-
return
|
|
101
|
+
return f(1, arguments), le(e, Date.now(), a);
|
|
102
102
|
}
|
|
103
103
|
var m = /* @__PURE__ */ ((e) => (e.PAGE = "page", e.COMPONENT = "component", e))(m || {});
|
|
104
|
-
const
|
|
104
|
+
const X = {
|
|
105
105
|
"en-US": {
|
|
106
106
|
lastUpdated: "Last updated: {date} ago"
|
|
107
107
|
}
|
|
108
|
-
},
|
|
109
|
-
i18n: { messages:
|
|
108
|
+
}, ce = C({
|
|
109
|
+
i18n: { messages: X },
|
|
110
110
|
name: "bento-header",
|
|
111
111
|
components: {
|
|
112
|
-
BentoTypography:
|
|
112
|
+
BentoTypography: V,
|
|
113
113
|
BentoButtonActions: J,
|
|
114
114
|
BentoInfoIcon: G
|
|
115
115
|
},
|
|
@@ -144,12 +144,12 @@ const x = {
|
|
|
144
144
|
lastUpdated: { type: [Date, Number], default: null }
|
|
145
145
|
},
|
|
146
146
|
setup(e, { slots: a }) {
|
|
147
|
-
const { t: r, locale: t } = F({ messages:
|
|
148
|
-
el: e.variant === m.PAGE ?
|
|
149
|
-
variant:
|
|
147
|
+
const { t: r, locale: t } = F({ messages: X }), l = { de: q, enUS: b, fr: z }, n = I(() => ({
|
|
148
|
+
el: e.variant === m.PAGE ? O.H1 : O.H2,
|
|
149
|
+
variant: $.TITLE,
|
|
150
150
|
medium: e.variant === m.COMPONENT,
|
|
151
151
|
large: e.variant === m.PAGE
|
|
152
|
-
})), o =
|
|
152
|
+
})), o = I(
|
|
153
153
|
() => e.lastUpdated ? r("lastUpdated", {
|
|
154
154
|
date: ue(e.lastUpdated, {
|
|
155
155
|
locale: l[t.value.substring(0, 2)] || b
|
|
@@ -159,22 +159,20 @@ const x = {
|
|
|
159
159
|
return {
|
|
160
160
|
hasSlot: L(a),
|
|
161
161
|
timestamp: o,
|
|
162
|
-
typography: n
|
|
163
|
-
BentoTypographyElement: D,
|
|
164
|
-
BentoTypographyVariant: A
|
|
162
|
+
typography: n
|
|
165
163
|
};
|
|
166
164
|
}
|
|
167
165
|
});
|
|
168
|
-
const
|
|
166
|
+
const fe = { class: "b-header" }, de = { class: "b-header__wrapper" }, me = { class: "b-header__title" };
|
|
169
167
|
function pe(e, a, r, t, l, n) {
|
|
170
|
-
const o = v("bento-typography"), u = v("bento-info-icon"),
|
|
171
|
-
return p(),
|
|
168
|
+
const o = v("bento-typography"), u = v("bento-info-icon"), c = v("bento-button-actions");
|
|
169
|
+
return p(), P("div", fe, [
|
|
172
170
|
_("div", de, [
|
|
173
171
|
_("div", me, [
|
|
174
172
|
_("div", null, [
|
|
175
|
-
|
|
176
|
-
default:
|
|
177
|
-
E(
|
|
173
|
+
R(o, k(e.typography, { class: "b-header__text" }), {
|
|
174
|
+
default: N(() => [
|
|
175
|
+
S(E(e.title), 1)
|
|
178
176
|
]),
|
|
179
177
|
_: 1
|
|
180
178
|
}, 16),
|
|
@@ -187,16 +185,16 @@ function pe(e, a, r, t, l, n) {
|
|
|
187
185
|
e.lastUpdated ? (p(), M(o, {
|
|
188
186
|
key: 0,
|
|
189
187
|
class: "b-header__timestamp",
|
|
190
|
-
el:
|
|
191
|
-
variant:
|
|
188
|
+
el: "div",
|
|
189
|
+
variant: "caption"
|
|
192
190
|
}, {
|
|
193
|
-
default:
|
|
194
|
-
E(
|
|
191
|
+
default: N(() => [
|
|
192
|
+
S(E(e.timestamp), 1)
|
|
195
193
|
]),
|
|
196
194
|
_: 1
|
|
197
|
-
}
|
|
195
|
+
})) : T("", !0)
|
|
198
196
|
]),
|
|
199
|
-
e.actions ? (p(), M(
|
|
197
|
+
e.actions ? (p(), M(c, {
|
|
200
198
|
key: 0,
|
|
201
199
|
actions: e.actions,
|
|
202
200
|
class: "b-header__actions"
|
|
@@ -204,7 +202,7 @@ function pe(e, a, r, t, l, n) {
|
|
|
204
202
|
])
|
|
205
203
|
]);
|
|
206
204
|
}
|
|
207
|
-
const Ne = /* @__PURE__ */ K(
|
|
205
|
+
const Ne = /* @__PURE__ */ K(ce, [["render", pe], ["__scopeId", "data-v-d3bc6768"]]);
|
|
208
206
|
export {
|
|
209
207
|
Ne as BentoHeader
|
|
210
208
|
};
|