@adyen/bento-vue2 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 -51
- package/dist/@types/packages/vue2/src/components/accordion/components/accordion-item.vue.d.ts +24 -28
- 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 +161 -150
- 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 +77 -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 +4 -6
- package/dist/@types/packages/vue2/src/components/checkbox/components/checkbox-group/checkbox-group.vue.d.ts +4 -4
- 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 +36 -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 +2 -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 +326 -14
- 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 +1 -21
- 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 +1 -21
- 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 +277 -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-avatar/dropdown-avatar.vue.d.ts +5 -5
- 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 +5 -6
- 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-currency/dropdown-currency.vue.d.ts +5 -5
- 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-payment-method/dropdown-payment-method.vue.d.ts +5 -5
- 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/components/variants/dropdown-tag/dropdown-tag.vue.d.ts +6 -6
- 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 +0 -26
- 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-range-filter/date-range-filter.vue.d.ts +0 -10
- package/dist/@types/packages/vue2/src/components/filter-bar/components/{base-filter/components/filter-bar-filter-button/filter-bar-filter-button.vue.d.ts → filter-bar-button/filter-bar-button.vue.d.ts} +17 -22
- 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/variants/select-country-filter/select-country-filter.vue.d.ts +2 -4
- package/dist/@types/packages/vue2/src/components/filter-bar/components/select-filter/variants/select-tag-filter/select-tag-filter.vue.d.ts +2 -4
- 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 +3 -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 +50 -47
- 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/__test__/calendar-month-day-stub.vue.d.ts +1 -1
- 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/controls-group/controls-group.vue.d.ts +1 -1
- 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 -4
- package/dist/@types/packages/vue2/src/components/search-bar/search-bar.vue.d.ts +16 -339
- 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 +4 -7
- package/dist/@types/packages/vue2/src/components/textarea/textarea.vue.d.ts +5 -9
- package/dist/@types/packages/vue2/src/components/timeline/components/timeline-item/timeline-item.vue.d.ts +6 -12
- 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 +4 -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/print-development-warning.d.ts +1 -0
- package/dist/accordion.js +69 -177
- package/dist/accordion.js.map +1 -1
- package/dist/alert.js +57 -60
- 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/index23.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 -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 +110 -12
- package/dist/button.js.map +1 -1
- package/dist/card.js +66 -67
- package/dist/card.js.map +1 -1
- package/dist/checkbox.js +27 -26
- package/dist/checkbox.js.map +1 -1
- package/dist/chunks/{base-button.98379576.js → base-button.bd8fa976.js} +24 -27
- package/dist/chunks/base-button.bd8fa976.js.map +1 -0
- package/dist/chunks/base-modal.a365f260.js +207 -0
- package/dist/chunks/base-modal.a365f260.js.map +1 -0
- package/dist/chunks/{button.d0c9527d.js → button.fb307df3.js} +36 -39
- package/dist/chunks/button.fb307df3.js.map +1 -0
- package/dist/chunks/{calendar.0ae43a96.js → calendar.79ea42c1.js} +214 -217
- package/dist/chunks/calendar.79ea42c1.js.map +1 -0
- package/dist/chunks/checkbox.c7d791ed.js +173 -0
- package/dist/chunks/checkbox.c7d791ed.js.map +1 -0
- package/dist/chunks/{chevron-down.b851a6da.js → chevron-up.674ec2e5.js} +8 -8
- package/dist/chunks/chevron-up.674ec2e5.js.map +1 -0
- package/dist/chunks/{controls-group.b827382b.js → controls-group.5d3e04dd.js} +20 -20
- package/dist/chunks/controls-group.5d3e04dd.js.map +1 -0
- package/dist/chunks/{copy.5a4cbd4d.js → copy.ac796536.js} +37 -38
- package/dist/chunks/copy.ac796536.js.map +1 -0
- package/dist/chunks/{dropdown-default-textbox.819e43f7.js → dropdown-default-textbox.109c36d2.js} +38 -40
- package/dist/chunks/dropdown-default-textbox.109c36d2.js.map +1 -0
- package/dist/chunks/{dropdown.c05678d0.js → dropdown.fd93f0ce.js} +351 -335
- package/dist/chunks/dropdown.fd93f0ce.js.map +1 -0
- package/dist/chunks/error-message.3b3c33d4.js +47 -0
- package/dist/chunks/error-message.3b3c33d4.js.map +1 -0
- package/dist/chunks/{footer-actions.67642347.js → footer-actions.f02e8699.js} +23 -23
- package/dist/chunks/footer-actions.f02e8699.js.map +1 -0
- package/dist/chunks/get-slot-text.c1114034.js +9 -0
- package/dist/chunks/get-slot-text.c1114034.js.map +1 -0
- package/dist/chunks/{grid-layout.73f23b1b.js → grid-layout.b7e0d964.js} +2 -2
- package/dist/chunks/{grid-layout.73f23b1b.js.map → grid-layout.b7e0d964.js.map} +1 -1
- package/dist/chunks/{index.56858f4e.js → index.45295dd3.js} +23 -19
- package/dist/chunks/index.45295dd3.js.map +1 -0
- package/dist/chunks/{index.10aaf539.js → index.88ff49c2.js} +136 -142
- package/dist/chunks/index.88ff49c2.js.map +1 -0
- package/dist/chunks/{index.73d50fa6.js → index.9902cae4.js} +65 -68
- package/dist/chunks/{index.73d50fa6.js.map → index.9902cae4.js.map} +1 -1
- package/dist/chunks/{index.0cf00b47.js → index.bd734551.js} +35 -37
- package/dist/chunks/index.bd734551.js.map +1 -0
- package/dist/chunks/{index.133e4da0.js → index.c85a1ab9.js} +81 -79
- package/dist/chunks/{index.133e4da0.js.map → index.c85a1ab9.js.map} +1 -1
- package/dist/chunks/{index.f0f8ed98.js → index.c8f81673.js} +23 -26
- package/dist/chunks/index.c8f81673.js.map +1 -0
- package/dist/chunks/{listbox-option-tag.8d6cccac.js → listbox-option-tag.ec42431b.js} +32 -36
- package/dist/chunks/listbox-option-tag.ec42431b.js.map +1 -0
- package/dist/chunks/{listbox.116ed0c1.js → listbox.e792d2d6.js} +244 -251
- package/dist/chunks/listbox.e792d2d6.js.map +1 -0
- package/dist/chunks/loading-button.429c8416.js +86 -0
- package/dist/chunks/loading-button.429c8416.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.2aff4fa6.js → tooltip.a47ace87.js} +49 -52
- package/dist/chunks/tooltip.a47ace87.js.map +1 -0
- package/dist/chunks/use-default-slot-validator.cbdfe693.js +13 -0
- package/dist/chunks/use-default-slot-validator.cbdfe693.js.map +1 -0
- package/dist/chunks/use-has-slot.6052d56a.js +6 -0
- package/dist/chunks/use-has-slot.6052d56a.js.map +1 -0
- package/dist/code-snippet.js +469 -413
- package/dist/code-snippet.js.map +1 -1
- package/dist/country.js +492 -494
- package/dist/country.js.map +1 -1
- package/dist/currency.js +32 -35
- package/dist/currency.js.map +1 -1
- package/dist/data-grid.js +595 -603
- package/dist/data-grid.js.map +1 -1
- package/dist/date-picker.js +76 -80
- package/dist/date-picker.js.map +1 -1
- package/dist/date-range-picker.js +2 -2
- package/dist/date.js +1 -1
- package/dist/divider.js +1 -1
- package/dist/dropdown.js +37 -39
- package/dist/dropdown.js.map +1 -1
- package/dist/empty-state.js +134 -0
- package/dist/empty-state.js.map +1 -0
- package/dist/filter-bar.js +648 -638
- package/dist/filter-bar.js.map +1 -1
- package/dist/focus-trap.js +1 -1
- package/dist/form-layout.js +64 -64
- package/dist/form-layout.js.map +1 -1
- package/dist/header.js +61 -63
- package/dist/header.js.map +1 -1
- package/dist/image.js +82 -0
- package/dist/image.js.map +1 -0
- package/dist/index.js +216 -205
- package/dist/index.js.map +1 -1
- package/dist/info-icon.js +2 -2
- package/dist/input-field.js +99 -123
- package/dist/input-field.js.map +1 -1
- package/dist/internal.js +7 -7
- package/dist/link.js +27 -26
- package/dist/link.js.map +1 -1
- package/dist/loading-indicator.js +1 -1
- package/dist/menu.js +96 -104
- package/dist/menu.js.map +1 -1
- package/dist/modal.js +111 -264
- package/dist/modal.js.map +1 -1
- package/dist/pagination.js +148 -145
- package/dist/pagination.js.map +1 -1
- package/dist/payment-method.js +16 -18
- package/dist/payment-method.js.map +1 -1
- package/dist/popover.js +58 -54
- package/dist/popover.js.map +1 -1
- package/dist/popper-container.js +13 -17
- package/dist/popper-container.js.map +1 -1
- package/dist/radio-group.js +71 -72
- package/dist/radio-group.js.map +1 -1
- package/dist/search-bar.js +54 -66
- package/dist/search-bar.js.map +1 -1
- package/dist/segmented-control.js +68 -55
- package/dist/segmented-control.js.map +1 -1
- package/dist/sidepanel.js +65 -64
- package/dist/sidepanel.js.map +1 -1
- package/dist/status.js +20 -23
- package/dist/status.js.map +1 -1
- package/dist/structured-list.js +1 -1
- package/dist/summary-grid.js +110 -141
- package/dist/summary-grid.js.map +1 -1
- package/dist/tabs.js +68 -60
- package/dist/tabs.js.map +1 -1
- package/dist/tag.js +23 -26
- package/dist/tag.js.map +1 -1
- package/dist/textarea.js +97 -96
- package/dist/textarea.js.map +1 -1
- package/dist/timeline.js +125 -125
- package/dist/timeline.js.map +1 -1
- package/dist/toast.js +44 -48
- package/dist/toast.js.map +1 -1
- package/dist/toggle.js +54 -52
- package/dist/toggle.js.map +1 -1
- package/dist/typography.js +1 -1
- package/dist/web-types.json +651 -397
- package/package.json +9 -12
- 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/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.98379576.js.map +0 -1
- package/dist/chunks/button-actions.bd397c79.js +0 -104
- package/dist/chunks/button-actions.bd397c79.js.map +0 -1
- package/dist/chunks/button.d0c9527d.js.map +0 -1
- package/dist/chunks/calendar.0ae43a96.js.map +0 -1
- package/dist/chunks/checkbox.f8457c93.js +0 -164
- package/dist/chunks/checkbox.f8457c93.js.map +0 -1
- package/dist/chunks/chevron-down.b851a6da.js.map +0 -1
- package/dist/chunks/controls-group.b827382b.js.map +0 -1
- package/dist/chunks/copy.5a4cbd4d.js.map +0 -1
- package/dist/chunks/dropdown-default-textbox.819e43f7.js.map +0 -1
- package/dist/chunks/dropdown.c05678d0.js.map +0 -1
- package/dist/chunks/error-message.0433b539.js +0 -47
- package/dist/chunks/error-message.0433b539.js.map +0 -1
- package/dist/chunks/footer-actions.67642347.js.map +0 -1
- package/dist/chunks/get-slot-text.e5c766d0.js +0 -9
- package/dist/chunks/get-slot-text.e5c766d0.js.map +0 -1
- package/dist/chunks/index.0cf00b47.js.map +0 -1
- package/dist/chunks/index.10aaf539.js.map +0 -1
- package/dist/chunks/index.56858f4e.js.map +0 -1
- package/dist/chunks/index.f0f8ed98.js.map +0 -1
- package/dist/chunks/listbox-option-tag.8d6cccac.js.map +0 -1
- package/dist/chunks/listbox.116ed0c1.js.map +0 -1
- package/dist/chunks/loading-button.1c201f87.js +0 -84
- package/dist/chunks/loading-button.1c201f87.js.map +0 -1
- package/dist/chunks/tooltip.2aff4fa6.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/code-snippet.js
CHANGED
|
@@ -1,28 +1,30 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { highlightActiveLine as
|
|
3
|
-
import { Compartment as
|
|
4
|
-
import { indentWithTab as
|
|
5
|
-
import { syntaxHighlighting as
|
|
6
|
-
import { json as
|
|
7
|
-
import { xml as
|
|
8
|
-
import { javascript as
|
|
9
|
-
import { java as
|
|
10
|
-
import { B as
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import { n as
|
|
17
|
-
import "./
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
1
|
+
import { defineComponent as Ve, ref as ae, computed as re, shallowRef as Ae, onMounted as $e, watch as De, watchEffect as Je } from "vue";
|
|
2
|
+
import { highlightActiveLine as Ue, keymap as We, EditorView as Ie, lineNumbers as Ge } from "@codemirror/view";
|
|
3
|
+
import { Compartment as be, EditorState as Le } from "@codemirror/state";
|
|
4
|
+
import { indentWithTab as Ke, history as Fe } from "@codemirror/commands";
|
|
5
|
+
import { syntaxHighlighting as qe, HighlightStyle as Xe } from "@codemirror/language";
|
|
6
|
+
import { json as Ze } from "@codemirror/lang-json";
|
|
7
|
+
import { xml as Qe } from "@codemirror/lang-xml";
|
|
8
|
+
import { javascript as Ye } from "@codemirror/lang-javascript";
|
|
9
|
+
import { java as et } from "@codemirror/lang-java";
|
|
10
|
+
import { B as tt } from "./chunks/dropdown.fd93f0ce.js";
|
|
11
|
+
import { f as nt } from "./chunks/base-modal.a365f260.js";
|
|
12
|
+
import { a as rt } from "./chunks/button.fb307df3.js";
|
|
13
|
+
import { B as it } from "./chunks/index.45295dd3.js";
|
|
14
|
+
import { BentoLoadingIndicator as st } from "./loading-indicator.js";
|
|
15
|
+
import { u as lt } from "./chunks/i18n.155748d6.js";
|
|
16
|
+
import { n as Te } from "./chunks/_plugin-vue2_normalizer.71e2aa87.js";
|
|
17
|
+
import { C as ot } from "./chunks/copy.ac796536.js";
|
|
18
|
+
import { b as at } from "./chunks/tooltip.a47ace87.js";
|
|
19
|
+
import "./assets/index10.css";
|
|
20
|
+
const ft = 1024;
|
|
21
|
+
let ut = 0;
|
|
22
|
+
class v {
|
|
21
23
|
/**
|
|
22
24
|
Create a new node prop type.
|
|
23
25
|
*/
|
|
24
26
|
constructor(e = {}) {
|
|
25
|
-
this.id =
|
|
27
|
+
this.id = ut++, this.perNode = !!e.perNode, this.deserialize = e.deserialize || (() => {
|
|
26
28
|
throw new Error("This node type doesn't define a deserialize function");
|
|
27
29
|
});
|
|
28
30
|
}
|
|
@@ -38,24 +40,24 @@ class _ {
|
|
|
38
40
|
add(e) {
|
|
39
41
|
if (this.perNode)
|
|
40
42
|
throw new RangeError("Can't add per-node props to node types");
|
|
41
|
-
return typeof e != "function" && (e =
|
|
43
|
+
return typeof e != "function" && (e = W.match(e)), (t) => {
|
|
42
44
|
let n = e(t);
|
|
43
45
|
return n === void 0 ? null : [this, n];
|
|
44
46
|
};
|
|
45
47
|
}
|
|
46
48
|
}
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
49
|
+
v.closedBy = new v({ deserialize: (i) => i.split(" ") });
|
|
50
|
+
v.openedBy = new v({ deserialize: (i) => i.split(" ") });
|
|
51
|
+
v.group = new v({ deserialize: (i) => i.split(" ") });
|
|
52
|
+
v.isolate = new v({ deserialize: (i) => {
|
|
51
53
|
if (i && i != "rtl" && i != "ltr" && i != "auto")
|
|
52
54
|
throw new RangeError("Invalid value for isolate: " + i);
|
|
53
55
|
return i || "auto";
|
|
54
56
|
} });
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
class
|
|
57
|
+
v.contextHash = new v({ perNode: !0 });
|
|
58
|
+
v.lookAhead = new v({ perNode: !0 });
|
|
59
|
+
v.mounted = new v({ perNode: !0 });
|
|
60
|
+
class ge {
|
|
59
61
|
constructor(e, t, n) {
|
|
60
62
|
this.tree = e, this.overlay = t, this.parser = n;
|
|
61
63
|
}
|
|
@@ -63,11 +65,11 @@ class ce {
|
|
|
63
65
|
@internal
|
|
64
66
|
*/
|
|
65
67
|
static get(e) {
|
|
66
|
-
return e && e.props && e.props[
|
|
68
|
+
return e && e.props && e.props[v.mounted.id];
|
|
67
69
|
}
|
|
68
70
|
}
|
|
69
71
|
const ht = /* @__PURE__ */ Object.create(null);
|
|
70
|
-
class
|
|
72
|
+
class W {
|
|
71
73
|
/**
|
|
72
74
|
@internal
|
|
73
75
|
*/
|
|
@@ -78,7 +80,7 @@ class V {
|
|
|
78
80
|
Define a node type.
|
|
79
81
|
*/
|
|
80
82
|
static define(e) {
|
|
81
|
-
let t = e.props && e.props.length ? /* @__PURE__ */ Object.create(null) : ht, n = (e.top ? 1 : 0) | (e.skipped ? 2 : 0) | (e.error ? 4 : 0) | (e.name == null ? 8 : 0), r = new
|
|
83
|
+
let t = e.props && e.props.length ? /* @__PURE__ */ Object.create(null) : ht, n = (e.top ? 1 : 0) | (e.skipped ? 2 : 0) | (e.error ? 4 : 0) | (e.name == null ? 8 : 0), r = new W(e.name || "", t, e.id, n);
|
|
82
84
|
if (e.props) {
|
|
83
85
|
for (let s of e.props)
|
|
84
86
|
if (Array.isArray(s) || (s = s(r)), s) {
|
|
@@ -129,7 +131,7 @@ class V {
|
|
|
129
131
|
if (typeof e == "string") {
|
|
130
132
|
if (this.name == e)
|
|
131
133
|
return !0;
|
|
132
|
-
let t = this.prop(
|
|
134
|
+
let t = this.prop(v.group);
|
|
133
135
|
return t ? t.indexOf(e) > -1 : !1;
|
|
134
136
|
}
|
|
135
137
|
return this.id == e;
|
|
@@ -148,7 +150,7 @@ class V {
|
|
|
148
150
|
for (let r of n.split(" "))
|
|
149
151
|
t[r] = e[n];
|
|
150
152
|
return (n) => {
|
|
151
|
-
for (let r = n.prop(
|
|
153
|
+
for (let r = n.prop(v.group), s = -1; s < (r ? r.length : 0); s++) {
|
|
152
154
|
let l = t[s < 0 ? n.name : r[s]];
|
|
153
155
|
if (l)
|
|
154
156
|
return l;
|
|
@@ -156,34 +158,34 @@ class V {
|
|
|
156
158
|
};
|
|
157
159
|
}
|
|
158
160
|
}
|
|
159
|
-
|
|
161
|
+
W.none = new W(
|
|
160
162
|
"",
|
|
161
163
|
/* @__PURE__ */ Object.create(null),
|
|
162
164
|
0,
|
|
163
165
|
8
|
|
164
166
|
/* NodeFlag.Anonymous */
|
|
165
167
|
);
|
|
166
|
-
const
|
|
168
|
+
const fe = /* @__PURE__ */ new WeakMap(), Be = /* @__PURE__ */ new WeakMap();
|
|
167
169
|
var S;
|
|
168
170
|
(function(i) {
|
|
169
171
|
i[i.ExcludeBuffers = 1] = "ExcludeBuffers", i[i.IncludeAnonymous = 2] = "IncludeAnonymous", i[i.IgnoreMounts = 4] = "IgnoreMounts", i[i.IgnoreOverlays = 8] = "IgnoreOverlays";
|
|
170
172
|
})(S || (S = {}));
|
|
171
|
-
class
|
|
173
|
+
class R {
|
|
172
174
|
/**
|
|
173
175
|
Construct a new tree. See also [`Tree.build`](#common.Tree^build).
|
|
174
176
|
*/
|
|
175
177
|
constructor(e, t, n, r, s) {
|
|
176
178
|
if (this.type = e, this.children = t, this.positions = n, this.length = r, this.props = null, s && s.length) {
|
|
177
179
|
this.props = /* @__PURE__ */ Object.create(null);
|
|
178
|
-
for (let [l,
|
|
179
|
-
this.props[typeof l == "number" ? l : l.id] =
|
|
180
|
+
for (let [l, f] of s)
|
|
181
|
+
this.props[typeof l == "number" ? l : l.id] = f;
|
|
180
182
|
}
|
|
181
183
|
}
|
|
182
184
|
/**
|
|
183
185
|
@internal
|
|
184
186
|
*/
|
|
185
187
|
toString() {
|
|
186
|
-
let e =
|
|
188
|
+
let e = ge.get(this);
|
|
187
189
|
if (e && !e.overlay)
|
|
188
190
|
return e.tree.toString();
|
|
189
191
|
let t = "";
|
|
@@ -199,7 +201,7 @@ class J {
|
|
|
199
201
|
nodes the cursor visits.
|
|
200
202
|
*/
|
|
201
203
|
cursor(e = 0) {
|
|
202
|
-
return new
|
|
204
|
+
return new _e(this.topNode, e);
|
|
203
205
|
}
|
|
204
206
|
/**
|
|
205
207
|
Get a [tree cursor](#common.TreeCursor) pointing into this tree
|
|
@@ -207,15 +209,15 @@ class J {
|
|
|
207
209
|
[`moveTo`](#common.TreeCursor.moveTo).
|
|
208
210
|
*/
|
|
209
211
|
cursorAt(e, t = 0, n = 0) {
|
|
210
|
-
let r =
|
|
211
|
-
return s.moveTo(e, t),
|
|
212
|
+
let r = fe.get(this) || this.topNode, s = new _e(r);
|
|
213
|
+
return s.moveTo(e, t), fe.set(this, s._tree), s;
|
|
212
214
|
}
|
|
213
215
|
/**
|
|
214
216
|
Get a [syntax node](#common.SyntaxNode) object for the top of the
|
|
215
217
|
tree.
|
|
216
218
|
*/
|
|
217
219
|
get topNode() {
|
|
218
|
-
return new
|
|
220
|
+
return new O(this, 0, 0, null);
|
|
219
221
|
}
|
|
220
222
|
/**
|
|
221
223
|
Get the [syntax node](#common.SyntaxNode) at the given position.
|
|
@@ -229,8 +231,8 @@ class J {
|
|
|
229
231
|
[`resolveInner`](#common.Tree.resolveInner) instead.
|
|
230
232
|
*/
|
|
231
233
|
resolve(e, t = 0) {
|
|
232
|
-
let n =
|
|
233
|
-
return
|
|
234
|
+
let n = le(fe.get(this) || this.topNode, e, t, !1);
|
|
235
|
+
return fe.set(this, n), n;
|
|
234
236
|
}
|
|
235
237
|
/**
|
|
236
238
|
Like [`resolve`](#common.Tree.resolve), but will enter
|
|
@@ -240,8 +242,8 @@ class J {
|
|
|
240
242
|
the host trees).
|
|
241
243
|
*/
|
|
242
244
|
resolveInner(e, t = 0) {
|
|
243
|
-
let n =
|
|
244
|
-
return
|
|
245
|
+
let n = le(Be.get(this) || this.topNode, e, t, !0);
|
|
246
|
+
return Be.set(this, n), n;
|
|
245
247
|
}
|
|
246
248
|
/**
|
|
247
249
|
In some situations, it can be useful to iterate through all
|
|
@@ -251,7 +253,7 @@ class J {
|
|
|
251
253
|
position.
|
|
252
254
|
*/
|
|
253
255
|
resolveStack(e, t = 0) {
|
|
254
|
-
return
|
|
256
|
+
return pt(this, e, t);
|
|
255
257
|
}
|
|
256
258
|
/**
|
|
257
259
|
Iterate over the tree and its children, calling `enter` for any
|
|
@@ -261,18 +263,18 @@ class J {
|
|
|
261
263
|
not have its children iterated over (or `leave` called).
|
|
262
264
|
*/
|
|
263
265
|
iterate(e) {
|
|
264
|
-
let { enter: t, leave: n, from: r = 0, to: s = this.length } = e, l = e.mode || 0,
|
|
265
|
-
for (let
|
|
266
|
-
let
|
|
267
|
-
if (
|
|
268
|
-
if (
|
|
266
|
+
let { enter: t, leave: n, from: r = 0, to: s = this.length } = e, l = e.mode || 0, f = (l & S.IncludeAnonymous) > 0;
|
|
267
|
+
for (let h = this.cursor(l | S.IncludeAnonymous); ; ) {
|
|
268
|
+
let C = !1;
|
|
269
|
+
if (h.from <= s && h.to >= r && (!f && h.type.isAnonymous || t(h) !== !1)) {
|
|
270
|
+
if (h.firstChild())
|
|
269
271
|
continue;
|
|
270
|
-
|
|
272
|
+
C = !0;
|
|
271
273
|
}
|
|
272
|
-
for (;
|
|
273
|
-
if (!
|
|
274
|
+
for (; C && n && (f || !h.type.isAnonymous) && n(h), !h.nextSibling(); ) {
|
|
275
|
+
if (!h.parent())
|
|
274
276
|
return;
|
|
275
|
-
|
|
277
|
+
C = !0;
|
|
276
278
|
}
|
|
277
279
|
}
|
|
278
280
|
}
|
|
@@ -301,18 +303,18 @@ class J {
|
|
|
301
303
|
[`NodeType.none`](#common.NodeType^none).
|
|
302
304
|
*/
|
|
303
305
|
balance(e = {}) {
|
|
304
|
-
return this.children.length <= 8 ? this : we(
|
|
306
|
+
return this.children.length <= 8 ? this : we(W.none, this.children, this.positions, 0, this.children.length, 0, this.length, (t, n, r) => new R(this.type, t, n, r, this.propValues), e.makeTree || ((t, n, r) => new R(W.none, t, n, r)));
|
|
305
307
|
}
|
|
306
308
|
/**
|
|
307
309
|
Build a tree from a postfix-ordered buffer of node information,
|
|
308
310
|
or a cursor over such a buffer.
|
|
309
311
|
*/
|
|
310
312
|
static build(e) {
|
|
311
|
-
return
|
|
313
|
+
return gt(e);
|
|
312
314
|
}
|
|
313
315
|
}
|
|
314
|
-
|
|
315
|
-
class
|
|
316
|
+
R.empty = new R(W.none, [], [], 0);
|
|
317
|
+
class Ce {
|
|
316
318
|
constructor(e, t) {
|
|
317
319
|
this.buffer = e, this.index = t;
|
|
318
320
|
}
|
|
@@ -335,10 +337,10 @@ class _e {
|
|
|
335
337
|
this.index -= 4;
|
|
336
338
|
}
|
|
337
339
|
fork() {
|
|
338
|
-
return new
|
|
340
|
+
return new Ce(this.buffer, this.index);
|
|
339
341
|
}
|
|
340
342
|
}
|
|
341
|
-
class
|
|
343
|
+
class q {
|
|
342
344
|
/**
|
|
343
345
|
Create a tree buffer.
|
|
344
346
|
*/
|
|
@@ -349,7 +351,7 @@ class G {
|
|
|
349
351
|
@internal
|
|
350
352
|
*/
|
|
351
353
|
get type() {
|
|
352
|
-
return
|
|
354
|
+
return W.none;
|
|
353
355
|
}
|
|
354
356
|
/**
|
|
355
357
|
@internal
|
|
@@ -376,25 +378,25 @@ class G {
|
|
|
376
378
|
@internal
|
|
377
379
|
*/
|
|
378
380
|
findChild(e, t, n, r, s) {
|
|
379
|
-
let { buffer: l } = this,
|
|
380
|
-
for (let
|
|
381
|
+
let { buffer: l } = this, f = -1;
|
|
382
|
+
for (let h = e; h != t && !(je(s, r, l[h + 1], l[h + 2]) && (f = h, n > 0)); h = l[h + 3])
|
|
381
383
|
;
|
|
382
|
-
return
|
|
384
|
+
return f;
|
|
383
385
|
}
|
|
384
386
|
/**
|
|
385
387
|
@internal
|
|
386
388
|
*/
|
|
387
389
|
slice(e, t, n) {
|
|
388
390
|
let r = this.buffer, s = new Uint16Array(t - e), l = 0;
|
|
389
|
-
for (let
|
|
390
|
-
s[
|
|
391
|
-
let
|
|
392
|
-
s[
|
|
391
|
+
for (let f = e, h = 0; f < t; ) {
|
|
392
|
+
s[h++] = r[f++], s[h++] = r[f++] - n;
|
|
393
|
+
let C = s[h++] = r[f++] - n;
|
|
394
|
+
s[h++] = r[f++] - e, l = Math.max(l, C);
|
|
393
395
|
}
|
|
394
|
-
return new
|
|
396
|
+
return new q(s, l, this.set);
|
|
395
397
|
}
|
|
396
398
|
}
|
|
397
|
-
function
|
|
399
|
+
function je(i, e, t, n) {
|
|
398
400
|
switch (i) {
|
|
399
401
|
case -2:
|
|
400
402
|
return t < e;
|
|
@@ -410,17 +412,17 @@ function Te(i, e, t, n) {
|
|
|
410
412
|
return !0;
|
|
411
413
|
}
|
|
412
414
|
}
|
|
413
|
-
function
|
|
415
|
+
function le(i, e, t, n) {
|
|
414
416
|
for (var r; i.from == i.to || (t < 1 ? i.from >= e : i.from > e) || (t > -1 ? i.to <= e : i.to < e); ) {
|
|
415
|
-
let l = !n && i instanceof
|
|
417
|
+
let l = !n && i instanceof O && i.index < 0 ? null : i.parent;
|
|
416
418
|
if (!l)
|
|
417
419
|
return i;
|
|
418
420
|
i = l;
|
|
419
421
|
}
|
|
420
422
|
let s = n ? 0 : S.IgnoreOverlays;
|
|
421
423
|
if (n)
|
|
422
|
-
for (let l = i,
|
|
423
|
-
l instanceof
|
|
424
|
+
for (let l = i, f = l.parent; f; l = f, f = l.parent)
|
|
425
|
+
l instanceof O && l.index < 0 && ((r = f.enter(e, t, s)) === null || r === void 0 ? void 0 : r.from) != l.from && (i = f);
|
|
424
426
|
for (; ; ) {
|
|
425
427
|
let l = i.enter(e, t, s);
|
|
426
428
|
if (!l)
|
|
@@ -428,9 +430,9 @@ function se(i, e, t, n) {
|
|
|
428
430
|
i = l;
|
|
429
431
|
}
|
|
430
432
|
}
|
|
431
|
-
class
|
|
433
|
+
class He {
|
|
432
434
|
cursor(e = 0) {
|
|
433
|
-
return new
|
|
435
|
+
return new _e(this, e);
|
|
434
436
|
}
|
|
435
437
|
getChild(e, t = null, n = null) {
|
|
436
438
|
let r = Oe(this, e, t, n);
|
|
@@ -440,13 +442,13 @@ class je {
|
|
|
440
442
|
return Oe(this, e, t, n);
|
|
441
443
|
}
|
|
442
444
|
resolve(e, t = 0) {
|
|
443
|
-
return
|
|
445
|
+
return le(this, e, t, !1);
|
|
444
446
|
}
|
|
445
447
|
resolveInner(e, t = 0) {
|
|
446
|
-
return
|
|
448
|
+
return le(this, e, t, !0);
|
|
447
449
|
}
|
|
448
450
|
matchContext(e) {
|
|
449
|
-
return
|
|
451
|
+
return xe(this, e);
|
|
450
452
|
}
|
|
451
453
|
enterUnfinishedNodesBefore(e) {
|
|
452
454
|
let t = this.childBefore(e), n = this;
|
|
@@ -465,7 +467,7 @@ class je {
|
|
|
465
467
|
return this.parent;
|
|
466
468
|
}
|
|
467
469
|
}
|
|
468
|
-
class
|
|
470
|
+
class O extends He {
|
|
469
471
|
constructor(e, t, n, r) {
|
|
470
472
|
super(), this._tree = e, this.from = t, this.index = n, this._parent = r;
|
|
471
473
|
}
|
|
@@ -480,21 +482,21 @@ class z extends je {
|
|
|
480
482
|
}
|
|
481
483
|
nextChild(e, t, n, r, s = 0) {
|
|
482
484
|
for (let l = this; ; ) {
|
|
483
|
-
for (let { children:
|
|
484
|
-
let
|
|
485
|
-
if (
|
|
486
|
-
if (
|
|
485
|
+
for (let { children: f, positions: h } = l._tree, C = t > 0 ? f.length : -1; e != C; e += t) {
|
|
486
|
+
let k = f[e], N = h[e] + l.from;
|
|
487
|
+
if (je(r, n, N, N + k.length)) {
|
|
488
|
+
if (k instanceof q) {
|
|
487
489
|
if (s & S.ExcludeBuffers)
|
|
488
490
|
continue;
|
|
489
|
-
let
|
|
490
|
-
if (
|
|
491
|
-
return new F(new
|
|
492
|
-
} else if (s & S.IncludeAnonymous || !
|
|
493
|
-
let
|
|
494
|
-
if (!(s & S.IgnoreMounts) && (
|
|
495
|
-
return new
|
|
496
|
-
let
|
|
497
|
-
return s & S.IncludeAnonymous || !
|
|
491
|
+
let A = k.findChild(0, k.buffer.length, t, n - N, r);
|
|
492
|
+
if (A > -1)
|
|
493
|
+
return new F(new ct(l, k, e, N), null, A);
|
|
494
|
+
} else if (s & S.IncludeAnonymous || !k.type.isAnonymous || ke(k)) {
|
|
495
|
+
let A;
|
|
496
|
+
if (!(s & S.IgnoreMounts) && (A = ge.get(k)) && !A.overlay)
|
|
497
|
+
return new O(A.tree, N, e, l);
|
|
498
|
+
let z = new O(k, N, e, l);
|
|
499
|
+
return s & S.IncludeAnonymous || !z.type.isAnonymous ? z : z.nextChild(t < 0 ? k.children.length - 1 : 0, t, n, r);
|
|
498
500
|
}
|
|
499
501
|
}
|
|
500
502
|
}
|
|
@@ -540,11 +542,11 @@ class z extends je {
|
|
|
540
542
|
}
|
|
541
543
|
enter(e, t, n = 0) {
|
|
542
544
|
let r;
|
|
543
|
-
if (!(n & S.IgnoreOverlays) && (r =
|
|
545
|
+
if (!(n & S.IgnoreOverlays) && (r = ge.get(this._tree)) && r.overlay) {
|
|
544
546
|
let s = e - this.from;
|
|
545
|
-
for (let { from: l, to:
|
|
546
|
-
if ((t > 0 ? l <= s : l < s) && (t < 0 ?
|
|
547
|
-
return new
|
|
547
|
+
for (let { from: l, to: f } of r.overlay)
|
|
548
|
+
if ((t > 0 ? l <= s : l < s) && (t < 0 ? f >= s : f > s))
|
|
549
|
+
return new O(r.tree, r.overlay[0].from + this.from, -1, this);
|
|
548
550
|
}
|
|
549
551
|
return this.nextChild(0, 1, e, t, n);
|
|
550
552
|
}
|
|
@@ -604,7 +606,7 @@ function Oe(i, e, t, n) {
|
|
|
604
606
|
return n == null ? s : [];
|
|
605
607
|
}
|
|
606
608
|
}
|
|
607
|
-
function
|
|
609
|
+
function xe(i, e, t = e.length - 1) {
|
|
608
610
|
for (let n = i.parent; t >= 0; n = n.parent) {
|
|
609
611
|
if (!n)
|
|
610
612
|
return !1;
|
|
@@ -616,12 +618,12 @@ function ye(i, e, t = e.length - 1) {
|
|
|
616
618
|
}
|
|
617
619
|
return !0;
|
|
618
620
|
}
|
|
619
|
-
class
|
|
621
|
+
class ct {
|
|
620
622
|
constructor(e, t, n, r) {
|
|
621
623
|
this.parent = e, this.buffer = t, this.index = n, this.start = r;
|
|
622
624
|
}
|
|
623
625
|
}
|
|
624
|
-
class F extends
|
|
626
|
+
class F extends He {
|
|
625
627
|
get name() {
|
|
626
628
|
return this.type.name;
|
|
627
629
|
}
|
|
@@ -712,7 +714,7 @@ class F extends je {
|
|
|
712
714
|
let l = n.buffer[this.index + 1];
|
|
713
715
|
e.push(n.slice(r, s, l)), t.push(0);
|
|
714
716
|
}
|
|
715
|
-
return new
|
|
717
|
+
return new R(this.type, e, t, this.to - this.from);
|
|
716
718
|
}
|
|
717
719
|
/**
|
|
718
720
|
@internal
|
|
@@ -721,7 +723,7 @@ class F extends je {
|
|
|
721
723
|
return this.context.buffer.childString(this.index);
|
|
722
724
|
}
|
|
723
725
|
}
|
|
724
|
-
function
|
|
726
|
+
function Re(i) {
|
|
725
727
|
if (!i.length)
|
|
726
728
|
return null;
|
|
727
729
|
let e = 0, t = i[0];
|
|
@@ -729,33 +731,33 @@ function Me(i) {
|
|
|
729
731
|
let l = i[s];
|
|
730
732
|
(l.from > t.from || l.to < t.to) && (t = l, e = s);
|
|
731
733
|
}
|
|
732
|
-
let n = t instanceof
|
|
733
|
-
return n ? r[e] = n : r.splice(e, 1), new
|
|
734
|
+
let n = t instanceof O && t.index < 0 ? null : t.parent, r = i.slice();
|
|
735
|
+
return n ? r[e] = n : r.splice(e, 1), new dt(r, t);
|
|
734
736
|
}
|
|
735
|
-
class
|
|
737
|
+
class dt {
|
|
736
738
|
constructor(e, t) {
|
|
737
739
|
this.heads = e, this.node = t;
|
|
738
740
|
}
|
|
739
741
|
get next() {
|
|
740
|
-
return
|
|
742
|
+
return Re(this.heads);
|
|
741
743
|
}
|
|
742
744
|
}
|
|
743
|
-
function
|
|
745
|
+
function pt(i, e, t) {
|
|
744
746
|
let n = i.resolveInner(e, t), r = null;
|
|
745
|
-
for (let s = n instanceof
|
|
747
|
+
for (let s = n instanceof O ? n : n.context.parent; s; s = s.parent)
|
|
746
748
|
if (s.index < 0) {
|
|
747
749
|
let l = s.parent;
|
|
748
750
|
(r || (r = [n])).push(l.resolve(e, t)), s = l;
|
|
749
751
|
} else {
|
|
750
|
-
let l =
|
|
752
|
+
let l = ge.get(s.tree);
|
|
751
753
|
if (l && l.overlay && l.overlay[0].from <= e && l.overlay[l.overlay.length - 1].to >= e) {
|
|
752
|
-
let
|
|
753
|
-
(r || (r = [n])).push(
|
|
754
|
+
let f = new O(l.tree, l.overlay[0].from + s.from, -1, s);
|
|
755
|
+
(r || (r = [n])).push(le(f, e, t, !1));
|
|
754
756
|
}
|
|
755
757
|
}
|
|
756
|
-
return r ?
|
|
758
|
+
return r ? Re(r) : n;
|
|
757
759
|
}
|
|
758
|
-
class
|
|
760
|
+
class _e {
|
|
759
761
|
/**
|
|
760
762
|
Shorthand for `.type.name`.
|
|
761
763
|
*/
|
|
@@ -766,7 +768,7 @@ class xe {
|
|
|
766
768
|
@internal
|
|
767
769
|
*/
|
|
768
770
|
constructor(e, t = 0) {
|
|
769
|
-
if (this.mode = t, this.buffer = null, this.stack = [], this.index = 0, this.bufferNode = null, e instanceof
|
|
771
|
+
if (this.mode = t, this.buffer = null, this.stack = [], this.index = 0, this.bufferNode = null, e instanceof O)
|
|
770
772
|
this.yieldNode(e);
|
|
771
773
|
else {
|
|
772
774
|
this._tree = e.context.parent, this.buffer = e.context;
|
|
@@ -787,7 +789,7 @@ class xe {
|
|
|
787
789
|
@internal
|
|
788
790
|
*/
|
|
789
791
|
yield(e) {
|
|
790
|
-
return e ? e instanceof
|
|
792
|
+
return e ? e instanceof O ? (this.buffer = null, this.yieldNode(e)) : (this.buffer = e.context, this.yieldBuf(e.index, e.type)) : !1;
|
|
791
793
|
}
|
|
792
794
|
/**
|
|
793
795
|
@internal
|
|
@@ -923,8 +925,8 @@ class xe {
|
|
|
923
925
|
for (; n; { index: t, _parent: n } = n)
|
|
924
926
|
if (t > -1)
|
|
925
927
|
for (let s = t + e, l = e < 0 ? -1 : n._tree.children.length; s != l; s += e) {
|
|
926
|
-
let
|
|
927
|
-
if (this.mode & S.IncludeAnonymous ||
|
|
928
|
+
let f = n._tree.children[s];
|
|
929
|
+
if (this.mode & S.IncludeAnonymous || f instanceof q || !f.type.isAnonymous || ke(f))
|
|
928
930
|
return !1;
|
|
929
931
|
}
|
|
930
932
|
return !0;
|
|
@@ -1037,11 +1039,11 @@ class xe {
|
|
|
1037
1039
|
*/
|
|
1038
1040
|
matchContext(e) {
|
|
1039
1041
|
if (!this.buffer)
|
|
1040
|
-
return
|
|
1042
|
+
return xe(this.node, e);
|
|
1041
1043
|
let { buffer: t } = this.buffer, { types: n } = t.set;
|
|
1042
1044
|
for (let r = e.length - 1, s = this.stack.length - 1; r >= 0; s--) {
|
|
1043
1045
|
if (s < 0)
|
|
1044
|
-
return
|
|
1046
|
+
return xe(this.node, e, r);
|
|
1045
1047
|
let l = n[t.buffer[this.stack[s]]];
|
|
1046
1048
|
if (!l.isAnonymous) {
|
|
1047
1049
|
if (e[r] && e[r] != l.name)
|
|
@@ -1052,200 +1054,200 @@ class xe {
|
|
|
1052
1054
|
return !0;
|
|
1053
1055
|
}
|
|
1054
1056
|
}
|
|
1055
|
-
function
|
|
1056
|
-
return i.children.some((e) => e instanceof
|
|
1057
|
+
function ke(i) {
|
|
1058
|
+
return i.children.some((e) => e instanceof q || !e.type.isAnonymous || ke(e));
|
|
1057
1059
|
}
|
|
1058
|
-
function
|
|
1060
|
+
function gt(i) {
|
|
1059
1061
|
var e;
|
|
1060
|
-
let { buffer: t, nodeSet: n, maxBufferLength: r =
|
|
1061
|
-
function
|
|
1062
|
-
let { id: c, start: d, end:
|
|
1063
|
-
for (;
|
|
1064
|
-
if (
|
|
1062
|
+
let { buffer: t, nodeSet: n, maxBufferLength: r = ft, reused: s = [], minRepeatType: l = n.types.length } = i, f = Array.isArray(t) ? new Ce(t, t.length) : t, h = n.types, C = 0, k = 0;
|
|
1063
|
+
function N(g, b, u, y, p, m) {
|
|
1064
|
+
let { id: c, start: d, end: _, size: x } = f, L = k;
|
|
1065
|
+
for (; x < 0; )
|
|
1066
|
+
if (f.next(), x == -1) {
|
|
1065
1067
|
let U = s[c];
|
|
1066
|
-
u.push(U),
|
|
1067
|
-
return;
|
|
1068
|
-
} else if (y == -3) {
|
|
1069
|
-
x = c;
|
|
1068
|
+
u.push(U), y.push(d - g);
|
|
1070
1069
|
return;
|
|
1071
|
-
} else if (
|
|
1070
|
+
} else if (x == -3) {
|
|
1072
1071
|
C = c;
|
|
1073
1072
|
return;
|
|
1073
|
+
} else if (x == -4) {
|
|
1074
|
+
k = c;
|
|
1075
|
+
return;
|
|
1074
1076
|
} else
|
|
1075
|
-
throw new RangeError(`Unrecognized record size: ${
|
|
1076
|
-
let
|
|
1077
|
-
if (
|
|
1078
|
-
let U = new Uint16Array(
|
|
1079
|
-
for (;
|
|
1080
|
-
|
|
1081
|
-
|
|
1077
|
+
throw new RangeError(`Unrecognized record size: ${x}`);
|
|
1078
|
+
let X = h[c], te, Z, Ne = d - g;
|
|
1079
|
+
if (_ - d <= r && (Z = V(f.pos - b, p))) {
|
|
1080
|
+
let U = new Uint16Array(Z.size - Z.skip), B = f.pos - Z.size, M = U.length;
|
|
1081
|
+
for (; f.pos > B; )
|
|
1082
|
+
M = $(Z.start, U, M);
|
|
1083
|
+
te = new q(U, _ - Z.start, n), Ne = Z.start - g;
|
|
1082
1084
|
} else {
|
|
1083
|
-
let U =
|
|
1084
|
-
|
|
1085
|
-
let
|
|
1086
|
-
for (;
|
|
1087
|
-
|
|
1088
|
-
if (
|
|
1089
|
-
let Se =
|
|
1090
|
-
|
|
1085
|
+
let U = f.pos - x;
|
|
1086
|
+
f.next();
|
|
1087
|
+
let B = [], M = [], Q = c >= l ? c : -1, ne = 0, oe = _;
|
|
1088
|
+
for (; f.pos > U; )
|
|
1089
|
+
Q >= 0 && f.id == Q && f.size >= 0 ? (f.end <= oe - r && (I(B, M, d, ne, f.end, oe, Q, L), ne = B.length, oe = f.end), f.next()) : m > 2500 ? A(d, U, B, M) : N(d, U, B, M, Q, m + 1);
|
|
1090
|
+
if (Q >= 0 && ne > 0 && ne < B.length && I(B, M, d, ne, d, oe, Q, L), B.reverse(), M.reverse(), Q > -1 && ne > 0) {
|
|
1091
|
+
let Se = z(X);
|
|
1092
|
+
te = we(X, B, M, 0, B.length, 0, _ - d, Se, Se);
|
|
1091
1093
|
} else
|
|
1092
|
-
|
|
1094
|
+
te = E(X, B, M, _ - d, L - _);
|
|
1093
1095
|
}
|
|
1094
|
-
u.push(
|
|
1095
|
-
}
|
|
1096
|
-
function
|
|
1097
|
-
let
|
|
1098
|
-
for (;
|
|
1099
|
-
let { id: d, start:
|
|
1100
|
-
if (
|
|
1101
|
-
|
|
1096
|
+
u.push(te), y.push(Ne);
|
|
1097
|
+
}
|
|
1098
|
+
function A(g, b, u, y) {
|
|
1099
|
+
let p = [], m = 0, c = -1;
|
|
1100
|
+
for (; f.pos > b; ) {
|
|
1101
|
+
let { id: d, start: _, end: x, size: L } = f;
|
|
1102
|
+
if (L > 4)
|
|
1103
|
+
f.next();
|
|
1102
1104
|
else {
|
|
1103
|
-
if (c > -1 &&
|
|
1105
|
+
if (c > -1 && _ < c)
|
|
1104
1106
|
break;
|
|
1105
|
-
c < 0 && (c =
|
|
1107
|
+
c < 0 && (c = x - r), p.push(d, _, x), m++, f.next();
|
|
1106
1108
|
}
|
|
1107
1109
|
}
|
|
1108
|
-
if (
|
|
1109
|
-
let d = new Uint16Array(
|
|
1110
|
-
for (let
|
|
1111
|
-
d[
|
|
1112
|
-
u.push(new
|
|
1110
|
+
if (m) {
|
|
1111
|
+
let d = new Uint16Array(m * 4), _ = p[p.length - 2];
|
|
1112
|
+
for (let x = p.length - 3, L = 0; x >= 0; x -= 3)
|
|
1113
|
+
d[L++] = p[x], d[L++] = p[x + 1] - _, d[L++] = p[x + 2] - _, d[L++] = L;
|
|
1114
|
+
u.push(new q(d, p[2] - _, n)), y.push(_ - g);
|
|
1113
1115
|
}
|
|
1114
1116
|
}
|
|
1115
|
-
function
|
|
1116
|
-
return (
|
|
1117
|
-
let
|
|
1118
|
-
if (
|
|
1119
|
-
if (!
|
|
1117
|
+
function z(g) {
|
|
1118
|
+
return (b, u, y) => {
|
|
1119
|
+
let p = 0, m = b.length - 1, c, d;
|
|
1120
|
+
if (m >= 0 && (c = b[m]) instanceof R) {
|
|
1121
|
+
if (!m && c.type == g && c.length == y)
|
|
1120
1122
|
return c;
|
|
1121
|
-
(d = c.prop(
|
|
1123
|
+
(d = c.prop(v.lookAhead)) && (p = u[m] + c.length + d);
|
|
1122
1124
|
}
|
|
1123
|
-
return
|
|
1125
|
+
return E(g, b, u, y, p);
|
|
1124
1126
|
};
|
|
1125
1127
|
}
|
|
1126
|
-
function
|
|
1127
|
-
let
|
|
1128
|
-
for (;
|
|
1129
|
-
|
|
1130
|
-
|
|
1128
|
+
function I(g, b, u, y, p, m, c, d) {
|
|
1129
|
+
let _ = [], x = [];
|
|
1130
|
+
for (; g.length > y; )
|
|
1131
|
+
_.push(g.pop()), x.push(b.pop() + u - p);
|
|
1132
|
+
g.push(E(n.types[c], _, x, m - p, d - m)), b.push(p - u);
|
|
1131
1133
|
}
|
|
1132
|
-
function
|
|
1133
|
-
if (
|
|
1134
|
-
let c = [
|
|
1135
|
-
|
|
1134
|
+
function E(g, b, u, y, p = 0, m) {
|
|
1135
|
+
if (C) {
|
|
1136
|
+
let c = [v.contextHash, C];
|
|
1137
|
+
m = m ? [c].concat(m) : [c];
|
|
1136
1138
|
}
|
|
1137
|
-
if (
|
|
1138
|
-
let c = [
|
|
1139
|
-
|
|
1139
|
+
if (p > 25) {
|
|
1140
|
+
let c = [v.lookAhead, p];
|
|
1141
|
+
m = m ? [c].concat(m) : [c];
|
|
1140
1142
|
}
|
|
1141
|
-
return new
|
|
1143
|
+
return new R(g, b, u, y, m);
|
|
1142
1144
|
}
|
|
1143
|
-
function
|
|
1144
|
-
let u =
|
|
1145
|
+
function V(g, b) {
|
|
1146
|
+
let u = f.fork(), y = 0, p = 0, m = 0, c = u.end - r, d = { size: 0, start: 0, skip: 0 };
|
|
1145
1147
|
e:
|
|
1146
|
-
for (let
|
|
1147
|
-
let
|
|
1148
|
-
if (u.id ==
|
|
1149
|
-
d.size =
|
|
1148
|
+
for (let _ = u.pos - g; u.pos > _; ) {
|
|
1149
|
+
let x = u.size;
|
|
1150
|
+
if (u.id == b && x >= 0) {
|
|
1151
|
+
d.size = y, d.start = p, d.skip = m, m += 4, y += 4, u.next();
|
|
1150
1152
|
continue;
|
|
1151
1153
|
}
|
|
1152
|
-
let
|
|
1153
|
-
if (
|
|
1154
|
+
let L = u.pos - x;
|
|
1155
|
+
if (x < 0 || L < _ || u.start < c)
|
|
1154
1156
|
break;
|
|
1155
|
-
let
|
|
1156
|
-
for (u.next(); u.pos >
|
|
1157
|
+
let X = u.id >= l ? 4 : 0, te = u.start;
|
|
1158
|
+
for (u.next(); u.pos > L; ) {
|
|
1157
1159
|
if (u.size < 0)
|
|
1158
1160
|
if (u.size == -3)
|
|
1159
|
-
|
|
1161
|
+
X += 4;
|
|
1160
1162
|
else
|
|
1161
1163
|
break e;
|
|
1162
1164
|
else
|
|
1163
|
-
u.id >= l && (
|
|
1165
|
+
u.id >= l && (X += 4);
|
|
1164
1166
|
u.next();
|
|
1165
1167
|
}
|
|
1166
|
-
|
|
1168
|
+
p = te, y += x, m += X;
|
|
1167
1169
|
}
|
|
1168
|
-
return (
|
|
1170
|
+
return (b < 0 || y == g) && (d.size = y, d.start = p, d.skip = m), d.size > 4 ? d : void 0;
|
|
1169
1171
|
}
|
|
1170
|
-
function
|
|
1171
|
-
let { id:
|
|
1172
|
-
if (
|
|
1172
|
+
function $(g, b, u) {
|
|
1173
|
+
let { id: y, start: p, end: m, size: c } = f;
|
|
1174
|
+
if (f.next(), c >= 0 && y < l) {
|
|
1173
1175
|
let d = u;
|
|
1174
1176
|
if (c > 4) {
|
|
1175
|
-
let
|
|
1176
|
-
for (;
|
|
1177
|
-
u =
|
|
1177
|
+
let _ = f.pos - (c - 4);
|
|
1178
|
+
for (; f.pos > _; )
|
|
1179
|
+
u = $(g, b, u);
|
|
1178
1180
|
}
|
|
1179
|
-
|
|
1181
|
+
b[--u] = d, b[--u] = m - g, b[--u] = p - g, b[--u] = y;
|
|
1180
1182
|
} else
|
|
1181
|
-
c == -3 ?
|
|
1183
|
+
c == -3 ? C = y : c == -4 && (k = y);
|
|
1182
1184
|
return u;
|
|
1183
1185
|
}
|
|
1184
|
-
let
|
|
1185
|
-
for (;
|
|
1186
|
-
|
|
1187
|
-
let
|
|
1188
|
-
return new
|
|
1186
|
+
let D = [], w = [];
|
|
1187
|
+
for (; f.pos > 0; )
|
|
1188
|
+
N(i.start || 0, i.bufferStart || 0, D, w, -1, 0);
|
|
1189
|
+
let J = (e = i.length) !== null && e !== void 0 ? e : D.length ? w[0] + D[0].length : 0;
|
|
1190
|
+
return new R(h[i.topID], D.reverse(), w.reverse(), J);
|
|
1189
1191
|
}
|
|
1190
1192
|
const ze = /* @__PURE__ */ new WeakMap();
|
|
1191
|
-
function
|
|
1192
|
-
if (!i.isAnonymous || e instanceof
|
|
1193
|
+
function de(i, e) {
|
|
1194
|
+
if (!i.isAnonymous || e instanceof q || e.type != i)
|
|
1193
1195
|
return 1;
|
|
1194
1196
|
let t = ze.get(e);
|
|
1195
1197
|
if (t == null) {
|
|
1196
1198
|
t = 1;
|
|
1197
1199
|
for (let n of e.children) {
|
|
1198
|
-
if (n.type != i || !(n instanceof
|
|
1200
|
+
if (n.type != i || !(n instanceof R)) {
|
|
1199
1201
|
t = 1;
|
|
1200
1202
|
break;
|
|
1201
1203
|
}
|
|
1202
|
-
t +=
|
|
1204
|
+
t += de(i, n);
|
|
1203
1205
|
}
|
|
1204
1206
|
ze.set(e, t);
|
|
1205
1207
|
}
|
|
1206
1208
|
return t;
|
|
1207
1209
|
}
|
|
1208
|
-
function we(i, e, t, n, r, s, l,
|
|
1209
|
-
let
|
|
1210
|
-
for (let
|
|
1211
|
-
|
|
1212
|
-
let
|
|
1213
|
-
|
|
1210
|
+
function we(i, e, t, n, r, s, l, f, h) {
|
|
1211
|
+
let C = 0;
|
|
1212
|
+
for (let I = n; I < r; I++)
|
|
1213
|
+
C += de(i, e[I]);
|
|
1214
|
+
let k = Math.ceil(
|
|
1215
|
+
C * 1.5 / 8
|
|
1214
1216
|
/* Balance.BranchFactor */
|
|
1215
|
-
),
|
|
1216
|
-
function
|
|
1217
|
-
for (let
|
|
1218
|
-
let
|
|
1219
|
-
for (
|
|
1220
|
-
let u =
|
|
1221
|
-
if (
|
|
1217
|
+
), N = [], A = [];
|
|
1218
|
+
function z(I, E, V, $, D) {
|
|
1219
|
+
for (let w = V; w < $; ) {
|
|
1220
|
+
let J = w, g = E[w], b = de(i, I[w]);
|
|
1221
|
+
for (w++; w < $; w++) {
|
|
1222
|
+
let u = de(i, I[w]);
|
|
1223
|
+
if (b + u >= k)
|
|
1222
1224
|
break;
|
|
1223
|
-
|
|
1225
|
+
b += u;
|
|
1224
1226
|
}
|
|
1225
|
-
if (
|
|
1226
|
-
if (
|
|
1227
|
-
let u =
|
|
1228
|
-
|
|
1227
|
+
if (w == J + 1) {
|
|
1228
|
+
if (b > k) {
|
|
1229
|
+
let u = I[J];
|
|
1230
|
+
z(u.children, u.positions, 0, u.children.length, E[J] + D);
|
|
1229
1231
|
continue;
|
|
1230
1232
|
}
|
|
1231
|
-
|
|
1233
|
+
N.push(I[J]);
|
|
1232
1234
|
} else {
|
|
1233
|
-
let u =
|
|
1234
|
-
|
|
1235
|
+
let u = E[w - 1] + I[w - 1].length - g;
|
|
1236
|
+
N.push(we(i, I, E, J, w, g, u, null, h));
|
|
1235
1237
|
}
|
|
1236
|
-
|
|
1238
|
+
A.push(g + D - s);
|
|
1237
1239
|
}
|
|
1238
1240
|
}
|
|
1239
|
-
return
|
|
1241
|
+
return z(e, t, n, r, 0), (f || h)(N, A, l);
|
|
1240
1242
|
}
|
|
1241
|
-
new
|
|
1242
|
-
let
|
|
1243
|
-
class
|
|
1243
|
+
new v({ perNode: !0 });
|
|
1244
|
+
let mt = 0;
|
|
1245
|
+
class H {
|
|
1244
1246
|
/**
|
|
1245
1247
|
@internal
|
|
1246
1248
|
*/
|
|
1247
1249
|
constructor(e, t, n) {
|
|
1248
|
-
this.set = e, this.base = t, this.modified = n, this.id =
|
|
1250
|
+
this.set = e, this.base = t, this.modified = n, this.id = mt++;
|
|
1249
1251
|
}
|
|
1250
1252
|
/**
|
|
1251
1253
|
Define a new tag. If `parent` is given, the tag is treated as a
|
|
@@ -1257,7 +1259,7 @@ class D {
|
|
|
1257
1259
|
static define(e) {
|
|
1258
1260
|
if (e != null && e.base)
|
|
1259
1261
|
throw new Error("Can not derive from a modified tag");
|
|
1260
|
-
let t = new
|
|
1262
|
+
let t = new H([], null, []);
|
|
1261
1263
|
if (t.set.push(t), e)
|
|
1262
1264
|
for (let n of e.set)
|
|
1263
1265
|
t.set.push(n);
|
|
@@ -1276,44 +1278,44 @@ class D {
|
|
|
1276
1278
|
`m1(m3(t1)`, and so on.
|
|
1277
1279
|
*/
|
|
1278
1280
|
static defineModifier() {
|
|
1279
|
-
let e = new
|
|
1280
|
-
return (t) => t.modified.indexOf(e) > -1 ? t :
|
|
1281
|
+
let e = new me();
|
|
1282
|
+
return (t) => t.modified.indexOf(e) > -1 ? t : me.get(t.base || t, t.modified.concat(e).sort((n, r) => n.id - r.id));
|
|
1281
1283
|
}
|
|
1282
1284
|
}
|
|
1283
|
-
let
|
|
1284
|
-
class
|
|
1285
|
+
let bt = 0;
|
|
1286
|
+
class me {
|
|
1285
1287
|
constructor() {
|
|
1286
|
-
this.instances = [], this.id =
|
|
1288
|
+
this.instances = [], this.id = bt++;
|
|
1287
1289
|
}
|
|
1288
1290
|
static get(e, t) {
|
|
1289
1291
|
if (!t.length)
|
|
1290
1292
|
return e;
|
|
1291
|
-
let n = t[0].instances.find((
|
|
1293
|
+
let n = t[0].instances.find((f) => f.base == e && yt(t, f.modified));
|
|
1292
1294
|
if (n)
|
|
1293
1295
|
return n;
|
|
1294
|
-
let r = [], s = new
|
|
1295
|
-
for (let
|
|
1296
|
-
|
|
1297
|
-
let l =
|
|
1298
|
-
for (let
|
|
1299
|
-
if (!
|
|
1300
|
-
for (let
|
|
1301
|
-
r.push(
|
|
1296
|
+
let r = [], s = new H(r, e, t);
|
|
1297
|
+
for (let f of t)
|
|
1298
|
+
f.instances.push(s);
|
|
1299
|
+
let l = xt(t);
|
|
1300
|
+
for (let f of e.set)
|
|
1301
|
+
if (!f.modified.length)
|
|
1302
|
+
for (let h of l)
|
|
1303
|
+
r.push(me.get(f, h));
|
|
1302
1304
|
return s;
|
|
1303
1305
|
}
|
|
1304
1306
|
}
|
|
1305
|
-
function
|
|
1307
|
+
function yt(i, e) {
|
|
1306
1308
|
return i.length == e.length && i.every((t, n) => t == e[n]);
|
|
1307
1309
|
}
|
|
1308
|
-
function
|
|
1310
|
+
function xt(i) {
|
|
1309
1311
|
let e = [[]];
|
|
1310
1312
|
for (let t = 0; t < i.length; t++)
|
|
1311
1313
|
for (let n = 0, r = e.length; n < r; n++)
|
|
1312
1314
|
e.push(e[n].concat(i[t]));
|
|
1313
1315
|
return e.sort((t, n) => n.length - t.length);
|
|
1314
1316
|
}
|
|
1315
|
-
new
|
|
1316
|
-
function
|
|
1317
|
+
new v();
|
|
1318
|
+
function _t(i, e) {
|
|
1317
1319
|
let t = /* @__PURE__ */ Object.create(null);
|
|
1318
1320
|
for (let s of i)
|
|
1319
1321
|
if (!Array.isArray(s.tag))
|
|
@@ -1325,11 +1327,11 @@ function yt(i, e) {
|
|
|
1325
1327
|
return {
|
|
1326
1328
|
style: (s) => {
|
|
1327
1329
|
let l = r;
|
|
1328
|
-
for (let
|
|
1329
|
-
for (let
|
|
1330
|
-
let
|
|
1331
|
-
if (
|
|
1332
|
-
l = l ? l + " " +
|
|
1330
|
+
for (let f of s)
|
|
1331
|
+
for (let h of f.set) {
|
|
1332
|
+
let C = t[h.id];
|
|
1333
|
+
if (C) {
|
|
1334
|
+
l = l ? l + " " + C : C;
|
|
1333
1335
|
break;
|
|
1334
1336
|
}
|
|
1335
1337
|
}
|
|
@@ -1338,31 +1340,31 @@ function yt(i, e) {
|
|
|
1338
1340
|
scope: n
|
|
1339
1341
|
};
|
|
1340
1342
|
}
|
|
1341
|
-
const a =
|
|
1343
|
+
const a = H.define, ue = a(), G = a(), Ee = a(G), Me = a(G), K = a(), he = a(K), ye = a(K), j = a(), Y = a(j), P = a(), T = a(), ve = a(), ie = a(ve), ce = a(), o = {
|
|
1342
1344
|
/**
|
|
1343
1345
|
A comment.
|
|
1344
1346
|
*/
|
|
1345
|
-
comment:
|
|
1347
|
+
comment: ue,
|
|
1346
1348
|
/**
|
|
1347
1349
|
A line [comment](#highlight.tags.comment).
|
|
1348
1350
|
*/
|
|
1349
|
-
lineComment: a(
|
|
1351
|
+
lineComment: a(ue),
|
|
1350
1352
|
/**
|
|
1351
1353
|
A block [comment](#highlight.tags.comment).
|
|
1352
1354
|
*/
|
|
1353
|
-
blockComment: a(
|
|
1355
|
+
blockComment: a(ue),
|
|
1354
1356
|
/**
|
|
1355
1357
|
A documentation [comment](#highlight.tags.comment).
|
|
1356
1358
|
*/
|
|
1357
|
-
docComment: a(
|
|
1359
|
+
docComment: a(ue),
|
|
1358
1360
|
/**
|
|
1359
1361
|
Any kind of identifier.
|
|
1360
1362
|
*/
|
|
1361
|
-
name:
|
|
1363
|
+
name: G,
|
|
1362
1364
|
/**
|
|
1363
1365
|
The [name](#highlight.tags.name) of a variable.
|
|
1364
1366
|
*/
|
|
1365
|
-
variableName: a(
|
|
1367
|
+
variableName: a(G),
|
|
1366
1368
|
/**
|
|
1367
1369
|
A type [name](#highlight.tags.name).
|
|
1368
1370
|
*/
|
|
@@ -1374,27 +1376,27 @@ const a = D.define, ae = a(), W = a(), Ee = a(W), Pe = a(W), K = a(), he = a(K),
|
|
|
1374
1376
|
/**
|
|
1375
1377
|
A property or field [name](#highlight.tags.name).
|
|
1376
1378
|
*/
|
|
1377
|
-
propertyName:
|
|
1379
|
+
propertyName: Me,
|
|
1378
1380
|
/**
|
|
1379
1381
|
An attribute name (subtag of [`propertyName`](#highlight.tags.propertyName)).
|
|
1380
1382
|
*/
|
|
1381
|
-
attributeName: a(
|
|
1383
|
+
attributeName: a(Me),
|
|
1382
1384
|
/**
|
|
1383
1385
|
The [name](#highlight.tags.name) of a class.
|
|
1384
1386
|
*/
|
|
1385
|
-
className: a(
|
|
1387
|
+
className: a(G),
|
|
1386
1388
|
/**
|
|
1387
1389
|
A label [name](#highlight.tags.name).
|
|
1388
1390
|
*/
|
|
1389
|
-
labelName: a(
|
|
1391
|
+
labelName: a(G),
|
|
1390
1392
|
/**
|
|
1391
1393
|
A namespace [name](#highlight.tags.name).
|
|
1392
1394
|
*/
|
|
1393
|
-
namespace: a(
|
|
1395
|
+
namespace: a(G),
|
|
1394
1396
|
/**
|
|
1395
1397
|
The [name](#highlight.tags.name) of a macro.
|
|
1396
1398
|
*/
|
|
1397
|
-
macroName: a(
|
|
1399
|
+
macroName: a(G),
|
|
1398
1400
|
/**
|
|
1399
1401
|
A literal value.
|
|
1400
1402
|
*/
|
|
@@ -1418,15 +1420,15 @@ const a = D.define, ae = a(), W = a(), Ee = a(W), Pe = a(W), K = a(), he = a(K),
|
|
|
1418
1420
|
/**
|
|
1419
1421
|
A number [literal](#highlight.tags.literal).
|
|
1420
1422
|
*/
|
|
1421
|
-
number:
|
|
1423
|
+
number: ye,
|
|
1422
1424
|
/**
|
|
1423
1425
|
An integer [number](#highlight.tags.number) literal.
|
|
1424
1426
|
*/
|
|
1425
|
-
integer: a(
|
|
1427
|
+
integer: a(ye),
|
|
1426
1428
|
/**
|
|
1427
1429
|
A floating-point [number](#highlight.tags.number) literal.
|
|
1428
1430
|
*/
|
|
1429
|
-
float: a(
|
|
1431
|
+
float: a(ye),
|
|
1430
1432
|
/**
|
|
1431
1433
|
A boolean [literal](#highlight.tags.literal).
|
|
1432
1434
|
*/
|
|
@@ -1451,94 +1453,94 @@ const a = D.define, ae = a(), W = a(), Ee = a(W), Pe = a(W), K = a(), he = a(K),
|
|
|
1451
1453
|
/**
|
|
1452
1454
|
A language keyword.
|
|
1453
1455
|
*/
|
|
1454
|
-
keyword:
|
|
1456
|
+
keyword: P,
|
|
1455
1457
|
/**
|
|
1456
1458
|
The [keyword](#highlight.tags.keyword) for the self or this
|
|
1457
1459
|
object.
|
|
1458
1460
|
*/
|
|
1459
|
-
self: a(
|
|
1461
|
+
self: a(P),
|
|
1460
1462
|
/**
|
|
1461
1463
|
The [keyword](#highlight.tags.keyword) for null.
|
|
1462
1464
|
*/
|
|
1463
|
-
null: a(
|
|
1465
|
+
null: a(P),
|
|
1464
1466
|
/**
|
|
1465
1467
|
A [keyword](#highlight.tags.keyword) denoting some atomic value.
|
|
1466
1468
|
*/
|
|
1467
|
-
atom: a(
|
|
1469
|
+
atom: a(P),
|
|
1468
1470
|
/**
|
|
1469
1471
|
A [keyword](#highlight.tags.keyword) that represents a unit.
|
|
1470
1472
|
*/
|
|
1471
|
-
unit: a(
|
|
1473
|
+
unit: a(P),
|
|
1472
1474
|
/**
|
|
1473
1475
|
A modifier [keyword](#highlight.tags.keyword).
|
|
1474
1476
|
*/
|
|
1475
|
-
modifier: a(
|
|
1477
|
+
modifier: a(P),
|
|
1476
1478
|
/**
|
|
1477
1479
|
A [keyword](#highlight.tags.keyword) that acts as an operator.
|
|
1478
1480
|
*/
|
|
1479
|
-
operatorKeyword: a(
|
|
1481
|
+
operatorKeyword: a(P),
|
|
1480
1482
|
/**
|
|
1481
1483
|
A control-flow related [keyword](#highlight.tags.keyword).
|
|
1482
1484
|
*/
|
|
1483
|
-
controlKeyword: a(
|
|
1485
|
+
controlKeyword: a(P),
|
|
1484
1486
|
/**
|
|
1485
1487
|
A [keyword](#highlight.tags.keyword) that defines something.
|
|
1486
1488
|
*/
|
|
1487
|
-
definitionKeyword: a(
|
|
1489
|
+
definitionKeyword: a(P),
|
|
1488
1490
|
/**
|
|
1489
1491
|
A [keyword](#highlight.tags.keyword) related to defining or
|
|
1490
1492
|
interfacing with modules.
|
|
1491
1493
|
*/
|
|
1492
|
-
moduleKeyword: a(
|
|
1494
|
+
moduleKeyword: a(P),
|
|
1493
1495
|
/**
|
|
1494
1496
|
An operator.
|
|
1495
1497
|
*/
|
|
1496
|
-
operator:
|
|
1498
|
+
operator: T,
|
|
1497
1499
|
/**
|
|
1498
1500
|
An [operator](#highlight.tags.operator) that dereferences something.
|
|
1499
1501
|
*/
|
|
1500
|
-
derefOperator: a(
|
|
1502
|
+
derefOperator: a(T),
|
|
1501
1503
|
/**
|
|
1502
1504
|
Arithmetic-related [operator](#highlight.tags.operator).
|
|
1503
1505
|
*/
|
|
1504
|
-
arithmeticOperator: a(
|
|
1506
|
+
arithmeticOperator: a(T),
|
|
1505
1507
|
/**
|
|
1506
1508
|
Logical [operator](#highlight.tags.operator).
|
|
1507
1509
|
*/
|
|
1508
|
-
logicOperator: a(
|
|
1510
|
+
logicOperator: a(T),
|
|
1509
1511
|
/**
|
|
1510
1512
|
Bit [operator](#highlight.tags.operator).
|
|
1511
1513
|
*/
|
|
1512
|
-
bitwiseOperator: a(
|
|
1514
|
+
bitwiseOperator: a(T),
|
|
1513
1515
|
/**
|
|
1514
1516
|
Comparison [operator](#highlight.tags.operator).
|
|
1515
1517
|
*/
|
|
1516
|
-
compareOperator: a(
|
|
1518
|
+
compareOperator: a(T),
|
|
1517
1519
|
/**
|
|
1518
1520
|
[Operator](#highlight.tags.operator) that updates its operand.
|
|
1519
1521
|
*/
|
|
1520
|
-
updateOperator: a(
|
|
1522
|
+
updateOperator: a(T),
|
|
1521
1523
|
/**
|
|
1522
1524
|
[Operator](#highlight.tags.operator) that defines something.
|
|
1523
1525
|
*/
|
|
1524
|
-
definitionOperator: a(
|
|
1526
|
+
definitionOperator: a(T),
|
|
1525
1527
|
/**
|
|
1526
1528
|
Type-related [operator](#highlight.tags.operator).
|
|
1527
1529
|
*/
|
|
1528
|
-
typeOperator: a(
|
|
1530
|
+
typeOperator: a(T),
|
|
1529
1531
|
/**
|
|
1530
1532
|
Control-flow [operator](#highlight.tags.operator).
|
|
1531
1533
|
*/
|
|
1532
|
-
controlOperator: a(
|
|
1534
|
+
controlOperator: a(T),
|
|
1533
1535
|
/**
|
|
1534
1536
|
Program or markup punctuation.
|
|
1535
1537
|
*/
|
|
1536
|
-
punctuation:
|
|
1538
|
+
punctuation: ve,
|
|
1537
1539
|
/**
|
|
1538
1540
|
[Punctuation](#highlight.tags.punctuation) that separates
|
|
1539
1541
|
things.
|
|
1540
1542
|
*/
|
|
1541
|
-
separator: a(
|
|
1543
|
+
separator: a(ve),
|
|
1542
1544
|
/**
|
|
1543
1545
|
Bracket-style [punctuation](#highlight.tags.punctuation).
|
|
1544
1546
|
*/
|
|
@@ -1566,7 +1568,7 @@ const a = D.define, ae = a(), W = a(), Ee = a(W), Pe = a(W), K = a(), he = a(K),
|
|
|
1566
1568
|
/**
|
|
1567
1569
|
Content, for example plain text in XML or markup documents.
|
|
1568
1570
|
*/
|
|
1569
|
-
content:
|
|
1571
|
+
content: j,
|
|
1570
1572
|
/**
|
|
1571
1573
|
[Content](#highlight.tags.content) that represents a heading.
|
|
1572
1574
|
*/
|
|
@@ -1598,37 +1600,37 @@ const a = D.define, ae = a(), W = a(), Ee = a(W), Pe = a(W), K = a(), he = a(K),
|
|
|
1598
1600
|
/**
|
|
1599
1601
|
A prose separator (such as a horizontal rule).
|
|
1600
1602
|
*/
|
|
1601
|
-
contentSeparator: a(
|
|
1603
|
+
contentSeparator: a(j),
|
|
1602
1604
|
/**
|
|
1603
1605
|
[Content](#highlight.tags.content) that represents a list.
|
|
1604
1606
|
*/
|
|
1605
|
-
list: a(
|
|
1607
|
+
list: a(j),
|
|
1606
1608
|
/**
|
|
1607
1609
|
[Content](#highlight.tags.content) that represents a quote.
|
|
1608
1610
|
*/
|
|
1609
|
-
quote: a(
|
|
1611
|
+
quote: a(j),
|
|
1610
1612
|
/**
|
|
1611
1613
|
[Content](#highlight.tags.content) that is emphasized.
|
|
1612
1614
|
*/
|
|
1613
|
-
emphasis: a(
|
|
1615
|
+
emphasis: a(j),
|
|
1614
1616
|
/**
|
|
1615
1617
|
[Content](#highlight.tags.content) that is styled strong.
|
|
1616
1618
|
*/
|
|
1617
|
-
strong: a(
|
|
1619
|
+
strong: a(j),
|
|
1618
1620
|
/**
|
|
1619
1621
|
[Content](#highlight.tags.content) that is part of a link.
|
|
1620
1622
|
*/
|
|
1621
|
-
link: a(
|
|
1623
|
+
link: a(j),
|
|
1622
1624
|
/**
|
|
1623
1625
|
[Content](#highlight.tags.content) that is styled as code or
|
|
1624
1626
|
monospace.
|
|
1625
1627
|
*/
|
|
1626
|
-
monospace: a(
|
|
1628
|
+
monospace: a(j),
|
|
1627
1629
|
/**
|
|
1628
1630
|
[Content](#highlight.tags.content) that has a strike-through
|
|
1629
1631
|
style.
|
|
1630
1632
|
*/
|
|
1631
|
-
strikethrough: a(
|
|
1633
|
+
strikethrough: a(j),
|
|
1632
1634
|
/**
|
|
1633
1635
|
Inserted text in a change-tracking format.
|
|
1634
1636
|
*/
|
|
@@ -1648,52 +1650,52 @@ const a = D.define, ae = a(), W = a(), Ee = a(W), Pe = a(W), K = a(), he = a(K),
|
|
|
1648
1650
|
/**
|
|
1649
1651
|
Metadata or meta-instruction.
|
|
1650
1652
|
*/
|
|
1651
|
-
meta:
|
|
1653
|
+
meta: ce,
|
|
1652
1654
|
/**
|
|
1653
1655
|
[Metadata](#highlight.tags.meta) that applies to the entire
|
|
1654
1656
|
document.
|
|
1655
1657
|
*/
|
|
1656
|
-
documentMeta: a(
|
|
1658
|
+
documentMeta: a(ce),
|
|
1657
1659
|
/**
|
|
1658
1660
|
[Metadata](#highlight.tags.meta) that annotates or adds
|
|
1659
1661
|
attributes to a given syntactic element.
|
|
1660
1662
|
*/
|
|
1661
|
-
annotation: a(
|
|
1663
|
+
annotation: a(ce),
|
|
1662
1664
|
/**
|
|
1663
1665
|
Processing instruction or preprocessor directive. Subtag of
|
|
1664
1666
|
[meta](#highlight.tags.meta).
|
|
1665
1667
|
*/
|
|
1666
|
-
processingInstruction: a(
|
|
1668
|
+
processingInstruction: a(ce),
|
|
1667
1669
|
/**
|
|
1668
1670
|
[Modifier](#highlight.Tag^defineModifier) that indicates that a
|
|
1669
1671
|
given element is being defined. Expected to be used with the
|
|
1670
1672
|
various [name](#highlight.tags.name) tags.
|
|
1671
1673
|
*/
|
|
1672
|
-
definition:
|
|
1674
|
+
definition: H.defineModifier(),
|
|
1673
1675
|
/**
|
|
1674
1676
|
[Modifier](#highlight.Tag^defineModifier) that indicates that
|
|
1675
1677
|
something is constant. Mostly expected to be used with
|
|
1676
1678
|
[variable names](#highlight.tags.variableName).
|
|
1677
1679
|
*/
|
|
1678
|
-
constant:
|
|
1680
|
+
constant: H.defineModifier(),
|
|
1679
1681
|
/**
|
|
1680
1682
|
[Modifier](#highlight.Tag^defineModifier) used to indicate that
|
|
1681
1683
|
a [variable](#highlight.tags.variableName) or [property
|
|
1682
1684
|
name](#highlight.tags.propertyName) is being called or defined
|
|
1683
1685
|
as a function.
|
|
1684
1686
|
*/
|
|
1685
|
-
function:
|
|
1687
|
+
function: H.defineModifier(),
|
|
1686
1688
|
/**
|
|
1687
1689
|
[Modifier](#highlight.Tag^defineModifier) that can be applied to
|
|
1688
1690
|
[names](#highlight.tags.name) to indicate that they belong to
|
|
1689
1691
|
the language's standard environment.
|
|
1690
1692
|
*/
|
|
1691
|
-
standard:
|
|
1693
|
+
standard: H.defineModifier(),
|
|
1692
1694
|
/**
|
|
1693
1695
|
[Modifier](#highlight.Tag^defineModifier) that indicates a given
|
|
1694
1696
|
[names](#highlight.tags.name) is local to some scope.
|
|
1695
1697
|
*/
|
|
1696
|
-
local:
|
|
1698
|
+
local: H.defineModifier(),
|
|
1697
1699
|
/**
|
|
1698
1700
|
A generic variant [modifier](#highlight.Tag^defineModifier) that
|
|
1699
1701
|
can be used to tag language-specific alternative variants of
|
|
@@ -1702,9 +1704,9 @@ const a = D.define, ae = a(), W = a(), Ee = a(W), Pe = a(W), K = a(), he = a(K),
|
|
|
1702
1704
|
[variable name](#highlight.tags.variableName) tags, since those
|
|
1703
1705
|
come up a lot.
|
|
1704
1706
|
*/
|
|
1705
|
-
special:
|
|
1707
|
+
special: H.defineModifier()
|
|
1706
1708
|
};
|
|
1707
|
-
|
|
1709
|
+
_t([
|
|
1708
1710
|
{ tag: o.link, class: "tok-link" },
|
|
1709
1711
|
{ tag: o.heading, class: "tok-heading" },
|
|
1710
1712
|
{ tag: o.emphasis, class: "tok-emphasis" },
|
|
@@ -1736,13 +1738,13 @@ yt([
|
|
|
1736
1738
|
{ tag: o.invalid, class: "tok-invalid" },
|
|
1737
1739
|
{ tag: o.punctuation, class: "tok-punctuation" }
|
|
1738
1740
|
]);
|
|
1739
|
-
const
|
|
1740
|
-
red:
|
|
1741
|
-
orange:
|
|
1742
|
-
green:
|
|
1743
|
-
blue:
|
|
1741
|
+
const vt = "#c72727", Ct = "#9b5700", kt = "#067934", wt = "#0063d7", Nt = {
|
|
1742
|
+
red: vt,
|
|
1743
|
+
orange: Ct,
|
|
1744
|
+
green: kt,
|
|
1745
|
+
blue: wt,
|
|
1744
1746
|
invalid: "#ffffff"
|
|
1745
|
-
},
|
|
1747
|
+
}, St = (i) => Xe.define([
|
|
1746
1748
|
{
|
|
1747
1749
|
tag: o.keyword,
|
|
1748
1750
|
color: i.red
|
|
@@ -1809,45 +1811,69 @@ const xt = "#c72727", kt = "#9b5700", vt = "#067934", _t = "#0063d7", Ct = {
|
|
|
1809
1811
|
tag: o.invalid,
|
|
1810
1812
|
color: i.invalid
|
|
1811
1813
|
}
|
|
1812
|
-
]),
|
|
1813
|
-
var
|
|
1814
|
-
const
|
|
1815
|
-
[
|
|
1816
|
-
[
|
|
1817
|
-
[
|
|
1818
|
-
[
|
|
1819
|
-
},
|
|
1820
|
-
loadLang: async () =>
|
|
1821
|
-
})
|
|
1814
|
+
]), At = qe(St(Nt));
|
|
1815
|
+
var pe = /* @__PURE__ */ ((i) => (i.INLINE = "inline", i.SINGLELINE = "singleline", i.MULTILINE = "multiline", i))(pe || {}), ee = /* @__PURE__ */ ((i) => (i.JSON = "json", i.XML = "xml", i.JAVA = "java", i.JAVASCRIPT = "javascript", i))(ee || {}), se = /* @__PURE__ */ ((i) => (i.ACTION = "action", i.CHANGE = "change", i))(se || {});
|
|
1816
|
+
const It = {
|
|
1817
|
+
[ee.JSON]: Ze,
|
|
1818
|
+
[ee.XML]: Qe,
|
|
1819
|
+
[ee.JAVASCRIPT]: Ye,
|
|
1820
|
+
[ee.JAVA]: et
|
|
1821
|
+
}, Lt = (i) => ({
|
|
1822
|
+
loadLang: async () => It[i]
|
|
1823
|
+
});
|
|
1824
|
+
let Pe = 0;
|
|
1825
|
+
const Bt = {
|
|
1826
|
+
beforeCreate() {
|
|
1827
|
+
this.uuid = Pe.toString(), Pe += 1;
|
|
1828
|
+
}
|
|
1829
|
+
};
|
|
1830
|
+
var Ot = function() {
|
|
1831
|
+
var e = this, t = e._self._c;
|
|
1832
|
+
return t("svg", e._b({ 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: "#00112C", "fill-rule": "evenodd", d: "M14 1.25H10C9.58579 1.25 9.25 1.58579 9.25 2C9.25 2.41421 9.58579 2.75 10 2.75H12.1893L9.46967 5.46967C9.17678 5.76256 9.17678 6.23744 9.46967 6.53033C9.76256 6.82322 10.2374 6.82322 10.5303 6.53033L13.25 3.81066V6C13.25 6.41421 13.5858 6.75 14 6.75C14.4142 6.75 14.75 6.41421 14.75 6V2C14.75 1.80806 14.6768 1.61612 14.5303 1.46967C14.4584 1.39776 14.3755 1.34351 14.2871 1.30691C14.1987 1.27024 14.1017 1.25 14 1.25Z", "clip-rule": "evenodd" } }), t("path", { attrs: { fill: "#00112C", "fill-rule": "evenodd", d: "M1.25 10C1.25 9.58579 1.58579 9.25 2 9.25C2.41421 9.25 2.75 9.58579 2.75 10V12.1893L5.46967 9.46967C5.76256 9.17678 6.23744 9.17678 6.53033 9.46967C6.82322 9.76256 6.82322 10.2374 6.53033 10.5303L3.81066 13.25H6C6.41421 13.25 6.75 13.5858 6.75 14C6.75 14.4142 6.41421 14.75 6 14.75H2C1.80806 14.75 1.61612 14.6768 1.46967 14.5303C1.39776 14.4584 1.34351 14.3755 1.30691 14.2871C1.27024 14.1987 1.25 14.1017 1.25 14V10Z", "clip-rule": "evenodd" } })]);
|
|
1833
|
+
}, zt = [], Et = /* @__PURE__ */ Te(
|
|
1834
|
+
Bt,
|
|
1835
|
+
Ot,
|
|
1836
|
+
zt,
|
|
1837
|
+
!1,
|
|
1838
|
+
null,
|
|
1839
|
+
"012ee7f3",
|
|
1840
|
+
null,
|
|
1841
|
+
null
|
|
1842
|
+
);
|
|
1843
|
+
const Mt = Et.exports, Pt = {
|
|
1822
1844
|
"en-US": {
|
|
1823
|
-
run: "Run"
|
|
1845
|
+
run: "Run",
|
|
1846
|
+
expand: "Expand"
|
|
1824
1847
|
}
|
|
1825
|
-
},
|
|
1826
|
-
i18n: { messages:
|
|
1848
|
+
}, Tt = Ve({
|
|
1849
|
+
i18n: { messages: Pt },
|
|
1827
1850
|
name: "bento-code-snippet",
|
|
1828
1851
|
components: {
|
|
1829
|
-
BentoTypography:
|
|
1830
|
-
BentoButton:
|
|
1831
|
-
BentoDropdown:
|
|
1832
|
-
Copy:
|
|
1852
|
+
BentoTypography: it,
|
|
1853
|
+
BentoButton: rt,
|
|
1854
|
+
BentoDropdown: tt,
|
|
1855
|
+
Copy: ot,
|
|
1856
|
+
BaseModal: nt,
|
|
1857
|
+
BentoLoadingIndicator: st,
|
|
1858
|
+
ExpandIcon: Mt
|
|
1833
1859
|
},
|
|
1834
|
-
directives: { BentoTooltipDirective:
|
|
1860
|
+
directives: { BentoTooltipDirective: at },
|
|
1835
1861
|
props: {
|
|
1836
1862
|
/**
|
|
1837
1863
|
* Defines the variant of code-snippet
|
|
1838
1864
|
*/
|
|
1839
1865
|
variant: {
|
|
1840
1866
|
type: String,
|
|
1841
|
-
default:
|
|
1842
|
-
validator: (i) => Object.values(
|
|
1867
|
+
default: pe.MULTILINE,
|
|
1868
|
+
validator: (i) => Object.values(pe).includes(i)
|
|
1843
1869
|
},
|
|
1844
1870
|
/**
|
|
1845
1871
|
* Language name for syntax highlighting rules
|
|
1846
1872
|
*/
|
|
1847
1873
|
lang: {
|
|
1848
1874
|
type: String,
|
|
1849
|
-
default:
|
|
1850
|
-
validator: (i) => Object.values(
|
|
1875
|
+
default: ee.JSON,
|
|
1876
|
+
validator: (i) => Object.values(ee).includes(i)
|
|
1851
1877
|
},
|
|
1852
1878
|
/**
|
|
1853
1879
|
* Label to show in the action-bar, describing the language
|
|
@@ -1878,6 +1904,14 @@ const St = {
|
|
|
1878
1904
|
type: Boolean,
|
|
1879
1905
|
default: !1
|
|
1880
1906
|
},
|
|
1907
|
+
/**
|
|
1908
|
+
* Displays a button that can expand the codeblock into a modal to easily
|
|
1909
|
+
* view large blocks of code.
|
|
1910
|
+
*/
|
|
1911
|
+
expandable: {
|
|
1912
|
+
type: Boolean,
|
|
1913
|
+
default: !1
|
|
1914
|
+
},
|
|
1881
1915
|
/**
|
|
1882
1916
|
* Displays a button that when clicked will emit a run event
|
|
1883
1917
|
* Leaves to the parent component the logic of what to do with it
|
|
@@ -1885,97 +1919,119 @@ const St = {
|
|
|
1885
1919
|
actionableText: {
|
|
1886
1920
|
type: String,
|
|
1887
1921
|
default: "run"
|
|
1922
|
+
},
|
|
1923
|
+
/**
|
|
1924
|
+
* Toggles the loading indicator within the action bar
|
|
1925
|
+
*/
|
|
1926
|
+
loading: {
|
|
1927
|
+
type: Boolean,
|
|
1928
|
+
default: !1
|
|
1888
1929
|
}
|
|
1889
1930
|
},
|
|
1890
|
-
emits: [
|
|
1931
|
+
emits: [se.ACTION, se.CHANGE],
|
|
1891
1932
|
setup(i, { emit: e }) {
|
|
1892
|
-
const { t } =
|
|
1893
|
-
}, l =
|
|
1894
|
-
"b-code-snippet--inline":
|
|
1895
|
-
"b-code-snippet--scrollable":
|
|
1896
|
-
})),
|
|
1897
|
-
|
|
1898
|
-
|
|
1899
|
-
|
|
1900
|
-
const
|
|
1901
|
-
|
|
1902
|
-
|
|
1903
|
-
|
|
1904
|
-
|
|
1905
|
-
|
|
1906
|
-
|
|
1907
|
-
|
|
1908
|
-
|
|
1933
|
+
const { t } = lt(), n = ae(null), r = [], s = () => {
|
|
1934
|
+
}, l = re(() => i.langLabel ?? i.lang.toUpperCase()), f = re(() => i.variant === pe.INLINE), h = re(() => ({
|
|
1935
|
+
"b-code-snippet--inline": f.value,
|
|
1936
|
+
"b-code-snippet--scrollable": !f.value
|
|
1937
|
+
})), C = re(() => ({
|
|
1938
|
+
"b-code-snippet__code-area-content--editable": i.editable
|
|
1939
|
+
})), { loadLang: k } = Lt(i.lang), N = Ae(), A = Ae(), z = new be(), I = new be(), E = new be(), V = ae(""), $ = ae(0);
|
|
1940
|
+
$e(async () => {
|
|
1941
|
+
const g = await k();
|
|
1942
|
+
V.value = i.content;
|
|
1943
|
+
const b = ({ state: p }) => {
|
|
1944
|
+
V.value = p.doc.toString();
|
|
1945
|
+
}, u = [
|
|
1946
|
+
Ue(),
|
|
1947
|
+
We.of([Ke]),
|
|
1948
|
+
z.of(g()),
|
|
1949
|
+
I.of(At),
|
|
1950
|
+
E.of(Le.readOnly.of(!i.editable)),
|
|
1951
|
+
Ie.updateListener.of((p) => b(p))
|
|
1909
1952
|
];
|
|
1910
|
-
i.variant === "multiline" &&
|
|
1911
|
-
const
|
|
1953
|
+
i.variant === "multiline" && u.push([Ge(), Fe()]);
|
|
1954
|
+
const y = Le.create({
|
|
1912
1955
|
doc: i.content,
|
|
1913
|
-
extensions: [...
|
|
1956
|
+
extensions: [...u]
|
|
1914
1957
|
});
|
|
1915
|
-
|
|
1916
|
-
state:
|
|
1917
|
-
parent:
|
|
1958
|
+
$.value = y.doc.length, A.value = new Ie({
|
|
1959
|
+
state: y,
|
|
1960
|
+
parent: N.value
|
|
1918
1961
|
});
|
|
1919
1962
|
}), De(
|
|
1920
1963
|
() => i.content,
|
|
1921
1964
|
() => {
|
|
1922
|
-
const
|
|
1923
|
-
|
|
1965
|
+
const g = i.content.length;
|
|
1966
|
+
A.value.dispatch({
|
|
1924
1967
|
changes: {
|
|
1925
1968
|
from: 0,
|
|
1926
|
-
to:
|
|
1969
|
+
to: $.value,
|
|
1927
1970
|
insert: i.content
|
|
1928
1971
|
}
|
|
1929
|
-
}),
|
|
1972
|
+
}), $.value = g;
|
|
1930
1973
|
}
|
|
1931
1974
|
);
|
|
1932
|
-
const
|
|
1975
|
+
const D = re(() => t(i.actionableText)), w = () => {
|
|
1976
|
+
e(se.ACTION, V.value);
|
|
1977
|
+
};
|
|
1978
|
+
Je(() => {
|
|
1979
|
+
e(se.CHANGE, V.value);
|
|
1980
|
+
});
|
|
1981
|
+
const J = ae(!1);
|
|
1933
1982
|
return {
|
|
1934
|
-
// Enums
|
|
1935
|
-
BentoTypographyElement: nt,
|
|
1936
|
-
BentoButtonVariant: et,
|
|
1937
|
-
BentoCodeSnippetVariant: ne,
|
|
1938
1983
|
// Values
|
|
1939
|
-
container: x,
|
|
1940
|
-
editor: C,
|
|
1941
|
-
currentContents: w,
|
|
1942
|
-
conditionalClasses: h,
|
|
1943
1984
|
availableLanguages: r,
|
|
1985
|
+
codeAreaContentConditionalClasses: C,
|
|
1986
|
+
conditionalClasses: h,
|
|
1987
|
+
container: N,
|
|
1988
|
+
currentContents: V,
|
|
1944
1989
|
displayedLang: l,
|
|
1990
|
+
editor: A,
|
|
1945
1991
|
selectedLanguage: n,
|
|
1992
|
+
showModal: J,
|
|
1993
|
+
isInlineVariant: f,
|
|
1946
1994
|
// Methods
|
|
1947
1995
|
handleChangeLanguage: s,
|
|
1948
|
-
|
|
1949
|
-
|
|
1950
|
-
|
|
1951
|
-
|
|
1996
|
+
onActionClicked: w,
|
|
1997
|
+
runText: D,
|
|
1998
|
+
// Translations
|
|
1999
|
+
t
|
|
1952
2000
|
};
|
|
1953
2001
|
}
|
|
1954
2002
|
});
|
|
1955
|
-
var
|
|
2003
|
+
var jt = function() {
|
|
1956
2004
|
var e = this, t = e._self._c;
|
|
1957
|
-
return e._self._setupProxy, t("div", { staticClass: "b-code-snippet", class: e.conditionalClasses }, [e.
|
|
2005
|
+
return e._self._setupProxy, t("div", { staticClass: "b-code-snippet", class: e.conditionalClasses }, [e.isInlineVariant ? e._e() : t("section", { staticClass: "b-code-snippet__action-bar" }, [t("div", { staticClass: "b-code-snippet__action-bar--start" }, [e.availableLanguages.length > 0 ? t("bento-dropdown", e._b({ staticClass: "b-code-snippet__language-picker", attrs: { disabled: e.availableLanguages.length === 1, items: e.availableLanguages }, on: { input: e.handleChangeLanguage }, model: { value: e.selectedLanguage, callback: function(n) {
|
|
1958
2006
|
e.selectedLanguage = n;
|
|
1959
|
-
}, expression: "selectedLanguage" } }, "bento-dropdown", e.$props, !1)) : e._e(), t("bento-typography", { attrs: { el:
|
|
1960
|
-
|
|
1961
|
-
}
|
|
2007
|
+
}, expression: "selectedLanguage" } }, "bento-dropdown", e.$props, !1)) : e._e(), t("bento-typography", { attrs: { el: "span", stronger: "" } }, [e._v(" " + e._s(e.displayedLang) + " ")])], 1), t("div", { staticClass: "b-code-snippet__action-bar--end" }, [e.loading ? t("bento-loading-indicator") : e._e(), t("copy", { staticClass: "b-structured-list__icon", attrs: { text: e.currentContents } }), e.expandable ? t("bento-button", { attrs: { variant: "tertiary", condensed: "", "aria-label": e.t("expand") }, on: { click: function(n) {
|
|
2008
|
+
e.showModal = !0;
|
|
2009
|
+
} }, scopedSlots: e._u([{ key: "iconLeft", fn: function() {
|
|
2010
|
+
return [t("expand-icon")];
|
|
2011
|
+
}, proxy: !0 }], null, !1, 3789760120) }) : e._e(), e.actionable ? t("bento-button", { attrs: { variant: "primary", tertiary: "", condensed: "" }, on: { click: e.onActionClicked }, scopedSlots: e._u([{ key: "iconLeft", fn: function() {
|
|
2012
|
+
return [t("bento-typography", { staticClass: "b-code-snippet__action-button", attrs: { el: "span" } }, [e._v(" " + e._s(e.runText) + " ")])];
|
|
2013
|
+
}, proxy: !0 }], null, !1, 4293069853) }) : e._e()], 1)]), e.content ? t("code", { staticClass: "b-code-snippet__code-area" }, [t("div", { ref: "container", staticClass: "b-code-snippet__code-area-content", class: e.codeAreaContentConditionalClasses })]) : t("section", [e._t("empty-state", function() {
|
|
1962
2014
|
return [t("div", { staticClass: "b-code-snippet__empty-state" }, [e._v("Nothing to show")])];
|
|
1963
|
-
})], 2)
|
|
1964
|
-
|
|
1965
|
-
|
|
1966
|
-
|
|
1967
|
-
|
|
2015
|
+
})], 2), e.expandable ? t("base-modal", { staticClass: "b-code-snippet__modal", attrs: { "hide-close-button": !0, "custom-padding": "0px", "is-dismissible": !0, "is-open": e.showModal, size: "large" }, on: { "close-modal": function(n) {
|
|
2016
|
+
e.showModal = !1;
|
|
2017
|
+
} }, scopedSlots: e._u([{ key: "content", fn: function() {
|
|
2018
|
+
return [t("bento-code-snippet", e._b({}, "bento-code-snippet", { ...e.$props, expandable: !1 }, !1))];
|
|
2019
|
+
}, proxy: !0 }], null, !1, 3343589027) }) : e._e()], 1);
|
|
2020
|
+
}, Ht = [], Rt = /* @__PURE__ */ Te(
|
|
2021
|
+
Tt,
|
|
2022
|
+
jt,
|
|
2023
|
+
Ht,
|
|
1968
2024
|
!1,
|
|
1969
2025
|
null,
|
|
1970
|
-
"
|
|
2026
|
+
"837f5e08",
|
|
1971
2027
|
null,
|
|
1972
2028
|
null
|
|
1973
2029
|
);
|
|
1974
|
-
const
|
|
2030
|
+
const sn = Rt.exports;
|
|
1975
2031
|
export {
|
|
1976
|
-
|
|
1977
|
-
|
|
1978
|
-
|
|
1979
|
-
|
|
2032
|
+
sn as BentoCodeSnippet,
|
|
2033
|
+
se as BentoCodeSnippetEvent,
|
|
2034
|
+
ee as BentoCodeSnippetSupportedLanguage,
|
|
2035
|
+
pe as BentoCodeSnippetVariant
|
|
1980
2036
|
};
|
|
1981
2037
|
//# sourceMappingURL=code-snippet.js.map
|