@postnord/pn-marketweb-components 3.0.3 → 3.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/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 +39 -33
- 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 +39 -32
- 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 +39 -33
- 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 +40 -34
- 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/pn-marketweb-init.js +1 -1
- package/umd/pn-marketweb-salesforce.js +1 -1
- 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-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-3ae1657a.entry.js +0 -2
- package/pn-market-web-components/p-3ae1657a.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-5ff663be.entry.js +0 -2
- package/pn-market-web-components/p-5ff663be.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-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-af16f7e3.entry.js +0 -2
- package/pn-market-web-components/p-af16f7e3.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-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-multi-row-connected-dropdown.js","sourceRoot":"","sources":["../../../../src/components/input/pn-multi-row-connected-dropdown/pn-multi-row-connected-dropdown.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,EAAE,OAAO,EAAE,KAAK,EAAE,IAAI,EAAS,KAAK,EAAgB,MAAM,EAAE,MAAM,eAAe,CAAC;AAE7G,OAAO,EAAE,EAAE,IAAI,MAAM,EAAE,MAAM,MAAM,CAAC;AACpC,OAAO,EAAE,IAAI,EAAE,MAAM,qCAAqC,CAAC;AAM3D,MAAM,OAAO,2BAA2B;;QA6B9B,qBAAgB,GAAW,IAAI,CAAC;QAChC,4BAAuB,GAAW,IAAI,CAAC;QACvC,6BAAwB,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,OAAO,EAAE,GAAG,EAAE;wBACZ,IAAI,CAAC,MAAM,EAAE,CAAC;oBAChB,CAAC,IAEA,IAAI,CAAC,UAAU,CACN,CACR,CACP,CAAC,CAAC,CAAC,IAAI,CACH,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, Prop, h, Element, State, Host, Watch, Event, EventEmitter, Listen } from '@stencil/core';\nimport { FormValue, PredefinedValues, Root, RowValue, SelectItem } from './types';\nimport { v4 as uuidv4 } from 'uuid';\nimport { plus } from 'pn-design-assets/pn-assets/icons.js';\n\n@Component({\n tag: 'pn-multi-row-connected-dropdown',\n styleUrl: 'pn-multi-row-connected-dropdown.scss',\n})\nexport class PnMultiRowConnectedDropdown {\n @Element() hostElement: Element;\n\n @Prop() dropdownData: string | Root[] = null;\n @Prop() languageCode: string = null;\n @Prop() label: string = null;\n @Prop() firstDropdownLabel: string = null;\n @Prop() secondDropdownLabel: string = null;\n @Prop() dropdownPlaceholder: string = null;\n @Prop() addRowText: string = null;\n @Prop() inputFildLabel: string = null;\n @Prop() inputFildPlaceholder: string = null;\n @Prop() dateButtonText: string = null;\n @Prop() datePlaceholder: string = null;\n @Prop() dateDaysFromToday: number = null;\n @Prop() allowMultipleRows: boolean = false;\n @Prop() allowMultipleDates: boolean = false;\n @Prop() startDateLabel: string = null;\n @Prop() endDateLabel: string = null;\n @Prop() multiDateHelperText: string = null;\n @Prop() generateDatesButtonText: string = null;\n @Prop() saveDateButtonText: string = null;\n @Prop() noDatesText: string = null;\n @Prop() yearsToAddToEndDate: number = null;\n\n @State() rowCount: number = null;\n @State() rowData: PredefinedValues[] = null;\n @State() formValues: FormValue[] = null;\n\n private _buttonValueName: string = null;\n private _firstDropdownValueName: string = null;\n private _secondDropdownValueName: string = null;\n private _inputValueName: string = null;\n private _dateValueName: string = null;\n\n @Event() allFormValues: EventEmitter<string>;\n\n private _defaultRow: PredefinedValues = {\n id: this.generateUniqueId(),\n buttons: [],\n firstDropdown: [],\n secondDropdown: [],\n input: '',\n dates: '',\n dateRange: {\n days: [],\n startDate: '',\n endDate: '',\n },\n };\n\n componentWillLoad() {\n this.setDaysArr();\n this.formValues = [];\n this.rowData = [this._defaultRow];\n this.rowCount = this.rowData.length;\n\n this._buttonValueName = this.label?.length ? this.label : 'value0';\n this._firstDropdownValueName = this.firstDropdownLabel?.length ? this.firstDropdownLabel : 'value1';\n this._secondDropdownValueName = this.secondDropdownLabel?.length ? this.secondDropdownLabel : 'value2';\n this._inputValueName = this.inputFildLabel?.length ? this.inputFildLabel : 'value3';\n this._dateValueName = this.dateButtonText?.length ? this.dateButtonText : 'value4';\n }\n\n componentDidLoad() {}\n\n emittValuesIfValid() {\n this.formValues = [];\n this.rowData.forEach(item => {\n const rowValue: FormValue = { row: [] };\n\n const buttonSelection = item.buttons.find(x => x.selected === true);\n if (buttonSelection) {\n const buttonValue: RowValue = { name: this._buttonValueName, value: buttonSelection.label };\n rowValue.row.push(buttonValue);\n }\n\n const firstDropdownSelection = item.firstDropdown.find(x => x.selected === true);\n if (firstDropdownSelection) {\n const firstDropdownValue: RowValue = { name: this._firstDropdownValueName, value: firstDropdownSelection.label };\n rowValue.row.push(firstDropdownValue);\n }\n\n const secondDropdownSelection = item.secondDropdown.find(x => x.selected === true);\n if (secondDropdownSelection) {\n const secondDropdownValue: RowValue = { name: this._secondDropdownValueName, value: secondDropdownSelection.label };\n rowValue.row.push(secondDropdownValue);\n }\n\n const input = item.input;\n if (input?.length) {\n const inputValue: RowValue = { name: this._inputValueName, value: input };\n rowValue.row.push(inputValue);\n }\n\n const dates = item.dates[\"start\"];\n if (dates?.length) {\n const datestValue: RowValue = { name: this._dateValueName, value: dates };\n rowValue.row.push(datestValue);\n }\n\n if (rowValue.row.length === 5) {\n this.formValues.push(rowValue);\n }\n });\n\n if (this.formValues.length === this.rowData.length) {\n const valueJsonString = JSON.stringify(this.formValues);\n this.allFormValues.emit(valueJsonString);\n } else {\n this.allFormValues.emit('');\n }\n }\n\n @Listen('rowValueChange')\n predefinedValueChange(e) {\n const indexToUpdate = this.rowData.findIndex(data => data.id === e.detail.id);\n const val: PredefinedValues = e.detail;\n this.rowData[indexToUpdate] = {\n ...this.rowData[indexToUpdate],\n buttons: val.buttons,\n firstDropdown: val.firstDropdown,\n secondDropdown: val.secondDropdown,\n input: val.input,\n dates: val.dates,\n dateRange: val.dateRange,\n };\n this.emittValuesIfValid();\n }\n\n @Listen('deleteRowEvent')\n deleteRowEvent(e) {\n const indexToRemove = this.rowData.findIndex(data => data.id === e.detail);\n this.rowData.splice(indexToRemove, 1);\n this.rowData = [...this.rowData];\n this.rowCount = this.rowData.length;\n this.emittValuesIfValid();\n }\n\n generateUniqueId() {\n return uuidv4();\n }\n\n addRow() {\n const newRow = this._defaultRow;\n newRow.id = this.generateUniqueId();\n\n this.rowData = [...this.rowData, newRow];\n this.rowCount = this.rowData.length;\n }\n\n setDaysArr() {\n const language = this.languageCode.toLowerCase();\n\n switch (language) {\n case 'en':\n this._defaultRow.dateRange.days = [\n { label: 'Monday', value: '1', selected: false },\n { label: 'Tuesday', value: '2', selected: false },\n { label: 'Wednesday', value: '3', selected: false },\n { label: 'Thursday', value: '4', selected: false },\n { label: 'Friday', value: '5', selected: false },\n ];\n break;\n\n case 'sv':\n this._defaultRow.dateRange.days = [\n { label: 'Måndag', value: '1', selected: false },\n { label: 'Tisdag', value: '2', selected: false },\n { label: 'Onsdag', value: '3', selected: false },\n { label: 'Torsdag', value: '4', selected: false },\n { label: 'Fredag', value: '5', selected: false },\n ];\n break;\n\n case 'da':\n this._defaultRow.dateRange.days = [\n { label: 'Mandag', value: '1', selected: false },\n { label: 'Tirsdag', value: '2', selected: false },\n { label: 'Onsdag', value: '3', selected: false },\n { label: 'Torsdag', value: '4', selected: false },\n { label: 'Fredag', value: '5', selected: false },\n ];\n break;\n\n case 'fi':\n this._defaultRow.dateRange.days = [\n { label: 'Maanantai', value: '1', selected: false },\n { label: 'Tiistai', value: '2', selected: false },\n { label: 'Keskiviikko', value: '3', selected: false },\n { label: 'Torstai', value: '4', selected: false },\n { label: 'Perjantai', value: '5', selected: false },\n ];\n break;\n\n case 'no':\n this._defaultRow.dateRange.days = [\n { label: 'Mandag', value: '1', selected: false },\n { label: 'Tirsdag', value: '2', selected: false },\n { label: 'Onsdag', value: '3', selected: false },\n { label: 'Torsdag', value: '4', selected: false },\n { label: 'Fredag', value: '5', selected: false },\n ];\n break;\n\n default:\n this._defaultRow.dateRange.days = [\n { label: 'Monday', value: '1', selected: false },\n { label: 'Tuesday', value: '2', selected: false },\n { label: 'Wednesday', value: '3', selected: false },\n { label: 'Thursday', value: '4', selected: false },\n { label: 'Friday', value: '5', selected: false },\n ];\n break;\n }\n }\n\n render() {\n return (\n <Host>\n {this.rowData?.map((data, i) => {\n return (\n <div class={'generated-row-' + i} id={'generated-row-connected-dropdown-' + i}>\n <pn-multi-row-connected-dropdown-row\n dropdown-data={this.dropdownData}\n language-code={this.languageCode}\n label={this.label}\n first-dropdown-label={this.firstDropdownLabel}\n second-dropdown-label={this.secondDropdownLabel}\n dropdown-placeholder={this.dropdownPlaceholder}\n add-row-text={this.addRowText}\n input-fild-label={this.inputFildLabel}\n input-fild-placeholder={this.inputFildPlaceholder}\n date-button-text={this.dateButtonText}\n date-placeholder={this.datePlaceholder}\n date-days-from-today={this.dateDaysFromToday}\n allow-multiple-dates={this.allowMultipleDates}\n start-date-label={this.startDateLabel}\n end-date-label={this.endDateLabel}\n multi-date-helper-text={this.multiDateHelperText}\n generate-dates-button-text={this.generateDatesButtonText}\n save-date-button-text={this.saveDateButtonText}\n no-dates-text={this.noDatesText}\n index={i}\n predefined-value={JSON.stringify(data)}\n years-to-add-to-end-date={this.yearsToAddToEndDate}\n ></pn-multi-row-connected-dropdown-row>\n </div>\n );\n })}\n\n {this.allowMultipleRows ? (\n <div class=\"connected-dropdown__row\">\n <pn-button\n tooltip={this.addRowText ? this.addRowText : null}\n left-icon=\"true\"\n arialabel=\"Add\"\n icon={plus}\n appearance=\"light\"\n variant=\"borderless\"\n class=\"connected-dropdown__button-right\"\n onClick={() => {\n this.addRow();\n }}\n >\n {this.addRowText}\n </pn-button>\n </div>\n ) : null}\n </Host>\n );\n }\n}\n"]}
|
|
1
|
+
{"version":3,"file":"pn-multi-row-connected-dropdown.js","sourceRoot":"","sources":["../../../../src/components/input/pn-multi-row-connected-dropdown/pn-multi-row-connected-dropdown.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,EAAE,OAAO,EAAE,KAAK,EAAE,IAAI,EAAS,KAAK,EAAgB,MAAM,EAAE,MAAM,eAAe,CAAC;AAE7G,OAAO,EAAE,EAAE,IAAI,MAAM,EAAE,MAAM,MAAM,CAAC;AACpC,OAAO,EAAE,IAAI,EAAE,MAAM,qCAAqC,CAAC;AAM3D,MAAM,OAAO,2BAA2B;;4BAGE,IAAI;4BACb,IAAI;qBACX,IAAI;kCACS,IAAI;mCACH,IAAI;mCACJ,IAAI;0BACb,IAAI;8BACA,IAAI;oCACE,IAAI;8BACV,IAAI;+BACH,IAAI;iCACF,IAAI;iCACH,KAAK;kCACJ,KAAK;8BACV,IAAI;4BACN,IAAI;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, Prop, h, Element, State, Host, Watch, Event, EventEmitter, Listen } from '@stencil/core';\nimport { FormValue, PredefinedValues, Root, RowValue, SelectItem } from './types';\nimport { v4 as uuidv4 } from 'uuid';\nimport { plus } from 'pn-design-assets/pn-assets/icons.js';\n\n@Component({\n tag: 'pn-multi-row-connected-dropdown',\n styleUrl: 'pn-multi-row-connected-dropdown.scss',\n})\nexport class PnMultiRowConnectedDropdown {\n @Element() hostElement: Element;\n\n @Prop() dropdownData: string | Root[] = null;\n @Prop() languageCode: string = null;\n @Prop() label: string = null;\n @Prop() firstDropdownLabel: string = null;\n @Prop() secondDropdownLabel: string = null;\n @Prop() dropdownPlaceholder: string = null;\n @Prop() addRowText: string = null;\n @Prop() inputFildLabel: string = null;\n @Prop() inputFildPlaceholder: string = null;\n @Prop() dateButtonText: string = null;\n @Prop() datePlaceholder: string = null;\n @Prop() dateDaysFromToday: number = null;\n @Prop() allowMultipleRows: boolean = false;\n @Prop() allowMultipleDates: boolean = false;\n @Prop() startDateLabel: string = null;\n @Prop() endDateLabel: string = null;\n @Prop() multiDateHelperText: string = null;\n @Prop() generateDatesButtonText: string = null;\n @Prop() saveDateButtonText: string = null;\n @Prop() noDatesText: string = null;\n @Prop() yearsToAddToEndDate: number = null;\n\n @State() rowCount: number = null;\n @State() rowData: PredefinedValues[] = null;\n @State() formValues: FormValue[] = null;\n\n private _buttonValueName: string = null;\n private _firstDropdownValueName: string = null;\n private _secondDropdownValueName: string = null;\n private _inputValueName: string = null;\n private _dateValueName: string = null;\n\n @Event() allFormValues: EventEmitter<string>;\n\n private _defaultRow: PredefinedValues = {\n id: this.generateUniqueId(),\n buttons: [],\n firstDropdown: [],\n secondDropdown: [],\n input: '',\n dates: '',\n dateRange: {\n days: [],\n startDate: '',\n endDate: '',\n },\n };\n\n componentWillLoad() {\n this.setDaysArr();\n this.formValues = [];\n this.rowData = [this._defaultRow];\n this.rowCount = this.rowData.length;\n\n this._buttonValueName = this.label?.length ? this.label : 'value0';\n this._firstDropdownValueName = this.firstDropdownLabel?.length ? this.firstDropdownLabel : 'value1';\n this._secondDropdownValueName = this.secondDropdownLabel?.length ? this.secondDropdownLabel : 'value2';\n this._inputValueName = this.inputFildLabel?.length ? this.inputFildLabel : 'value3';\n this._dateValueName = this.dateButtonText?.length ? this.dateButtonText : 'value4';\n }\n\n componentDidLoad() {}\n\n emittValuesIfValid() {\n this.formValues = [];\n this.rowData.forEach(item => {\n const rowValue: FormValue = { row: [] };\n\n const buttonSelection = item.buttons.find(x => x.selected === true);\n if (buttonSelection) {\n const buttonValue: RowValue = { name: this._buttonValueName, value: buttonSelection.label };\n rowValue.row.push(buttonValue);\n }\n\n const firstDropdownSelection = item.firstDropdown.find(x => x.selected === true);\n if (firstDropdownSelection) {\n const firstDropdownValue: RowValue = { name: this._firstDropdownValueName, value: firstDropdownSelection.label };\n rowValue.row.push(firstDropdownValue);\n }\n\n const secondDropdownSelection = item.secondDropdown.find(x => x.selected === true);\n if (secondDropdownSelection) {\n const secondDropdownValue: RowValue = { name: this._secondDropdownValueName, value: secondDropdownSelection.label };\n rowValue.row.push(secondDropdownValue);\n }\n\n const input = item.input;\n if (input?.length) {\n const inputValue: RowValue = { name: this._inputValueName, value: input };\n rowValue.row.push(inputValue);\n }\n\n const dates = item.dates[\"start\"];\n if (dates?.length) {\n const datestValue: RowValue = { name: this._dateValueName, value: dates };\n rowValue.row.push(datestValue);\n }\n\n if (rowValue.row.length === 5) {\n this.formValues.push(rowValue);\n }\n });\n\n if (this.formValues.length === this.rowData.length) {\n const valueJsonString = JSON.stringify(this.formValues);\n this.allFormValues.emit(valueJsonString);\n } else {\n this.allFormValues.emit('');\n }\n }\n\n @Listen('rowValueChange')\n predefinedValueChange(e) {\n const indexToUpdate = this.rowData.findIndex(data => data.id === e.detail.id);\n const val: PredefinedValues = e.detail;\n this.rowData[indexToUpdate] = {\n ...this.rowData[indexToUpdate],\n buttons: val.buttons,\n firstDropdown: val.firstDropdown,\n secondDropdown: val.secondDropdown,\n input: val.input,\n dates: val.dates,\n dateRange: val.dateRange,\n };\n this.emittValuesIfValid();\n }\n\n @Listen('deleteRowEvent')\n deleteRowEvent(e) {\n const indexToRemove = this.rowData.findIndex(data => data.id === e.detail);\n this.rowData.splice(indexToRemove, 1);\n this.rowData = [...this.rowData];\n this.rowCount = this.rowData.length;\n this.emittValuesIfValid();\n }\n\n generateUniqueId() {\n return uuidv4();\n }\n\n addRow() {\n const newRow = this._defaultRow;\n newRow.id = this.generateUniqueId();\n\n this.rowData = [...this.rowData, newRow];\n this.rowCount = this.rowData.length;\n }\n\n setDaysArr() {\n const language = this.languageCode.toLowerCase();\n\n switch (language) {\n case 'en':\n this._defaultRow.dateRange.days = [\n { label: 'Monday', value: '1', selected: false },\n { label: 'Tuesday', value: '2', selected: false },\n { label: 'Wednesday', value: '3', selected: false },\n { label: 'Thursday', value: '4', selected: false },\n { label: 'Friday', value: '5', selected: false },\n ];\n break;\n\n case 'sv':\n this._defaultRow.dateRange.days = [\n { label: 'Måndag', value: '1', selected: false },\n { label: 'Tisdag', value: '2', selected: false },\n { label: 'Onsdag', value: '3', selected: false },\n { label: 'Torsdag', value: '4', selected: false },\n { label: 'Fredag', value: '5', selected: false },\n ];\n break;\n\n case 'da':\n this._defaultRow.dateRange.days = [\n { label: 'Mandag', value: '1', selected: false },\n { label: 'Tirsdag', value: '2', selected: false },\n { label: 'Onsdag', value: '3', selected: false },\n { label: 'Torsdag', value: '4', selected: false },\n { label: 'Fredag', value: '5', selected: false },\n ];\n break;\n\n case 'fi':\n this._defaultRow.dateRange.days = [\n { label: 'Maanantai', value: '1', selected: false },\n { label: 'Tiistai', value: '2', selected: false },\n { label: 'Keskiviikko', value: '3', selected: false },\n { label: 'Torstai', value: '4', selected: false },\n { label: 'Perjantai', value: '5', selected: false },\n ];\n break;\n\n case 'no':\n this._defaultRow.dateRange.days = [\n { label: 'Mandag', value: '1', selected: false },\n { label: 'Tirsdag', value: '2', selected: false },\n { label: 'Onsdag', value: '3', selected: false },\n { label: 'Torsdag', value: '4', selected: false },\n { label: 'Fredag', value: '5', selected: false },\n ];\n break;\n\n default:\n this._defaultRow.dateRange.days = [\n { label: 'Monday', value: '1', selected: false },\n { label: 'Tuesday', value: '2', selected: false },\n { label: 'Wednesday', value: '3', selected: false },\n { label: 'Thursday', value: '4', selected: false },\n { label: 'Friday', value: '5', selected: false },\n ];\n break;\n }\n }\n\n render() {\n return (\n <Host>\n {this.rowData?.map((data, i) => {\n return (\n <div class={'generated-row-' + i} id={'generated-row-connected-dropdown-' + i}>\n <pn-multi-row-connected-dropdown-row\n dropdown-data={this.dropdownData}\n language-code={this.languageCode}\n label={this.label}\n first-dropdown-label={this.firstDropdownLabel}\n second-dropdown-label={this.secondDropdownLabel}\n dropdown-placeholder={this.dropdownPlaceholder}\n add-row-text={this.addRowText}\n input-fild-label={this.inputFildLabel}\n input-fild-placeholder={this.inputFildPlaceholder}\n date-button-text={this.dateButtonText}\n date-placeholder={this.datePlaceholder}\n date-days-from-today={this.dateDaysFromToday}\n allow-multiple-dates={this.allowMultipleDates}\n start-date-label={this.startDateLabel}\n end-date-label={this.endDateLabel}\n multi-date-helper-text={this.multiDateHelperText}\n generate-dates-button-text={this.generateDatesButtonText}\n save-date-button-text={this.saveDateButtonText}\n no-dates-text={this.noDatesText}\n index={i}\n predefined-value={JSON.stringify(data)}\n years-to-add-to-end-date={this.yearsToAddToEndDate}\n ></pn-multi-row-connected-dropdown-row>\n </div>\n );\n })}\n\n {this.allowMultipleRows ? (\n <div class=\"connected-dropdown__row\">\n <pn-button\n tooltip={this.addRowText ? this.addRowText : null}\n left-icon=\"true\"\n arialabel=\"Add\"\n icon={plus}\n appearance=\"light\"\n variant=\"borderless\"\n class=\"connected-dropdown__button-right\"\n onClick={() => {\n this.addRow();\n }}\n >\n {this.addRowText}\n </pn-button>\n </div>\n ) : null}\n </Host>\n );\n }\n}\n"]}
|
|
@@ -4,13 +4,15 @@ import debounce from "debounce";
|
|
|
4
4
|
import { minus, plus } from "pn-design-assets/pn-assets/icons.js";
|
|
5
5
|
export class PnMultipleInput {
|
|
6
6
|
constructor() {
|
|
7
|
-
this.pnSlotElement = null;
|
|
8
|
-
this._formValues = [];
|
|
9
7
|
this.label = null;
|
|
10
8
|
this.placeholder = null;
|
|
11
9
|
this.addRowButtonText = null;
|
|
12
10
|
this.rowData = [];
|
|
13
11
|
}
|
|
12
|
+
hostElement;
|
|
13
|
+
pnSlotElement = null;
|
|
14
|
+
_formValues = [];
|
|
15
|
+
allFormValues;
|
|
14
16
|
componentWillLoad() {
|
|
15
17
|
const elemtnId = this.generateUniqueId();
|
|
16
18
|
const newRow = { id: elemtnId, input: '' };
|
|
@@ -56,7 +58,10 @@ export class PnMultipleInput {
|
|
|
56
58
|
if (index < 0) {
|
|
57
59
|
return;
|
|
58
60
|
}
|
|
59
|
-
this.rowData[index] =
|
|
61
|
+
this.rowData[index] = {
|
|
62
|
+
...this.rowData[index],
|
|
63
|
+
input: value,
|
|
64
|
+
};
|
|
60
65
|
this.emitValues();
|
|
61
66
|
}
|
|
62
67
|
emitValues() {
|
|
@@ -81,8 +86,7 @@ export class PnMultipleInput {
|
|
|
81
86
|
}
|
|
82
87
|
}
|
|
83
88
|
render() {
|
|
84
|
-
|
|
85
|
-
return (h(Host, { key: '0e11604bc1d4a9be1ff05d2f926ca39c4e20c369' }, h("div", { key: '0b5c1a99dce6934bd54f73e5d60eddb579fa1cb4', ref: el => (this.pnSlotElement = el), class: "multiple-input-slot" }, (_a = this.rowData) === null || _a === void 0 ? void 0 : _a.map((data, i) => {
|
|
89
|
+
return (h(Host, { key: '0e11604bc1d4a9be1ff05d2f926ca39c4e20c369' }, h("div", { key: '0b5c1a99dce6934bd54f73e5d60eddb579fa1cb4', ref: el => (this.pnSlotElement = el), class: "multiple-input-slot" }, this.rowData?.map((data, i) => {
|
|
86
90
|
return (h("div", { class: "multiple-input-generated-row" }, h("pn-marketweb-input", { label: this.label, type: "text", placeholder: this.placeholder, value: data.input, id: data.id }), i > 0 ? (h("pn-button", { arialabel: "Delete", icon: minus, appearance: "warning", onClick: () => {
|
|
87
91
|
this.deleteRow(i);
|
|
88
92
|
}, index: i, id: data.id }, "Delete")) : null));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pn-multiple-input.js","sourceRoot":"","sources":["../../../../src/components/input/pn-multiple-input/pn-multiple-input.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,EAAE,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,KAAK,EAAgB,MAAM,eAAe,CAAC;AAE9F,OAAO,EAAE,EAAE,IAAI,MAAM,EAAE,MAAM,MAAM,CAAC;AACpC,OAAO,QAAQ,MAAM,UAAU,CAAC;AAChC,OAAO,EAAE,KAAK,EAAE,IAAI,EAAE,MAAM,qCAAqC,CAAC;AAMlE,MAAM,OAAO,eAAe;;
|
|
1
|
+
{"version":3,"file":"pn-multiple-input.js","sourceRoot":"","sources":["../../../../src/components/input/pn-multiple-input/pn-multiple-input.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,EAAE,OAAO,EAAE,KAAK,EAA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AAW,EAAE,IAAI,CAAC,WAAW,EAAE,KAAK,EAAE,IAAI,CAAC,KAAK,EAAE,EAAE,EAAE,IAAI,CAAC,EAAE,GAAuB;oBACtI,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CACP,iBACE,SAAS,EAAC,QAAQ,EAClB,IAAI,EAAE,KAAK,EACX,UAAU,EAAC,SAAS,EACpB,OAAO,EAAE,GAAG,EAAE;4BACZ,IAAI,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC;wBACpB,CAAC,EACD,KAAK,EAAE,CAAC,EACR,EAAE,EAAE,IAAI,CAAC,EAAE,aAGD,CACb,CAAC,CAAC,CAAC,IAAI,CACJ,CACP,CAAC;YACJ,CAAC,CAAC,CACE;YACN,4DAAK,KAAK,EAAC,oBAAoB;gBAC7B,kEACE,OAAO,EAAE,IAAI,CAAC,gBAAgB,CAAC,CAAC,CAAC,IAAI,CAAC,gBAAgB,CAAC,CAAC,CAAC,IAAI,eACnD,MAAM,EAChB,SAAS,EAAC,KAAK,EACf,IAAI,EAAE,IAAI,EACV,UAAU,EAAC,OAAO,EAClB,OAAO,EAAC,YAAY,EACpB,KAAK,EAAC,kCAAkC,EACxC,OAAO,EAAE,GAAG,EAAE;wBACZ,IAAI,CAAC,MAAM,EAAE,CAAC;oBAChB,CAAC,IAEA,IAAI,CAAC,gBAAgB,CACZ,CACR,CACD,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, Prop, h, Element, State, Host, Event, EventEmitter } from '@stencil/core';\nimport { FormValue, Row, RowValue } from './types';\nimport { v4 as uuidv4 } from 'uuid';\nimport debounce from 'debounce';\nimport { minus, plus } from 'pn-design-assets/pn-assets/icons.js';\n\n@Component({\n tag: 'pn-multiple-input',\n styleUrl: 'pn-multiple-input.scss',\n})\nexport class PnMultipleInput {\n @Element() hostElement: Element;\n pnSlotElement: HTMLElement = null;\n\n @Prop() label: string = null;\n @Prop() placeholder: string = null;\n @Prop() addRowButtonText: string = null;\n\n @State() rowData: Row[] = [];\n\n private _formValues: FormValue[] = [];\n\n @Event() allFormValues: EventEmitter<string>;\n\n componentWillLoad() {\n const elemtnId = this.generateUniqueId();\n const newRow: Row = { id: elemtnId, input: '' };\n this.rowData = [...this.rowData, newRow];\n }\n\n componentDidLoad() {\n this.addEventHandlers();\n }\n\n componentDidUpdate() {\n this.addEventHandlers();\n }\n\n addEventHandlers() {\n const rows = this.pnSlotElement.querySelectorAll('pn-marketweb-input');\n\n rows.forEach(element => {\n element.addEventListener('keyup', debounce(this.handleInput.bind(this), 500));\n });\n }\n\n generateUniqueId() {\n return uuidv4();\n }\n\n deleteRow(indexToRemove) {\n if (indexToRemove < 0) {\n return;\n }\n\n this.rowData.splice(indexToRemove, 1);\n this.rowData = [...this.rowData];\n this.emitValues();\n }\n\n addRow() {\n const newRow: Row = { id: this.generateUniqueId(), input: '' };\n this.rowData = [...this.rowData, newRow];\n this.emitValues();\n }\n\n handleInput(e) {\n const target = e.target;\n const inputElm = target.closest('pn-marketweb-input');\n\n if (!inputElm) {\n return;\n }\n\n const inputElmId = inputElm.id;\n const value = target.value;\n const index = this.rowData.findIndex(item => item.id === inputElmId);\n\n if (index < 0) {\n return;\n }\n\n this.rowData[index] = {\n ...this.rowData[index],\n input: value,\n };\n\n this.emitValues();\n }\n\n emitValues() {\n this._formValues = [];\n const label = this.label ? this.label : 'InputField';\n this.rowData.forEach(item => {\n const rowValue: FormValue = { row: [] };\n if (item.input) {\n const dropDownValue: RowValue = { name: label, value: item.input };\n rowValue.row.push(dropDownValue);\n }\n\n if (rowValue.row.length === 1) {\n this._formValues.push(rowValue);\n }\n });\n\n if (this._formValues.length === this.rowData.length) {\n const valueJsonString = JSON.stringify(this._formValues);\n this.allFormValues.emit(valueJsonString);\n } else {\n this.allFormValues.emit('');\n }\n }\n\n render() {\n return (\n <Host>\n <div ref={el => (this.pnSlotElement = el as HTMLElement)} class=\"multiple-input-slot\">\n {this.rowData?.map((data, i) => {\n return (\n <div class=\"multiple-input-generated-row\">\n <pn-marketweb-input label={this.label} type=\"text\" placeholder={this.placeholder} value={data.input} id={data.id}></pn-marketweb-input>\n {i > 0 ? (\n <pn-button\n arialabel=\"Delete\"\n icon={minus}\n appearance=\"warning\"\n onClick={() => {\n this.deleteRow(i);\n }}\n index={i}\n id={data.id}\n >\n Delete\n </pn-button>\n ) : null}\n </div>\n );\n })}\n </div>\n <dvi class=\"multiple-input-row\">\n <pn-button\n tooltip={this.addRowButtonText ? this.addRowButtonText : null}\n left-icon=\"true\"\n arialabel=\"Add\"\n icon={plus}\n appearance=\"light\"\n variant=\"borderless\"\n class=\"connected-dropdown__button-right\"\n onClick={() => {\n this.addRow();\n }}\n >\n {this.addRowButtonText}\n </pn-button>\n </dvi>\n </Host>\n );\n }\n}\n"]}
|
package/collection/components/layout-components/pn-marketweb-sitefooter/pn-marketweb-sitefooter.js
CHANGED
|
@@ -5,10 +5,6 @@ import { getSocialMediaIconsByType } from "./socialMediaIcons";
|
|
|
5
5
|
import { translations } from "./translations";
|
|
6
6
|
export class PnMarketwebSiteheader {
|
|
7
7
|
constructor() {
|
|
8
|
-
// FetchHelper
|
|
9
|
-
this.fetchHelper = new FetchHelper('sitefooter');
|
|
10
|
-
//endpoint
|
|
11
|
-
this.endpointPath = '/api/footer/footer';
|
|
12
8
|
this.market = 'se';
|
|
13
9
|
this.language = 'sv';
|
|
14
10
|
this.environment = null;
|
|
@@ -24,13 +20,17 @@ export class PnMarketwebSiteheader {
|
|
|
24
20
|
this.gotData = false;
|
|
25
21
|
this.fetchingData = false;
|
|
26
22
|
}
|
|
23
|
+
hostElement;
|
|
24
|
+
// FetchHelper
|
|
25
|
+
fetchHelper = new FetchHelper('sitefooter');
|
|
26
|
+
//endpoint
|
|
27
|
+
endpointPath = '/api/footer/footer';
|
|
27
28
|
componentWillLoad() {
|
|
28
29
|
this.setInitialValues().then(() => {
|
|
29
30
|
this.init();
|
|
30
31
|
});
|
|
31
32
|
}
|
|
32
33
|
async setInitialValues(href = window.location.href) {
|
|
33
|
-
var _a;
|
|
34
34
|
const marketWebContextService = new MarketWebContextService(href);
|
|
35
35
|
if (!this.market) {
|
|
36
36
|
const resolvedMarket = await marketWebContextService.getMarket();
|
|
@@ -43,7 +43,7 @@ export class PnMarketwebSiteheader {
|
|
|
43
43
|
if (!this.environment) {
|
|
44
44
|
this.environment = await marketWebContextService.getEnvironmentName();
|
|
45
45
|
}
|
|
46
|
-
if (!this.endpoint &&
|
|
46
|
+
if (!this.endpoint && this.environment?.indexOf('local') === -1) {
|
|
47
47
|
this.endpoint = await marketWebContextService.getEndpoint(this.environment, this.market);
|
|
48
48
|
}
|
|
49
49
|
if (!this.endpoint) {
|
|
@@ -128,10 +128,9 @@ export class PnMarketwebSiteheader {
|
|
|
128
128
|
return 'footer-' + text.replace(/[^A-Za-z0-9.\\\/]/gim, '');
|
|
129
129
|
}
|
|
130
130
|
renderCols() {
|
|
131
|
-
|
|
132
|
-
if (this.gotData && ((_a = this.footerContent) === null || _a === void 0 ? void 0 : _a.columns)) {
|
|
131
|
+
if (this.gotData && this.footerContent?.columns) {
|
|
133
132
|
return this.footerContent.columns.map(column => {
|
|
134
|
-
return (h("pn-site-footer-col", { theme: this.theme }, column.firstLinkAsHeader && column.links && column.links[0] ? (h("a", { href: column.links[0].linkHref, target: column.links[0].openInNewWindow ? '_blank' : null, rel: column.links[0].openInNewWindow ? 'noopener nofollower noreferrer' : null, title: column.links[0].linkText, id: this.uniqueId(column.links[0].linkText) }, h("h3", null, column.links[0].linkText))) : (h("h3", null, column.heading)), column.links && (!column.body || this.theme === 'tpl') ? (h("ul",
|
|
133
|
+
return (h("pn-site-footer-col", { theme: this.theme }, column.firstLinkAsHeader && column.links && column.links[0] ? (h("a", { href: column.links[0].linkHref, target: column.links[0].openInNewWindow ? '_blank' : null, rel: column.links[0].openInNewWindow ? 'noopener nofollower noreferrer' : null, title: column.links[0].linkText, id: this.uniqueId(column.links[0].linkText) }, h("h3", null, column.links[0].linkText))) : (h("h3", null, column.heading)), column.links && (!column.body || this.theme === 'tpl') ? (h("ul", { ...(column.links && column.links[0] && column.links[0].linkType && { class: 'social-media' }) }, column.links.map((link, i) => {
|
|
135
134
|
if (!link.linkHref || (column.firstLinkAsHeader && i == 0)) {
|
|
136
135
|
return false;
|
|
137
136
|
}
|
|
@@ -140,7 +139,7 @@ export class PnMarketwebSiteheader {
|
|
|
140
139
|
linkText = getSocialMediaIconsByType(link.linkType);
|
|
141
140
|
}
|
|
142
141
|
let linkId = this.uniqueId(linkText);
|
|
143
|
-
return (h("li", null, h("a",
|
|
142
|
+
return (h("li", null, h("a", { href: link.linkHref, ...(link.openInNewWindow && { target: '_blank' }), title: link.linkText, innerHTML: linkText, id: linkId }, this.theme === 'tpl' ? h("span", { class: "footer-tpl-links" }, link.linkText) : null)));
|
|
144
143
|
}))) : null, column.body ? h("div", { innerHTML: column.body }) : null, h("slot", { name: "bottomsocialmediadesktop" }), h("slot", { name: "bottomsocialmediamobile" })));
|
|
145
144
|
});
|
|
146
145
|
}
|
|
@@ -154,35 +153,31 @@ export class PnMarketwebSiteheader {
|
|
|
154
153
|
return h("li", null, link.linkText);
|
|
155
154
|
}
|
|
156
155
|
let linkId = this.uniqueId(link.linkText);
|
|
157
|
-
return (h("li", null, h("a",
|
|
156
|
+
return (h("li", null, h("a", { href: link.linkHref, ...(link.openInNewWindow && { target: '_blank' }), title: link.linkText, id: linkId }, link.linkText)));
|
|
158
157
|
});
|
|
159
158
|
}
|
|
160
159
|
renderDefaultFooter() {
|
|
161
|
-
|
|
162
|
-
return (h(Host, { language: this.language, market: this.market, environment: this.environment }, h("pn-site-footer", { url: (_b = (_a = this.siteDefinition) === null || _a === void 0 ? void 0 : _a.url) !== null && _b !== void 0 ? _b : '' }, h("slot", { name: "logo" }), this.renderCols(), h("div", { slot: "bottom" }, this.gotData && ((_c = this.footerContent) === null || _c === void 0 ? void 0 : _c.copyrightText) ? h("span", null, this.footerContent.copyrightText) : null, this.gotData && ((_d = this.footerContent) === null || _d === void 0 ? void 0 : _d.bottomLinks) ? (h("span", null, this.footerContent.bottomLinks.map(link => {
|
|
160
|
+
return (h(Host, { language: this.language, market: this.market, environment: this.environment }, h("pn-site-footer", { url: this.siteDefinition?.url ?? '' }, h("slot", { name: "logo" }), this.renderCols(), h("div", { slot: "bottom" }, this.gotData && this.footerContent?.copyrightText ? h("span", null, this.footerContent.copyrightText) : null, this.gotData && this.footerContent?.bottomLinks ? (h("span", null, this.footerContent.bottomLinks.map(link => {
|
|
163
161
|
if (!link.linkHref) {
|
|
164
162
|
return h("span", null, link.linkText);
|
|
165
163
|
}
|
|
166
164
|
let linkId = this.uniqueId(link.linkText);
|
|
167
|
-
return (h("a",
|
|
165
|
+
return (h("a", { href: link.linkHref, ...(link.openInNewWindow && { target: '_blank' }), title: link.linkText, id: linkId }, link.linkText));
|
|
168
166
|
}))) : null))));
|
|
169
167
|
}
|
|
170
168
|
renderSocialMeidaIconListElements() {
|
|
171
|
-
var _a;
|
|
172
169
|
return (this.gotData &&
|
|
173
|
-
|
|
170
|
+
this.footerContent?.socialmedialinks.map(link => {
|
|
174
171
|
let linkText = getSocialMediaIconsByType(link.linkType, '#00A0D6');
|
|
175
172
|
let linkId = this.uniqueId(link.linkText);
|
|
176
|
-
return (h("li", null, h("a",
|
|
177
|
-
}))
|
|
173
|
+
return (h("li", null, h("a", { href: link.linkHref, ...(link.openInNewWindow && { target: '_blank' }), title: link.linkText, innerHTML: linkText, id: linkId })));
|
|
174
|
+
}));
|
|
178
175
|
}
|
|
179
176
|
renderSwanComponent() {
|
|
180
|
-
|
|
181
|
-
return (this.showSwan && (h("div", { class: "swan-wrapper" }, h("div", { class: "separator" }), h("pn-swan", { language: this.language, "license-number": (_b = (_a = this.footerContent) === null || _a === void 0 ? void 0 : _a.swanInfo) === null || _b === void 0 ? void 0 : _b.swanLicense, "link-to": (_d = (_c = this.footerContent) === null || _c === void 0 ? void 0 : _c.swanInfo) === null || _d === void 0 ? void 0 : _d.swanLink }))));
|
|
177
|
+
return (this.showSwan && (h("div", { class: "swan-wrapper" }, h("div", { class: "separator" }), h("pn-swan", { language: this.language, "license-number": this.footerContent?.swanInfo?.swanLicense, "link-to": this.footerContent?.swanInfo?.swanLink }))));
|
|
182
178
|
}
|
|
183
179
|
renderDotComFooter() {
|
|
184
|
-
|
|
185
|
-
return (h(Host, { language: this.language, market: this.market, environment: this.environment }, h("pn-site-footer", { theme: this.theme, url: (_b = (_a = this.siteDefinition) === null || _a === void 0 ? void 0 : _a.url) !== null && _b !== void 0 ? _b : '' }, this.renderCols(), h("slot", { name: "middle-extra" }), h("slot", { name: "middle-extra-mobile" }), h("div", { slot: "bottom" }, h("div", { class: `social-media ${this.showSwan ? 'social-media--swan' : ''}` }, h("ul", null, this.renderSocialMeidaIconListElements()), this.renderSwanComponent()), h("div", { class: "copyright" }, this.gotData && ((_c = this.footerContent) === null || _c === void 0 ? void 0 : _c.copyrightText) ? h("span", null, this.footerContent.copyrightText) : null, this.gotData && ((_d = this.footerContent) === null || _d === void 0 ? void 0 : _d.bottomLinks) ? h("ul", null, this.renderBottomLinks()) : null)))));
|
|
180
|
+
return (h(Host, { language: this.language, market: this.market, environment: this.environment }, h("pn-site-footer", { theme: this.theme, url: this.siteDefinition?.url ?? '' }, this.renderCols(), h("slot", { name: "middle-extra" }), h("slot", { name: "middle-extra-mobile" }), h("div", { slot: "bottom" }, h("div", { class: `social-media ${this.showSwan ? 'social-media--swan' : ''}` }, h("ul", null, this.renderSocialMeidaIconListElements()), this.renderSwanComponent()), h("div", { class: "copyright" }, this.gotData && this.footerContent?.copyrightText ? h("span", null, this.footerContent.copyrightText) : null, this.gotData && this.footerContent?.bottomLinks ? h("ul", null, this.renderBottomLinks()) : null)))));
|
|
186
181
|
}
|
|
187
182
|
render() {
|
|
188
183
|
switch (this.theme) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pn-marketweb-sitefooter.js","sourceRoot":"","sources":["../../../../src/components/layout-components/pn-marketweb-sitefooter/pn-marketweb-sitefooter.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,IAAI,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AAEhF,OAAO,EAAE,WAAW,EAAE,MAAM,8BAA8B,CAAC;AAC3D,OAAO,EAAE,uBAAuB,EAAE,MAAM,0CAA0C,CAAC;AAEnF,OAAO,EAAE,yBAAyB,EAAE,MAAM,oBAAoB,CAAC;AAC/D,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAM9C,MAAM,OAAO,qBAAqB;;QAiChC,cAAc;QACd,gBAAW,GAAG,IAAI,WAAW,CAAC,YAAY,CAAC,CAAC;QAE5C,UAAU;QACV,iBAAY,GAAG,oBAAoB,CAAC;sBAjCqB,IAAI;wBAEF,IAAI;2BAED,IAAI;wBAEvC,IAAI;gCAGK,KAAK;qBAGhB,KAAK;qBAGW,SAAS;+BAEC,aAAa;wBAGpC,KAAK;;;;uBAML,KAAK;4BACA,KAAK;;IAQtC,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,IAAI,CAAC,IAAI,CAAC,MAAM,EAAE,CAAC;YACjB,MAAM,cAAc,GAAG,MAAM,uBAAuB,CAAC,SAAS,EAAE,CAAC;YACjE,IAAI,CAAC,MAAM,GAAG,cAAc,CAAC;QAC/B,CAAC;QACD,IAAI,CAAC,IAAI,CA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;wBACnB,IAAI,CAAC,OAAO,KAAI,MAAA,IAAI,CAAC,aAAa,0CAAE,aAAa,CAAA,CAAC,CAAC,CAAC,gBAAO,IAAI,CAAC,aAAa,CAAC,aAAa,CAAQ,CAAC,CAAC,CAAC,IAAI;wBAC1G,IAAI,CAAC,OAAO,KAAI,MAAA,IAAI,CAAC,aAAa,0CAAE,WAAW,CAAA,CAAC,CAAC,CAAC,cAAK,IAAI,CAAC,iBAAiB,EAAE,CAAM,CAAC,CAAC,CAAC,IAAI,CACzF,CACF,CACS,CACZ,CACR,CAAC;IACJ,CAAC;IAED,MAAM;QACJ,QAAQ,IAAI,CAAC,KAAK,EAAE,CAAC;YACnB,KAAK,QAAQ;gBACX,OAAO,IAAI,CAAC,kBAAkB,EAAE,CAAC;YACnC;gBACE,OAAO,IAAI,CAAC,mBAAmB,EAAE,CAAC;QACtC,CAAC;IACH,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, Element, h, Host, Prop, State, Watch } from '@stencil/core';\n\nimport { FetchHelper } from '../../../globals/FetchHelper';\nimport { MarketWebContextService } from '../../../globals/MarketWebContextService';\nimport { MenuSiteDefinition, SiteFooterContentModel } from './pn-marketweb-sitefooter-types';\nimport { getSocialMediaIconsByType } from './socialMediaIcons';\nimport { translations } from './translations';\n\n@Component({\n tag: 'pn-marketweb-sitefooter',\n styleUrl: 'pn-marketweb-sitefooter.scss',\n})\nexport class PnMarketwebSiteheader {\n @Element() hostElement: Element;\n\n /** Specifies which market we want to show (se,dk,fi,no,com) */\n @Prop({ mutable: true, reflect: true }) market: string = 'se';\n /** Specifies which language we want to show (sv,da,fi,no,en) */\n @Prop({ mutable: true, reflect: true }) language: string = 'sv';\n /** Specifies which environment we're fetching data from. (production, preproduction, integration, localhost) */\n @Prop({ mutable: true, reflect: true }) environment: string = null; //sv\n /** Specifies which endpoint domain we should load from */\n @Prop() endpoint: string = null;\n\n /** Adjusts the menus URLs */\n @Prop() siteDomainInUrls: boolean = false;\n\n /** If the component should use cached requests */\n @Prop() cache: boolean = false;\n\n /** dotcom prop */\n @Prop({ reflect: true }) theme: string = 'default';\n /** dotcom backgroundcolor */\n @Prop({ reflect: true }) backgroundcolor: string = 'darkestblue';\n\n /** swan flag - default false */\n @Prop() showSwan: boolean = false;\n\n @State() siteDefinition: MenuSiteDefinition;\n @State() footerContent: SiteFooterContentModel;\n\n @State() i18n: any;\n @State() gotData: boolean = false;\n @State() fetchingData: boolean = false;\n\n // FetchHelper\n fetchHelper = new FetchHelper('sitefooter');\n\n //endpoint\n endpointPath = '/api/footer/footer';\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 if (!this.market) {\n const resolvedMarket = await marketWebContextService.getMarket();\n this.market = resolvedMarket;\n }\n if (!this.language) {\n const resolvedMarket = await marketWebContextService.getLanguage();\n this.language = resolvedMarket;\n }\n if (!this.environment) {\n this.environment = await marketWebContextService.getEnvironmentName();\n }\n if (!this.endpoint && this.environment?.indexOf('local') === -1) {\n this.endpoint = await marketWebContextService.getEndpoint(this.environment, this.market);\n }\n if (!this.endpoint) {\n this.endpoint = '';\n }\n }\n\n async init() {\n this.setTranslations();\n await this.fetchData();\n }\n\n setTranslations() {\n if (this.language && translations[this.language]) {\n this.i18n = translations[this.language];\n }\n }\n\n @Watch('language')\n onLanguageChange() {\n this.setTranslations();\n this.fetchData();\n }\n\n @Watch('market')\n onMarketChange() {\n this.fetchData();\n }\n\n setFetchUrl(endpointBase: string) {\n switch (this.theme) {\n case 'dotcom':\n return `${endpointBase}${this.endpointPath}?market=${this.market}&language=${this.language}&breakOutSocialMedia=true&extendColumns=true`;\n default:\n return `${endpointBase}${this.endpointPath}?market=${this.market}&language=${this.language}`;\n }\n }\n\n async fetchData() {\n if (this.endpoint === null || !this.market || !this.language) {\n // console.warn(`One or more values where not specified.\\nEndpoint: ${this.endpoint}\\nMarket: ${this.market}\\nLanguage: ${this.language}`)\n return;\n }\n\n this.fetchingData = true;\n const endpointBase = this.endpoint.lastIndexOf('/') === this.endpoint.length - 1 ? this.endpoint.substring(0, this.endpoint.length - 1) : this.endpoint;\n const fetchUrl = this.setFetchUrl(endpointBase);\n const data = (await this.fetchHelper.fetchJson(\n fetchUrl,\n {\n mode: 'cors',\n },\n this.cache,\n this.onFetchRefreshed.bind(this),\n )) as any;\n await this.setStateFromData(data);\n }\n\n onFetchRefreshed(data) {\n this.setStateFromData(data);\n }\n\n setStateFromData(data: any) {\n if (typeof data !== 'object') {\n console.warn('Data was not valid', data);\n }\n\n // Set site definition\n this.siteDefinition = data.sitedefinition;\n\n // Set footer content\n this.footerContent = data.footer;\n\n if (this.siteDomainInUrls) {\n this.adjustLinks();\n }\n\n this.gotData = true;\n this.fetchingData = true;\n }\n adjustLinks() {\n this.footerContent.bottomLinks.forEach(link => {\n link.linkHref = this.adjustHref(link.linkHref);\n });\n this.footerContent.columns.forEach(col => {\n col.links.forEach(link => {\n link.linkHref = this.adjustHref(link.linkHref);\n });\n });\n }\n\n adjustHref(href: string) {\n if (!href || href.indexOf('http') === 0 || this.siteDomainInUrls) {\n return href;\n }\n const domainUrl =\n this.siteDefinition.url.lastIndexOf('/') === this.siteDefinition.url.length - 1\n ? this.siteDefinition.url.substring(0, this.siteDefinition.url.length - 1)\n : this.siteDefinition.url;\n href = domainUrl + href;\n return href;\n }\n\n uniqueId(text: string) {\n return 'footer-' + text.replace(/[^A-Za-z0-9.\\\\\\/]/gim, '');\n }\n\n renderCols() {\n if (this.gotData && this.footerContent?.columns) {\n return this.footerContent.columns.map(column => {\n return (\n <pn-site-footer-col theme={this.theme}>\n {column.firstLinkAsHeader && column.links && column.links[0] ? (\n <a\n href={column.links[0].linkHref}\n target={column.links[0].openInNewWindow ? '_blank' : null}\n rel={column.links[0].openInNewWindow ? 'noopener nofollower noreferrer' : null}\n title={column.links[0].linkText}\n id={this.uniqueId(column.links[0].linkText)}\n >\n <h3>{column.links[0].linkText}</h3>\n </a>\n ) : (\n <h3>{column.heading}</h3>\n )}\n {column.links && (!column.body || this.theme === 'tpl') ? (\n <ul {...(column.links && column.links[0] && column.links[0].linkType && { class: 'social-media' })}>\n {column.links.map((link, i) => {\n if (!link.linkHref || (column.firstLinkAsHeader && i == 0)) {\n return false;\n }\n let linkText = link.linkText;\n if (link.linkType) {\n linkText = getSocialMediaIconsByType(link.linkType);\n }\n let linkId = this.uniqueId(linkText);\n return (\n <li>\n <a href={link.linkHref} {...(link.openInNewWindow && { target: '_blank' })} title={link.linkText} innerHTML={linkText} id={linkId}>\n {this.theme === 'tpl' ? <span class=\"footer-tpl-links\">{link.linkText}</span> : null}\n </a>\n </li>\n );\n })}\n </ul>\n ) : null}\n {column.body ? <div innerHTML={column.body}></div> : null}\n <slot name=\"bottomsocialmediadesktop\" />\n <slot name=\"bottomsocialmediamobile\" />\n </pn-site-footer-col>\n );\n });\n } else {\n return null;\n }\n }\n\n renderBottomLinks() {\n return this.footerContent.bottomLinks.map(link => {\n if (!link.linkHref) {\n return <li>{link.linkText}</li>;\n }\n let linkId = this.uniqueId(link.linkText);\n\n return (\n <li>\n <a href={link.linkHref} {...(link.openInNewWindow && { target: '_blank' })} title={link.linkText} id={linkId}>\n {link.linkText}\n </a>\n </li>\n );\n });\n }\n\n renderDefaultFooter() {\n return (\n <Host language={this.language} market={this.market} environment={this.environment}>\n <pn-site-footer url={this.siteDefinition?.url ?? ''}>\n <slot name=\"logo\"></slot>\n {this.renderCols()}\n\n <div slot=\"bottom\">\n {this.gotData && this.footerContent?.copyrightText ? <span>{this.footerContent.copyrightText}</span> : null}\n {this.gotData && this.footerContent?.bottomLinks ? (\n <span>\n {this.footerContent.bottomLinks.map(link => {\n if (!link.linkHref) {\n return <span>{link.linkText}</span>;\n }\n let linkId = this.uniqueId(link.linkText);\n return (\n <a href={link.linkHref} {...(link.openInNewWindow && { target: '_blank' })} title={link.linkText} id={linkId}>\n {link.linkText}\n </a>\n );\n })}\n </span>\n ) : null}\n </div>\n </pn-site-footer>\n </Host>\n );\n }\n\n renderSocialMeidaIconListElements() {\n return (\n this.gotData &&\n this.footerContent?.socialmedialinks.map(link => {\n let linkText = getSocialMediaIconsByType(link.linkType, '#00A0D6');\n let linkId = this.uniqueId(link.linkText);\n return (\n <li>\n <a href={link.linkHref} {...(link.openInNewWindow && { target: '_blank' })} title={link.linkText} innerHTML={linkText} id={linkId}></a>\n </li>\n );\n })\n );\n }\n\n renderSwanComponent() {\n return (\n this.showSwan && (\n <div class=\"swan-wrapper\">\n <div class=\"separator\"></div>\n <pn-swan language={this.language} license-number={this.footerContent?.swanInfo?.swanLicense} link-to={this.footerContent?.swanInfo?.swanLink} />\n </div>\n )\n );\n }\n\n renderDotComFooter() {\n return (\n <Host language={this.language} market={this.market} environment={this.environment}>\n <pn-site-footer theme={this.theme} url={this.siteDefinition?.url ?? ''}>\n {this.renderCols()}\n <slot name=\"middle-extra\"></slot>\n <slot name=\"middle-extra-mobile\"></slot>\n <div slot=\"bottom\">\n <div class={`social-media ${this.showSwan ? 'social-media--swan' : ''}`}>\n <ul>{this.renderSocialMeidaIconListElements()}</ul>\n {this.renderSwanComponent()}\n </div>\n\n <div class=\"copyright\">\n {this.gotData && this.footerContent?.copyrightText ? <span>{this.footerContent.copyrightText}</span> : null}\n {this.gotData && this.footerContent?.bottomLinks ? <ul>{this.renderBottomLinks()}</ul> : null}\n </div>\n </div>\n </pn-site-footer>\n </Host>\n );\n }\n\n render() {\n switch (this.theme) {\n case 'dotcom':\n return this.renderDotComFooter();\n default:\n return this.renderDefaultFooter();\n }\n }\n}\n"]}
|
|
1
|
+
{"version":3,"file":"pn-marketweb-sitefoo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IAAI,CAAC,OAAO,IAAI,IAAI,CAAC,aAAa,EAAE,WAAW,CAAC,CAAC,CAAC,cAAK,IAAI,CAAC,iBAAiB,EAAE,CAAM,CAAC,CAAC,CAAC,IAAI,CACzF,CACF,CACS,CACZ,CACR,CAAC;IACJ,CAAC;IAED,MAAM;QACJ,QAAQ,IAAI,CAAC,KAAK,EAAE,CAAC;YACnB,KAAK,QAAQ;gBACX,OAAO,IAAI,CAAC,kBAAkB,EAAE,CAAC;YACnC;gBACE,OAAO,IAAI,CAAC,mBAAmB,EAAE,CAAC;QACtC,CAAC;IACH,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, Element, h, Host, Prop, State, Watch } from '@stencil/core';\n\nimport { FetchHelper } from '../../../globals/FetchHelper';\nimport { MarketWebContextService } from '../../../globals/MarketWebContextService';\nimport { MenuSiteDefinition, SiteFooterContentModel } from './pn-marketweb-sitefooter-types';\nimport { getSocialMediaIconsByType } from './socialMediaIcons';\nimport { translations } from './translations';\n\n@Component({\n tag: 'pn-marketweb-sitefooter',\n styleUrl: 'pn-marketweb-sitefooter.scss',\n})\nexport class PnMarketwebSiteheader {\n @Element() hostElement: Element;\n\n /** Specifies which market we want to show (se,dk,fi,no,com) */\n @Prop({ mutable: true, reflect: true }) market: string = 'se';\n /** Specifies which language we want to show (sv,da,fi,no,en) */\n @Prop({ mutable: true, reflect: true }) language: string = 'sv';\n /** Specifies which environment we're fetching data from. (production, preproduction, integration, localhost) */\n @Prop({ mutable: true, reflect: true }) environment: string = null; //sv\n /** Specifies which endpoint domain we should load from */\n @Prop() endpoint: string = null;\n\n /** Adjusts the menus URLs */\n @Prop() siteDomainInUrls: boolean = false;\n\n /** If the component should use cached requests */\n @Prop() cache: boolean = false;\n\n /** dotcom prop */\n @Prop({ reflect: true }) theme: string = 'default';\n /** dotcom backgroundcolor */\n @Prop({ reflect: true }) backgroundcolor: string = 'darkestblue';\n\n /** swan flag - default false */\n @Prop() showSwan: boolean = false;\n\n @State() siteDefinition: MenuSiteDefinition;\n @State() footerContent: SiteFooterContentModel;\n\n @State() i18n: any;\n @State() gotData: boolean = false;\n @State() fetchingData: boolean = false;\n\n // FetchHelper\n fetchHelper = new FetchHelper('sitefooter');\n\n //endpoint\n endpointPath = '/api/footer/footer';\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 if (!this.market) {\n const resolvedMarket = await marketWebContextService.getMarket();\n this.market = resolvedMarket;\n }\n if (!this.language) {\n const resolvedMarket = await marketWebContextService.getLanguage();\n this.language = resolvedMarket;\n }\n if (!this.environment) {\n this.environment = await marketWebContextService.getEnvironmentName();\n }\n if (!this.endpoint && this.environment?.indexOf('local') === -1) {\n this.endpoint = await marketWebContextService.getEndpoint(this.environment, this.market);\n }\n if (!this.endpoint) {\n this.endpoint = '';\n }\n }\n\n async init() {\n this.setTranslations();\n await this.fetchData();\n }\n\n setTranslations() {\n if (this.language && translations[this.language]) {\n this.i18n = translations[this.language];\n }\n }\n\n @Watch('language')\n onLanguageChange() {\n this.setTranslations();\n this.fetchData();\n }\n\n @Watch('market')\n onMarketChange() {\n this.fetchData();\n }\n\n setFetchUrl(endpointBase: string) {\n switch (this.theme) {\n case 'dotcom':\n return `${endpointBase}${this.endpointPath}?market=${this.market}&language=${this.language}&breakOutSocialMedia=true&extendColumns=true`;\n default:\n return `${endpointBase}${this.endpointPath}?market=${this.market}&language=${this.language}`;\n }\n }\n\n async fetchData() {\n if (this.endpoint === null || !this.market || !this.language) {\n // console.warn(`One or more values where not specified.\\nEndpoint: ${this.endpoint}\\nMarket: ${this.market}\\nLanguage: ${this.language}`)\n return;\n }\n\n this.fetchingData = true;\n const endpointBase = this.endpoint.lastIndexOf('/') === this.endpoint.length - 1 ? this.endpoint.substring(0, this.endpoint.length - 1) : this.endpoint;\n const fetchUrl = this.setFetchUrl(endpointBase);\n const data = (await this.fetchHelper.fetchJson(\n fetchUrl,\n {\n mode: 'cors',\n },\n this.cache,\n this.onFetchRefreshed.bind(this),\n )) as any;\n await this.setStateFromData(data);\n }\n\n onFetchRefreshed(data) {\n this.setStateFromData(data);\n }\n\n setStateFromData(data: any) {\n if (typeof data !== 'object') {\n console.warn('Data was not valid', data);\n }\n\n // Set site definition\n this.siteDefinition = data.sitedefinition;\n\n // Set footer content\n this.footerContent = data.footer;\n\n if (this.siteDomainInUrls) {\n this.adjustLinks();\n }\n\n this.gotData = true;\n this.fetchingData = true;\n }\n adjustLinks() {\n this.footerContent.bottomLinks.forEach(link => {\n link.linkHref = this.adjustHref(link.linkHref);\n });\n this.footerContent.columns.forEach(col => {\n col.links.forEach(link => {\n link.linkHref = this.adjustHref(link.linkHref);\n });\n });\n }\n\n adjustHref(href: string) {\n if (!href || href.indexOf('http') === 0 || this.siteDomainInUrls) {\n return href;\n }\n const domainUrl =\n this.siteDefinition.url.lastIndexOf('/') === this.siteDefinition.url.length - 1\n ? this.siteDefinition.url.substring(0, this.siteDefinition.url.length - 1)\n : this.siteDefinition.url;\n href = domainUrl + href;\n return href;\n }\n\n uniqueId(text: string) {\n return 'footer-' + text.replace(/[^A-Za-z0-9.\\\\\\/]/gim, '');\n }\n\n renderCols() {\n if (this.gotData && this.footerContent?.columns) {\n return this.footerContent.columns.map(column => {\n return (\n <pn-site-footer-col theme={this.theme}>\n {column.firstLinkAsHeader && column.links && column.links[0] ? (\n <a\n href={column.links[0].linkHref}\n target={column.links[0].openInNewWindow ? '_blank' : null}\n rel={column.links[0].openInNewWindow ? 'noopener nofollower noreferrer' : null}\n title={column.links[0].linkText}\n id={this.uniqueId(column.links[0].linkText)}\n >\n <h3>{column.links[0].linkText}</h3>\n </a>\n ) : (\n <h3>{column.heading}</h3>\n )}\n {column.links && (!column.body || this.theme === 'tpl') ? (\n <ul {...(column.links && column.links[0] && column.links[0].linkType && { class: 'social-media' })}>\n {column.links.map((link, i) => {\n if (!link.linkHref || (column.firstLinkAsHeader && i == 0)) {\n return false;\n }\n let linkText = link.linkText;\n if (link.linkType) {\n linkText = getSocialMediaIconsByType(link.linkType);\n }\n let linkId = this.uniqueId(linkText);\n return (\n <li>\n <a href={link.linkHref} {...(link.openInNewWindow && { target: '_blank' })} title={link.linkText} innerHTML={linkText} id={linkId}>\n {this.theme === 'tpl' ? <span class=\"footer-tpl-links\">{link.linkText}</span> : null}\n </a>\n </li>\n );\n })}\n </ul>\n ) : null}\n {column.body ? <div innerHTML={column.body}></div> : null}\n <slot name=\"bottomsocialmediadesktop\" />\n <slot name=\"bottomsocialmediamobile\" />\n </pn-site-footer-col>\n );\n });\n } else {\n return null;\n }\n }\n\n renderBottomLinks() {\n return this.footerContent.bottomLinks.map(link => {\n if (!link.linkHref) {\n return <li>{link.linkText}</li>;\n }\n let linkId = this.uniqueId(link.linkText);\n\n return (\n <li>\n <a href={link.linkHref} {...(link.openInNewWindow && { target: '_blank' })} title={link.linkText} id={linkId}>\n {link.linkText}\n </a>\n </li>\n );\n });\n }\n\n renderDefaultFooter() {\n return (\n <Host language={this.language} market={this.market} environment={this.environment}>\n <pn-site-footer url={this.siteDefinition?.url ?? ''}>\n <slot name=\"logo\"></slot>\n {this.renderCols()}\n\n <div slot=\"bottom\">\n {this.gotData && this.footerContent?.copyrightText ? <span>{this.footerContent.copyrightText}</span> : null}\n {this.gotData && this.footerContent?.bottomLinks ? (\n <span>\n {this.footerContent.bottomLinks.map(link => {\n if (!link.linkHref) {\n return <span>{link.linkText}</span>;\n }\n let linkId = this.uniqueId(link.linkText);\n return (\n <a href={link.linkHref} {...(link.openInNewWindow && { target: '_blank' })} title={link.linkText} id={linkId}>\n {link.linkText}\n </a>\n );\n })}\n </span>\n ) : null}\n </div>\n </pn-site-footer>\n </Host>\n );\n }\n\n renderSocialMeidaIconListElements() {\n return (\n this.gotData &&\n this.footerContent?.socialmedialinks.map(link => {\n let linkText = getSocialMediaIconsByType(link.linkType, '#00A0D6');\n let linkId = this.uniqueId(link.linkText);\n return (\n <li>\n <a href={link.linkHref} {...(link.openInNewWindow && { target: '_blank' })} title={link.linkText} innerHTML={linkText} id={linkId}></a>\n </li>\n );\n })\n );\n }\n\n renderSwanComponent() {\n return (\n this.showSwan && (\n <div class=\"swan-wrapper\">\n <div class=\"separator\"></div>\n <pn-swan language={this.language} license-number={this.footerContent?.swanInfo?.swanLicense} link-to={this.footerContent?.swanInfo?.swanLink} />\n </div>\n )\n );\n }\n\n renderDotComFooter() {\n return (\n <Host language={this.language} market={this.market} environment={this.environment}>\n <pn-site-footer theme={this.theme} url={this.siteDefinition?.url ?? ''}>\n {this.renderCols()}\n <slot name=\"middle-extra\"></slot>\n <slot name=\"middle-extra-mobile\"></slot>\n <div slot=\"bottom\">\n <div class={`social-media ${this.showSwan ? 'social-media--swan' : ''}`}>\n <ul>{this.renderSocialMeidaIconListElements()}</ul>\n {this.renderSwanComponent()}\n </div>\n\n <div class=\"copyright\">\n {this.gotData && this.footerContent?.copyrightText ? <span>{this.footerContent.copyrightText}</span> : null}\n {this.gotData && this.footerContent?.bottomLinks ? <ul>{this.renderBottomLinks()}</ul> : null}\n </div>\n </div>\n </pn-site-footer>\n </Host>\n );\n }\n\n render() {\n switch (this.theme) {\n case 'dotcom':\n return this.renderDotComFooter();\n default:\n return this.renderDefaultFooter();\n }\n }\n}\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pn-marketweb-siteheader-login-button.js","sourceRoot":"","sources":["../../../../src/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-login-button.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,eAAe,CAAC;AAElE,OAAO,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAMnD,MAAM,OAAO,gCAAgC;;qBAEnB,QAAQ;;
|
|
1
|
+
{"version":3,"file":"pn-marketweb-siteheader-login-button.js","sourceRoot":"","sources":["../../../../src/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-login-button.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,eAAe,CAAC;AAElE,OAAO,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAMnD,MAAM,OAAO,gCAAgC;;qBAEnB,QAAQ;;IADrB,WAAW,CAAc;IAGpC,QAAQ,CAAS;IAEjB,iBAAiB;QACf,IAAI,CAAC,QAAQ,GAAG,WAAW,CAAC,MAAM,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC;IACpD,CAAC;IAED,kBAAkB;QAChB,MAAM,aAAa,GAAG,GAAG,IAAI,CAAC,QAAQ,GAAG,MAAM,CAAC,QAAQ,CAAC,IAAI,EAAE,CAAC;QAChE,OAAO,aAAa,CAAC;IACvB,CAAC;IAED,MAAM;QACJ,OAAO,CACL,EAAC,IAAI;YACH,kEAAW,IAAI,EAAE,IAAI,CAAC,kBAAkB,EAAE,IAAG,IAAI,CAAC,KAAK,CAAa,CAC/D,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, Element, h, Host, Prop } from '@stencil/core';\n\nimport { getLoginUrl } from './unifiedLoginHelper';\n\n@Component({\n tag: 'pn-marketweb-siteheader-login-button',\n styleUrl: 'pn-marketweb-siteheader-login-button.scss',\n})\nexport class PnMarketwebSiteheaderLoginButton {\n @Element() hostElement: HTMLElement;\n @Prop() label: string = 'Log in';\n\n loginUrl: string;\n\n componentWillLoad() {\n this.loginUrl = getLoginUrl(window.location.host);\n }\n\n nagivateToLoginUrl() {\n const navigationUrl = `${this.loginUrl}${window.location.href}`;\n return navigationUrl;\n }\n\n render() {\n return (\n <Host>\n <pn-button href={this.nagivateToLoginUrl()}>{this.label}</pn-button>\n </Host>\n );\n }\n}\n"]}
|
|
@@ -8,6 +8,7 @@ export class PnMarketwebSiteheaderLoginLinklist {
|
|
|
8
8
|
this.idNamespace = '';
|
|
9
9
|
this.showUnifiedLogin = false;
|
|
10
10
|
}
|
|
11
|
+
hostElement;
|
|
11
12
|
componentWillLoad() { }
|
|
12
13
|
uniqueId(text) {
|
|
13
14
|
return 'loginlink-' + text.replace(/[^A-Za-z0-9.\\\/]/gim, '') + '-' + this.idNamespace;
|
|
@@ -47,18 +48,18 @@ export class PnMarketwebSiteheaderLoginLinklist {
|
|
|
47
48
|
return attributes;
|
|
48
49
|
}
|
|
49
50
|
renderListAsButtons(link) {
|
|
50
|
-
return (h("li", null, h("pn-button",
|
|
51
|
+
return (h("li", null, h("pn-button", { href: link.href, id: this.uniqueId(link.linkText), ...(link.openInNewWindow && { target: '_blank' }), ...this.linkAppearanceAttributes(link), onClick: () => {
|
|
51
52
|
if (link.isLogoutLink) {
|
|
52
53
|
headerState.loginManager.clearUserData();
|
|
53
54
|
}
|
|
54
|
-
} }
|
|
55
|
+
} }, link.linkText)));
|
|
55
56
|
}
|
|
56
57
|
renderListAsLinks(link) {
|
|
57
|
-
return (h("li", null, h("a",
|
|
58
|
+
return (h("li", null, h("a", { href: link.href, id: this.uniqueId(link.linkText), ...(link.openInNewWindow && { target: '_blank' }), onClick: () => {
|
|
58
59
|
if (link.isLogoutLink) {
|
|
59
60
|
headerState.loginManager.clearUserData();
|
|
60
61
|
}
|
|
61
|
-
} }
|
|
62
|
+
} }, link.linkText, link.isLogoutLink ? h("pn-icon", { icon: transfer }) : h("pn-icon", { icon: arrow_right }))));
|
|
62
63
|
}
|
|
63
64
|
render() {
|
|
64
65
|
if (!this.links || this.links.length === 0) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pn-marketweb-siteheader-login-linklist.js","sourceRoot":"","sources":["../../../../src/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-login-linklist.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,eAAe,CAAC;AAElE,OAAO,EAAE,KAAK,IAAI,WAAW,EAAE,MAAM,iCAAiC,CAAC;AAEvE,OAAO,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,qCAAqC,CAAC;AAM5E,MAAM,OAAO,kCAAkC;;uBAGnB,IAAI;qBACK,EAAE;2BACP,EAAE;gCACI,KAAK;;
|
|
1
|
+
{"version":3,"file":"pn-marketweb-siteheader-login-linklist.js","sourceRoot":"","sources":["../../../../src/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-login-linklist.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,eAAe,CAAC;AAElE,OAAO,EAAE,KAAK,IAAI,WAAW,EAAE,MAAM,iCAAiC,CAAC;AAEvE,OAAO,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,qCAAqC,CAAC;AAM5E,MAAM,OAAO,kCAAkC;;uBAGnB,IAAI;qBACK,EAAE;2BACP,EAAE;gCACI,KAAK;;IAL9B,WAAW,CAAc;IAOpC,iBAAiB,KAAI,CAAC;IAEtB,QAAQ,CAAC,IAAY;QACnB,OAAO,YAAY,GAAG,IAAI,CAAC,OAAO,CAAC,sBAAsB,EAAE,EAAE,CAAC,GAAG,GAAG,GAAG,IAAI,CAAC,WAAW,CAAC;IAC1F,CAAC;IAED,wBAAwB,CAAC,IAAI;QAC3B,IAAI,UAAU,GAAG,EAAE,CAAC;QACpB,IAAI,IAAI,CAAC,QAAQ,EAAE,CAAC;YAClB,QAAQ,IAAI,CAAC,QAAQ,EAAE,CAA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C,IAAI,CAAC,QAAQ,CAAC,KAC5B,CAAC,IAAI,CAAC,eAAe,IAAI,EAAE,MAAM,EAAE,QAAQ,EAAE,CAAC,EAClD,OAAO,EAAE,GAAG,EAAE;oBACZ,IAAI,IAAI,CAAC,YAAY,EAAE,CAAC;wBACtB,WAAW,CAAC,YAAY,CAAC,aAAa,EAAE,CAAC;oBAC3C,CAAC;gBACH,CAAC;gBAEA,IAAI,CAAC,QAAQ;gBACb,IAAI,CAAC,YAAY,CAAC,CAAC,CAAC,eAAS,IAAI,EAAE,QAAQ,GAAY,CAAC,CAAC,CAAC,eAAS,IAAI,EAAE,WAAW,GAAY,CAC/F,CACD,CACN,CAAC;IACJ,CAAC;IAED,MAAM;QACJ,IAAI,CAAC,IAAI,CAAC,KAAK,IAAI,IAAI,CAAC,KAAK,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;YAC3C,OAAO;QACT,CAAC;QACD,OAAO,CACL,EAAC,IAAI;YACF,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC,kBAAS,IAAI,CAAC,OAAO,CAAU,CAAC,CAAC,CAAC,IAAI;YACtD,cACG,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,IAAI,CAAC,EAAE;gBACrB,CAAC;oBACC,OAAO,IAAI,CAAC,gBAAgB,CAAC,CAAC,CAAC,IAAI,CAAC,iBAAiB,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,mBAAmB,CAAC,IAAI,CAAC,CAAC;gBAC/F,CAAC;YACH,CAAC,CAAC,CACC,CACA,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, Element, h, Host, Prop } from '@stencil/core';\n\nimport { state as headerState } from './pn-marketweb-siteheader-store';\nimport { LoginDialogLink } from './pn-marketweb-siteheader-types';\nimport { arrow_right, transfer } from 'pn-design-assets/pn-assets/icons.js';\n\n@Component({\n tag: 'pn-marketweb-siteheader-login-linklist',\n styleUrl: 'pn-marketweb-siteheader-login-linklist.scss',\n})\nexport class PnMarketwebSiteheaderLoginLinklist {\n @Element() hostElement: HTMLElement;\n\n @Prop() heading: string = null;\n @Prop() links: LoginDialogLink[] = [];\n @Prop() idNamespace: string = '';\n @Prop() showUnifiedLogin: boolean = false;\n\n componentWillLoad() {}\n\n uniqueId(text: string) {\n return 'loginlink-' + text.replace(/[^A-Za-z0-9.\\\\\\/]/gim, '') + '-' + this.idNamespace;\n }\n\n linkAppearanceAttributes(link) {\n let attributes = {};\n if (link.linkType) {\n switch (link.linkType) {\n case 'primary':\n attributes = {\n appearance: '',\n variant: '',\n };\n break;\n case 'secondary':\n attributes = {\n appearance: 'light',\n variant: 'outlined',\n };\n break;\n case 'regularlink':\n default:\n attributes = {\n appearance: 'light',\n variant: 'borderless',\n icon: arrow_right,\n };\n break;\n }\n return attributes;\n }\n if (!link.linkType) {\n attributes = {\n appearance: link.primaryLinkApperance ? 'dark' : 'light',\n };\n }\n return attributes;\n }\n\n renderListAsButtons(link) {\n return (\n <li>\n <pn-button\n href={link.href}\n id={this.uniqueId(link.linkText)}\n {...(link.openInNewWindow && { target: '_blank' })}\n {...this.linkAppearanceAttributes(link)}\n onClick={() => {\n if (link.isLogoutLink) {\n headerState.loginManager.clearUserData();\n }\n }}\n >\n {link.linkText}\n </pn-button>\n </li>\n );\n }\n\n renderListAsLinks(link) {\n return (\n <li>\n <a\n href={link.href}\n id={this.uniqueId(link.linkText)}\n {...(link.openInNewWindow && { target: '_blank' })}\n onClick={() => {\n if (link.isLogoutLink) {\n headerState.loginManager.clearUserData();\n }\n }}\n >\n {link.linkText}\n {link.isLogoutLink ? <pn-icon icon={transfer}></pn-icon> : <pn-icon icon={arrow_right}></pn-icon>}\n </a>\n </li>\n );\n }\n\n render() {\n if (!this.links || this.links.length === 0) {\n return;\n }\n return (\n <Host>\n {this.heading ? <strong>{this.heading}</strong> : null}\n <ul>\n {this.links.map(link => {\n {\n return this.showUnifiedLogin ? this.renderListAsLinks(link) : this.renderListAsButtons(link);\n }\n })}\n </ul>\n </Host>\n );\n }\n}\n"]}
|
|
@@ -8,6 +8,7 @@ export class PnMarketwebSiteheaderLoginLinks {
|
|
|
8
8
|
this.username = '';
|
|
9
9
|
this.showUnifiedLogin = false;
|
|
10
10
|
}
|
|
11
|
+
hostElement;
|
|
11
12
|
componentWillLoad() {
|
|
12
13
|
this.init();
|
|
13
14
|
}
|
|
@@ -15,7 +16,6 @@ export class PnMarketwebSiteheaderLoginLinks {
|
|
|
15
16
|
this.adjustLoginLinks();
|
|
16
17
|
}
|
|
17
18
|
adjustLoginLinks() {
|
|
18
|
-
var _a, _b, _c, _d;
|
|
19
19
|
if (!this.loginDialog) {
|
|
20
20
|
return;
|
|
21
21
|
}
|
|
@@ -35,11 +35,11 @@ export class PnMarketwebSiteheaderLoginLinks {
|
|
|
35
35
|
link.linkType = 'primary';
|
|
36
36
|
}
|
|
37
37
|
};
|
|
38
|
-
if (
|
|
39
|
-
|
|
38
|
+
if (this.loginDialog?.loginMenuLinks) {
|
|
39
|
+
this.loginDialog?.loginMenuLinks.forEach(adjustLink);
|
|
40
40
|
}
|
|
41
|
-
if (
|
|
42
|
-
|
|
41
|
+
if (this.loginDialog?.loggedInLinks) {
|
|
42
|
+
this.loginDialog?.loggedInLinks.forEach(adjustLink);
|
|
43
43
|
}
|
|
44
44
|
this.loginDialog.legacyLoginLinks = [
|
|
45
45
|
{
|
|
@@ -62,7 +62,6 @@ export class PnMarketwebSiteheaderLoginLinks {
|
|
|
62
62
|
];
|
|
63
63
|
}
|
|
64
64
|
render() {
|
|
65
|
-
var _a;
|
|
66
65
|
if (!this.loginDialog) {
|
|
67
66
|
return;
|
|
68
67
|
}
|
|
@@ -74,7 +73,7 @@ export class PnMarketwebSiteheaderLoginLinks {
|
|
|
74
73
|
hostElementAttribute.username = this.username;
|
|
75
74
|
hostElementAttribute.loggedin = this.loggedin;
|
|
76
75
|
}
|
|
77
|
-
return (h(Host,
|
|
76
|
+
return (h(Host, { ...hostElementAttribute }, !this.loginDialog.overrideLoginMenu ? (h("div", { "data-loggedin": this.loggedin + '' }, this.loggedin ? (h("pn-marketweb-siteheader-login-linklist", { links: this.loginDialog.loggedInLinks, idNamespace: this.idNamespace })) : (h("div", null, this.loginDialog.loginMenuLinks?.length > 0 ? (h("pn-marketweb-siteheader-login-linklist", { heading: this.loginDialog.loginTitle, links: this.loginDialog.loginMenuLinks, idNamespace: this.idNamespace, showUnifiedLogin: this.showUnifiedLogin })) : (h("pn-marketweb-siteheader-login-linklist", { links: this.loginDialog.legacyLoginLinks, idNamespace: this.idNamespace })))))) : null, this.loginDialog.overrideLoginMenu ? (h("pn-marketweb-siteheader-login-linklist", { links: this.loginDialog.loginMenuLinks, idNamespace: this.idNamespace })) : null));
|
|
78
77
|
}
|
|
79
78
|
static get is() { return "pn-marketweb-siteheader-login-links"; }
|
|
80
79
|
static get originalStyleUrls() {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pn-marketweb-siteheader-login-links.js","sourceRoot":"","sources":["../../../../src/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-login-links.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AAEzE,OAAO,EAAE,KAAK,IAAI,WAAW,EAAE,MAAM,iCAAiC,CAAC;AAOvE,MAAM,OAAO,+BAA+B;;2BAIU,IAAI;2BAC1B,EAAE;wBACa,KAAK;wBACvB,EAAE;gCACO,KAAK;;
|
|
1
|
+
{"version":3,"file":"pn-marketweb-siteheader-login-links.js","sourceRoot":"","sources":["../../../../src/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-login-links.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,CA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;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, Element, h, Host, Prop, Watch } from '@stencil/core';\n\nimport { state as headerState } from './pn-marketweb-siteheader-store';\nimport { LoginDialog } from './pn-marketweb-siteheader-types';\n\n@Component({\n tag: 'pn-marketweb-siteheader-login-links',\n styleUrl: 'pn-marketweb-siteheader-login-links.scss',\n})\nexport class PnMarketwebSiteheaderLoginLinks {\n @Element() hostElement: HTMLElement;\n\n // Login dialog\n @Prop({ mutable: true }) loginDialog: LoginDialog = null;\n @Prop() idNamespace: string = '';\n @Prop({ reflect: true }) loggedin: boolean = false;\n @Prop() username: string = '';\n @Prop() showUnifiedLogin: boolean = false;\n\n componentWillLoad() {\n this.init();\n }\n\n @Watch('loginDialog')\n async init() {\n this.adjustLoginLinks();\n }\n adjustLoginLinks() {\n if (!this.loginDialog) {\n return;\n }\n\n const adjustLink = (link, i) => {\n if (!link.isLogoutLink) {\n link.isLogoutLink = link.pageLink.indexOf('location.href') !== -1 && link.pageLink.indexOf('logout') !== -1;\n }\n if (link.isLogoutLink) {\n link.href = headerState.loginManager.getLogoutUrl(link.href);\n }\n link.href = link.href.replace('window.location.href', window.location.href);\n if (i === 0 && !link.href) {\n link.href = headerState.loginManager.getLoginUrl();\n link.linkType = 'primary';\n }\n if (link.primaryLinkApperance && !link.linkType) {\n link.linkType = 'primary';\n }\n };\n\n if (this.loginDialog?.loginMenuLinks) {\n this.loginDialog?.loginMenuLinks.forEach(adjustLink);\n }\n if (this.loginDialog?.loggedInLinks) {\n this.loginDialog?.loggedInLinks.forEach(adjustLink);\n }\n\n this.loginDialog.legacyLoginLinks = [\n {\n href: headerState.loginManager.getLoginUrl(this.loginDialog.loginUrl),\n linkText: this.loginDialog.loginLinkText,\n openInNewWindow: false,\n isLogoutLink: false,\n pageLink: null,\n linkType: 'primary',\n primaryLinkApperance: true,\n },\n {\n href: headerState.loginManager.getLoginUrl(this.loginDialog.registerUrl),\n linkText: this.loginDialog.createLoginLinkText,\n openInNewWindow: false,\n isLogoutLink: false,\n pageLink: null,\n primaryLinkApperance: false,\n },\n ];\n }\n\n render() {\n if (!this.loginDialog) {\n return;\n }\n\n let hostElementAttribute = {\n username: null,\n loggedin: false,\n };\n if (this.username) {\n hostElementAttribute.username = this.username;\n hostElementAttribute.loggedin = this.loggedin;\n }\n return (\n <Host {...hostElementAttribute}>\n {!this.loginDialog.overrideLoginMenu ? (\n <div data-loggedin={this.loggedin + ''}>\n {this.loggedin ? (\n <pn-marketweb-siteheader-login-linklist links={this.loginDialog.loggedInLinks} idNamespace={this.idNamespace}></pn-marketweb-siteheader-login-linklist>\n ) : (\n <div>\n {/* Get login links from API */}\n {this.loginDialog.loginMenuLinks?.length > 0 ? (\n <pn-marketweb-siteheader-login-linklist\n heading={this.loginDialog.loginTitle}\n links={this.loginDialog.loginMenuLinks}\n idNamespace={this.idNamespace}\n showUnifiedLogin={this.showUnifiedLogin}\n ></pn-marketweb-siteheader-login-linklist>\n ) : (\n <pn-marketweb-siteheader-login-linklist links={this.loginDialog.legacyLoginLinks} idNamespace={this.idNamespace}></pn-marketweb-siteheader-login-linklist>\n )}\n </div>\n )}\n </div>\n ) : null}\n\n {/* Override the default logic for some markets such as DK */}\n {this.loginDialog.overrideLoginMenu ? (\n <pn-marketweb-siteheader-login-linklist links={this.loginDialog.loginMenuLinks} idNamespace={this.idNamespace}></pn-marketweb-siteheader-login-linklist>\n ) : null}\n </Host>\n );\n }\n}\n"]}
|