@empathyco/x-components 3.0.0-alpha.32 → 3.0.0-alpha.36
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 +116 -0
- package/core/index.js +24 -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.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.isxcomponent.md +2 -2
- package/docs/API-reference/api/x-components.maybearray.md +13 -0
- package/docs/API-reference/api/x-components.md +12 -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.snippetconfig.isspa.md +13 -0
- package/docs/API-reference/api/x-components.snippetconfig.md +1 -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.xeventstypes.md +0 -1
- 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 +6 -7
- 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 +6 -7
- 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 +7 -8
- 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 +2 -2
- package/js/components/animations/animate-width.vue.js.map +1 -1
- package/js/components/animations/collapse-from-top.vue.js +2 -2
- package/js/components/animations/collapse-from-top.vue.js.map +1 -1
- package/js/components/animations/collapse-height.vue.js +2 -2
- package/js/components/animations/collapse-height.vue.js.map +1 -1
- package/js/components/animations/collapse-width.vue.js +2 -2
- package/js/components/animations/collapse-width.vue.js.map +1 -1
- package/js/components/animations/cross-fade.vue.js +2 -2
- package/js/components/animations/cross-fade.vue.js.map +1 -1
- package/js/components/animations/fade-and-slide.vue.js +2 -2
- package/js/components/animations/fade-and-slide.vue.js.map +1 -1
- package/js/components/animations/staggered-fade-and-slide.vue.js +2 -2
- 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 +2 -2
- package/js/components/animations/translate-from-left.vue.js.map +1 -1
- package/js/components/animations/translate-from-right.vue.js +2 -2
- package/js/components/animations/translate-from-right.vue.js.map +1 -1
- package/js/components/base-dropdown.vue.js +2 -2
- package/js/components/base-dropdown.vue.js.map +1 -1
- package/js/components/base-event-button.vue.js.map +1 -1
- package/js/components/base-grid.vue.js +2 -2
- package/js/components/base-grid.vue.js.map +1 -1
- package/js/components/base-keyboard-navigation.vue.js.map +1 -1
- package/js/components/base-rating.vue.js +2 -2
- package/js/components/base-rating.vue.js.map +1 -1
- package/js/components/base-variable-column-grid.vue.js.map +1 -1
- 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 +2 -2
- package/js/components/column-picker/base-column-picker-list.vue.js.map +1 -1
- 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.map +1 -1
- package/js/components/global-x-bus.vue.js.map +1 -1
- package/js/components/global-x-bus.vue_rollup-plugin-vue=script.js +2 -1
- package/js/components/global-x-bus.vue_rollup-plugin-vue=script.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/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 +3 -3
- 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 +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.map +1 -1
- package/js/components/modals/base-events-modal-open.vue.js.map +1 -1
- package/js/components/modals/base-events-modal.vue.js.map +1 -1
- package/js/components/modals/base-id-modal-close.vue.js.map +1 -1
- package/js/components/modals/base-id-modal-open.vue.js.map +1 -1
- package/js/components/modals/base-id-modal.vue.js.map +1 -1
- package/js/components/modals/base-modal.vue.js +2 -2
- package/js/components/modals/base-modal.vue.js.map +1 -1
- package/js/components/panels/base-header-toggle-panel.vue.js +2 -2
- package/js/components/panels/base-header-toggle-panel.vue.js.map +1 -1
- package/js/components/panels/base-id-toggle-panel-button.vue.js.map +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.map +1 -1
- package/js/components/result/base-result-add-to-cart.vue.js.map +1 -1
- package/js/components/result/base-result-current-price.vue.js.map +1 -1
- package/js/components/result/base-result-image.vue.js +2 -2
- package/js/components/result/base-result-image.vue.js.map +1 -1
- package/js/components/result/base-result-link.vue.js +5 -5
- 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-previous-price.vue.js.map +1 -1
- package/js/components/scroll/base-scroll.vue.js +2 -2
- package/js/components/scroll/base-scroll.vue.js.map +1 -1
- package/js/components/sliding-panel.vue.js +2 -2
- package/js/components/sliding-panel.vue.js.map +1 -1
- package/js/components/suggestions/base-suggestion.vue.js.map +1 -1
- package/js/components/suggestions/base-suggestions.vue.js +2 -2
- 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 +32 -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/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/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 +14 -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.map +1 -1
- package/js/x-modules/extra-params/components/renderless-extra-param.vue_rollup-plugin-vue=script.js +14 -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.map +1 -1
- package/js/x-modules/extra-params/components/snippet-config-extra-params.vue_rollup-plugin-vue=script.js +23 -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.map +1 -1
- package/js/x-modules/facets/components/clear-filters.vue_rollup-plugin-vue=script.js +14 -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 +18 -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 +2 -2
- package/js/x-modules/facets/components/facets/facets.vue.js.map +1 -1
- 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 +14 -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.map +1 -1
- package/js/x-modules/facets/components/filters/base-filter.vue_rollup-plugin-vue=script.js +14 -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 +1 -1
- 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.map +1 -1
- package/js/x-modules/facets/components/filters/hierarchical-filter.vue_rollup-plugin-vue=script.js +14 -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.map +1 -1
- package/js/x-modules/facets/components/filters/number-range-filter.vue_rollup-plugin-vue=script.js +14 -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 +14 -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.map +1 -1
- package/js/x-modules/facets/components/filters/simple-filter.vue_rollup-plugin-vue=script.js +14 -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 +14 -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 +2 -2
- 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 +14 -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 +2 -2
- 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 +14 -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.map +1 -1
- 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 +14 -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.map +1 -1
- package/js/x-modules/facets/components/lists/sliced-filters.vue_rollup-plugin-vue=script.js +14 -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 +14 -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.map +1 -1
- 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.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.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.map +1 -1
- 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_rollup-plugin-vue=script.js +1 -1
- 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.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.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.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_rollup-plugin-vue=script.js +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 +2 -2
- package/js/x-modules/recommendations/components/recommendations.vue.js.map +1 -1
- package/js/x-modules/related-tags/components/related-tag.vue.js +7 -3
- 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 +15 -4
- 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_rollup-plugin-vue=script.js +16 -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.map +1 -1
- package/js/x-modules/scroll/components/scroll-to-top.vue_rollup-plugin-vue=script.js +16 -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.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 +16 -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 +2 -1
- 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_rollup-plugin-vue=script.js +1 -1
- 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 +2 -2
- package/js/x-modules/search/components/partial-results-list.vue.js.map +1 -1
- package/js/x-modules/search/components/promoted.vue.js +2 -1
- 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_rollup-plugin-vue=script.js +1 -1
- 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_rollup-plugin-vue=script.js +2 -2
- package/js/x-modules/search/components/sort-dropdown.vue.js.map +1 -1
- package/js/x-modules/search/components/sort-list.vue.js +2 -2
- 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 +14 -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 +14 -12
- package/js/x-modules/search/components/sort.mixin.js.map +1 -1
- package/js/x-modules/search/components/spellcheck-button.vue.js.map +1 -1
- 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 +14 -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 +4 -1
- 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/search-input.vue.js +2 -2
- 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/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 +48 -4
- package/js/x-modules/tagging/wiring.js.map +1 -1
- package/js/x-modules/url/components/url-handler.vue.js +1 -1
- 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 +9 -10
- package/report/tsdoc-metadata.json +1 -1
- package/report/x-adapter.api.json +27 -1
- package/report/x-components.api.json +674 -223
- package/report/x-components.api.md +86 -35
- package/report/x-types.api.json +27 -1
- package/tagging/index.js +1 -1
- 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.map +1 -1
- 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 +1 -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/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/types.d.ts +6 -0
- package/types/utils/types.d.ts.map +1 -1
- package/types/wiring/events.types.d.ts +0 -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 +2 -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/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,6 +1,7 @@
|
|
|
1
1
|
import { __extends, __assign, __decorate } from 'tslib';
|
|
2
2
|
import Vue from 'vue';
|
|
3
|
-
import { Component } from 'vue-property-decorator';
|
|
3
|
+
import { Inject, Component } from 'vue-property-decorator';
|
|
4
|
+
import { isArrayEmpty } from '../../../utils/array.js';
|
|
4
5
|
import { objectFilter } from '../../../utils/object.js';
|
|
5
6
|
import { XOn } from '../../../components/decorators/bus.decorators.js';
|
|
6
7
|
import { xComponentMixin } from '../../../components/x-component.mixin.js';
|
|
@@ -25,6 +26,12 @@ var UrlHandler = /** @class */ (function (_super) {
|
|
|
25
26
|
* @internal
|
|
26
27
|
*/
|
|
27
28
|
_this.urlLoaded = false;
|
|
29
|
+
/**
|
|
30
|
+
* Flag to know if the page has been persisted by the browser's back-forward cache.
|
|
31
|
+
*
|
|
32
|
+
* @internal
|
|
33
|
+
*/
|
|
34
|
+
_this.isPagePersisted = false;
|
|
28
35
|
return _this;
|
|
29
36
|
}
|
|
30
37
|
Object.defineProperty(UrlHandler.prototype, "managedParamsNames", {
|
|
@@ -80,23 +87,108 @@ var UrlHandler = /** @class */ (function (_super) {
|
|
|
80
87
|
UrlHandler.prototype.updateUrlWithReplace = function (newUrlParams) {
|
|
81
88
|
this.updateUrl(newUrlParams, window.history.replaceState.bind(window.history));
|
|
82
89
|
};
|
|
90
|
+
/**
|
|
91
|
+
* Handler of the
|
|
92
|
+
* {@link https://developer.mozilla.org/en-US/docs/Web/API/Window/pageshow_event | pageshow }
|
|
93
|
+
* event.
|
|
94
|
+
*
|
|
95
|
+
* @remarks The pageshow event is listened to check if the browser has performed a navigation
|
|
96
|
+
* using the back-forward cache. This information is available in the
|
|
97
|
+
* PageTransitionEvent.persisted property.
|
|
98
|
+
*
|
|
99
|
+
* @param event - The page transition event.
|
|
100
|
+
* @internal
|
|
101
|
+
*/
|
|
102
|
+
UrlHandler.prototype.onPageShow = function (event) {
|
|
103
|
+
this.isPagePersisted = event.persisted;
|
|
104
|
+
if (event.persisted) {
|
|
105
|
+
// The internal url is reset due to the back-forward cache storing the previous value which
|
|
106
|
+
// is no longer valid.
|
|
107
|
+
this.url = undefined;
|
|
108
|
+
}
|
|
109
|
+
};
|
|
83
110
|
/**
|
|
84
111
|
* Emits the {@link UrlXEvents.ParamsLoadedFromUrl} XEvent,
|
|
85
112
|
* the {@link UrlXEvents.ExtraParamsLoadedFromUrl} XEvent and, if there is query, also emits
|
|
86
|
-
* the
|
|
113
|
+
* the {@link XEventsTypes.UserOpenXProgrammatically}.
|
|
87
114
|
*
|
|
88
115
|
* @internal
|
|
89
116
|
*/
|
|
90
117
|
UrlHandler.prototype.emitEvents = function () {
|
|
91
118
|
var _a = this.parseUrlParams(), all = _a.all, extra = _a.extra;
|
|
92
|
-
this
|
|
93
|
-
this.$x.emit('
|
|
119
|
+
var metadata = this.createWireMetadata();
|
|
120
|
+
this.$x.emit('ParamsLoadedFromUrl', all, metadata);
|
|
121
|
+
this.$x.emit('ExtraParamsLoadedFromUrl', extra, metadata);
|
|
94
122
|
// TODO: Move this logic from here.
|
|
95
123
|
if (all.query) {
|
|
96
|
-
this.$x.emit('UserOpenXProgrammatically');
|
|
124
|
+
this.$x.emit('UserOpenXProgrammatically', undefined, metadata);
|
|
97
125
|
}
|
|
98
126
|
this.urlLoaded = true;
|
|
99
127
|
};
|
|
128
|
+
/**
|
|
129
|
+
* Creates the wire metadata to include in every emitted {@link XEvent | XEvents}.
|
|
130
|
+
*
|
|
131
|
+
* @returns The {@link WireMetadata | metadata}.
|
|
132
|
+
* @internal
|
|
133
|
+
*/
|
|
134
|
+
UrlHandler.prototype.createWireMetadata = function () {
|
|
135
|
+
return {
|
|
136
|
+
feature: 'url',
|
|
137
|
+
location: this.detectLocation()
|
|
138
|
+
};
|
|
139
|
+
};
|
|
140
|
+
/**
|
|
141
|
+
* Detects the {@link FeatureLocation | location} used to build the
|
|
142
|
+
* {@link QueryOriginInit | events metadata origin}.
|
|
143
|
+
*
|
|
144
|
+
* @returns The {@link FeatureLocation | location}.
|
|
145
|
+
* @internal
|
|
146
|
+
*/
|
|
147
|
+
UrlHandler.prototype.detectLocation = function () {
|
|
148
|
+
var currentUrl = new URL(window.location.href);
|
|
149
|
+
var previousUrl = this.url;
|
|
150
|
+
this.url = currentUrl;
|
|
151
|
+
var isInternalNavigation = (previousUrl === null || previousUrl === void 0 ? void 0 : previousUrl.search) !== currentUrl.search && (previousUrl === null || previousUrl === void 0 ? void 0 : previousUrl.pathname) === currentUrl.pathname;
|
|
152
|
+
if (isInternalNavigation) {
|
|
153
|
+
return 'url_history';
|
|
154
|
+
}
|
|
155
|
+
if (this.isNavigatingFromPdp()) {
|
|
156
|
+
return 'url_history_pdp';
|
|
157
|
+
}
|
|
158
|
+
return 'external';
|
|
159
|
+
};
|
|
160
|
+
/**
|
|
161
|
+
* Check if the navigation is from a product page.
|
|
162
|
+
*
|
|
163
|
+
* @remarks Due to Safari 14 not supporting the new and standard PerformanceNavigationTiming
|
|
164
|
+
* API, we are falling back to the deprecated one, PerformanceNavigation. We also fallback to
|
|
165
|
+
* this API whenever we get a navigationType equal to reload, because Safari has a bug that the
|
|
166
|
+
* navigationType is permanently set to reload after you have reload the page and it never
|
|
167
|
+
* resets. As some browsers have a back-forward cache implemented, we also take into account if
|
|
168
|
+
* the page is persisted.
|
|
169
|
+
*
|
|
170
|
+
* @returns True if the navigation is from a product page, false otherwise.
|
|
171
|
+
* @internal
|
|
172
|
+
*/
|
|
173
|
+
UrlHandler.prototype.isNavigatingFromPdp = function () {
|
|
174
|
+
var _a, _b, _c;
|
|
175
|
+
var isPagePersisted = this.isPagePersisted;
|
|
176
|
+
var navigationEntries = window.performance.getEntriesByType('navigation');
|
|
177
|
+
var navigationType = (_a = navigationEntries[0]) === null || _a === void 0 ? void 0 : _a.type;
|
|
178
|
+
var useFallbackStrategy = window.performance.navigation &&
|
|
179
|
+
(isArrayEmpty(navigationEntries) || navigationType === 'reload');
|
|
180
|
+
// Reset internal isPagePersisted property value
|
|
181
|
+
this.isPagePersisted = false;
|
|
182
|
+
if (useFallbackStrategy) {
|
|
183
|
+
var _d = window.performance.navigation, fallbackNavigationType = _d.type, TYPE_BACK_FORWARD = _d.TYPE_BACK_FORWARD, TYPE_NAVIGATE = _d.TYPE_NAVIGATE;
|
|
184
|
+
var isNavigatingInSpa = !!((_b = this.snippetConfig) === null || _b === void 0 ? void 0 : _b.isSpa) && fallbackNavigationType === TYPE_NAVIGATE;
|
|
185
|
+
return fallbackNavigationType === TYPE_BACK_FORWARD || isNavigatingInSpa || isPagePersisted;
|
|
186
|
+
}
|
|
187
|
+
else {
|
|
188
|
+
var isNavigatingInSpa = !!((_c = this.snippetConfig) === null || _c === void 0 ? void 0 : _c.isSpa) && navigationType === 'navigate';
|
|
189
|
+
return navigationType === 'back_forward' || isNavigatingInSpa || isPagePersisted;
|
|
190
|
+
}
|
|
191
|
+
};
|
|
100
192
|
/**
|
|
101
193
|
* Gets the {@link UrlParams} from the URL, including only the params defined by `paramsNames`.
|
|
102
194
|
*
|
|
@@ -138,6 +230,7 @@ var UrlHandler = /** @class */ (function (_super) {
|
|
|
138
230
|
if (url.href.replace(/\+/g, '%20') !== window.location.href) {
|
|
139
231
|
historyMethod(__assign({}, window.history.state), document.title, url.href);
|
|
140
232
|
}
|
|
233
|
+
this.url = url;
|
|
141
234
|
}
|
|
142
235
|
};
|
|
143
236
|
/**
|
|
@@ -222,6 +315,9 @@ var UrlHandler = /** @class */ (function (_super) {
|
|
|
222
315
|
return value;
|
|
223
316
|
}
|
|
224
317
|
};
|
|
318
|
+
__decorate([
|
|
319
|
+
Inject({ default: undefined })
|
|
320
|
+
], UrlHandler.prototype, "snippetConfig", void 0);
|
|
225
321
|
__decorate([
|
|
226
322
|
XOn('PushableUrlStateChanged')
|
|
227
323
|
], UrlHandler.prototype, "updateUrlWithPush", null);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"url-handler.vue_rollup-plugin-vue=script.js","sources":["../../../../../src/x-modules/url/components/url-handler.vue?rollup-plugin-vue=script.ts"],"sourcesContent":["\n\n\n\n\nimport Vue from 'vue';\nimport GlobalEvents from 'vue-global-events';\nimport { Component } from 'vue-property-decorator';\nimport { XOn } from '../../../components/decorators/bus.decorators';\nimport { xComponentMixin } from '../../../components/x-component.mixin';\nimport { UrlParams } from '../../../types/url-params';\nimport { objectFilter } from '../../../utils/object';\nimport { Dictionary } from '../../../utils/types';\nimport { initialUrlState } from '../store/initial-state';\nimport { UrlParamValue } from '../store/types';\nimport { urlXModule } from '../x-module';\n\ninterface ParsedUrlParams {\n all: UrlParams;\n extra: Dictionary<unknown>;\n}\n\n/**\n * This component manage the browser URL parameters to perserve them through reloads and browser\n * history navigation. It allow to configure the default url parameter names using its attributes.\n * This component doesn't render elements to the DOM.\n *\n * @public\n */\n@Component({\n components: {\n GlobalEvents\n },\n mixins: [xComponentMixin(urlXModule)]\n})\nexport default class UrlHandler extends Vue {\n /**\n * Computed to know which params we must get from URL. It gets the params names from the initial\n * state, to get all default params names, and also from the `$attrs` to get the extra params\n * names to take into account.\n *\n * @returns An array with the name of the params.\n *\n * @internal\n */\n protected get managedParamsNames(): string[] {\n return Object.keys({ ...initialUrlState, ...this.$attrs });\n }\n\n /**\n * Returns the mapping of the param keys used in the URL is configured through $attrs. This way\n * we can support any param and extra param, no matters its name.\n *\n * @param paramName - The param name to get the Url key.\n * @returns The key used in the URL for the `paramName` passed.\n *\n * @internal\n */\n protected getUrlKey(paramName: string): string {\n return this.$attrs[paramName] ?? paramName;\n }\n\n /**\n * Flag to know if the params were already loaded from the URL.\n *\n * @internal\n */\n protected urlLoaded = false;\n\n /**\n * To emit the Url events just when the URL is load, and before the components mounted events\n * and state changes, we do it in the created of this component.\n */\n created(): void {\n this.emitEvents();\n }\n\n /**\n * Updates the browser URL with the new {@link UrlParams} using the history `pushState` method.\n *\n * @param newUrlParams - The new params to update browser URL.\n */\n @XOn('PushableUrlStateChanged')\n updateUrlWithPush(newUrlParams: UrlParams): void {\n this.updateUrl(newUrlParams, window.history.pushState.bind(window.history));\n }\n\n /**\n * Updates the browser URL with the new {@link UrlParams} using the history `replaceState`\n * method.\n *\n * @param newUrlParams - The new params to update browser URL.\n */\n @XOn('ReplaceableUrlStateChanged')\n updateUrlWithReplace(newUrlParams: UrlParams): void {\n this.updateUrl(newUrlParams, window.history.replaceState.bind(window.history));\n }\n\n /**\n * Emits the {@link UrlXEvents.ParamsLoadedFromUrl} XEvent,\n * the {@link UrlXEvents.ExtraParamsLoadedFromUrl} XEvent and, if there is query, also emits\n * the {@link XEventsTypes.UserOpenXProgrammatically}.\n *\n * @internal\n */\n protected emitEvents(): void {\n const { all, extra } = this.parseUrlParams();\n this.$x.emit('ParamsLoadedFromUrl', all, { feature: 'url' });\n this.$x.emit('ExtraParamsLoadedFromUrl', extra, { feature: 'url' });\n // TODO: Move this logic from here.\n if (all.query) {\n this.$x.emit('UserOpenXProgrammatically');\n }\n this.urlLoaded = true;\n }\n\n /**\n * Gets the {@link UrlParams} from the URL, including only the params defined by `paramsNames`.\n *\n * @returns ParsedUrlParams obtained from URL.\n * @internal\n */\n\n protected parseUrlParams(): ParsedUrlParams {\n const urlSearchParams = new URL(window.location.href).searchParams;\n return this.managedParamsNames.reduce<ParsedUrlParams>(\n (params, name) => {\n const urlKey = this.getUrlKey(name);\n if (urlSearchParams.has(urlKey)) {\n if (name in initialUrlState) {\n const urlValue = urlSearchParams.getAll(urlKey);\n params.all[name] = this.parseUrlParam(name, urlValue);\n } else {\n params.all[name] = params.extra[name] = urlSearchParams.get(urlKey);\n }\n }\n return params;\n },\n { all: { ...initialUrlState }, extra: {} }\n );\n }\n\n /**\n * Updates the browser URL with the passed `newUrlParams` and using the browser history method\n * passed as `historyMethod`. It only updates the browser history if the new URL is different\n * from the current.\n *\n * @param newUrlParams - The new params to add to the browser URL.\n * @param historyMethod - The browser history method used to add the new URL.\n *\n * @internal\n */\n protected updateUrl(\n newUrlParams: UrlParams,\n historyMethod: History['pushState'] | History['replaceState']\n ): void {\n if (this.urlLoaded) {\n const url = new URL(window.location.href);\n this.deleteUrlParameters(url);\n this.setUrlParameters(url, newUrlParams);\n if (url.href.replace(/\\+/g, '%20') !== window.location.href) {\n historyMethod({ ...window.history.state }, document.title, url.href);\n }\n }\n }\n\n /**\n * Deletes all the parameters in the passed URL.\n *\n * @param url - The URL to remove parameters from.\n * @internal\n * **/\n protected deleteUrlParameters(url: URL): void {\n this.managedParamsNames.forEach(paramName =>\n url.searchParams.delete(this.getUrlKey(paramName))\n );\n }\n\n /**\n * Set all the provided parameters to the url with the mapped key.\n *\n * @param url - The current URL.\n * @param urlParams - The list of parameters to add.\n * @remarks The params are filtered because there maybe received extra params which will not be\n * managed by URL. This is defined by the `managedParamsNames` computed. Also, the parameters\n * are sorted Alphabetically to produce always the same URL with the same parameters.This is\n * important for SEO purposes.\n *\n * @internal\n * **/\n protected setUrlParameters(url: URL, urlParams: UrlParams): void {\n const filteredParams = objectFilter(urlParams, paramName =>\n this.managedParamsNames.includes(paramName as string)\n );\n const sortedParameters = this.sortParams(filteredParams);\n sortedParameters.forEach(([paramName, paramValue]) => {\n const urlParamKey = this.getUrlKey(paramName);\n if (Array.isArray(paramValue)) {\n paramValue.forEach(value => {\n url.searchParams.append(urlParamKey, String(value));\n });\n } else {\n url.searchParams.set(urlParamKey, String(paramValue));\n }\n });\n }\n\n /**\n * Sorts the params in a tuple array [key,value] to generate always the same URL with the params\n * in the same order.\n *\n * @param urlParams - The {@link UrlParams} to sort.\n * @returns An array of tuples with the key-value of each paramter, sorted by key.\n * @internal\n */\n protected sortParams(urlParams: UrlParams): Array<[string, unknown]> {\n return Object.entries(urlParams).sort(([param1], [param2]) => {\n return param1 < param2 ? -1 : 1;\n });\n }\n\n /**\n * Returns the URL param value parsed depending on its type in the initial store state. As we\n * can not know what type can have an extra param, all extra params are parsed as strings. We\n * know if it is an extra param because it is not in the initial state.\n *\n * @param name - The name of the param in {@link UrlParams}.\n * @param value - The `URLSearchParams` value as an arry of strings.\n * @returns The parsed value.\n *\n * @internal\n */\n protected parseUrlParam(name: string, value: string[]): UrlParamValue {\n switch (typeof initialUrlState[name]) {\n case 'number':\n return Number(value[0]);\n case 'boolean':\n return value[0].toLowerCase() === 'true';\n case 'string':\n return value[0];\n default:\n // array\n return value;\n }\n }\n}\n"],"names":[],"mappings":";;;;;;;;;;AAsBA;;;;;;;AAaA;IAAwC,8BAAG;IAA3C;QAAA,qEAkNC;;;;;;QAlLW,eAAS,GAAG,KAAK,CAAC;;KAkL7B;IAxMC,sBAAc,0CAAkB;;;;;;;;;;aAAhC;YACE,OAAO,MAAM,CAAC,IAAI,uBAAM,eAAe,GAAK,IAAI,CAAC,MAAM,EAAG,CAAC;SAC5D;;;OAAA;;;;;;;;;;IAWS,8BAAS,GAAnB,UAAoB,SAAiB;;QACnC,OAAO,MAAA,IAAI,CAAC,MAAM,CAAC,SAAS,CAAC,mCAAI,SAAS,CAAC;KAC5C;;;;;IAaD,4BAAO,GAAP;QACE,IAAI,CAAC,UAAU,EAAE,CAAC;KACnB;;;;;;IAQD,sCAAiB,GAAjB,UAAkB,YAAuB;QACvC,IAAI,CAAC,SAAS,CAAC,YAAY,EAAE,MAAM,CAAC,OAAO,CAAC,SAAS,CAAC,IAAI,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC;KAC7E;;;;;;;IASD,yCAAoB,GAApB,UAAqB,YAAuB;QAC1C,IAAI,CAAC,SAAS,CAAC,YAAY,EAAE,MAAM,CAAC,OAAO,CAAC,YAAY,CAAC,IAAI,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC;KAChF;;;;;;;;IASS,+BAAU,GAApB;QACQ,IAAA,KAAiB,IAAI,CAAC,cAAc,EAAE,EAAp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A,CAlNuC,GAAG;;;;"}
|
|
1
|
+
{"version":3,"file":"url-handler.vue_rollup-plugin-vue=script.js","sources":["../../../../../src/x-modules/url/components/url-handler.vue?rollup-plugin-vue=script.ts"],"sourcesContent":["\n\n\n\n\nimport Vue from 'vue';\nimport GlobalEvents from 'vue-global-events';\nimport { Component, Inject } from 'vue-property-decorator';\nimport { XOn } from '../../../components/decorators/bus.decorators';\nimport { xComponentMixin } from '../../../components/x-component.mixin';\nimport { FeatureLocation } from '../../../types/origin';\nimport { UrlParams } from '../../../types/url-params';\nimport { isArrayEmpty } from '../../../utils/array';\nimport { objectFilter } from '../../../utils/object';\nimport { Dictionary } from '../../../utils/types';\nimport { WireMetadata } from '../../../wiring/wiring.types';\nimport { SnippetConfig } from '../../../x-installer/api/api.types';\nimport { initialUrlState } from '../store/initial-state';\nimport { UrlParamValue } from '../store/types';\nimport { urlXModule } from '../x-module';\n\ninterface ParsedUrlParams {\n all: UrlParams;\n extra: Dictionary<unknown>;\n}\n\n/**\n * This component manage the browser URL parameters to perserve them through reloads and browser\n * history navigation. It allow to configure the default url parameter names using its attributes.\n * This component doesn't render elements to the DOM.\n *\n * @public\n */\n@Component({\n components: {\n GlobalEvents\n },\n mixins: [xComponentMixin(urlXModule)]\n})\nexport default class UrlHandler extends Vue {\n /**\n * The {@link SnippetConfig} provided by an ancestor.\n *\n * @internal\n */\n @Inject({ default: undefined })\n protected snippetConfig?: SnippetConfig;\n\n /**\n * Flag to know if the params were already loaded from the URL.\n *\n * @internal\n */\n protected urlLoaded = false;\n\n /**\n * The page URL. It is used to compare against the current URL to check navigation state.\n *\n * @internal\n */\n protected url?: URL;\n\n /**\n * Flag to know if the page has been persisted by the browser's back-forward cache.\n *\n * @internal\n */\n protected isPagePersisted = false;\n\n /**\n * Computed to know which params we must get from URL. It gets the params names from the initial\n * state, to get all default params names, and also from the `$attrs` to get the extra params\n * names to take into account.\n *\n * @returns An array with the name of the params.\n *\n * @internal\n */\n protected get managedParamsNames(): string[] {\n return Object.keys({ ...initialUrlState, ...this.$attrs });\n }\n\n /**\n * Returns the mapping of the param keys used in the URL is configured through $attrs. This way\n * we can support any param and extra param, no matters its name.\n *\n * @param paramName - The param name to get the Url key.\n * @returns The key used in the URL for the `paramName` passed.\n *\n * @internal\n */\n protected getUrlKey(paramName: string): string {\n return this.$attrs[paramName] ?? paramName;\n }\n\n /**\n * To emit the Url events just when the URL is load, and before the components mounted events\n * and state changes, we do it in the created of this component.\n */\n created(): void {\n this.emitEvents();\n }\n\n /**\n * Updates the browser URL with the new {@link UrlParams} using the history `pushState` method.\n *\n * @param newUrlParams - The new params to update browser URL.\n */\n @XOn('PushableUrlStateChanged')\n updateUrlWithPush(newUrlParams: UrlParams): void {\n this.updateUrl(newUrlParams, window.history.pushState.bind(window.history));\n }\n\n /**\n * Updates the browser URL with the new {@link UrlParams} using the history `replaceState`\n * method.\n *\n * @param newUrlParams - The new params to update browser URL.\n */\n @XOn('ReplaceableUrlStateChanged')\n updateUrlWithReplace(newUrlParams: UrlParams): void {\n this.updateUrl(newUrlParams, window.history.replaceState.bind(window.history));\n }\n\n /**\n * Handler of the\n * {@link https://developer.mozilla.org/en-US/docs/Web/API/Window/pageshow_event | pageshow }\n * event.\n *\n * @remarks The pageshow event is listened to check if the browser has performed a navigation\n * using the back-forward cache. This information is available in the\n * PageTransitionEvent.persisted property.\n *\n * @param event - The page transition event.\n * @internal\n */\n protected onPageShow(event: PageTransitionEvent): void {\n this.isPagePersisted = event.persisted;\n if (event.persisted) {\n // The internal url is reset due to the back-forward cache storing the previous value which\n // is no longer valid.\n this.url = undefined;\n }\n }\n\n /**\n * Emits the {@link UrlXEvents.ParamsLoadedFromUrl} XEvent,\n * the {@link UrlXEvents.ExtraParamsLoadedFromUrl} XEvent and, if there is query, also emits\n * the {@link XEventsTypes.UserOpenXProgrammatically}.\n *\n * @internal\n */\n protected emitEvents(): void {\n const { all, extra } = this.parseUrlParams();\n const metadata = this.createWireMetadata();\n this.$x.emit('ParamsLoadedFromUrl', all, metadata);\n this.$x.emit('ExtraParamsLoadedFromUrl', extra, metadata);\n // TODO: Move this logic from here.\n if (all.query) {\n this.$x.emit('UserOpenXProgrammatically', undefined, metadata);\n }\n this.urlLoaded = true;\n }\n\n /**\n * Creates the wire metadata to include in every emitted {@link XEvent | XEvents}.\n *\n * @returns The {@link WireMetadata | metadata}.\n * @internal\n */\n protected createWireMetadata(): Pick<WireMetadata, 'feature' | 'location'> {\n return {\n feature: 'url',\n location: this.detectLocation()\n };\n }\n\n /**\n * Detects the {@link FeatureLocation | location} used to build the\n * {@link QueryOriginInit | events metadata origin}.\n *\n * @returns The {@link FeatureLocation | location}.\n * @internal\n */\n protected detectLocation(): FeatureLocation {\n const currentUrl = new URL(window.location.href);\n const previousUrl = this.url;\n this.url = currentUrl;\n\n const isInternalNavigation =\n previousUrl?.search !== currentUrl.search && previousUrl?.pathname === currentUrl.pathname;\n if (isInternalNavigation) {\n return 'url_history';\n }\n\n if (this.isNavigatingFromPdp()) {\n return 'url_history_pdp';\n }\n\n return 'external';\n }\n\n /**\n * Check if the navigation is from a product page.\n *\n * @remarks Due to Safari 14 not supporting the new and standard PerformanceNavigationTiming\n * API, we are falling back to the deprecated one, PerformanceNavigation. We also fallback to\n * this API whenever we get a navigationType equal to reload, because Safari has a bug that the\n * navigationType is permanently set to reload after you have reload the page and it never\n * resets. As some browsers have a back-forward cache implemented, we also take into account if\n * the page is persisted.\n *\n * @returns True if the navigation is from a product page, false otherwise.\n * @internal\n */\n protected isNavigatingFromPdp(): boolean {\n const isPagePersisted = this.isPagePersisted;\n const navigationEntries = window.performance.getEntriesByType('navigation');\n const navigationType = (navigationEntries[0] as PerformanceNavigationTiming)?.type;\n const useFallbackStrategy =\n window.performance.navigation &&\n (isArrayEmpty(navigationEntries) || navigationType === 'reload');\n\n // Reset internal isPagePersisted property value\n this.isPagePersisted = false;\n\n if (useFallbackStrategy) {\n const {\n type: fallbackNavigationType,\n TYPE_BACK_FORWARD,\n TYPE_NAVIGATE\n } = window.performance.navigation;\n const isNavigatingInSpa =\n !!this.snippetConfig?.isSpa && fallbackNavigationType === TYPE_NAVIGATE;\n return fallbackNavigationType === TYPE_BACK_FORWARD || isNavigatingInSpa || isPagePersisted;\n } else {\n const isNavigatingInSpa = !!this.snippetConfig?.isSpa && navigationType === 'navigate';\n return navigationType === 'back_forward' || isNavigatingInSpa || isPagePersisted;\n }\n }\n\n /**\n * Gets the {@link UrlParams} from the URL, including only the params defined by `paramsNames`.\n *\n * @returns ParsedUrlParams obtained from URL.\n * @internal\n */\n protected parseUrlParams(): ParsedUrlParams {\n const urlSearchParams = new URL(window.location.href).searchParams;\n return this.managedParamsNames.reduce<ParsedUrlParams>(\n (params, name) => {\n const urlKey = this.getUrlKey(name);\n if (urlSearchParams.has(urlKey)) {\n if (name in initialUrlState) {\n const urlValue = urlSearchParams.getAll(urlKey);\n params.all[name] = this.parseUrlParam(name, urlValue);\n } else {\n params.all[name] = params.extra[name] = urlSearchParams.get(urlKey);\n }\n }\n return params;\n },\n { all: { ...initialUrlState }, extra: {} }\n );\n }\n\n /**\n * Updates the browser URL with the passed `newUrlParams` and using the browser history method\n * passed as `historyMethod`. It only updates the browser history if the new URL is different\n * from the current.\n *\n * @param newUrlParams - The new params to add to the browser URL.\n * @param historyMethod - The browser history method used to add the new URL.\n *\n * @internal\n */\n protected updateUrl(\n newUrlParams: UrlParams,\n historyMethod: History['pushState'] | History['replaceState']\n ): void {\n if (this.urlLoaded) {\n const url = new URL(window.location.href);\n this.deleteUrlParameters(url);\n this.setUrlParameters(url, newUrlParams);\n if (url.href.replace(/\\+/g, '%20') !== window.location.href) {\n historyMethod({ ...window.history.state }, document.title, url.href);\n }\n this.url = url;\n }\n }\n\n /**\n * Deletes all the parameters in the passed URL.\n *\n * @param url - The URL to remove parameters from.\n * @internal\n * **/\n protected deleteUrlParameters(url: URL): void {\n this.managedParamsNames.forEach(paramName =>\n url.searchParams.delete(this.getUrlKey(paramName))\n );\n }\n\n /**\n * Set all the provided parameters to the url with the mapped key.\n *\n * @param url - The current URL.\n * @param urlParams - The list of parameters to add.\n * @remarks The params are filtered because there maybe received extra params which will not be\n * managed by URL. This is defined by the `managedParamsNames` computed. Also, the parameters\n * are sorted Alphabetically to produce always the same URL with the same parameters.This is\n * important for SEO purposes.\n *\n * @internal\n * **/\n protected setUrlParameters(url: URL, urlParams: UrlParams): void {\n const filteredParams = objectFilter(urlParams, paramName =>\n this.managedParamsNames.includes(paramName as string)\n );\n const sortedParameters = this.sortParams(filteredParams);\n sortedParameters.forEach(([paramName, paramValue]) => {\n const urlParamKey = this.getUrlKey(paramName);\n if (Array.isArray(paramValue)) {\n paramValue.forEach(value => {\n url.searchParams.append(urlParamKey, String(value));\n });\n } else {\n url.searchParams.set(urlParamKey, String(paramValue));\n }\n });\n }\n\n /**\n * Sorts the params in a tuple array [key,value] to generate always the same URL with the params\n * in the same order.\n *\n * @param urlParams - The {@link UrlParams} to sort.\n * @returns An array of tuples with the key-value of each paramter, sorted by key.\n * @internal\n */\n protected sortParams(urlParams: UrlParams): Array<[string, unknown]> {\n return Object.entries(urlParams).sort(([param1], [param2]) => {\n return param1 < param2 ? -1 : 1;\n });\n }\n\n /**\n * Returns the URL param value parsed depending on its type in the initial store state. As we\n * can not know what type can have an extra param, all extra params are parsed as strings. We\n * know if it is an extra param because it is not in the initial state.\n *\n * @param name - The name of the param in {@link UrlParams}.\n * @param value - The `URLSearchParams` value as an arry of strings.\n * @returns The parsed value.\n *\n * @internal\n */\n protected parseUrlParam(name: string, value: string[]): UrlParamValue {\n switch (typeof initialUrlState[name]) {\n case 'number':\n return Number(value[0]);\n case 'boolean':\n return value[0].toLowerCase() === 'true';\n case 'string':\n return value[0];\n default:\n // array\n return value;\n }\n }\n}\n"],"names":[],"mappings":";;;;;;;;;;;AA0BA;;;;;;;AAaA;IAAwC,8BAAG;IAA3C;QAAA,qEA2UC;;;;;;QA7TW,eAAS,GAAG,KAAK,CAAC;;;;;;QAclB,qBAAe,GAAG,KA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ACS;IA+DxC;QADC,GAAG,CAAC,yBAAyB,CAAC;uDAG9B;IASD;QADC,GAAG,CAAC,4BAA4B,CAAC;0DAGjC;IAnFkB,UAAU;QAN9B,SAAS,CAAC;YACT,UAAU,EAAE;gBACV,YAAY,cAAA;aACb;YACD,MAAM,EAAE,CAAC,eAAe,CAAC,UAAU,CAAC,CAAC;SACtC,CAAC;OACmB,UAAU,CA2U9B;IAAD,iBAAC;CAAA,CA3UuC,GAAG;;;;"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@empathyco/x-components",
|
|
3
|
-
"version": "3.0.0-alpha.
|
|
3
|
+
"version": "3.0.0-alpha.36",
|
|
4
4
|
"description": "Empathy X Components",
|
|
5
5
|
"author": "Empathy Systems Corporation S.L.",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -53,23 +53,23 @@
|
|
|
53
53
|
"test:unit-watch": "jest --watch",
|
|
54
54
|
"test:e2e": "vue-cli-service test:e2e",
|
|
55
55
|
"test:e2e:ci": "vue-cli-service test:e2e --headless --browser chrome",
|
|
56
|
-
"test": "
|
|
56
|
+
"test": "npm run test:unit && npm run test:e2e:ci",
|
|
57
57
|
"cypress:open": "cypress open",
|
|
58
58
|
"cypress:open:component": "cypress open-ct",
|
|
59
59
|
"release": "standard-version --no-verify",
|
|
60
60
|
"release:alpha": "standard-version --no-verify --prerelease alpha"
|
|
61
61
|
},
|
|
62
62
|
"dependencies": {
|
|
63
|
-
"@empathyco/x-adapter": "^7.0.0-alpha.
|
|
63
|
+
"@empathyco/x-adapter": "^7.0.0-alpha.8",
|
|
64
64
|
"@empathyco/x-deep-merge": "^1.3.0-alpha.1",
|
|
65
65
|
"@empathyco/x-logger": "^1.2.0-alpha.1",
|
|
66
66
|
"@empathyco/x-storage-service": "^2.0.0-alpha.0",
|
|
67
|
-
"@empathyco/x-types": "^10.0.0-alpha.
|
|
67
|
+
"@empathyco/x-types": "^10.0.0-alpha.13",
|
|
68
68
|
"@types/resize-observer-browser": "~0.1.5",
|
|
69
69
|
"magic-string": "~0.25.7",
|
|
70
|
-
"nanoid": "
|
|
70
|
+
"nanoid": "~3.1.30",
|
|
71
71
|
"reflect-metadata": "~0.1.13",
|
|
72
|
-
"rxjs": "~
|
|
72
|
+
"rxjs": "~7.4.0",
|
|
73
73
|
"tslib": "~2.3.0",
|
|
74
74
|
"vue": "^2.6.0",
|
|
75
75
|
"vue-class-component": "~7.1.0",
|
|
@@ -99,7 +99,7 @@
|
|
|
99
99
|
"@vue/cli-plugin-vuex": "~4.5.11",
|
|
100
100
|
"@vue/cli-service": "~4.5.11",
|
|
101
101
|
"@vue/test-utils": "~1.0.3",
|
|
102
|
-
"@vue/vue2-jest": "
|
|
102
|
+
"@vue/vue2-jest": "~27.0.0-alpha.3",
|
|
103
103
|
"autoprefixer": "~9.7.4",
|
|
104
104
|
"cypress": "~8.4.0",
|
|
105
105
|
"cypress-cucumber-preprocessor": "~4.0.0",
|
|
@@ -112,7 +112,6 @@
|
|
|
112
112
|
"rollup": "~1.31.0",
|
|
113
113
|
"rollup-plugin-copy": "~3.4.0",
|
|
114
114
|
"rollup-plugin-delete": "~1.2.0",
|
|
115
|
-
"rollup-plugin-postcss": "~2.0.6",
|
|
116
115
|
"rollup-plugin-rename": "~1.0.1",
|
|
117
116
|
"rollup-plugin-scss": "~2.1.0",
|
|
118
117
|
"rollup-plugin-sourcemaps": "~0.5.0",
|
|
@@ -126,11 +125,11 @@
|
|
|
126
125
|
"typescript": "~4.3.5",
|
|
127
126
|
"vue-docgen-cli": "~4.13.1",
|
|
128
127
|
"vue-router": "~3.4.3",
|
|
129
|
-
"vue-template-compiler": "^2.6.
|
|
128
|
+
"vue-template-compiler": "^2.6.0"
|
|
130
129
|
},
|
|
131
130
|
"publishConfig": {
|
|
132
131
|
"access": "public",
|
|
133
132
|
"directory": "dist"
|
|
134
133
|
},
|
|
135
|
-
"gitHead": "
|
|
134
|
+
"gitHead": "1dbbb5f00d47cd57405010ef454a3e347d5a9c2b"
|
|
136
135
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"metadata": {
|
|
3
3
|
"toolPackage": "@microsoft/api-extractor",
|
|
4
|
-
"toolVersion": "7.18.
|
|
4
|
+
"toolVersion": "7.18.21",
|
|
5
5
|
"schemaVersion": 1004,
|
|
6
6
|
"oldestForwardsCompatibleVersion": 1001,
|
|
7
7
|
"tsdocConfig": {
|
|
@@ -9925,6 +9925,32 @@
|
|
|
9925
9925
|
"endIndex": 2
|
|
9926
9926
|
}
|
|
9927
9927
|
},
|
|
9928
|
+
{
|
|
9929
|
+
"kind": "PropertySignature",
|
|
9930
|
+
"canonicalReference": "@empathyco/x-adapter!EmpathyRelatedTag#source:member",
|
|
9931
|
+
"docComment": "",
|
|
9932
|
+
"excerptTokens": [
|
|
9933
|
+
{
|
|
9934
|
+
"kind": "Content",
|
|
9935
|
+
"text": "source?: "
|
|
9936
|
+
},
|
|
9937
|
+
{
|
|
9938
|
+
"kind": "Content",
|
|
9939
|
+
"text": "'CURATED' | 'ORGANIC' | 'ENRICHED'"
|
|
9940
|
+
},
|
|
9941
|
+
{
|
|
9942
|
+
"kind": "Content",
|
|
9943
|
+
"text": ";"
|
|
9944
|
+
}
|
|
9945
|
+
],
|
|
9946
|
+
"isOptional": true,
|
|
9947
|
+
"releaseTag": "Public",
|
|
9948
|
+
"name": "source",
|
|
9949
|
+
"propertyTypeTokenRange": {
|
|
9950
|
+
"startIndex": 1,
|
|
9951
|
+
"endIndex": 2
|
|
9952
|
+
}
|
|
9953
|
+
},
|
|
9928
9954
|
{
|
|
9929
9955
|
"kind": "PropertySignature",
|
|
9930
9956
|
"canonicalReference": "@empathyco/x-adapter!EmpathyRelatedTag#tag:member",
|