@postnord/pn-marketweb-components 3.0.2 → 3.0.4
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/cjs/{FetchHelper-8d537d38.js → FetchHelper-dcfe4038.js} +122 -123
- package/cjs/FetchHelper-dcfe4038.js.map +1 -0
- package/cjs/loader.cjs.js +1 -1
- package/cjs/pn-address-autofill.cjs.entry.js +47 -49
- package/cjs/pn-address-autofill.cjs.entry.js.map +1 -1
- package/cjs/pn-animated-tile.cjs.entry.js +4 -4
- package/cjs/pn-animated-tile.cjs.entry.js.map +1 -1
- package/cjs/pn-app-banner.cjs.entry.js +15 -15
- package/cjs/pn-app-banner.cjs.entry.js.map +1 -1
- package/cjs/pn-bonus-progressbar-level.cjs.entry.js +1 -1
- package/cjs/pn-bonus-progressbar-level.cjs.entry.js.map +1 -1
- package/cjs/pn-bonus-progressbar.cjs.entry.js +1 -1
- package/cjs/pn-bonus-progressbar.cjs.entry.js.map +1 -1
- package/cjs/pn-breakpoints.cjs.entry.js +1 -1
- package/cjs/pn-breakpoints.cjs.entry.js.map +1 -1
- package/cjs/pn-chart.cjs.entry.js +47 -10
- package/cjs/pn-chart.cjs.entry.js.map +1 -1
- package/cjs/pn-charts-card.cjs.entry.js +7 -7
- package/cjs/pn-charts-card.cjs.entry.js.map +1 -1
- package/cjs/pn-choice-button.cjs.entry.js +1 -1
- package/cjs/pn-choice-button.cjs.entry.js.map +1 -1
- package/cjs/pn-cta-block.cjs.entry.js +1 -1
- package/cjs/pn-cta-block.cjs.entry.js.map +1 -1
- package/cjs/pn-customernumber-selector-option.cjs.entry.js +1 -1
- package/cjs/pn-customernumber-selector-option.cjs.entry.js.map +1 -1
- package/cjs/pn-customernumber-selector.cjs.entry.js +1 -1
- package/cjs/pn-customernumber-selector.cjs.entry.js.map +1 -1
- package/cjs/pn-date-and-time.cjs.entry.js +13 -15
- package/cjs/pn-date-and-time.cjs.entry.js.map +1 -1
- package/cjs/pn-dropdown-choice-adds-row.cjs.entry.js +33 -36
- package/cjs/pn-dropdown-choice-adds-row.cjs.entry.js.map +1 -1
- package/cjs/pn-dropdown-with-multi-input-rows-row.cjs.entry.js +13 -10
- package/cjs/pn-dropdown-with-multi-input-rows-row.cjs.entry.js.map +1 -1
- package/cjs/pn-dropdown-with-multi-input-rows.cjs.entry.js +46 -40
- package/cjs/pn-dropdown-with-multi-input-rows.cjs.entry.js.map +1 -1
- package/cjs/pn-filter-checkbox.cjs.entry.js +2 -3
- package/cjs/pn-filter-checkbox.cjs.entry.js.map +1 -1
- package/cjs/pn-find-price.cjs.entry.js +1 -2
- package/cjs/pn-find-price.cjs.entry.js.map +1 -1
- package/cjs/pn-find-service-and-price.cjs.entry.js +2 -3
- package/cjs/pn-find-service-and-price.cjs.entry.js.map +1 -1
- package/cjs/pn-hero-block-international.cjs.entry.js +3 -3
- package/cjs/pn-hero-block-international.cjs.entry.js.map +1 -1
- package/cjs/pn-language-selector_9.cjs.entry.js +83 -79
- package/cjs/pn-language-selector_9.cjs.entry.js.map +1 -1
- package/cjs/pn-line-shape.cjs.entry.js +1 -1
- package/cjs/pn-line-shape.cjs.entry.js.map +1 -1
- package/cjs/pn-link-list.cjs.entry.js +33 -37
- package/cjs/pn-link-list.cjs.entry.js.map +1 -1
- package/cjs/pn-mainnav-link.cjs.entry.js +2 -2
- package/cjs/pn-mainnav-link.cjs.entry.js.map +1 -1
- package/cjs/pn-market-web-components.cjs.js +1 -1
- package/cjs/pn-marketweb-input.cjs.entry.js +1 -2
- package/cjs/pn-marketweb-input.cjs.entry.js.map +1 -1
- package/cjs/pn-marketweb-search.cjs.entry.js +5 -1
- package/cjs/pn-marketweb-search.cjs.entry.js.map +1 -1
- package/cjs/pn-marketweb-sitefooter.cjs.entry.js +18 -24
- package/cjs/pn-marketweb-sitefooter.cjs.entry.js.map +1 -1
- package/cjs/pn-marketweb-siteheader-login-button_5.cjs.entry.js +17 -20
- package/cjs/pn-marketweb-siteheader-login-button_5.cjs.entry.js.map +1 -1
- package/cjs/pn-marketweb-siteheader-login-linklist.cjs.entry.js +5 -5
- package/cjs/pn-marketweb-siteheader-login-linklist.cjs.entry.js.map +1 -1
- package/cjs/pn-marketweb-siteheader.cjs.entry.js +22 -27
- package/cjs/pn-marketweb-siteheader.cjs.entry.js.map +1 -1
- package/cjs/pn-media-block.cjs.entry.js +31 -29
- package/cjs/pn-media-block.cjs.entry.js.map +1 -1
- package/cjs/pn-multi-row-connected-dropdown-row.cjs.entry.js +37 -45
- package/cjs/pn-multi-row-connected-dropdown-row.cjs.entry.js.map +1 -1
- package/cjs/pn-multi-row-connected-dropdown.cjs.entry.js +40 -34
- package/cjs/pn-multi-row-connected-dropdown.cjs.entry.js.map +1 -1
- package/cjs/pn-multiple-input.cjs.entry.js +9 -6
- package/cjs/pn-multiple-input.cjs.entry.js.map +1 -1
- package/cjs/pn-parcel-tracker.cjs.entry.js +1 -1
- package/cjs/pn-parcel-tracker.cjs.entry.js.map +1 -1
- package/cjs/pn-pex-pricefinder.cjs.entry.js +1 -1
- package/cjs/pn-pex-pricefinder.cjs.entry.js.map +1 -1
- package/cjs/pn-play-on-scroll.cjs.entry.js +19 -17
- package/cjs/pn-play-on-scroll.cjs.entry.js.map +1 -1
- package/cjs/pn-product-pricelist.cjs.entry.js +2 -3
- package/cjs/pn-product-pricelist.cjs.entry.js.map +1 -1
- package/cjs/pn-profile-modal-customernumber.cjs.entry.js +2 -1
- package/cjs/pn-profile-modal-customernumber.cjs.entry.js.map +1 -1
- package/cjs/pn-profile-modal-profile.cjs.entry.js +3 -1
- package/cjs/pn-profile-modal-profile.cjs.entry.js.map +1 -1
- package/cjs/pn-profile-modal-type.cjs.entry.js +1 -1
- package/cjs/pn-profile-modal-type.cjs.entry.js.map +1 -1
- package/cjs/pn-profile-modal.cjs.entry.js +1 -1
- package/cjs/pn-profile-modal.cjs.entry.js.map +1 -1
- package/cjs/pn-profile-selector-option.cjs.entry.js +1 -1
- package/cjs/pn-profile-selector-option.cjs.entry.js.map +1 -1
- package/cjs/pn-profile-selector.cjs.entry.js +1 -1
- package/cjs/pn-profile-selector.cjs.entry.js.map +1 -1
- package/cjs/pn-proxio-findprice-result.cjs.entry.js +8 -12
- package/cjs/pn-proxio-findprice-result.cjs.entry.js.map +1 -1
- package/cjs/pn-proxio-findprice.cjs.entry.js +16 -23
- package/cjs/pn-proxio-findprice.cjs.entry.js.map +1 -1
- package/cjs/pn-proxio-pricegroup.cjs.entry.js +9 -13
- package/cjs/pn-proxio-pricegroup.cjs.entry.js.map +1 -1
- package/cjs/pn-quick-cta.cjs.entry.js +1 -1
- package/cjs/pn-quick-cta.cjs.entry.js.map +1 -1
- package/cjs/pn-quote-card.cjs.entry.js +1 -1
- package/cjs/pn-quote-card.cjs.entry.js.map +1 -1
- package/cjs/pn-scroll_2.cjs.entry.js +16 -15
- package/cjs/pn-scroll_2.cjs.entry.js.map +1 -1
- package/cjs/pn-share-item.cjs.entry.js +1 -1
- package/cjs/pn-share-item.cjs.entry.js.map +1 -1
- package/cjs/pn-share.cjs.entry.js +1 -1
- package/cjs/pn-share.cjs.entry.js.map +1 -1
- package/cjs/pn-sidenav-level.cjs.entry.js +3 -4
- package/cjs/pn-sidenav-level.cjs.entry.js.map +1 -1
- package/cjs/pn-sidenav-link.cjs.entry.js +2 -2
- package/cjs/pn-sidenav-link.cjs.entry.js.map +1 -1
- package/cjs/pn-sidenav-togglebutton.cjs.entry.js +1 -1
- package/cjs/pn-sidenav-togglebutton.cjs.entry.js.map +1 -1
- package/cjs/pn-sidenav.cjs.entry.js +1 -1
- package/cjs/pn-sidenav.cjs.entry.js.map +1 -1
- package/cjs/pn-site-footer_3.cjs.entry.js +1 -1
- package/cjs/pn-site-footer_3.cjs.entry.js.map +1 -1
- package/cjs/pn-spotlight.cjs.entry.js +1 -1
- package/cjs/pn-spotlight.cjs.entry.js.map +1 -1
- package/cjs/pn-stats-info-data.cjs.entry.js +5 -5
- package/cjs/pn-stats-info-data.cjs.entry.js.map +1 -1
- package/cjs/pn-teaser-card.cjs.entry.js +2 -3
- package/cjs/pn-teaser-card.cjs.entry.js.map +1 -1
- package/cjs/pn-titletag.cjs.entry.js +1 -1
- package/cjs/pn-titletag.cjs.entry.js.map +1 -1
- package/cjs/pn-usp-promoter.cjs.entry.js +1 -1
- package/cjs/pn-usp-promoter.cjs.entry.js.map +1 -1
- package/collection/components/animation/pn-animated-tile/pn-animated-tile.js +4 -3
- package/collection/components/animation/pn-animated-tile/pn-animated-tile.js.map +1 -1
- package/collection/components/animation/pn-play-on-scroll/pn-play-on-scroll.js +19 -16
- package/collection/components/animation/pn-play-on-scroll/pn-play-on-scroll.js.map +1 -1
- package/collection/components/animation/pn-play-on-scroll/pn-video-overlay/pn-video-overlay.js +11 -9
- package/collection/components/animation/pn-play-on-scroll/pn-video-overlay/pn-video-overlay.js.map +1 -1
- package/collection/components/animation/pn-scroll/pn-scroll.js +5 -4
- package/collection/components/animation/pn-scroll/pn-scroll.js.map +1 -1
- package/collection/components/cards/pn-quote-card/pn-line-shape/pn-line-shape.js +1 -0
- package/collection/components/cards/pn-quote-card/pn-line-shape/pn-line-shape.js.map +1 -1
- package/collection/components/cards/pn-quote-card/pn-quote-card.js +1 -0
- package/collection/components/cards/pn-quote-card/pn-quote-card.js.map +1 -1
- package/collection/components/cards/pn-teaser-card/pn-teaser-card.js +2 -2
- package/collection/components/cards/pn-teaser-card/pn-teaser-card.js.map +1 -1
- package/collection/components/charts/pn-chart/pn-chart-helper.js +32 -7
- package/collection/components/charts/pn-chart/pn-chart-helper.js.map +1 -1
- package/collection/components/charts/pn-chart/pn-chart.js +15 -2
- package/collection/components/charts/pn-chart/pn-chart.js.map +1 -1
- package/collection/components/charts/pn-charts-card/pn-charts-card.js +7 -6
- package/collection/components/charts/pn-charts-card/pn-charts-card.js.map +1 -1
- package/collection/components/cta/pn-cta-block/pn-cta-block.js +1 -0
- package/collection/components/cta/pn-cta-block/pn-cta-block.js.map +1 -1
- package/collection/components/cta/pn-parcel-tracker/pn-parcel-tracker.js +1 -0
- package/collection/components/cta/pn-parcel-tracker/pn-parcel-tracker.js.map +1 -1
- package/collection/components/cta/pn-quick-cta/pn-quick-cta.js +1 -0
- package/collection/components/cta/pn-quick-cta/pn-quick-cta.js.map +1 -1
- package/collection/components/cta/pn-share/pn-share-item.js +1 -0
- package/collection/components/cta/pn-share/pn-share-item.js.map +1 -1
- package/collection/components/cta/pn-share/pn-share.js +1 -0
- package/collection/components/cta/pn-share/pn-share.js.map +1 -1
- package/collection/components/cta/pn-spotlight/pn-spotlight.js +1 -0
- package/collection/components/cta/pn-spotlight/pn-spotlight.js.map +1 -1
- package/collection/components/data-visualization/pn-stats-info/pn-stats-info-data/pn-stats-info-data.js +5 -5
- package/collection/components/data-visualization/pn-stats-info/pn-stats-info-data/pn-stats-info-data.js.map +1 -1
- package/collection/components/input/pn-address-autofill/pn-address-autofill.js +46 -47
- package/collection/components/input/pn-address-autofill/pn-address-autofill.js.map +1 -1
- package/collection/components/input/pn-bonus-progressbar/pn-bonus-progressbar-level.js +1 -0
- package/collection/components/input/pn-bonus-progressbar/pn-bonus-progressbar-level.js.map +1 -1
- package/collection/components/input/pn-bonus-progressbar/pn-bonus-progressbar.js +1 -0
- package/collection/components/input/pn-bonus-progressbar/pn-bonus-progressbar.js.map +1 -1
- package/collection/components/input/pn-choice-button/pn-choice-button.js +1 -0
- package/collection/components/input/pn-choice-button/pn-choice-button.js.map +1 -1
- package/collection/components/input/pn-date-and-time/pn-date-and-time.js +13 -14
- package/collection/components/input/pn-date-and-time/pn-date-and-time.js.map +1 -1
- package/collection/components/input/pn-dropdown-choice-adds-row/pn-dropdown-choice-adds-row.js +51 -35
- package/collection/components/input/pn-dropdown-choice-adds-row/pn-dropdown-choice-adds-row.js.map +1 -1
- package/collection/components/input/pn-dropdown-choice-adds-row/pn-dropdown-choice-adds-row.stories.js +1 -1
- package/collection/components/input/pn-dropdown-with-multi-input-rows/pn-dropdown-with-multi-input-rows-row.js +13 -9
- package/collection/components/input/pn-dropdown-with-multi-input-rows/pn-dropdown-with-multi-input-rows-row.js.map +1 -1
- package/collection/components/input/pn-dropdown-with-multi-input-rows/pn-dropdown-with-multi-input-rows.js +46 -39
- package/collection/components/input/pn-dropdown-with-multi-input-rows/pn-dropdown-with-multi-input-rows.js.map +1 -1
- package/collection/components/input/pn-dropdown-with-multi-input-rows/pn-dropdown-with-multi-input-rows.stories.js +1 -1
- package/collection/components/input/pn-filter-checkbox/pn-filter-checkbox.js +2 -2
- package/collection/components/input/pn-filter-checkbox/pn-filter-checkbox.js.map +1 -1
- package/collection/components/input/pn-marketweb-input/pn-marketweb-input.js +1 -2
- package/collection/components/input/pn-marketweb-input/pn-marketweb-input.js.map +1 -1
- package/collection/components/input/pn-marketweb-search/pn-marketweb-search.js +5 -0
- package/collection/components/input/pn-marketweb-search/pn-marketweb-search.js.map +1 -1
- package/collection/components/input/pn-multi-row-connected-dropdown/pn-multi-row-connected-dropdown-row.js +37 -44
- package/collection/components/input/pn-multi-row-connected-dropdown/pn-multi-row-connected-dropdown-row.js.map +1 -1
- package/collection/components/input/pn-multi-row-connected-dropdown/pn-multi-row-connected-dropdown.js +40 -33
- package/collection/components/input/pn-multi-row-connected-dropdown/pn-multi-row-connected-dropdown.js.map +1 -1
- package/collection/components/input/pn-multi-row-connected-dropdown/pn-multi-row-connected-dropdown.stories.js +1 -1
- package/collection/components/input/pn-multiple-input/pn-multiple-input.js +9 -5
- package/collection/components/input/pn-multiple-input/pn-multiple-input.js.map +1 -1
- package/collection/components/layout-components/pn-marketweb-sitefooter/pn-marketweb-sitefooter.js +17 -22
- package/collection/components/layout-components/pn-marketweb-sitefooter/pn-marketweb-sitefooter.js.map +1 -1
- package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-login-button.js +2 -0
- package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-login-button.js.map +1 -1
- package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-login-linklist.js +5 -4
- package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-login-linklist.js.map +1 -1
- package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-login-links.js +6 -7
- package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-login-links.js.map +1 -1
- package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-login-mypage-button.js +1 -0
- package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-login-mypage-button.js.map +1 -1
- package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-login-profileselection.js +7 -8
- package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-login-profileselection.js.map +1 -1
- package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-login.js +7 -6
- package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-login.js.map +1 -1
- package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-search.js +3 -2
- package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-search.js.map +1 -1
- package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-unified-login.js +1 -0
- package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-unified-login.js.map +1 -1
- package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader.js +21 -25
- package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader.js.map +1 -1
- package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader.stories.js +5 -22
- package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader.stories.js.map +1 -1
- package/collection/components/media/pn-media-block/pn-media-block.js +31 -28
- package/collection/components/media/pn-media-block/pn-media-block.js.map +1 -1
- package/collection/components/minor/pn-app-banner/pn-app-banner.js +15 -14
- package/collection/components/minor/pn-app-banner/pn-app-banner.js.map +1 -1
- package/collection/components/minor/pn-swan/pn-swan.js +1 -0
- package/collection/components/minor/pn-swan/pn-swan.js.map +1 -1
- package/collection/components/minor/pn-titletag/pn-titletag.js +1 -0
- package/collection/components/minor/pn-titletag/pn-titletag.js.map +1 -1
- package/collection/components/navigation/pn-language-selector/pn-language-selector-option.js +1 -0
- package/collection/components/navigation/pn-language-selector/pn-language-selector-option.js.map +1 -1
- package/collection/components/navigation/pn-language-selector/pn-language-selector.js +4 -2
- package/collection/components/navigation/pn-language-selector/pn-language-selector.js.map +1 -1
- package/collection/components/navigation/pn-mainnav/pn-mainnav-level.js +2 -1
- package/collection/components/navigation/pn-mainnav/pn-mainnav-level.js.map +1 -1
- package/collection/components/navigation/pn-mainnav/pn-mainnav-link.js +2 -1
- package/collection/components/navigation/pn-mainnav/pn-mainnav-link.js.map +1 -1
- package/collection/components/navigation/pn-mainnav/pn-mainnav-list.js +1 -0
- package/collection/components/navigation/pn-mainnav/pn-mainnav-list.js.map +1 -1
- package/collection/components/navigation/pn-mainnav/pn-mainnav.js +4 -0
- package/collection/components/navigation/pn-mainnav/pn-mainnav.js.map +1 -1
- package/collection/components/navigation/pn-sidenav/pn-sidenav-level.js +3 -3
- package/collection/components/navigation/pn-sidenav/pn-sidenav-level.js.map +1 -1
- package/collection/components/navigation/pn-sidenav/pn-sidenav-link.js +2 -1
- package/collection/components/navigation/pn-sidenav/pn-sidenav-link.js.map +1 -1
- package/collection/components/navigation/pn-sidenav/pn-sidenav-togglebutton.js +1 -0
- package/collection/components/navigation/pn-sidenav/pn-sidenav-togglebutton.js.map +1 -1
- package/collection/components/navigation/pn-sidenav/pn-sidenav.js +1 -0
- package/collection/components/navigation/pn-sidenav/pn-sidenav.js.map +1 -1
- package/collection/components/navigation/pn-site-selector/pn-site-selector.js +1 -0
- package/collection/components/navigation/pn-site-selector/pn-site-selector.js.map +1 -1
- package/collection/components/profile/pn-customernumber-selector/pn-customernumber-selector-option.js +1 -0
- package/collection/components/profile/pn-customernumber-selector/pn-customernumber-selector-option.js.map +1 -1
- package/collection/components/profile/pn-customernumber-selector/pn-customernumber-selector.js +1 -0
- package/collection/components/profile/pn-customernumber-selector/pn-customernumber-selector.js.map +1 -1
- package/collection/components/profile/pn-profile-modal/pn-profile-modal-customernumber.js +2 -0
- package/collection/components/profile/pn-profile-modal/pn-profile-modal-customernumber.js.map +1 -1
- package/collection/components/profile/pn-profile-modal/pn-profile-modal-profile.js +3 -0
- package/collection/components/profile/pn-profile-modal/pn-profile-modal-profile.js.map +1 -1
- package/collection/components/profile/pn-profile-modal/pn-profile-modal-type.js +1 -0
- package/collection/components/profile/pn-profile-modal/pn-profile-modal-type.js.map +1 -1
- package/collection/components/profile/pn-profile-modal/pn-profile-modal.js +1 -0
- package/collection/components/profile/pn-profile-modal/pn-profile-modal.js.map +1 -1
- package/collection/components/profile/pn-profile-selector/pn-profile-selector-option.js +1 -0
- package/collection/components/profile/pn-profile-selector/pn-profile-selector-option.js.map +1 -1
- package/collection/components/profile/pn-profile-selector/pn-profile-selector.js +1 -0
- package/collection/components/profile/pn-profile-selector/pn-profile-selector.js.map +1 -1
- package/collection/components/utilities/pn-breakpoints/pn-breakpoints.js +1 -0
- package/collection/components/utilities/pn-breakpoints/pn-breakpoints.js.map +1 -1
- package/collection/components/widgets/pn-find-price/pn-find-price.js +1 -2
- package/collection/components/widgets/pn-find-price/pn-find-price.js.map +1 -1
- package/collection/components/widgets/pn-find-service-and-price/pn-find-service-and-price.js +2 -3
- package/collection/components/widgets/pn-find-service-and-price/pn-find-service-and-price.js.map +1 -1
- package/collection/components/widgets/pn-hero-block-international/pn-hero-block-international.js +3 -2
- package/collection/components/widgets/pn-hero-block-international/pn-hero-block-international.js.map +1 -1
- package/collection/components/widgets/pn-link-list/pn-link-list.js +33 -37
- package/collection/components/widgets/pn-link-list/pn-link-list.js.map +1 -1
- package/collection/components/widgets/pn-pex-pricefinder/pn-pex-pricefinder.js +1 -0
- package/collection/components/widgets/pn-pex-pricefinder/pn-pex-pricefinder.js.map +1 -1
- package/collection/components/widgets/pn-product-pricelist/pn-product-pricelist.js +2 -3
- package/collection/components/widgets/pn-product-pricelist/pn-product-pricelist.js.map +1 -1
- package/collection/components/widgets/pn-proxio-findprice/pn-proxio-findprice-result.js +8 -12
- package/collection/components/widgets/pn-proxio-findprice/pn-proxio-findprice-result.js.map +1 -1
- package/collection/components/widgets/pn-proxio-findprice/pn-proxio-findprice.js +15 -22
- package/collection/components/widgets/pn-proxio-findprice/pn-proxio-findprice.js.map +1 -1
- package/collection/components/widgets/pn-proxio-pricegroup/pn-proxio-pricegroup.js +8 -12
- package/collection/components/widgets/pn-proxio-pricegroup/pn-proxio-pricegroup.js.map +1 -1
- package/collection/components/widgets/pn-usp-promoter/pn-usp-promoter.js +1 -0
- package/collection/components/widgets/pn-usp-promoter/pn-usp-promoter.js.map +1 -1
- package/collection/globals/FetchHelper.js +35 -35
- package/collection/globals/FetchHelper.js.map +1 -1
- package/collection/globals/MarketWebContextService.js +86 -87
- package/collection/globals/MarketWebContextService.js.map +1 -1
- package/collection/globals/MarketWebLoginManager.js +60 -61
- package/collection/globals/MarketWebLoginManager.js.map +1 -1
- package/components/FetchHelper.js +121 -122
- package/components/FetchHelper.js.map +1 -1
- package/components/pn-address-autofill.js +46 -48
- package/components/pn-address-autofill.js.map +1 -1
- package/components/pn-animated-tile.js +4 -4
- package/components/pn-animated-tile.js.map +1 -1
- package/components/pn-app-banner.js +15 -15
- package/components/pn-app-banner.js.map +1 -1
- package/components/pn-bonus-progressbar-level.js +1 -1
- package/components/pn-bonus-progressbar-level.js.map +1 -1
- package/components/pn-bonus-progressbar.js +1 -1
- package/components/pn-bonus-progressbar.js.map +1 -1
- package/components/pn-breakpoints.js +1 -1
- package/components/pn-breakpoints.js.map +1 -1
- package/components/pn-chart.js +47 -10
- package/components/pn-chart.js.map +1 -1
- package/components/pn-charts-card.js +7 -7
- package/components/pn-charts-card.js.map +1 -1
- package/components/pn-choice-button2.js +1 -1
- package/components/pn-choice-button2.js.map +1 -1
- package/components/pn-cta-block.js +1 -1
- package/components/pn-cta-block.js.map +1 -1
- package/components/pn-customernumber-selector-option.js +1 -1
- package/components/pn-customernumber-selector-option.js.map +1 -1
- package/components/pn-customernumber-selector.js +1 -1
- package/components/pn-customernumber-selector.js.map +1 -1
- package/components/pn-date-and-time.js +13 -15
- package/components/pn-date-and-time.js.map +1 -1
- package/components/pn-dropdown-choice-adds-row.js +34 -36
- package/components/pn-dropdown-choice-adds-row.js.map +1 -1
- package/components/pn-dropdown-with-multi-input-rows-row2.js +13 -10
- package/components/pn-dropdown-with-multi-input-rows-row2.js.map +1 -1
- package/components/pn-dropdown-with-multi-input-rows.js +46 -40
- package/components/pn-dropdown-with-multi-input-rows.js.map +1 -1
- package/components/pn-filter-checkbox2.js +2 -3
- package/components/pn-filter-checkbox2.js.map +1 -1
- package/components/pn-find-price.js +1 -2
- package/components/pn-find-price.js.map +1 -1
- package/components/pn-find-service-and-price.js +2 -3
- package/components/pn-find-service-and-price.js.map +1 -1
- package/components/pn-hero-block-international.js +3 -3
- package/components/pn-hero-block-international.js.map +1 -1
- package/components/pn-language-selector-option2.js +1 -0
- package/components/pn-language-selector-option2.js.map +1 -1
- package/components/pn-language-selector2.js +4 -3
- package/components/pn-language-selector2.js.map +1 -1
- package/components/pn-line-shape.js +1 -1
- package/components/pn-line-shape.js.map +1 -1
- package/components/pn-link-list.js +33 -37
- package/components/pn-link-list.js.map +1 -1
- package/components/pn-mainnav-level2.js +2 -2
- package/components/pn-mainnav-level2.js.map +1 -1
- package/components/pn-mainnav-link2.js +2 -2
- package/components/pn-mainnav-link2.js.map +1 -1
- package/components/pn-mainnav-list2.js +1 -1
- package/components/pn-mainnav-list2.js.map +1 -1
- package/components/pn-mainnav2.js +4 -1
- package/components/pn-mainnav2.js.map +1 -1
- package/components/pn-marketweb-input2.js +1 -2
- package/components/pn-marketweb-input2.js.map +1 -1
- package/components/pn-marketweb-search.js +5 -1
- package/components/pn-marketweb-search.js.map +1 -1
- package/components/pn-marketweb-sitefooter.js +17 -23
- package/components/pn-marketweb-sitefooter.js.map +1 -1
- package/components/pn-marketweb-siteheader-login-button2.js +2 -1
- package/components/pn-marketweb-siteheader-login-button2.js.map +1 -1
- package/components/pn-marketweb-siteheader-login-linklist2.js +5 -5
- package/components/pn-marketweb-siteheader-login-linklist2.js.map +1 -1
- package/components/pn-marketweb-siteheader-login-links2.js +6 -8
- package/components/pn-marketweb-siteheader-login-links2.js.map +1 -1
- package/components/pn-marketweb-siteheader-login-mypage-button2.js +1 -1
- package/components/pn-marketweb-siteheader-login-mypage-button2.js.map +1 -1
- package/components/pn-marketweb-siteheader-login-profileselection2.js +7 -9
- package/components/pn-marketweb-siteheader-login-profileselection2.js.map +1 -1
- package/components/pn-marketweb-siteheader-login2.js +67 -68
- package/components/pn-marketweb-siteheader-login2.js.map +1 -1
- package/components/pn-marketweb-siteheader-search2.js +3 -3
- package/components/pn-marketweb-siteheader-search2.js.map +1 -1
- package/components/pn-marketweb-siteheader-unified-login2.js +1 -1
- package/components/pn-marketweb-siteheader-unified-login2.js.map +1 -1
- package/components/pn-marketweb-siteheader.js +21 -26
- package/components/pn-marketweb-siteheader.js.map +1 -1
- package/components/pn-media-block.js +31 -29
- package/components/pn-media-block.js.map +1 -1
- package/components/pn-multi-row-connected-dropdown-row2.js +37 -45
- package/components/pn-multi-row-connected-dropdown-row2.js.map +1 -1
- package/components/pn-multi-row-connected-dropdown.js +40 -34
- package/components/pn-multi-row-connected-dropdown.js.map +1 -1
- package/components/pn-multiple-input.js +9 -6
- package/components/pn-multiple-input.js.map +1 -1
- package/components/pn-parcel-tracker.js +1 -1
- package/components/pn-parcel-tracker.js.map +1 -1
- package/components/pn-pex-pricefinder.js +1 -1
- package/components/pn-pex-pricefinder.js.map +1 -1
- package/components/pn-play-on-scroll2.js +19 -17
- package/components/pn-play-on-scroll2.js.map +1 -1
- package/components/pn-product-pricelist.js +2 -3
- package/components/pn-product-pricelist.js.map +1 -1
- package/components/pn-profile-modal-customernumber.js +2 -1
- package/components/pn-profile-modal-customernumber.js.map +1 -1
- package/components/pn-profile-modal-profile.js +3 -1
- package/components/pn-profile-modal-profile.js.map +1 -1
- package/components/pn-profile-modal-type.js +1 -1
- package/components/pn-profile-modal-type.js.map +1 -1
- package/components/pn-profile-modal.js +1 -1
- package/components/pn-profile-modal.js.map +1 -1
- package/components/pn-profile-selector-option.js +1 -1
- package/components/pn-profile-selector-option.js.map +1 -1
- package/components/pn-profile-selector.js +1 -1
- package/components/pn-profile-selector.js.map +1 -1
- package/components/pn-proxio-findprice-result2.js +8 -12
- package/components/pn-proxio-findprice-result2.js.map +1 -1
- package/components/pn-proxio-findprice.js +15 -22
- package/components/pn-proxio-findprice.js.map +1 -1
- package/components/pn-proxio-pricegroup.js +8 -12
- package/components/pn-proxio-pricegroup.js.map +1 -1
- package/components/pn-quick-cta.js +1 -1
- package/components/pn-quick-cta.js.map +1 -1
- package/components/pn-quote-card.js +1 -1
- package/components/pn-quote-card.js.map +1 -1
- package/components/pn-scroll2.js +5 -5
- package/components/pn-scroll2.js.map +1 -1
- package/components/pn-share-item2.js +1 -1
- package/components/pn-share-item2.js.map +1 -1
- package/components/pn-share.js +1 -1
- package/components/pn-share.js.map +1 -1
- package/components/pn-sidenav-level.js +3 -4
- package/components/pn-sidenav-level.js.map +1 -1
- package/components/pn-sidenav-link.js +2 -2
- package/components/pn-sidenav-link.js.map +1 -1
- package/components/pn-sidenav-togglebutton.js +1 -1
- package/components/pn-sidenav-togglebutton.js.map +1 -1
- package/components/pn-sidenav.js +1 -1
- package/components/pn-sidenav.js.map +1 -1
- package/components/pn-site-selector2.js +1 -1
- package/components/pn-site-selector2.js.map +1 -1
- package/components/pn-spotlight.js +1 -1
- package/components/pn-spotlight.js.map +1 -1
- package/components/pn-stats-info-data2.js +5 -5
- package/components/pn-stats-info-data2.js.map +1 -1
- package/components/pn-swan2.js +1 -1
- package/components/pn-swan2.js.map +1 -1
- package/components/pn-teaser-card.js +2 -3
- package/components/pn-teaser-card.js.map +1 -1
- package/components/pn-titletag2.js +1 -1
- package/components/pn-titletag2.js.map +1 -1
- package/components/pn-usp-promoter.js +1 -1
- package/components/pn-usp-promoter.js.map +1 -1
- package/components/pn-video-overlay2.js +11 -10
- package/components/pn-video-overlay2.js.map +1 -1
- package/esm/{FetchHelper-03b37a44.js → FetchHelper-da579b12.js} +122 -123
- package/esm/FetchHelper-da579b12.js.map +1 -0
- package/esm/loader.js +1 -1
- package/esm/pn-address-autofill.entry.js +48 -50
- package/esm/pn-address-autofill.entry.js.map +1 -1
- package/esm/pn-animated-tile.entry.js +5 -5
- package/esm/pn-animated-tile.entry.js.map +1 -1
- package/esm/pn-app-banner.entry.js +16 -16
- package/esm/pn-app-banner.entry.js.map +1 -1
- package/esm/pn-bonus-progressbar-level.entry.js +2 -2
- package/esm/pn-bonus-progressbar-level.entry.js.map +1 -1
- package/esm/pn-bonus-progressbar.entry.js +2 -2
- package/esm/pn-bonus-progressbar.entry.js.map +1 -1
- package/esm/pn-breakpoints.entry.js +2 -2
- package/esm/pn-breakpoints.entry.js.map +1 -1
- package/esm/pn-chart.entry.js +48 -11
- package/esm/pn-chart.entry.js.map +1 -1
- package/esm/pn-charts-card.entry.js +8 -8
- package/esm/pn-charts-card.entry.js.map +1 -1
- package/esm/pn-choice-button.entry.js +2 -2
- package/esm/pn-choice-button.entry.js.map +1 -1
- package/esm/pn-cta-block.entry.js +2 -2
- package/esm/pn-cta-block.entry.js.map +1 -1
- package/esm/pn-customernumber-selector-option.entry.js +2 -2
- package/esm/pn-customernumber-selector-option.entry.js.map +1 -1
- package/esm/pn-customernumber-selector.entry.js +2 -2
- package/esm/pn-customernumber-selector.entry.js.map +1 -1
- package/esm/pn-date-and-time.entry.js +14 -16
- package/esm/pn-date-and-time.entry.js.map +1 -1
- package/esm/pn-dropdown-choice-adds-row.entry.js +34 -37
- package/esm/pn-dropdown-choice-adds-row.entry.js.map +1 -1
- package/esm/pn-dropdown-with-multi-input-rows-row.entry.js +14 -11
- package/esm/pn-dropdown-with-multi-input-rows-row.entry.js.map +1 -1
- package/esm/pn-dropdown-with-multi-input-rows.entry.js +47 -41
- package/esm/pn-dropdown-with-multi-input-rows.entry.js.map +1 -1
- package/esm/pn-filter-checkbox.entry.js +3 -4
- package/esm/pn-filter-checkbox.entry.js.map +1 -1
- package/esm/pn-find-price.entry.js +1 -2
- package/esm/pn-find-price.entry.js.map +1 -1
- package/esm/pn-find-service-and-price.entry.js +2 -3
- package/esm/pn-find-service-and-price.entry.js.map +1 -1
- package/esm/pn-hero-block-international.entry.js +4 -4
- package/esm/pn-hero-block-international.entry.js.map +1 -1
- package/esm/pn-language-selector_9.entry.js +84 -80
- package/esm/pn-language-selector_9.entry.js.map +1 -1
- package/esm/pn-line-shape.entry.js +2 -2
- package/esm/pn-line-shape.entry.js.map +1 -1
- package/esm/pn-link-list.entry.js +33 -37
- package/esm/pn-link-list.entry.js.map +1 -1
- package/esm/pn-mainnav-link.entry.js +3 -3
- package/esm/pn-mainnav-link.entry.js.map +1 -1
- package/esm/pn-market-web-components.js +1 -1
- package/esm/pn-marketweb-input.entry.js +1 -2
- package/esm/pn-marketweb-input.entry.js.map +1 -1
- package/esm/pn-marketweb-search.entry.js +6 -2
- package/esm/pn-marketweb-search.entry.js.map +1 -1
- package/esm/pn-marketweb-sitefooter.entry.js +19 -25
- package/esm/pn-marketweb-sitefooter.entry.js.map +1 -1
- package/esm/pn-marketweb-siteheader-login-button_5.entry.js +18 -21
- package/esm/pn-marketweb-siteheader-login-button_5.entry.js.map +1 -1
- package/esm/pn-marketweb-siteheader-login-linklist.entry.js +6 -6
- package/esm/pn-marketweb-siteheader-login-linklist.entry.js.map +1 -1
- package/esm/pn-marketweb-siteheader.entry.js +23 -28
- package/esm/pn-marketweb-siteheader.entry.js.map +1 -1
- package/esm/pn-media-block.entry.js +32 -30
- package/esm/pn-media-block.entry.js.map +1 -1
- package/esm/pn-multi-row-connected-dropdown-row.entry.js +38 -46
- package/esm/pn-multi-row-connected-dropdown-row.entry.js.map +1 -1
- package/esm/pn-multi-row-connected-dropdown.entry.js +41 -35
- package/esm/pn-multi-row-connected-dropdown.entry.js.map +1 -1
- package/esm/pn-multiple-input.entry.js +10 -7
- package/esm/pn-multiple-input.entry.js.map +1 -1
- package/esm/pn-parcel-tracker.entry.js +2 -2
- package/esm/pn-parcel-tracker.entry.js.map +1 -1
- package/esm/pn-pex-pricefinder.entry.js +2 -2
- package/esm/pn-pex-pricefinder.entry.js.map +1 -1
- package/esm/pn-play-on-scroll.entry.js +20 -18
- package/esm/pn-play-on-scroll.entry.js.map +1 -1
- package/esm/pn-product-pricelist.entry.js +2 -3
- package/esm/pn-product-pricelist.entry.js.map +1 -1
- package/esm/pn-profile-modal-customernumber.entry.js +3 -2
- package/esm/pn-profile-modal-customernumber.entry.js.map +1 -1
- package/esm/pn-profile-modal-profile.entry.js +4 -2
- package/esm/pn-profile-modal-profile.entry.js.map +1 -1
- package/esm/pn-profile-modal-type.entry.js +2 -2
- package/esm/pn-profile-modal-type.entry.js.map +1 -1
- package/esm/pn-profile-modal.entry.js +2 -2
- package/esm/pn-profile-modal.entry.js.map +1 -1
- package/esm/pn-profile-selector-option.entry.js +2 -2
- package/esm/pn-profile-selector-option.entry.js.map +1 -1
- package/esm/pn-profile-selector.entry.js +2 -2
- package/esm/pn-profile-selector.entry.js.map +1 -1
- package/esm/pn-proxio-findprice-result.entry.js +8 -12
- package/esm/pn-proxio-findprice-result.entry.js.map +1 -1
- package/esm/pn-proxio-findprice.entry.js +16 -23
- package/esm/pn-proxio-findprice.entry.js.map +1 -1
- package/esm/pn-proxio-pricegroup.entry.js +9 -13
- package/esm/pn-proxio-pricegroup.entry.js.map +1 -1
- package/esm/pn-quick-cta.entry.js +2 -2
- package/esm/pn-quick-cta.entry.js.map +1 -1
- package/esm/pn-quote-card.entry.js +2 -2
- package/esm/pn-quote-card.entry.js.map +1 -1
- package/esm/pn-scroll_2.entry.js +17 -16
- package/esm/pn-scroll_2.entry.js.map +1 -1
- package/esm/pn-share-item.entry.js +2 -2
- package/esm/pn-share-item.entry.js.map +1 -1
- package/esm/pn-share.entry.js +2 -2
- package/esm/pn-share.entry.js.map +1 -1
- package/esm/pn-sidenav-level.entry.js +4 -5
- package/esm/pn-sidenav-level.entry.js.map +1 -1
- package/esm/pn-sidenav-link.entry.js +3 -3
- package/esm/pn-sidenav-link.entry.js.map +1 -1
- package/esm/pn-sidenav-togglebutton.entry.js +2 -2
- package/esm/pn-sidenav-togglebutton.entry.js.map +1 -1
- package/esm/pn-sidenav.entry.js +2 -2
- package/esm/pn-sidenav.entry.js.map +1 -1
- package/esm/pn-site-footer_3.entry.js +1 -1
- package/esm/pn-site-footer_3.entry.js.map +1 -1
- package/esm/pn-spotlight.entry.js +2 -2
- package/esm/pn-spotlight.entry.js.map +1 -1
- package/esm/pn-stats-info-data.entry.js +5 -5
- package/esm/pn-stats-info-data.entry.js.map +1 -1
- package/esm/pn-teaser-card.entry.js +3 -4
- package/esm/pn-teaser-card.entry.js.map +1 -1
- package/esm/pn-titletag.entry.js +2 -2
- package/esm/pn-titletag.entry.js.map +1 -1
- package/esm/pn-usp-promoter.entry.js +2 -2
- package/esm/pn-usp-promoter.entry.js.map +1 -1
- package/package.json +1 -2
- package/pn-market-web-components/{p-8ca34ec3.entry.js → p-0247c553.entry.js} +2 -2
- package/pn-market-web-components/p-0247c553.entry.js.map +1 -0
- package/pn-market-web-components/{p-3f50be05.entry.js → p-09b9cc06.entry.js} +2 -2
- package/pn-market-web-components/{p-3f50be05.entry.js.map → p-09b9cc06.entry.js.map} +1 -1
- package/pn-market-web-components/{p-03dfc155.entry.js → p-0a522476.entry.js} +2 -2
- package/pn-market-web-components/{p-03dfc155.entry.js.map → p-0a522476.entry.js.map} +1 -1
- package/pn-market-web-components/{p-2b2b615e.entry.js → p-1317587f.entry.js} +4 -4
- package/pn-market-web-components/{p-2b2b615e.entry.js.map → p-1317587f.entry.js.map} +1 -1
- package/pn-market-web-components/p-1535a09f.entry.js +2 -0
- package/pn-market-web-components/p-1535a09f.entry.js.map +1 -0
- package/pn-market-web-components/{p-470ca6e7.entry.js → p-1578e02e.entry.js} +2 -2
- package/pn-market-web-components/{p-470ca6e7.entry.js.map → p-1578e02e.entry.js.map} +1 -1
- package/pn-market-web-components/p-16f70311.entry.js +2 -0
- package/pn-market-web-components/{p-b7a5fb1b.entry.js.map → p-16f70311.entry.js.map} +1 -1
- package/pn-market-web-components/{p-c8bbdd96.entry.js → p-190c671b.entry.js} +2 -2
- package/pn-market-web-components/{p-c8bbdd96.entry.js.map → p-190c671b.entry.js.map} +1 -1
- package/pn-market-web-components/{p-3e4208bb.entry.js → p-1bd5fa26.entry.js} +2 -2
- package/pn-market-web-components/{p-3e4208bb.entry.js.map → p-1bd5fa26.entry.js.map} +1 -1
- package/pn-market-web-components/{p-e74e962e.entry.js → p-2044eddc.entry.js} +2 -2
- package/pn-market-web-components/{p-e74e962e.entry.js.map → p-2044eddc.entry.js.map} +1 -1
- package/pn-market-web-components/p-370829c6.entry.js +2 -0
- package/pn-market-web-components/p-370829c6.entry.js.map +1 -0
- package/pn-market-web-components/p-391970af.entry.js +2 -0
- package/pn-market-web-components/p-391970af.entry.js.map +1 -0
- package/pn-market-web-components/{p-49fd7182.entry.js → p-40538914.entry.js} +2 -2
- package/pn-market-web-components/{p-49fd7182.entry.js.map → p-40538914.entry.js.map} +1 -1
- package/pn-market-web-components/{p-fa9ea740.entry.js → p-4372d10e.entry.js} +2 -2
- package/pn-market-web-components/p-4372d10e.entry.js.map +1 -0
- package/pn-market-web-components/p-4ea1409d.entry.js +2 -0
- package/pn-market-web-components/p-4ea1409d.entry.js.map +1 -0
- package/pn-market-web-components/{p-66981606.entry.js → p-56bd346e.entry.js} +2 -2
- package/pn-market-web-components/{p-66981606.entry.js.map → p-56bd346e.entry.js.map} +1 -1
- package/pn-market-web-components/p-586a1e3c.entry.js +2 -0
- package/pn-market-web-components/{p-f8eb860b.entry.js.map → p-586a1e3c.entry.js.map} +1 -1
- package/pn-market-web-components/{p-baa28521.entry.js → p-5a467ca6.entry.js} +2 -2
- package/pn-market-web-components/{p-baa28521.entry.js.map → p-5a467ca6.entry.js.map} +1 -1
- package/pn-market-web-components/p-5ac23b38.entry.js +2 -0
- package/pn-market-web-components/p-5ac23b38.entry.js.map +1 -0
- package/pn-market-web-components/{p-7fdc49d1.entry.js → p-63505736.entry.js} +2 -2
- package/pn-market-web-components/p-63505736.entry.js.map +1 -0
- package/pn-market-web-components/{p-3696ebf8.entry.js → p-67d862ac.entry.js} +2 -2
- package/pn-market-web-components/{p-3696ebf8.entry.js.map → p-67d862ac.entry.js.map} +1 -1
- package/pn-market-web-components/{p-3d3f0648.entry.js → p-68aa55f7.entry.js} +2 -2
- package/pn-market-web-components/{p-3d3f0648.entry.js.map → p-68aa55f7.entry.js.map} +1 -1
- package/pn-market-web-components/{p-d2109ea6.entry.js → p-6e9875e5.entry.js} +2 -2
- package/pn-market-web-components/p-6e9875e5.entry.js.map +1 -0
- package/pn-market-web-components/p-7021985c.entry.js +2 -0
- package/pn-market-web-components/{p-c64cb117.entry.js.map → p-7021985c.entry.js.map} +1 -1
- package/pn-market-web-components/{p-716165d2.entry.js → p-721598b8.entry.js} +2 -2
- package/pn-market-web-components/p-721598b8.entry.js.map +1 -0
- package/pn-market-web-components/p-73cef33c.js +2 -0
- package/pn-market-web-components/p-73cef33c.js.map +1 -0
- package/pn-market-web-components/p-74203d3e.entry.js +2 -0
- package/pn-market-web-components/{p-545ea4ef.entry.js.map → p-74203d3e.entry.js.map} +1 -1
- package/pn-market-web-components/p-781ef432.entry.js +2 -0
- package/pn-market-web-components/p-781ef432.entry.js.map +1 -0
- package/pn-market-web-components/{p-3a08299c.entry.js → p-78fbc88c.entry.js} +2 -2
- package/pn-market-web-components/{p-3a08299c.entry.js.map → p-78fbc88c.entry.js.map} +1 -1
- package/pn-market-web-components/{p-22a65c3e.entry.js → p-796ebfee.entry.js} +2 -2
- package/pn-market-web-components/p-796ebfee.entry.js.map +1 -0
- package/pn-market-web-components/p-7b05d7c7.entry.js +2 -0
- package/pn-market-web-components/p-7b05d7c7.entry.js.map +1 -0
- package/pn-market-web-components/{p-6b2009dc.entry.js → p-81b3e038.entry.js} +2 -2
- package/pn-market-web-components/{p-6b2009dc.entry.js.map → p-81b3e038.entry.js.map} +1 -1
- package/pn-market-web-components/p-828449da.entry.js +2 -0
- package/pn-market-web-components/{p-db2f3f6d.entry.js.map → p-828449da.entry.js.map} +1 -1
- package/pn-market-web-components/p-85d57c9d.entry.js +2 -0
- package/pn-market-web-components/p-85d57c9d.entry.js.map +1 -0
- package/pn-market-web-components/p-90ba1d8e.entry.js +2 -0
- package/pn-market-web-components/{p-655e6f71.entry.js.map → p-90ba1d8e.entry.js.map} +1 -1
- package/pn-market-web-components/{p-eee5ec0a.entry.js → p-931d3a9b.entry.js} +2 -2
- package/pn-market-web-components/{p-eee5ec0a.entry.js.map → p-931d3a9b.entry.js.map} +1 -1
- package/pn-market-web-components/{p-9a93bcd0.entry.js → p-95c10b7e.entry.js} +2 -2
- package/pn-market-web-components/{p-9a93bcd0.entry.js.map → p-95c10b7e.entry.js.map} +1 -1
- package/pn-market-web-components/{p-138ecede.entry.js → p-95e054fd.entry.js} +2 -2
- package/pn-market-web-components/{p-138ecede.entry.js.map → p-95e054fd.entry.js.map} +1 -1
- package/pn-market-web-components/p-9776a1c5.entry.js +2 -0
- package/pn-market-web-components/p-9776a1c5.entry.js.map +1 -0
- package/pn-market-web-components/{p-db2e2762.entry.js → p-9998c29d.entry.js} +2 -2
- package/pn-market-web-components/p-9998c29d.entry.js.map +1 -0
- package/pn-market-web-components/p-9a7abcee.entry.js +2 -0
- package/pn-market-web-components/p-9a7abcee.entry.js.map +1 -0
- package/pn-market-web-components/{p-0dca82de.entry.js → p-9be27d72.entry.js} +2 -2
- package/pn-market-web-components/{p-0dca82de.entry.js.map → p-9be27d72.entry.js.map} +1 -1
- package/pn-market-web-components/{p-48f6e683.entry.js → p-a8220c88.entry.js} +2 -2
- package/pn-market-web-components/{p-48f6e683.entry.js.map → p-a8220c88.entry.js.map} +1 -1
- package/pn-market-web-components/p-a9d2f528.entry.js +2 -0
- package/pn-market-web-components/p-a9d2f528.entry.js.map +1 -0
- package/pn-market-web-components/p-acbe60df.entry.js +2 -0
- package/pn-market-web-components/p-acbe60df.entry.js.map +1 -0
- package/pn-market-web-components/{p-5666f0e7.entry.js → p-ade7ffcf.entry.js} +2 -2
- package/pn-market-web-components/p-ade7ffcf.entry.js.map +1 -0
- package/pn-market-web-components/p-b2dcce7c.entry.js +2 -0
- package/pn-market-web-components/p-b2dcce7c.entry.js.map +1 -0
- package/pn-market-web-components/{p-10a3c6f4.entry.js → p-b765e4a9.entry.js} +2 -2
- package/pn-market-web-components/p-b765e4a9.entry.js.map +1 -0
- package/pn-market-web-components/{p-914e1d15.entry.js → p-c224d7c4.entry.js} +2 -2
- package/pn-market-web-components/p-c224d7c4.entry.js.map +1 -0
- package/pn-market-web-components/{p-787e20a1.entry.js → p-c5856c0b.entry.js} +2 -2
- package/pn-market-web-components/{p-787e20a1.entry.js.map → p-c5856c0b.entry.js.map} +1 -1
- package/pn-market-web-components/p-c696bedf.entry.js +2 -0
- package/pn-market-web-components/{p-012ee486.entry.js.map → p-c696bedf.entry.js.map} +1 -1
- package/pn-market-web-components/p-c9f21ea3.entry.js +2 -0
- package/pn-market-web-components/{p-03cb46c2.entry.js.map → p-c9f21ea3.entry.js.map} +1 -1
- package/pn-market-web-components/{p-87aa1f73.entry.js → p-d07cf4c8.entry.js} +2 -2
- package/pn-market-web-components/{p-87aa1f73.entry.js.map → p-d07cf4c8.entry.js.map} +1 -1
- package/pn-market-web-components/p-d40ff187.entry.js +2 -0
- package/pn-market-web-components/p-d40ff187.entry.js.map +1 -0
- package/pn-market-web-components/{p-f21fdae0.entry.js → p-e42f0fbe.entry.js} +2 -2
- package/pn-market-web-components/{p-f21fdae0.entry.js.map → p-e42f0fbe.entry.js.map} +1 -1
- package/pn-market-web-components/{p-4f2a7d41.entry.js → p-e4c7aaec.entry.js} +2 -2
- package/pn-market-web-components/{p-4f2a7d41.entry.js.map → p-e4c7aaec.entry.js.map} +1 -1
- package/pn-market-web-components/{p-107568aa.entry.js → p-e5345c69.entry.js} +2 -2
- package/pn-market-web-components/p-e5345c69.entry.js.map +1 -0
- package/pn-market-web-components/p-e9501c6f.entry.js +2 -0
- package/pn-market-web-components/p-e9501c6f.entry.js.map +1 -0
- package/pn-market-web-components/{p-fa3ccbfb.entry.js → p-ebaeee5e.entry.js} +2 -2
- package/pn-market-web-components/{p-fa3ccbfb.entry.js.map → p-ebaeee5e.entry.js.map} +1 -1
- package/pn-market-web-components/{p-9de267ec.entry.js → p-f2d0d0cc.entry.js} +2 -2
- package/pn-market-web-components/{p-9de267ec.entry.js.map → p-f2d0d0cc.entry.js.map} +1 -1
- package/pn-market-web-components/{p-da953848.entry.js → p-f62879f6.entry.js} +2 -2
- package/pn-market-web-components/p-f62879f6.entry.js.map +1 -0
- package/pn-market-web-components/{p-ec3fcbf9.entry.js → p-fbc07c7a.entry.js} +2 -2
- package/pn-market-web-components/{p-ec3fcbf9.entry.js.map → p-fbc07c7a.entry.js.map} +1 -1
- package/pn-market-web-components/p-fbe70284.entry.js +2 -0
- package/pn-market-web-components/{p-663e4bb8.entry.js.map → p-fbe70284.entry.js.map} +1 -1
- package/pn-market-web-components/pn-market-web-components.esm.js +1 -1
- package/pn-market-web-components/pn-market-web-components.esm.js.map +1 -1
- package/types/components/input/pn-dropdown-choice-adds-row/pn-dropdown-choice-adds-row.d.ts +1 -0
- package/types/components/widgets/pn-proxio-pricegroup/pn-proxio-pricegroup.d.ts +1 -1
- package/types/components.d.ts +2 -0
- package/umd/standalone-loader-salesforce.js +3 -3
- package/umd/standalone-loader.js +2 -2
- package/cjs/FetchHelper-8d537d38.js.map +0 -1
- package/esm/FetchHelper-03b37a44.js.map +0 -1
- package/pn-market-web-components/p-012ee486.entry.js +0 -2
- package/pn-market-web-components/p-03cb46c2.entry.js +0 -2
- package/pn-market-web-components/p-07253be3.entry.js +0 -2
- package/pn-market-web-components/p-07253be3.entry.js.map +0 -1
- package/pn-market-web-components/p-08a64973.entry.js +0 -2
- package/pn-market-web-components/p-08a64973.entry.js.map +0 -1
- package/pn-market-web-components/p-107568aa.entry.js.map +0 -1
- package/pn-market-web-components/p-10a3c6f4.entry.js.map +0 -1
- package/pn-market-web-components/p-161970d1.entry.js +0 -2
- package/pn-market-web-components/p-161970d1.entry.js.map +0 -1
- package/pn-market-web-components/p-22a65c3e.entry.js.map +0 -1
- package/pn-market-web-components/p-23916c49.entry.js +0 -2
- package/pn-market-web-components/p-23916c49.entry.js.map +0 -1
- package/pn-market-web-components/p-2ac83614.entry.js +0 -2
- package/pn-market-web-components/p-2ac83614.entry.js.map +0 -1
- package/pn-market-web-components/p-2fd40198.entry.js +0 -2
- package/pn-market-web-components/p-2fd40198.entry.js.map +0 -1
- package/pn-market-web-components/p-545ea4ef.entry.js +0 -2
- package/pn-market-web-components/p-5666f0e7.entry.js.map +0 -1
- package/pn-market-web-components/p-655e6f71.entry.js +0 -2
- package/pn-market-web-components/p-657957fc.entry.js +0 -2
- package/pn-market-web-components/p-657957fc.entry.js.map +0 -1
- package/pn-market-web-components/p-663e4bb8.entry.js +0 -2
- package/pn-market-web-components/p-67089fc8.entry.js +0 -2
- package/pn-market-web-components/p-67089fc8.entry.js.map +0 -1
- package/pn-market-web-components/p-716165d2.entry.js.map +0 -1
- package/pn-market-web-components/p-7fdc49d1.entry.js.map +0 -1
- package/pn-market-web-components/p-8ca34ec3.entry.js.map +0 -1
- package/pn-market-web-components/p-914e1d15.entry.js.map +0 -1
- package/pn-market-web-components/p-b7a5fb1b.entry.js +0 -2
- package/pn-market-web-components/p-be6e903e.entry.js +0 -2
- package/pn-market-web-components/p-be6e903e.entry.js.map +0 -1
- package/pn-market-web-components/p-bece6791.entry.js +0 -2
- package/pn-market-web-components/p-bece6791.entry.js.map +0 -1
- package/pn-market-web-components/p-c64cb117.entry.js +0 -2
- package/pn-market-web-components/p-c95def57.js +0 -2
- package/pn-market-web-components/p-c95def57.js.map +0 -1
- package/pn-market-web-components/p-d2109ea6.entry.js.map +0 -1
- package/pn-market-web-components/p-da0c533f.entry.js +0 -2
- package/pn-market-web-components/p-da0c533f.entry.js.map +0 -1
- package/pn-market-web-components/p-da953848.entry.js.map +0 -1
- package/pn-market-web-components/p-db2e2762.entry.js.map +0 -1
- package/pn-market-web-components/p-db2f3f6d.entry.js +0 -2
- package/pn-market-web-components/p-e0f4dc3d.entry.js +0 -2
- package/pn-market-web-components/p-e0f4dc3d.entry.js.map +0 -1
- package/pn-market-web-components/p-e8189227.entry.js +0 -2
- package/pn-market-web-components/p-e8189227.entry.js.map +0 -1
- package/pn-market-web-components/p-e9088d97.entry.js +0 -2
- package/pn-market-web-components/p-e9088d97.entry.js.map +0 -1
- package/pn-market-web-components/p-f8eb860b.entry.js +0 -2
- package/pn-market-web-components/p-fa9ea740.entry.js.map +0 -1
- package/pn-market-web-components/p-fd639f58.entry.js +0 -2
- package/pn-market-web-components/p-fd639f58.entry.js.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pn-proxio-findprice-result.js","sourceRoot":"","sources":["../../../../src/components/widgets/pn-proxio-findprice/pn-proxio-findprice-result.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,CAAC,EAAE,IAAI,EAAE,IAAI,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AAEvE,OAAO,EAAE,YAAY,EAAE,MAAM,sCAAsC,CAAC;AAMpE,MAAM,OAAO,uBAAuB;;oBAC4B,IAAI;4BAClB,IAAI;0BACC,EAAE;;;;2BAItB,EAAE;+BACC,KAAK;iCACJ,KAAK;mCACJ,EAAE;sBACf,EAAE;wBACiB,IAAI;0BAE1B,EAAE;sBACE,EAAE;yBACC,EAAE;uBACJ,EAAE;sBACH,EAAE;oBACU,YAAY,CAAC,IAAI,CAAC,QAAQ,CAAC;;IAEjE,iBAAiB;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EAAE,OAAO,CAAC,eAAe,GACA,CACpC,CAAC;oBACJ,CAAC,CAAC,IAAI,CACJ;YACL,IAAI,CAAC,sBAAsB,CAAC,IAAI,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC,CAAC,CAAC,CACtD,WAAK,IAAI,EAAC,WAAW;gBACnB,WAAK,KAAK,EAAC,eAAe,IAAE,IAAI,CAAC,sBAAsB,CAAC,IAAI,CAAC,IAAI,CAAC,aAAa,CAAC,CAAO,CACnF,CACP,CAAC,CAAC,CAAC,IAAI,CACc,CAErB,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, h, Prop, Host, Watch, State } from '@stencil/core';\nimport { ProxioPriceGroupi18n, ProxioProduct, ProductGenericItem, ProductWeightGroupListItem, ProxioPriceListGroupResponse } from '../pn-proxio-pricegroup/types';\nimport { translations } from '../pn-proxio-pricegroup/translations';\n\n@Component({\n tag: 'pn-proxio-findprice-result',\n styleUrl: 'pn-proxio-findprice-result.scss',\n})\nexport class PnProxioFindPriceResult {\n @Prop({ mutable: true }) item: ProxioPriceListGroupResponse = null;\n @Prop({ mutable: true }) activeweight: number = null;\n @Prop() shownitems: ProxioPriceListGroupResponse[] = [];\n @Prop() Usp1?: string;\n @Prop() Usp2?: string;\n @Prop() Usp3?: string;\n @Prop() description?: string[] = [];\n @Prop() showMeasurement?: boolean = false;\n @Prop() showInternational: boolean = false;\n @Prop() selectedCountrycode: string = '';\n @Prop() market: string = '';\n @Prop({ mutable: true }) language: string = 'sv';\n\n @State() weightText = '';\n @State() linkId: string = '';\n @State() shopLabel: string = '';\n @State() shopUrl: string = '';\n @State() shopId: string = '';\n @State() i18n: ProxioPriceGroupi18n = translations[this.language];\n\n componentWillLoad() {\n this.composeItems();\n }\n\n @Watch('item')\n composeItems() {\n this.shownitems = [this.item];\n }\n\n @Watch('activeweight')\n getPriceString(product: ProxioProduct) {\n if (!product.productWeightGroupList) {\n return null;\n }\n\n const activeIndex = product.productWeightGroupList.findIndex(item => item.item1 === this.activeweight);\n\n let price = '';\n\n if (this.showInternational && this.selectedCountrycode && this.selectedCountrycode !== this.market && product.weightPriceCountryList) {\n let weightPriceCountryList = product.weightPriceCountryList.filter(item => item.item3.includes(this.selectedCountrycode.toUpperCase()));\n\n price = weightPriceCountryList ? weightPriceCountryList[activeIndex]?.item2 : '';\n } else {\n price = product.weightAndPriceList ? product?.weightAndPriceList[activeIndex]?.item2 : '';\n }\n\n return price ? this.i18n.from + price : '';\n }\n\n @Watch('activeweight')\n getProductLink(product: ProxioProduct, productWeightGroupList: ProductWeightGroupListItem[]) {\n if (product.productWeightGroupList) {\n const activeIndex = product.productWeightGroupList.findIndex(item => item.item1 === this.activeweight);\n\n let productId = productWeightGroupList[activeIndex]?.item2;\n let productLink = product.productLink ? product?.productLink : '';\n return productLink ? productLink + (productId ? '?productId=' + productId : '') : '';\n }\n return null;\n }\n\n getDeliveryInformation(product: ProxioProduct) {\n if (!this.showInternational || !product.deliveryDateInternationalInformation) {\n return product.deliveryDateInformation;\n }\n\n const internationalShipment = product?.deliveryDateInternationalInformation?.find(info => info.item1.toLowerCase() === this.selectedCountrycode.toLowerCase());\n\n if (!internationalShipment?.item2 ?? true) {\n return product.deliveryDateInformation;\n }\n\n return internationalShipment.item2;\n }\n\n getInsuranceAmountText(product: ProxioProduct) {\n if (!product.insuranceAmounts) {\n return '';\n }\n\n const insuranceAmount = product?.insuranceAmounts?.find(info => info.item1.toLowerCase() === this.selectedCountrycode.toLowerCase());\n\n if (!insuranceAmount?.item2 ?? true) {\n return '';\n }\n\n return insuranceAmount.item2;\n }\n\n render() {\n return (\n <Host>\n {\n <pn-proxio-productcard>\n <pn-illustration slot=\"illustrationmobile\" illustration={this.item.proxioProduct.productIcon}></pn-illustration>\n <h2 slot=\"title\">{this.item.proxioProduct.productTitle}</h2>\n <pn-proxio-productcard-description\n slot=\"description\"\n heading={this.item.proxioProduct.productPreamble}\n highlight={this.getDeliveryInformation(this.item.proxioProduct)}\n list={this.item.proxioProduct.productDescriptionBulletListItems}\n ></pn-proxio-productcard-description>\n <div slot=\"information\">\n <pn-proxio-productcard-information\n label={this.i18n.labelMaxDimensions}\n information={this.item.proxioProduct.productPackageDimensionsList as ProductGenericItem[]}\n ></pn-proxio-productcard-information>\n <pn-proxio-productcard-information\n label={this.i18n.labelMaxDimensionsRoll}\n information={this.item.proxioProduct.productRollDimensionsList as ProductGenericItem[]}\n ></pn-proxio-productcard-information>\n </div>\n <div slot=\"bottomtags\">\n {this.item.proxioProduct.usp1 ? <pn-titletag color=\"gray50\">{this.item.proxioProduct.usp1}</pn-titletag> : null}\n {this.item.proxioProduct.usp2 ? <pn-titletag color=\"gray50\">{this.item.proxioProduct.usp2}</pn-titletag> : null}\n {this.item.proxioProduct.usp3 ? <pn-titletag color=\"gray50\">{this.item.proxioProduct.usp3}</pn-titletag> : null}\n </div>\n <pn-illustration slot=\"illustration\" illustration={this.item.proxioProduct.productIcon}></pn-illustration>\n <div slot=\"pricelink\">\n <pn-proxio-productcard-pricelink\n price={this.getPriceString(this.item.proxioProduct)}\n link={this.getProductLink(this.item.proxioProduct, this.item.proxioProduct.productWeightGroupList)}\n linktext={this.item.proxioProduct.productLinkText}\n ></pn-proxio-productcard-pricelink>\n {this.item.relatedProxioProducts\n ? this.item.relatedProxioProducts.map(product => (\n <pn-proxio-productcard-pricelink\n price={this.getPriceString(product)}\n link={product.productLink}\n linktext={product.productLinkText}\n ></pn-proxio-productcard-pricelink>\n ))\n : null}\n </div>\n {this.getInsuranceAmountText(this.item.proxioProduct) ? (\n <div slot=\"insurance\">\n <div class=\"insurance-box\">{this.getInsuranceAmountText(this.item.proxioProduct)}</div>\n </div>\n ) : null}\n </pn-proxio-productcard>\n }\n </Host>\n );\n }\n}\n"]}
|
|
1
|
+
{"version":3,"file":"pn-proxio-findprice-result.js","sourceRoot":"","sources":["../../../../src/components/widgets/pn-proxio-findprice/pn-proxio-findprice-result.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,CAAC,EAAE,IAAI,EAAE,IAAI,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AAEvE,OAAO,EAAE,YAAY,EAAE,MAAM,sCAAsC,CAAC;AAMpE,MAAM,OAAO,uBAAuB;;oBAC4B,IAAI;4BAClB,IAAI;0BACC,EAAE;;;;2BAItB,EAAE;+BACC,KAAK;iCACJ,KAAK;mCACJ,EAAE;sBACf,EAAE;wBACiB,IAAI;0BAE1B,EAAE;sBACE,EAAE;yBACC,EAAE;uBACJ,EAAE;sBACH,EAAE;oBACU,YAAY,CAAC,IAAI,CAAC,QAAQ,CAAC;;IAEjE,iBAAiB;QACf,IAAI,CAAC,YAAY,EAAE,CAAC;IACtB,CAAC;IAGD,YAAY;QACV,IAAI,CAAC,UAAU,GAAG,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IAChC,CAAC;IAGD,cAAc,CAAC,OAAsB;QACnC,IAAI,CAAC,OAAO,CAAC,sBAAsB,EAAE,CAAC;YACpC,OAAO,IAAI,CAAC;QACd,CAAC;QAED,MAAM,WAAW,GAAG,OAAO,CAAC,sBAAsB,CAAC,SAAS,CAAC,IAAI,CAAC,EAAE,CAAC,IAAI,CAAC,KAAK,KAAK,IAAI,CAAC,YAAY,CAAC,CAAC;QAEvG,IAAI,KAAK,GAAG,EAAE,CAAC;QAEf,IAAI,IAAI,CAAC,iBAAiB,IAAI,IAAI,CAAC,mBAAmB,IAAI,IAAI,CAAC,mBAAmB,KAAK,IAAI,CAAC,MAAM,IAAI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AAC,aAAa,CAAC,EACnD,IAAI,EAAE,IAAI,CAAC,cAAc,CAAC,IAAI,CAAC,IAAI,CAAC,aAAa,EAAE,IAAI,CAAC,IAAI,CAAC,aAAa,CAAC,sBAAsB,CAAC,EAClG,QAAQ,EAAE,IAAI,CAAC,IAAI,CAAC,aAAa,CAAC,eAAe,GAChB;gBAClC,IAAI,CAAC,IAAI,CAAC,qBAAqB;oBAC9B,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,qBAAqB,CAAC,GAAG,CAAC,OAAO,CAAC,EAAE,CAAC,CAC7C,uCACE,KAAK,EAAE,IAAI,CAAC,cAAc,CAAC,OAAO,CAAC,EACnC,IAAI,EAAE,OAAO,CAAC,WAAW,EACzB,QAAQ,EAAE,OAAO,CAAC,eAAe,GACA,CACpC,CAAC;oBACJ,CAAC,CAAC,IAAI,CACJ;YACL,IAAI,CAAC,sBAAsB,CAAC,IAAI,CAAC,IAAI,CAAC,aAAa,CAAC,CAAC,CAAC,CAAC,CACtD,WAAK,IAAI,EAAC,WAAW;gBACnB,WAAK,KAAK,EAAC,eAAe,IAAE,IAAI,CAAC,sBAAsB,CAAC,IAAI,CAAC,IAAI,CAAC,aAAa,CAAC,CAAO,CACnF,CACP,CAAC,CAAC,CAAC,IAAI,CACc,CAErB,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, h, Prop, Host, Watch, State } from '@stencil/core';\nimport { ProxioPriceGroupi18n, ProxioProduct, ProductGenericItem, ProductWeightGroupListItem, ProxioPriceListGroupResponse } from '../pn-proxio-pricegroup/types';\nimport { translations } from '../pn-proxio-pricegroup/translations';\n\n@Component({\n tag: 'pn-proxio-findprice-result',\n styleUrl: 'pn-proxio-findprice-result.scss',\n})\nexport class PnProxioFindPriceResult {\n @Prop({ mutable: true }) item: ProxioPriceListGroupResponse = null;\n @Prop({ mutable: true }) activeweight: number = null;\n @Prop() shownitems: ProxioPriceListGroupResponse[] = [];\n @Prop() Usp1?: string;\n @Prop() Usp2?: string;\n @Prop() Usp3?: string;\n @Prop() description?: string[] = [];\n @Prop() showMeasurement?: boolean = false;\n @Prop() showInternational: boolean = false;\n @Prop() selectedCountrycode: string = '';\n @Prop() market: string = '';\n @Prop({ mutable: true }) language: string = 'sv';\n\n @State() weightText = '';\n @State() linkId: string = '';\n @State() shopLabel: string = '';\n @State() shopUrl: string = '';\n @State() shopId: string = '';\n @State() i18n: ProxioPriceGroupi18n = translations[this.language];\n\n componentWillLoad() {\n this.composeItems();\n }\n\n @Watch('item')\n composeItems() {\n this.shownitems = [this.item];\n }\n\n @Watch('activeweight')\n getPriceString(product: ProxioProduct) {\n if (!product.productWeightGroupList) {\n return null;\n }\n\n const activeIndex = product.productWeightGroupList.findIndex(item => item.item1 === this.activeweight);\n\n let price = '';\n\n if (this.showInternational && this.selectedCountrycode && this.selectedCountrycode !== this.market && product.weightPriceCountryList) {\n let weightPriceCountryList = product.weightPriceCountryList.filter(item => item.item3.includes(this.selectedCountrycode.toUpperCase()));\n\n price = weightPriceCountryList ? weightPriceCountryList[activeIndex]?.item2 : '';\n } else {\n price = product.weightAndPriceList ? product?.weightAndPriceList[activeIndex]?.item2 : '';\n }\n\n return price ? this.i18n.from + price : '';\n }\n\n @Watch('activeweight')\n getProductLink(product: ProxioProduct, productWeightGroupList: ProductWeightGroupListItem[]) {\n if (product.productWeightGroupList) {\n const activeIndex = product.productWeightGroupList.findIndex(item => item.item1 === this.activeweight);\n\n let productId = productWeightGroupList[activeIndex]?.item2;\n let productLink = product.productLink ? product?.productLink : '';\n return productLink ? productLink + (productId ? '?productId=' + productId : '') : '';\n }\n return null;\n }\n\n getDeliveryInformation(product: ProxioProduct) {\n if (!this.showInternational || !product.deliveryDateInternationalInformation) {\n return product.deliveryDateInformation;\n }\n\n const internationalShipment = product?.deliveryDateInternationalInformation?.find(info => info.item1.toLowerCase() === this.selectedCountrycode.toLowerCase());\n\n if (!internationalShipment?.item2 ?? true) {\n return product.deliveryDateInformation;\n }\n\n return internationalShipment.item2;\n }\n\n getInsuranceAmountText(product: ProxioProduct) {\n if (!product.insuranceAmounts) {\n return '';\n }\n\n const insuranceAmount = product?.insuranceAmounts?.find(info => info.item1.toLowerCase() === this.selectedCountrycode.toLowerCase());\n\n if (!insuranceAmount?.item2 ?? true) {\n return '';\n }\n\n return insuranceAmount.item2;\n }\n\n render() {\n return (\n <Host>\n {\n <pn-proxio-productcard>\n <pn-illustration slot=\"illustrationmobile\" illustration={this.item.proxioProduct.productIcon}></pn-illustration>\n <h2 slot=\"title\">{this.item.proxioProduct.productTitle}</h2>\n <pn-proxio-productcard-description\n slot=\"description\"\n heading={this.item.proxioProduct.productPreamble}\n highlight={this.getDeliveryInformation(this.item.proxioProduct)}\n list={this.item.proxioProduct.productDescriptionBulletListItems}\n ></pn-proxio-productcard-description>\n <div slot=\"information\">\n <pn-proxio-productcard-information\n label={this.i18n.labelMaxDimensions}\n information={this.item.proxioProduct.productPackageDimensionsList as ProductGenericItem[]}\n ></pn-proxio-productcard-information>\n <pn-proxio-productcard-information\n label={this.i18n.labelMaxDimensionsRoll}\n information={this.item.proxioProduct.productRollDimensionsList as ProductGenericItem[]}\n ></pn-proxio-productcard-information>\n </div>\n <div slot=\"bottomtags\">\n {this.item.proxioProduct.usp1 ? <pn-titletag color=\"gray50\">{this.item.proxioProduct.usp1}</pn-titletag> : null}\n {this.item.proxioProduct.usp2 ? <pn-titletag color=\"gray50\">{this.item.proxioProduct.usp2}</pn-titletag> : null}\n {this.item.proxioProduct.usp3 ? <pn-titletag color=\"gray50\">{this.item.proxioProduct.usp3}</pn-titletag> : null}\n </div>\n <pn-illustration slot=\"illustration\" illustration={this.item.proxioProduct.productIcon}></pn-illustration>\n <div slot=\"pricelink\">\n <pn-proxio-productcard-pricelink\n price={this.getPriceString(this.item.proxioProduct)}\n link={this.getProductLink(this.item.proxioProduct, this.item.proxioProduct.productWeightGroupList)}\n linktext={this.item.proxioProduct.productLinkText}\n ></pn-proxio-productcard-pricelink>\n {this.item.relatedProxioProducts\n ? this.item.relatedProxioProducts.map(product => (\n <pn-proxio-productcard-pricelink\n price={this.getPriceString(product)}\n link={product.productLink}\n linktext={product.productLinkText}\n ></pn-proxio-productcard-pricelink>\n ))\n : null}\n </div>\n {this.getInsuranceAmountText(this.item.proxioProduct) ? (\n <div slot=\"insurance\">\n <div class=\"insurance-box\">{this.getInsuranceAmountText(this.item.proxioProduct)}</div>\n </div>\n ) : null}\n </pn-proxio-productcard>\n }\n </Host>\n );\n }\n}\n"]}
|
|
@@ -12,7 +12,6 @@ import clouds from "./img/clouds.svg";
|
|
|
12
12
|
import { trash_can } from "pn-design-assets/pn-assets/icons.js";
|
|
13
13
|
export class PnProxioFindPrice {
|
|
14
14
|
constructor() {
|
|
15
|
-
this.fetchHelper = new FetchHelper('proxiopricegroups');
|
|
16
15
|
this.endpoint = null;
|
|
17
16
|
this.language = 'da';
|
|
18
17
|
this.market = 'dk';
|
|
@@ -28,6 +27,7 @@ export class PnProxioFindPrice {
|
|
|
28
27
|
this.sizecategory = { value: '', name: '', icon: '', unit: '' };
|
|
29
28
|
this.data = { proxioProducts: [], shipmentCountries: [] };
|
|
30
29
|
}
|
|
30
|
+
fetchHelper = new FetchHelper('proxiopricegroups');
|
|
31
31
|
componentWillLoad() {
|
|
32
32
|
this.setInitialValues().then(() => {
|
|
33
33
|
this.init();
|
|
@@ -36,7 +36,7 @@ export class PnProxioFindPrice {
|
|
|
36
36
|
async setInitialValues(href = window.location.href) {
|
|
37
37
|
const marketWebContextService = new MarketWebContextService(href);
|
|
38
38
|
const environment = await marketWebContextService.getEnvironmentName();
|
|
39
|
-
if (!this.endpoint &&
|
|
39
|
+
if (!this.endpoint && environment?.indexOf('local') === -1) {
|
|
40
40
|
const market = await marketWebContextService.getMarket();
|
|
41
41
|
this.market = this.market ? this.market : market;
|
|
42
42
|
this.endpoint = await marketWebContextService.getEndpoint(environment, market);
|
|
@@ -92,7 +92,6 @@ export class PnProxioFindPrice {
|
|
|
92
92
|
}
|
|
93
93
|
}
|
|
94
94
|
filterItems() {
|
|
95
|
-
var _a, _b;
|
|
96
95
|
const sizeItemData = this.data.proxioProducts.filter(item => {
|
|
97
96
|
return item.proxioProduct.productWeightGroupList.some(weightGroup => {
|
|
98
97
|
return weightGroup.item3.includes(this.sizecategory.value);
|
|
@@ -102,25 +101,23 @@ export class PnProxioFindPrice {
|
|
|
102
101
|
return;
|
|
103
102
|
}
|
|
104
103
|
const comparisonWeight = this.weight.value;
|
|
105
|
-
let weightFilteredData = sizeItemData
|
|
104
|
+
let weightFilteredData = sizeItemData?.filter(item => {
|
|
106
105
|
return item.proxioProduct.productWeightGroupList.some(weightGroup => {
|
|
107
106
|
return weightGroup.item1 === comparisonWeight;
|
|
108
107
|
});
|
|
109
108
|
});
|
|
110
|
-
let isInternational = this.showInternational && (
|
|
109
|
+
let isInternational = this.showInternational && (this.countrycodevalue?.trim() !== '' ?? false);
|
|
111
110
|
if (isInternational) {
|
|
112
|
-
weightFilteredData = weightFilteredData
|
|
111
|
+
weightFilteredData = weightFilteredData?.filter(item => item.proxioProduct.weightPriceCountryList.some(countryItem => countryItem.item3.includes(this.countrycodevalue.toUpperCase())));
|
|
113
112
|
}
|
|
114
113
|
weightFilteredData = this.sortWeightItems(weightFilteredData, isInternational);
|
|
115
114
|
this.filteredItems = weightFilteredData;
|
|
116
115
|
}
|
|
117
116
|
parseFloatFromString(text) {
|
|
118
|
-
|
|
119
|
-
return parseFloat((_a = text === null || text === void 0 ? void 0 : text.replace(/[^\d\.\,]*/g, '')) !== null && _a !== void 0 ? _a : 100000);
|
|
117
|
+
return parseFloat(text?.replace(/[^\d\.\,]*/g, '') ?? 100000);
|
|
120
118
|
}
|
|
121
119
|
sortWeightItems(weightFilteredData, isInternational) {
|
|
122
|
-
|
|
123
|
-
(_a = weightFilteredData === null || weightFilteredData === void 0 ? void 0 : weightFilteredData.sort((a, b) => {
|
|
120
|
+
weightFilteredData?.sort((a, b) => {
|
|
124
121
|
let aNumber = this.getSortNumber(a, isInternational);
|
|
125
122
|
let bNumber = this.getSortNumber(b, isInternational);
|
|
126
123
|
if (aNumber && bNumber) {
|
|
@@ -133,34 +130,31 @@ export class PnProxioFindPrice {
|
|
|
133
130
|
return 1;
|
|
134
131
|
}
|
|
135
132
|
return 0;
|
|
136
|
-
})
|
|
133
|
+
}) ?? [];
|
|
137
134
|
return weightFilteredData;
|
|
138
135
|
}
|
|
139
136
|
getSortNumber(proxioPriceListGroupResponseItem, isInternational) {
|
|
140
|
-
|
|
141
|
-
let index = (_c = (_b = (_a = proxioPriceListGroupResponseItem === null || proxioPriceListGroupResponseItem === void 0 ? void 0 : proxioPriceListGroupResponseItem.proxioProduct) === null || _a === void 0 ? void 0 : _a.productWeightGroupList) === null || _b === void 0 ? void 0 : _b.findIndex(weightGroup => weightGroup.item1 === this.weight.value)) !== null && _c !== void 0 ? _c : 0;
|
|
137
|
+
let index = proxioPriceListGroupResponseItem?.proxioProduct?.productWeightGroupList?.findIndex(weightGroup => weightGroup.item1 === this.weight.value) ?? 0;
|
|
142
138
|
if (index < 0) {
|
|
143
139
|
index = 0;
|
|
144
140
|
}
|
|
145
|
-
let pricevalue =
|
|
141
|
+
let pricevalue = proxioPriceListGroupResponseItem?.proxioProduct?.weightAndPriceList[index]?.item2?.toLowerCase() ?? '';
|
|
146
142
|
if (isInternational) {
|
|
147
|
-
let weightPriceCurrentCountryList =
|
|
148
|
-
pricevalue =
|
|
143
|
+
let weightPriceCurrentCountryList = proxioPriceListGroupResponseItem?.proxioProduct?.weightPriceCountryList?.filter(countryItem => countryItem.item3.includes(this.countrycodevalue.toUpperCase()));
|
|
144
|
+
pricevalue = weightPriceCurrentCountryList[index]?.item2?.toLowerCase() ?? '';
|
|
149
145
|
}
|
|
150
146
|
let sortNumber = this.parseFloatFromString(pricevalue);
|
|
151
147
|
return sortNumber;
|
|
152
148
|
}
|
|
153
149
|
resetFilters() {
|
|
154
|
-
var _a, _b, _c;
|
|
155
150
|
this.weight = { value: 0, name: '' };
|
|
156
151
|
this.sizecategory = sizeCategories.filter(x => x.value === 'S')[0];
|
|
157
152
|
this.weightvalue = 0;
|
|
158
|
-
this.countrycodevalue =
|
|
153
|
+
this.countrycodevalue = this.data?.shipmentCountries[0]?.countryCode ?? this.market;
|
|
159
154
|
}
|
|
160
155
|
getWeights() {
|
|
161
|
-
var _a;
|
|
162
156
|
let weightListName = this.market + this.weightListName;
|
|
163
|
-
let marketWeightsArray =
|
|
157
|
+
let marketWeightsArray = weights[weightListName] ?? { S: [], M: [], L: [] };
|
|
164
158
|
let marketWeights = marketWeightsArray[this.sizecategory.unit];
|
|
165
159
|
let isInternationalWeights = this.maxAbroadKg != 0 && this.countrycodevalue.toLowerCase() !== this.market.toLowerCase();
|
|
166
160
|
marketWeights = isInternationalWeights ? marketWeights.filter(number => number.value / 1000 <= this.maxAbroadKg) : marketWeights;
|
|
@@ -172,7 +166,6 @@ export class PnProxioFindPrice {
|
|
|
172
166
|
this.countrycodevalue = countryCode;
|
|
173
167
|
}
|
|
174
168
|
render() {
|
|
175
|
-
var _a, _b;
|
|
176
169
|
return (h("div", { key: '68c83e3f592af3966aa9587bba3774e0dfef55f5', class: "findprice-form" }, h("div", { key: 'a576283df7229228c385cf59343575827d267186', class: "findprice-form-wrapper" }, h("h4", { key: '1a1beac884093350be6c33ef8c70d320526a1ed6', class: "findprice__heading" }, state.i18n.sizeheading), h("div", { key: '2aeb792414a3a72995833c39d0a6f628b7e9ed23', class: "sizecategory" }, h("table", { key: 'e43dbe8d7556b7bcadcba4fa420b060ce1be2a31', class: "sizeTable" }, h("img", { key: 'e0ebf6910f666aa5a94a7ee5250572ef0cc45677', id: "clouds", src: clouds }), h("tr", { key: 'ae9144b60778e1c9b195eb877aa7145f0dfdf234' }, h("td", { key: 'b08e2084c61b68c2a780f94d09ec2e553fea416e' }, h("img", { key: 'd554baed204b69b28c1cc5e9221ce66c9ed48597', class: "firstCell", src: person })), h("td", { key: 'd63e424e4698f95e3db0379067471cbb85b709aa' }, h("img", { key: '908291bd5b69fbde4fa06082b43269e46b8e0a91', src: S })), this.showMedium ? (h("td", null, h("img", { src: M }))) : null, h("td", { key: 'b27388e528f94893a37320b996c0b4410b35fb71' }, h("img", { key: '62a481e1583c8012e8086bbb892f254cc934ff14', src: L }))), h("tr", { key: 'dbd684e390a8e2e9e6f8163b66e0d1c35e1a82bb' }, h("td", { key: 'def38fa0d80de07fd36d6f4d014906c42df09380' }), sizeCategories.map(sizeCategory => !this.showMedium && sizeCategory.value === 'M' ? null : (h("td", null, h("pn-radio-button", { id: 'findpricecategory-' + sizeCategory.value, radioid: sizeCategory.value, value: sizeCategory.value, name: "sizecategory", checked: sizeCategory.value === this.sizecategory.value, onChange: () => {
|
|
177
170
|
this.sizecategory = sizeCategories.filter(x => x.value === sizeCategory.value)[0];
|
|
178
171
|
this.weight = { value: 0, name: '' };
|
|
@@ -180,7 +173,7 @@ export class PnProxioFindPrice {
|
|
|
180
173
|
} }))))))), h("h4", { key: 'f38ab55173f027e46b0676b9d87617ae3f0eb9b0', class: "findprice__heading findprice__subheading" }, state.i18n.weightheading), this.sizecategory.value && this.getWeights() ? (h("div", { class: "weightoption" }, h("div", { class: "weightoption-content" }, this.getWeights().map(wght => (h("pn-choice-button", { id: 'findpriceweight-' + wght.value, choiceid: this.sizecategory.value + wght.value, name: "weight", type: "radio", value: !this.weight.value ? 0 : this.getWeights().findIndex(x => x.value === this.weightvalue), checked: wght.value === this.weight.value, onChange: () => {
|
|
181
174
|
this.weight = this.getWeights().filter(x => x.value === wght.value)[0];
|
|
182
175
|
this.weightvalue = this.weight.value;
|
|
183
|
-
} }, wght.name)))))) : null, this.showInternational && (
|
|
176
|
+
} }, wght.name)))))) : null, this.showInternational && (this.data?.shipmentCountries ?? false) ? (h("div", { class: "shipmentcountry" }, h("h4", { class: "shipmentcountry-header" }, state.i18n.countryToSendTo), h("div", { class: "shipmentcountry-select-container" }, h("svg", { class: "arrow", width: "18", height: "10", viewBox: "0 0 18 10", fill: "none", xmlns: "http://www.w3.org/2000/svg" }, h("path", { "fill-rule": "evenodd", "clip-rule": "evenodd", d: "M9.70711 9.70711C9.31658 10.0976 8.68342 10.0976 8.29289 9.70711L0.292892 1.70711C-0.0976315 1.31658 -0.0976315 0.683417 0.292892 0.292893C0.683418 -0.0976315 1.31658 -0.0976315 1.70711 0.292893L9 7.58579L16.2929 0.292893C16.6834 -0.0976315 17.3166 -0.0976315 17.7071 0.292893C18.0976 0.683417 18.0976 1.31658 17.7071 1.70711L9.70711 9.70711Z" })), h("select", { name: "shipmentCountry-select", id: "proxio-shipmentcountry", onChange: this.handleDropdownChange.bind(this) }, this.data.shipmentCountries.map(item => (h("option", { selected: item.countryCode.toLowerCase() === this.countrycodevalue.toLowerCase(), value: item.countryCode }, item.countryName))))))) : null, h("div", { key: 'b001f2646f4ddbb5265c9152c4c0cb29c57e7b16', class: "findprice__clear-all-filters", role: "button" }, h("div", { key: '315fc72758b23fb5d6d3998822e12aa7f56e4f0c', class: "findprice__clear-all-filters__btn", onClick: () => this.resetFilters() }, h("pn-icon", { key: '234be7673fe3ce7b563c1569c2d61e2581567a92', icon: trash_can, color: "blue700" }), h("span", { key: '091e286b429ccac6056ac9bd8273beefe290aa78', class: "clear-all-filters__text" }, state.i18n.clearFilterButton)))), this.filteredItems && this.filteredItems.length > 0 ? (h("div", { class: "resultlist" }, state.i18n.resultlistheading ? h("div", { class: "resultHeading" }, state.i18n.resultlistheading) : null, this.filteredItems.map((item) => (h("div", null, h("pn-proxio-findprice-result", { activeweight: this.weight.value, item: item, language: this.language, "selected-countrycode": this.countrycodevalue, "show-international": this.showInternational, market: this.market })))))) : this.weightvalue !== 0 ? (h("h4", { class: "resultHeading" }, state.i18n.noResultMessage)) : null));
|
|
184
177
|
}
|
|
185
178
|
static get is() { return "pn-proxio-findprice"; }
|
|
186
179
|
static get originalStyleUrls() {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pn-proxio-findprice.js","sourceRoot":"","sources":["../../../../src/components/widgets/pn-proxio-findprice/pn-proxio-findprice.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,CAAC,EAAE,IAAI,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AACjE,OAAO,EAAE,YAAY,EAAE,OAAO,EAAE,MAAM,oCAAoC,CAAC;AAS3E,OAAO,EAAE,uBAAuB,EAAE,MAAM,0CAA0C,CAAC;AACnF,OAAO,EAAE,OAAO,EAAE,cAAc,EAAE,MAAM,WAAW,CAAC;AACpD,OAAO,EAAE,WAAW,EAAE,MAAM,8BAA8B,CAAC;AAC3D,OAAO,EAAE,KAAK,EAAE,MAAM,6BAA6B,CAAC;AACpD,OAAO,CAAC,MAAM,yBAAyB,CAAC;AACxC,OAAO,CAAC,MAAM,0BAA0B,CAAC;AACzC,OAAO,CAAC,MAAM,yBAAyB,CAAC;AACxC,OAAO,MAAM,MAAM,4BAA4B,CAAC;AAChD,OAAO,MAAM,MAAM,kBAAkB,CAAC;AACtC,OAAO,EAAE,SAAS,EAAE,MAAM,qCAAqC,CAAC;AAMhE,MAAM,OAAO,iBAAiB;;QAiB5B,gBAAW,GAAG,IAAI,WAAW,CAAC,mBAAmB,CAAC,CAAC;wBAhBP,IAAI;wBACJ,IAAI;sBACN,IAAI;0BAChB,KAAK;iCACE,KAAK;2BACZ,CAAC;8BACE,EAAE;qBAEV,KAAK;6BAC2B,EAAE;sBACX,EAAE,KAAK,EAAE,CAAC,EAAE,IAAI,EAAE,EAAE,EAAkC;2BACvE,CAA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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, h, Prop, State, Watch } from '@stencil/core';\nimport { translations, markets } from './pn-proxio-findprice-translations';\nimport { ProxioPriceListGroupResponse } from '../pn-proxio-pricegroup/types';\nimport {\n ProxioPriceListGroupsResponse,\n ProxioProductFindPriceWeight,\n ProxioProductFindPriceSizeCategory,\n ProxioProductFindPriceMarket,\n ProxioFindPricei18n,\n} from './pn-proxio-findprice-types';\nimport { MarketWebContextService } from '../../../globals/MarketWebContextService';\nimport { weights, sizeCategories } from './data.js';\nimport { FetchHelper } from '../../../globals/FetchHelper';\nimport { state } from './pn-proxio-findprice-store';\nimport S from './img/small-package.svg';\nimport M from './img/medium-package.svg';\nimport L from './img/large-package.svg';\nimport person from './img/postnord-person2.svg';\nimport clouds from './img/clouds.svg';\nimport { trash_can } from 'pn-design-assets/pn-assets/icons.js';\n\n@Component({\n tag: 'pn-proxio-findprice',\n styleUrl: 'pn-proxio-findprice.scss',\n})\nexport class PnProxioFindPrice {\n @Prop({ mutable: true }) endpoint: string = null;\n @Prop({ mutable: true }) language: string = 'da';\n @Prop({ mutable: true }) market: string = 'dk';\n @Prop() showMedium: boolean = false;\n @Prop() showInternational: boolean = false;\n @Prop() maxAbroadKg: number = 0;\n @Prop() weightListName: string = '';\n\n @Prop() cache: boolean = false;\n @State() filteredItems: ProxioPriceListGroupResponse[] = [];\n @State() weight: ProxioProductFindPriceWeight = { value: 0, name: '' } as ProxioProductFindPriceWeight;\n @State() weightvalue: number = 0;\n @State() countrycodevalue: string = '';\n @State() sizecategory: ProxioProductFindPriceSizeCategory = { value: '', name: '', icon: '', unit: '' } as ProxioProductFindPriceSizeCategory;\n @State() data: ProxioPriceListGroupsResponse = { proxioProducts: [], shipmentCountries: [] } as ProxioPriceListGroupsResponse;\n\n fetchHelper = new FetchHelper('proxiopricegroups');\n\n componentWillLoad() {\n this.setInitialValues().then(() => {\n this.init();\n });\n }\n\n async setInitialValues(href = window.location.href) {\n const marketWebContextService = new MarketWebContextService(href);\n const environment = await marketWebContextService.getEnvironmentName();\n\n if (!this.endpoint && environment?.indexOf('local') === -1) {\n const market = await marketWebContextService.getMarket();\n this.market = this.market ? this.market : market;\n this.endpoint = await marketWebContextService.getEndpoint(environment, market);\n }\n\n if (!this.endpoint) {\n this.endpoint = '';\n }\n\n if (this.countrycodevalue === '') {\n this.countrycodevalue = this.market.toLowerCase();\n }\n }\n\n init() {\n this.setState();\n this.fetchData().then(() => {\n this.getDataSource();\n });\n }\n\n async getDataSource() {\n try {\n this.sizecategory = (sizeCategories as ProxioProductFindPriceSizeCategory[]).filter(x => x.value === 'S')[0];\n this.filterItems();\n } catch (e) {\n console.log('Unable to parse data');\n }\n }\n\n async fetchData() {\n if (!this.market || !this.language) {\n return;\n }\n const endpoint = this.endpoint.lastIndexOf('/') === this.endpoint.length - 1 ? this.endpoint.substring(0, this.endpoint.length - 1) : this.endpoint;\n const fetchUrl = `${endpoint}/api/proxio/price-list-groups?market=${this.market}&language=${this.language}&cached=${this.cache}`;\n //const fetchUrl = `https://localhost:51547/api/proxio/price-list-groups?market=${this.market}&language=${this.language}&cached=${this.cache}`;\n\n const data = (await this.fetchHelper.fetchJson(\n fetchUrl,\n {\n mode: 'cors',\n },\n false,\n this.onFetchData.bind(this),\n )) as any;\n\n if (data) {\n this.data = data as ProxioPriceListGroupsResponse;\n this.data.proxioProducts = data.proxioProducts as ProxioPriceListGroupResponse[];\n }\n this.filterItems();\n }\n\n onFetchData(data) {\n this.data = data;\n }\n\n @Watch('market')\n @Watch('language')\n setState() {\n this.market = this.market ? this.market : 'dk';\n if (this.market) {\n state.market = markets[this.market] as ProxioProductFindPriceMarket;\n }\n if (this.language && translations[this.language]) {\n state.i18n = translations[this.language] as ProxioFindPricei18n;\n }\n }\n\n @Watch('sizecategory')\n @Watch('weightvalue')\n @Watch('countrycodevalue')\n filterItems() {\n const sizeItemData = this.data.proxioProducts.filter(item => {\n return item.proxioProduct.productWeightGroupList.some(weightGroup => {\n return weightGroup.item3.includes(this.sizecategory.value);\n });\n });\n\n if (!this.weight) {\n return;\n }\n const comparisonWeight = this.weight.value;\n\n let weightFilteredData = sizeItemData?.filter(item => {\n return item.proxioProduct.productWeightGroupList.some(weightGroup => {\n return weightGroup.item1 === comparisonWeight;\n });\n });\n\n let isInternational = this.showInternational && (this.countrycodevalue?.trim() !== '' ?? false);\n\n if (isInternational) {\n weightFilteredData = weightFilteredData?.filter(item =>\n item.proxioProduct.weightPriceCountryList.some(countryItem => countryItem.item3.includes(this.countrycodevalue.toUpperCase())),\n );\n }\n\n weightFilteredData = this.sortWeightItems(weightFilteredData, isInternational);\n\n this.filteredItems = weightFilteredData;\n }\n\n parseFloatFromString(text) {\n return parseFloat(text?.replace(/[^\\d\\.\\,]*/g, '') ?? 100000);\n }\n\n sortWeightItems(weightFilteredData: ProxioPriceListGroupResponse[], isInternational: boolean) {\n weightFilteredData?.sort((a, b) => {\n let aNumber = this.getSortNumber(a, isInternational);\n let bNumber = this.getSortNumber(b, isInternational);\n\n if (aNumber && bNumber) {\n return aNumber - bNumber;\n }\n\n if (aNumber < bNumber) {\n return -1;\n }\n\n if (aNumber > bNumber) {\n return 1;\n }\n\n return 0;\n }) ?? [];\n\n return weightFilteredData;\n }\n\n getSortNumber(proxioPriceListGroupResponseItem: ProxioPriceListGroupResponse, isInternational: boolean) {\n let index = proxioPriceListGroupResponseItem?.proxioProduct?.productWeightGroupList?.findIndex(weightGroup => weightGroup.item1 === this.weight.value) ?? 0;\n\n if (index < 0) {\n index = 0;\n }\n\n let pricevalue = proxioPriceListGroupResponseItem?.proxioProduct?.weightAndPriceList[index]?.item2?.toLowerCase() ?? '';\n\n if (isInternational) {\n let weightPriceCurrentCountryList = proxioPriceListGroupResponseItem?.proxioProduct?.weightPriceCountryList?.filter(countryItem =>\n countryItem.item3.includes(this.countrycodevalue.toUpperCase()),\n );\n\n pricevalue = weightPriceCurrentCountryList[index]?.item2?.toLowerCase() ?? '';\n }\n\n let sortNumber = this.parseFloatFromString(pricevalue);\n\n return sortNumber;\n }\n\n resetFilters() {\n this.weight = { value: 0, name: '' } as ProxioProductFindPriceWeight;\n this.sizecategory = (sizeCategories as ProxioProductFindPriceSizeCategory[]).filter(x => x.value === 'S')[0];\n this.weightvalue = 0;\n this.countrycodevalue = this.data?.shipmentCountries[0]?.countryCode ?? this.market;\n }\n\n getWeights() {\n let weightListName = this.market + this.weightListName;\n let marketWeightsArray = weights[weightListName] ?? { S: [], M: [], L: [] };\n let marketWeights = marketWeightsArray[this.sizecategory.unit];\n let isInternationalWeights = this.maxAbroadKg != 0 && this.countrycodevalue.toLowerCase() !== this.market.toLowerCase();\n marketWeights = isInternationalWeights ? marketWeights.filter(number => number.value / 1000 <= this.maxAbroadKg) : marketWeights;\n\n return marketWeights;\n }\n\n handleDropdownChange(event: Event) {\n const target = event.target as HTMLInputElement;\n const countryCode = target.value;\n this.countrycodevalue = countryCode;\n }\n\n render() {\n return (\n <div class=\"findprice-form\">\n <div class=\"findprice-form-wrapper\">\n <h4 class=\"findprice__heading\">{state.i18n.sizeheading}</h4>\n <div class=\"sizecategory\">\n <table class=\"sizeTable\">\n <img id=\"clouds\" src={clouds}></img>\n <tr>\n <td>\n <img class=\"firstCell\" src={person}></img>\n </td>\n <td>\n <img src={S}></img>\n </td>\n {this.showMedium ? (\n <td>\n <img src={M}></img>\n </td>\n ) : null}\n <td>\n <img src={L}></img>\n </td>\n </tr>\n <tr>\n <td></td>\n {sizeCategories.map(sizeCategory =>\n !this.showMedium && sizeCategory.value === 'M' ? null : (\n <td>\n <pn-radio-button\n id={'findpricecategory-' + sizeCategory.value}\n radioid={sizeCategory.value}\n value={sizeCategory.value}\n name=\"sizecategory\"\n checked={sizeCategory.value === this.sizecategory.value}\n onChange={() => {\n this.sizecategory = (sizeCategories as ProxioProductFindPriceSizeCategory[]).filter(x => x.value === sizeCategory.value)[0];\n this.weight = { value: 0, name: '' } as ProxioProductFindPriceWeight;\n this.weightvalue = this.weight.value;\n }}\n ></pn-radio-button>\n </td>\n ),\n )}\n </tr>\n </table>\n </div>\n\n <h4 class=\"findprice__heading findprice__subheading\">{state.i18n.weightheading}</h4>\n {this.sizecategory.value && this.getWeights() ? (\n <div class=\"weightoption\">\n {\n <div class=\"weightoption-content\">\n {this.getWeights().map(wght => (\n <pn-choice-button\n id={'findpriceweight-' + wght.value}\n choiceid={this.sizecategory.value + wght.value}\n name=\"weight\"\n type=\"radio\"\n value={!this.weight.value ? 0 : this.getWeights().findIndex(x => x.value === this.weightvalue)}\n checked={wght.value === this.weight.value}\n onChange={() => {\n this.weight = (this.getWeights() as ProxioProductFindPriceWeight[]).filter(x => x.value === wght.value)[0];\n this.weightvalue = this.weight.value;\n }}\n >\n {wght.name}\n </pn-choice-button>\n ))}\n </div>\n }\n </div>\n ) : null}\n\n {this.showInternational && (this.data?.shipmentCountries ?? false) ? (\n <div class=\"shipmentcountry\">\n <h4 class=\"shipmentcountry-header\">{state.i18n.countryToSendTo}</h4>\n <div class=\"shipmentcountry-select-container\">\n <svg class=\"arrow\" width=\"18\" height=\"10\" viewBox=\"0 0 18 10\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n <path\n fill-rule=\"evenodd\"\n clip-rule=\"evenodd\"\n d=\"M9.70711 9.70711C9.31658 10.0976 8.68342 10.0976 8.29289 9.70711L0.292892 1.70711C-0.0976315 1.31658 -0.0976315 0.683417 0.292892 0.292893C0.683418 -0.0976315 1.31658 -0.0976315 1.70711 0.292893L9 7.58579L16.2929 0.292893C16.6834 -0.0976315 17.3166 -0.0976315 17.7071 0.292893C18.0976 0.683417 18.0976 1.31658 17.7071 1.70711L9.70711 9.70711Z\"\n ></path>\n </svg>\n <select name=\"shipmentCountry-select\" id=\"proxio-shipmentcountry\" onChange={this.handleDropdownChange.bind(this)}>\n {this.data.shipmentCountries.map(item => (\n <option selected={item.countryCode.toLowerCase() === this.countrycodevalue.toLowerCase()} value={item.countryCode}>\n {item.countryName}\n </option>\n ))}\n </select>\n </div>\n </div>\n ) : null}\n\n <div class=\"findprice__clear-all-filters\" role=\"button\">\n <div class=\"findprice__clear-all-filters__btn\" onClick={() => this.resetFilters()}>\n <pn-icon icon={trash_can} color=\"blue700\" />\n <span class=\"clear-all-filters__text\">{state.i18n.clearFilterButton}</span>\n </div>\n </div>\n </div>\n\n {this.filteredItems && this.filteredItems.length > 0 ? (\n <div class=\"resultlist\">\n {state.i18n.resultlistheading ? <div class=\"resultHeading\">{state.i18n.resultlistheading}</div> : null}\n {this.filteredItems.map((item: ProxioPriceListGroupResponse) => (\n <div>\n <pn-proxio-findprice-result\n activeweight={this.weight.value}\n item={item}\n language={this.language}\n selected-countrycode={this.countrycodevalue}\n show-international={this.showInternational}\n market={this.market}\n ></pn-proxio-findprice-result>\n </div>\n ))}\n </div>\n ) : this.weightvalue !== 0 ? (\n <h4 class=\"resultHeading\">{state.i18n.noResultMessage}</h4>\n ) : null}\n </div>\n );\n }\n}\n"]}
|
|
1
|
+
{"version":3,"file":"pn-proxio-findprice.js","sourceRoot":"","sources":["../../../../src/components/widgets/pn-proxio-findprice/pn-proxio-findprice.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,CAAC,EAAE,IAAI,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AACjE,OAAO,EAAE,YAAY,EAAE,OAAO,EAAE,MAAM,oCAAoC,CAAC;AAS3E,OAAO,EAAE,uBAAuB,EAAE,MAAM,0CAA0C,CAAC;AACnF,OAAO,EAAE,OAAO,EAAE,cAAc,EAAE,MAAM,WAAW,CAAC;AACpD,OAAO,EAAE,WAAW,EAAE,MAAM,8BAA8B,CAAC;AAC3D,OAAO,EAAE,KAAK,EAAE,MAAM,6BAA6B,CA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C,eAAe,CAAM,CAC5D,CAAC,CAAC,CAAC,IAAI,CACJ,CACP,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, h, Prop, State, Watch } from '@stencil/core';\nimport { translations, markets } from './pn-proxio-findprice-translations';\nimport { ProxioPriceListGroupResponse } from '../pn-proxio-pricegroup/types';\nimport {\n ProxioPriceListGroupsResponse,\n ProxioProductFindPriceWeight,\n ProxioProductFindPriceSizeCategory,\n ProxioProductFindPriceMarket,\n ProxioFindPricei18n,\n} from './pn-proxio-findprice-types';\nimport { MarketWebContextService } from '../../../globals/MarketWebContextService';\nimport { weights, sizeCategories } from './data.js';\nimport { FetchHelper } from '../../../globals/FetchHelper';\nimport { state } from './pn-proxio-findprice-store';\nimport S from './img/small-package.svg';\nimport M from './img/medium-package.svg';\nimport L from './img/large-package.svg';\nimport person from './img/postnord-person2.svg';\nimport clouds from './img/clouds.svg';\nimport { trash_can } from 'pn-design-assets/pn-assets/icons.js';\n\n@Component({\n tag: 'pn-proxio-findprice',\n styleUrl: 'pn-proxio-findprice.scss',\n})\nexport class PnProxioFindPrice {\n @Prop({ mutable: true }) endpoint: string = null;\n @Prop({ mutable: true }) language: string = 'da';\n @Prop({ mutable: true }) market: string = 'dk';\n @Prop() showMedium: boolean = false;\n @Prop() showInternational: boolean = false;\n @Prop() maxAbroadKg: number = 0;\n @Prop() weightListName: string = '';\n\n @Prop() cache: boolean = false;\n @State() filteredItems: ProxioPriceListGroupResponse[] = [];\n @State() weight: ProxioProductFindPriceWeight = { value: 0, name: '' } as ProxioProductFindPriceWeight;\n @State() weightvalue: number = 0;\n @State() countrycodevalue: string = '';\n @State() sizecategory: ProxioProductFindPriceSizeCategory = { value: '', name: '', icon: '', unit: '' } as ProxioProductFindPriceSizeCategory;\n @State() data: ProxioPriceListGroupsResponse = { proxioProducts: [], shipmentCountries: [] } as ProxioPriceListGroupsResponse;\n\n fetchHelper = new FetchHelper('proxiopricegroups');\n\n componentWillLoad() {\n this.setInitialValues().then(() => {\n this.init();\n });\n }\n\n async setInitialValues(href = window.location.href) {\n const marketWebContextService = new MarketWebContextService(href);\n const environment = await marketWebContextService.getEnvironmentName();\n\n if (!this.endpoint && environment?.indexOf('local') === -1) {\n const market = await marketWebContextService.getMarket();\n this.market = this.market ? this.market : market;\n this.endpoint = await marketWebContextService.getEndpoint(environment, market);\n }\n\n if (!this.endpoint) {\n this.endpoint = '';\n }\n\n if (this.countrycodevalue === '') {\n this.countrycodevalue = this.market.toLowerCase();\n }\n }\n\n init() {\n this.setState();\n this.fetchData().then(() => {\n this.getDataSource();\n });\n }\n\n async getDataSource() {\n try {\n this.sizecategory = (sizeCategories as ProxioProductFindPriceSizeCategory[]).filter(x => x.value === 'S')[0];\n this.filterItems();\n } catch (e) {\n console.log('Unable to parse data');\n }\n }\n\n async fetchData() {\n if (!this.market || !this.language) {\n return;\n }\n const endpoint = this.endpoint.lastIndexOf('/') === this.endpoint.length - 1 ? this.endpoint.substring(0, this.endpoint.length - 1) : this.endpoint;\n const fetchUrl = `${endpoint}/api/proxio/price-list-groups?market=${this.market}&language=${this.language}&cached=${this.cache}`;\n //const fetchUrl = `https://localhost:51547/api/proxio/price-list-groups?market=${this.market}&language=${this.language}&cached=${this.cache}`;\n\n const data = (await this.fetchHelper.fetchJson(\n fetchUrl,\n {\n mode: 'cors',\n },\n false,\n this.onFetchData.bind(this),\n )) as any;\n\n if (data) {\n this.data = data as ProxioPriceListGroupsResponse;\n this.data.proxioProducts = data.proxioProducts as ProxioPriceListGroupResponse[];\n }\n this.filterItems();\n }\n\n onFetchData(data) {\n this.data = data;\n }\n\n @Watch('market')\n @Watch('language')\n setState() {\n this.market = this.market ? this.market : 'dk';\n if (this.market) {\n state.market = markets[this.market] as ProxioProductFindPriceMarket;\n }\n if (this.language && translations[this.language]) {\n state.i18n = translations[this.language] as ProxioFindPricei18n;\n }\n }\n\n @Watch('sizecategory')\n @Watch('weightvalue')\n @Watch('countrycodevalue')\n filterItems() {\n const sizeItemData = this.data.proxioProducts.filter(item => {\n return item.proxioProduct.productWeightGroupList.some(weightGroup => {\n return weightGroup.item3.includes(this.sizecategory.value);\n });\n });\n\n if (!this.weight) {\n return;\n }\n const comparisonWeight = this.weight.value;\n\n let weightFilteredData = sizeItemData?.filter(item => {\n return item.proxioProduct.productWeightGroupList.some(weightGroup => {\n return weightGroup.item1 === comparisonWeight;\n });\n });\n\n let isInternational = this.showInternational && (this.countrycodevalue?.trim() !== '' ?? false);\n\n if (isInternational) {\n weightFilteredData = weightFilteredData?.filter(item =>\n item.proxioProduct.weightPriceCountryList.some(countryItem => countryItem.item3.includes(this.countrycodevalue.toUpperCase())),\n );\n }\n\n weightFilteredData = this.sortWeightItems(weightFilteredData, isInternational);\n\n this.filteredItems = weightFilteredData;\n }\n\n parseFloatFromString(text) {\n return parseFloat(text?.replace(/[^\\d\\.\\,]*/g, '') ?? 100000);\n }\n\n sortWeightItems(weightFilteredData: ProxioPriceListGroupResponse[], isInternational: boolean) {\n weightFilteredData?.sort((a, b) => {\n let aNumber = this.getSortNumber(a, isInternational);\n let bNumber = this.getSortNumber(b, isInternational);\n\n if (aNumber && bNumber) {\n return aNumber - bNumber;\n }\n\n if (aNumber < bNumber) {\n return -1;\n }\n\n if (aNumber > bNumber) {\n return 1;\n }\n\n return 0;\n }) ?? [];\n\n return weightFilteredData;\n }\n\n getSortNumber(proxioPriceListGroupResponseItem: ProxioPriceListGroupResponse, isInternational: boolean) {\n let index = proxioPriceListGroupResponseItem?.proxioProduct?.productWeightGroupList?.findIndex(weightGroup => weightGroup.item1 === this.weight.value) ?? 0;\n\n if (index < 0) {\n index = 0;\n }\n\n let pricevalue = proxioPriceListGroupResponseItem?.proxioProduct?.weightAndPriceList[index]?.item2?.toLowerCase() ?? '';\n\n if (isInternational) {\n let weightPriceCurrentCountryList = proxioPriceListGroupResponseItem?.proxioProduct?.weightPriceCountryList?.filter(countryItem =>\n countryItem.item3.includes(this.countrycodevalue.toUpperCase()),\n );\n\n pricevalue = weightPriceCurrentCountryList[index]?.item2?.toLowerCase() ?? '';\n }\n\n let sortNumber = this.parseFloatFromString(pricevalue);\n\n return sortNumber;\n }\n\n resetFilters() {\n this.weight = { value: 0, name: '' } as ProxioProductFindPriceWeight;\n this.sizecategory = (sizeCategories as ProxioProductFindPriceSizeCategory[]).filter(x => x.value === 'S')[0];\n this.weightvalue = 0;\n this.countrycodevalue = this.data?.shipmentCountries[0]?.countryCode ?? this.market;\n }\n\n getWeights() {\n let weightListName = this.market + this.weightListName;\n let marketWeightsArray = weights[weightListName] ?? { S: [], M: [], L: [] };\n let marketWeights = marketWeightsArray[this.sizecategory.unit];\n let isInternationalWeights = this.maxAbroadKg != 0 && this.countrycodevalue.toLowerCase() !== this.market.toLowerCase();\n marketWeights = isInternationalWeights ? marketWeights.filter(number => number.value / 1000 <= this.maxAbroadKg) : marketWeights;\n\n return marketWeights;\n }\n\n handleDropdownChange(event: Event) {\n const target = event.target as HTMLInputElement;\n const countryCode = target.value;\n this.countrycodevalue = countryCode;\n }\n\n render() {\n return (\n <div class=\"findprice-form\">\n <div class=\"findprice-form-wrapper\">\n <h4 class=\"findprice__heading\">{state.i18n.sizeheading}</h4>\n <div class=\"sizecategory\">\n <table class=\"sizeTable\">\n <img id=\"clouds\" src={clouds}></img>\n <tr>\n <td>\n <img class=\"firstCell\" src={person}></img>\n </td>\n <td>\n <img src={S}></img>\n </td>\n {this.showMedium ? (\n <td>\n <img src={M}></img>\n </td>\n ) : null}\n <td>\n <img src={L}></img>\n </td>\n </tr>\n <tr>\n <td></td>\n {sizeCategories.map(sizeCategory =>\n !this.showMedium && sizeCategory.value === 'M' ? null : (\n <td>\n <pn-radio-button\n id={'findpricecategory-' + sizeCategory.value}\n radioid={sizeCategory.value}\n value={sizeCategory.value}\n name=\"sizecategory\"\n checked={sizeCategory.value === this.sizecategory.value}\n onChange={() => {\n this.sizecategory = (sizeCategories as ProxioProductFindPriceSizeCategory[]).filter(x => x.value === sizeCategory.value)[0];\n this.weight = { value: 0, name: '' } as ProxioProductFindPriceWeight;\n this.weightvalue = this.weight.value;\n }}\n ></pn-radio-button>\n </td>\n ),\n )}\n </tr>\n </table>\n </div>\n\n <h4 class=\"findprice__heading findprice__subheading\">{state.i18n.weightheading}</h4>\n {this.sizecategory.value && this.getWeights() ? (\n <div class=\"weightoption\">\n {\n <div class=\"weightoption-content\">\n {this.getWeights().map(wght => (\n <pn-choice-button\n id={'findpriceweight-' + wght.value}\n choiceid={this.sizecategory.value + wght.value}\n name=\"weight\"\n type=\"radio\"\n value={!this.weight.value ? 0 : this.getWeights().findIndex(x => x.value === this.weightvalue)}\n checked={wght.value === this.weight.value}\n onChange={() => {\n this.weight = (this.getWeights() as ProxioProductFindPriceWeight[]).filter(x => x.value === wght.value)[0];\n this.weightvalue = this.weight.value;\n }}\n >\n {wght.name}\n </pn-choice-button>\n ))}\n </div>\n }\n </div>\n ) : null}\n\n {this.showInternational && (this.data?.shipmentCountries ?? false) ? (\n <div class=\"shipmentcountry\">\n <h4 class=\"shipmentcountry-header\">{state.i18n.countryToSendTo}</h4>\n <div class=\"shipmentcountry-select-container\">\n <svg class=\"arrow\" width=\"18\" height=\"10\" viewBox=\"0 0 18 10\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n <path\n fill-rule=\"evenodd\"\n clip-rule=\"evenodd\"\n d=\"M9.70711 9.70711C9.31658 10.0976 8.68342 10.0976 8.29289 9.70711L0.292892 1.70711C-0.0976315 1.31658 -0.0976315 0.683417 0.292892 0.292893C0.683418 -0.0976315 1.31658 -0.0976315 1.70711 0.292893L9 7.58579L16.2929 0.292893C16.6834 -0.0976315 17.3166 -0.0976315 17.7071 0.292893C18.0976 0.683417 18.0976 1.31658 17.7071 1.70711L9.70711 9.70711Z\"\n ></path>\n </svg>\n <select name=\"shipmentCountry-select\" id=\"proxio-shipmentcountry\" onChange={this.handleDropdownChange.bind(this)}>\n {this.data.shipmentCountries.map(item => (\n <option selected={item.countryCode.toLowerCase() === this.countrycodevalue.toLowerCase()} value={item.countryCode}>\n {item.countryName}\n </option>\n ))}\n </select>\n </div>\n </div>\n ) : null}\n\n <div class=\"findprice__clear-all-filters\" role=\"button\">\n <div class=\"findprice__clear-all-filters__btn\" onClick={() => this.resetFilters()}>\n <pn-icon icon={trash_can} color=\"blue700\" />\n <span class=\"clear-all-filters__text\">{state.i18n.clearFilterButton}</span>\n </div>\n </div>\n </div>\n\n {this.filteredItems && this.filteredItems.length > 0 ? (\n <div class=\"resultlist\">\n {state.i18n.resultlistheading ? <div class=\"resultHeading\">{state.i18n.resultlistheading}</div> : null}\n {this.filteredItems.map((item: ProxioPriceListGroupResponse) => (\n <div>\n <pn-proxio-findprice-result\n activeweight={this.weight.value}\n item={item}\n language={this.language}\n selected-countrycode={this.countrycodevalue}\n show-international={this.showInternational}\n market={this.market}\n ></pn-proxio-findprice-result>\n </div>\n ))}\n </div>\n ) : this.weightvalue !== 0 ? (\n <h4 class=\"resultHeading\">{state.i18n.noResultMessage}</h4>\n ) : null}\n </div>\n );\n }\n}\n"]}
|
|
@@ -5,7 +5,6 @@ import { translations } from "./translations";
|
|
|
5
5
|
import { arrow_left, arrow_right } from "pn-design-assets/pn-assets/icons.js";
|
|
6
6
|
export class PnProxioPricegroup {
|
|
7
7
|
constructor() {
|
|
8
|
-
this.fetchHelper = new FetchHelper('proxiopricegroup');
|
|
9
8
|
this.endpoint = null;
|
|
10
9
|
this.language = 'sv';
|
|
11
10
|
this.market = 'se';
|
|
@@ -15,6 +14,7 @@ export class PnProxioPricegroup {
|
|
|
15
14
|
this.data = null;
|
|
16
15
|
this.i18n = translations['sv'];
|
|
17
16
|
}
|
|
17
|
+
fetchHelper = new FetchHelper('proxiopricegroup');
|
|
18
18
|
componentWillLoad() {
|
|
19
19
|
this.setInitialValues().then(() => {
|
|
20
20
|
this.init();
|
|
@@ -23,7 +23,7 @@ export class PnProxioPricegroup {
|
|
|
23
23
|
async setInitialValues(href = window.location.href) {
|
|
24
24
|
const marketWebContextService = new MarketWebContextService(href);
|
|
25
25
|
const environment = await marketWebContextService.getEnvironmentName();
|
|
26
|
-
if (!this.endpoint &&
|
|
26
|
+
if (!this.endpoint && environment?.indexOf('local') === -1) {
|
|
27
27
|
const market = await marketWebContextService.getMarket();
|
|
28
28
|
this.endpoint = await marketWebContextService.getEndpoint(environment, market);
|
|
29
29
|
}
|
|
@@ -45,7 +45,7 @@ export class PnProxioPricegroup {
|
|
|
45
45
|
const data = (await this.fetchHelper.fetchJson(fetchUrl, {
|
|
46
46
|
mode: 'cors',
|
|
47
47
|
}, this.cache, this.onFetchData.bind(this)));
|
|
48
|
-
if (data
|
|
48
|
+
if (data?.proxioProduct) {
|
|
49
49
|
this.data = data;
|
|
50
50
|
}
|
|
51
51
|
}
|
|
@@ -53,9 +53,8 @@ export class PnProxioPricegroup {
|
|
|
53
53
|
this.data = data;
|
|
54
54
|
}
|
|
55
55
|
setActiveWeightIndex(weightIndex) {
|
|
56
|
-
var _a, _b, _c;
|
|
57
56
|
let minIndex = 0;
|
|
58
|
-
let maxIndex =
|
|
57
|
+
let maxIndex = this.data.proxioProduct?.weightAndPriceList?.length - 1 ?? minIndex;
|
|
59
58
|
weightIndex = weightIndex > maxIndex ? maxIndex : weightIndex;
|
|
60
59
|
weightIndex = weightIndex < minIndex ? minIndex : weightIndex;
|
|
61
60
|
this.activeWeightIndex = weightIndex;
|
|
@@ -66,14 +65,12 @@ export class PnProxioPricegroup {
|
|
|
66
65
|
}
|
|
67
66
|
}
|
|
68
67
|
getPriceString(product) {
|
|
69
|
-
|
|
70
|
-
let price = product.weightAndPriceList ? (_a = product === null || product === void 0 ? void 0 : product.weightAndPriceList[this.activeWeightIndex]) === null || _a === void 0 ? void 0 : _a.item2 : '';
|
|
68
|
+
let price = product.weightAndPriceList ? product?.weightAndPriceList[this.activeWeightIndex]?.item2 : '';
|
|
71
69
|
return price ? this.i18n.from + price : '';
|
|
72
70
|
}
|
|
73
71
|
getProductLink(product, productWeightGroupList) {
|
|
74
|
-
|
|
75
|
-
let
|
|
76
|
-
let productLink = product.productLink ? product === null || product === void 0 ? void 0 : product.productLink : '';
|
|
72
|
+
let productId = productWeightGroupList[this.activeWeightIndex]?.item2;
|
|
73
|
+
let productLink = product.productLink ? product?.productLink : '';
|
|
77
74
|
return productLink ? productLink + (productId ? '?productId=' + productId : '') : '';
|
|
78
75
|
}
|
|
79
76
|
isActive(index) {
|
|
@@ -121,8 +118,7 @@ export class PnProxioPricegroup {
|
|
|
121
118
|
}
|
|
122
119
|
}
|
|
123
120
|
render() {
|
|
124
|
-
|
|
125
|
-
return (h(Host, { key: '382bffa036a8d0d4dd545e661ce81a014c3d427d' }, ((_a = this.data) === null || _a === void 0 ? void 0 : _a.proxioProduct) ? (h("div", { class: "proxio-pricegroup-container" }, h("div", { class: "weightcontainer" }, this.data.proxioProduct.weightAndPriceList ? (h("div", { class: "weightvaluecontainer" }, h("pn-button", { disabled: this.activeWeightIndex === 0 ? 'disabled' : null, icon: arrow_left, appearance: "light", small: "true", onClick: () => this.setActiveWeightIndex(this.activeWeightIndex - 1) }), h("div", { class: "weightradios ", "data-carousel-container-position": this.getContainerPosition() }, h("div", { class: "weightline" }), this.data.proxioProduct.weightAndPriceList.map((weightItem, index) => this.getCarouselPosition(index) !== null ? (h("div", { class: "weightdata", "data-carousel-position": this.getCarouselPosition(index), onClick: () => this.setActiveWeightIndex(index) }, h("input", { type: "radio", id: 'weightradio' + index, name: "weightradio", value: index, checked: this.isActive(index) }), h("label", { htmlFor: 'weightradio' + index }, weightItem.item1))) : null)), h("pn-button", { disabled: this.activeWeightIndex === ((_c = (_b = this.data.proxioProduct) === null || _b === void 0 ? void 0 : _b.weightAndPriceList) === null || _c === void 0 ? void 0 : _c.length) - 1 ? 'disabled' : null, icon: arrow_right, appearance: "light", small: "true", onClick: () => this.setActiveWeightIndex(this.activeWeightIndex + 1) }))) : null), h("pn-proxio-productcard", null, h("pn-illustration", { slot: "illustrationmobile", illustration: this.data.proxioProduct.productIcon }), h("h2", { slot: "title" }, this.data.proxioProduct.productTitle), h("pn-proxio-productcard-description", { slot: "description", heading: this.data.proxioProduct.productPreamble, highlight: this.data.proxioProduct.deliveryDateInformation, list: this.data.proxioProduct.productDescriptionBulletListItems }), h("div", { slot: "information" }, h("pn-proxio-productcard-information", { label: this.i18n.labelMaxDimensions, information: this.data.proxioProduct.productPackageDimensionsList }), h("pn-proxio-productcard-information", { label: this.i18n.labelMaxDimensionsRoll, information: this.data.proxioProduct.productRollDimensionsList })), h("div", { slot: "bottomtags" }, this.data.proxioProduct.usp1 ? h("pn-titletag", { color: "gray50" }, this.data.proxioProduct.usp1) : null, this.data.proxioProduct.usp2 ? h("pn-titletag", { color: "gray50" }, this.data.proxioProduct.usp2) : null, this.data.proxioProduct.usp3 ? h("pn-titletag", { color: "gray50" }, this.data.proxioProduct.usp3) : null), h("pn-illustration", { slot: "illustration", illustration: this.data.proxioProduct.productIcon }), h("div", { slot: "pricelink" }, h("pn-proxio-productcard-pricelink", { price: this.getPriceString(this.data.proxioProduct), link: this.getProductLink(this.data.proxioProduct, this.data.proxioProduct.productWeightGroupList), linktext: this.data.proxioProduct.productLinkText }), this.data.relatedProxioProducts
|
|
121
|
+
return (h(Host, { key: '382bffa036a8d0d4dd545e661ce81a014c3d427d' }, this.data?.proxioProduct ? (h("div", { class: "proxio-pricegroup-container" }, h("div", { class: "weightcontainer" }, this.data.proxioProduct.weightAndPriceList ? (h("div", { class: "weightvaluecontainer" }, h("pn-button", { disabled: this.activeWeightIndex === 0 ? 'disabled' : null, icon: arrow_left, appearance: "light", small: "true", onClick: () => this.setActiveWeightIndex(this.activeWeightIndex - 1) }), h("div", { class: "weightradios ", "data-carousel-container-position": this.getContainerPosition() }, h("div", { class: "weightline" }), this.data.proxioProduct.weightAndPriceList.map((weightItem, index) => this.getCarouselPosition(index) !== null ? (h("div", { class: "weightdata", "data-carousel-position": this.getCarouselPosition(index), onClick: () => this.setActiveWeightIndex(index) }, h("input", { type: "radio", id: 'weightradio' + index, name: "weightradio", value: index, checked: this.isActive(index) }), h("label", { htmlFor: 'weightradio' + index }, weightItem.item1))) : null)), h("pn-button", { disabled: this.activeWeightIndex === this.data.proxioProduct?.weightAndPriceList?.length - 1 ? 'disabled' : null, icon: arrow_right, appearance: "light", small: "true", onClick: () => this.setActiveWeightIndex(this.activeWeightIndex + 1) }))) : null), h("pn-proxio-productcard", null, h("pn-illustration", { slot: "illustrationmobile", illustration: this.data.proxioProduct.productIcon }), h("h2", { slot: "title" }, this.data.proxioProduct.productTitle), h("pn-proxio-productcard-description", { slot: "description", heading: this.data.proxioProduct.productPreamble, highlight: this.data.proxioProduct.deliveryDateInformation, list: this.data.proxioProduct.productDescriptionBulletListItems }), h("div", { slot: "information" }, h("pn-proxio-productcard-information", { label: this.i18n.labelMaxDimensions, information: this.data.proxioProduct.productPackageDimensionsList }), h("pn-proxio-productcard-information", { label: this.i18n.labelMaxDimensionsRoll, information: this.data.proxioProduct.productRollDimensionsList })), h("div", { slot: "bottomtags" }, this.data.proxioProduct.usp1 ? h("pn-titletag", { color: "gray50" }, this.data.proxioProduct.usp1) : null, this.data.proxioProduct.usp2 ? h("pn-titletag", { color: "gray50" }, this.data.proxioProduct.usp2) : null, this.data.proxioProduct.usp3 ? h("pn-titletag", { color: "gray50" }, this.data.proxioProduct.usp3) : null), h("pn-illustration", { slot: "illustration", illustration: this.data.proxioProduct.productIcon }), h("div", { slot: "pricelink" }, h("pn-proxio-productcard-pricelink", { price: this.getPriceString(this.data.proxioProduct), link: this.getProductLink(this.data.proxioProduct, this.data.proxioProduct.productWeightGroupList), linktext: this.data.proxioProduct.productLinkText }), this.data.relatedProxioProducts
|
|
126
122
|
? this.data.relatedProxioProducts.map(product => (h("pn-proxio-productcard-pricelink", { price: this.getPriceString(product), link: product.productLink, linktext: product.productLinkText })))
|
|
127
123
|
: null)))) : null));
|
|
128
124
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pn-proxio-pricegroup.js","sourceRoot":"","sources":["../../../../src/components/widgets/pn-proxio-pricegroup/pn-proxio-pricegroup.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AACxE,OAAO,EAAE,WAAW,EAAE,MAAM,8BAA8B,CAAC;AAC3D,OAAO,EAAE,uBAAuB,EAAE,MAAM,0CAA0C,CAAC;AACnF,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAE9C,OAAO,EAAE,UAAU,EAAE,WAAW,EAAE,MAAM,qCAAqC,CAAC;AAM9E,MAAM,OAAO,kBAAkB;;QAa7B,gBAAW,GAAG,IAAI,WAAW,CAAC,kBAAkB,CAAC,CAAC;wBAXN,IAAI;wBAErB,IAAI;sBACN,IAAI;wBACF,EAAE;qBACJ,IAAI;iCAEQ,CAAC;oBACQ,IAAI;oBACZ,YAAY,CAAC,IAAI,CAAC;;IAIxD,iBAAiB;QACf,IAAI,CAAC,gBAAgB,EAAE,CAAC,IAAI,CAAC,GAAG,EAAE;YAChC,IAAI,CAAC,IAAI,EAAE,CAAC;QACd,CAAC,CAAC,CAAC;IACL,CAAC;IAED,KAAK,CAAC,gBAAgB,CAAC,IAAI,GAAG,MAAM,CAAC,QAAQ,CAAC,IAAI;QAChD,MAAM,uBAAuB,GAAG,IAAI,uBAAuB,CAAC,IAAI,CAAC,CAAC;QAClE,MAAM,WAAW,GAAG,MAAM,uBAAuB,CAAC,kBAAkB,EAAE,CAAC;QAEvE,IAAI,CAAC,IAAI,CAAC,QAAQ,IAAI,CAAA,WAAW,aAAX,WAAW,uBAAX,WA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AC,sBAAsB,CAAC,EAClG,QAAQ,EAAE,IAAI,CAAC,IAAI,CAAC,aAAa,CAAC,eAAe,GAChB;oBAClC,IAAI,CAAC,IAAI,CAAC,qBAAqB;wBAC9B,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,qBAAqB,CAAC,GAAG,CAAC,OAAO,CAAC,EAAE,CAAC,CAC7C,uCACE,KAAK,EAAE,IAAI,CAAC,cAAc,CAAC,OAAO,CAAC,EACnC,IAAI,EAAE,OAAO,CAAC,WAAW,EACzB,QAAQ,EAAE,OAAO,CAAC,eAAe,GACA,CACpC,CAAC;wBACJ,CAAC,CAAC,IAAI,CACJ,CACgB,CACpB,CACP,CAAC,CAAC,CAAC,IAAI,CACH,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, h, Host, Listen, Prop, State } from '@stencil/core';\nimport { FetchHelper } from '../../../globals/FetchHelper';\nimport { MarketWebContextService } from '../../../globals/MarketWebContextService';\nimport { translations } from './translations';\nimport { ProductGenericItem, ProxioPriceGroupi18n, ProxioPriceListGroupResponse, ProxioProduct, ProductWeightGroupListItem } from './types';\nimport { arrow_left, arrow_right } from 'pn-design-assets/pn-assets/icons.js';\n\n@Component({\n tag: 'pn-proxio-pricegroup',\n styleUrl: 'pn-proxio-pricegroup.scss',\n})\nexport class PnProxioPricegroup {\n /** Specifies which endpoint domain we should load from */\n @Prop({ mutable: true }) endpoint: string = null;\n //@Prop() culture: string = \"sv-SE\";\n @Prop() language: string = 'sv';\n @Prop() market: string = 'se';\n @Prop() tariffid: string = '';\n @Prop() cache: boolean = true;\n\n @State() activeWeightIndex: number = 0;\n @State() data: ProxioPriceListGroupResponse = null;\n @State() i18n: ProxioPriceGroupi18n = translations['sv'];\n\n fetchHelper = new FetchHelper('proxiopricegroup');\n\n componentWillLoad() {\n this.setInitialValues().then(() => {\n this.init();\n });\n }\n\n async setInitialValues(href = window.location.href) {\n const marketWebContextService = new MarketWebContextService(href);\n const environment = await marketWebContextService.getEnvironmentName();\n\n if (!this.endpoint && environment?.indexOf('local') === -1) {\n const market = await marketWebContextService.getMarket();\n this.endpoint = await marketWebContextService.getEndpoint(environment, market);\n }\n\n if (!this.endpoint) {\n this.endpoint = '';\n }\n }\n\n init() {\n this.setLanguage();\n this.fetchData();\n }\n\n async fetchData() {\n if (!this.market || !this.language || !this.tariffid) {\n return;\n }\n const endpoint = this.endpoint.lastIndexOf('/') === this.endpoint.length - 1 ? this.endpoint.substring(0, this.endpoint.length - 1) : this.endpoint;\n const fetchUrl = `${endpoint}/api/proxio/price-list-group?tariffId=${this.tariffid}&market=${this.market}&language=${this.language}&cached=${this.cache}`;\n //const fetchUrl = `https://localhost:51547/api/proxio/price-list-group?tariffId=${this.tariffid}&market=${this.market}&language=${this.language}&cached=${this.cache}`;\n const data = (await this.fetchHelper.fetchJson(\n fetchUrl,\n {\n mode: 'cors',\n },\n this.cache,\n this.onFetchData.bind(this),\n )) as any;\n\n if (data?.proxioProduct) {\n this.data = data;\n }\n }\n\n onFetchData(data) {\n this.data = data;\n }\n\n @Listen('activeWeightIndex')\n setActiveWeightIndex(weightIndex: number) {\n let minIndex = 0;\n let maxIndex = this.data.proxioProduct?.weightAndPriceList?.length - 1 ?? minIndex;\n weightIndex = weightIndex > maxIndex ? maxIndex : weightIndex;\n weightIndex = weightIndex < minIndex ? minIndex : weightIndex;\n this.activeWeightIndex = weightIndex;\n }\n\n @Listen('language')\n setLanguage() {\n if (translations[this.language]) {\n this.i18n = translations[this.language] as ProxioPriceGroupi18n;\n }\n }\n\n getPriceString(product: ProxioProduct) {\n let price = product.weightAndPriceList ? product?.weightAndPriceList[this.activeWeightIndex]?.item2 : '';\n return price ? this.i18n.from + price : '';\n }\n\n getProductLink(product: ProxioProduct, productWeightGroupList: ProductWeightGroupListItem[]) {\n let productId = productWeightGroupList[this.activeWeightIndex]?.item2;\n let productLink = product.productLink ? product?.productLink : '';\n return productLink ? productLink + (productId ? '?productId=' + productId : '') : '';\n }\n\n isActive(index: number) {\n return index === this.activeWeightIndex;\n }\n\n getCarouselPosition(index: number) {\n switch (index) {\n case this.activeWeightIndex - 2: {\n return -2;\n }\n case this.activeWeightIndex - 1: {\n return -1;\n }\n case this.activeWeightIndex: {\n return 0;\n }\n case this.activeWeightIndex + 1: {\n return 1;\n }\n case this.activeWeightIndex + 2: {\n return 2;\n }\n default:\n return 'outside';\n }\n }\n\n getContainerPosition() {\n let maxIndex = this.data.proxioProduct.weightAndPriceList.length - 1;\n switch (this.activeWeightIndex) {\n case 0: {\n return 'end50';\n }\n case 1: {\n return 'end75';\n }\n case maxIndex - 1: {\n return 'start75';\n }\n case maxIndex: {\n return 'start50';\n }\n default: {\n return 'default';\n }\n }\n }\n\n render() {\n return (\n <Host>\n {this.data?.proxioProduct ? (\n <div class=\"proxio-pricegroup-container\">\n <div class=\"weightcontainer\">\n {this.data.proxioProduct.weightAndPriceList ? (\n <div class=\"weightvaluecontainer\">\n <pn-button\n disabled={this.activeWeightIndex === 0 ? 'disabled' : null}\n icon={arrow_left}\n appearance=\"light\"\n small=\"true\"\n onClick={() => this.setActiveWeightIndex(this.activeWeightIndex - 1)}\n ></pn-button>\n <div class=\"weightradios \" data-carousel-container-position={this.getContainerPosition()}>\n <div class=\"weightline\"></div>\n {this.data.proxioProduct.weightAndPriceList.map((weightItem, index) =>\n this.getCarouselPosition(index) !== null ? (\n <div class=\"weightdata\" data-carousel-position={this.getCarouselPosition(index)} onClick={() => this.setActiveWeightIndex(index)}>\n <input type=\"radio\" id={'weightradio' + index} name=\"weightradio\" value={index} checked={this.isActive(index)} />\n <label htmlFor={'weightradio' + index}>{weightItem.item1}</label>\n </div>\n ) : null,\n )}\n </div>\n <pn-button\n disabled={this.activeWeightIndex === this.data.proxioProduct?.weightAndPriceList?.length - 1 ? 'disabled' : null}\n icon={arrow_right}\n appearance=\"light\"\n small=\"true\"\n onClick={() => this.setActiveWeightIndex(this.activeWeightIndex + 1)}\n ></pn-button>\n </div>\n ) : null}\n </div>\n <pn-proxio-productcard>\n <pn-illustration slot=\"illustrationmobile\" illustration={this.data.proxioProduct.productIcon}></pn-illustration>\n <h2 slot=\"title\">{this.data.proxioProduct.productTitle}</h2>\n <pn-proxio-productcard-description\n slot=\"description\"\n heading={this.data.proxioProduct.productPreamble}\n highlight={this.data.proxioProduct.deliveryDateInformation}\n list={this.data.proxioProduct.productDescriptionBulletListItems}\n ></pn-proxio-productcard-description>\n <div slot=\"information\">\n <pn-proxio-productcard-information\n label={this.i18n.labelMaxDimensions}\n information={this.data.proxioProduct.productPackageDimensionsList as ProductGenericItem[]}\n ></pn-proxio-productcard-information>\n <pn-proxio-productcard-information\n label={this.i18n.labelMaxDimensionsRoll}\n information={this.data.proxioProduct.productRollDimensionsList as ProductGenericItem[]}\n ></pn-proxio-productcard-information>\n </div>\n <div slot=\"bottomtags\">\n {this.data.proxioProduct.usp1 ? <pn-titletag color=\"gray50\">{this.data.proxioProduct.usp1}</pn-titletag> : null}\n {this.data.proxioProduct.usp2 ? <pn-titletag color=\"gray50\">{this.data.proxioProduct.usp2}</pn-titletag> : null}\n {this.data.proxioProduct.usp3 ? <pn-titletag color=\"gray50\">{this.data.proxioProduct.usp3}</pn-titletag> : null}\n </div>\n <pn-illustration slot=\"illustration\" illustration={this.data.proxioProduct.productIcon}></pn-illustration>\n <div slot=\"pricelink\">\n <pn-proxio-productcard-pricelink\n price={this.getPriceString(this.data.proxioProduct)}\n link={this.getProductLink(this.data.proxioProduct, this.data.proxioProduct.productWeightGroupList)}\n linktext={this.data.proxioProduct.productLinkText}\n ></pn-proxio-productcard-pricelink>\n {this.data.relatedProxioProducts\n ? this.data.relatedProxioProducts.map(product => (\n <pn-proxio-productcard-pricelink\n price={this.getPriceString(product)}\n link={product.productLink}\n linktext={product.productLinkText}\n ></pn-proxio-productcard-pricelink>\n ))\n : null}\n </div>\n </pn-proxio-productcard>\n </div>\n ) : null}\n </Host>\n );\n }\n}\n"]}
|
|
1
|
+
{"version":3,"file":"pn-proxio-pricegroup.js","sourceRoot":"","sources":["../../../../src/components/widgets/pn-proxio-pricegroup/pn-proxio-pricegroup.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AACxE,OAAO,EAAE,WAAW,EAAE,MAAM,8BAA8B,CAAC;AAC3D,OAAO,EAAE,uBAAuB,EAAE,MAAM,0CAA0C,CAAC;AACnF,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAE9C,OAAO,EAAE,UAAU,EAAE,WAAW,EAAE,MAAM,qCAAqC,CAAC;AAM9E,MAAM,OAAO,kBAAkB;;wBAEe,IAAI;wBAErB,IAAI;sBACN,IAAI;wBACF,EAAE;qBACJ,IAAI;iCAEQ,CAAC;oBACQ,IAAI;oBACZ,YAAY,CAAC,IAAI,CAAC;;IAExD,WAAW,GAAG,IAAI,WAAW,CAAC,kBAAkB,CAAC,CAAC;IAElD,iBAAiB;QACf,IAAI,CAAC,gBAAgB,EAAE,CAAC,IAAI,CAAC,GAAG,EAAE;YAChC,IAAI,CAAC,IAAI,EAAE,CAAC;QACd,CAAC,CAAC,CAAC;IACL,CAAC;IAED,KAAK,CAAC,gBAAgB,CAAC,IAAI,GAAG,MAAM,CAAC,QAAQ,CAAC,IAAI;QAChD,MAAM,uBAAuB,GAAG,IAAI,uBAAuB,CAAC,IAAI,CAAC,CAAC;QAClE,MAAM,WAAW,GAAG,MAAM,uBAAuB,CAAC,kBAAkB,EAAE,CAAC;QAEvE,IAAI,CAAC,IAAI,CAAC,QAAQ,IAAI,WAAW,EAAE,OAAO,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC,EAAE,CAAC;YAC3D,MAAM,MAAM,GAA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IAAI,CAAC,cAAc,CAAC,OAAO,CAAC,EACnC,IAAI,EAAE,OAAO,CAAC,WAAW,EACzB,QAAQ,EAAE,OAAO,CAAC,eAAe,GACA,CACpC,CAAC;wBACJ,CAAC,CAAC,IAAI,CACJ,CACgB,CACpB,CACP,CAAC,CAAC,CAAC,IAAI,CACH,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, h, Host, Listen, Prop, State } from '@stencil/core';\nimport { FetchHelper } from '../../../globals/FetchHelper';\nimport { MarketWebContextService } from '../../../globals/MarketWebContextService';\nimport { translations } from './translations';\nimport { ProductGenericItem, ProxioPriceGroupi18n, ProxioPriceListGroupResponse, ProxioProduct, ProductWeightGroupListItem } from './types';\nimport { arrow_left, arrow_right } from 'pn-design-assets/pn-assets/icons.js';\n\n@Component({\n tag: 'pn-proxio-pricegroup',\n styleUrl: 'pn-proxio-pricegroup.scss',\n})\nexport class PnProxioPricegroup {\n /** Specifies which endpoint domain we should load from */\n @Prop({ mutable: true }) endpoint: string = null;\n //@Prop() culture: string = \"sv-SE\";\n @Prop() language: string = 'sv';\n @Prop() market: string = 'se';\n @Prop() tariffid: string = '';\n @Prop() cache: boolean = true;\n\n @State() activeWeightIndex: number = 0;\n @State() data: ProxioPriceListGroupResponse = null;\n @State() i18n: ProxioPriceGroupi18n = translations['sv'];\n\n fetchHelper = new FetchHelper('proxiopricegroup');\n\n componentWillLoad() {\n this.setInitialValues().then(() => {\n this.init();\n });\n }\n\n async setInitialValues(href = window.location.href) {\n const marketWebContextService = new MarketWebContextService(href);\n const environment = await marketWebContextService.getEnvironmentName();\n\n if (!this.endpoint && environment?.indexOf('local') === -1) {\n const market = await marketWebContextService.getMarket();\n this.endpoint = await marketWebContextService.getEndpoint(environment, market);\n }\n\n if (!this.endpoint) {\n this.endpoint = '';\n }\n }\n\n init() {\n this.setLanguage();\n this.fetchData();\n }\n\n async fetchData() {\n if (!this.market || !this.language || !this.tariffid) {\n return;\n }\n const endpoint = this.endpoint.lastIndexOf('/') === this.endpoint.length - 1 ? this.endpoint.substring(0, this.endpoint.length - 1) : this.endpoint;\n const fetchUrl = `${endpoint}/api/proxio/price-list-group?tariffId=${this.tariffid}&market=${this.market}&language=${this.language}&cached=${this.cache}`;\n //const fetchUrl = `https://localhost:51547/api/proxio/price-list-group?tariffId=${this.tariffid}&market=${this.market}&language=${this.language}&cached=${this.cache}`;\n const data = (await this.fetchHelper.fetchJson(\n fetchUrl,\n {\n mode: 'cors',\n },\n this.cache,\n this.onFetchData.bind(this),\n )) as any;\n\n if (data?.proxioProduct) {\n this.data = data;\n }\n }\n\n onFetchData(data) {\n this.data = data;\n }\n\n @Listen('activeWeightIndex')\n setActiveWeightIndex(weightIndex: number) {\n let minIndex = 0;\n let maxIndex = this.data.proxioProduct?.weightAndPriceList?.length - 1 ?? minIndex;\n weightIndex = weightIndex > maxIndex ? maxIndex : weightIndex;\n weightIndex = weightIndex < minIndex ? minIndex : weightIndex;\n this.activeWeightIndex = weightIndex;\n }\n\n @Listen('language')\n setLanguage() {\n if (translations[this.language]) {\n this.i18n = translations[this.language] as ProxioPriceGroupi18n;\n }\n }\n\n getPriceString(product: ProxioProduct) {\n let price = product.weightAndPriceList ? product?.weightAndPriceList[this.activeWeightIndex]?.item2 : '';\n return price ? this.i18n.from + price : '';\n }\n\n getProductLink(product: ProxioProduct, productWeightGroupList: ProductWeightGroupListItem[]) {\n let productId = productWeightGroupList[this.activeWeightIndex]?.item2;\n let productLink = product.productLink ? product?.productLink : '';\n return productLink ? productLink + (productId ? '?productId=' + productId : '') : '';\n }\n\n isActive(index: number) {\n return index === this.activeWeightIndex;\n }\n\n getCarouselPosition(index: number) {\n switch (index) {\n case this.activeWeightIndex - 2: {\n return -2;\n }\n case this.activeWeightIndex - 1: {\n return -1;\n }\n case this.activeWeightIndex: {\n return 0;\n }\n case this.activeWeightIndex + 1: {\n return 1;\n }\n case this.activeWeightIndex + 2: {\n return 2;\n }\n default:\n return 'outside';\n }\n }\n\n getContainerPosition() {\n let maxIndex = this.data.proxioProduct.weightAndPriceList.length - 1;\n switch (this.activeWeightIndex) {\n case 0: {\n return 'end50';\n }\n case 1: {\n return 'end75';\n }\n case maxIndex - 1: {\n return 'start75';\n }\n case maxIndex: {\n return 'start50';\n }\n default: {\n return 'default';\n }\n }\n }\n\n render() {\n return (\n <Host>\n {this.data?.proxioProduct ? (\n <div class=\"proxio-pricegroup-container\">\n <div class=\"weightcontainer\">\n {this.data.proxioProduct.weightAndPriceList ? (\n <div class=\"weightvaluecontainer\">\n <pn-button\n disabled={this.activeWeightIndex === 0 ? 'disabled' : null}\n icon={arrow_left}\n appearance=\"light\"\n small=\"true\"\n onClick={() => this.setActiveWeightIndex(this.activeWeightIndex - 1)}\n ></pn-button>\n <div class=\"weightradios \" data-carousel-container-position={this.getContainerPosition()}>\n <div class=\"weightline\"></div>\n {this.data.proxioProduct.weightAndPriceList.map((weightItem, index) =>\n this.getCarouselPosition(index) !== null ? (\n <div class=\"weightdata\" data-carousel-position={this.getCarouselPosition(index)} onClick={() => this.setActiveWeightIndex(index)}>\n <input type=\"radio\" id={'weightradio' + index} name=\"weightradio\" value={index} checked={this.isActive(index)} />\n <label htmlFor={'weightradio' + index}>{weightItem.item1}</label>\n </div>\n ) : null,\n )}\n </div>\n <pn-button\n disabled={this.activeWeightIndex === this.data.proxioProduct?.weightAndPriceList?.length - 1 ? 'disabled' : null}\n icon={arrow_right}\n appearance=\"light\"\n small=\"true\"\n onClick={() => this.setActiveWeightIndex(this.activeWeightIndex + 1)}\n ></pn-button>\n </div>\n ) : null}\n </div>\n <pn-proxio-productcard>\n <pn-illustration slot=\"illustrationmobile\" illustration={this.data.proxioProduct.productIcon}></pn-illustration>\n <h2 slot=\"title\">{this.data.proxioProduct.productTitle}</h2>\n <pn-proxio-productcard-description\n slot=\"description\"\n heading={this.data.proxioProduct.productPreamble}\n highlight={this.data.proxioProduct.deliveryDateInformation}\n list={this.data.proxioProduct.productDescriptionBulletListItems}\n ></pn-proxio-productcard-description>\n <div slot=\"information\">\n <pn-proxio-productcard-information\n label={this.i18n.labelMaxDimensions}\n information={this.data.proxioProduct.productPackageDimensionsList as ProductGenericItem[]}\n ></pn-proxio-productcard-information>\n <pn-proxio-productcard-information\n label={this.i18n.labelMaxDimensionsRoll}\n information={this.data.proxioProduct.productRollDimensionsList as ProductGenericItem[]}\n ></pn-proxio-productcard-information>\n </div>\n <div slot=\"bottomtags\">\n {this.data.proxioProduct.usp1 ? <pn-titletag color=\"gray50\">{this.data.proxioProduct.usp1}</pn-titletag> : null}\n {this.data.proxioProduct.usp2 ? <pn-titletag color=\"gray50\">{this.data.proxioProduct.usp2}</pn-titletag> : null}\n {this.data.proxioProduct.usp3 ? <pn-titletag color=\"gray50\">{this.data.proxioProduct.usp3}</pn-titletag> : null}\n </div>\n <pn-illustration slot=\"illustration\" illustration={this.data.proxioProduct.productIcon}></pn-illustration>\n <div slot=\"pricelink\">\n <pn-proxio-productcard-pricelink\n price={this.getPriceString(this.data.proxioProduct)}\n link={this.getProductLink(this.data.proxioProduct, this.data.proxioProduct.productWeightGroupList)}\n linktext={this.data.proxioProduct.productLinkText}\n ></pn-proxio-productcard-pricelink>\n {this.data.relatedProxioProducts\n ? this.data.relatedProxioProducts.map(product => (\n <pn-proxio-productcard-pricelink\n price={this.getPriceString(product)}\n link={product.productLink}\n linktext={product.productLinkText}\n ></pn-proxio-productcard-pricelink>\n ))\n : null}\n </div>\n </pn-proxio-productcard>\n </div>\n ) : null}\n </Host>\n );\n }\n}\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pn-usp-promoter.js","sourceRoot":"","sources":["../../../../src/components/widgets/pn-usp-promoter/pn-usp-promoter.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS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,mBAAmB,EAAE,EAAE,EAAE,KAAK,EAAE,EAAE,YAAY,EAAE,GAAG,IAAI,CAAC,kBAAkB,EAAE,EAAE;gBAC5G,4DAAK,KAAK,EAAC,uBAAuB;oBAChC,6DAAM,IAAI,EAAC,cAAc,GAAQ;oBACjC,4DAAK,KAAK,EAAC,+BAA+B;wBACxC,2DAAI,KAAK,EAAE,iCAAiC,mBAAmB,EAAE;4BAC/D,+DAAO,IAAI,CAAC,OAAO,CAAQ;4BAC1B,IAAI,CAAC,gBAAgB,CAAC,CAAC,CAAC,gBAAO,IAAI,CAAC,gBAAgB,CAAQ,CAAC,CAAC,CAAC,IAAI,CACjE;wBACL,0DAAG,KAAK,EAAC,4BAA4B,IAAE,IAAI,CAAC,QAAQ,CAAK;wBACzD,6DAAM,IAAI,EAAC,WAAW,GAAQ;wBAC9B,6DAAM,IAAI,EAAC,aAAa,GAAQ,CAC5B,CACF,CACF,CACD,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, Prop, h, Host, Element } from '@stencil/core';\n\n@Component({\n tag: 'pn-usp-promoter',\n styleUrl: 'pn-usp-promoter.scss',\n})\nexport class PnUspPromoter {\n @Element() hostElement: HTMLElement;\n\n @Prop() heading: string = null;\n @Prop() headingExtension: string = null;\n @Prop() bodyText: string = null;\n @Prop() backgroundGradient: string = null;\n @Prop() fullWidth: boolean = false;\n @Prop() rightAlign: boolean = false;\n @Prop() hideMobileImage: boolean = false;\n\n private centerMobileContent() {\n const slot = this.hostElement.querySelector('[slot=\"illustration\"]');\n if (this.hideMobileImage || slot == null) {\n return 'usp-promoter--hide-image-small-screen';\n }\n return \"\";\n }\n\n render() {\n const { fullWidth, rightAlign } = this;\n const classes = [\n 'usp-promoter',\n fullWidth ? \"usp-promoter--full-width\" : \"\",\n rightAlign ? \"usp-promoter--right-align\" : \"\",\n ].join(' ');\n const hasHeadingExtension = this.headingExtension ? \"usp-promoter__heading-extension\" : \"\";\n\n return (\n <Host>\n <div class={` ${classes} ${this.centerMobileContent()}`} style={{ 'background': `${this.backgroundGradient}` }}>\n <div class=\"usp-promoter__content\">\n <slot name=\"illustration\"></slot>\n <div class=\"usp-promoter__content-wrapper\">\n <h2 class={`usp-promoter__content-heading ${hasHeadingExtension}`}>\n <span>{this.heading}</span>\n {this.headingExtension ? <span>{this.headingExtension}</span> : null}\n </h2>\n <p class=\"usp-promoter__content-text\">{this.bodyText}</p>\n <slot name=\"app-store\"></slot>\n <slot name=\"usp-buttons\"></slot>\n </div>\n </div>\n </div>\n </Host>\n );\n }\n}\n"]}
|