@empathyco/x-components 3.0.0-alpha.31 → 3.0.0-alpha.35
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/CHANGELOG.md +132 -0
- package/core/index.js +26 -22
- package/core/index.js.map +1 -1
- package/docs/API-reference/api/x-adapter.empathyrelatedtag.md +1 -0
- package/docs/API-reference/api/x-adapter.empathyrelatedtag.source.md +11 -0
- package/docs/API-reference/api/x-components.baseidtogglepanel.md +0 -1
- package/docs/API-reference/api/x-components.baseresultlink.md +1 -1
- package/docs/API-reference/api/x-components.defaultsessionservice.clearsessionid.md +2 -0
- package/docs/API-reference/api/x-components.defaultsessionservice.getsessionid.md +4 -0
- package/docs/API-reference/api/x-components.defaultsessionservice.md +3 -3
- package/docs/API-reference/api/x-components.defaultsessionservice.session_id_key.md +3 -1
- package/docs/API-reference/api/x-components.featurelocation.md +1 -1
- package/docs/API-reference/api/x-components.fixedheaderandasideslayout.isbackdropvisible.md +11 -0
- package/docs/API-reference/api/x-components.fixedheaderandasideslayout.leftasideanimation.md +11 -0
- package/docs/API-reference/api/x-components.fixedheaderandasideslayout.md +30 -0
- package/docs/API-reference/api/x-components.fixedheaderandasideslayout.rightasideanimation.md +11 -0
- package/docs/API-reference/api/x-components.fixedheaderandasideslayout.scrollposition.md +11 -0
- package/docs/API-reference/api/x-components.fixedheaderandasideslayout.setposition.md +22 -0
- package/docs/API-reference/api/x-components.getrootxcomponent.md +2 -2
- package/docs/API-reference/api/x-components.globalxbus.created.md +15 -0
- package/docs/API-reference/api/x-components.globalxbus.md +21 -0
- package/docs/API-reference/api/x-components.isxcomponent.md +2 -2
- package/docs/API-reference/api/x-components.maybearray.md +13 -0
- package/docs/API-reference/api/x-components.md +16 -7
- package/docs/API-reference/api/x-components.namespaceddebounce.md +2 -2
- package/docs/API-reference/api/x-components.namespacedthrottle.md +2 -2
- package/docs/API-reference/api/{x-components.namespacedtimeretrieving.md → x-components.namespacedtimeselector.md} +3 -3
- package/docs/API-reference/api/x-components.namespacedtimewireoperator.md +3 -3
- package/docs/API-reference/api/x-components.relatedtag.highlightcurated.md +13 -0
- package/docs/API-reference/api/x-components.relatedtag.md +1 -0
- package/docs/API-reference/api/x-components.relatedtags.highlightcurated.md +13 -0
- package/docs/API-reference/api/x-components.searchxevents.md +2 -0
- package/docs/API-reference/api/x-components.searchxevents.userclickedabanner.md +13 -0
- package/docs/API-reference/api/x-components.searchxevents.userclickedapromoted.md +13 -0
- package/docs/API-reference/api/x-components.setconsent.md +1 -1
- package/docs/API-reference/api/x-components.setquerytaggingdebounce.md +1 -1
- package/docs/API-reference/api/x-components.setsessionduration.md +1 -1
- package/docs/API-reference/api/x-components.snippetcallbacks.md +15 -0
- package/docs/API-reference/api/x-components.snippetconfig.callbacks.md +13 -0
- package/docs/API-reference/api/x-components.snippetconfig.isspa.md +13 -0
- package/docs/API-reference/api/x-components.snippetconfig.md +2 -0
- package/docs/API-reference/api/x-components.tagging.activeconsent.md +18 -0
- package/docs/API-reference/api/x-components.tagging.consent.md +13 -0
- package/docs/API-reference/api/x-components.tagging.md +28 -0
- package/docs/API-reference/api/x-components.tagging.render.md +15 -0
- package/docs/API-reference/api/x-components.tagicon.md +11 -0
- package/docs/API-reference/api/x-components.throttle.md +3 -3
- package/docs/API-reference/api/x-components.timedwireoperatoroptions.cancelon.md +13 -0
- package/docs/API-reference/api/x-components.timedwireoperatoroptions.forceon.md +13 -0
- package/docs/API-reference/api/x-components.timedwireoperatoroptions.md +21 -0
- package/docs/API-reference/api/{x-components.timeretrieving.md → x-components.timeselector.md} +3 -3
- package/docs/API-reference/api/x-components.trackaddtocartwire.md +13 -0
- package/docs/API-reference/api/{x-components.trackwire.md → x-components.trackquerywire.md} +3 -3
- package/docs/API-reference/api/x-components.trackresultclickedwire.md +13 -0
- package/docs/API-reference/api/x-components.xeventlisteners.md +17 -0
- package/docs/API-reference/api/x-components.xeventstypes.md +1 -1
- package/docs/API-reference/api/x-components.xeventstypes.snippetcallbackexecuted.md +16 -0
- package/docs/API-reference/api/x-components.xinstaller.md +1 -1
- package/docs/API-reference/api/x-types.relatedtag.iscurated.md +13 -0
- package/docs/API-reference/api/x-types.relatedtag.md +1 -0
- package/docs/API-reference/components/common/animations/x-components.animate-width.md +6 -7
- package/docs/API-reference/components/common/animations/x-components.collapse-from-top.md +7 -8
- package/docs/API-reference/components/common/animations/x-components.collapse-height.md +8 -9
- package/docs/API-reference/components/common/animations/x-components.collapse-width.md +8 -9
- package/docs/API-reference/components/common/animations/x-components.cross-fade.md +7 -8
- package/docs/API-reference/components/common/animations/x-components.fade-and-slide.md +7 -8
- package/docs/API-reference/components/common/animations/x-components.staggered-fade-and-slide.md +7 -8
- package/docs/API-reference/components/common/{x-components.staggering-transition-group.md → animations/x-components.staggering-transition-group.md} +8 -9
- package/docs/API-reference/components/common/animations/x-components.translate-from-left.md +7 -8
- package/docs/API-reference/components/common/animations/x-components.translate-from-right.md +7 -8
- package/docs/API-reference/components/common/column-picker/x-components.base-column-picker-dropdown.md +12 -13
- package/docs/API-reference/components/common/column-picker/x-components.base-column-picker-list.md +11 -12
- package/docs/API-reference/components/common/currency/x-components.base-currency.md +9 -12
- package/docs/API-reference/components/common/filters/labels/x-components.base-price-filter-label.md +9 -10
- package/docs/API-reference/components/common/filters/labels/x-components.base-rating-filter-label.md +11 -12
- package/docs/API-reference/components/common/icons/x-components.arrow.md +3 -4
- package/docs/API-reference/components/common/icons/x-components.bag.md +3 -4
- package/docs/API-reference/components/common/icons/x-components.bar-code.md +4 -5
- package/docs/API-reference/components/common/icons/x-components.barcode-tiny.md +4 -5
- package/docs/API-reference/components/common/icons/x-components.cart.md +3 -4
- package/docs/API-reference/components/common/icons/x-components.check-tiny.md +4 -5
- package/docs/API-reference/components/common/icons/x-components.check.md +3 -4
- package/docs/API-reference/components/common/icons/x-components.checkbox-card-selected.md +4 -5
- package/docs/API-reference/components/common/icons/x-components.checkbox-card-unselected.md +4 -5
- package/docs/API-reference/components/common/icons/x-components.checkbox-selected.md +4 -5
- package/docs/API-reference/components/common/icons/x-components.checkbox-unselected.md +4 -5
- package/docs/API-reference/components/common/icons/x-components.chevron-down.md +4 -5
- package/docs/API-reference/components/common/icons/x-components.chevron-left.md +4 -5
- package/docs/API-reference/components/common/icons/x-components.chevron-right.md +4 -5
- package/docs/API-reference/components/common/icons/x-components.chevron-tiny-down.md +4 -5
- package/docs/API-reference/components/common/icons/x-components.chevron-tiny-left.md +4 -5
- package/docs/API-reference/components/common/icons/x-components.chevron-tiny-right.md +4 -5
- package/docs/API-reference/components/common/icons/x-components.chevron-tiny-up.md +4 -5
- package/docs/API-reference/components/common/icons/x-components.chevron-up.md +4 -5
- package/docs/API-reference/components/common/icons/x-components.cross-tiny.md +4 -5
- package/docs/API-reference/components/common/icons/x-components.cross.md +3 -4
- package/docs/API-reference/components/common/icons/x-components.filters.md +3 -4
- package/docs/API-reference/components/common/icons/x-components.grid-1-col.md +4 -5
- package/docs/API-reference/components/common/icons/x-components.grid-2-col.md +4 -5
- package/docs/API-reference/components/common/icons/x-components.hide.md +3 -4
- package/docs/API-reference/components/common/icons/x-components.history-tiny.md +4 -5
- package/docs/API-reference/components/common/icons/x-components.history.md +3 -4
- package/docs/API-reference/components/common/icons/x-components.menu.md +3 -4
- package/docs/API-reference/components/common/icons/x-components.minus-tiny.md +4 -5
- package/docs/API-reference/components/common/icons/x-components.minus.md +3 -4
- package/docs/API-reference/components/common/icons/x-components.nq-1.md +4 -5
- package/docs/API-reference/components/common/icons/x-components.nq-2.md +4 -5
- package/docs/API-reference/components/common/icons/x-components.nq-3.md +4 -5
- package/docs/API-reference/components/common/icons/x-components.nq-4.md +4 -5
- package/docs/API-reference/components/common/icons/x-components.plus.md +3 -4
- package/docs/API-reference/components/common/icons/x-components.search-tiny.md +4 -5
- package/docs/API-reference/components/common/icons/x-components.search.md +3 -4
- package/docs/API-reference/components/common/icons/x-components.show.md +3 -4
- package/docs/API-reference/components/common/icons/x-components.star.md +3 -4
- package/docs/API-reference/components/common/icons/x-components.tag.md +7 -0
- package/docs/API-reference/components/common/icons/x-components.trash-open.md +4 -5
- package/docs/API-reference/components/common/icons/x-components.trash.md +3 -4
- package/docs/API-reference/components/common/icons/x-components.trending-tiny.md +4 -5
- package/docs/API-reference/components/common/icons/x-components.trending.md +3 -4
- package/docs/API-reference/components/common/icons/x-components.user.md +3 -4
- package/docs/API-reference/components/common/layouts/x-components.fixed-header-and-asides-layout.md +8 -9
- package/docs/API-reference/components/common/layouts/x-components.multi-column-max-width-layout.md +8 -9
- package/docs/API-reference/components/common/layouts/x-components.single-column-layout.md +6 -5
- package/docs/API-reference/components/common/modals/x-components.base-events-modal-close.md +10 -11
- package/docs/API-reference/components/common/modals/x-components.base-events-modal-open.md +10 -11
- package/docs/API-reference/components/common/modals/x-components.base-events-modal.md +15 -16
- package/docs/API-reference/components/common/modals/x-components.base-id-modal-close.md +9 -10
- package/docs/API-reference/components/common/modals/x-components.base-id-modal-open.md +9 -10
- package/docs/API-reference/components/common/modals/x-components.base-id-modal.md +11 -12
- package/docs/API-reference/components/common/modals/x-components.base-modal.md +7 -8
- package/docs/API-reference/components/common/panels/x-components.base-header-toggle-panel.md +11 -12
- package/docs/API-reference/components/common/panels/x-components.base-id-toggle-panel-button.md +10 -11
- package/docs/API-reference/components/common/panels/x-components.base-id-toggle-panel.md +10 -11
- package/docs/API-reference/components/common/panels/x-components.base-toggle-panel.md +8 -9
- package/docs/API-reference/components/common/result/x-components.base-result-add-to-cart.md +9 -10
- package/docs/API-reference/components/common/result/x-components.base-result-current-price.md +10 -11
- package/docs/API-reference/components/common/result/x-components.base-result-fallback-image.md +4 -5
- package/docs/API-reference/components/common/result/x-components.base-result-image.md +9 -10
- package/docs/API-reference/components/common/result/x-components.base-result-link.md +15 -24
- package/docs/API-reference/components/common/result/x-components.base-result-placeholder-image.md +4 -5
- package/docs/API-reference/components/common/result/x-components.base-result-previous-price.md +9 -10
- package/docs/API-reference/components/common/scroll/x-components.base-scroll.md +8 -9
- package/docs/API-reference/components/common/suggestions/x-components.base-suggestion.md +10 -11
- package/docs/API-reference/components/common/suggestions/x-components.base-suggestions.md +7 -8
- package/docs/API-reference/components/common/x-components.auto-progress-bar.md +5 -6
- package/docs/API-reference/components/common/x-components.base-dropdown.md +8 -9
- package/docs/API-reference/components/common/x-components.base-event-button.md +11 -12
- package/docs/API-reference/components/common/x-components.base-grid.md +15 -16
- package/docs/API-reference/components/common/x-components.base-keyboard-navigation.md +10 -11
- package/docs/API-reference/components/common/x-components.base-rating.md +10 -11
- package/docs/API-reference/components/common/x-components.base-variable-column-grid.md +10 -11
- package/docs/API-reference/components/common/x-components.global-x-bus.md +50 -0
- package/docs/API-reference/components/common/x-components.items-list.md +6 -5
- package/docs/API-reference/components/common/x-components.location-provider.md +6 -7
- package/docs/API-reference/components/common/x-components.sliding-panel.md +10 -11
- package/docs/API-reference/components/common/x-components.snippet-callbacks.md +36 -0
- package/docs/API-reference/components/device/x-components.device-detector.md +8 -9
- package/docs/API-reference/components/empathize/x-components.empathize.md +8 -9
- package/docs/API-reference/components/extra-params/x-components.extra-params.md +7 -8
- package/docs/API-reference/components/extra-params/x-components.renderless-extra-param.md +9 -10
- package/docs/API-reference/components/extra-params/x-components.snippet-config-extra-params.md +6 -7
- package/docs/API-reference/components/facets/x-components.clear-filters.md +9 -10
- package/docs/API-reference/components/facets/x-components.facets/facets-provider.md +10 -11
- package/docs/API-reference/components/facets/x-components.facets/facets.md +12 -13
- package/docs/API-reference/components/facets/x-components.filters/all-filter.md +15 -16
- package/docs/API-reference/components/facets/x-components.filters/base-filter.md +12 -13
- package/docs/API-reference/components/facets/x-components.filters/editable-number-range-filter.md +12 -13
- package/docs/API-reference/components/facets/x-components.filters/hierarchical-filter.md +9 -10
- package/docs/API-reference/components/facets/x-components.filters/number-range-filter.md +9 -10
- package/docs/API-reference/components/facets/x-components.filters/renderless-filter.md +12 -13
- package/docs/API-reference/components/facets/x-components.filters/simple-filter.md +10 -11
- package/docs/API-reference/components/facets/x-components.lists/exclude-filters-with-no-results.md +11 -12
- package/docs/API-reference/components/facets/x-components.lists/filters-list.md +11 -12
- package/docs/API-reference/components/facets/x-components.lists/filters-search.md +9 -10
- package/docs/API-reference/components/facets/x-components.lists/selected-filters-list.md +12 -13
- package/docs/API-reference/components/facets/x-components.lists/selected-filters.md +11 -12
- package/docs/API-reference/components/facets/x-components.lists/sliced-filters.md +11 -12
- package/docs/API-reference/components/facets/x-components.lists/sorted-filters.md +11 -12
- package/docs/API-reference/components/history-queries/x-components.clear-history-queries.md +10 -11
- package/docs/API-reference/components/history-queries/x-components.history-queries.md +10 -11
- package/docs/API-reference/components/history-queries/x-components.history-query.md +11 -12
- package/docs/API-reference/components/history-queries/x-components.remove-history-query.md +10 -11
- package/docs/API-reference/components/identifier-results/x-components.identifier-result.md +9 -10
- package/docs/API-reference/components/identifier-results/x-components.identifier-results.md +10 -11
- package/docs/API-reference/components/next-queries/x-components.next-queries-list.md +7 -8
- package/docs/API-reference/components/next-queries/x-components.next-queries.md +14 -15
- package/docs/API-reference/components/next-queries/x-components.next-query.md +11 -12
- package/docs/API-reference/components/popular-searches/x-components.popular-search.md +11 -12
- package/docs/API-reference/components/popular-searches/x-components.popular-searches.md +13 -14
- package/docs/API-reference/components/query-suggestions/x-components.query-suggestion.md +8 -9
- package/docs/API-reference/components/query-suggestions/x-components.query-suggestions.md +8 -9
- package/docs/API-reference/components/recommendations/x-components.recommendations.md +14 -15
- package/docs/API-reference/components/related-tags/x-components.related-tag.md +19 -17
- package/docs/API-reference/components/related-tags/x-components.related-tags.md +19 -19
- package/docs/API-reference/components/scroll/x-components.main-scroll-item.md +7 -8
- package/docs/API-reference/components/scroll/x-components.main-scroll.md +7 -8
- package/docs/API-reference/components/scroll/x-components.scroll-to-top.md +9 -10
- package/docs/API-reference/components/scroll/x-components.scroll.md +25 -30
- package/docs/API-reference/components/scroll/x-components.window-scroll.md +13 -16
- package/docs/API-reference/components/search/x-components.banner.md +8 -9
- package/docs/API-reference/components/search/x-components.banners-list.md +7 -8
- package/docs/API-reference/components/search/x-components.partial-query-button.md +11 -12
- package/docs/API-reference/components/search/x-components.partial-results-list.md +11 -12
- package/docs/API-reference/components/search/x-components.promoted.md +7 -8
- package/docs/API-reference/components/search/x-components.promoteds-list.md +7 -8
- package/docs/API-reference/components/search/x-components.redirection.md +8 -9
- package/docs/API-reference/components/search/x-components.results-list.md +7 -8
- package/docs/API-reference/components/search/x-components.sort-dropdown.md +8 -9
- package/docs/API-reference/components/search/x-components.sort-list.md +8 -9
- package/docs/API-reference/components/search/x-components.spellcheck-button.md +11 -12
- package/docs/API-reference/components/search/x-components.spellcheck.md +11 -12
- package/docs/API-reference/components/search-box/x-components.clear-search-input.md +6 -7
- package/docs/API-reference/components/search-box/x-components.search-button.md +6 -7
- package/docs/API-reference/components/search-box/x-components.search-input.md +7 -8
- package/docs/API-reference/components/tagging/x-components.tagging.md +8 -5
- package/docs/API-reference/components/url/x-components.url-handler.md +7 -8
- package/docs/build-search-ui/README.md +0 -5
- package/docs/build-search-ui/web-archetype-development-guide.md +178 -0
- package/docs/build-search-ui/web-archetype-integration-guide.md +146 -143
- package/docs/build-search-ui/web-use-x-components-guide.md +0 -5
- package/docs/build-search-ui/web-x-components-integration-guide.md +3 -8
- package/docs/build-search-ui/x-architecture/README.md +0 -5
- package/js/components/animations/animate-width.vue.js +3 -3
- package/js/components/animations/animate-width.vue.js.map +1 -1
- package/js/components/animations/collapse-from-top.vue.js +3 -3
- package/js/components/animations/collapse-from-top.vue.js.map +1 -1
- package/js/components/animations/collapse-height.vue.js +5 -5
- package/js/components/animations/collapse-height.vue.js.map +1 -1
- package/js/components/animations/collapse-width.vue.js +5 -5
- package/js/components/animations/collapse-width.vue.js.map +1 -1
- package/js/components/animations/cross-fade.vue.js +3 -3
- package/js/components/animations/cross-fade.vue.js.map +1 -1
- package/js/components/animations/fade-and-slide.vue.js +4 -4
- package/js/components/animations/fade-and-slide.vue.js.map +1 -1
- package/js/components/animations/staggered-fade-and-slide.vue.js +4 -4
- package/js/components/animations/staggered-fade-and-slide.vue.js.map +1 -1
- package/js/components/animations/staggered-fade-and-slide.vue_rollup-plugin-vue=script.js +1 -1
- package/js/components/animations/staggered-fade-and-slide.vue_rollup-plugin-vue=script.js.map +1 -1
- package/js/components/{staggering-transition-group.vue.js → animations/staggering-transition-group.vue.js} +2 -2
- package/js/components/animations/staggering-transition-group.vue.js.map +1 -0
- package/js/components/{staggering-transition-group.vue_rollup-plugin-vue=script.js → animations/staggering-transition-group.vue_rollup-plugin-vue=script.js} +17 -17
- package/js/components/animations/staggering-transition-group.vue_rollup-plugin-vue=script.js.map +1 -0
- package/js/components/animations/translate-from-left.vue.js +3 -3
- package/js/components/animations/translate-from-left.vue.js.map +1 -1
- package/js/components/animations/translate-from-right.vue.js +3 -3
- package/js/components/animations/translate-from-right.vue.js.map +1 -1
- package/js/components/auto-progress-bar.vue.js +4 -5
- package/js/components/auto-progress-bar.vue.js.map +1 -1
- package/js/components/base-dropdown.vue.js +35 -47
- package/js/components/base-dropdown.vue.js.map +1 -1
- package/js/components/base-event-button.vue.js +1 -1
- package/js/components/base-event-button.vue.js.map +1 -1
- package/js/components/base-grid.vue.js +9 -11
- package/js/components/base-grid.vue.js.map +1 -1
- package/js/components/base-keyboard-navigation.vue.js +7 -10
- package/js/components/base-keyboard-navigation.vue.js.map +1 -1
- package/js/components/base-rating.vue.js +21 -22
- package/js/components/base-rating.vue.js.map +1 -1
- package/js/components/base-variable-column-grid.vue.js +6 -7
- package/js/components/base-variable-column-grid.vue.js.map +1 -1
- package/js/components/column-picker/base-column-picker-dropdown.vue.js +11 -14
- package/js/components/column-picker/base-column-picker-dropdown.vue.js.map +1 -1
- package/js/components/column-picker/base-column-picker-list.vue.js +11 -13
- package/js/components/column-picker/base-column-picker-list.vue.js.map +1 -1
- package/js/components/currency/base-currency.vue.js +2 -3
- package/js/components/currency/base-currency.vue.js.map +1 -1
- package/js/components/filters/labels/base-price-filter-label.vue.js.map +1 -1
- package/js/components/filters/labels/base-rating-filter-label.vue.js +7 -8
- package/js/components/filters/labels/base-rating-filter-label.vue.js.map +1 -1
- package/js/components/global-x-bus.vue.js +39 -0
- package/js/components/global-x-bus.vue.js.map +1 -0
- package/js/components/global-x-bus.vue_rollup-plugin-vue=script.js +47 -0
- package/js/components/global-x-bus.vue_rollup-plugin-vue=script.js.map +1 -0
- package/js/components/icons/arrow.vue.js +4 -6
- package/js/components/icons/arrow.vue.js.map +1 -1
- package/js/components/icons/bag.vue.js +8 -12
- package/js/components/icons/bag.vue.js.map +1 -1
- package/js/components/icons/bar-code.vue.js +6 -9
- package/js/components/icons/bar-code.vue.js.map +1 -1
- package/js/components/icons/barcode-tiny.vue.js +6 -9
- package/js/components/icons/barcode-tiny.vue.js.map +1 -1
- package/js/components/icons/cart.vue.js +10 -13
- package/js/components/icons/cart.vue.js.map +1 -1
- package/js/components/icons/check-tiny.vue.js +4 -6
- package/js/components/icons/check-tiny.vue.js.map +1 -1
- package/js/components/icons/check.vue.js +4 -6
- package/js/components/icons/check.vue.js.map +1 -1
- package/js/components/icons/checkbox-card-selected.vue.js +5 -7
- package/js/components/icons/checkbox-card-selected.vue.js.map +1 -1
- package/js/components/icons/checkbox-card-unselected.vue.js +5 -7
- package/js/components/icons/checkbox-card-unselected.vue.js.map +1 -1
- package/js/components/icons/checkbox-selected.vue.js +5 -7
- package/js/components/icons/checkbox-selected.vue.js.map +1 -1
- package/js/components/icons/checkbox-unselected.vue.js +6 -6
- package/js/components/icons/chevron-down.vue.js +6 -8
- package/js/components/icons/chevron-down.vue.js.map +1 -1
- package/js/components/icons/chevron-left.vue.js +6 -8
- package/js/components/icons/chevron-left.vue.js.map +1 -1
- package/js/components/icons/chevron-right.vue.js +4 -6
- package/js/components/icons/chevron-right.vue.js.map +1 -1
- package/js/components/icons/chevron-tiny-down.vue.js +6 -8
- package/js/components/icons/chevron-tiny-down.vue.js.map +1 -1
- package/js/components/icons/chevron-tiny-left.vue.js +6 -8
- package/js/components/icons/chevron-tiny-left.vue.js.map +1 -1
- package/js/components/icons/chevron-tiny-right.vue.js +6 -8
- package/js/components/icons/chevron-tiny-right.vue.js.map +1 -1
- package/js/components/icons/chevron-tiny-up.vue.js +6 -8
- package/js/components/icons/chevron-tiny-up.vue.js.map +1 -1
- package/js/components/icons/chevron-up.vue.js +6 -8
- package/js/components/icons/chevron-up.vue.js.map +1 -1
- package/js/components/icons/cross-tiny.vue.js +4 -6
- package/js/components/icons/cross-tiny.vue.js.map +1 -1
- package/js/components/icons/cross.vue.js +4 -6
- package/js/components/icons/cross.vue.js.map +1 -1
- package/js/components/icons/filters.vue.js +10 -15
- package/js/components/icons/filters.vue.js.map +1 -1
- package/js/components/icons/grid-1-col.vue.js +6 -9
- package/js/components/icons/grid-1-col.vue.js.map +1 -1
- package/js/components/icons/grid-2-col.vue.js +8 -10
- package/js/components/icons/grid-2-col.vue.js.map +1 -1
- package/js/components/icons/hide.vue.js +10 -15
- package/js/components/icons/hide.vue.js.map +1 -1
- package/js/components/icons/history-tiny.vue.js +9 -12
- package/js/components/icons/history-tiny.vue.js.map +1 -1
- package/js/components/icons/history.vue.js +9 -12
- package/js/components/icons/history.vue.js.map +1 -1
- package/js/components/icons/menu.vue.js +6 -8
- package/js/components/icons/menu.vue.js.map +1 -1
- package/js/components/icons/minus-tiny.vue.js +4 -6
- package/js/components/icons/minus-tiny.vue.js.map +1 -1
- package/js/components/icons/minus.vue.js +4 -6
- package/js/components/icons/minus.vue.js.map +1 -1
- package/js/components/icons/nq-1.vue.js +4 -6
- package/js/components/icons/nq-1.vue.js.map +1 -1
- package/js/components/icons/nq-2.vue.js +4 -6
- package/js/components/icons/nq-2.vue.js.map +1 -1
- package/js/components/icons/nq-3.vue.js +6 -8
- package/js/components/icons/nq-3.vue.js.map +1 -1
- package/js/components/icons/nq-4.vue.js +9 -12
- package/js/components/icons/nq-4.vue.js.map +1 -1
- package/js/components/icons/plus.vue.js +4 -6
- package/js/components/icons/plus.vue.js.map +1 -1
- package/js/components/icons/search-tiny.vue.js +6 -9
- package/js/components/icons/search-tiny.vue.js.map +1 -1
- package/js/components/icons/search.vue.js +6 -8
- package/js/components/icons/search.vue.js.map +1 -1
- package/js/components/icons/show.vue.js +7 -10
- package/js/components/icons/show.vue.js.map +1 -1
- package/js/components/icons/star.vue.js +6 -9
- package/js/components/icons/star.vue.js.map +1 -1
- package/js/components/icons/tag.vue.js +59 -0
- package/js/components/icons/tag.vue.js.map +1 -0
- package/js/components/icons/tag.vue_rollup-plugin-vue=script.js +4 -0
- package/js/components/icons/tag.vue_rollup-plugin-vue=script.js.map +1 -0
- package/js/components/icons/trash-open.vue.js +12 -15
- package/js/components/icons/trash-open.vue.js.map +1 -1
- package/js/components/icons/trash.vue.js +8 -11
- package/js/components/icons/trash.vue.js.map +1 -1
- package/js/components/icons/trending-tiny.vue.js +8 -10
- package/js/components/icons/trending-tiny.vue.js.map +1 -1
- package/js/components/icons/trending.vue.js +8 -10
- package/js/components/icons/trending.vue.js.map +1 -1
- package/js/components/icons/user.vue.js +6 -9
- package/js/components/icons/user.vue.js.map +1 -1
- package/js/components/items-list.vue.js +6 -7
- package/js/components/items-list.vue.js.map +1 -1
- package/js/components/layouts/fixed-header-and-asides-layout.vue.js +212 -0
- package/js/components/layouts/fixed-header-and-asides-layout.vue.js.map +1 -0
- package/js/components/layouts/fixed-header-and-asides-layout.vue_rollup-plugin-vue=script.js +57 -0
- package/js/components/layouts/fixed-header-and-asides-layout.vue_rollup-plugin-vue=script.js.map +1 -0
- package/js/components/layouts/multi-column-max-width-layout.vue.js +57 -91
- package/js/components/layouts/multi-column-max-width-layout.vue.js.map +1 -1
- package/js/components/layouts/multi-column-max-width-layout.vue_rollup-plugin-vue=script.js +1 -1
- package/js/components/layouts/single-column-layout.vue.js +39 -67
- package/js/components/layouts/single-column-layout.vue.js.map +1 -1
- package/js/components/layouts/single-column-layout.vue_rollup-plugin-vue=script.js +1 -1
- package/js/components/modals/base-events-modal-close.vue.js +2 -2
- package/js/components/modals/base-events-modal-close.vue.js.map +1 -1
- package/js/components/modals/base-events-modal-open.vue.js +2 -2
- package/js/components/modals/base-events-modal-open.vue.js.map +1 -1
- package/js/components/modals/base-events-modal.vue.js +3 -3
- package/js/components/modals/base-events-modal.vue.js.map +1 -1
- package/js/components/modals/base-id-modal-close.vue.js +2 -2
- package/js/components/modals/base-id-modal-close.vue.js.map +1 -1
- package/js/components/modals/base-id-modal-open.vue.js +2 -2
- package/js/components/modals/base-id-modal-open.vue.js.map +1 -1
- package/js/components/modals/base-id-modal.vue.js +3 -3
- package/js/components/modals/base-id-modal.vue.js.map +1 -1
- package/js/components/modals/base-modal.vue.js +11 -13
- package/js/components/modals/base-modal.vue.js.map +1 -1
- package/js/components/panels/base-header-toggle-panel.vue.js +7 -9
- package/js/components/panels/base-header-toggle-panel.vue.js.map +1 -1
- package/js/components/panels/base-id-toggle-panel-button.vue.js +2 -2
- package/js/components/panels/base-id-toggle-panel-button.vue.js.map +1 -1
- package/js/components/panels/base-id-toggle-panel.vue.js +1 -1
- package/js/components/panels/base-id-toggle-panel.vue.js.map +1 -1
- package/js/components/panels/base-id-toggle-panel.vue_rollup-plugin-vue=script.js +4 -9
- package/js/components/panels/base-id-toggle-panel.vue_rollup-plugin-vue=script.js.map +1 -1
- package/js/components/panels/base-toggle-panel.vue.js +3 -4
- package/js/components/panels/base-toggle-panel.vue.js.map +1 -1
- package/js/components/result/base-result-add-to-cart.vue.js +2 -2
- package/js/components/result/base-result-add-to-cart.vue.js.map +1 -1
- package/js/components/result/base-result-current-price.vue.js +6 -8
- package/js/components/result/base-result-current-price.vue.js.map +1 -1
- package/js/components/result/base-result-fallback-image.vue.js +7 -9
- package/js/components/result/base-result-fallback-image.vue.js.map +1 -1
- package/js/components/result/base-result-image.vue.js +11 -14
- package/js/components/result/base-result-image.vue.js.map +1 -1
- package/js/components/result/base-result-link.vue.js +8 -8
- package/js/components/result/base-result-link.vue.js.map +1 -1
- package/js/components/result/base-result-link.vue_rollup-plugin-vue=script.js +3 -12
- package/js/components/result/base-result-link.vue_rollup-plugin-vue=script.js.map +1 -1
- package/js/components/result/base-result-placeholder-image.vue.js +7 -9
- package/js/components/result/base-result-placeholder-image.vue.js.map +1 -1
- package/js/components/result/base-result-previous-price.vue.js +7 -9
- package/js/components/result/base-result-previous-price.vue.js.map +1 -1
- package/js/components/scroll/base-scroll.vue.js +4 -4
- package/js/components/scroll/base-scroll.vue.js.map +1 -1
- package/js/components/sliding-panel.vue.js +13 -16
- package/js/components/sliding-panel.vue.js.map +1 -1
- package/js/components/snippet-callbacks.vue.js +47 -0
- package/js/components/snippet-callbacks.vue.js.map +1 -0
- package/js/components/snippet-callbacks.vue_rollup-plugin-vue=script.js +58 -0
- package/js/components/snippet-callbacks.vue_rollup-plugin-vue=script.js.map +1 -0
- package/js/components/suggestions/base-suggestion.vue.js +6 -8
- package/js/components/suggestions/base-suggestion.vue.js.map +1 -1
- package/js/components/suggestions/base-suggestions.vue.js +8 -9
- package/js/components/suggestions/base-suggestions.vue.js.map +1 -1
- package/js/components/x-component.mixin.js +1 -4
- package/js/components/x-component.mixin.js.map +1 -1
- package/js/components/x-component.utils.js +4 -20
- package/js/components/x-component.utils.js.map +1 -1
- package/js/index.js +35 -30
- package/js/index.js.map +1 -1
- package/js/plugins/x-plugin.alias.js +21 -20
- package/js/plugins/x-plugin.alias.js.map +1 -1
- package/js/plugins/x-plugin.mixin.js +2 -2
- package/js/plugins/x-plugin.mixin.js.map +1 -1
- package/js/utils/origin.js +5 -3
- package/js/utils/origin.js.map +1 -1
- package/js/utils/storage.js +2 -2
- package/js/utils/storage.js.map +1 -1
- package/js/wiring/namespaced-wires.operators.js +3 -4
- package/js/wiring/namespaced-wires.operators.js.map +1 -1
- package/js/wiring/wires-operators.utils.js +55 -0
- package/js/wiring/wires-operators.utils.js.map +1 -0
- package/js/wiring/wires.operators.js +17 -12
- package/js/wiring/wires.operators.js.map +1 -1
- package/js/x-installer/x-installer/x-installer.js +1 -1
- package/js/x-installer/x-installer/x-installer.js.map +1 -1
- package/js/x-modules/device/components/device-detector.vue.js +2 -2
- package/js/x-modules/empathize/components/empathize.vue.js +5 -6
- package/js/x-modules/empathize/components/empathize.vue.js.map +1 -1
- package/js/x-modules/empathize/components/empathize.vue_rollup-plugin-vue=script.js +1 -1
- package/js/x-modules/extra-params/components/extra-params.vue_rollup-plugin-vue=script.js +16 -12
- package/js/x-modules/extra-params/components/extra-params.vue_rollup-plugin-vue=script.js.map +1 -1
- package/js/x-modules/extra-params/components/renderless-extra-param.vue.js +3 -4
- package/js/x-modules/extra-params/components/renderless-extra-param.vue.js.map +1 -1
- package/js/x-modules/extra-params/components/renderless-extra-param.vue_rollup-plugin-vue=script.js +16 -12
- package/js/x-modules/extra-params/components/renderless-extra-param.vue_rollup-plugin-vue=script.js.map +1 -1
- package/js/x-modules/extra-params/components/snippet-config-extra-params.vue.js +1 -1
- package/js/x-modules/extra-params/components/snippet-config-extra-params.vue.js.map +1 -1
- package/js/x-modules/extra-params/components/snippet-config-extra-params.vue_rollup-plugin-vue=script.js +25 -12
- package/js/x-modules/extra-params/components/snippet-config-extra-params.vue_rollup-plugin-vue=script.js.map +1 -1
- package/js/x-modules/facets/components/clear-filters.vue.js +6 -8
- package/js/x-modules/facets/components/clear-filters.vue.js.map +1 -1
- package/js/x-modules/facets/components/clear-filters.vue_rollup-plugin-vue=script.js +16 -12
- package/js/x-modules/facets/components/clear-filters.vue_rollup-plugin-vue=script.js.map +1 -1
- package/js/x-modules/facets/components/facets/facets-provider.vue.js +2 -2
- package/js/x-modules/facets/components/facets/facets-provider.vue.js.map +1 -1
- package/js/x-modules/facets/components/facets/facets-provider.vue_rollup-plugin-vue=script.js +20 -23
- package/js/x-modules/facets/components/facets/facets-provider.vue_rollup-plugin-vue=script.js.map +1 -1
- package/js/x-modules/facets/components/facets/facets.vue.js +12 -13
- package/js/x-modules/facets/components/facets/facets.vue.js.map +1 -1
- package/js/x-modules/facets/components/filters/all-filter.vue.js +5 -6
- package/js/x-modules/facets/components/filters/all-filter.vue.js.map +1 -1
- package/js/x-modules/facets/components/filters/all-filter.vue_rollup-plugin-vue=script.js +16 -12
- package/js/x-modules/facets/components/filters/all-filter.vue_rollup-plugin-vue=script.js.map +1 -1
- package/js/x-modules/facets/components/filters/base-filter.vue.js +5 -6
- package/js/x-modules/facets/components/filters/base-filter.vue.js.map +1 -1
- package/js/x-modules/facets/components/filters/base-filter.vue_rollup-plugin-vue=script.js +16 -12
- package/js/x-modules/facets/components/filters/base-filter.vue_rollup-plugin-vue=script.js.map +1 -1
- package/js/x-modules/facets/components/filters/editable-number-range-filter.vue.js +20 -24
- package/js/x-modules/facets/components/filters/editable-number-range-filter.vue.js.map +1 -1
- package/js/x-modules/facets/components/filters/hierarchical-filter.vue.js +29 -38
- package/js/x-modules/facets/components/filters/hierarchical-filter.vue.js.map +1 -1
- package/js/x-modules/facets/components/filters/hierarchical-filter.vue_rollup-plugin-vue=script.js +16 -12
- package/js/x-modules/facets/components/filters/hierarchical-filter.vue_rollup-plugin-vue=script.js.map +1 -1
- package/js/x-modules/facets/components/filters/number-range-filter.vue.js +5 -6
- package/js/x-modules/facets/components/filters/number-range-filter.vue.js.map +1 -1
- package/js/x-modules/facets/components/filters/number-range-filter.vue_rollup-plugin-vue=script.js +16 -12
- package/js/x-modules/facets/components/filters/number-range-filter.vue_rollup-plugin-vue=script.js.map +1 -1
- package/js/x-modules/facets/components/filters/renderless-filter.vue.js.map +1 -1
- package/js/x-modules/facets/components/filters/renderless-filter.vue_rollup-plugin-vue=script.js +16 -12
- package/js/x-modules/facets/components/filters/renderless-filter.vue_rollup-plugin-vue=script.js.map +1 -1
- package/js/x-modules/facets/components/filters/simple-filter.vue.js +13 -17
- package/js/x-modules/facets/components/filters/simple-filter.vue.js.map +1 -1
- package/js/x-modules/facets/components/filters/simple-filter.vue_rollup-plugin-vue=script.js +16 -12
- package/js/x-modules/facets/components/filters/simple-filter.vue_rollup-plugin-vue=script.js.map +1 -1
- package/js/x-modules/facets/components/lists/exclude-filters-with-no-results.vue.js.map +1 -1
- package/js/x-modules/facets/components/lists/exclude-filters-with-no-results.vue_rollup-plugin-vue=script.js +16 -12
- package/js/x-modules/facets/components/lists/exclude-filters-with-no-results.vue_rollup-plugin-vue=script.js.map +1 -1
- package/js/x-modules/facets/components/lists/filters-list.vue.js +6 -6
- package/js/x-modules/facets/components/lists/filters-list.vue.js.map +1 -1
- package/js/x-modules/facets/components/lists/filters-list.vue_rollup-plugin-vue=script.js +16 -12
- package/js/x-modules/facets/components/lists/filters-list.vue_rollup-plugin-vue=script.js.map +1 -1
- package/js/x-modules/facets/components/lists/filters-search.vue.js +10 -12
- package/js/x-modules/facets/components/lists/filters-search.vue.js.map +1 -1
- package/js/x-modules/facets/components/lists/filters-search.vue_rollup-plugin-vue=script.js +16 -12
- package/js/x-modules/facets/components/lists/filters-search.vue_rollup-plugin-vue=script.js.map +1 -1
- package/js/x-modules/facets/components/lists/selected-filters-list.vue.js +14 -20
- package/js/x-modules/facets/components/lists/selected-filters-list.vue.js.map +1 -1
- package/js/x-modules/facets/components/lists/selected-filters.vue.js +3 -4
- package/js/x-modules/facets/components/lists/selected-filters.vue.js.map +1 -1
- package/js/x-modules/facets/components/lists/selected-filters.vue_rollup-plugin-vue=script.js +16 -12
- package/js/x-modules/facets/components/lists/selected-filters.vue_rollup-plugin-vue=script.js.map +1 -1
- package/js/x-modules/facets/components/lists/sliced-filters.vue.js +12 -18
- package/js/x-modules/facets/components/lists/sliced-filters.vue.js.map +1 -1
- package/js/x-modules/facets/components/lists/sliced-filters.vue_rollup-plugin-vue=script.js +16 -12
- package/js/x-modules/facets/components/lists/sliced-filters.vue_rollup-plugin-vue=script.js.map +1 -1
- package/js/x-modules/facets/components/lists/sorted-filters.vue.js.map +1 -1
- package/js/x-modules/facets/components/lists/sorted-filters.vue_rollup-plugin-vue=script.js +16 -12
- package/js/x-modules/facets/components/lists/sorted-filters.vue_rollup-plugin-vue=script.js.map +1 -1
- package/js/x-modules/history-queries/components/clear-history-queries.vue.js +5 -6
- package/js/x-modules/history-queries/components/clear-history-queries.vue.js.map +1 -1
- package/js/x-modules/history-queries/components/history-queries.vue.js +19 -25
- package/js/x-modules/history-queries/components/history-queries.vue.js.map +1 -1
- package/js/x-modules/history-queries/components/history-queries.vue_rollup-plugin-vue=script.js +1 -1
- package/js/x-modules/history-queries/components/history-query.vue.js +13 -17
- package/js/x-modules/history-queries/components/history-query.vue.js.map +1 -1
- package/js/x-modules/history-queries/components/history-query.vue_rollup-plugin-vue=script.js +1 -1
- package/js/x-modules/history-queries/components/remove-history-query.vue.js +2 -2
- package/js/x-modules/history-queries/components/remove-history-query.vue.js.map +1 -1
- package/js/x-modules/history-queries/wiring.js +1 -1
- package/js/x-modules/history-queries/wiring.js.map +1 -1
- package/js/x-modules/identifier-results/components/identifier-result.vue.js +2 -2
- package/js/x-modules/identifier-results/components/identifier-result.vue.js.map +1 -1
- package/js/x-modules/identifier-results/components/identifier-results.vue.js +4 -4
- package/js/x-modules/identifier-results/components/identifier-results.vue.js.map +1 -1
- package/js/x-modules/identifier-results/store/actions/fetch-and-save-identifier-results.action.js +4 -2
- package/js/x-modules/identifier-results/store/actions/fetch-and-save-identifier-results.action.js.map +1 -1
- package/js/x-modules/identifier-results/store/getters/identifier-results-request.getter.js +2 -3
- package/js/x-modules/identifier-results/store/getters/identifier-results-request.getter.js.map +1 -1
- package/js/x-modules/identifier-results/wiring.js +3 -2
- package/js/x-modules/identifier-results/wiring.js.map +1 -1
- package/js/x-modules/next-queries/components/next-queries-list.vue.js +9 -12
- package/js/x-modules/next-queries/components/next-queries-list.vue.js.map +1 -1
- package/js/x-modules/next-queries/components/next-queries-list.vue_rollup-plugin-vue=script.js +1 -1
- package/js/x-modules/next-queries/components/next-queries.vue.js +15 -20
- package/js/x-modules/next-queries/components/next-queries.vue.js.map +1 -1
- package/js/x-modules/next-queries/components/next-queries.vue_rollup-plugin-vue=script.js +1 -1
- package/js/x-modules/next-queries/components/next-query.vue.js +8 -10
- package/js/x-modules/next-queries/components/next-query.vue.js.map +1 -1
- package/js/x-modules/next-queries/components/next-query.vue_rollup-plugin-vue=script.js +1 -1
- package/js/x-modules/popular-searches/components/popular-search.vue.js +8 -10
- package/js/x-modules/popular-searches/components/popular-search.vue.js.map +1 -1
- package/js/x-modules/popular-searches/components/popular-search.vue_rollup-plugin-vue=script.js +1 -1
- package/js/x-modules/popular-searches/components/popular-searches.vue.js +15 -20
- package/js/x-modules/popular-searches/components/popular-searches.vue.js.map +1 -1
- package/js/x-modules/popular-searches/components/popular-searches.vue_rollup-plugin-vue=script.js +1 -1
- package/js/x-modules/query-suggestions/components/query-suggestion.vue.js +9 -11
- package/js/x-modules/query-suggestions/components/query-suggestion.vue.js.map +1 -1
- package/js/x-modules/query-suggestions/components/query-suggestion.vue_rollup-plugin-vue=script.js +1 -1
- package/js/x-modules/query-suggestions/components/query-suggestions.vue.js +15 -20
- package/js/x-modules/query-suggestions/components/query-suggestions.vue.js.map +1 -1
- package/js/x-modules/query-suggestions/components/query-suggestions.vue_rollup-plugin-vue=script.js +1 -1
- package/js/x-modules/query-suggestions/wiring.js +1 -1
- package/js/x-modules/query-suggestions/wiring.js.map +1 -1
- package/js/x-modules/recommendations/components/recommendations.vue.js +11 -14
- package/js/x-modules/recommendations/components/recommendations.vue.js.map +1 -1
- package/js/x-modules/related-tags/components/related-tag.vue.js +11 -8
- package/js/x-modules/related-tags/components/related-tag.vue.js.map +1 -1
- package/js/x-modules/related-tags/components/related-tag.vue_rollup-plugin-vue=script.js +20 -0
- package/js/x-modules/related-tags/components/related-tag.vue_rollup-plugin-vue=script.js.map +1 -1
- package/js/x-modules/related-tags/components/related-tags.vue.js +28 -21
- package/js/x-modules/related-tags/components/related-tags.vue.js.map +1 -1
- package/js/x-modules/related-tags/components/related-tags.vue_rollup-plugin-vue=script.js +3 -0
- package/js/x-modules/related-tags/components/related-tags.vue_rollup-plugin-vue=script.js.map +1 -1
- package/js/x-modules/scroll/components/main-scroll-item.vue.js +1 -1
- package/js/x-modules/scroll/components/main-scroll-item.vue_rollup-plugin-vue=script.js +18 -14
- package/js/x-modules/scroll/components/main-scroll-item.vue_rollup-plugin-vue=script.js.map +1 -1
- package/js/x-modules/scroll/components/scroll-to-top.vue.js +3 -4
- package/js/x-modules/scroll/components/scroll-to-top.vue.js.map +1 -1
- package/js/x-modules/scroll/components/scroll-to-top.vue_rollup-plugin-vue=script.js +18 -14
- package/js/x-modules/scroll/components/scroll-to-top.vue_rollup-plugin-vue=script.js.map +1 -1
- package/js/x-modules/scroll/components/scroll.vue.js +4 -4
- package/js/x-modules/scroll/components/scroll.vue.js.map +1 -1
- package/js/x-modules/scroll/components/scroll.vue_rollup-plugin-vue=script.js +1 -1
- package/js/x-modules/scroll/components/window-scroll.vue.js.map +1 -1
- package/js/x-modules/scroll/components/window-scroll.vue_rollup-plugin-vue=script.js +18 -14
- package/js/x-modules/scroll/components/window-scroll.vue_rollup-plugin-vue=script.js.map +1 -1
- package/js/x-modules/search/components/banner.vue.js +6 -7
- package/js/x-modules/search/components/banner.vue.js.map +1 -1
- package/js/x-modules/search/components/banner.vue_rollup-plugin-vue=script.js +8 -0
- package/js/x-modules/search/components/banner.vue_rollup-plugin-vue=script.js.map +1 -1
- package/js/x-modules/search/components/banners-list.vue.js +9 -12
- package/js/x-modules/search/components/banners-list.vue.js.map +1 -1
- package/js/x-modules/search/components/banners-list.vue_rollup-plugin-vue=script.js +1 -1
- package/js/x-modules/search/components/partial-query-button.vue.js +4 -5
- package/js/x-modules/search/components/partial-query-button.vue.js.map +1 -1
- package/js/x-modules/search/components/partial-results-list.vue.js +6 -6
- package/js/x-modules/search/components/partial-results-list.vue.js.map +1 -1
- package/js/x-modules/search/components/promoted.vue.js +6 -7
- package/js/x-modules/search/components/promoted.vue.js.map +1 -1
- package/js/x-modules/search/components/promoted.vue_rollup-plugin-vue=script.js +8 -0
- package/js/x-modules/search/components/promoted.vue_rollup-plugin-vue=script.js.map +1 -1
- package/js/x-modules/search/components/promoteds-list.vue.js +9 -12
- package/js/x-modules/search/components/promoteds-list.vue.js.map +1 -1
- package/js/x-modules/search/components/promoteds-list.vue_rollup-plugin-vue=script.js +1 -1
- package/js/x-modules/search/components/redirection.vue.js +4 -5
- package/js/x-modules/search/components/redirection.vue.js.map +1 -1
- package/js/x-modules/search/components/redirection.vue_rollup-plugin-vue=script.js.map +1 -1
- package/js/x-modules/search/components/results-list.vue.js +9 -12
- package/js/x-modules/search/components/results-list.vue.js.map +1 -1
- package/js/x-modules/search/components/results-list.vue_rollup-plugin-vue=script.js +2 -2
- package/js/x-modules/search/components/sort-dropdown.vue.js +13 -16
- package/js/x-modules/search/components/sort-dropdown.vue.js.map +1 -1
- package/js/x-modules/search/components/sort-list.vue.js +10 -12
- package/js/x-modules/search/components/sort-list.vue.js.map +1 -1
- package/js/x-modules/search/components/sort-list.vue_rollup-plugin-vue=script.js +16 -12
- package/js/x-modules/search/components/sort-list.vue_rollup-plugin-vue=script.js.map +1 -1
- package/js/x-modules/search/components/sort.mixin.js +16 -12
- package/js/x-modules/search/components/sort.mixin.js.map +1 -1
- package/js/x-modules/search/components/spellcheck-button.vue.js +4 -5
- package/js/x-modules/search/components/spellcheck-button.vue.js.map +1 -1
- package/js/x-modules/search/components/spellcheck.vue.js +4 -6
- package/js/x-modules/search/components/spellcheck.vue.js.map +1 -1
- package/js/x-modules/search/components/spellcheck.vue_rollup-plugin-vue=script.js +16 -12
- package/js/x-modules/search/components/spellcheck.vue_rollup-plugin-vue=script.js.map +1 -1
- package/js/x-modules/search/store/actions/fetch-and-save-search-response.action.js +7 -2
- package/js/x-modules/search/store/actions/fetch-and-save-search-response.action.js.map +1 -1
- package/js/x-modules/search/store/getters/request.getter.js +2 -3
- package/js/x-modules/search/store/getters/request.getter.js.map +1 -1
- package/js/x-modules/search/wiring.js +4 -3
- package/js/x-modules/search/wiring.js.map +1 -1
- package/js/x-modules/search-box/components/clear-search-input.vue.js +5 -6
- package/js/x-modules/search-box/components/clear-search-input.vue.js.map +1 -1
- package/js/x-modules/search-box/components/search-button.vue.js +4 -5
- package/js/x-modules/search-box/components/search-button.vue.js.map +1 -1
- package/js/x-modules/search-box/components/search-input.vue.js +9 -11
- package/js/x-modules/search-box/components/search-input.vue.js.map +1 -1
- package/js/x-modules/search-box/components/search-input.vue_rollup-plugin-vue=script.js +7 -5
- package/js/x-modules/search-box/components/search-input.vue_rollup-plugin-vue=script.js.map +1 -1
- package/js/x-modules/tagging/components/tagging.vue.js +39 -0
- package/js/x-modules/tagging/components/tagging.vue.js.map +1 -0
- package/js/x-modules/tagging/components/tagging.vue_rollup-plugin-vue=script.js +65 -0
- package/js/x-modules/tagging/components/tagging.vue_rollup-plugin-vue=script.js.map +1 -0
- package/js/x-modules/tagging/service/session.service.js +23 -6
- package/js/x-modules/tagging/service/session.service.js.map +1 -1
- package/js/x-modules/tagging/store/actions/track.action.js +2 -2
- package/js/x-modules/tagging/store/actions/track.action.js.map +1 -1
- package/js/x-modules/tagging/wiring.js +52 -5
- package/js/x-modules/tagging/wiring.js.map +1 -1
- package/js/x-modules/url/components/url-handler.vue.js +2 -2
- package/js/x-modules/url/components/url-handler.vue.js.map +1 -1
- package/js/x-modules/url/components/url-handler.vue_rollup-plugin-vue=script.js +101 -5
- package/js/x-modules/url/components/url-handler.vue_rollup-plugin-vue=script.js.map +1 -1
- package/package.json +18 -16
- package/report/tsdoc-metadata.json +1 -1
- package/report/x-adapter.api.json +29 -3
- package/report/x-components.api.json +999 -231
- package/report/x-components.api.md +132 -45
- package/report/x-types.api.json +27 -1
- package/tagging/index.js +3 -2
- package/types/adapter/mocked-adapter.d.ts.map +1 -1
- package/types/components/animations/index.d.ts +1 -0
- package/types/components/animations/index.d.ts.map +1 -1
- package/types/components/{staggering-transition-group.vue.d.ts → animations/staggering-transition-group.vue.d.ts} +0 -0
- package/types/components/animations/staggering-transition-group.vue.d.ts.map +1 -0
- package/types/components/global-x-bus.vue.d.ts +25 -0
- package/types/components/global-x-bus.vue.d.ts.map +1 -0
- package/types/components/icons/index.d.ts +1 -0
- package/types/components/icons/index.d.ts.map +1 -1
- package/types/components/icons/tag.vue.d.ts +3 -0
- package/types/components/icons/tag.vue.d.ts.map +1 -0
- package/types/components/index.d.ts +3 -4
- package/types/components/index.d.ts.map +1 -1
- package/types/components/layouts/fixed-header-and-asides-layout.vue.d.ts +17 -0
- package/types/components/layouts/fixed-header-and-asides-layout.vue.d.ts.map +1 -0
- package/types/components/layouts/index.d.ts +4 -0
- package/types/components/layouts/index.d.ts.map +1 -0
- package/types/components/panels/base-id-toggle-panel.vue.d.ts +0 -5
- package/types/components/panels/base-id-toggle-panel.vue.d.ts.map +1 -1
- package/types/components/result/base-result-link.vue.d.ts +3 -10
- package/types/components/result/base-result-link.vue.d.ts.map +1 -1
- package/types/components/snippet-callbacks.vue.d.ts +27 -0
- package/types/components/snippet-callbacks.vue.d.ts.map +1 -0
- package/types/components/x-component.mixin.d.ts.map +1 -1
- package/types/components/x-component.utils.d.ts +1 -16
- package/types/components/x-component.utils.d.ts.map +1 -1
- package/types/plugins/x-plugin.alias.d.ts +4 -6
- package/types/plugins/x-plugin.alias.d.ts.map +1 -1
- package/types/plugins/x-plugin.mixin.d.ts +13 -3
- package/types/plugins/x-plugin.mixin.d.ts.map +1 -1
- package/types/types/origin.d.ts +1 -1
- package/types/types/origin.d.ts.map +1 -1
- package/types/utils/origin.d.ts +3 -1
- package/types/utils/origin.d.ts.map +1 -1
- package/types/utils/storage.d.ts +1 -7
- package/types/utils/storage.d.ts.map +1 -1
- package/types/utils/types.d.ts +6 -0
- package/types/utils/types.d.ts.map +1 -1
- package/types/wiring/events.types.d.ts +8 -5
- package/types/wiring/events.types.d.ts.map +1 -1
- package/types/wiring/namespaced-wires.operators.d.ts +2 -3
- package/types/wiring/namespaced-wires.operators.d.ts.map +1 -1
- package/types/wiring/namespaced-wiring.types.d.ts +9 -10
- package/types/wiring/namespaced-wiring.types.d.ts.map +1 -1
- package/types/wiring/wires-operators.utils.d.ts +36 -0
- package/types/wiring/wires-operators.utils.d.ts.map +1 -0
- package/types/wiring/wires.operators.d.ts +5 -8
- package/types/wiring/wires.operators.d.ts.map +1 -1
- package/types/wiring/wiring.types.d.ts +17 -4
- package/types/wiring/wiring.types.d.ts.map +1 -1
- package/types/x-installer/api/api.types.d.ts +14 -0
- package/types/x-installer/api/api.types.d.ts.map +1 -1
- package/types/x-installer/x-installer/x-installer.d.ts +1 -1
- package/types/x-modules/extra-params/components/snippet-config-extra-params.vue.d.ts +6 -0
- package/types/x-modules/extra-params/components/snippet-config-extra-params.vue.d.ts.map +1 -1
- package/types/x-modules/facets/components/facets/facets-provider.vue.d.ts +0 -8
- package/types/x-modules/facets/components/facets/facets-provider.vue.d.ts.map +1 -1
- package/types/x-modules/history-queries/wiring.d.ts +1 -1
- package/types/x-modules/identifier-results/store/actions/fetch-and-save-identifier-results.action.d.ts.map +1 -1
- package/types/x-modules/identifier-results/store/getters/identifier-results-request.getter.d.ts.map +1 -1
- package/types/x-modules/identifier-results/wiring.d.ts +2 -1
- package/types/x-modules/identifier-results/wiring.d.ts.map +1 -1
- package/types/x-modules/query-suggestions/wiring.d.ts +1 -1
- package/types/x-modules/related-tags/components/related-tag.vue.d.ts +14 -0
- package/types/x-modules/related-tags/components/related-tag.vue.d.ts.map +1 -1
- package/types/x-modules/related-tags/components/related-tags.vue.d.ts +6 -0
- package/types/x-modules/related-tags/components/related-tags.vue.d.ts.map +1 -1
- package/types/x-modules/search/components/banner.vue.d.ts +6 -0
- package/types/x-modules/search/components/banner.vue.d.ts.map +1 -1
- package/types/x-modules/search/components/promoted.vue.d.ts +6 -0
- package/types/x-modules/search/components/promoted.vue.d.ts.map +1 -1
- package/types/x-modules/search/components/redirection.vue.d.ts +1 -1
- package/types/x-modules/search/components/redirection.vue.d.ts.map +1 -1
- package/types/x-modules/search/events.types.d.ts +11 -1
- package/types/x-modules/search/events.types.d.ts.map +1 -1
- package/types/x-modules/search/store/actions/fetch-and-save-search-response.action.d.ts.map +1 -1
- package/types/x-modules/search/store/getters/request.getter.d.ts.map +1 -1
- package/types/x-modules/search/wiring.d.ts +2 -1
- package/types/x-modules/search/wiring.d.ts.map +1 -1
- package/types/x-modules/search-box/components/search-input.vue.d.ts +5 -2
- package/types/x-modules/search-box/components/search-input.vue.d.ts.map +1 -1
- package/types/x-modules/tagging/components/tagging.vue.d.ts +47 -0
- package/types/x-modules/tagging/components/tagging.vue.d.ts.map +1 -0
- package/types/x-modules/tagging/index.d.ts +1 -0
- package/types/x-modules/tagging/index.d.ts.map +1 -1
- package/types/x-modules/tagging/service/session.service.d.ts +18 -1
- package/types/x-modules/tagging/service/session.service.d.ts.map +1 -1
- package/types/x-modules/tagging/wiring.d.ts +29 -9
- package/types/x-modules/tagging/wiring.d.ts.map +1 -1
- package/types/x-modules/url/components/url-handler.vue.d.ts +70 -7
- package/types/x-modules/url/components/url-handler.vue.d.ts.map +1 -1
- package/docs/API-reference/api/x-components.baseidtogglepanel.created.md +0 -17
- package/docs/API-reference/api/x-components.xcomponent.md +0 -15
- package/docs/API-reference/api/x-components.xeventstypes.userrightclickedaresult.md +0 -13
- package/docs/sidebar.json +0 -1
- package/js/components/staggering-transition-group.vue.js.map +0 -1
- package/js/components/staggering-transition-group.vue_rollup-plugin-vue=script.js.map +0 -1
- package/js/wiring/utils/wire-racing-handling.js +0 -108
- package/js/wiring/utils/wire-racing-handling.js.map +0 -1
- package/types/components/staggering-transition-group.vue.d.ts.map +0 -1
- package/types/components/x-component.types.d.ts +0 -19
- package/types/components/x-component.types.d.ts.map +0 -1
- package/types/wiring/utils/wire-racing-handling.d.ts +0 -27
- package/types/wiring/utils/wire-racing-handling.d.ts.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"base-result-link.vue_rollup-plugin-vue=script.js","sources":["../../../../src/components/result/base-result-link.vue?rollup-plugin-vue=script.ts"],"sourcesContent":["\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nimport { Result } from '@empathyco/x-types';\nimport Vue from 'vue';\nimport { Component, Inject, Prop } from 'vue-property-decorator';\nimport { PropsWithType } from '../../utils/types';\nimport { XEventsTypes } from '../../wiring/events.types';\n\n/**\n * Component to be reused that renders an `<a>` wrapping the result contents.\n *\n * @remarks\n * It has the logic to emit {@link XEventsTypes.UserClickedAResult}
|
|
1
|
+
{"version":3,"file":"base-result-link.vue_rollup-plugin-vue=script.js","sources":["../../../../src/components/result/base-result-link.vue?rollup-plugin-vue=script.ts"],"sourcesContent":["\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nimport { Result } from '@empathyco/x-types';\nimport Vue from 'vue';\nimport { Component, Inject, Prop } from 'vue-property-decorator';\nimport { PropsWithType } from '../../utils/types';\nimport { XEventsTypes } from '../../wiring/events.types';\n\n/**\n * Component to be reused that renders an `<a>` wrapping the result contents.\n *\n * @remarks\n * It has the logic to emit {@link XEventsTypes.UserClickedAResult} to the bus on click mouse\n * events. Additionally, this component may be injected other events to be emitted on click\n * event, so, depending where it's used its father component may provide this events.\n *\n * @public\n */\n@Component\nexport default class BaseResultLink extends Vue {\n /**\n * The rendered DOM element.\n *\n * @internal\n */\n public $el!: HTMLElement;\n /**\n * The list of additional events to be emitted by the component when user clicks the link.\n *\n * @internal\n */\n @Inject({ from: 'resultClickExtraEvents', default: [] })\n protected resultClickExtraEvents!: PropsWithType<XEventsTypes, Result>[];\n\n /**\n * (Required) The {@link @empathyco/x-types#Result | result} information.\n *\n * @public\n */\n @Prop({ required: true })\n protected result!: Result;\n\n /**\n * Emits the {@link XEventsTypes.UserClickedAResult} when user clicks on the result, and also\n * additional events if have been injected in the component.\n *\n * @internal\n */\n protected emitUserClickedAResult(): void {\n this.$x.emit('UserClickedAResult', this.result, { target: this.$el });\n this.resultClickExtraEvents.forEach(event => {\n this.$x.emit(event, this.result, { target: this.$el });\n });\n }\n}\n"],"names":[],"mappings":";;;;AAwBA;;;;;;;;;;AAWA;IAA4C,kCAAG;IAA/C;;KAmCC;;;;;;;IANW,+CAAsB,GAAhC;QAAA,iBAKC;QAJC,IAAI,CAAC,EAAE,CAAC,IAAI,CAAC,oBAAoB,EAAE,IAAI,CAAC,MAAM,EAAE,EAAE,MAAM,EAAE,IAAI,CAAC,GAAG,EAAE,CAAC,CAAC;QACtE,IAAI,CAAC,sBAAsB,CAAC,OAAO,CAAC,UAAA,KAAK;YACvC,KAAI,CAAC,EAAE,CAAC,IAAI,CAAC,KAAK,EAAE,KAAI,CAAC,MAAM,EAAE,EAAE,MAAM,EAAE,KAAI,CAAC,GAAG,EAAE,CAAC,CAAC;SACxD,CAAC,CAAC;KACJ;IArBD;QADC,MAAM,CAAC,EAAE,IAAI,EAAE,wBAAwB,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC;kEACiB;IAQzE;QADC,IAAI,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;kDACC;IArBP,cAAc;QADlC,SAAS;OACW,cAAc,CAmClC;IAAD,qBAAC;CAAA,CAnC2C,GAAG;;;;"}
|
|
@@ -5,7 +5,7 @@ import script from './base-result-placeholder-image.vue_rollup-plugin-vue=script
|
|
|
5
5
|
var __vue_script__ = script;
|
|
6
6
|
|
|
7
7
|
/* template */
|
|
8
|
-
var __vue_render__ = function(_h, _vm) {
|
|
8
|
+
var __vue_render__ = function (_h, _vm) {
|
|
9
9
|
var _c = _vm._c;
|
|
10
10
|
return _c(
|
|
11
11
|
"svg",
|
|
@@ -18,20 +18,18 @@ var __vue_render__ = function(_h, _vm) {
|
|
|
18
18
|
version: "1.1",
|
|
19
19
|
viewBox: "0 0 256 371",
|
|
20
20
|
xmlns: "http://www.w3.org/2000/svg",
|
|
21
|
-
"xmlns:xlink": "http://www.w3.org/1999/xlink"
|
|
22
|
-
}
|
|
21
|
+
"xmlns:xlink": "http://www.w3.org/1999/xlink",
|
|
22
|
+
},
|
|
23
23
|
},
|
|
24
24
|
[
|
|
25
25
|
_c("rect", { attrs: { height: "371", width: "256", x: "0", y: "0" } }),
|
|
26
26
|
_vm._v(" "),
|
|
27
27
|
_c("path", {
|
|
28
28
|
attrs: {
|
|
29
|
-
d:
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
})
|
|
34
|
-
]
|
|
29
|
+
d: "M162.40625,77 L162.40625,90.5625 L40.34375,90.5625 C36.5983809,90.5625 33.5625,93.5983809\n 33.5625,97.34375 L33.5625,97.34375 L33.5625,236.969687 L96.628125,173.971875\n C99.2732363,171.342445 103.544576,171.342445 106.189687,173.971875 L106.189687,173.971875\n L148.84375,216.625937 L184.784375,180.753125 C187.429486,178.123695 191.700826,178.123695\n 194.345938,180.753125 L194.345938,180.753125 L223.4375,209.844687 L223.4375,158.375\n L237,158.375 L237,273.65625 C237,284.891934 227.891934,294 216.65625,294 L216.65625,294\n L40.34375,294 C29.1080664,294 20,284.891934 20,273.65625 L20,273.65625 L20,97.34375\n C20,86.1080664 29.1080664,77 40.34375,77 L40.34375,77 L162.40625,77 Z M82,114\n C93.045625,114 102,122.954375 102,134 C102,145.045625 93.045625,154 82,154 C70.954375,154\n 62,145.045625 62,134 C62,122.954375 70.954375,114 82,114 Z M175.444623,100.396089\n L183.687219,108.661381 C184.620423,109.602859 184.620423,111.123422 183.680918,112.077314\n C182.737148,113.018189 181.212972,113.018189 180.26465,112.073775 L180.26465,112.073775\n L177.727,109.527 L177.745354,109.644062 C179.677469,121.418749 189.812727,130.462066\n 202.047328,130.661575 L202.047328,130.661575 L202.460517,130.664942 C209.153157,130.664942\n 215.436777,128.056193 220.174617,123.31173 C221.12269,122.361456 222.670209,122.361776\n 223.58594,123.311542 C224.527282,124.25405 224.527282,125.78338 223.586285,126.726562\n C217.94114,132.382374 210.431948,135.5 202.451652,135.5 C187.460762,135.5 174.984785,124.35392\n 172.907406,109.825508 L172.907406,109.825508 L172.902,109.787 L170.627234,112.068625\n C170.216136,112.485215 169.674234,112.730073 169.104127,112.774878 L169.104127,112.774878\n L168.913187,112.782365 C168.276718,112.782365 167.658303,112.532522 167.207809,112.075026\n C166.263587,111.129629 166.263587,109.597657 167.206898,108.658263 L167.206898,108.658263\n L175.444623,100.396089 Z M202.54801,75.5 C217.536718,75.5 230.012345,86.6439604\n 232.093604,101.171817 L232.093604,101.171817 L232.098,101.21 L234.379146,98.9226859\n C235.281116,98.0234824 236.717815,97.9826095 237.660635,98.8020572 L237.660635,98.8020572\n L237.791853,98.9249739 C238.734405,99.8686992 238.736601,101.398026 237.795291,102.341522\n L237.795291,102.341522 L229.557794,110.600807 L221.31437,102.338232 C220.381166,101.396755\n 220.381166,99.876192 221.320671,98.9222996 C222.265013,97.9808537 223.794144,97.9808537\n 224.736486,98.9253846 L224.736486,98.9253846 L227.277,101.473 L227.259636,101.355612\n C225.324141,89.5799272 215.187742,80.5375269 202.954224,80.3380384 L202.954224,80.3380384\n L202.541072,80.3346719 C195.847619,80.3346719 189.562063,82.9439869 184.830962,87.683869\n C183.887384,88.6368031 182.34531,88.6368031 181.414841,87.6918832 C180.466611,86.7485972\n 180.466611,85.2139736 181.411064,84.2734376 C187.057027,78.6168059 194.564245,75.5\n 202.54801,75.5 Z",
|
|
30
|
+
"fill-rule": "nonzero",
|
|
31
|
+
},
|
|
32
|
+
}) ]
|
|
35
33
|
)
|
|
36
34
|
};
|
|
37
35
|
var __vue_staticRenderFns__ = [];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"base-result-placeholder-image.vue.js","sources":["../../../../src/components/result/base-result-placeholder-image.vue"],"sourcesContent":["<template functional>\n <svg\n :class=\"['x-picture__image x-picture__image--placeholder'].concat(data.staticClass, data.class)\"\n version=\"1.1\"\n viewBox=\"0 0 256 371\"\n xmlns=\"http://www.w3.org/2000/svg\"\n xmlns:xlink=\"http://www.w3.org/1999/xlink\"\n >\n <rect height=\"371\" width=\"256\" x=\"0\" y=\"0\"></rect>\n <path\n d=\"M162.40625,77 L162.40625,90.5625 L40.34375,90.5625 C36.5983809,90.5625 33.5625,93.5983809\n 33.5625,97.34375 L33.5625,97.34375 L33.5625,236.969687 L96.628125,173.971875\n C99.2732363,171.342445 103.544576,171.342445 106.189687,173.971875 L106.189687,173.971875\n L148.84375,216.625937 L184.784375,180.753125 C187.429486,178.123695 191.700826,178.123695\n 194.345938,180.753125 L194.345938,180.753125 L223.4375,209.844687 L223.4375,158.375\n L237,158.375 L237,273.65625 C237,284.891934 227.891934,294 216.65625,294 L216.65625,294\n L40.34375,294 C29.1080664,294 20,284.891934 20,273.65625 L20,273.65625 L20,97.34375\n C20,86.1080664 29.1080664,77 40.34375,77 L40.34375,77 L162.40625,77 Z M82,114\n C93.045625,114 102,122.954375 102,134 C102,145.045625 93.045625,154 82,154 C70.954375,154\n 62,145.045625 62,134 C62,122.954375 70.954375,114 82,114 Z M175.444623,100.396089\n L183.687219,108.661381 C184.620423,109.602859 184.620423,111.123422 183.680918,112.077314\n C182.737148,113.018189 181.212972,113.018189 180.26465,112.073775 L180.26465,112.073775\n L177.727,109.527 L177.745354,109.644062 C179.677469,121.418749 189.812727,130.462066\n 202.047328,130.661575 L202.047328,130.661575 L202.460517,130.664942 C209.153157,130.664942\n 215.436777,128.056193 220.174617,123.31173 C221.12269,122.361456 222.670209,122.361776\n 223.58594,123.311542 C224.527282,124.25405 224.527282,125.78338 223.586285,126.726562\n C217.94114,132.382374 210.431948,135.5 202.451652,135.5 C187.460762,135.5 174.984785,124.35392\n 172.907406,109.825508 L172.907406,109.825508 L172.902,109.787 L170.627234,112.068625\n C170.216136,112.485215 169.674234,112.730073 169.104127,112.774878 L169.104127,112.774878\n L168.913187,112.782365 C168.276718,112.782365 167.658303,112.532522 167.207809,112.075026\n C166.263587,111.129629 166.263587,109.597657 167.206898,108.658263 L167.206898,108.658263\n L175.444623,100.396089 Z M202.54801,75.5 C217.536718,75.5 230.012345,86.6439604\n 232.093604,101.171817 L232.093604,101.171817 L232.098,101.21 L234.379146,98.9226859\n C235.281116,98.0234824 236.717815,97.9826095 237.660635,98.8020572 L237.660635,98.8020572\n L237.791853,98.9249739 C238.734405,99.8686992 238.736601,101.398026 237.795291,102.341522\n L237.795291,102.341522 L229.557794,110.600807 L221.31437,102.338232 C220.381166,101.396755\n 220.381166,99.876192 221.320671,98.9222996 C222.265013,97.9808537 223.794144,97.9808537\n 224.736486,98.9253846 L224.736486,98.9253846 L227.277,101.473 L227.259636,101.355612\n C225.324141,89.5799272 215.187742,80.5375269 202.954224,80.3380384 L202.954224,80.3380384\n L202.541072,80.3346719 C195.847619,80.3346719 189.562063,82.9439869 184.830962,87.683869\n C183.887384,88.6368031 182.34531,88.6368031 181.414841,87.6918832 C180.466611,86.7485972\n 180.466611,85.2139736 181.411064,84.2734376 C187.057027,78.6168059 194.564245,75.5\n 202.54801,75.5 Z\"\n fill-rule=\"nonzero\"\n ></path>\n </svg>\n</template>\n\n<script lang=\"ts\">\n export default {};\n</script>\n"],"names":["const"],"mappings":";;;;AAEAA
|
|
1
|
+
{"version":3,"file":"base-result-placeholder-image.vue.js","sources":["../../../../src/components/result/base-result-placeholder-image.vue"],"sourcesContent":["<template functional>\n <svg\n :class=\"['x-picture__image x-picture__image--placeholder'].concat(data.staticClass, data.class)\"\n version=\"1.1\"\n viewBox=\"0 0 256 371\"\n xmlns=\"http://www.w3.org/2000/svg\"\n xmlns:xlink=\"http://www.w3.org/1999/xlink\"\n >\n <rect height=\"371\" width=\"256\" x=\"0\" y=\"0\"></rect>\n <path\n d=\"M162.40625,77 L162.40625,90.5625 L40.34375,90.5625 C36.5983809,90.5625 33.5625,93.5983809\n 33.5625,97.34375 L33.5625,97.34375 L33.5625,236.969687 L96.628125,173.971875\n C99.2732363,171.342445 103.544576,171.342445 106.189687,173.971875 L106.189687,173.971875\n L148.84375,216.625937 L184.784375,180.753125 C187.429486,178.123695 191.700826,178.123695\n 194.345938,180.753125 L194.345938,180.753125 L223.4375,209.844687 L223.4375,158.375\n L237,158.375 L237,273.65625 C237,284.891934 227.891934,294 216.65625,294 L216.65625,294\n L40.34375,294 C29.1080664,294 20,284.891934 20,273.65625 L20,273.65625 L20,97.34375\n C20,86.1080664 29.1080664,77 40.34375,77 L40.34375,77 L162.40625,77 Z M82,114\n C93.045625,114 102,122.954375 102,134 C102,145.045625 93.045625,154 82,154 C70.954375,154\n 62,145.045625 62,134 C62,122.954375 70.954375,114 82,114 Z M175.444623,100.396089\n L183.687219,108.661381 C184.620423,109.602859 184.620423,111.123422 183.680918,112.077314\n C182.737148,113.018189 181.212972,113.018189 180.26465,112.073775 L180.26465,112.073775\n L177.727,109.527 L177.745354,109.644062 C179.677469,121.418749 189.812727,130.462066\n 202.047328,130.661575 L202.047328,130.661575 L202.460517,130.664942 C209.153157,130.664942\n 215.436777,128.056193 220.174617,123.31173 C221.12269,122.361456 222.670209,122.361776\n 223.58594,123.311542 C224.527282,124.25405 224.527282,125.78338 223.586285,126.726562\n C217.94114,132.382374 210.431948,135.5 202.451652,135.5 C187.460762,135.5 174.984785,124.35392\n 172.907406,109.825508 L172.907406,109.825508 L172.902,109.787 L170.627234,112.068625\n C170.216136,112.485215 169.674234,112.730073 169.104127,112.774878 L169.104127,112.774878\n L168.913187,112.782365 C168.276718,112.782365 167.658303,112.532522 167.207809,112.075026\n C166.263587,111.129629 166.263587,109.597657 167.206898,108.658263 L167.206898,108.658263\n L175.444623,100.396089 Z M202.54801,75.5 C217.536718,75.5 230.012345,86.6439604\n 232.093604,101.171817 L232.093604,101.171817 L232.098,101.21 L234.379146,98.9226859\n C235.281116,98.0234824 236.717815,97.9826095 237.660635,98.8020572 L237.660635,98.8020572\n L237.791853,98.9249739 C238.734405,99.8686992 238.736601,101.398026 237.795291,102.341522\n L237.795291,102.341522 L229.557794,110.600807 L221.31437,102.338232 C220.381166,101.396755\n 220.381166,99.876192 221.320671,98.9222996 C222.265013,97.9808537 223.794144,97.9808537\n 224.736486,98.9253846 L224.736486,98.9253846 L227.277,101.473 L227.259636,101.355612\n C225.324141,89.5799272 215.187742,80.5375269 202.954224,80.3380384 L202.954224,80.3380384\n L202.541072,80.3346719 C195.847619,80.3346719 189.562063,82.9439869 184.830962,87.683869\n C183.887384,88.6368031 182.34531,88.6368031 181.414841,87.6918832 C180.466611,86.7485972\n 180.466611,85.2139736 181.411064,84.2734376 C187.057027,78.6168059 194.564245,75.5\n 202.54801,75.5 Z\"\n fill-rule=\"nonzero\"\n ></path>\n </svg>\n</template>\n\n<script lang=\"ts\">\n export default {};\n</script>\n"],"names":["const"],"mappings":";;;;AAEAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -5,7 +5,7 @@ import script from './base-result-previous-price.vue_rollup-plugin-vue=script.js
|
|
|
5
5
|
var __vue_script__ = script;
|
|
6
6
|
|
|
7
7
|
/* template */
|
|
8
|
-
var __vue_render__ = function() {
|
|
8
|
+
var __vue_render__ = function () {
|
|
9
9
|
var _vm = this;
|
|
10
10
|
var _h = _vm.$createElement;
|
|
11
11
|
var _c = _vm._self._c || _h;
|
|
@@ -14,24 +14,22 @@ var __vue_render__ = function() {
|
|
|
14
14
|
"div",
|
|
15
15
|
{
|
|
16
16
|
staticClass: "x-result-previous-price",
|
|
17
|
-
attrs: { "data-test": "result-previous-price" }
|
|
17
|
+
attrs: { "data-test": "result-previous-price" },
|
|
18
18
|
},
|
|
19
19
|
[
|
|
20
20
|
_vm._t(
|
|
21
21
|
"default",
|
|
22
|
-
function() {
|
|
22
|
+
function () {
|
|
23
23
|
return [
|
|
24
24
|
_c("BaseCurrency", {
|
|
25
25
|
attrs: {
|
|
26
26
|
value: _vm.result.price.originalValue,
|
|
27
|
-
format: _vm.format
|
|
28
|
-
}
|
|
29
|
-
})
|
|
30
|
-
]
|
|
27
|
+
format: _vm.format,
|
|
28
|
+
},
|
|
29
|
+
}) ]
|
|
31
30
|
},
|
|
32
31
|
{ result: _vm.result }
|
|
33
|
-
)
|
|
34
|
-
],
|
|
32
|
+
) ],
|
|
35
33
|
2
|
|
36
34
|
)
|
|
37
35
|
: _vm._e()
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"base-result-previous-price.vue.js","sources":["../../../../src/components/result/base-result-previous-price.vue"],"sourcesContent":["<template>\n <div\n v-if=\"result.price.hasDiscount\"\n class=\"x-result-previous-price\"\n data-test=\"result-previous-price\"\n >\n <!--\n @slot Base currency item\n @binding {result} result - Result data\n -->\n <slot :result=\"result\">\n <BaseCurrency :value=\"result.price.originalValue\" :format=\"format\" />\n </slot>\n </div>\n</template>\n\n<script lang=\"ts\">\n import { Result } from '@empathyco/x-types';\n import { Component, Prop } from 'vue-property-decorator';\n import Vue from 'vue';\n import BaseCurrency from '../currency/base-currency.vue';\n\n /**\n * Component that renders the {@link @empathyco/x-types#Result | result} previous price.\n *\n * @public\n */\n @Component({\n components: { BaseCurrency }\n })\n export default class BaseResultPreviousPrice extends Vue {\n /**\n * (Required) The {@link @empathyco/x-types#Result | result} information.\n *\n * @public\n */\n @Prop({ required: true })\n protected result!: Result;\n\n /**\n * Format or mask to be defined as string.\n * - Use 'i' to define integer numbers.\n * - Use 'd' to define decimal numbers. You can define the length of the decimal part. If the\n * doesn't include decimals, it is filled with zeros until reach the length defined with 'd's.\n * - Integer separator must be defined between the 3rd and the 4th integer 'i' of a group.\n * - Decimal separator must be defined between the last 'i' and the first 'd'. It can be more\n * than one character.\n * - Set whatever you need around the integers and decimals marks.\n * - Default mask: 'i.iii,dd' which returns '1.345,67'.\n *\n * @remarks The number of 'd', which is the maximum decimal length, MUST match with the length\n * of decimals provided from the adapter. Otherwise, when the component truncate the decimal\n * part, delete significant digits.\n *\n * @public\n */\n @Prop({ default: 'i.iii,dd' })\n protected format!: string;\n }\n</script>\n\n<docs lang=\"mdx\">\n
|
|
1
|
+
{"version":3,"file":"base-result-previous-price.vue.js","sources":["../../../../src/components/result/base-result-previous-price.vue"],"sourcesContent":["<template>\n <div\n v-if=\"result.price.hasDiscount\"\n class=\"x-result-previous-price\"\n data-test=\"result-previous-price\"\n >\n <!--\n @slot Base currency item\n @binding {result} result - Result data\n -->\n <slot :result=\"result\">\n <BaseCurrency :value=\"result.price.originalValue\" :format=\"format\" />\n </slot>\n </div>\n</template>\n\n<script lang=\"ts\">\n import { Result } from '@empathyco/x-types';\n import { Component, Prop } from 'vue-property-decorator';\n import Vue from 'vue';\n import BaseCurrency from '../currency/base-currency.vue';\n\n /**\n * Component that renders the {@link @empathyco/x-types#Result | result} previous price.\n *\n * @public\n */\n @Component({\n components: { BaseCurrency }\n })\n export default class BaseResultPreviousPrice extends Vue {\n /**\n * (Required) The {@link @empathyco/x-types#Result | result} information.\n *\n * @public\n */\n @Prop({ required: true })\n protected result!: Result;\n\n /**\n * Format or mask to be defined as string.\n * - Use 'i' to define integer numbers.\n * - Use 'd' to define decimal numbers. You can define the length of the decimal part. If the\n * doesn't include decimals, it is filled with zeros until reach the length defined with 'd's.\n * - Integer separator must be defined between the 3rd and the 4th integer 'i' of a group.\n * - Decimal separator must be defined between the last 'i' and the first 'd'. It can be more\n * than one character.\n * - Set whatever you need around the integers and decimals marks.\n * - Default mask: 'i.iii,dd' which returns '1.345,67'.\n *\n * @remarks The number of 'd', which is the maximum decimal length, MUST match with the length\n * of decimals provided from the adapter. Otherwise, when the component truncate the decimal\n * part, delete significant digits.\n *\n * @public\n */\n @Prop({ default: 'i.iii,dd' })\n protected format!: string;\n }\n</script>\n\n<docs lang=\"mdx\">\n## Examples\n\n### Basic example\n\nThis component shows the previous price formatted if it has discount. The component has two optional\nprops. `format` to select the currency format to be applied.\n\n```vue\n<BaseResultPreviousPrice :value=\"result\" :format=\"'i.iii,ddd €'\" />\n```\n\n### Overriding default slot\n\n```vue\n<BaseResultPreviousPrice :result=\"result\">\n <span class=\"custom-base-result-previous-price\">{{ result.price.originalValue }}</span>\n</BaseResultPreviousPrice>\n```\n</docs>\n"],"names":["const"],"mappings":";;;;AAEAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -6,7 +6,7 @@ import script from './base-scroll.vue_rollup-plugin-vue=script.js';
|
|
|
6
6
|
var __vue_script__ = script;
|
|
7
7
|
|
|
8
8
|
/* template */
|
|
9
|
-
var __vue_render__ = function() {
|
|
9
|
+
var __vue_render__ = function () {
|
|
10
10
|
var _vm = this;
|
|
11
11
|
var _h = _vm.$createElement;
|
|
12
12
|
var _c = _vm._self._c || _h;
|
|
@@ -15,7 +15,7 @@ var __vue_render__ = function() {
|
|
|
15
15
|
{
|
|
16
16
|
staticClass: "x-scroll x-base-scroll",
|
|
17
17
|
attrs: { "data-test": "base-scroll" },
|
|
18
|
-
on: { scroll: _vm.throttledStoreScrollData }
|
|
18
|
+
on: { scroll: _vm.throttledStoreScrollData },
|
|
19
19
|
},
|
|
20
20
|
[_vm._t("default")],
|
|
21
21
|
2
|
|
@@ -27,11 +27,11 @@ __vue_render__._withStripped = true;
|
|
|
27
27
|
/* style */
|
|
28
28
|
var __vue_inject_styles__ = function (inject) {
|
|
29
29
|
if (!inject) { return }
|
|
30
|
-
inject("data-v-
|
|
30
|
+
inject("data-v-3b6a5d44_0", { source: ".x-base-scroll[data-v-3b6a5d44] {\n overflow-y: var(--x-string-overflow-scroll, auto);\n}", map: undefined, media: undefined });
|
|
31
31
|
|
|
32
32
|
};
|
|
33
33
|
/* scoped */
|
|
34
|
-
var __vue_scope_id__ = "data-v-
|
|
34
|
+
var __vue_scope_id__ = "data-v-3b6a5d44";
|
|
35
35
|
/* module identifier */
|
|
36
36
|
var __vue_module_identifier__ = undefined;
|
|
37
37
|
/* functional template */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"base-scroll.vue.js","sources":["../../../../src/components/scroll/base-scroll.vue"],"sourcesContent":["<template>\n <div @scroll=\"throttledStoreScrollData\" class=\"x-scroll x-base-scroll\" data-test=\"base-scroll\">\n <slot />\n </div>\n</template>\n\n<script lang=\"ts\">\n import { mixins } from 'vue-class-component';\n import { Component } from 'vue-property-decorator';\n import ScrollMixin from './scroll.mixin';\n\n /**\n * Base scroll component that depending on the user interactivity emits different events for\n * knowing when the user scrolls, the direction of scroll and if user reaches the start or end.\n *\n * @public\n */\n @Component\n export default class BaseScroll extends mixins(ScrollMixin) {}\n</script>\n\n<style lang=\"scss\" scoped>\n .x-base-scroll {\n overflow-y: var(--x-string-overflow-scroll, auto);\n }\n</style>\n\n<docs lang=\"mdx\">\n
|
|
1
|
+
{"version":3,"file":"base-scroll.vue.js","sources":["../../../../src/components/scroll/base-scroll.vue"],"sourcesContent":["<template>\n <div @scroll=\"throttledStoreScrollData\" class=\"x-scroll x-base-scroll\" data-test=\"base-scroll\">\n <slot />\n </div>\n</template>\n\n<script lang=\"ts\">\n import { mixins } from 'vue-class-component';\n import { Component } from 'vue-property-decorator';\n import ScrollMixin from './scroll.mixin';\n\n /**\n * Base scroll component that depending on the user interactivity emits different events for\n * knowing when the user scrolls, the direction of scroll and if user reaches the start or end.\n *\n * @public\n */\n @Component\n export default class BaseScroll extends mixins(ScrollMixin) {}\n</script>\n\n<style lang=\"scss\" scoped>\n .x-base-scroll {\n overflow-y: var(--x-string-overflow-scroll, auto);\n }\n</style>\n\n<docs lang=\"mdx\">\n## Example\n\nThe BaseScroll is a component that manage the states of scroll of a specified element. The component\ndoes the necessary calculations for knowing the direction of scroll, if the scroll has reached to\nstart or to end, and is about to reaching to end. The components emits the next events depending of\nmovement that realize the user:\n\n```vue\n<template>\n <BaseScroll\n @scroll=\"scroll\"\n @scroll:direction-change=\"scrollDirectionChange\"\n @scroll:at-start=\"scrollAtStart\"\n @scroll:almost-at-end=\"scrollAlmostAtEnd\"\n @scroll:at-end=\"scrollAtEnd\"\n throttleMs=\"1000\"\n distanceToBottom=\"200\"\n >\n <template>\n <div class=\"content-scroll\">\n <span>content1</span>\n <span>content1</span>\n </div>\n </template>\n </BaseScroll>\n</template>\n\n<script>\n import { BaseScroll } from '@empathyco/x-components';\n\n export default {\n name: 'ScrollTest',\n components: {\n BaseScroll\n },\n methods: {\n scroll(position) {\n console.log('scroll', position);\n },\n scrollDirectionChange(direction) {\n console.log('scroll:direction-change', direction);\n },\n scrollAtStart() {\n console.log('scroll:at-start');\n },\n scrollAlmostAtEnd(distance) {\n console.log('scroll:almost-at-end', distance);\n },\n scrollAtEnd() {\n console.log('scroll:at-end');\n }\n }\n };\n</script>\n```\n\n### Avoid reset scroll on query change\n\nSet to false the reset scroll on query change feature which is true by default.\n\n```vue\n<template>\n <BaseScroll\n @scroll=\"scroll\"\n @scroll:direction-change=\"scrollDirectionChange\"\n @scroll:at-start=\"scrollAtStart\"\n @scroll:almost-at-end=\"scrollAlmostAtEnd\"\n @scroll:at-end=\"scrollAtEnd\"\n throttleMs=\"1000\"\n distanceToBottom=\"200\"\n >\n <template>\n <div class=\"content-scroll\">\n <span>content1</span>\n <span>content1</span>\n </div>\n </template>\n </BaseScroll>\n</template>\n\n<script>\n import { BaseScroll } from '@empathyco/x-components';\n\n export default {\n name: 'ScrollTest',\n components: {\n BaseScroll\n },\n methods: {\n scroll(position) {\n console.log('scroll', position);\n },\n scrollDirectionChange(direction) {\n console.log('scroll:direction-change', direction);\n },\n scrollAtStart() {\n console.log('scroll:at-start');\n },\n scrollAlmostAtEnd(distance) {\n console.log('scroll:almost-at-end', distance);\n },\n scrollAtEnd() {\n console.log('scroll:at-end');\n }\n }\n };\n</script>\n```\n\n## Vue Events:\n\n- `scroll`: the event is emitted after the user scrolls in this container. The payload is the scroll\n top distance in pixels.\n- `scroll:direction-change`: the event is emitted when the user changes the scroll direction. The\n payload is the new scrolling direction.\n- `scroll:at-start`: the event is emitted when the user scrolls up to the initial position of the\n scroll.\n- `scroll:almost-at-end`: the event is emitted when the user is about to reach the bottom part of\n the scroll.\n- `scroll:at-end`: the event is emitted when the user has reached the bottom part of the scroll.\n</docs>\n"],"names":["const"],"mappings":";;;;;AAEAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -6,7 +6,7 @@ import script from './sliding-panel.vue_rollup-plugin-vue=script.js';
|
|
|
6
6
|
var __vue_script__ = script;
|
|
7
7
|
|
|
8
8
|
/* template */
|
|
9
|
-
var __vue_render__ = function() {
|
|
9
|
+
var __vue_render__ = function () {
|
|
10
10
|
var _vm = this;
|
|
11
11
|
var _h = _vm.$createElement;
|
|
12
12
|
var _c = _vm._self._c || _h;
|
|
@@ -16,7 +16,7 @@ var __vue_render__ = function() {
|
|
|
16
16
|
{
|
|
17
17
|
staticClass: "x-sliding-panel",
|
|
18
18
|
class: _vm.cssClasses,
|
|
19
|
-
attrs: { "data-test": "sliding-panel" }
|
|
19
|
+
attrs: { "data-test": "sliding-panel" },
|
|
20
20
|
},
|
|
21
21
|
[
|
|
22
22
|
_vm.showButtons
|
|
@@ -26,13 +26,12 @@ var __vue_render__ = function() {
|
|
|
26
26
|
staticClass:
|
|
27
27
|
"x-sliding-panel__button x-sliding-panel__button-left x-button x-button--round",
|
|
28
28
|
attrs: { "data-test": "sliding-panel-left-button" },
|
|
29
|
-
on: { click: _vm.scrollLeft }
|
|
29
|
+
on: { click: _vm.scrollLeft },
|
|
30
30
|
},
|
|
31
31
|
[
|
|
32
|
-
_vm._t("sliding-panel-left-button", function() {
|
|
32
|
+
_vm._t("sliding-panel-left-button", function () {
|
|
33
33
|
return [_vm._v("ᐸ")]
|
|
34
|
-
})
|
|
35
|
-
],
|
|
34
|
+
}) ],
|
|
36
35
|
2
|
|
37
36
|
)
|
|
38
37
|
: _vm._e(),
|
|
@@ -46,8 +45,8 @@ var __vue_render__ = function() {
|
|
|
46
45
|
on: {
|
|
47
46
|
scroll: _vm.debouncedUpdateScrollPosition,
|
|
48
47
|
transitionend: _vm.debouncedUpdateScrollPosition,
|
|
49
|
-
animationend: _vm.debouncedUpdateScrollPosition
|
|
50
|
-
}
|
|
48
|
+
animationend: _vm.debouncedUpdateScrollPosition,
|
|
49
|
+
},
|
|
51
50
|
},
|
|
52
51
|
[_vm._t("default")],
|
|
53
52
|
2
|
|
@@ -60,17 +59,15 @@ var __vue_render__ = function() {
|
|
|
60
59
|
staticClass:
|
|
61
60
|
"x-sliding-panel__button x-sliding-panel__button-right x-button x-button--round",
|
|
62
61
|
attrs: { "data-test": "sliding-panel-right-button" },
|
|
63
|
-
on: { click: _vm.scrollRight }
|
|
62
|
+
on: { click: _vm.scrollRight },
|
|
64
63
|
},
|
|
65
64
|
[
|
|
66
|
-
_vm._t("sliding-panel-right-button", function() {
|
|
65
|
+
_vm._t("sliding-panel-right-button", function () {
|
|
67
66
|
return [_vm._v("ᐳ")]
|
|
68
|
-
})
|
|
69
|
-
],
|
|
67
|
+
}) ],
|
|
70
68
|
2
|
|
71
69
|
)
|
|
72
|
-
: _vm._e()
|
|
73
|
-
]
|
|
70
|
+
: _vm._e() ]
|
|
74
71
|
)
|
|
75
72
|
: _vm._e()
|
|
76
73
|
};
|
|
@@ -80,11 +77,11 @@ __vue_render__._withStripped = true;
|
|
|
80
77
|
/* style */
|
|
81
78
|
var __vue_inject_styles__ = function (inject) {
|
|
82
79
|
if (!inject) { return }
|
|
83
|
-
inject("data-v-
|
|
80
|
+
inject("data-v-6800b566_0", { source: ".x-sliding-panel[data-v-6800b566] {\n align-items: center;\n display: flex;\n flex-flow: row nowrap;\n height: 100%;\n position: relative;\n}\n.x-sliding-panel__button[data-v-6800b566] {\n opacity: 0;\n pointer-events: none;\n position: absolute;\n transition: all ease-out 0.2s;\n z-index: 2;\n /* To overlay the design system gradient with z-index:1 */\n}\n.x-sliding-panel__button-left[data-v-6800b566] {\n left: 0;\n}\n.x-sliding-panel__button-right[data-v-6800b566] {\n right: 0;\n}\n.x-sliding-panel__scroll[data-v-6800b566] {\n display: flex;\n flex: 100%;\n flex-flow: row nowrap;\n overflow: auto;\n scrollbar-width: none;\n -ms-overflow-style: none;\n}\n.x-sliding-panel__scroll[data-v-6800b566]::-webkit-scrollbar {\n display: none;\n}\n.x-sliding-panel:not(.x-sliding-panel--show-buttons-on-hover):not(.x-sliding-panel--at-start) .x-sliding-panel__button-left[data-v-6800b566] {\n opacity: 1;\n pointer-events: all;\n}\n.x-sliding-panel:not(.x-sliding-panel--show-buttons-on-hover):not(.x-sliding-panel--at-end) .x-sliding-panel__button-right[data-v-6800b566] {\n opacity: 1;\n pointer-events: all;\n}", map: undefined, media: undefined });
|
|
84
81
|
|
|
85
82
|
};
|
|
86
83
|
/* scoped */
|
|
87
|
-
var __vue_scope_id__ = "data-v-
|
|
84
|
+
var __vue_scope_id__ = "data-v-6800b566";
|
|
88
85
|
/* module identifier */
|
|
89
86
|
var __vue_module_identifier__ = undefined;
|
|
90
87
|
/* functional template */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sliding-panel.vue.js","sources":["../../../src/components/sliding-panel.vue"],"sourcesContent":["<template>\n <div v-if=\"$slots.default\" class=\"x-sliding-panel\" :class=\"cssClasses\" data-test=\"sliding-panel\">\n <button\n v-if=\"showButtons\"\n @click=\"scrollLeft\"\n class=\"x-sliding-panel__button x-sliding-panel__button-left x-button x-button--round\"\n data-test=\"sliding-panel-left-button\"\n >\n <!-- @slot Left button content -->\n <slot name=\"sliding-panel-left-button\">ᐸ</slot>\n </button>\n <div\n ref=\"scrollContainer\"\n @scroll=\"debouncedUpdateScrollPosition\"\n @transitionend=\"debouncedUpdateScrollPosition\"\n @animationend=\"debouncedUpdateScrollPosition\"\n class=\"x-list x-list--horizontal x-sliding-panel__scroll\"\n data-test=\"sliding-panel-scroll\"\n >\n <!-- @slot (Required) Sliding panel content -->\n <slot />\n </div>\n <button\n v-if=\"showButtons\"\n @click=\"scrollRight\"\n class=\"x-sliding-panel__button x-sliding-panel__button-right x-button x-button--round\"\n data-test=\"sliding-panel-right-button\"\n >\n <!-- @slot Right button content -->\n <slot name=\"sliding-panel-right-button\">ᐳ</slot>\n </button>\n </div>\n</template>\n\n<script lang=\"ts\">\n import Vue from 'vue';\n import { Component, Prop } from 'vue-property-decorator';\n import { VueCSSClasses } from '../utils/types';\n import { Debounce } from './decorators/debounce.decorators';\n\n /**\n * Horizontal slide panel component. The content that is provided to this component would be\n * navigable horizontally using two navigational buttons.\n *\n * @public\n */\n @Component\n export default class SlidingPanel extends Vue {\n /**\n * Scroll factor that will dictate how much the scroll moves when pressing a navigation button.\n */\n @Prop({ default: 0.7 })\n protected scrollFactor!: number;\n\n /**\n * Would make the navigation buttons visible when they're needed or always hide them.\n */\n @Prop({ default: true })\n protected showButtons!: boolean;\n\n /**\n * MutationObserver that watches for changes inside the wrapping div to update\n * the scroll position.\n */\n protected scrollObserver = new MutationObserver(\n // eslint-disable-next-line @typescript-eslint/unbound-method\n this.restoreAndUpdateScroll\n );\n\n /**\n * Indicates if the scroll is at the start of the sliding panel.\n */\n protected isScrollAtStart = true;\n\n /**\n * Indicates if the scroll is at the end of the sliding panel.\n */\n protected isScrollAtEnd = true;\n\n /**\n * HTMLElement referencing the scroll of the component.\n */\n public $refs!: {\n scrollContainer: HTMLElement;\n };\n\n mounted(): void {\n this.scrollObserver.observe(this.$refs.scrollContainer, {\n attributes: false,\n childList: true,\n subtree: true,\n characterData: false\n });\n // eslint-disable-next-line @typescript-eslint/unbound-method\n window?.addEventListener('resize', this.debouncedUpdateScrollPosition);\n\n this.updateScrollPosition();\n }\n\n beforeDestroy(): void {\n this.scrollObserver.disconnect();\n // eslint-disable-next-line @typescript-eslint/unbound-method\n window?.removeEventListener('resize', this.debouncedUpdateScrollPosition);\n }\n\n /**\n * Resets the scroll and updates the values of the scroll for the buttons to react.\n *\n * @internal\n */\n @Debounce(100, { leading: true })\n restoreAndUpdateScroll(): void {\n this.$refs.scrollContainer.scroll({ left: 0, behavior: 'smooth' });\n this.updateScrollPosition();\n }\n\n /**\n * Updates the values of the scroll positions to show or hide the buttons depending on it.\n *\n * @internal\n */\n protected updateScrollPosition(): void {\n const { scrollLeft, clientWidth, scrollWidth } = this.$refs.scrollContainer;\n this.isScrollAtStart = !scrollLeft;\n /* The 2 px extra is to fix some cases in some resolutions where the scroll + client size is\n * less than the scroll width even when the scroll is at the end */\n this.isScrollAtEnd = scrollLeft + clientWidth + 2 >= scrollWidth;\n }\n\n /**\n * Debounced version of the {@link SlidingPanel.updateScrollPosition | updateScrollPosition}\n * method.\n *\n * @internal\n */\n @Debounce(100, { leading: true })\n debouncedUpdateScrollPosition(): void {\n this.updateScrollPosition();\n }\n\n /**\n * Scrolls the wrapper element to the left.\n *\n * @internal\n */\n protected scrollLeft(): void {\n this.scrollTo(-this.$refs.scrollContainer.clientWidth);\n }\n\n /**\n * Scrolls the wrapper element to the right.\n *\n * @internal\n */\n protected scrollRight(): void {\n this.scrollTo(this.$refs.scrollContainer.clientWidth);\n }\n\n /**\n * Scrolls the wrapper element towards the provided scroll value.\n *\n * @param scrollValue - The value the scroll will go towards.\n *\n * @remarks this function uses the scrollBy from Element and it's not available in all browsers.\n *\n * @internal\n */\n protected scrollTo(scrollValue: number): void {\n this.$refs.scrollContainer.scrollBy({\n left: scrollValue * this.scrollFactor,\n behavior: 'smooth'\n });\n }\n\n /**\n * CSS classes to apply based on the scroll position.\n *\n * @returns The CSS classes to apply.\n *\n * @internal\n */\n protected get cssClasses(): VueCSSClasses {\n return {\n 'x-sliding-panel--at-start': this.isScrollAtStart,\n 'x-sliding-panel--at-end': this.isScrollAtEnd\n };\n }\n }\n</script>\n\n<style lang=\"scss\" scoped>\n .x-sliding-panel {\n align-items: center;\n display: flex;\n flex-flow: row nowrap;\n height: 100%;\n position: relative;\n\n &__button {\n opacity: 0;\n pointer-events: none;\n position: absolute;\n transition: all ease-out 0.2s;\n z-index: 2; /* To overlay the design system gradient with z-index:1 */\n\n &-left {\n left: 0;\n }\n\n &-right {\n right: 0;\n }\n }\n\n &__scroll {\n display: flex;\n flex: 100%;\n flex-flow: row nowrap;\n overflow: auto;\n scrollbar-width: none; // Firefox\n -ms-overflow-style: none; // IE\n\n // Chrome, Edge & Safari\n &::-webkit-scrollbar {\n display: none;\n }\n }\n\n &:not(.x-sliding-panel--show-buttons-on-hover):not(.x-sliding-panel--at-start) {\n .x-sliding-panel__button-left {\n opacity: 1;\n pointer-events: all;\n }\n }\n &:not(.x-sliding-panel--show-buttons-on-hover):not(.x-sliding-panel--at-end) {\n .x-sliding-panel__button-right {\n opacity: 1;\n pointer-events: all;\n }\n }\n }\n</style>\n\n<docs lang=\"mdx\">\n
|
|
1
|
+
{"version":3,"file":"sliding-panel.vue.js","sources":["../../../src/components/sliding-panel.vue"],"sourcesContent":["<template>\n <div v-if=\"$slots.default\" class=\"x-sliding-panel\" :class=\"cssClasses\" data-test=\"sliding-panel\">\n <button\n v-if=\"showButtons\"\n @click=\"scrollLeft\"\n class=\"x-sliding-panel__button x-sliding-panel__button-left x-button x-button--round\"\n data-test=\"sliding-panel-left-button\"\n >\n <!-- @slot Left button content -->\n <slot name=\"sliding-panel-left-button\">ᐸ</slot>\n </button>\n <div\n ref=\"scrollContainer\"\n @scroll=\"debouncedUpdateScrollPosition\"\n @transitionend=\"debouncedUpdateScrollPosition\"\n @animationend=\"debouncedUpdateScrollPosition\"\n class=\"x-list x-list--horizontal x-sliding-panel__scroll\"\n data-test=\"sliding-panel-scroll\"\n >\n <!-- @slot (Required) Sliding panel content -->\n <slot />\n </div>\n <button\n v-if=\"showButtons\"\n @click=\"scrollRight\"\n class=\"x-sliding-panel__button x-sliding-panel__button-right x-button x-button--round\"\n data-test=\"sliding-panel-right-button\"\n >\n <!-- @slot Right button content -->\n <slot name=\"sliding-panel-right-button\">ᐳ</slot>\n </button>\n </div>\n</template>\n\n<script lang=\"ts\">\n import Vue from 'vue';\n import { Component, Prop } from 'vue-property-decorator';\n import { VueCSSClasses } from '../utils/types';\n import { Debounce } from './decorators/debounce.decorators';\n\n /**\n * Horizontal slide panel component. The content that is provided to this component would be\n * navigable horizontally using two navigational buttons.\n *\n * @public\n */\n @Component\n export default class SlidingPanel extends Vue {\n /**\n * Scroll factor that will dictate how much the scroll moves when pressing a navigation button.\n */\n @Prop({ default: 0.7 })\n protected scrollFactor!: number;\n\n /**\n * Would make the navigation buttons visible when they're needed or always hide them.\n */\n @Prop({ default: true })\n protected showButtons!: boolean;\n\n /**\n * MutationObserver that watches for changes inside the wrapping div to update\n * the scroll position.\n */\n protected scrollObserver = new MutationObserver(\n // eslint-disable-next-line @typescript-eslint/unbound-method\n this.restoreAndUpdateScroll\n );\n\n /**\n * Indicates if the scroll is at the start of the sliding panel.\n */\n protected isScrollAtStart = true;\n\n /**\n * Indicates if the scroll is at the end of the sliding panel.\n */\n protected isScrollAtEnd = true;\n\n /**\n * HTMLElement referencing the scroll of the component.\n */\n public $refs!: {\n scrollContainer: HTMLElement;\n };\n\n mounted(): void {\n this.scrollObserver.observe(this.$refs.scrollContainer, {\n attributes: false,\n childList: true,\n subtree: true,\n characterData: false\n });\n // eslint-disable-next-line @typescript-eslint/unbound-method\n window?.addEventListener('resize', this.debouncedUpdateScrollPosition);\n\n this.updateScrollPosition();\n }\n\n beforeDestroy(): void {\n this.scrollObserver.disconnect();\n // eslint-disable-next-line @typescript-eslint/unbound-method\n window?.removeEventListener('resize', this.debouncedUpdateScrollPosition);\n }\n\n /**\n * Resets the scroll and updates the values of the scroll for the buttons to react.\n *\n * @internal\n */\n @Debounce(100, { leading: true })\n restoreAndUpdateScroll(): void {\n this.$refs.scrollContainer.scroll({ left: 0, behavior: 'smooth' });\n this.updateScrollPosition();\n }\n\n /**\n * Updates the values of the scroll positions to show or hide the buttons depending on it.\n *\n * @internal\n */\n protected updateScrollPosition(): void {\n const { scrollLeft, clientWidth, scrollWidth } = this.$refs.scrollContainer;\n this.isScrollAtStart = !scrollLeft;\n /* The 2 px extra is to fix some cases in some resolutions where the scroll + client size is\n * less than the scroll width even when the scroll is at the end */\n this.isScrollAtEnd = scrollLeft + clientWidth + 2 >= scrollWidth;\n }\n\n /**\n * Debounced version of the {@link SlidingPanel.updateScrollPosition | updateScrollPosition}\n * method.\n *\n * @internal\n */\n @Debounce(100, { leading: true })\n debouncedUpdateScrollPosition(): void {\n this.updateScrollPosition();\n }\n\n /**\n * Scrolls the wrapper element to the left.\n *\n * @internal\n */\n protected scrollLeft(): void {\n this.scrollTo(-this.$refs.scrollContainer.clientWidth);\n }\n\n /**\n * Scrolls the wrapper element to the right.\n *\n * @internal\n */\n protected scrollRight(): void {\n this.scrollTo(this.$refs.scrollContainer.clientWidth);\n }\n\n /**\n * Scrolls the wrapper element towards the provided scroll value.\n *\n * @param scrollValue - The value the scroll will go towards.\n *\n * @remarks this function uses the scrollBy from Element and it's not available in all browsers.\n *\n * @internal\n */\n protected scrollTo(scrollValue: number): void {\n this.$refs.scrollContainer.scrollBy({\n left: scrollValue * this.scrollFactor,\n behavior: 'smooth'\n });\n }\n\n /**\n * CSS classes to apply based on the scroll position.\n *\n * @returns The CSS classes to apply.\n *\n * @internal\n */\n protected get cssClasses(): VueCSSClasses {\n return {\n 'x-sliding-panel--at-start': this.isScrollAtStart,\n 'x-sliding-panel--at-end': this.isScrollAtEnd\n };\n }\n }\n</script>\n\n<style lang=\"scss\" scoped>\n .x-sliding-panel {\n align-items: center;\n display: flex;\n flex-flow: row nowrap;\n height: 100%;\n position: relative;\n\n &__button {\n opacity: 0;\n pointer-events: none;\n position: absolute;\n transition: all ease-out 0.2s;\n z-index: 2; /* To overlay the design system gradient with z-index:1 */\n\n &-left {\n left: 0;\n }\n\n &-right {\n right: 0;\n }\n }\n\n &__scroll {\n display: flex;\n flex: 100%;\n flex-flow: row nowrap;\n overflow: auto;\n scrollbar-width: none; // Firefox\n -ms-overflow-style: none; // IE\n\n // Chrome, Edge & Safari\n &::-webkit-scrollbar {\n display: none;\n }\n }\n\n &:not(.x-sliding-panel--show-buttons-on-hover):not(.x-sliding-panel--at-start) {\n .x-sliding-panel__button-left {\n opacity: 1;\n pointer-events: all;\n }\n }\n &:not(.x-sliding-panel--show-buttons-on-hover):not(.x-sliding-panel--at-end) {\n .x-sliding-panel__button-right {\n opacity: 1;\n pointer-events: all;\n }\n }\n }\n</style>\n\n<docs lang=\"mdx\">\n## Examples\n\nThis component allows for any other component or element inside it to be horizontally navigable. It\nalso implements customizable buttons as well as other minor customizations to its general behavior.\nThe component uses the method `scrollBy` from `Element` to function, and it doesn't work properly in\nall browsers. A polyfill for the `scrollBy` would be needed for the component to behave as expected\nin those browsers.\n\n### Default usage\n\nSimplest implementation of the component, just a list-based component inside its slot.\n\n```vue\n<SlidingPanel>\n <RelatedTags />\n</SlidingPanel>\n```\n\n### Behavior customization\n\nEdit how much the scroll travels when navigating with the buttons by changing the `scrollFactor`.\n\n```vue\n<SlidingPanel :scrollFactor=\"1.2\">\n <RelatedTags />\n</SlidingPanel>\n```\n\nHide the navigational buttons completely by setting the `showButtons` prop to `false`. This is\nintended to be used when other scrolling options are available, like in mobile, where you can scroll\njust by swiping.\n\n```vue\n<SlidingPanel :showButtons=\"isMobile\">\n <RelatedTags />\n</SlidingPanel>\n```\n\n### Overriding Button content\n\nBy default the buttons show an arrow depicting the direction the scroll would go to when clicked,\nbut this content can be customized with anything, from characters to SVG and images.\n\n```vue\n<SlidingPanel>\n <template #sliding-panel-left-button>\n Left\n </template>\n <RelatedTags />\n <template #sliding-panel-right-button>\n Right\n </template>\n</SlidingPanel>\n```\n</docs>\n"],"names":["const"],"mappings":";;;;;AAEAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import __vue_normalize__ from 'vue-runtime-helpers/dist/normalize-component.js';
|
|
2
|
+
import script from './snippet-callbacks.vue_rollup-plugin-vue=script.js';
|
|
3
|
+
|
|
4
|
+
/* script */
|
|
5
|
+
var __vue_script__ = script;
|
|
6
|
+
|
|
7
|
+
/* template */
|
|
8
|
+
var __vue_render__ = function () {
|
|
9
|
+
var _vm = this;
|
|
10
|
+
var _h = _vm.$createElement;
|
|
11
|
+
var _c = _vm._self._c || _h;
|
|
12
|
+
return _c("GlobalXBus", _vm._g({}, _vm.eventListeners))
|
|
13
|
+
};
|
|
14
|
+
var __vue_staticRenderFns__ = [];
|
|
15
|
+
__vue_render__._withStripped = true;
|
|
16
|
+
|
|
17
|
+
/* style */
|
|
18
|
+
var __vue_inject_styles__ = undefined;
|
|
19
|
+
/* scoped */
|
|
20
|
+
var __vue_scope_id__ = undefined;
|
|
21
|
+
/* module identifier */
|
|
22
|
+
var __vue_module_identifier__ = undefined;
|
|
23
|
+
/* functional template */
|
|
24
|
+
var __vue_is_functional_template__ = false;
|
|
25
|
+
/* style inject */
|
|
26
|
+
|
|
27
|
+
/* style inject SSR */
|
|
28
|
+
|
|
29
|
+
/* style inject shadow dom */
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
var __vue_component__ = /*#__PURE__*/__vue_normalize__(
|
|
34
|
+
{ render: __vue_render__, staticRenderFns: __vue_staticRenderFns__ },
|
|
35
|
+
__vue_inject_styles__,
|
|
36
|
+
__vue_script__,
|
|
37
|
+
__vue_scope_id__,
|
|
38
|
+
__vue_is_functional_template__,
|
|
39
|
+
__vue_module_identifier__,
|
|
40
|
+
false,
|
|
41
|
+
undefined,
|
|
42
|
+
undefined,
|
|
43
|
+
undefined
|
|
44
|
+
);
|
|
45
|
+
|
|
46
|
+
export default __vue_component__;
|
|
47
|
+
//# sourceMappingURL=snippet-callbacks.vue.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"snippet-callbacks.vue.js","sources":["../../../src/components/snippet-callbacks.vue"],"sourcesContent":["<template>\n <GlobalXBus v-on=\"eventListeners\" />\n</template>\n\n<script lang=\"ts\">\n import { Component, Inject } from 'vue-property-decorator';\n import Vue from 'vue';\n import { map } from '../utils/object';\n import { WireMetadata } from '../wiring';\n import { SnippetConfig, XEventListeners } from '../x-installer/api/api.types';\n import GlobalXBus from './global-x-bus.vue';\n\n /**\n * This component subscribes to any {@link XEvent} with a custom callbacks provided by the snippet\n * configuration.\n *\n * @public\n */\n @Component({\n components: { GlobalXBus }\n })\n export default class SnippetCallbacks extends Vue {\n /**\n * Injects {@link SnippetConfig} provided by an ancestor as snippetConfig.\n *\n * @internal\n */\n @Inject('snippetConfig')\n public snippetConfig!: SnippetConfig;\n\n /**\n * It maps all the callbacks provided by the snippetConfig and adds an emit to each one.\n *\n * @returns The event listeners with the {@link XEventsTypes.SnippetCallbackExecuted} emit in\n * the callback.\n *\n * @internal\n *\n */\n protected get eventListeners(): XEventListeners {\n const { callbacks } = this.snippetConfig;\n return callbacks\n ? map(callbacks, (eventName, callback) => {\n return (payload: unknown, metadata: WireMetadata) => {\n const callbackReturn = callback(payload as never, metadata);\n this.$x.emit('SnippetCallbackExecuted', {\n event: eventName,\n callbackReturn\n });\n };\n })\n : ({} as XEventListeners);\n }\n }\n</script>\n\n<docs lang=\"mdx\">\n## Events\n\nThe `SnippetCallbacks` will emit the `SnippetCallbackExecuted` each time a callback provided by the\nsnippetConfig is fired.\n\n## See it in action\n\nThis component does not render anything. Its only responsibility is to receive any callback that\nwill be triggered once its listened event is emitted.\n\n```vue\n<template>\n <SnippetCallbacks />\n</template>\n\n<script>\n import { SnippetCallbacks } from '@empathyco/x-components';\n export default {\n name: 'SnippetCallbacksTest',\n components: {\n SnippetCallbacks\n }\n };\n</script>\n```\n</docs>\n"],"names":["const"],"mappings":";;;;AAEAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import { __extends, __decorate } from 'tslib';
|
|
2
|
+
import Vue from 'vue';
|
|
3
|
+
import { Inject, Component } from 'vue-property-decorator';
|
|
4
|
+
import { map } from '../utils/object.js';
|
|
5
|
+
import GlobalXBus from './global-x-bus.vue.js';
|
|
6
|
+
|
|
7
|
+
/**
|
|
8
|
+
* This component subscribes to any {@link XEvent} with a custom callbacks provided by the snippet
|
|
9
|
+
* configuration.
|
|
10
|
+
*
|
|
11
|
+
* @public
|
|
12
|
+
*/
|
|
13
|
+
var SnippetCallbacks = /** @class */ (function (_super) {
|
|
14
|
+
__extends(SnippetCallbacks, _super);
|
|
15
|
+
function SnippetCallbacks() {
|
|
16
|
+
return _super !== null && _super.apply(this, arguments) || this;
|
|
17
|
+
}
|
|
18
|
+
Object.defineProperty(SnippetCallbacks.prototype, "eventListeners", {
|
|
19
|
+
/**
|
|
20
|
+
* It maps all the callbacks provided by the snippetConfig and adds an emit to each one.
|
|
21
|
+
*
|
|
22
|
+
* @returns The event listeners with the {@link XEventsTypes.SnippetCallbackExecuted} emit in
|
|
23
|
+
* the callback.
|
|
24
|
+
*
|
|
25
|
+
* @internal
|
|
26
|
+
*
|
|
27
|
+
*/
|
|
28
|
+
get: function () {
|
|
29
|
+
var _this = this;
|
|
30
|
+
var callbacks = this.snippetConfig.callbacks;
|
|
31
|
+
return callbacks
|
|
32
|
+
? map(callbacks, function (eventName, callback) {
|
|
33
|
+
return function (payload, metadata) {
|
|
34
|
+
var callbackReturn = callback(payload, metadata);
|
|
35
|
+
_this.$x.emit('SnippetCallbackExecuted', {
|
|
36
|
+
event: eventName,
|
|
37
|
+
callbackReturn: callbackReturn
|
|
38
|
+
});
|
|
39
|
+
};
|
|
40
|
+
})
|
|
41
|
+
: {};
|
|
42
|
+
},
|
|
43
|
+
enumerable: false,
|
|
44
|
+
configurable: true
|
|
45
|
+
});
|
|
46
|
+
__decorate([
|
|
47
|
+
Inject('snippetConfig')
|
|
48
|
+
], SnippetCallbacks.prototype, "snippetConfig", void 0);
|
|
49
|
+
SnippetCallbacks = __decorate([
|
|
50
|
+
Component({
|
|
51
|
+
components: { GlobalXBus: GlobalXBus }
|
|
52
|
+
})
|
|
53
|
+
], SnippetCallbacks);
|
|
54
|
+
return SnippetCallbacks;
|
|
55
|
+
}(Vue));
|
|
56
|
+
|
|
57
|
+
export default SnippetCallbacks;
|
|
58
|
+
//# sourceMappingURL=snippet-callbacks.vue_rollup-plugin-vue=script.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"snippet-callbacks.vue_rollup-plugin-vue=script.js","sources":["../../../src/components/snippet-callbacks.vue?rollup-plugin-vue=script.ts"],"sourcesContent":["\n\n\n\n\nimport { Component, Inject } from 'vue-property-decorator';\nimport Vue from 'vue';\nimport { map } from '../utils/object';\nimport { WireMetadata } from '../wiring';\nimport { SnippetConfig, XEventListeners } from '../x-installer/api/api.types';\nimport GlobalXBus from './global-x-bus.vue';\n\n/**\n * This component subscribes to any {@link XEvent} with a custom callbacks provided by the snippet\n * configuration.\n *\n * @public\n */\n@Component({\n components: { GlobalXBus }\n})\nexport default class SnippetCallbacks extends Vue {\n /**\n * Injects {@link SnippetConfig} provided by an ancestor as snippetConfig.\n *\n * @internal\n */\n @Inject('snippetConfig')\n public snippetConfig!: SnippetConfig;\n\n /**\n * It maps all the callbacks provided by the snippetConfig and adds an emit to each one.\n *\n * @returns The event listeners with the {@link XEventsTypes.SnippetCallbackExecuted} emit in\n * the callback.\n *\n * @internal\n *\n */\n protected get eventListeners(): XEventListeners {\n const { callbacks } = this.snippetConfig;\n return callbacks\n ? map(callbacks, (eventName, callback) => {\n return (payload: unknown, metadata: WireMetadata) => {\n const callbackReturn = callback(payload as never, metadata);\n this.$x.emit('SnippetCallbackExecuted', {\n event: eventName,\n callbackReturn\n });\n };\n })\n : ({} as XEventListeners);\n }\n}\n"],"names":[],"mappings":";;;;;;AAYA;;;;;;AASA;IAA8C,oCAAG;IAAjD;;KAgCC;IAdC,sBAAc,4CAAc;;;;;;;;;;aAA5B;YAAA,iBAaC;YAZS,IAAA,SAAS,GAAK,IAAI,CAAC,aAAa,UAAvB,CAAwB;YACzC,OAAO,SAAS;kBACZ,GAAG,CAAC,SAAS,EAAE,UAAC,SAAS,EAAE,QAAQ;oBACjC,OAAO,UAAC,OAAgB,EAAE,QAAsB;wBAC9C,IAAM,cAAc,GAAG,QAAQ,CAAC,OAAgB,EAAE,QAAQ,CAAC,CAAC;wBAC5D,KAAI,CAAC,EAAE,CAAC,IAAI,CAAC,yBAAyB,EAAE;4BACtC,KAAK,EAAE,SAAS;4BAChB,cAAc,gBAAA;yBACf,CAAC,CAAC;qBACJ,CAAC;iBACH,CAAC;kBACD,EAAsB,CAAC;SAC7B;;;OAAA;IAxBD;QADC,MAAM,CAAC,eAAe,CAAC;2DACa;IAPlB,gBAAgB;QAHpC,SAAS,CAAC;YACT,UAAU,EAAE,EAAE,UAAU,YAAA,EAAE;SAC3B,CAAC;OACmB,gBAAgB,CAgCpC;IAAD,uBAAC;CAAA,CAhC6C,GAAG;;;;"}
|
|
@@ -5,7 +5,7 @@ import script from './base-suggestion.vue_rollup-plugin-vue=script.js';
|
|
|
5
5
|
var __vue_script__ = script;
|
|
6
6
|
|
|
7
7
|
/* template */
|
|
8
|
-
var __vue_render__ = function() {
|
|
8
|
+
var __vue_render__ = function () {
|
|
9
9
|
var _vm = this;
|
|
10
10
|
var _h = _vm.$createElement;
|
|
11
11
|
var _c = _vm._self._c || _h;
|
|
@@ -14,24 +14,22 @@ var __vue_render__ = function() {
|
|
|
14
14
|
{
|
|
15
15
|
staticClass: "x-suggestion",
|
|
16
16
|
class: _vm.dynamicCSSClasses,
|
|
17
|
-
on: { click: _vm.emitEvents }
|
|
17
|
+
on: { click: _vm.emitEvents },
|
|
18
18
|
},
|
|
19
19
|
[
|
|
20
20
|
_vm._t(
|
|
21
21
|
"default",
|
|
22
|
-
function() {
|
|
22
|
+
function () {
|
|
23
23
|
return [
|
|
24
24
|
_c("span", {
|
|
25
25
|
staticClass: "x-suggestion__query",
|
|
26
26
|
attrs: { "aria-label": _vm.suggestion.query },
|
|
27
|
-
domProps: { innerHTML: _vm._s(_vm.queryHTML) }
|
|
28
|
-
})
|
|
29
|
-
]
|
|
27
|
+
domProps: { innerHTML: _vm._s(_vm.queryHTML) },
|
|
28
|
+
}) ]
|
|
30
29
|
},
|
|
31
30
|
null,
|
|
32
31
|
{ suggestion: _vm.suggestion, queryHTML: _vm.queryHTML }
|
|
33
|
-
)
|
|
34
|
-
],
|
|
32
|
+
) ],
|
|
35
33
|
2
|
|
36
34
|
)
|
|
37
35
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"base-suggestion.vue.js","sources":["../../../../src/components/suggestions/base-suggestion.vue"],"sourcesContent":["<template>\n <button @click=\"emitEvents\" :class=\"dynamicCSSClasses\" class=\"x-suggestion\">\n <!-- eslint-disable max-len -->\n <!--\n @slot Button content\n @binding {Suggestion} suggestion - Suggestion data\n @binding {string} queryHTML - Suggestion's query with the matching part inside a `<span>` tag\n -->\n <!-- eslint-enable max-len -->\n <slot v-bind=\"{ suggestion, queryHTML }\">\n <span v-html=\"queryHTML\" :aria-label=\"suggestion.query\" class=\"x-suggestion__query\" />\n </slot>\n </button>\n</template>\n\n<script lang=\"ts\">\n import { Suggestion } from '@empathyco/x-types';\n import Vue from 'vue';\n import { Component, Prop } from 'vue-property-decorator';\n import { QueryFeature } from '../../types/origin';\n import { forEach } from '../../utils/object';\n import { normalizeString } from '../../utils/normalize';\n import { sanitize } from '../../utils/sanitize';\n import { VueCSSClasses } from '../../utils/types';\n import { XEventsTypes } from '../../wiring/events.types';\n\n /**\n * Renders a button with a default slot. It receives a query, which should be the query of the\n * module using this component, a suggestion, the {@link XEvent | XEvents} that will be emitted\n * on click with a given feature.\n *\n * The default slot receives the suggestion and the matched query has props.\n *\n * @public\n */\n @Component\n export default class BaseSuggestion extends Vue {\n /**\n * The normalized query of the module using this component.\n *\n * @public\n */\n @Prop({ default: '' })\n protected query!: string;\n\n /**\n * The suggestion to render and use in the default slot.\n *\n * @public\n */\n @Prop({ required: true })\n protected suggestion!: Suggestion;\n\n /**\n * The feature from which the events will be emitted.\n *\n * @public\n */\n @Prop() //TODO: set to true when the suggestions components pass it.\n protected feature?: QueryFeature;\n\n /**\n * The {@link XEvent | XEvents} that will be emitted when selecting a suggestion.\n *\n * @public\n */\n @Prop({ required: true })\n protected suggestionSelectedEvents!: Partial<XEventsTypes>;\n\n /**\n * The event handler that will be triggered when clicking on a suggestion.\n *\n * @remarks\n * * UserAcceptedAQuery: suggestion.query\n * * UserSelectedASuggestion: suggestion\n * * Merges the events defined in the suggestionSelectedEvents prop and also emits them\n *\n * @returns The {@link XEvent | XEvents} to emit.\n * @public\n */\n protected get events(): Partial<XEventsTypes> {\n return {\n UserAcceptedAQuery: this.suggestion.query,\n UserSelectedASuggestion: this.suggestion,\n ...this.suggestionSelectedEvents\n };\n }\n\n /**\n * Emits the events when the button is clicked.\n *\n * @public\n */\n protected emitEvents(): void {\n forEach(this.events, (event, payload) => {\n this.$x.emit(event, payload, {\n target: this.$el as HTMLElement,\n feature: this.feature\n });\n });\n }\n\n /**\n * Checks if the normalized suggestion query matches with the module's query so it has a\n * matching part.\n *\n * @returns If the query has a matching part or not.\n * @internal\n */\n protected get hasMatchingQuery(): boolean {\n return !!this.query && normalizeString(this.suggestion.query).includes(this.query);\n }\n\n /**\n * Generates css classes dynamically.\n *\n * @remarks\n * 'x-suggestion--matching added when the query should be matched.\n *\n * @returns The {@link VueCSSClasses} classes.\n * @public\n */\n protected get dynamicCSSClasses(): VueCSSClasses {\n return {\n 'x-suggestion--matching': this.hasMatchingQuery\n };\n }\n\n /**\n * Highlights the matching part of the suggestion query with the query passed as prop of the\n * component putting it inside a `<span>` tag.\n *\n * @remarks\n * The query prop should be normalized.\n *\n * @returns The suggestion's query with the matching part inside a `<span>` tag.\n * @public\n */\n protected get queryHTML(): string {\n if (this.hasMatchingQuery) {\n const matcherIndex = normalizeString(this.suggestion.query).indexOf(this.query);\n\n const [beginning, matching, end] = this.splitAt(\n this.suggestion.query,\n matcherIndex,\n this.query.length\n );\n\n const attrsMatching = 'data-test=\"matching-part\" class=\"x-suggestion__matching-part\"';\n return `${beginning}<span ${attrsMatching}>${matching}</span>${end}`;\n }\n\n return sanitize(this.suggestion.query);\n }\n\n /**\n * Splits the label in three parts based on two indexes.\n *\n * @param label - The string that will be divided in three parts.\n * @param start - The first index that the label will be divided by.\n * @param skip - The second index that the label will be divided by.\n *\n * @returns The three parts of the divided label.\n * @internal\n */\n protected splitAt(label: string, start: number, skip: number): [string, string, string] {\n const startPart = label.substr(0, start);\n const matchingPart = label.substr(start, skip);\n const endPart = label.substr(start + skip);\n\n return [sanitize(startPart), sanitize(matchingPart), sanitize(endPart)];\n }\n }\n</script>\n\n<docs lang=\"mdx\">\n
|
|
1
|
+
{"version":3,"file":"base-suggestion.vue.js","sources":["../../../../src/components/suggestions/base-suggestion.vue"],"sourcesContent":["<template>\n <button @click=\"emitEvents\" :class=\"dynamicCSSClasses\" class=\"x-suggestion\">\n <!-- eslint-disable max-len -->\n <!--\n @slot Button content\n @binding {Suggestion} suggestion - Suggestion data\n @binding {string} queryHTML - Suggestion's query with the matching part inside a `<span>` tag\n -->\n <!-- eslint-enable max-len -->\n <slot v-bind=\"{ suggestion, queryHTML }\">\n <span v-html=\"queryHTML\" :aria-label=\"suggestion.query\" class=\"x-suggestion__query\" />\n </slot>\n </button>\n</template>\n\n<script lang=\"ts\">\n import { Suggestion } from '@empathyco/x-types';\n import Vue from 'vue';\n import { Component, Prop } from 'vue-property-decorator';\n import { QueryFeature } from '../../types/origin';\n import { forEach } from '../../utils/object';\n import { normalizeString } from '../../utils/normalize';\n import { sanitize } from '../../utils/sanitize';\n import { VueCSSClasses } from '../../utils/types';\n import { XEventsTypes } from '../../wiring/events.types';\n\n /**\n * Renders a button with a default slot. It receives a query, which should be the query of the\n * module using this component, a suggestion, the {@link XEvent | XEvents} that will be emitted\n * on click with a given feature.\n *\n * The default slot receives the suggestion and the matched query has props.\n *\n * @public\n */\n @Component\n export default class BaseSuggestion extends Vue {\n /**\n * The normalized query of the module using this component.\n *\n * @public\n */\n @Prop({ default: '' })\n protected query!: string;\n\n /**\n * The suggestion to render and use in the default slot.\n *\n * @public\n */\n @Prop({ required: true })\n protected suggestion!: Suggestion;\n\n /**\n * The feature from which the events will be emitted.\n *\n * @public\n */\n @Prop() //TODO: set to true when the suggestions components pass it.\n protected feature?: QueryFeature;\n\n /**\n * The {@link XEvent | XEvents} that will be emitted when selecting a suggestion.\n *\n * @public\n */\n @Prop({ required: true })\n protected suggestionSelectedEvents!: Partial<XEventsTypes>;\n\n /**\n * The event handler that will be triggered when clicking on a suggestion.\n *\n * @remarks\n * * UserAcceptedAQuery: suggestion.query\n * * UserSelectedASuggestion: suggestion\n * * Merges the events defined in the suggestionSelectedEvents prop and also emits them\n *\n * @returns The {@link XEvent | XEvents} to emit.\n * @public\n */\n protected get events(): Partial<XEventsTypes> {\n return {\n UserAcceptedAQuery: this.suggestion.query,\n UserSelectedASuggestion: this.suggestion,\n ...this.suggestionSelectedEvents\n };\n }\n\n /**\n * Emits the events when the button is clicked.\n *\n * @public\n */\n protected emitEvents(): void {\n forEach(this.events, (event, payload) => {\n this.$x.emit(event, payload, {\n target: this.$el as HTMLElement,\n feature: this.feature\n });\n });\n }\n\n /**\n * Checks if the normalized suggestion query matches with the module's query so it has a\n * matching part.\n *\n * @returns If the query has a matching part or not.\n * @internal\n */\n protected get hasMatchingQuery(): boolean {\n return !!this.query && normalizeString(this.suggestion.query).includes(this.query);\n }\n\n /**\n * Generates css classes dynamically.\n *\n * @remarks\n * 'x-suggestion--matching added when the query should be matched.\n *\n * @returns The {@link VueCSSClasses} classes.\n * @public\n */\n protected get dynamicCSSClasses(): VueCSSClasses {\n return {\n 'x-suggestion--matching': this.hasMatchingQuery\n };\n }\n\n /**\n * Highlights the matching part of the suggestion query with the query passed as prop of the\n * component putting it inside a `<span>` tag.\n *\n * @remarks\n * The query prop should be normalized.\n *\n * @returns The suggestion's query with the matching part inside a `<span>` tag.\n * @public\n */\n protected get queryHTML(): string {\n if (this.hasMatchingQuery) {\n const matcherIndex = normalizeString(this.suggestion.query).indexOf(this.query);\n\n const [beginning, matching, end] = this.splitAt(\n this.suggestion.query,\n matcherIndex,\n this.query.length\n );\n\n const attrsMatching = 'data-test=\"matching-part\" class=\"x-suggestion__matching-part\"';\n return `${beginning}<span ${attrsMatching}>${matching}</span>${end}`;\n }\n\n return sanitize(this.suggestion.query);\n }\n\n /**\n * Splits the label in three parts based on two indexes.\n *\n * @param label - The string that will be divided in three parts.\n * @param start - The first index that the label will be divided by.\n * @param skip - The second index that the label will be divided by.\n *\n * @returns The three parts of the divided label.\n * @internal\n */\n protected splitAt(label: string, start: number, skip: number): [string, string, string] {\n const startPart = label.substr(0, start);\n const matchingPart = label.substr(start, skip);\n const endPart = label.substr(start + skip);\n\n return [sanitize(startPart), sanitize(matchingPart), sanitize(endPart)];\n }\n }\n</script>\n\n<docs lang=\"mdx\">\n## Examples\n\nThis default suggestion component expects a suggestion to render and pass to its default slot, a\nnormalized query to compare with the suggestion's query and highlight its matching parts and events\nto emit when the suggestion is selected.\n\n### Default usage\n\n```vue\n<BaseSuggestion v-bind=\"{ query, suggestion, suggestionSelectedEvents }\" />\n```\n\n### Customized usage\n\n```vue\n<BaseSuggestion v-bind=\"{ query, suggestion, suggestionSelectedEvents }\">\n <template #default=\"{ suggestion, queryHTML }\">\n <span\n class=\"my-suggestion\"\n v-html=\"queryHTML\"\n :aria-label=\"suggestion.query\"\n />\n </template>\n</BaseSuggestion>\n```\n\n## Events\n\nA list of events that the component will emit:\n\n- `UserAcceptedAQuery`: the event is emitted after the user clicks the button. The event payload is\n the suggestion query data.\n- `UserSelectedASuggestion`: the event is emitted after the user clicks the button. The event\n payload is the suggestion data.\n- The component can emit more events on click using the `suggestionSelectedEvents` prop.\n</docs>\n"],"names":["const"],"mappings":";;;;AAEAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -6,7 +6,7 @@ import script from './base-suggestions.vue_rollup-plugin-vue=script.js';
|
|
|
6
6
|
var __vue_script__ = script;
|
|
7
7
|
|
|
8
8
|
/* template */
|
|
9
|
-
var __vue_render__ = function() {
|
|
9
|
+
var __vue_render__ = function () {
|
|
10
10
|
var _vm = this;
|
|
11
11
|
var _h = _vm.$createElement;
|
|
12
12
|
var _c = _vm._self._c || _h;
|
|
@@ -16,22 +16,21 @@ var __vue_render__ = function() {
|
|
|
16
16
|
{
|
|
17
17
|
tag: "component",
|
|
18
18
|
staticClass: "x-list x-suggestions",
|
|
19
|
-
attrs: { tag: "ul" }
|
|
19
|
+
attrs: { tag: "ul" },
|
|
20
20
|
},
|
|
21
|
-
_vm._l(_vm.suggestionsToRender, function(suggestion, index) {
|
|
21
|
+
_vm._l(_vm.suggestionsToRender, function (suggestion, index) {
|
|
22
22
|
return _c(
|
|
23
23
|
"li",
|
|
24
24
|
{
|
|
25
25
|
key: _vm.suggestionsKeys[index],
|
|
26
26
|
staticClass: "x-suggestions__item",
|
|
27
|
-
attrs: { "data-test": "suggestion-item" }
|
|
27
|
+
attrs: { "data-test": "suggestion-item" },
|
|
28
28
|
},
|
|
29
29
|
[
|
|
30
30
|
_vm._t("default", null, null, {
|
|
31
31
|
suggestion: suggestion,
|
|
32
|
-
index: index
|
|
33
|
-
})
|
|
34
|
-
],
|
|
32
|
+
index: index,
|
|
33
|
+
}) ],
|
|
35
34
|
2
|
|
36
35
|
)
|
|
37
36
|
}),
|
|
@@ -45,11 +44,11 @@ __vue_render__._withStripped = true;
|
|
|
45
44
|
/* style */
|
|
46
45
|
var __vue_inject_styles__ = function (inject) {
|
|
47
46
|
if (!inject) { return }
|
|
48
|
-
inject("data-v-
|
|
47
|
+
inject("data-v-162f615e_0", { source: ".x-suggestions[data-v-162f615e] {\n list-style-type: none;\n}", map: undefined, media: undefined });
|
|
49
48
|
|
|
50
49
|
};
|
|
51
50
|
/* scoped */
|
|
52
|
-
var __vue_scope_id__ = "data-v-
|
|
51
|
+
var __vue_scope_id__ = "data-v-162f615e";
|
|
53
52
|
/* module identifier */
|
|
54
53
|
var __vue_module_identifier__ = undefined;
|
|
55
54
|
/* functional template */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"base-suggestions.vue.js","sources":["../../../../src/components/suggestions/base-suggestions.vue"],"sourcesContent":["<template>\n <component :is=\"animation\" v-if=\"suggestions.length\" tag=\"ul\" class=\"x-list x-suggestions\">\n <li\n v-for=\"(suggestion, index) in suggestionsToRender\"\n :key=\"suggestionsKeys[index]\"\n class=\"x-suggestions__item\"\n data-test=\"suggestion-item\"\n >\n <!--\n @slot (Required) List item content\n @binding {Suggestion} suggestion - Suggestion data\n @binding {number} index - Suggestion index\n -->\n <slot v-bind=\"{ suggestion, index }\" />\n </li>\n </component>\n</template>\n\n<style lang=\"scss\" scoped>\n .x-suggestions {\n list-style-type: none;\n }\n</style>\n\n<script lang=\"ts\">\n import { Component, Prop } from 'vue-property-decorator';\n import { Suggestion, Facet } from '@empathyco/x-types';\n import Vue from 'vue';\n import { isArrayEmpty } from '../../utils/array';\n\n /**\n * Paints a list of suggestions passed in by prop. Requires a component for a single suggestion\n * in the default slot for working.\n *\n * @public\n */\n @Component\n export default class BaseSuggestions extends Vue {\n /**\n * The list of suggestions to render.\n *\n * @public\n */\n @Prop({ required: true })\n protected suggestions!: Suggestion[];\n\n /**\n * Animation component that will be used to animate the suggestion.\n *\n * @public\n */\n @Prop({ default: 'ul' })\n protected animation!: Vue | string;\n\n /**\n * Number of suggestions to be rendered.\n *\n * @public\n */\n @Prop()\n protected maxItemsToRender?: number;\n\n /**\n * An array with the unique keys for each suggestion. Required by the `v-for` loop.\n *\n * @returns An array with the unique keys of the suggestions.\n * @internal\n */\n protected get suggestionsKeys(): string[] {\n return this.suggestions.map(suggestion =>\n isArrayEmpty(suggestion.facets)\n ? suggestion.query\n : `${suggestion.query}-in-${this.getFacetsKey(suggestion.facets)}`\n );\n }\n\n /**\n * Generates a string from the given facets.\n *\n * @param facets - The list of facets to reduce to a string.\n * @returns - A string representing the list of facets.\n * @internal\n */\n protected getFacetsKey(facets: Facet[]): string {\n // Component methods are bound by Vue:\n // eslint-disable-next-line @typescript-eslint/unbound-method\n return facets.map(this.getFacetKey).join('&');\n }\n\n /**\n * Generates a string from the given facet.\n *\n * @param facet - The facet to reduce to a string.\n * @returns - A string representing the facet.\n * @internal\n */\n protected getFacetKey(facet: Facet): string {\n return facet.filters.map(filter => filter.id).join('&');\n }\n\n /**\n * Slices the suggestions from the state.\n *\n * @returns - The list of suggestions slice by the number of items to render.\n *\n * @internal\n */\n protected get suggestionsToRender(): Suggestion[] {\n return this.suggestions.slice(0, this.maxItemsToRender);\n }\n }\n</script>\n\n<docs lang=\"mdx\">\n
|
|
1
|
+
{"version":3,"file":"base-suggestions.vue.js","sources":["../../../../src/components/suggestions/base-suggestions.vue"],"sourcesContent":["<template>\n <component :is=\"animation\" v-if=\"suggestions.length\" tag=\"ul\" class=\"x-list x-suggestions\">\n <li\n v-for=\"(suggestion, index) in suggestionsToRender\"\n :key=\"suggestionsKeys[index]\"\n class=\"x-suggestions__item\"\n data-test=\"suggestion-item\"\n >\n <!--\n @slot (Required) List item content\n @binding {Suggestion} suggestion - Suggestion data\n @binding {number} index - Suggestion index\n -->\n <slot v-bind=\"{ suggestion, index }\" />\n </li>\n </component>\n</template>\n\n<style lang=\"scss\" scoped>\n .x-suggestions {\n list-style-type: none;\n }\n</style>\n\n<script lang=\"ts\">\n import { Component, Prop } from 'vue-property-decorator';\n import { Suggestion, Facet } from '@empathyco/x-types';\n import Vue from 'vue';\n import { isArrayEmpty } from '../../utils/array';\n\n /**\n * Paints a list of suggestions passed in by prop. Requires a component for a single suggestion\n * in the default slot for working.\n *\n * @public\n */\n @Component\n export default class BaseSuggestions extends Vue {\n /**\n * The list of suggestions to render.\n *\n * @public\n */\n @Prop({ required: true })\n protected suggestions!: Suggestion[];\n\n /**\n * Animation component that will be used to animate the suggestion.\n *\n * @public\n */\n @Prop({ default: 'ul' })\n protected animation!: Vue | string;\n\n /**\n * Number of suggestions to be rendered.\n *\n * @public\n */\n @Prop()\n protected maxItemsToRender?: number;\n\n /**\n * An array with the unique keys for each suggestion. Required by the `v-for` loop.\n *\n * @returns An array with the unique keys of the suggestions.\n * @internal\n */\n protected get suggestionsKeys(): string[] {\n return this.suggestions.map(suggestion =>\n isArrayEmpty(suggestion.facets)\n ? suggestion.query\n : `${suggestion.query}-in-${this.getFacetsKey(suggestion.facets)}`\n );\n }\n\n /**\n * Generates a string from the given facets.\n *\n * @param facets - The list of facets to reduce to a string.\n * @returns - A string representing the list of facets.\n * @internal\n */\n protected getFacetsKey(facets: Facet[]): string {\n // Component methods are bound by Vue:\n // eslint-disable-next-line @typescript-eslint/unbound-method\n return facets.map(this.getFacetKey).join('&');\n }\n\n /**\n * Generates a string from the given facet.\n *\n * @param facet - The facet to reduce to a string.\n * @returns - A string representing the facet.\n * @internal\n */\n protected getFacetKey(facet: Facet): string {\n return facet.filters.map(filter => filter.id).join('&');\n }\n\n /**\n * Slices the suggestions from the state.\n *\n * @returns - The list of suggestions slice by the number of items to render.\n *\n * @internal\n */\n protected get suggestionsToRender(): Suggestion[] {\n return this.suggestions.slice(0, this.maxItemsToRender);\n }\n }\n</script>\n\n<docs lang=\"mdx\">\n## Examples\n\nFor this component to work, you will need to set a list of suggestions as prop, and also to\nimplement the component for single suggestion, which handles the click event. In the following\nexample, the suggestions are retrieved from a property called `suggestions`, and the implementation\nof the suggestion component is a simple `button`, that calls the `emitSuggestionSelected` method\nwhen clicked.\n\n```vue\n<BaseSuggestions :suggestions=\"suggestions\">\n <template #default=\"{ suggestion }\">\n <button @click=\"emitSuggestionSelected($event, suggestion)\">\n {{ suggestion.query }}\n </button>\n </template>\n</BaseSuggestions>\n```\n\nFollowing the previous example, the component options object could be something like this:\n\n```js\nexport default {\n computed: {\n ...mapGetters(['x', 'querySuggestions'], { suggestions: 'suggestions' })\n },\n methods: {\n emitSuggestionSelected(event, suggestion) {\n this.$x.emit('UserAcceptedAQuery', suggestion.query, { target: event.target });\n this.$x.emit('UserSelectedAQuerySuggestion', suggestion, { target: event.target });\n }\n }\n};\n```\n\n### Play with props\n\nIn this example, the suggestions has been limited to render a maximum of 3 items.\n\n_Type “puzzle” or another toy in the input field to try it out!_\n\n```vue\n<template>\n <BaseSuggestions :suggestions=\"suggestions\" :maxItemToRender=\"3\" />\n</template>\n\n<script>\n import { BaseSuggestions } from '@empathyco/x-components';\n\n export default {\n name: 'BaseSuggestionsDemo',\n components: {\n BaseSuggestions\n },\n data() {\n return {\n suggestions: [\n {\n facets: [],\n key: 'chips',\n query: 'Chips',\n totalResults: 10,\n results: [],\n modelName: 'PopularSearch'\n }\n ]\n };\n }\n };\n</script>\n```\n</docs>\n"],"names":["const"],"mappings":";;;;;AAEAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|