@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.
Files changed (758) hide show
  1. package/cjs/{FetchHelper-8d537d38.js → FetchHelper-dcfe4038.js} +122 -123
  2. package/cjs/FetchHelper-dcfe4038.js.map +1 -0
  3. package/cjs/loader.cjs.js +1 -1
  4. package/cjs/pn-address-autofill.cjs.entry.js +47 -49
  5. package/cjs/pn-address-autofill.cjs.entry.js.map +1 -1
  6. package/cjs/pn-animated-tile.cjs.entry.js +4 -4
  7. package/cjs/pn-animated-tile.cjs.entry.js.map +1 -1
  8. package/cjs/pn-app-banner.cjs.entry.js +15 -15
  9. package/cjs/pn-app-banner.cjs.entry.js.map +1 -1
  10. package/cjs/pn-bonus-progressbar-level.cjs.entry.js +1 -1
  11. package/cjs/pn-bonus-progressbar-level.cjs.entry.js.map +1 -1
  12. package/cjs/pn-bonus-progressbar.cjs.entry.js +1 -1
  13. package/cjs/pn-bonus-progressbar.cjs.entry.js.map +1 -1
  14. package/cjs/pn-breakpoints.cjs.entry.js +1 -1
  15. package/cjs/pn-breakpoints.cjs.entry.js.map +1 -1
  16. package/cjs/pn-chart.cjs.entry.js +47 -10
  17. package/cjs/pn-chart.cjs.entry.js.map +1 -1
  18. package/cjs/pn-charts-card.cjs.entry.js +7 -7
  19. package/cjs/pn-charts-card.cjs.entry.js.map +1 -1
  20. package/cjs/pn-choice-button.cjs.entry.js +1 -1
  21. package/cjs/pn-choice-button.cjs.entry.js.map +1 -1
  22. package/cjs/pn-cta-block.cjs.entry.js +1 -1
  23. package/cjs/pn-cta-block.cjs.entry.js.map +1 -1
  24. package/cjs/pn-customernumber-selector-option.cjs.entry.js +1 -1
  25. package/cjs/pn-customernumber-selector-option.cjs.entry.js.map +1 -1
  26. package/cjs/pn-customernumber-selector.cjs.entry.js +1 -1
  27. package/cjs/pn-customernumber-selector.cjs.entry.js.map +1 -1
  28. package/cjs/pn-date-and-time.cjs.entry.js +13 -15
  29. package/cjs/pn-date-and-time.cjs.entry.js.map +1 -1
  30. package/cjs/pn-dropdown-choice-adds-row.cjs.entry.js +33 -36
  31. package/cjs/pn-dropdown-choice-adds-row.cjs.entry.js.map +1 -1
  32. package/cjs/pn-dropdown-with-multi-input-rows-row.cjs.entry.js +13 -10
  33. package/cjs/pn-dropdown-with-multi-input-rows-row.cjs.entry.js.map +1 -1
  34. package/cjs/pn-dropdown-with-multi-input-rows.cjs.entry.js +46 -40
  35. package/cjs/pn-dropdown-with-multi-input-rows.cjs.entry.js.map +1 -1
  36. package/cjs/pn-filter-checkbox.cjs.entry.js +2 -3
  37. package/cjs/pn-filter-checkbox.cjs.entry.js.map +1 -1
  38. package/cjs/pn-find-price.cjs.entry.js +1 -2
  39. package/cjs/pn-find-price.cjs.entry.js.map +1 -1
  40. package/cjs/pn-find-service-and-price.cjs.entry.js +2 -3
  41. package/cjs/pn-find-service-and-price.cjs.entry.js.map +1 -1
  42. package/cjs/pn-hero-block-international.cjs.entry.js +3 -3
  43. package/cjs/pn-hero-block-international.cjs.entry.js.map +1 -1
  44. package/cjs/pn-language-selector_9.cjs.entry.js +83 -79
  45. package/cjs/pn-language-selector_9.cjs.entry.js.map +1 -1
  46. package/cjs/pn-line-shape.cjs.entry.js +1 -1
  47. package/cjs/pn-line-shape.cjs.entry.js.map +1 -1
  48. package/cjs/pn-link-list.cjs.entry.js +33 -37
  49. package/cjs/pn-link-list.cjs.entry.js.map +1 -1
  50. package/cjs/pn-mainnav-link.cjs.entry.js +2 -2
  51. package/cjs/pn-mainnav-link.cjs.entry.js.map +1 -1
  52. package/cjs/pn-market-web-components.cjs.js +1 -1
  53. package/cjs/pn-marketweb-input.cjs.entry.js +1 -2
  54. package/cjs/pn-marketweb-input.cjs.entry.js.map +1 -1
  55. package/cjs/pn-marketweb-search.cjs.entry.js +5 -1
  56. package/cjs/pn-marketweb-search.cjs.entry.js.map +1 -1
  57. package/cjs/pn-marketweb-sitefooter.cjs.entry.js +18 -24
  58. package/cjs/pn-marketweb-sitefooter.cjs.entry.js.map +1 -1
  59. package/cjs/pn-marketweb-siteheader-login-button_5.cjs.entry.js +17 -20
  60. package/cjs/pn-marketweb-siteheader-login-button_5.cjs.entry.js.map +1 -1
  61. package/cjs/pn-marketweb-siteheader-login-linklist.cjs.entry.js +5 -5
  62. package/cjs/pn-marketweb-siteheader-login-linklist.cjs.entry.js.map +1 -1
  63. package/cjs/pn-marketweb-siteheader.cjs.entry.js +22 -27
  64. package/cjs/pn-marketweb-siteheader.cjs.entry.js.map +1 -1
  65. package/cjs/pn-media-block.cjs.entry.js +31 -29
  66. package/cjs/pn-media-block.cjs.entry.js.map +1 -1
  67. package/cjs/pn-multi-row-connected-dropdown-row.cjs.entry.js +37 -45
  68. package/cjs/pn-multi-row-connected-dropdown-row.cjs.entry.js.map +1 -1
  69. package/cjs/pn-multi-row-connected-dropdown.cjs.entry.js +39 -33
  70. package/cjs/pn-multi-row-connected-dropdown.cjs.entry.js.map +1 -1
  71. package/cjs/pn-multiple-input.cjs.entry.js +9 -6
  72. package/cjs/pn-multiple-input.cjs.entry.js.map +1 -1
  73. package/cjs/pn-parcel-tracker.cjs.entry.js +1 -1
  74. package/cjs/pn-parcel-tracker.cjs.entry.js.map +1 -1
  75. package/cjs/pn-pex-pricefinder.cjs.entry.js +1 -1
  76. package/cjs/pn-pex-pricefinder.cjs.entry.js.map +1 -1
  77. package/cjs/pn-play-on-scroll.cjs.entry.js +19 -17
  78. package/cjs/pn-play-on-scroll.cjs.entry.js.map +1 -1
  79. package/cjs/pn-product-pricelist.cjs.entry.js +2 -3
  80. package/cjs/pn-product-pricelist.cjs.entry.js.map +1 -1
  81. package/cjs/pn-profile-modal-customernumber.cjs.entry.js +2 -1
  82. package/cjs/pn-profile-modal-customernumber.cjs.entry.js.map +1 -1
  83. package/cjs/pn-profile-modal-profile.cjs.entry.js +3 -1
  84. package/cjs/pn-profile-modal-profile.cjs.entry.js.map +1 -1
  85. package/cjs/pn-profile-modal-type.cjs.entry.js +1 -1
  86. package/cjs/pn-profile-modal-type.cjs.entry.js.map +1 -1
  87. package/cjs/pn-profile-modal.cjs.entry.js +1 -1
  88. package/cjs/pn-profile-modal.cjs.entry.js.map +1 -1
  89. package/cjs/pn-profile-selector-option.cjs.entry.js +1 -1
  90. package/cjs/pn-profile-selector-option.cjs.entry.js.map +1 -1
  91. package/cjs/pn-profile-selector.cjs.entry.js +1 -1
  92. package/cjs/pn-profile-selector.cjs.entry.js.map +1 -1
  93. package/cjs/pn-proxio-findprice-result.cjs.entry.js +8 -12
  94. package/cjs/pn-proxio-findprice-result.cjs.entry.js.map +1 -1
  95. package/cjs/pn-proxio-findprice.cjs.entry.js +16 -23
  96. package/cjs/pn-proxio-findprice.cjs.entry.js.map +1 -1
  97. package/cjs/pn-proxio-pricegroup.cjs.entry.js +9 -13
  98. package/cjs/pn-proxio-pricegroup.cjs.entry.js.map +1 -1
  99. package/cjs/pn-quick-cta.cjs.entry.js +1 -1
  100. package/cjs/pn-quick-cta.cjs.entry.js.map +1 -1
  101. package/cjs/pn-quote-card.cjs.entry.js +1 -1
  102. package/cjs/pn-quote-card.cjs.entry.js.map +1 -1
  103. package/cjs/pn-scroll_2.cjs.entry.js +16 -15
  104. package/cjs/pn-scroll_2.cjs.entry.js.map +1 -1
  105. package/cjs/pn-share-item.cjs.entry.js +1 -1
  106. package/cjs/pn-share-item.cjs.entry.js.map +1 -1
  107. package/cjs/pn-share.cjs.entry.js +1 -1
  108. package/cjs/pn-share.cjs.entry.js.map +1 -1
  109. package/cjs/pn-sidenav-level.cjs.entry.js +3 -4
  110. package/cjs/pn-sidenav-level.cjs.entry.js.map +1 -1
  111. package/cjs/pn-sidenav-link.cjs.entry.js +2 -2
  112. package/cjs/pn-sidenav-link.cjs.entry.js.map +1 -1
  113. package/cjs/pn-sidenav-togglebutton.cjs.entry.js +1 -1
  114. package/cjs/pn-sidenav-togglebutton.cjs.entry.js.map +1 -1
  115. package/cjs/pn-sidenav.cjs.entry.js +1 -1
  116. package/cjs/pn-sidenav.cjs.entry.js.map +1 -1
  117. package/cjs/pn-site-footer_3.cjs.entry.js +1 -1
  118. package/cjs/pn-site-footer_3.cjs.entry.js.map +1 -1
  119. package/cjs/pn-spotlight.cjs.entry.js +1 -1
  120. package/cjs/pn-spotlight.cjs.entry.js.map +1 -1
  121. package/cjs/pn-stats-info-data.cjs.entry.js +5 -5
  122. package/cjs/pn-stats-info-data.cjs.entry.js.map +1 -1
  123. package/cjs/pn-teaser-card.cjs.entry.js +2 -3
  124. package/cjs/pn-teaser-card.cjs.entry.js.map +1 -1
  125. package/cjs/pn-titletag.cjs.entry.js +1 -1
  126. package/cjs/pn-titletag.cjs.entry.js.map +1 -1
  127. package/cjs/pn-usp-promoter.cjs.entry.js +1 -1
  128. package/cjs/pn-usp-promoter.cjs.entry.js.map +1 -1
  129. package/collection/components/animation/pn-animated-tile/pn-animated-tile.js +4 -3
  130. package/collection/components/animation/pn-animated-tile/pn-animated-tile.js.map +1 -1
  131. package/collection/components/animation/pn-play-on-scroll/pn-play-on-scroll.js +19 -16
  132. package/collection/components/animation/pn-play-on-scroll/pn-play-on-scroll.js.map +1 -1
  133. package/collection/components/animation/pn-play-on-scroll/pn-video-overlay/pn-video-overlay.js +11 -9
  134. package/collection/components/animation/pn-play-on-scroll/pn-video-overlay/pn-video-overlay.js.map +1 -1
  135. package/collection/components/animation/pn-scroll/pn-scroll.js +5 -4
  136. package/collection/components/animation/pn-scroll/pn-scroll.js.map +1 -1
  137. package/collection/components/cards/pn-quote-card/pn-line-shape/pn-line-shape.js +1 -0
  138. package/collection/components/cards/pn-quote-card/pn-line-shape/pn-line-shape.js.map +1 -1
  139. package/collection/components/cards/pn-quote-card/pn-quote-card.js +1 -0
  140. package/collection/components/cards/pn-quote-card/pn-quote-card.js.map +1 -1
  141. package/collection/components/cards/pn-teaser-card/pn-teaser-card.js +2 -2
  142. package/collection/components/cards/pn-teaser-card/pn-teaser-card.js.map +1 -1
  143. package/collection/components/charts/pn-chart/pn-chart-helper.js +32 -7
  144. package/collection/components/charts/pn-chart/pn-chart-helper.js.map +1 -1
  145. package/collection/components/charts/pn-chart/pn-chart.js +15 -2
  146. package/collection/components/charts/pn-chart/pn-chart.js.map +1 -1
  147. package/collection/components/charts/pn-charts-card/pn-charts-card.js +7 -6
  148. package/collection/components/charts/pn-charts-card/pn-charts-card.js.map +1 -1
  149. package/collection/components/cta/pn-cta-block/pn-cta-block.js +1 -0
  150. package/collection/components/cta/pn-cta-block/pn-cta-block.js.map +1 -1
  151. package/collection/components/cta/pn-parcel-tracker/pn-parcel-tracker.js +1 -0
  152. package/collection/components/cta/pn-parcel-tracker/pn-parcel-tracker.js.map +1 -1
  153. package/collection/components/cta/pn-quick-cta/pn-quick-cta.js +1 -0
  154. package/collection/components/cta/pn-quick-cta/pn-quick-cta.js.map +1 -1
  155. package/collection/components/cta/pn-share/pn-share-item.js +1 -0
  156. package/collection/components/cta/pn-share/pn-share-item.js.map +1 -1
  157. package/collection/components/cta/pn-share/pn-share.js +1 -0
  158. package/collection/components/cta/pn-share/pn-share.js.map +1 -1
  159. package/collection/components/cta/pn-spotlight/pn-spotlight.js +1 -0
  160. package/collection/components/cta/pn-spotlight/pn-spotlight.js.map +1 -1
  161. package/collection/components/data-visualization/pn-stats-info/pn-stats-info-data/pn-stats-info-data.js +5 -5
  162. package/collection/components/data-visualization/pn-stats-info/pn-stats-info-data/pn-stats-info-data.js.map +1 -1
  163. package/collection/components/input/pn-address-autofill/pn-address-autofill.js +46 -47
  164. package/collection/components/input/pn-address-autofill/pn-address-autofill.js.map +1 -1
  165. package/collection/components/input/pn-bonus-progressbar/pn-bonus-progressbar-level.js +1 -0
  166. package/collection/components/input/pn-bonus-progressbar/pn-bonus-progressbar-level.js.map +1 -1
  167. package/collection/components/input/pn-bonus-progressbar/pn-bonus-progressbar.js +1 -0
  168. package/collection/components/input/pn-bonus-progressbar/pn-bonus-progressbar.js.map +1 -1
  169. package/collection/components/input/pn-choice-button/pn-choice-button.js +1 -0
  170. package/collection/components/input/pn-choice-button/pn-choice-button.js.map +1 -1
  171. package/collection/components/input/pn-date-and-time/pn-date-and-time.js +13 -14
  172. package/collection/components/input/pn-date-and-time/pn-date-and-time.js.map +1 -1
  173. package/collection/components/input/pn-dropdown-choice-adds-row/pn-dropdown-choice-adds-row.js +51 -35
  174. package/collection/components/input/pn-dropdown-choice-adds-row/pn-dropdown-choice-adds-row.js.map +1 -1
  175. package/collection/components/input/pn-dropdown-choice-adds-row/pn-dropdown-choice-adds-row.stories.js +1 -1
  176. package/collection/components/input/pn-dropdown-with-multi-input-rows/pn-dropdown-with-multi-input-rows-row.js +13 -9
  177. package/collection/components/input/pn-dropdown-with-multi-input-rows/pn-dropdown-with-multi-input-rows-row.js.map +1 -1
  178. package/collection/components/input/pn-dropdown-with-multi-input-rows/pn-dropdown-with-multi-input-rows.js +46 -39
  179. package/collection/components/input/pn-dropdown-with-multi-input-rows/pn-dropdown-with-multi-input-rows.js.map +1 -1
  180. package/collection/components/input/pn-dropdown-with-multi-input-rows/pn-dropdown-with-multi-input-rows.stories.js +1 -1
  181. package/collection/components/input/pn-filter-checkbox/pn-filter-checkbox.js +2 -2
  182. package/collection/components/input/pn-filter-checkbox/pn-filter-checkbox.js.map +1 -1
  183. package/collection/components/input/pn-marketweb-input/pn-marketweb-input.js +1 -2
  184. package/collection/components/input/pn-marketweb-input/pn-marketweb-input.js.map +1 -1
  185. package/collection/components/input/pn-marketweb-search/pn-marketweb-search.js +5 -0
  186. package/collection/components/input/pn-marketweb-search/pn-marketweb-search.js.map +1 -1
  187. package/collection/components/input/pn-multi-row-connected-dropdown/pn-multi-row-connected-dropdown-row.js +37 -44
  188. package/collection/components/input/pn-multi-row-connected-dropdown/pn-multi-row-connected-dropdown-row.js.map +1 -1
  189. package/collection/components/input/pn-multi-row-connected-dropdown/pn-multi-row-connected-dropdown.js +39 -32
  190. package/collection/components/input/pn-multi-row-connected-dropdown/pn-multi-row-connected-dropdown.js.map +1 -1
  191. package/collection/components/input/pn-multi-row-connected-dropdown/pn-multi-row-connected-dropdown.stories.js +1 -1
  192. package/collection/components/input/pn-multiple-input/pn-multiple-input.js +9 -5
  193. package/collection/components/input/pn-multiple-input/pn-multiple-input.js.map +1 -1
  194. package/collection/components/layout-components/pn-marketweb-sitefooter/pn-marketweb-sitefooter.js +17 -22
  195. package/collection/components/layout-components/pn-marketweb-sitefooter/pn-marketweb-sitefooter.js.map +1 -1
  196. package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-login-button.js +2 -0
  197. package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-login-button.js.map +1 -1
  198. package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-login-linklist.js +5 -4
  199. package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-login-linklist.js.map +1 -1
  200. package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-login-links.js +6 -7
  201. package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-login-links.js.map +1 -1
  202. package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-login-mypage-button.js +1 -0
  203. package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-login-mypage-button.js.map +1 -1
  204. package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-login-profileselection.js +7 -8
  205. package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-login-profileselection.js.map +1 -1
  206. package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-login.js +7 -6
  207. package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-login.js.map +1 -1
  208. package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-search.js +3 -2
  209. package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-search.js.map +1 -1
  210. package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-unified-login.js +1 -0
  211. package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader-unified-login.js.map +1 -1
  212. package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader.js +21 -25
  213. package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader.js.map +1 -1
  214. package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader.stories.js +5 -22
  215. package/collection/components/layout-components/pn-marketweb-siteheader/pn-marketweb-siteheader.stories.js.map +1 -1
  216. package/collection/components/media/pn-media-block/pn-media-block.js +31 -28
  217. package/collection/components/media/pn-media-block/pn-media-block.js.map +1 -1
  218. package/collection/components/minor/pn-app-banner/pn-app-banner.js +15 -14
  219. package/collection/components/minor/pn-app-banner/pn-app-banner.js.map +1 -1
  220. package/collection/components/minor/pn-swan/pn-swan.js +1 -0
  221. package/collection/components/minor/pn-swan/pn-swan.js.map +1 -1
  222. package/collection/components/minor/pn-titletag/pn-titletag.js +1 -0
  223. package/collection/components/minor/pn-titletag/pn-titletag.js.map +1 -1
  224. package/collection/components/navigation/pn-language-selector/pn-language-selector-option.js +1 -0
  225. package/collection/components/navigation/pn-language-selector/pn-language-selector-option.js.map +1 -1
  226. package/collection/components/navigation/pn-language-selector/pn-language-selector.js +4 -2
  227. package/collection/components/navigation/pn-language-selector/pn-language-selector.js.map +1 -1
  228. package/collection/components/navigation/pn-mainnav/pn-mainnav-level.js +2 -1
  229. package/collection/components/navigation/pn-mainnav/pn-mainnav-level.js.map +1 -1
  230. package/collection/components/navigation/pn-mainnav/pn-mainnav-link.js +2 -1
  231. package/collection/components/navigation/pn-mainnav/pn-mainnav-link.js.map +1 -1
  232. package/collection/components/navigation/pn-mainnav/pn-mainnav-list.js +1 -0
  233. package/collection/components/navigation/pn-mainnav/pn-mainnav-list.js.map +1 -1
  234. package/collection/components/navigation/pn-mainnav/pn-mainnav.js +4 -0
  235. package/collection/components/navigation/pn-mainnav/pn-mainnav.js.map +1 -1
  236. package/collection/components/navigation/pn-sidenav/pn-sidenav-level.js +3 -3
  237. package/collection/components/navigation/pn-sidenav/pn-sidenav-level.js.map +1 -1
  238. package/collection/components/navigation/pn-sidenav/pn-sidenav-link.js +2 -1
  239. package/collection/components/navigation/pn-sidenav/pn-sidenav-link.js.map +1 -1
  240. package/collection/components/navigation/pn-sidenav/pn-sidenav-togglebutton.js +1 -0
  241. package/collection/components/navigation/pn-sidenav/pn-sidenav-togglebutton.js.map +1 -1
  242. package/collection/components/navigation/pn-sidenav/pn-sidenav.js +1 -0
  243. package/collection/components/navigation/pn-sidenav/pn-sidenav.js.map +1 -1
  244. package/collection/components/navigation/pn-site-selector/pn-site-selector.js +1 -0
  245. package/collection/components/navigation/pn-site-selector/pn-site-selector.js.map +1 -1
  246. package/collection/components/profile/pn-customernumber-selector/pn-customernumber-selector-option.js +1 -0
  247. package/collection/components/profile/pn-customernumber-selector/pn-customernumber-selector-option.js.map +1 -1
  248. package/collection/components/profile/pn-customernumber-selector/pn-customernumber-selector.js +1 -0
  249. package/collection/components/profile/pn-customernumber-selector/pn-customernumber-selector.js.map +1 -1
  250. package/collection/components/profile/pn-profile-modal/pn-profile-modal-customernumber.js +2 -0
  251. package/collection/components/profile/pn-profile-modal/pn-profile-modal-customernumber.js.map +1 -1
  252. package/collection/components/profile/pn-profile-modal/pn-profile-modal-profile.js +3 -0
  253. package/collection/components/profile/pn-profile-modal/pn-profile-modal-profile.js.map +1 -1
  254. package/collection/components/profile/pn-profile-modal/pn-profile-modal-type.js +1 -0
  255. package/collection/components/profile/pn-profile-modal/pn-profile-modal-type.js.map +1 -1
  256. package/collection/components/profile/pn-profile-modal/pn-profile-modal.js +1 -0
  257. package/collection/components/profile/pn-profile-modal/pn-profile-modal.js.map +1 -1
  258. package/collection/components/profile/pn-profile-selector/pn-profile-selector-option.js +1 -0
  259. package/collection/components/profile/pn-profile-selector/pn-profile-selector-option.js.map +1 -1
  260. package/collection/components/profile/pn-profile-selector/pn-profile-selector.js +1 -0
  261. package/collection/components/profile/pn-profile-selector/pn-profile-selector.js.map +1 -1
  262. package/collection/components/utilities/pn-breakpoints/pn-breakpoints.js +1 -0
  263. package/collection/components/utilities/pn-breakpoints/pn-breakpoints.js.map +1 -1
  264. package/collection/components/widgets/pn-find-price/pn-find-price.js +1 -2
  265. package/collection/components/widgets/pn-find-price/pn-find-price.js.map +1 -1
  266. package/collection/components/widgets/pn-find-service-and-price/pn-find-service-and-price.js +2 -3
  267. package/collection/components/widgets/pn-find-service-and-price/pn-find-service-and-price.js.map +1 -1
  268. package/collection/components/widgets/pn-hero-block-international/pn-hero-block-international.js +3 -2
  269. package/collection/components/widgets/pn-hero-block-international/pn-hero-block-international.js.map +1 -1
  270. package/collection/components/widgets/pn-link-list/pn-link-list.js +33 -37
  271. package/collection/components/widgets/pn-link-list/pn-link-list.js.map +1 -1
  272. package/collection/components/widgets/pn-pex-pricefinder/pn-pex-pricefinder.js +1 -0
  273. package/collection/components/widgets/pn-pex-pricefinder/pn-pex-pricefinder.js.map +1 -1
  274. package/collection/components/widgets/pn-product-pricelist/pn-product-pricelist.js +2 -3
  275. package/collection/components/widgets/pn-product-pricelist/pn-product-pricelist.js.map +1 -1
  276. package/collection/components/widgets/pn-proxio-findprice/pn-proxio-findprice-result.js +8 -12
  277. package/collection/components/widgets/pn-proxio-findprice/pn-proxio-findprice-result.js.map +1 -1
  278. package/collection/components/widgets/pn-proxio-findprice/pn-proxio-findprice.js +15 -22
  279. package/collection/components/widgets/pn-proxio-findprice/pn-proxio-findprice.js.map +1 -1
  280. package/collection/components/widgets/pn-proxio-pricegroup/pn-proxio-pricegroup.js +8 -12
  281. package/collection/components/widgets/pn-proxio-pricegroup/pn-proxio-pricegroup.js.map +1 -1
  282. package/collection/components/widgets/pn-usp-promoter/pn-usp-promoter.js +1 -0
  283. package/collection/components/widgets/pn-usp-promoter/pn-usp-promoter.js.map +1 -1
  284. package/collection/globals/FetchHelper.js +35 -35
  285. package/collection/globals/FetchHelper.js.map +1 -1
  286. package/collection/globals/MarketWebContextService.js +86 -87
  287. package/collection/globals/MarketWebContextService.js.map +1 -1
  288. package/collection/globals/MarketWebLoginManager.js +60 -61
  289. package/collection/globals/MarketWebLoginManager.js.map +1 -1
  290. package/components/FetchHelper.js +121 -122
  291. package/components/FetchHelper.js.map +1 -1
  292. package/components/pn-address-autofill.js +46 -48
  293. package/components/pn-address-autofill.js.map +1 -1
  294. package/components/pn-animated-tile.js +4 -4
  295. package/components/pn-animated-tile.js.map +1 -1
  296. package/components/pn-app-banner.js +15 -15
  297. package/components/pn-app-banner.js.map +1 -1
  298. package/components/pn-bonus-progressbar-level.js +1 -1
  299. package/components/pn-bonus-progressbar-level.js.map +1 -1
  300. package/components/pn-bonus-progressbar.js +1 -1
  301. package/components/pn-bonus-progressbar.js.map +1 -1
  302. package/components/pn-breakpoints.js +1 -1
  303. package/components/pn-breakpoints.js.map +1 -1
  304. package/components/pn-chart.js +47 -10
  305. package/components/pn-chart.js.map +1 -1
  306. package/components/pn-charts-card.js +7 -7
  307. package/components/pn-charts-card.js.map +1 -1
  308. package/components/pn-choice-button2.js +1 -1
  309. package/components/pn-choice-button2.js.map +1 -1
  310. package/components/pn-cta-block.js +1 -1
  311. package/components/pn-cta-block.js.map +1 -1
  312. package/components/pn-customernumber-selector-option.js +1 -1
  313. package/components/pn-customernumber-selector-option.js.map +1 -1
  314. package/components/pn-customernumber-selector.js +1 -1
  315. package/components/pn-customernumber-selector.js.map +1 -1
  316. package/components/pn-date-and-time.js +13 -15
  317. package/components/pn-date-and-time.js.map +1 -1
  318. package/components/pn-dropdown-choice-adds-row.js +34 -36
  319. package/components/pn-dropdown-choice-adds-row.js.map +1 -1
  320. package/components/pn-dropdown-with-multi-input-rows-row2.js +13 -10
  321. package/components/pn-dropdown-with-multi-input-rows-row2.js.map +1 -1
  322. package/components/pn-dropdown-with-multi-input-rows.js +46 -40
  323. package/components/pn-dropdown-with-multi-input-rows.js.map +1 -1
  324. package/components/pn-filter-checkbox2.js +2 -3
  325. package/components/pn-filter-checkbox2.js.map +1 -1
  326. package/components/pn-find-price.js +1 -2
  327. package/components/pn-find-price.js.map +1 -1
  328. package/components/pn-find-service-and-price.js +2 -3
  329. package/components/pn-find-service-and-price.js.map +1 -1
  330. package/components/pn-hero-block-international.js +3 -3
  331. package/components/pn-hero-block-international.js.map +1 -1
  332. package/components/pn-language-selector-option2.js +1 -0
  333. package/components/pn-language-selector-option2.js.map +1 -1
  334. package/components/pn-language-selector2.js +4 -3
  335. package/components/pn-language-selector2.js.map +1 -1
  336. package/components/pn-line-shape.js +1 -1
  337. package/components/pn-line-shape.js.map +1 -1
  338. package/components/pn-link-list.js +33 -37
  339. package/components/pn-link-list.js.map +1 -1
  340. package/components/pn-mainnav-level2.js +2 -2
  341. package/components/pn-mainnav-level2.js.map +1 -1
  342. package/components/pn-mainnav-link2.js +2 -2
  343. package/components/pn-mainnav-link2.js.map +1 -1
  344. package/components/pn-mainnav-list2.js +1 -1
  345. package/components/pn-mainnav-list2.js.map +1 -1
  346. package/components/pn-mainnav2.js +4 -1
  347. package/components/pn-mainnav2.js.map +1 -1
  348. package/components/pn-marketweb-input2.js +1 -2
  349. package/components/pn-marketweb-input2.js.map +1 -1
  350. package/components/pn-marketweb-search.js +5 -1
  351. package/components/pn-marketweb-search.js.map +1 -1
  352. package/components/pn-marketweb-sitefooter.js +17 -23
  353. package/components/pn-marketweb-sitefooter.js.map +1 -1
  354. package/components/pn-marketweb-siteheader-login-button2.js +2 -1
  355. package/components/pn-marketweb-siteheader-login-button2.js.map +1 -1
  356. package/components/pn-marketweb-siteheader-login-linklist2.js +5 -5
  357. package/components/pn-marketweb-siteheader-login-linklist2.js.map +1 -1
  358. package/components/pn-marketweb-siteheader-login-links2.js +6 -8
  359. package/components/pn-marketweb-siteheader-login-links2.js.map +1 -1
  360. package/components/pn-marketweb-siteheader-login-mypage-button2.js +1 -1
  361. package/components/pn-marketweb-siteheader-login-mypage-button2.js.map +1 -1
  362. package/components/pn-marketweb-siteheader-login-profileselection2.js +7 -9
  363. package/components/pn-marketweb-siteheader-login-profileselection2.js.map +1 -1
  364. package/components/pn-marketweb-siteheader-login2.js +67 -68
  365. package/components/pn-marketweb-siteheader-login2.js.map +1 -1
  366. package/components/pn-marketweb-siteheader-search2.js +3 -3
  367. package/components/pn-marketweb-siteheader-search2.js.map +1 -1
  368. package/components/pn-marketweb-siteheader-unified-login2.js +1 -1
  369. package/components/pn-marketweb-siteheader-unified-login2.js.map +1 -1
  370. package/components/pn-marketweb-siteheader.js +21 -26
  371. package/components/pn-marketweb-siteheader.js.map +1 -1
  372. package/components/pn-media-block.js +31 -29
  373. package/components/pn-media-block.js.map +1 -1
  374. package/components/pn-multi-row-connected-dropdown-row2.js +37 -45
  375. package/components/pn-multi-row-connected-dropdown-row2.js.map +1 -1
  376. package/components/pn-multi-row-connected-dropdown.js +39 -33
  377. package/components/pn-multi-row-connected-dropdown.js.map +1 -1
  378. package/components/pn-multiple-input.js +9 -6
  379. package/components/pn-multiple-input.js.map +1 -1
  380. package/components/pn-parcel-tracker.js +1 -1
  381. package/components/pn-parcel-tracker.js.map +1 -1
  382. package/components/pn-pex-pricefinder.js +1 -1
  383. package/components/pn-pex-pricefinder.js.map +1 -1
  384. package/components/pn-play-on-scroll2.js +19 -17
  385. package/components/pn-play-on-scroll2.js.map +1 -1
  386. package/components/pn-product-pricelist.js +2 -3
  387. package/components/pn-product-pricelist.js.map +1 -1
  388. package/components/pn-profile-modal-customernumber.js +2 -1
  389. package/components/pn-profile-modal-customernumber.js.map +1 -1
  390. package/components/pn-profile-modal-profile.js +3 -1
  391. package/components/pn-profile-modal-profile.js.map +1 -1
  392. package/components/pn-profile-modal-type.js +1 -1
  393. package/components/pn-profile-modal-type.js.map +1 -1
  394. package/components/pn-profile-modal.js +1 -1
  395. package/components/pn-profile-modal.js.map +1 -1
  396. package/components/pn-profile-selector-option.js +1 -1
  397. package/components/pn-profile-selector-option.js.map +1 -1
  398. package/components/pn-profile-selector.js +1 -1
  399. package/components/pn-profile-selector.js.map +1 -1
  400. package/components/pn-proxio-findprice-result2.js +8 -12
  401. package/components/pn-proxio-findprice-result2.js.map +1 -1
  402. package/components/pn-proxio-findprice.js +15 -22
  403. package/components/pn-proxio-findprice.js.map +1 -1
  404. package/components/pn-proxio-pricegroup.js +8 -12
  405. package/components/pn-proxio-pricegroup.js.map +1 -1
  406. package/components/pn-quick-cta.js +1 -1
  407. package/components/pn-quick-cta.js.map +1 -1
  408. package/components/pn-quote-card.js +1 -1
  409. package/components/pn-quote-card.js.map +1 -1
  410. package/components/pn-scroll2.js +5 -5
  411. package/components/pn-scroll2.js.map +1 -1
  412. package/components/pn-share-item2.js +1 -1
  413. package/components/pn-share-item2.js.map +1 -1
  414. package/components/pn-share.js +1 -1
  415. package/components/pn-share.js.map +1 -1
  416. package/components/pn-sidenav-level.js +3 -4
  417. package/components/pn-sidenav-level.js.map +1 -1
  418. package/components/pn-sidenav-link.js +2 -2
  419. package/components/pn-sidenav-link.js.map +1 -1
  420. package/components/pn-sidenav-togglebutton.js +1 -1
  421. package/components/pn-sidenav-togglebutton.js.map +1 -1
  422. package/components/pn-sidenav.js +1 -1
  423. package/components/pn-sidenav.js.map +1 -1
  424. package/components/pn-site-selector2.js +1 -1
  425. package/components/pn-site-selector2.js.map +1 -1
  426. package/components/pn-spotlight.js +1 -1
  427. package/components/pn-spotlight.js.map +1 -1
  428. package/components/pn-stats-info-data2.js +5 -5
  429. package/components/pn-stats-info-data2.js.map +1 -1
  430. package/components/pn-swan2.js +1 -1
  431. package/components/pn-swan2.js.map +1 -1
  432. package/components/pn-teaser-card.js +2 -3
  433. package/components/pn-teaser-card.js.map +1 -1
  434. package/components/pn-titletag2.js +1 -1
  435. package/components/pn-titletag2.js.map +1 -1
  436. package/components/pn-usp-promoter.js +1 -1
  437. package/components/pn-usp-promoter.js.map +1 -1
  438. package/components/pn-video-overlay2.js +11 -10
  439. package/components/pn-video-overlay2.js.map +1 -1
  440. package/esm/{FetchHelper-03b37a44.js → FetchHelper-da579b12.js} +122 -123
  441. package/esm/FetchHelper-da579b12.js.map +1 -0
  442. package/esm/loader.js +1 -1
  443. package/esm/pn-address-autofill.entry.js +48 -50
  444. package/esm/pn-address-autofill.entry.js.map +1 -1
  445. package/esm/pn-animated-tile.entry.js +5 -5
  446. package/esm/pn-animated-tile.entry.js.map +1 -1
  447. package/esm/pn-app-banner.entry.js +16 -16
  448. package/esm/pn-app-banner.entry.js.map +1 -1
  449. package/esm/pn-bonus-progressbar-level.entry.js +2 -2
  450. package/esm/pn-bonus-progressbar-level.entry.js.map +1 -1
  451. package/esm/pn-bonus-progressbar.entry.js +2 -2
  452. package/esm/pn-bonus-progressbar.entry.js.map +1 -1
  453. package/esm/pn-breakpoints.entry.js +2 -2
  454. package/esm/pn-breakpoints.entry.js.map +1 -1
  455. package/esm/pn-chart.entry.js +48 -11
  456. package/esm/pn-chart.entry.js.map +1 -1
  457. package/esm/pn-charts-card.entry.js +8 -8
  458. package/esm/pn-charts-card.entry.js.map +1 -1
  459. package/esm/pn-choice-button.entry.js +2 -2
  460. package/esm/pn-choice-button.entry.js.map +1 -1
  461. package/esm/pn-cta-block.entry.js +2 -2
  462. package/esm/pn-cta-block.entry.js.map +1 -1
  463. package/esm/pn-customernumber-selector-option.entry.js +2 -2
  464. package/esm/pn-customernumber-selector-option.entry.js.map +1 -1
  465. package/esm/pn-customernumber-selector.entry.js +2 -2
  466. package/esm/pn-customernumber-selector.entry.js.map +1 -1
  467. package/esm/pn-date-and-time.entry.js +14 -16
  468. package/esm/pn-date-and-time.entry.js.map +1 -1
  469. package/esm/pn-dropdown-choice-adds-row.entry.js +34 -37
  470. package/esm/pn-dropdown-choice-adds-row.entry.js.map +1 -1
  471. package/esm/pn-dropdown-with-multi-input-rows-row.entry.js +14 -11
  472. package/esm/pn-dropdown-with-multi-input-rows-row.entry.js.map +1 -1
  473. package/esm/pn-dropdown-with-multi-input-rows.entry.js +47 -41
  474. package/esm/pn-dropdown-with-multi-input-rows.entry.js.map +1 -1
  475. package/esm/pn-filter-checkbox.entry.js +3 -4
  476. package/esm/pn-filter-checkbox.entry.js.map +1 -1
  477. package/esm/pn-find-price.entry.js +1 -2
  478. package/esm/pn-find-price.entry.js.map +1 -1
  479. package/esm/pn-find-service-and-price.entry.js +2 -3
  480. package/esm/pn-find-service-and-price.entry.js.map +1 -1
  481. package/esm/pn-hero-block-international.entry.js +4 -4
  482. package/esm/pn-hero-block-international.entry.js.map +1 -1
  483. package/esm/pn-language-selector_9.entry.js +84 -80
  484. package/esm/pn-language-selector_9.entry.js.map +1 -1
  485. package/esm/pn-line-shape.entry.js +2 -2
  486. package/esm/pn-line-shape.entry.js.map +1 -1
  487. package/esm/pn-link-list.entry.js +33 -37
  488. package/esm/pn-link-list.entry.js.map +1 -1
  489. package/esm/pn-mainnav-link.entry.js +3 -3
  490. package/esm/pn-mainnav-link.entry.js.map +1 -1
  491. package/esm/pn-market-web-components.js +1 -1
  492. package/esm/pn-marketweb-input.entry.js +1 -2
  493. package/esm/pn-marketweb-input.entry.js.map +1 -1
  494. package/esm/pn-marketweb-search.entry.js +6 -2
  495. package/esm/pn-marketweb-search.entry.js.map +1 -1
  496. package/esm/pn-marketweb-sitefooter.entry.js +19 -25
  497. package/esm/pn-marketweb-sitefooter.entry.js.map +1 -1
  498. package/esm/pn-marketweb-siteheader-login-button_5.entry.js +18 -21
  499. package/esm/pn-marketweb-siteheader-login-button_5.entry.js.map +1 -1
  500. package/esm/pn-marketweb-siteheader-login-linklist.entry.js +6 -6
  501. package/esm/pn-marketweb-siteheader-login-linklist.entry.js.map +1 -1
  502. package/esm/pn-marketweb-siteheader.entry.js +23 -28
  503. package/esm/pn-marketweb-siteheader.entry.js.map +1 -1
  504. package/esm/pn-media-block.entry.js +32 -30
  505. package/esm/pn-media-block.entry.js.map +1 -1
  506. package/esm/pn-multi-row-connected-dropdown-row.entry.js +38 -46
  507. package/esm/pn-multi-row-connected-dropdown-row.entry.js.map +1 -1
  508. package/esm/pn-multi-row-connected-dropdown.entry.js +40 -34
  509. package/esm/pn-multi-row-connected-dropdown.entry.js.map +1 -1
  510. package/esm/pn-multiple-input.entry.js +10 -7
  511. package/esm/pn-multiple-input.entry.js.map +1 -1
  512. package/esm/pn-parcel-tracker.entry.js +2 -2
  513. package/esm/pn-parcel-tracker.entry.js.map +1 -1
  514. package/esm/pn-pex-pricefinder.entry.js +2 -2
  515. package/esm/pn-pex-pricefinder.entry.js.map +1 -1
  516. package/esm/pn-play-on-scroll.entry.js +20 -18
  517. package/esm/pn-play-on-scroll.entry.js.map +1 -1
  518. package/esm/pn-product-pricelist.entry.js +2 -3
  519. package/esm/pn-product-pricelist.entry.js.map +1 -1
  520. package/esm/pn-profile-modal-customernumber.entry.js +3 -2
  521. package/esm/pn-profile-modal-customernumber.entry.js.map +1 -1
  522. package/esm/pn-profile-modal-profile.entry.js +4 -2
  523. package/esm/pn-profile-modal-profile.entry.js.map +1 -1
  524. package/esm/pn-profile-modal-type.entry.js +2 -2
  525. package/esm/pn-profile-modal-type.entry.js.map +1 -1
  526. package/esm/pn-profile-modal.entry.js +2 -2
  527. package/esm/pn-profile-modal.entry.js.map +1 -1
  528. package/esm/pn-profile-selector-option.entry.js +2 -2
  529. package/esm/pn-profile-selector-option.entry.js.map +1 -1
  530. package/esm/pn-profile-selector.entry.js +2 -2
  531. package/esm/pn-profile-selector.entry.js.map +1 -1
  532. package/esm/pn-proxio-findprice-result.entry.js +8 -12
  533. package/esm/pn-proxio-findprice-result.entry.js.map +1 -1
  534. package/esm/pn-proxio-findprice.entry.js +16 -23
  535. package/esm/pn-proxio-findprice.entry.js.map +1 -1
  536. package/esm/pn-proxio-pricegroup.entry.js +9 -13
  537. package/esm/pn-proxio-pricegroup.entry.js.map +1 -1
  538. package/esm/pn-quick-cta.entry.js +2 -2
  539. package/esm/pn-quick-cta.entry.js.map +1 -1
  540. package/esm/pn-quote-card.entry.js +2 -2
  541. package/esm/pn-quote-card.entry.js.map +1 -1
  542. package/esm/pn-scroll_2.entry.js +17 -16
  543. package/esm/pn-scroll_2.entry.js.map +1 -1
  544. package/esm/pn-share-item.entry.js +2 -2
  545. package/esm/pn-share-item.entry.js.map +1 -1
  546. package/esm/pn-share.entry.js +2 -2
  547. package/esm/pn-share.entry.js.map +1 -1
  548. package/esm/pn-sidenav-level.entry.js +4 -5
  549. package/esm/pn-sidenav-level.entry.js.map +1 -1
  550. package/esm/pn-sidenav-link.entry.js +3 -3
  551. package/esm/pn-sidenav-link.entry.js.map +1 -1
  552. package/esm/pn-sidenav-togglebutton.entry.js +2 -2
  553. package/esm/pn-sidenav-togglebutton.entry.js.map +1 -1
  554. package/esm/pn-sidenav.entry.js +2 -2
  555. package/esm/pn-sidenav.entry.js.map +1 -1
  556. package/esm/pn-site-footer_3.entry.js +1 -1
  557. package/esm/pn-site-footer_3.entry.js.map +1 -1
  558. package/esm/pn-spotlight.entry.js +2 -2
  559. package/esm/pn-spotlight.entry.js.map +1 -1
  560. package/esm/pn-stats-info-data.entry.js +5 -5
  561. package/esm/pn-stats-info-data.entry.js.map +1 -1
  562. package/esm/pn-teaser-card.entry.js +3 -4
  563. package/esm/pn-teaser-card.entry.js.map +1 -1
  564. package/esm/pn-titletag.entry.js +2 -2
  565. package/esm/pn-titletag.entry.js.map +1 -1
  566. package/esm/pn-usp-promoter.entry.js +2 -2
  567. package/esm/pn-usp-promoter.entry.js.map +1 -1
  568. package/package.json +1 -2
  569. package/pn-market-web-components/{p-8ca34ec3.entry.js → p-0247c553.entry.js} +2 -2
  570. package/pn-market-web-components/p-0247c553.entry.js.map +1 -0
  571. package/pn-market-web-components/{p-3f50be05.entry.js → p-09b9cc06.entry.js} +2 -2
  572. package/pn-market-web-components/{p-3f50be05.entry.js.map → p-09b9cc06.entry.js.map} +1 -1
  573. package/pn-market-web-components/{p-03dfc155.entry.js → p-0a522476.entry.js} +2 -2
  574. package/pn-market-web-components/{p-03dfc155.entry.js.map → p-0a522476.entry.js.map} +1 -1
  575. package/pn-market-web-components/{p-2b2b615e.entry.js → p-1317587f.entry.js} +4 -4
  576. package/pn-market-web-components/{p-2b2b615e.entry.js.map → p-1317587f.entry.js.map} +1 -1
  577. package/pn-market-web-components/p-1535a09f.entry.js +2 -0
  578. package/pn-market-web-components/p-1535a09f.entry.js.map +1 -0
  579. package/pn-market-web-components/{p-470ca6e7.entry.js → p-1578e02e.entry.js} +2 -2
  580. package/pn-market-web-components/{p-470ca6e7.entry.js.map → p-1578e02e.entry.js.map} +1 -1
  581. package/pn-market-web-components/p-16f70311.entry.js +2 -0
  582. package/pn-market-web-components/{p-b7a5fb1b.entry.js.map → p-16f70311.entry.js.map} +1 -1
  583. package/pn-market-web-components/{p-c8bbdd96.entry.js → p-190c671b.entry.js} +2 -2
  584. package/pn-market-web-components/{p-c8bbdd96.entry.js.map → p-190c671b.entry.js.map} +1 -1
  585. package/pn-market-web-components/{p-3e4208bb.entry.js → p-1bd5fa26.entry.js} +2 -2
  586. package/pn-market-web-components/{p-3e4208bb.entry.js.map → p-1bd5fa26.entry.js.map} +1 -1
  587. package/pn-market-web-components/{p-e74e962e.entry.js → p-2044eddc.entry.js} +2 -2
  588. package/pn-market-web-components/{p-e74e962e.entry.js.map → p-2044eddc.entry.js.map} +1 -1
  589. package/pn-market-web-components/p-370829c6.entry.js +2 -0
  590. package/pn-market-web-components/p-370829c6.entry.js.map +1 -0
  591. package/pn-market-web-components/p-391970af.entry.js +2 -0
  592. package/pn-market-web-components/p-391970af.entry.js.map +1 -0
  593. package/pn-market-web-components/{p-49fd7182.entry.js → p-40538914.entry.js} +2 -2
  594. package/pn-market-web-components/{p-49fd7182.entry.js.map → p-40538914.entry.js.map} +1 -1
  595. package/pn-market-web-components/{p-fa9ea740.entry.js → p-4372d10e.entry.js} +2 -2
  596. package/pn-market-web-components/p-4372d10e.entry.js.map +1 -0
  597. package/pn-market-web-components/p-4ea1409d.entry.js +2 -0
  598. package/pn-market-web-components/p-4ea1409d.entry.js.map +1 -0
  599. package/pn-market-web-components/{p-66981606.entry.js → p-56bd346e.entry.js} +2 -2
  600. package/pn-market-web-components/{p-66981606.entry.js.map → p-56bd346e.entry.js.map} +1 -1
  601. package/pn-market-web-components/p-586a1e3c.entry.js +2 -0
  602. package/pn-market-web-components/{p-f8eb860b.entry.js.map → p-586a1e3c.entry.js.map} +1 -1
  603. package/pn-market-web-components/{p-baa28521.entry.js → p-5a467ca6.entry.js} +2 -2
  604. package/pn-market-web-components/{p-baa28521.entry.js.map → p-5a467ca6.entry.js.map} +1 -1
  605. package/pn-market-web-components/p-5ac23b38.entry.js +2 -0
  606. package/pn-market-web-components/p-5ac23b38.entry.js.map +1 -0
  607. package/pn-market-web-components/{p-7fdc49d1.entry.js → p-63505736.entry.js} +2 -2
  608. package/pn-market-web-components/p-63505736.entry.js.map +1 -0
  609. package/pn-market-web-components/{p-3696ebf8.entry.js → p-67d862ac.entry.js} +2 -2
  610. package/pn-market-web-components/{p-3696ebf8.entry.js.map → p-67d862ac.entry.js.map} +1 -1
  611. package/pn-market-web-components/{p-3d3f0648.entry.js → p-68aa55f7.entry.js} +2 -2
  612. package/pn-market-web-components/{p-3d3f0648.entry.js.map → p-68aa55f7.entry.js.map} +1 -1
  613. package/pn-market-web-components/{p-d2109ea6.entry.js → p-6e9875e5.entry.js} +2 -2
  614. package/pn-market-web-components/p-6e9875e5.entry.js.map +1 -0
  615. package/pn-market-web-components/p-7021985c.entry.js +2 -0
  616. package/pn-market-web-components/{p-c64cb117.entry.js.map → p-7021985c.entry.js.map} +1 -1
  617. package/pn-market-web-components/{p-716165d2.entry.js → p-721598b8.entry.js} +2 -2
  618. package/pn-market-web-components/p-721598b8.entry.js.map +1 -0
  619. package/pn-market-web-components/p-73cef33c.js +2 -0
  620. package/pn-market-web-components/p-73cef33c.js.map +1 -0
  621. package/pn-market-web-components/p-74203d3e.entry.js +2 -0
  622. package/pn-market-web-components/{p-545ea4ef.entry.js.map → p-74203d3e.entry.js.map} +1 -1
  623. package/pn-market-web-components/p-781ef432.entry.js +2 -0
  624. package/pn-market-web-components/p-781ef432.entry.js.map +1 -0
  625. package/pn-market-web-components/{p-3a08299c.entry.js → p-78fbc88c.entry.js} +2 -2
  626. package/pn-market-web-components/{p-3a08299c.entry.js.map → p-78fbc88c.entry.js.map} +1 -1
  627. package/pn-market-web-components/{p-22a65c3e.entry.js → p-796ebfee.entry.js} +2 -2
  628. package/pn-market-web-components/p-796ebfee.entry.js.map +1 -0
  629. package/pn-market-web-components/p-7b05d7c7.entry.js +2 -0
  630. package/pn-market-web-components/p-7b05d7c7.entry.js.map +1 -0
  631. package/pn-market-web-components/{p-6b2009dc.entry.js → p-81b3e038.entry.js} +2 -2
  632. package/pn-market-web-components/{p-6b2009dc.entry.js.map → p-81b3e038.entry.js.map} +1 -1
  633. package/pn-market-web-components/p-828449da.entry.js +2 -0
  634. package/pn-market-web-components/{p-db2f3f6d.entry.js.map → p-828449da.entry.js.map} +1 -1
  635. package/pn-market-web-components/p-85d57c9d.entry.js +2 -0
  636. package/pn-market-web-components/p-85d57c9d.entry.js.map +1 -0
  637. package/pn-market-web-components/p-90ba1d8e.entry.js +2 -0
  638. package/pn-market-web-components/{p-655e6f71.entry.js.map → p-90ba1d8e.entry.js.map} +1 -1
  639. package/pn-market-web-components/{p-eee5ec0a.entry.js → p-931d3a9b.entry.js} +2 -2
  640. package/pn-market-web-components/{p-eee5ec0a.entry.js.map → p-931d3a9b.entry.js.map} +1 -1
  641. package/pn-market-web-components/{p-9a93bcd0.entry.js → p-95c10b7e.entry.js} +2 -2
  642. package/pn-market-web-components/{p-9a93bcd0.entry.js.map → p-95c10b7e.entry.js.map} +1 -1
  643. package/pn-market-web-components/{p-138ecede.entry.js → p-95e054fd.entry.js} +2 -2
  644. package/pn-market-web-components/{p-138ecede.entry.js.map → p-95e054fd.entry.js.map} +1 -1
  645. package/pn-market-web-components/p-9776a1c5.entry.js +2 -0
  646. package/pn-market-web-components/p-9776a1c5.entry.js.map +1 -0
  647. package/pn-market-web-components/{p-db2e2762.entry.js → p-9998c29d.entry.js} +2 -2
  648. package/pn-market-web-components/p-9998c29d.entry.js.map +1 -0
  649. package/pn-market-web-components/p-9a7abcee.entry.js +2 -0
  650. package/pn-market-web-components/p-9a7abcee.entry.js.map +1 -0
  651. package/pn-market-web-components/{p-0dca82de.entry.js → p-9be27d72.entry.js} +2 -2
  652. package/pn-market-web-components/{p-0dca82de.entry.js.map → p-9be27d72.entry.js.map} +1 -1
  653. package/pn-market-web-components/{p-48f6e683.entry.js → p-a8220c88.entry.js} +2 -2
  654. package/pn-market-web-components/{p-48f6e683.entry.js.map → p-a8220c88.entry.js.map} +1 -1
  655. package/pn-market-web-components/p-a9d2f528.entry.js +2 -0
  656. package/pn-market-web-components/p-a9d2f528.entry.js.map +1 -0
  657. package/pn-market-web-components/p-acbe60df.entry.js +2 -0
  658. package/pn-market-web-components/p-acbe60df.entry.js.map +1 -0
  659. package/pn-market-web-components/{p-5666f0e7.entry.js → p-ade7ffcf.entry.js} +2 -2
  660. package/pn-market-web-components/p-ade7ffcf.entry.js.map +1 -0
  661. package/pn-market-web-components/p-b2dcce7c.entry.js +2 -0
  662. package/pn-market-web-components/p-b2dcce7c.entry.js.map +1 -0
  663. package/pn-market-web-components/{p-10a3c6f4.entry.js → p-b765e4a9.entry.js} +2 -2
  664. package/pn-market-web-components/p-b765e4a9.entry.js.map +1 -0
  665. package/pn-market-web-components/{p-914e1d15.entry.js → p-c224d7c4.entry.js} +2 -2
  666. package/pn-market-web-components/p-c224d7c4.entry.js.map +1 -0
  667. package/pn-market-web-components/{p-787e20a1.entry.js → p-c5856c0b.entry.js} +2 -2
  668. package/pn-market-web-components/{p-787e20a1.entry.js.map → p-c5856c0b.entry.js.map} +1 -1
  669. package/pn-market-web-components/p-c696bedf.entry.js +2 -0
  670. package/pn-market-web-components/{p-012ee486.entry.js.map → p-c696bedf.entry.js.map} +1 -1
  671. package/pn-market-web-components/p-c9f21ea3.entry.js +2 -0
  672. package/pn-market-web-components/{p-03cb46c2.entry.js.map → p-c9f21ea3.entry.js.map} +1 -1
  673. package/pn-market-web-components/{p-87aa1f73.entry.js → p-d07cf4c8.entry.js} +2 -2
  674. package/pn-market-web-components/{p-87aa1f73.entry.js.map → p-d07cf4c8.entry.js.map} +1 -1
  675. package/pn-market-web-components/p-d40ff187.entry.js +2 -0
  676. package/pn-market-web-components/p-d40ff187.entry.js.map +1 -0
  677. package/pn-market-web-components/{p-f21fdae0.entry.js → p-e42f0fbe.entry.js} +2 -2
  678. package/pn-market-web-components/{p-f21fdae0.entry.js.map → p-e42f0fbe.entry.js.map} +1 -1
  679. package/pn-market-web-components/{p-4f2a7d41.entry.js → p-e4c7aaec.entry.js} +2 -2
  680. package/pn-market-web-components/{p-4f2a7d41.entry.js.map → p-e4c7aaec.entry.js.map} +1 -1
  681. package/pn-market-web-components/{p-107568aa.entry.js → p-e5345c69.entry.js} +2 -2
  682. package/pn-market-web-components/p-e5345c69.entry.js.map +1 -0
  683. package/pn-market-web-components/p-e9501c6f.entry.js +2 -0
  684. package/pn-market-web-components/p-e9501c6f.entry.js.map +1 -0
  685. package/pn-market-web-components/{p-fa3ccbfb.entry.js → p-ebaeee5e.entry.js} +2 -2
  686. package/pn-market-web-components/{p-fa3ccbfb.entry.js.map → p-ebaeee5e.entry.js.map} +1 -1
  687. package/pn-market-web-components/{p-9de267ec.entry.js → p-f2d0d0cc.entry.js} +2 -2
  688. package/pn-market-web-components/{p-9de267ec.entry.js.map → p-f2d0d0cc.entry.js.map} +1 -1
  689. package/pn-market-web-components/{p-da953848.entry.js → p-f62879f6.entry.js} +2 -2
  690. package/pn-market-web-components/p-f62879f6.entry.js.map +1 -0
  691. package/pn-market-web-components/{p-ec3fcbf9.entry.js → p-fbc07c7a.entry.js} +2 -2
  692. package/pn-market-web-components/{p-ec3fcbf9.entry.js.map → p-fbc07c7a.entry.js.map} +1 -1
  693. package/pn-market-web-components/p-fbe70284.entry.js +2 -0
  694. package/pn-market-web-components/{p-663e4bb8.entry.js.map → p-fbe70284.entry.js.map} +1 -1
  695. package/pn-market-web-components/pn-market-web-components.esm.js +1 -1
  696. package/pn-market-web-components/pn-market-web-components.esm.js.map +1 -1
  697. package/types/components/input/pn-dropdown-choice-adds-row/pn-dropdown-choice-adds-row.d.ts +1 -0
  698. package/types/components/widgets/pn-proxio-pricegroup/pn-proxio-pricegroup.d.ts +1 -1
  699. package/types/components.d.ts +2 -0
  700. package/umd/pn-marketweb-init.js +1 -1
  701. package/umd/pn-marketweb-salesforce.js +1 -1
  702. package/umd/standalone-loader-salesforce.js +3 -3
  703. package/umd/standalone-loader.js +2 -2
  704. package/cjs/FetchHelper-8d537d38.js.map +0 -1
  705. package/esm/FetchHelper-03b37a44.js.map +0 -1
  706. package/pn-market-web-components/p-012ee486.entry.js +0 -2
  707. package/pn-market-web-components/p-03cb46c2.entry.js +0 -2
  708. package/pn-market-web-components/p-07253be3.entry.js +0 -2
  709. package/pn-market-web-components/p-07253be3.entry.js.map +0 -1
  710. package/pn-market-web-components/p-08a64973.entry.js +0 -2
  711. package/pn-market-web-components/p-08a64973.entry.js.map +0 -1
  712. package/pn-market-web-components/p-107568aa.entry.js.map +0 -1
  713. package/pn-market-web-components/p-10a3c6f4.entry.js.map +0 -1
  714. package/pn-market-web-components/p-161970d1.entry.js +0 -2
  715. package/pn-market-web-components/p-161970d1.entry.js.map +0 -1
  716. package/pn-market-web-components/p-22a65c3e.entry.js.map +0 -1
  717. package/pn-market-web-components/p-2ac83614.entry.js +0 -2
  718. package/pn-market-web-components/p-2ac83614.entry.js.map +0 -1
  719. package/pn-market-web-components/p-2fd40198.entry.js +0 -2
  720. package/pn-market-web-components/p-2fd40198.entry.js.map +0 -1
  721. package/pn-market-web-components/p-3ae1657a.entry.js +0 -2
  722. package/pn-market-web-components/p-3ae1657a.entry.js.map +0 -1
  723. package/pn-market-web-components/p-545ea4ef.entry.js +0 -2
  724. package/pn-market-web-components/p-5666f0e7.entry.js.map +0 -1
  725. package/pn-market-web-components/p-5ff663be.entry.js +0 -2
  726. package/pn-market-web-components/p-5ff663be.entry.js.map +0 -1
  727. package/pn-market-web-components/p-655e6f71.entry.js +0 -2
  728. package/pn-market-web-components/p-657957fc.entry.js +0 -2
  729. package/pn-market-web-components/p-657957fc.entry.js.map +0 -1
  730. package/pn-market-web-components/p-663e4bb8.entry.js +0 -2
  731. package/pn-market-web-components/p-716165d2.entry.js.map +0 -1
  732. package/pn-market-web-components/p-7fdc49d1.entry.js.map +0 -1
  733. package/pn-market-web-components/p-8ca34ec3.entry.js.map +0 -1
  734. package/pn-market-web-components/p-914e1d15.entry.js.map +0 -1
  735. package/pn-market-web-components/p-af16f7e3.entry.js +0 -2
  736. package/pn-market-web-components/p-af16f7e3.entry.js.map +0 -1
  737. package/pn-market-web-components/p-b7a5fb1b.entry.js +0 -2
  738. package/pn-market-web-components/p-be6e903e.entry.js +0 -2
  739. package/pn-market-web-components/p-be6e903e.entry.js.map +0 -1
  740. package/pn-market-web-components/p-bece6791.entry.js +0 -2
  741. package/pn-market-web-components/p-bece6791.entry.js.map +0 -1
  742. package/pn-market-web-components/p-c64cb117.entry.js +0 -2
  743. package/pn-market-web-components/p-c95def57.js +0 -2
  744. package/pn-market-web-components/p-c95def57.js.map +0 -1
  745. package/pn-market-web-components/p-d2109ea6.entry.js.map +0 -1
  746. package/pn-market-web-components/p-da0c533f.entry.js +0 -2
  747. package/pn-market-web-components/p-da0c533f.entry.js.map +0 -1
  748. package/pn-market-web-components/p-da953848.entry.js.map +0 -1
  749. package/pn-market-web-components/p-db2e2762.entry.js.map +0 -1
  750. package/pn-market-web-components/p-db2f3f6d.entry.js +0 -2
  751. package/pn-market-web-components/p-e0f4dc3d.entry.js +0 -2
  752. package/pn-market-web-components/p-e0f4dc3d.entry.js.map +0 -1
  753. package/pn-market-web-components/p-e8189227.entry.js +0 -2
  754. package/pn-market-web-components/p-e8189227.entry.js.map +0 -1
  755. package/pn-market-web-components/p-f8eb860b.entry.js +0 -2
  756. package/pn-market-web-components/p-fa9ea740.entry.js.map +0 -1
  757. package/pn-market-web-components/p-fd639f58.entry.js +0 -2
  758. package/pn-market-web-components/p-fd639f58.entry.js.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"pn-proxio-findprice-result.js","sourceRoot":"","sources":["../../../../src/components/widgets/pn-proxio-findprice/pn-proxio-findprice-result.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,CAAC,EAAE,IAAI,EAAE,IAAI,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AAEvE,OAAO,EAAE,YAAY,EAAE,MAAM,sCAAsC,CAAC;AAMpE,MAAM,OAAO,uBAAuB;;oBAC4B,IAAI;4BAClB,IAAI;0BACC,EAAE;;;;2BAItB,EAAE;+BACC,KAAK;iCACJ,KAAK;mCACJ,EAAE;sBACf,EAAE;wBACiB,IAAI;0BAE1B,EAAE;sBACE,EAAE;yBACC,EAAE;uBACJ,EAAE;sBACH,EAAE;oBACU,YAAY,CAAC,IAAI,CAAC,QAAQ,CAAC;;IAEjE,iBAAiB;QACf,IAAI,CAAC,YAAY,EAAE,CAAC;IACtB,CAAC;IAGD,YAAY;QACV,IAAI,CAAC,UAAU,GAAG,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;IAChC,CAAC;IAGD,cAAc,CAAC,OAAsB;;QACnC,IAAI,CAAC,OAAO,CAAC,sBAAsB,EAAE,CAAC;YACpC,OAAO,IAAI,CAAC;QACd,CAAC;QAED,MAAM,WAAW,GAAG,OAAO,CAAC,sBAAsB,CAAC,SAAS,CAAC,IAAI,CAAC,EAAE,CAAC,IAAI,CAAC,KAAK,KAAK,IAAI,CAAC,YAAY,CAAC,CAAC;QAEvG,IAAI,KAAK,GAAG,EAAE,CAAC;QAEf,IAAI,IAAI,CAAC,iBAAiB,IAAI,IAAI,CAAC,mBAAmB,IAAI,IAAI,CAAC,mBAAmB,KAAK,IAAI,CAAC,MAAM,IAAI,OAAO,CAAC,sBAAsB,EAAE,CAAC;Y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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, h, Prop, Host, Watch, State } from '@stencil/core';\nimport { ProxioPriceGroupi18n, ProxioProduct, ProductGenericItem, ProductWeightGroupListItem, ProxioPriceListGroupResponse } from '../pn-proxio-pricegroup/types';\nimport { translations } from '../pn-proxio-pricegroup/translations';\n\n@Component({\n tag: 'pn-proxio-findprice-result',\n styleUrl: 'pn-proxio-findprice-result.scss',\n})\nexport class PnProxioFindPriceResult {\n @Prop({ mutable: true }) item: ProxioPriceListGroupResponse = null;\n @Prop({ mutable: true }) activeweight: number = null;\n @Prop() shownitems: ProxioPriceListGroupResponse[] = [];\n @Prop() Usp1?: string;\n @Prop() Usp2?: string;\n @Prop() Usp3?: string;\n @Prop() description?: string[] = [];\n @Prop() showMeasurement?: boolean = false;\n @Prop() showInternational: boolean = false;\n @Prop() selectedCountrycode: string = '';\n @Prop() market: string = '';\n @Prop({ mutable: true }) language: string = 'sv';\n\n @State() weightText = '';\n @State() linkId: string = '';\n @State() shopLabel: string = '';\n @State() shopUrl: string = '';\n @State() shopId: string = '';\n @State() i18n: ProxioPriceGroupi18n = translations[this.language];\n\n componentWillLoad() {\n this.composeItems();\n }\n\n @Watch('item')\n composeItems() {\n this.shownitems = [this.item];\n }\n\n @Watch('activeweight')\n getPriceString(product: ProxioProduct) {\n if (!product.productWeightGroupList) {\n return null;\n }\n\n const activeIndex = product.productWeightGroupList.findIndex(item => item.item1 === this.activeweight);\n\n let price = '';\n\n if (this.showInternational && this.selectedCountrycode && this.selectedCountrycode !== this.market && product.weightPriceCountryList) {\n let weightPriceCountryList = product.weightPriceCountryList.filter(item => item.item3.includes(this.selectedCountrycode.toUpperCase()));\n\n price = weightPriceCountryList ? weightPriceCountryList[activeIndex]?.item2 : '';\n } else {\n price = product.weightAndPriceList ? product?.weightAndPriceList[activeIndex]?.item2 : '';\n }\n\n return price ? this.i18n.from + price : '';\n }\n\n @Watch('activeweight')\n getProductLink(product: ProxioProduct, productWeightGroupList: ProductWeightGroupListItem[]) {\n if (product.productWeightGroupList) {\n const activeIndex = product.productWeightGroupList.findIndex(item => item.item1 === this.activeweight);\n\n let productId = productWeightGroupList[activeIndex]?.item2;\n let productLink = product.productLink ? product?.productLink : '';\n return productLink ? productLink + (productId ? '?productId=' + productId : '') : '';\n }\n return null;\n }\n\n getDeliveryInformation(product: ProxioProduct) {\n if (!this.showInternational || !product.deliveryDateInternationalInformation) {\n return product.deliveryDateInformation;\n }\n\n const internationalShipment = product?.deliveryDateInternationalInformation?.find(info => info.item1.toLowerCase() === this.selectedCountrycode.toLowerCase());\n\n if (!internationalShipment?.item2 ?? true) {\n return product.deliveryDateInformation;\n }\n\n return internationalShipment.item2;\n }\n\n getInsuranceAmountText(product: ProxioProduct) {\n if (!product.insuranceAmounts) {\n return '';\n }\n\n const insuranceAmount = product?.insuranceAmounts?.find(info => info.item1.toLowerCase() === this.selectedCountrycode.toLowerCase());\n\n if (!insuranceAmount?.item2 ?? true) {\n return '';\n }\n\n return insuranceAmount.item2;\n }\n\n render() {\n return (\n <Host>\n {\n <pn-proxio-productcard>\n <pn-illustration slot=\"illustrationmobile\" illustration={this.item.proxioProduct.productIcon}></pn-illustration>\n <h2 slot=\"title\">{this.item.proxioProduct.productTitle}</h2>\n <pn-proxio-productcard-description\n slot=\"description\"\n heading={this.item.proxioProduct.productPreamble}\n highlight={this.getDeliveryInformation(this.item.proxioProduct)}\n list={this.item.proxioProduct.productDescriptionBulletListItems}\n ></pn-proxio-productcard-description>\n <div slot=\"information\">\n <pn-proxio-productcard-information\n label={this.i18n.labelMaxDimensions}\n information={this.item.proxioProduct.productPackageDimensionsList as ProductGenericItem[]}\n ></pn-proxio-productcard-information>\n <pn-proxio-productcard-information\n label={this.i18n.labelMaxDimensionsRoll}\n information={this.item.proxioProduct.productRollDimensionsList as ProductGenericItem[]}\n ></pn-proxio-productcard-information>\n </div>\n <div slot=\"bottomtags\">\n {this.item.proxioProduct.usp1 ? <pn-titletag color=\"gray50\">{this.item.proxioProduct.usp1}</pn-titletag> : null}\n {this.item.proxioProduct.usp2 ? <pn-titletag color=\"gray50\">{this.item.proxioProduct.usp2}</pn-titletag> : null}\n {this.item.proxioProduct.usp3 ? <pn-titletag color=\"gray50\">{this.item.proxioProduct.usp3}</pn-titletag> : null}\n </div>\n <pn-illustration slot=\"illustration\" illustration={this.item.proxioProduct.productIcon}></pn-illustration>\n <div slot=\"pricelink\">\n <pn-proxio-productcard-pricelink\n price={this.getPriceString(this.item.proxioProduct)}\n link={this.getProductLink(this.item.proxioProduct, this.item.proxioProduct.productWeightGroupList)}\n linktext={this.item.proxioProduct.productLinkText}\n ></pn-proxio-productcard-pricelink>\n {this.item.relatedProxioProducts\n ? this.item.relatedProxioProducts.map(product => (\n <pn-proxio-productcard-pricelink\n price={this.getPriceString(product)}\n link={product.productLink}\n linktext={product.productLinkText}\n ></pn-proxio-productcard-pricelink>\n ))\n : null}\n </div>\n {this.getInsuranceAmountText(this.item.proxioProduct) ? (\n <div slot=\"insurance\">\n <div class=\"insurance-box\">{this.getInsuranceAmountText(this.item.proxioProduct)}</div>\n </div>\n ) : null}\n </pn-proxio-productcard>\n }\n </Host>\n );\n }\n}\n"]}
1
+ {"version":3,"file":"pn-proxio-findprice-result.js","sourceRoot":"","sources":["../../../../src/components/widgets/pn-proxio-findprice/pn-proxio-findprice-result.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,CAAC,EAAE,IAAI,EAAE,IAAI,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AAEvE,OAAO,EAAE,YAAY,EAAE,MAAM,sCAAsC,CAAC;AAMpE,MAAM,OAAO,uBAAuB;;oBAC4B,IAAI;4BAClB,IAAI;0BACC,EAAE;;;;2BAItB,EAAE;+BACC,KAAK;iCACJ,KAAK;mCACJ,EAAE;sBACf,EAAE;wBACiB,IAAI;0BAE1B,EA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AAC,aAAa,CAAC,CAAC,CAAC,CAAC,CACtD,WAAK,IAAI,EAAC,WAAW;gBACnB,WAAK,KAAK,EAAC,eAAe,IAAE,IAAI,CAAC,sBAAsB,CAAC,IAAI,CAAC,IAAI,CAAC,aAAa,CAAC,CAAO,CACnF,CACP,CAAC,CAAC,CAAC,IAAI,CACc,CAErB,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, h, Prop, Host, Watch, State } from '@stencil/core';\nimport { ProxioPriceGroupi18n, ProxioProduct, ProductGenericItem, ProductWeightGroupListItem, ProxioPriceListGroupResponse } from '../pn-proxio-pricegroup/types';\nimport { translations } from '../pn-proxio-pricegroup/translations';\n\n@Component({\n tag: 'pn-proxio-findprice-result',\n styleUrl: 'pn-proxio-findprice-result.scss',\n})\nexport class PnProxioFindPriceResult {\n @Prop({ mutable: true }) item: ProxioPriceListGroupResponse = null;\n @Prop({ mutable: true }) activeweight: number = null;\n @Prop() shownitems: ProxioPriceListGroupResponse[] = [];\n @Prop() Usp1?: string;\n @Prop() Usp2?: string;\n @Prop() Usp3?: string;\n @Prop() description?: string[] = [];\n @Prop() showMeasurement?: boolean = false;\n @Prop() showInternational: boolean = false;\n @Prop() selectedCountrycode: string = '';\n @Prop() market: string = '';\n @Prop({ mutable: true }) language: string = 'sv';\n\n @State() weightText = '';\n @State() linkId: string = '';\n @State() shopLabel: string = '';\n @State() shopUrl: string = '';\n @State() shopId: string = '';\n @State() i18n: ProxioPriceGroupi18n = translations[this.language];\n\n componentWillLoad() {\n this.composeItems();\n }\n\n @Watch('item')\n composeItems() {\n this.shownitems = [this.item];\n }\n\n @Watch('activeweight')\n getPriceString(product: ProxioProduct) {\n if (!product.productWeightGroupList) {\n return null;\n }\n\n const activeIndex = product.productWeightGroupList.findIndex(item => item.item1 === this.activeweight);\n\n let price = '';\n\n if (this.showInternational && this.selectedCountrycode && this.selectedCountrycode !== this.market && product.weightPriceCountryList) {\n let weightPriceCountryList = product.weightPriceCountryList.filter(item => item.item3.includes(this.selectedCountrycode.toUpperCase()));\n\n price = weightPriceCountryList ? weightPriceCountryList[activeIndex]?.item2 : '';\n } else {\n price = product.weightAndPriceList ? product?.weightAndPriceList[activeIndex]?.item2 : '';\n }\n\n return price ? this.i18n.from + price : '';\n }\n\n @Watch('activeweight')\n getProductLink(product: ProxioProduct, productWeightGroupList: ProductWeightGroupListItem[]) {\n if (product.productWeightGroupList) {\n const activeIndex = product.productWeightGroupList.findIndex(item => item.item1 === this.activeweight);\n\n let productId = productWeightGroupList[activeIndex]?.item2;\n let productLink = product.productLink ? product?.productLink : '';\n return productLink ? productLink + (productId ? '?productId=' + productId : '') : '';\n }\n return null;\n }\n\n getDeliveryInformation(product: ProxioProduct) {\n if (!this.showInternational || !product.deliveryDateInternationalInformation) {\n return product.deliveryDateInformation;\n }\n\n const internationalShipment = product?.deliveryDateInternationalInformation?.find(info => info.item1.toLowerCase() === this.selectedCountrycode.toLowerCase());\n\n if (!internationalShipment?.item2 ?? true) {\n return product.deliveryDateInformation;\n }\n\n return internationalShipment.item2;\n }\n\n getInsuranceAmountText(product: ProxioProduct) {\n if (!product.insuranceAmounts) {\n return '';\n }\n\n const insuranceAmount = product?.insuranceAmounts?.find(info => info.item1.toLowerCase() === this.selectedCountrycode.toLowerCase());\n\n if (!insuranceAmount?.item2 ?? true) {\n return '';\n }\n\n return insuranceAmount.item2;\n }\n\n render() {\n return (\n <Host>\n {\n <pn-proxio-productcard>\n <pn-illustration slot=\"illustrationmobile\" illustration={this.item.proxioProduct.productIcon}></pn-illustration>\n <h2 slot=\"title\">{this.item.proxioProduct.productTitle}</h2>\n <pn-proxio-productcard-description\n slot=\"description\"\n heading={this.item.proxioProduct.productPreamble}\n highlight={this.getDeliveryInformation(this.item.proxioProduct)}\n list={this.item.proxioProduct.productDescriptionBulletListItems}\n ></pn-proxio-productcard-description>\n <div slot=\"information\">\n <pn-proxio-productcard-information\n label={this.i18n.labelMaxDimensions}\n information={this.item.proxioProduct.productPackageDimensionsList as ProductGenericItem[]}\n ></pn-proxio-productcard-information>\n <pn-proxio-productcard-information\n label={this.i18n.labelMaxDimensionsRoll}\n information={this.item.proxioProduct.productRollDimensionsList as ProductGenericItem[]}\n ></pn-proxio-productcard-information>\n </div>\n <div slot=\"bottomtags\">\n {this.item.proxioProduct.usp1 ? <pn-titletag color=\"gray50\">{this.item.proxioProduct.usp1}</pn-titletag> : null}\n {this.item.proxioProduct.usp2 ? <pn-titletag color=\"gray50\">{this.item.proxioProduct.usp2}</pn-titletag> : null}\n {this.item.proxioProduct.usp3 ? <pn-titletag color=\"gray50\">{this.item.proxioProduct.usp3}</pn-titletag> : null}\n </div>\n <pn-illustration slot=\"illustration\" illustration={this.item.proxioProduct.productIcon}></pn-illustration>\n <div slot=\"pricelink\">\n <pn-proxio-productcard-pricelink\n price={this.getPriceString(this.item.proxioProduct)}\n link={this.getProductLink(this.item.proxioProduct, this.item.proxioProduct.productWeightGroupList)}\n linktext={this.item.proxioProduct.productLinkText}\n ></pn-proxio-productcard-pricelink>\n {this.item.relatedProxioProducts\n ? this.item.relatedProxioProducts.map(product => (\n <pn-proxio-productcard-pricelink\n price={this.getPriceString(product)}\n link={product.productLink}\n linktext={product.productLinkText}\n ></pn-proxio-productcard-pricelink>\n ))\n : null}\n </div>\n {this.getInsuranceAmountText(this.item.proxioProduct) ? (\n <div slot=\"insurance\">\n <div class=\"insurance-box\">{this.getInsuranceAmountText(this.item.proxioProduct)}</div>\n </div>\n ) : null}\n </pn-proxio-productcard>\n }\n </Host>\n );\n }\n}\n"]}
@@ -12,7 +12,6 @@ import clouds from "./img/clouds.svg";
12
12
  import { trash_can } from "pn-design-assets/pn-assets/icons.js";
13
13
  export class PnProxioFindPrice {
14
14
  constructor() {
15
- this.fetchHelper = new FetchHelper('proxiopricegroups');
16
15
  this.endpoint = null;
17
16
  this.language = 'da';
18
17
  this.market = 'dk';
@@ -28,6 +27,7 @@ export class PnProxioFindPrice {
28
27
  this.sizecategory = { value: '', name: '', icon: '', unit: '' };
29
28
  this.data = { proxioProducts: [], shipmentCountries: [] };
30
29
  }
30
+ fetchHelper = new FetchHelper('proxiopricegroups');
31
31
  componentWillLoad() {
32
32
  this.setInitialValues().then(() => {
33
33
  this.init();
@@ -36,7 +36,7 @@ export class PnProxioFindPrice {
36
36
  async setInitialValues(href = window.location.href) {
37
37
  const marketWebContextService = new MarketWebContextService(href);
38
38
  const environment = await marketWebContextService.getEnvironmentName();
39
- if (!this.endpoint && (environment === null || environment === void 0 ? void 0 : environment.indexOf('local')) === -1) {
39
+ if (!this.endpoint && environment?.indexOf('local') === -1) {
40
40
  const market = await marketWebContextService.getMarket();
41
41
  this.market = this.market ? this.market : market;
42
42
  this.endpoint = await marketWebContextService.getEndpoint(environment, market);
@@ -92,7 +92,6 @@ export class PnProxioFindPrice {
92
92
  }
93
93
  }
94
94
  filterItems() {
95
- var _a, _b;
96
95
  const sizeItemData = this.data.proxioProducts.filter(item => {
97
96
  return item.proxioProduct.productWeightGroupList.some(weightGroup => {
98
97
  return weightGroup.item3.includes(this.sizecategory.value);
@@ -102,25 +101,23 @@ export class PnProxioFindPrice {
102
101
  return;
103
102
  }
104
103
  const comparisonWeight = this.weight.value;
105
- let weightFilteredData = sizeItemData === null || sizeItemData === void 0 ? void 0 : sizeItemData.filter(item => {
104
+ let weightFilteredData = sizeItemData?.filter(item => {
106
105
  return item.proxioProduct.productWeightGroupList.some(weightGroup => {
107
106
  return weightGroup.item1 === comparisonWeight;
108
107
  });
109
108
  });
110
- let isInternational = this.showInternational && ((_b = ((_a = this.countrycodevalue) === null || _a === void 0 ? void 0 : _a.trim()) !== '') !== null && _b !== void 0 ? _b : false);
109
+ let isInternational = this.showInternational && (this.countrycodevalue?.trim() !== '' ?? false);
111
110
  if (isInternational) {
112
- weightFilteredData = weightFilteredData === null || weightFilteredData === void 0 ? void 0 : weightFilteredData.filter(item => item.proxioProduct.weightPriceCountryList.some(countryItem => countryItem.item3.includes(this.countrycodevalue.toUpperCase())));
111
+ weightFilteredData = weightFilteredData?.filter(item => item.proxioProduct.weightPriceCountryList.some(countryItem => countryItem.item3.includes(this.countrycodevalue.toUpperCase())));
113
112
  }
114
113
  weightFilteredData = this.sortWeightItems(weightFilteredData, isInternational);
115
114
  this.filteredItems = weightFilteredData;
116
115
  }
117
116
  parseFloatFromString(text) {
118
- var _a;
119
- return parseFloat((_a = text === null || text === void 0 ? void 0 : text.replace(/[^\d\.\,]*/g, '')) !== null && _a !== void 0 ? _a : 100000);
117
+ return parseFloat(text?.replace(/[^\d\.\,]*/g, '') ?? 100000);
120
118
  }
121
119
  sortWeightItems(weightFilteredData, isInternational) {
122
- var _a;
123
- (_a = weightFilteredData === null || weightFilteredData === void 0 ? void 0 : weightFilteredData.sort((a, b) => {
120
+ weightFilteredData?.sort((a, b) => {
124
121
  let aNumber = this.getSortNumber(a, isInternational);
125
122
  let bNumber = this.getSortNumber(b, isInternational);
126
123
  if (aNumber && bNumber) {
@@ -133,34 +130,31 @@ export class PnProxioFindPrice {
133
130
  return 1;
134
131
  }
135
132
  return 0;
136
- })) !== null && _a !== void 0 ? _a : [];
133
+ }) ?? [];
137
134
  return weightFilteredData;
138
135
  }
139
136
  getSortNumber(proxioPriceListGroupResponseItem, isInternational) {
140
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m;
141
- let index = (_c = (_b = (_a = proxioPriceListGroupResponseItem === null || proxioPriceListGroupResponseItem === void 0 ? void 0 : proxioPriceListGroupResponseItem.proxioProduct) === null || _a === void 0 ? void 0 : _a.productWeightGroupList) === null || _b === void 0 ? void 0 : _b.findIndex(weightGroup => weightGroup.item1 === this.weight.value)) !== null && _c !== void 0 ? _c : 0;
137
+ let index = proxioPriceListGroupResponseItem?.proxioProduct?.productWeightGroupList?.findIndex(weightGroup => weightGroup.item1 === this.weight.value) ?? 0;
142
138
  if (index < 0) {
143
139
  index = 0;
144
140
  }
145
- let pricevalue = (_g = (_f = (_e = (_d = proxioPriceListGroupResponseItem === null || proxioPriceListGroupResponseItem === void 0 ? void 0 : proxioPriceListGroupResponseItem.proxioProduct) === null || _d === void 0 ? void 0 : _d.weightAndPriceList[index]) === null || _e === void 0 ? void 0 : _e.item2) === null || _f === void 0 ? void 0 : _f.toLowerCase()) !== null && _g !== void 0 ? _g : '';
141
+ let pricevalue = proxioPriceListGroupResponseItem?.proxioProduct?.weightAndPriceList[index]?.item2?.toLowerCase() ?? '';
146
142
  if (isInternational) {
147
- let weightPriceCurrentCountryList = (_j = (_h = proxioPriceListGroupResponseItem === null || proxioPriceListGroupResponseItem === void 0 ? void 0 : proxioPriceListGroupResponseItem.proxioProduct) === null || _h === void 0 ? void 0 : _h.weightPriceCountryList) === null || _j === void 0 ? void 0 : _j.filter(countryItem => countryItem.item3.includes(this.countrycodevalue.toUpperCase()));
148
- pricevalue = (_m = (_l = (_k = weightPriceCurrentCountryList[index]) === null || _k === void 0 ? void 0 : _k.item2) === null || _l === void 0 ? void 0 : _l.toLowerCase()) !== null && _m !== void 0 ? _m : '';
143
+ let weightPriceCurrentCountryList = proxioPriceListGroupResponseItem?.proxioProduct?.weightPriceCountryList?.filter(countryItem => countryItem.item3.includes(this.countrycodevalue.toUpperCase()));
144
+ pricevalue = weightPriceCurrentCountryList[index]?.item2?.toLowerCase() ?? '';
149
145
  }
150
146
  let sortNumber = this.parseFloatFromString(pricevalue);
151
147
  return sortNumber;
152
148
  }
153
149
  resetFilters() {
154
- var _a, _b, _c;
155
150
  this.weight = { value: 0, name: '' };
156
151
  this.sizecategory = sizeCategories.filter(x => x.value === 'S')[0];
157
152
  this.weightvalue = 0;
158
- this.countrycodevalue = (_c = (_b = (_a = this.data) === null || _a === void 0 ? void 0 : _a.shipmentCountries[0]) === null || _b === void 0 ? void 0 : _b.countryCode) !== null && _c !== void 0 ? _c : this.market;
153
+ this.countrycodevalue = this.data?.shipmentCountries[0]?.countryCode ?? this.market;
159
154
  }
160
155
  getWeights() {
161
- var _a;
162
156
  let weightListName = this.market + this.weightListName;
163
- let marketWeightsArray = (_a = weights[weightListName]) !== null && _a !== void 0 ? _a : { S: [], M: [], L: [] };
157
+ let marketWeightsArray = weights[weightListName] ?? { S: [], M: [], L: [] };
164
158
  let marketWeights = marketWeightsArray[this.sizecategory.unit];
165
159
  let isInternationalWeights = this.maxAbroadKg != 0 && this.countrycodevalue.toLowerCase() !== this.market.toLowerCase();
166
160
  marketWeights = isInternationalWeights ? marketWeights.filter(number => number.value / 1000 <= this.maxAbroadKg) : marketWeights;
@@ -172,7 +166,6 @@ export class PnProxioFindPrice {
172
166
  this.countrycodevalue = countryCode;
173
167
  }
174
168
  render() {
175
- var _a, _b;
176
169
  return (h("div", { key: '68c83e3f592af3966aa9587bba3774e0dfef55f5', class: "findprice-form" }, h("div", { key: 'a576283df7229228c385cf59343575827d267186', class: "findprice-form-wrapper" }, h("h4", { key: '1a1beac884093350be6c33ef8c70d320526a1ed6', class: "findprice__heading" }, state.i18n.sizeheading), h("div", { key: '2aeb792414a3a72995833c39d0a6f628b7e9ed23', class: "sizecategory" }, h("table", { key: 'e43dbe8d7556b7bcadcba4fa420b060ce1be2a31', class: "sizeTable" }, h("img", { key: 'e0ebf6910f666aa5a94a7ee5250572ef0cc45677', id: "clouds", src: clouds }), h("tr", { key: 'ae9144b60778e1c9b195eb877aa7145f0dfdf234' }, h("td", { key: 'b08e2084c61b68c2a780f94d09ec2e553fea416e' }, h("img", { key: 'd554baed204b69b28c1cc5e9221ce66c9ed48597', class: "firstCell", src: person })), h("td", { key: 'd63e424e4698f95e3db0379067471cbb85b709aa' }, h("img", { key: '908291bd5b69fbde4fa06082b43269e46b8e0a91', src: S })), this.showMedium ? (h("td", null, h("img", { src: M }))) : null, h("td", { key: 'b27388e528f94893a37320b996c0b4410b35fb71' }, h("img", { key: '62a481e1583c8012e8086bbb892f254cc934ff14', src: L }))), h("tr", { key: 'dbd684e390a8e2e9e6f8163b66e0d1c35e1a82bb' }, h("td", { key: 'def38fa0d80de07fd36d6f4d014906c42df09380' }), sizeCategories.map(sizeCategory => !this.showMedium && sizeCategory.value === 'M' ? null : (h("td", null, h("pn-radio-button", { id: 'findpricecategory-' + sizeCategory.value, radioid: sizeCategory.value, value: sizeCategory.value, name: "sizecategory", checked: sizeCategory.value === this.sizecategory.value, onChange: () => {
177
170
  this.sizecategory = sizeCategories.filter(x => x.value === sizeCategory.value)[0];
178
171
  this.weight = { value: 0, name: '' };
@@ -180,7 +173,7 @@ export class PnProxioFindPrice {
180
173
  } }))))))), h("h4", { key: 'f38ab55173f027e46b0676b9d87617ae3f0eb9b0', class: "findprice__heading findprice__subheading" }, state.i18n.weightheading), this.sizecategory.value && this.getWeights() ? (h("div", { class: "weightoption" }, h("div", { class: "weightoption-content" }, this.getWeights().map(wght => (h("pn-choice-button", { id: 'findpriceweight-' + wght.value, choiceid: this.sizecategory.value + wght.value, name: "weight", type: "radio", value: !this.weight.value ? 0 : this.getWeights().findIndex(x => x.value === this.weightvalue), checked: wght.value === this.weight.value, onChange: () => {
181
174
  this.weight = this.getWeights().filter(x => x.value === wght.value)[0];
182
175
  this.weightvalue = this.weight.value;
183
- } }, wght.name)))))) : null, this.showInternational && ((_b = (_a = this.data) === null || _a === void 0 ? void 0 : _a.shipmentCountries) !== null && _b !== void 0 ? _b : false) ? (h("div", { class: "shipmentcountry" }, h("h4", { class: "shipmentcountry-header" }, state.i18n.countryToSendTo), h("div", { class: "shipmentcountry-select-container" }, h("svg", { class: "arrow", width: "18", height: "10", viewBox: "0 0 18 10", fill: "none", xmlns: "http://www.w3.org/2000/svg" }, h("path", { "fill-rule": "evenodd", "clip-rule": "evenodd", d: "M9.70711 9.70711C9.31658 10.0976 8.68342 10.0976 8.29289 9.70711L0.292892 1.70711C-0.0976315 1.31658 -0.0976315 0.683417 0.292892 0.292893C0.683418 -0.0976315 1.31658 -0.0976315 1.70711 0.292893L9 7.58579L16.2929 0.292893C16.6834 -0.0976315 17.3166 -0.0976315 17.7071 0.292893C18.0976 0.683417 18.0976 1.31658 17.7071 1.70711L9.70711 9.70711Z" })), h("select", { name: "shipmentCountry-select", id: "proxio-shipmentcountry", onChange: this.handleDropdownChange.bind(this) }, this.data.shipmentCountries.map(item => (h("option", { selected: item.countryCode.toLowerCase() === this.countrycodevalue.toLowerCase(), value: item.countryCode }, item.countryName))))))) : null, h("div", { key: 'b001f2646f4ddbb5265c9152c4c0cb29c57e7b16', class: "findprice__clear-all-filters", role: "button" }, h("div", { key: '315fc72758b23fb5d6d3998822e12aa7f56e4f0c', class: "findprice__clear-all-filters__btn", onClick: () => this.resetFilters() }, h("pn-icon", { key: '234be7673fe3ce7b563c1569c2d61e2581567a92', icon: trash_can, color: "blue700" }), h("span", { key: '091e286b429ccac6056ac9bd8273beefe290aa78', class: "clear-all-filters__text" }, state.i18n.clearFilterButton)))), this.filteredItems && this.filteredItems.length > 0 ? (h("div", { class: "resultlist" }, state.i18n.resultlistheading ? h("div", { class: "resultHeading" }, state.i18n.resultlistheading) : null, this.filteredItems.map((item) => (h("div", null, h("pn-proxio-findprice-result", { activeweight: this.weight.value, item: item, language: this.language, "selected-countrycode": this.countrycodevalue, "show-international": this.showInternational, market: this.market })))))) : this.weightvalue !== 0 ? (h("h4", { class: "resultHeading" }, state.i18n.noResultMessage)) : null));
176
+ } }, wght.name)))))) : null, this.showInternational && (this.data?.shipmentCountries ?? false) ? (h("div", { class: "shipmentcountry" }, h("h4", { class: "shipmentcountry-header" }, state.i18n.countryToSendTo), h("div", { class: "shipmentcountry-select-container" }, h("svg", { class: "arrow", width: "18", height: "10", viewBox: "0 0 18 10", fill: "none", xmlns: "http://www.w3.org/2000/svg" }, h("path", { "fill-rule": "evenodd", "clip-rule": "evenodd", d: "M9.70711 9.70711C9.31658 10.0976 8.68342 10.0976 8.29289 9.70711L0.292892 1.70711C-0.0976315 1.31658 -0.0976315 0.683417 0.292892 0.292893C0.683418 -0.0976315 1.31658 -0.0976315 1.70711 0.292893L9 7.58579L16.2929 0.292893C16.6834 -0.0976315 17.3166 -0.0976315 17.7071 0.292893C18.0976 0.683417 18.0976 1.31658 17.7071 1.70711L9.70711 9.70711Z" })), h("select", { name: "shipmentCountry-select", id: "proxio-shipmentcountry", onChange: this.handleDropdownChange.bind(this) }, this.data.shipmentCountries.map(item => (h("option", { selected: item.countryCode.toLowerCase() === this.countrycodevalue.toLowerCase(), value: item.countryCode }, item.countryName))))))) : null, h("div", { key: 'b001f2646f4ddbb5265c9152c4c0cb29c57e7b16', class: "findprice__clear-all-filters", role: "button" }, h("div", { key: '315fc72758b23fb5d6d3998822e12aa7f56e4f0c', class: "findprice__clear-all-filters__btn", onClick: () => this.resetFilters() }, h("pn-icon", { key: '234be7673fe3ce7b563c1569c2d61e2581567a92', icon: trash_can, color: "blue700" }), h("span", { key: '091e286b429ccac6056ac9bd8273beefe290aa78', class: "clear-all-filters__text" }, state.i18n.clearFilterButton)))), this.filteredItems && this.filteredItems.length > 0 ? (h("div", { class: "resultlist" }, state.i18n.resultlistheading ? h("div", { class: "resultHeading" }, state.i18n.resultlistheading) : null, this.filteredItems.map((item) => (h("div", null, h("pn-proxio-findprice-result", { activeweight: this.weight.value, item: item, language: this.language, "selected-countrycode": this.countrycodevalue, "show-international": this.showInternational, market: this.market })))))) : this.weightvalue !== 0 ? (h("h4", { class: "resultHeading" }, state.i18n.noResultMessage)) : null));
184
177
  }
185
178
  static get is() { return "pn-proxio-findprice"; }
186
179
  static get originalStyleUrls() {
@@ -1 +1 @@
1
- {"version":3,"file":"pn-proxio-findprice.js","sourceRoot":"","sources":["../../../../src/components/widgets/pn-proxio-findprice/pn-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AAS,GAAG;wBAC5C,6DAAM,KAAK,EAAC,yBAAyB,IAAE,KAAK,CAAC,IAAI,CAAC,iBAAiB,CAAQ,CACvE,CACF,CACF;YAEL,IAAI,CAAC,aAAa,IAAI,IAAI,CAAC,aAAa,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,CAAC,CACrD,WAAK,KAAK,EAAC,YAAY;gBACpB,KAAK,CAAC,IAAI,CAAC,iBAAiB,CAAC,CAAC,CAAC,WAAK,KAAK,EAAC,eAAe,IAAE,KAAK,CAAC,IAAI,CAAC,iBAAiB,CAAO,CAAC,CAAC,CAAC,IAAI;gBACrG,IAAI,CAAC,aAAa,CAAC,GAAG,CAAC,CAAC,IAAkC,EAAE,EAAE,CAAC,CAC9D;oBACE,kCACE,YAAY,EAAE,IAAI,CAAC,MAAM,CAAC,KAAK,EAC/B,IAAI,EAAE,IAAI,EACV,QAAQ,EAAE,IAAI,CAAC,QAAQ,0BACD,IAAI,CAAC,gBAAgB,wBACvB,IAAI,CAAC,iBAAiB,EAC1C,MAAM,EAAE,IAAI,CAAC,MAAM,GACS,CAC1B,CACP,CAAC,CACE,CACP,CAAC,CAAC,CAAC,IAAI,CAAC,WAAW,KAAK,CAAC,CAAC,CAAC,CAAC,CAC3B,UAAI,KAAK,EAAC,eAAe,IAAE,KAAK,CAAC,IAAI,CAAC,eAAe,CAAM,CAC5D,CAAC,CAAC,CAAC,IAAI,CACJ,CACP,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, h, Prop, State, Watch } from '@stencil/core';\nimport { translations, markets } from './pn-proxio-findprice-translations';\nimport { ProxioPriceListGroupResponse } from '../pn-proxio-pricegroup/types';\nimport {\n ProxioPriceListGroupsResponse,\n ProxioProductFindPriceWeight,\n ProxioProductFindPriceSizeCategory,\n ProxioProductFindPriceMarket,\n ProxioFindPricei18n,\n} from './pn-proxio-findprice-types';\nimport { MarketWebContextService } from '../../../globals/MarketWebContextService';\nimport { weights, sizeCategories } from './data.js';\nimport { FetchHelper } from '../../../globals/FetchHelper';\nimport { state } from './pn-proxio-findprice-store';\nimport S from './img/small-package.svg';\nimport M from './img/medium-package.svg';\nimport L from './img/large-package.svg';\nimport person from './img/postnord-person2.svg';\nimport clouds from './img/clouds.svg';\nimport { trash_can } from 'pn-design-assets/pn-assets/icons.js';\n\n@Component({\n tag: 'pn-proxio-findprice',\n styleUrl: 'pn-proxio-findprice.scss',\n})\nexport class PnProxioFindPrice {\n @Prop({ mutable: true }) endpoint: string = null;\n @Prop({ mutable: true }) language: string = 'da';\n @Prop({ mutable: true }) market: string = 'dk';\n @Prop() showMedium: boolean = false;\n @Prop() showInternational: boolean = false;\n @Prop() maxAbroadKg: number = 0;\n @Prop() weightListName: string = '';\n\n @Prop() cache: boolean = false;\n @State() filteredItems: ProxioPriceListGroupResponse[] = [];\n @State() weight: ProxioProductFindPriceWeight = { value: 0, name: '' } as ProxioProductFindPriceWeight;\n @State() weightvalue: number = 0;\n @State() countrycodevalue: string = '';\n @State() sizecategory: ProxioProductFindPriceSizeCategory = { value: '', name: '', icon: '', unit: '' } as ProxioProductFindPriceSizeCategory;\n @State() data: ProxioPriceListGroupsResponse = { proxioProducts: [], shipmentCountries: [] } as ProxioPriceListGroupsResponse;\n\n fetchHelper = new FetchHelper('proxiopricegroups');\n\n componentWillLoad() {\n this.setInitialValues().then(() => {\n this.init();\n });\n }\n\n async setInitialValues(href = window.location.href) {\n const marketWebContextService = new MarketWebContextService(href);\n const environment = await marketWebContextService.getEnvironmentName();\n\n if (!this.endpoint && environment?.indexOf('local') === -1) {\n const market = await marketWebContextService.getMarket();\n this.market = this.market ? this.market : market;\n this.endpoint = await marketWebContextService.getEndpoint(environment, market);\n }\n\n if (!this.endpoint) {\n this.endpoint = '';\n }\n\n if (this.countrycodevalue === '') {\n this.countrycodevalue = this.market.toLowerCase();\n }\n }\n\n init() {\n this.setState();\n this.fetchData().then(() => {\n this.getDataSource();\n });\n }\n\n async getDataSource() {\n try {\n this.sizecategory = (sizeCategories as ProxioProductFindPriceSizeCategory[]).filter(x => x.value === 'S')[0];\n this.filterItems();\n } catch (e) {\n console.log('Unable to parse data');\n }\n }\n\n async fetchData() {\n if (!this.market || !this.language) {\n return;\n }\n const endpoint = this.endpoint.lastIndexOf('/') === this.endpoint.length - 1 ? this.endpoint.substring(0, this.endpoint.length - 1) : this.endpoint;\n const fetchUrl = `${endpoint}/api/proxio/price-list-groups?market=${this.market}&language=${this.language}&cached=${this.cache}`;\n //const fetchUrl = `https://localhost:51547/api/proxio/price-list-groups?market=${this.market}&language=${this.language}&cached=${this.cache}`;\n\n const data = (await this.fetchHelper.fetchJson(\n fetchUrl,\n {\n mode: 'cors',\n },\n false,\n this.onFetchData.bind(this),\n )) as any;\n\n if (data) {\n this.data = data as ProxioPriceListGroupsResponse;\n this.data.proxioProducts = data.proxioProducts as ProxioPriceListGroupResponse[];\n }\n this.filterItems();\n }\n\n onFetchData(data) {\n this.data = data;\n }\n\n @Watch('market')\n @Watch('language')\n setState() {\n this.market = this.market ? this.market : 'dk';\n if (this.market) {\n state.market = markets[this.market] as ProxioProductFindPriceMarket;\n }\n if (this.language && translations[this.language]) {\n state.i18n = translations[this.language] as ProxioFindPricei18n;\n }\n }\n\n @Watch('sizecategory')\n @Watch('weightvalue')\n @Watch('countrycodevalue')\n filterItems() {\n const sizeItemData = this.data.proxioProducts.filter(item => {\n return item.proxioProduct.productWeightGroupList.some(weightGroup => {\n return weightGroup.item3.includes(this.sizecategory.value);\n });\n });\n\n if (!this.weight) {\n return;\n }\n const comparisonWeight = this.weight.value;\n\n let weightFilteredData = sizeItemData?.filter(item => {\n return item.proxioProduct.productWeightGroupList.some(weightGroup => {\n return weightGroup.item1 === comparisonWeight;\n });\n });\n\n let isInternational = this.showInternational && (this.countrycodevalue?.trim() !== '' ?? false);\n\n if (isInternational) {\n weightFilteredData = weightFilteredData?.filter(item =>\n item.proxioProduct.weightPriceCountryList.some(countryItem => countryItem.item3.includes(this.countrycodevalue.toUpperCase())),\n );\n }\n\n weightFilteredData = this.sortWeightItems(weightFilteredData, isInternational);\n\n this.filteredItems = weightFilteredData;\n }\n\n parseFloatFromString(text) {\n return parseFloat(text?.replace(/[^\\d\\.\\,]*/g, '') ?? 100000);\n }\n\n sortWeightItems(weightFilteredData: ProxioPriceListGroupResponse[], isInternational: boolean) {\n weightFilteredData?.sort((a, b) => {\n let aNumber = this.getSortNumber(a, isInternational);\n let bNumber = this.getSortNumber(b, isInternational);\n\n if (aNumber && bNumber) {\n return aNumber - bNumber;\n }\n\n if (aNumber < bNumber) {\n return -1;\n }\n\n if (aNumber > bNumber) {\n return 1;\n }\n\n return 0;\n }) ?? [];\n\n return weightFilteredData;\n }\n\n getSortNumber(proxioPriceListGroupResponseItem: ProxioPriceListGroupResponse, isInternational: boolean) {\n let index = proxioPriceListGroupResponseItem?.proxioProduct?.productWeightGroupList?.findIndex(weightGroup => weightGroup.item1 === this.weight.value) ?? 0;\n\n if (index < 0) {\n index = 0;\n }\n\n let pricevalue = proxioPriceListGroupResponseItem?.proxioProduct?.weightAndPriceList[index]?.item2?.toLowerCase() ?? '';\n\n if (isInternational) {\n let weightPriceCurrentCountryList = proxioPriceListGroupResponseItem?.proxioProduct?.weightPriceCountryList?.filter(countryItem =>\n countryItem.item3.includes(this.countrycodevalue.toUpperCase()),\n );\n\n pricevalue = weightPriceCurrentCountryList[index]?.item2?.toLowerCase() ?? '';\n }\n\n let sortNumber = this.parseFloatFromString(pricevalue);\n\n return sortNumber;\n }\n\n resetFilters() {\n this.weight = { value: 0, name: '' } as ProxioProductFindPriceWeight;\n this.sizecategory = (sizeCategories as ProxioProductFindPriceSizeCategory[]).filter(x => x.value === 'S')[0];\n this.weightvalue = 0;\n this.countrycodevalue = this.data?.shipmentCountries[0]?.countryCode ?? this.market;\n }\n\n getWeights() {\n let weightListName = this.market + this.weightListName;\n let marketWeightsArray = weights[weightListName] ?? { S: [], M: [], L: [] };\n let marketWeights = marketWeightsArray[this.sizecategory.unit];\n let isInternationalWeights = this.maxAbroadKg != 0 && this.countrycodevalue.toLowerCase() !== this.market.toLowerCase();\n marketWeights = isInternationalWeights ? marketWeights.filter(number => number.value / 1000 <= this.maxAbroadKg) : marketWeights;\n\n return marketWeights;\n }\n\n handleDropdownChange(event: Event) {\n const target = event.target as HTMLInputElement;\n const countryCode = target.value;\n this.countrycodevalue = countryCode;\n }\n\n render() {\n return (\n <div class=\"findprice-form\">\n <div class=\"findprice-form-wrapper\">\n <h4 class=\"findprice__heading\">{state.i18n.sizeheading}</h4>\n <div class=\"sizecategory\">\n <table class=\"sizeTable\">\n <img id=\"clouds\" src={clouds}></img>\n <tr>\n <td>\n <img class=\"firstCell\" src={person}></img>\n </td>\n <td>\n <img src={S}></img>\n </td>\n {this.showMedium ? (\n <td>\n <img src={M}></img>\n </td>\n ) : null}\n <td>\n <img src={L}></img>\n </td>\n </tr>\n <tr>\n <td></td>\n {sizeCategories.map(sizeCategory =>\n !this.showMedium && sizeCategory.value === 'M' ? null : (\n <td>\n <pn-radio-button\n id={'findpricecategory-' + sizeCategory.value}\n radioid={sizeCategory.value}\n value={sizeCategory.value}\n name=\"sizecategory\"\n checked={sizeCategory.value === this.sizecategory.value}\n onChange={() => {\n this.sizecategory = (sizeCategories as ProxioProductFindPriceSizeCategory[]).filter(x => x.value === sizeCategory.value)[0];\n this.weight = { value: 0, name: '' } as ProxioProductFindPriceWeight;\n this.weightvalue = this.weight.value;\n }}\n ></pn-radio-button>\n </td>\n ),\n )}\n </tr>\n </table>\n </div>\n\n <h4 class=\"findprice__heading findprice__subheading\">{state.i18n.weightheading}</h4>\n {this.sizecategory.value && this.getWeights() ? (\n <div class=\"weightoption\">\n {\n <div class=\"weightoption-content\">\n {this.getWeights().map(wght => (\n <pn-choice-button\n id={'findpriceweight-' + wght.value}\n choiceid={this.sizecategory.value + wght.value}\n name=\"weight\"\n type=\"radio\"\n value={!this.weight.value ? 0 : this.getWeights().findIndex(x => x.value === this.weightvalue)}\n checked={wght.value === this.weight.value}\n onChange={() => {\n this.weight = (this.getWeights() as ProxioProductFindPriceWeight[]).filter(x => x.value === wght.value)[0];\n this.weightvalue = this.weight.value;\n }}\n >\n {wght.name}\n </pn-choice-button>\n ))}\n </div>\n }\n </div>\n ) : null}\n\n {this.showInternational && (this.data?.shipmentCountries ?? false) ? (\n <div class=\"shipmentcountry\">\n <h4 class=\"shipmentcountry-header\">{state.i18n.countryToSendTo}</h4>\n <div class=\"shipmentcountry-select-container\">\n <svg class=\"arrow\" width=\"18\" height=\"10\" viewBox=\"0 0 18 10\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n <path\n fill-rule=\"evenodd\"\n clip-rule=\"evenodd\"\n d=\"M9.70711 9.70711C9.31658 10.0976 8.68342 10.0976 8.29289 9.70711L0.292892 1.70711C-0.0976315 1.31658 -0.0976315 0.683417 0.292892 0.292893C0.683418 -0.0976315 1.31658 -0.0976315 1.70711 0.292893L9 7.58579L16.2929 0.292893C16.6834 -0.0976315 17.3166 -0.0976315 17.7071 0.292893C18.0976 0.683417 18.0976 1.31658 17.7071 1.70711L9.70711 9.70711Z\"\n ></path>\n </svg>\n <select name=\"shipmentCountry-select\" id=\"proxio-shipmentcountry\" onChange={this.handleDropdownChange.bind(this)}>\n {this.data.shipmentCountries.map(item => (\n <option selected={item.countryCode.toLowerCase() === this.countrycodevalue.toLowerCase()} value={item.countryCode}>\n {item.countryName}\n </option>\n ))}\n </select>\n </div>\n </div>\n ) : null}\n\n <div class=\"findprice__clear-all-filters\" role=\"button\">\n <div class=\"findprice__clear-all-filters__btn\" onClick={() => this.resetFilters()}>\n <pn-icon icon={trash_can} color=\"blue700\" />\n <span class=\"clear-all-filters__text\">{state.i18n.clearFilterButton}</span>\n </div>\n </div>\n </div>\n\n {this.filteredItems && this.filteredItems.length > 0 ? (\n <div class=\"resultlist\">\n {state.i18n.resultlistheading ? <div class=\"resultHeading\">{state.i18n.resultlistheading}</div> : null}\n {this.filteredItems.map((item: ProxioPriceListGroupResponse) => (\n <div>\n <pn-proxio-findprice-result\n activeweight={this.weight.value}\n item={item}\n language={this.language}\n selected-countrycode={this.countrycodevalue}\n show-international={this.showInternational}\n market={this.market}\n ></pn-proxio-findprice-result>\n </div>\n ))}\n </div>\n ) : this.weightvalue !== 0 ? (\n <h4 class=\"resultHeading\">{state.i18n.noResultMessage}</h4>\n ) : null}\n </div>\n );\n }\n}\n"]}
1
+ {"version":3,"file":"pn-proxio-findprice.js","sourceRoot":"","sources":["../../../../src/components/widgets/pn-proxio-findprice/pn-proxio-findprice.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,CAAC,EAAE,IAAI,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AACjE,OAAO,EAAE,YAAY,EAAE,OAAO,EAAE,MAAM,oCAAoC,CAAC;AAS3E,OAAO,EAAE,uBAAuB,EAAE,MAAM,0CAA0C,CAAC;AACnF,OAAO,EAAE,OAAO,EAAE,cAAc,EAAE,MAAM,WAAW,CAAC;AACpD,OAAO,EAAE,WAAW,EAAE,MAAM,8BAA8B,CAAC;AAC3D,OAAO,EAAE,KAAK,EAAE,MAAM,6BAA6B,CAAC;AACpD,OAAO,CAAC,MAAM,yBAAyB,CAAC;AACxC,OAAO,CAAC,MAAM,0BAA0B,CAAC;AACzC,OAAO,CAAC,MAAM,yBAAyB,CAAC;AACxC,OAAO,MAAM,MAAM,4BAA4B,CAAC;AAChD,OAAO,MAAM,MAAM,kBAAkB,CAAC;AACtC,OAAO,EAAE,SAAS,EAAE,MAAM,qCAAqC,CAAC;AAMhE,MAAM,OAAO,iBAAiB;;wBACgB,IAAI;wBACJ,IAAI;sBACN,IAAI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op, State, Watch } from '@stencil/core';\nimport { translations, markets } from './pn-proxio-findprice-translations';\nimport { ProxioPriceListGroupResponse } from '../pn-proxio-pricegroup/types';\nimport {\n ProxioPriceListGroupsResponse,\n ProxioProductFindPriceWeight,\n ProxioProductFindPriceSizeCategory,\n ProxioProductFindPriceMarket,\n ProxioFindPricei18n,\n} from './pn-proxio-findprice-types';\nimport { MarketWebContextService } from '../../../globals/MarketWebContextService';\nimport { weights, sizeCategories } from './data.js';\nimport { FetchHelper } from '../../../globals/FetchHelper';\nimport { state } from './pn-proxio-findprice-store';\nimport S from './img/small-package.svg';\nimport M from './img/medium-package.svg';\nimport L from './img/large-package.svg';\nimport person from './img/postnord-person2.svg';\nimport clouds from './img/clouds.svg';\nimport { trash_can } from 'pn-design-assets/pn-assets/icons.js';\n\n@Component({\n tag: 'pn-proxio-findprice',\n styleUrl: 'pn-proxio-findprice.scss',\n})\nexport class PnProxioFindPrice {\n @Prop({ mutable: true }) endpoint: string = null;\n @Prop({ mutable: true }) language: string = 'da';\n @Prop({ mutable: true }) market: string = 'dk';\n @Prop() showMedium: boolean = false;\n @Prop() showInternational: boolean = false;\n @Prop() maxAbroadKg: number = 0;\n @Prop() weightListName: string = '';\n\n @Prop() cache: boolean = false;\n @State() filteredItems: ProxioPriceListGroupResponse[] = [];\n @State() weight: ProxioProductFindPriceWeight = { value: 0, name: '' } as ProxioProductFindPriceWeight;\n @State() weightvalue: number = 0;\n @State() countrycodevalue: string = '';\n @State() sizecategory: ProxioProductFindPriceSizeCategory = { value: '', name: '', icon: '', unit: '' } as ProxioProductFindPriceSizeCategory;\n @State() data: ProxioPriceListGroupsResponse = { proxioProducts: [], shipmentCountries: [] } as ProxioPriceListGroupsResponse;\n\n fetchHelper = new FetchHelper('proxiopricegroups');\n\n componentWillLoad() {\n this.setInitialValues().then(() => {\n this.init();\n });\n }\n\n async setInitialValues(href = window.location.href) {\n const marketWebContextService = new MarketWebContextService(href);\n const environment = await marketWebContextService.getEnvironmentName();\n\n if (!this.endpoint && environment?.indexOf('local') === -1) {\n const market = await marketWebContextService.getMarket();\n this.market = this.market ? this.market : market;\n this.endpoint = await marketWebContextService.getEndpoint(environment, market);\n }\n\n if (!this.endpoint) {\n this.endpoint = '';\n }\n\n if (this.countrycodevalue === '') {\n this.countrycodevalue = this.market.toLowerCase();\n }\n }\n\n init() {\n this.setState();\n this.fetchData().then(() => {\n this.getDataSource();\n });\n }\n\n async getDataSource() {\n try {\n this.sizecategory = (sizeCategories as ProxioProductFindPriceSizeCategory[]).filter(x => x.value === 'S')[0];\n this.filterItems();\n } catch (e) {\n console.log('Unable to parse data');\n }\n }\n\n async fetchData() {\n if (!this.market || !this.language) {\n return;\n }\n const endpoint = this.endpoint.lastIndexOf('/') === this.endpoint.length - 1 ? this.endpoint.substring(0, this.endpoint.length - 1) : this.endpoint;\n const fetchUrl = `${endpoint}/api/proxio/price-list-groups?market=${this.market}&language=${this.language}&cached=${this.cache}`;\n //const fetchUrl = `https://localhost:51547/api/proxio/price-list-groups?market=${this.market}&language=${this.language}&cached=${this.cache}`;\n\n const data = (await this.fetchHelper.fetchJson(\n fetchUrl,\n {\n mode: 'cors',\n },\n false,\n this.onFetchData.bind(this),\n )) as any;\n\n if (data) {\n this.data = data as ProxioPriceListGroupsResponse;\n this.data.proxioProducts = data.proxioProducts as ProxioPriceListGroupResponse[];\n }\n this.filterItems();\n }\n\n onFetchData(data) {\n this.data = data;\n }\n\n @Watch('market')\n @Watch('language')\n setState() {\n this.market = this.market ? this.market : 'dk';\n if (this.market) {\n state.market = markets[this.market] as ProxioProductFindPriceMarket;\n }\n if (this.language && translations[this.language]) {\n state.i18n = translations[this.language] as ProxioFindPricei18n;\n }\n }\n\n @Watch('sizecategory')\n @Watch('weightvalue')\n @Watch('countrycodevalue')\n filterItems() {\n const sizeItemData = this.data.proxioProducts.filter(item => {\n return item.proxioProduct.productWeightGroupList.some(weightGroup => {\n return weightGroup.item3.includes(this.sizecategory.value);\n });\n });\n\n if (!this.weight) {\n return;\n }\n const comparisonWeight = this.weight.value;\n\n let weightFilteredData = sizeItemData?.filter(item => {\n return item.proxioProduct.productWeightGroupList.some(weightGroup => {\n return weightGroup.item1 === comparisonWeight;\n });\n });\n\n let isInternational = this.showInternational && (this.countrycodevalue?.trim() !== '' ?? false);\n\n if (isInternational) {\n weightFilteredData = weightFilteredData?.filter(item =>\n item.proxioProduct.weightPriceCountryList.some(countryItem => countryItem.item3.includes(this.countrycodevalue.toUpperCase())),\n );\n }\n\n weightFilteredData = this.sortWeightItems(weightFilteredData, isInternational);\n\n this.filteredItems = weightFilteredData;\n }\n\n parseFloatFromString(text) {\n return parseFloat(text?.replace(/[^\\d\\.\\,]*/g, '') ?? 100000);\n }\n\n sortWeightItems(weightFilteredData: ProxioPriceListGroupResponse[], isInternational: boolean) {\n weightFilteredData?.sort((a, b) => {\n let aNumber = this.getSortNumber(a, isInternational);\n let bNumber = this.getSortNumber(b, isInternational);\n\n if (aNumber && bNumber) {\n return aNumber - bNumber;\n }\n\n if (aNumber < bNumber) {\n return -1;\n }\n\n if (aNumber > bNumber) {\n return 1;\n }\n\n return 0;\n }) ?? [];\n\n return weightFilteredData;\n }\n\n getSortNumber(proxioPriceListGroupResponseItem: ProxioPriceListGroupResponse, isInternational: boolean) {\n let index = proxioPriceListGroupResponseItem?.proxioProduct?.productWeightGroupList?.findIndex(weightGroup => weightGroup.item1 === this.weight.value) ?? 0;\n\n if (index < 0) {\n index = 0;\n }\n\n let pricevalue = proxioPriceListGroupResponseItem?.proxioProduct?.weightAndPriceList[index]?.item2?.toLowerCase() ?? '';\n\n if (isInternational) {\n let weightPriceCurrentCountryList = proxioPriceListGroupResponseItem?.proxioProduct?.weightPriceCountryList?.filter(countryItem =>\n countryItem.item3.includes(this.countrycodevalue.toUpperCase()),\n );\n\n pricevalue = weightPriceCurrentCountryList[index]?.item2?.toLowerCase() ?? '';\n }\n\n let sortNumber = this.parseFloatFromString(pricevalue);\n\n return sortNumber;\n }\n\n resetFilters() {\n this.weight = { value: 0, name: '' } as ProxioProductFindPriceWeight;\n this.sizecategory = (sizeCategories as ProxioProductFindPriceSizeCategory[]).filter(x => x.value === 'S')[0];\n this.weightvalue = 0;\n this.countrycodevalue = this.data?.shipmentCountries[0]?.countryCode ?? this.market;\n }\n\n getWeights() {\n let weightListName = this.market + this.weightListName;\n let marketWeightsArray = weights[weightListName] ?? { S: [], M: [], L: [] };\n let marketWeights = marketWeightsArray[this.sizecategory.unit];\n let isInternationalWeights = this.maxAbroadKg != 0 && this.countrycodevalue.toLowerCase() !== this.market.toLowerCase();\n marketWeights = isInternationalWeights ? marketWeights.filter(number => number.value / 1000 <= this.maxAbroadKg) : marketWeights;\n\n return marketWeights;\n }\n\n handleDropdownChange(event: Event) {\n const target = event.target as HTMLInputElement;\n const countryCode = target.value;\n this.countrycodevalue = countryCode;\n }\n\n render() {\n return (\n <div class=\"findprice-form\">\n <div class=\"findprice-form-wrapper\">\n <h4 class=\"findprice__heading\">{state.i18n.sizeheading}</h4>\n <div class=\"sizecategory\">\n <table class=\"sizeTable\">\n <img id=\"clouds\" src={clouds}></img>\n <tr>\n <td>\n <img class=\"firstCell\" src={person}></img>\n </td>\n <td>\n <img src={S}></img>\n </td>\n {this.showMedium ? (\n <td>\n <img src={M}></img>\n </td>\n ) : null}\n <td>\n <img src={L}></img>\n </td>\n </tr>\n <tr>\n <td></td>\n {sizeCategories.map(sizeCategory =>\n !this.showMedium && sizeCategory.value === 'M' ? null : (\n <td>\n <pn-radio-button\n id={'findpricecategory-' + sizeCategory.value}\n radioid={sizeCategory.value}\n value={sizeCategory.value}\n name=\"sizecategory\"\n checked={sizeCategory.value === this.sizecategory.value}\n onChange={() => {\n this.sizecategory = (sizeCategories as ProxioProductFindPriceSizeCategory[]).filter(x => x.value === sizeCategory.value)[0];\n this.weight = { value: 0, name: '' } as ProxioProductFindPriceWeight;\n this.weightvalue = this.weight.value;\n }}\n ></pn-radio-button>\n </td>\n ),\n )}\n </tr>\n </table>\n </div>\n\n <h4 class=\"findprice__heading findprice__subheading\">{state.i18n.weightheading}</h4>\n {this.sizecategory.value && this.getWeights() ? (\n <div class=\"weightoption\">\n {\n <div class=\"weightoption-content\">\n {this.getWeights().map(wght => (\n <pn-choice-button\n id={'findpriceweight-' + wght.value}\n choiceid={this.sizecategory.value + wght.value}\n name=\"weight\"\n type=\"radio\"\n value={!this.weight.value ? 0 : this.getWeights().findIndex(x => x.value === this.weightvalue)}\n checked={wght.value === this.weight.value}\n onChange={() => {\n this.weight = (this.getWeights() as ProxioProductFindPriceWeight[]).filter(x => x.value === wght.value)[0];\n this.weightvalue = this.weight.value;\n }}\n >\n {wght.name}\n </pn-choice-button>\n ))}\n </div>\n }\n </div>\n ) : null}\n\n {this.showInternational && (this.data?.shipmentCountries ?? false) ? (\n <div class=\"shipmentcountry\">\n <h4 class=\"shipmentcountry-header\">{state.i18n.countryToSendTo}</h4>\n <div class=\"shipmentcountry-select-container\">\n <svg class=\"arrow\" width=\"18\" height=\"10\" viewBox=\"0 0 18 10\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n <path\n fill-rule=\"evenodd\"\n clip-rule=\"evenodd\"\n d=\"M9.70711 9.70711C9.31658 10.0976 8.68342 10.0976 8.29289 9.70711L0.292892 1.70711C-0.0976315 1.31658 -0.0976315 0.683417 0.292892 0.292893C0.683418 -0.0976315 1.31658 -0.0976315 1.70711 0.292893L9 7.58579L16.2929 0.292893C16.6834 -0.0976315 17.3166 -0.0976315 17.7071 0.292893C18.0976 0.683417 18.0976 1.31658 17.7071 1.70711L9.70711 9.70711Z\"\n ></path>\n </svg>\n <select name=\"shipmentCountry-select\" id=\"proxio-shipmentcountry\" onChange={this.handleDropdownChange.bind(this)}>\n {this.data.shipmentCountries.map(item => (\n <option selected={item.countryCode.toLowerCase() === this.countrycodevalue.toLowerCase()} value={item.countryCode}>\n {item.countryName}\n </option>\n ))}\n </select>\n </div>\n </div>\n ) : null}\n\n <div class=\"findprice__clear-all-filters\" role=\"button\">\n <div class=\"findprice__clear-all-filters__btn\" onClick={() => this.resetFilters()}>\n <pn-icon icon={trash_can} color=\"blue700\" />\n <span class=\"clear-all-filters__text\">{state.i18n.clearFilterButton}</span>\n </div>\n </div>\n </div>\n\n {this.filteredItems && this.filteredItems.length > 0 ? (\n <div class=\"resultlist\">\n {state.i18n.resultlistheading ? <div class=\"resultHeading\">{state.i18n.resultlistheading}</div> : null}\n {this.filteredItems.map((item: ProxioPriceListGroupResponse) => (\n <div>\n <pn-proxio-findprice-result\n activeweight={this.weight.value}\n item={item}\n language={this.language}\n selected-countrycode={this.countrycodevalue}\n show-international={this.showInternational}\n market={this.market}\n ></pn-proxio-findprice-result>\n </div>\n ))}\n </div>\n ) : this.weightvalue !== 0 ? (\n <h4 class=\"resultHeading\">{state.i18n.noResultMessage}</h4>\n ) : null}\n </div>\n );\n }\n}\n"]}
@@ -5,7 +5,6 @@ import { translations } from "./translations";
5
5
  import { arrow_left, arrow_right } from "pn-design-assets/pn-assets/icons.js";
6
6
  export class PnProxioPricegroup {
7
7
  constructor() {
8
- this.fetchHelper = new FetchHelper('proxiopricegroup');
9
8
  this.endpoint = null;
10
9
  this.language = 'sv';
11
10
  this.market = 'se';
@@ -15,6 +14,7 @@ export class PnProxioPricegroup {
15
14
  this.data = null;
16
15
  this.i18n = translations['sv'];
17
16
  }
17
+ fetchHelper = new FetchHelper('proxiopricegroup');
18
18
  componentWillLoad() {
19
19
  this.setInitialValues().then(() => {
20
20
  this.init();
@@ -23,7 +23,7 @@ export class PnProxioPricegroup {
23
23
  async setInitialValues(href = window.location.href) {
24
24
  const marketWebContextService = new MarketWebContextService(href);
25
25
  const environment = await marketWebContextService.getEnvironmentName();
26
- if (!this.endpoint && (environment === null || environment === void 0 ? void 0 : environment.indexOf('local')) === -1) {
26
+ if (!this.endpoint && environment?.indexOf('local') === -1) {
27
27
  const market = await marketWebContextService.getMarket();
28
28
  this.endpoint = await marketWebContextService.getEndpoint(environment, market);
29
29
  }
@@ -45,7 +45,7 @@ export class PnProxioPricegroup {
45
45
  const data = (await this.fetchHelper.fetchJson(fetchUrl, {
46
46
  mode: 'cors',
47
47
  }, this.cache, this.onFetchData.bind(this)));
48
- if (data === null || data === void 0 ? void 0 : data.proxioProduct) {
48
+ if (data?.proxioProduct) {
49
49
  this.data = data;
50
50
  }
51
51
  }
@@ -53,9 +53,8 @@ export class PnProxioPricegroup {
53
53
  this.data = data;
54
54
  }
55
55
  setActiveWeightIndex(weightIndex) {
56
- var _a, _b, _c;
57
56
  let minIndex = 0;
58
- let maxIndex = (_c = ((_b = (_a = this.data.proxioProduct) === null || _a === void 0 ? void 0 : _a.weightAndPriceList) === null || _b === void 0 ? void 0 : _b.length) - 1) !== null && _c !== void 0 ? _c : minIndex;
57
+ let maxIndex = this.data.proxioProduct?.weightAndPriceList?.length - 1 ?? minIndex;
59
58
  weightIndex = weightIndex > maxIndex ? maxIndex : weightIndex;
60
59
  weightIndex = weightIndex < minIndex ? minIndex : weightIndex;
61
60
  this.activeWeightIndex = weightIndex;
@@ -66,14 +65,12 @@ export class PnProxioPricegroup {
66
65
  }
67
66
  }
68
67
  getPriceString(product) {
69
- var _a;
70
- let price = product.weightAndPriceList ? (_a = product === null || product === void 0 ? void 0 : product.weightAndPriceList[this.activeWeightIndex]) === null || _a === void 0 ? void 0 : _a.item2 : '';
68
+ let price = product.weightAndPriceList ? product?.weightAndPriceList[this.activeWeightIndex]?.item2 : '';
71
69
  return price ? this.i18n.from + price : '';
72
70
  }
73
71
  getProductLink(product, productWeightGroupList) {
74
- var _a;
75
- let productId = (_a = productWeightGroupList[this.activeWeightIndex]) === null || _a === void 0 ? void 0 : _a.item2;
76
- let productLink = product.productLink ? product === null || product === void 0 ? void 0 : product.productLink : '';
72
+ let productId = productWeightGroupList[this.activeWeightIndex]?.item2;
73
+ let productLink = product.productLink ? product?.productLink : '';
77
74
  return productLink ? productLink + (productId ? '?productId=' + productId : '') : '';
78
75
  }
79
76
  isActive(index) {
@@ -121,8 +118,7 @@ export class PnProxioPricegroup {
121
118
  }
122
119
  }
123
120
  render() {
124
- var _a, _b, _c;
125
- return (h(Host, { key: '382bffa036a8d0d4dd545e661ce81a014c3d427d' }, ((_a = this.data) === null || _a === void 0 ? void 0 : _a.proxioProduct) ? (h("div", { class: "proxio-pricegroup-container" }, h("div", { class: "weightcontainer" }, this.data.proxioProduct.weightAndPriceList ? (h("div", { class: "weightvaluecontainer" }, h("pn-button", { disabled: this.activeWeightIndex === 0 ? 'disabled' : null, icon: arrow_left, appearance: "light", small: "true", onClick: () => this.setActiveWeightIndex(this.activeWeightIndex - 1) }), h("div", { class: "weightradios ", "data-carousel-container-position": this.getContainerPosition() }, h("div", { class: "weightline" }), this.data.proxioProduct.weightAndPriceList.map((weightItem, index) => this.getCarouselPosition(index) !== null ? (h("div", { class: "weightdata", "data-carousel-position": this.getCarouselPosition(index), onClick: () => this.setActiveWeightIndex(index) }, h("input", { type: "radio", id: 'weightradio' + index, name: "weightradio", value: index, checked: this.isActive(index) }), h("label", { htmlFor: 'weightradio' + index }, weightItem.item1))) : null)), h("pn-button", { disabled: this.activeWeightIndex === ((_c = (_b = this.data.proxioProduct) === null || _b === void 0 ? void 0 : _b.weightAndPriceList) === null || _c === void 0 ? void 0 : _c.length) - 1 ? 'disabled' : null, icon: arrow_right, appearance: "light", small: "true", onClick: () => this.setActiveWeightIndex(this.activeWeightIndex + 1) }))) : null), h("pn-proxio-productcard", null, h("pn-illustration", { slot: "illustrationmobile", illustration: this.data.proxioProduct.productIcon }), h("h2", { slot: "title" }, this.data.proxioProduct.productTitle), h("pn-proxio-productcard-description", { slot: "description", heading: this.data.proxioProduct.productPreamble, highlight: this.data.proxioProduct.deliveryDateInformation, list: this.data.proxioProduct.productDescriptionBulletListItems }), h("div", { slot: "information" }, h("pn-proxio-productcard-information", { label: this.i18n.labelMaxDimensions, information: this.data.proxioProduct.productPackageDimensionsList }), h("pn-proxio-productcard-information", { label: this.i18n.labelMaxDimensionsRoll, information: this.data.proxioProduct.productRollDimensionsList })), h("div", { slot: "bottomtags" }, this.data.proxioProduct.usp1 ? h("pn-titletag", { color: "gray50" }, this.data.proxioProduct.usp1) : null, this.data.proxioProduct.usp2 ? h("pn-titletag", { color: "gray50" }, this.data.proxioProduct.usp2) : null, this.data.proxioProduct.usp3 ? h("pn-titletag", { color: "gray50" }, this.data.proxioProduct.usp3) : null), h("pn-illustration", { slot: "illustration", illustration: this.data.proxioProduct.productIcon }), h("div", { slot: "pricelink" }, h("pn-proxio-productcard-pricelink", { price: this.getPriceString(this.data.proxioProduct), link: this.getProductLink(this.data.proxioProduct, this.data.proxioProduct.productWeightGroupList), linktext: this.data.proxioProduct.productLinkText }), this.data.relatedProxioProducts
121
+ return (h(Host, { key: '382bffa036a8d0d4dd545e661ce81a014c3d427d' }, this.data?.proxioProduct ? (h("div", { class: "proxio-pricegroup-container" }, h("div", { class: "weightcontainer" }, this.data.proxioProduct.weightAndPriceList ? (h("div", { class: "weightvaluecontainer" }, h("pn-button", { disabled: this.activeWeightIndex === 0 ? 'disabled' : null, icon: arrow_left, appearance: "light", small: "true", onClick: () => this.setActiveWeightIndex(this.activeWeightIndex - 1) }), h("div", { class: "weightradios ", "data-carousel-container-position": this.getContainerPosition() }, h("div", { class: "weightline" }), this.data.proxioProduct.weightAndPriceList.map((weightItem, index) => this.getCarouselPosition(index) !== null ? (h("div", { class: "weightdata", "data-carousel-position": this.getCarouselPosition(index), onClick: () => this.setActiveWeightIndex(index) }, h("input", { type: "radio", id: 'weightradio' + index, name: "weightradio", value: index, checked: this.isActive(index) }), h("label", { htmlFor: 'weightradio' + index }, weightItem.item1))) : null)), h("pn-button", { disabled: this.activeWeightIndex === this.data.proxioProduct?.weightAndPriceList?.length - 1 ? 'disabled' : null, icon: arrow_right, appearance: "light", small: "true", onClick: () => this.setActiveWeightIndex(this.activeWeightIndex + 1) }))) : null), h("pn-proxio-productcard", null, h("pn-illustration", { slot: "illustrationmobile", illustration: this.data.proxioProduct.productIcon }), h("h2", { slot: "title" }, this.data.proxioProduct.productTitle), h("pn-proxio-productcard-description", { slot: "description", heading: this.data.proxioProduct.productPreamble, highlight: this.data.proxioProduct.deliveryDateInformation, list: this.data.proxioProduct.productDescriptionBulletListItems }), h("div", { slot: "information" }, h("pn-proxio-productcard-information", { label: this.i18n.labelMaxDimensions, information: this.data.proxioProduct.productPackageDimensionsList }), h("pn-proxio-productcard-information", { label: this.i18n.labelMaxDimensionsRoll, information: this.data.proxioProduct.productRollDimensionsList })), h("div", { slot: "bottomtags" }, this.data.proxioProduct.usp1 ? h("pn-titletag", { color: "gray50" }, this.data.proxioProduct.usp1) : null, this.data.proxioProduct.usp2 ? h("pn-titletag", { color: "gray50" }, this.data.proxioProduct.usp2) : null, this.data.proxioProduct.usp3 ? h("pn-titletag", { color: "gray50" }, this.data.proxioProduct.usp3) : null), h("pn-illustration", { slot: "illustration", illustration: this.data.proxioProduct.productIcon }), h("div", { slot: "pricelink" }, h("pn-proxio-productcard-pricelink", { price: this.getPriceString(this.data.proxioProduct), link: this.getProductLink(this.data.proxioProduct, this.data.proxioProduct.productWeightGroupList), linktext: this.data.proxioProduct.productLinkText }), this.data.relatedProxioProducts
126
122
  ? this.data.relatedProxioProducts.map(product => (h("pn-proxio-productcard-pricelink", { price: this.getPriceString(product), link: product.productLink, linktext: product.productLinkText })))
127
123
  : null)))) : null));
128
124
  }
@@ -1 +1 @@
1
- {"version":3,"file":"pn-proxio-pricegroup.js","sourceRoot":"","sources":["../../../../src/components/widgets/pn-proxio-pricegroup/pn-proxio-pricegroup.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AACxE,OAAO,EAAE,WAAW,EAAE,MAAM,8BAA8B,CAAC;AAC3D,OAAO,EAAE,uBAAuB,EAAE,MAAM,0CAA0C,CAAC;AACnF,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAE9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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, h, Host, Listen, Prop, State } from '@stencil/core';\nimport { FetchHelper } from '../../../globals/FetchHelper';\nimport { MarketWebContextService } from '../../../globals/MarketWebContextService';\nimport { translations } from './translations';\nimport { ProductGenericItem, ProxioPriceGroupi18n, ProxioPriceListGroupResponse, ProxioProduct, ProductWeightGroupListItem } from './types';\nimport { arrow_left, arrow_right } from 'pn-design-assets/pn-assets/icons.js';\n\n@Component({\n tag: 'pn-proxio-pricegroup',\n styleUrl: 'pn-proxio-pricegroup.scss',\n})\nexport class PnProxioPricegroup {\n /** Specifies which endpoint domain we should load from */\n @Prop({ mutable: true }) endpoint: string = null;\n //@Prop() culture: string = \"sv-SE\";\n @Prop() language: string = 'sv';\n @Prop() market: string = 'se';\n @Prop() tariffid: string = '';\n @Prop() cache: boolean = true;\n\n @State() activeWeightIndex: number = 0;\n @State() data: ProxioPriceListGroupResponse = null;\n @State() i18n: ProxioPriceGroupi18n = translations['sv'];\n\n fetchHelper = new FetchHelper('proxiopricegroup');\n\n componentWillLoad() {\n this.setInitialValues().then(() => {\n this.init();\n });\n }\n\n async setInitialValues(href = window.location.href) {\n const marketWebContextService = new MarketWebContextService(href);\n const environment = await marketWebContextService.getEnvironmentName();\n\n if (!this.endpoint && environment?.indexOf('local') === -1) {\n const market = await marketWebContextService.getMarket();\n this.endpoint = await marketWebContextService.getEndpoint(environment, market);\n }\n\n if (!this.endpoint) {\n this.endpoint = '';\n }\n }\n\n init() {\n this.setLanguage();\n this.fetchData();\n }\n\n async fetchData() {\n if (!this.market || !this.language || !this.tariffid) {\n return;\n }\n const endpoint = this.endpoint.lastIndexOf('/') === this.endpoint.length - 1 ? this.endpoint.substring(0, this.endpoint.length - 1) : this.endpoint;\n const fetchUrl = `${endpoint}/api/proxio/price-list-group?tariffId=${this.tariffid}&market=${this.market}&language=${this.language}&cached=${this.cache}`;\n //const fetchUrl = `https://localhost:51547/api/proxio/price-list-group?tariffId=${this.tariffid}&market=${this.market}&language=${this.language}&cached=${this.cache}`;\n const data = (await this.fetchHelper.fetchJson(\n fetchUrl,\n {\n mode: 'cors',\n },\n this.cache,\n this.onFetchData.bind(this),\n )) as any;\n\n if (data?.proxioProduct) {\n this.data = data;\n }\n }\n\n onFetchData(data) {\n this.data = data;\n }\n\n @Listen('activeWeightIndex')\n setActiveWeightIndex(weightIndex: number) {\n let minIndex = 0;\n let maxIndex = this.data.proxioProduct?.weightAndPriceList?.length - 1 ?? minIndex;\n weightIndex = weightIndex > maxIndex ? maxIndex : weightIndex;\n weightIndex = weightIndex < minIndex ? minIndex : weightIndex;\n this.activeWeightIndex = weightIndex;\n }\n\n @Listen('language')\n setLanguage() {\n if (translations[this.language]) {\n this.i18n = translations[this.language] as ProxioPriceGroupi18n;\n }\n }\n\n getPriceString(product: ProxioProduct) {\n let price = product.weightAndPriceList ? product?.weightAndPriceList[this.activeWeightIndex]?.item2 : '';\n return price ? this.i18n.from + price : '';\n }\n\n getProductLink(product: ProxioProduct, productWeightGroupList: ProductWeightGroupListItem[]) {\n let productId = productWeightGroupList[this.activeWeightIndex]?.item2;\n let productLink = product.productLink ? product?.productLink : '';\n return productLink ? productLink + (productId ? '?productId=' + productId : '') : '';\n }\n\n isActive(index: number) {\n return index === this.activeWeightIndex;\n }\n\n getCarouselPosition(index: number) {\n switch (index) {\n case this.activeWeightIndex - 2: {\n return -2;\n }\n case this.activeWeightIndex - 1: {\n return -1;\n }\n case this.activeWeightIndex: {\n return 0;\n }\n case this.activeWeightIndex + 1: {\n return 1;\n }\n case this.activeWeightIndex + 2: {\n return 2;\n }\n default:\n return 'outside';\n }\n }\n\n getContainerPosition() {\n let maxIndex = this.data.proxioProduct.weightAndPriceList.length - 1;\n switch (this.activeWeightIndex) {\n case 0: {\n return 'end50';\n }\n case 1: {\n return 'end75';\n }\n case maxIndex - 1: {\n return 'start75';\n }\n case maxIndex: {\n return 'start50';\n }\n default: {\n return 'default';\n }\n }\n }\n\n render() {\n return (\n <Host>\n {this.data?.proxioProduct ? (\n <div class=\"proxio-pricegroup-container\">\n <div class=\"weightcontainer\">\n {this.data.proxioProduct.weightAndPriceList ? (\n <div class=\"weightvaluecontainer\">\n <pn-button\n disabled={this.activeWeightIndex === 0 ? 'disabled' : null}\n icon={arrow_left}\n appearance=\"light\"\n small=\"true\"\n onClick={() => this.setActiveWeightIndex(this.activeWeightIndex - 1)}\n ></pn-button>\n <div class=\"weightradios \" data-carousel-container-position={this.getContainerPosition()}>\n <div class=\"weightline\"></div>\n {this.data.proxioProduct.weightAndPriceList.map((weightItem, index) =>\n this.getCarouselPosition(index) !== null ? (\n <div class=\"weightdata\" data-carousel-position={this.getCarouselPosition(index)} onClick={() => this.setActiveWeightIndex(index)}>\n <input type=\"radio\" id={'weightradio' + index} name=\"weightradio\" value={index} checked={this.isActive(index)} />\n <label htmlFor={'weightradio' + index}>{weightItem.item1}</label>\n </div>\n ) : null,\n )}\n </div>\n <pn-button\n disabled={this.activeWeightIndex === this.data.proxioProduct?.weightAndPriceList?.length - 1 ? 'disabled' : null}\n icon={arrow_right}\n appearance=\"light\"\n small=\"true\"\n onClick={() => this.setActiveWeightIndex(this.activeWeightIndex + 1)}\n ></pn-button>\n </div>\n ) : null}\n </div>\n <pn-proxio-productcard>\n <pn-illustration slot=\"illustrationmobile\" illustration={this.data.proxioProduct.productIcon}></pn-illustration>\n <h2 slot=\"title\">{this.data.proxioProduct.productTitle}</h2>\n <pn-proxio-productcard-description\n slot=\"description\"\n heading={this.data.proxioProduct.productPreamble}\n highlight={this.data.proxioProduct.deliveryDateInformation}\n list={this.data.proxioProduct.productDescriptionBulletListItems}\n ></pn-proxio-productcard-description>\n <div slot=\"information\">\n <pn-proxio-productcard-information\n label={this.i18n.labelMaxDimensions}\n information={this.data.proxioProduct.productPackageDimensionsList as ProductGenericItem[]}\n ></pn-proxio-productcard-information>\n <pn-proxio-productcard-information\n label={this.i18n.labelMaxDimensionsRoll}\n information={this.data.proxioProduct.productRollDimensionsList as ProductGenericItem[]}\n ></pn-proxio-productcard-information>\n </div>\n <div slot=\"bottomtags\">\n {this.data.proxioProduct.usp1 ? <pn-titletag color=\"gray50\">{this.data.proxioProduct.usp1}</pn-titletag> : null}\n {this.data.proxioProduct.usp2 ? <pn-titletag color=\"gray50\">{this.data.proxioProduct.usp2}</pn-titletag> : null}\n {this.data.proxioProduct.usp3 ? <pn-titletag color=\"gray50\">{this.data.proxioProduct.usp3}</pn-titletag> : null}\n </div>\n <pn-illustration slot=\"illustration\" illustration={this.data.proxioProduct.productIcon}></pn-illustration>\n <div slot=\"pricelink\">\n <pn-proxio-productcard-pricelink\n price={this.getPriceString(this.data.proxioProduct)}\n link={this.getProductLink(this.data.proxioProduct, this.data.proxioProduct.productWeightGroupList)}\n linktext={this.data.proxioProduct.productLinkText}\n ></pn-proxio-productcard-pricelink>\n {this.data.relatedProxioProducts\n ? this.data.relatedProxioProducts.map(product => (\n <pn-proxio-productcard-pricelink\n price={this.getPriceString(product)}\n link={product.productLink}\n linktext={product.productLinkText}\n ></pn-proxio-productcard-pricelink>\n ))\n : null}\n </div>\n </pn-proxio-productcard>\n </div>\n ) : null}\n </Host>\n );\n }\n}\n"]}
1
+ {"version":3,"file":"pn-proxio-pricegroup.js","sourceRoot":"","sources":["../../../../src/components/widgets/pn-proxio-pricegroup/pn-proxio-pricegroup.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AACxE,OAAO,EAAE,WAAW,EAAE,MAAM,8BAA8B,CAAC;AAC3D,OAAO,EAAE,uBAAuB,EAAE,MAAM,0CAA0C,CAAC;AACnF,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAE9C,OAAO,EAAE,UAAU,EAAE,WAAW,EAAE,MAAM,qCAAqC,CAAC;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,CAAC,mBAAa,KAAK,EAAC,QAAQ,IAAE,IAAI,CAAC,IAAI,CAAC,aAAa,CAAC,IAAI,CAAe,CAAC,CAAC,CAAC,IAAI,CAC3G;gBACN,uBAAiB,IAAI,EAAC,cAAc,EAAC,YAAY,EAAE,IAAI,CAAC,IAAI,CAAC,aAAa,CAAC,WAAW,GAAoB;gBAC1G,WAAK,IAAI,EAAC,WAAW;oBACnB,uCACE,KAAK,EAAE,IAAI,CAAC,cAAc,CAAC,IAAI,CAAC,IAAI,CAAC,aAAa,CAAC,EACnD,IAAI,EAAE,IAAI,CAAC,cAAc,CAAC,IAAI,CAAC,IAAI,CAAC,aAAa,EAAE,IAAI,CAAC,IAAI,CAAC,aAAa,CAAC,sBAAsB,CAAC,EAClG,QAAQ,EAAE,IAAI,CAAC,IAAI,CAAC,aAAa,CAAC,eAAe,GAChB;oBAClC,IAAI,CAAC,IAAI,CAAC,qBAAqB;wBAC9B,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,qBAAqB,CAAC,GAAG,CAAC,OAAO,CAAC,EAAE,CAAC,CAC7C,uCACE,KAAK,EAAE,IAAI,CAAC,cAAc,CAAC,OAAO,CAAC,EACnC,IAAI,EAAE,OAAO,CAAC,WAAW,EACzB,QAAQ,EAAE,OAAO,CAAC,eAAe,GACA,CACpC,CAAC;wBACJ,CAAC,CAAC,IAAI,CACJ,CACgB,CACpB,CACP,CAAC,CAAC,CAAC,IAAI,CACH,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, h, Host, Listen, Prop, State } from '@stencil/core';\nimport { FetchHelper } from '../../../globals/FetchHelper';\nimport { MarketWebContextService } from '../../../globals/MarketWebContextService';\nimport { translations } from './translations';\nimport { ProductGenericItem, ProxioPriceGroupi18n, ProxioPriceListGroupResponse, ProxioProduct, ProductWeightGroupListItem } from './types';\nimport { arrow_left, arrow_right } from 'pn-design-assets/pn-assets/icons.js';\n\n@Component({\n tag: 'pn-proxio-pricegroup',\n styleUrl: 'pn-proxio-pricegroup.scss',\n})\nexport class PnProxioPricegroup {\n /** Specifies which endpoint domain we should load from */\n @Prop({ mutable: true }) endpoint: string = null;\n //@Prop() culture: string = \"sv-SE\";\n @Prop() language: string = 'sv';\n @Prop() market: string = 'se';\n @Prop() tariffid: string = '';\n @Prop() cache: boolean = true;\n\n @State() activeWeightIndex: number = 0;\n @State() data: ProxioPriceListGroupResponse = null;\n @State() i18n: ProxioPriceGroupi18n = translations['sv'];\n\n fetchHelper = new FetchHelper('proxiopricegroup');\n\n componentWillLoad() {\n this.setInitialValues().then(() => {\n this.init();\n });\n }\n\n async setInitialValues(href = window.location.href) {\n const marketWebContextService = new MarketWebContextService(href);\n const environment = await marketWebContextService.getEnvironmentName();\n\n if (!this.endpoint && environment?.indexOf('local') === -1) {\n const market = await marketWebContextService.getMarket();\n this.endpoint = await marketWebContextService.getEndpoint(environment, market);\n }\n\n if (!this.endpoint) {\n this.endpoint = '';\n }\n }\n\n init() {\n this.setLanguage();\n this.fetchData();\n }\n\n async fetchData() {\n if (!this.market || !this.language || !this.tariffid) {\n return;\n }\n const endpoint = this.endpoint.lastIndexOf('/') === this.endpoint.length - 1 ? this.endpoint.substring(0, this.endpoint.length - 1) : this.endpoint;\n const fetchUrl = `${endpoint}/api/proxio/price-list-group?tariffId=${this.tariffid}&market=${this.market}&language=${this.language}&cached=${this.cache}`;\n //const fetchUrl = `https://localhost:51547/api/proxio/price-list-group?tariffId=${this.tariffid}&market=${this.market}&language=${this.language}&cached=${this.cache}`;\n const data = (await this.fetchHelper.fetchJson(\n fetchUrl,\n {\n mode: 'cors',\n },\n this.cache,\n this.onFetchData.bind(this),\n )) as any;\n\n if (data?.proxioProduct) {\n this.data = data;\n }\n }\n\n onFetchData(data) {\n this.data = data;\n }\n\n @Listen('activeWeightIndex')\n setActiveWeightIndex(weightIndex: number) {\n let minIndex = 0;\n let maxIndex = this.data.proxioProduct?.weightAndPriceList?.length - 1 ?? minIndex;\n weightIndex = weightIndex > maxIndex ? maxIndex : weightIndex;\n weightIndex = weightIndex < minIndex ? minIndex : weightIndex;\n this.activeWeightIndex = weightIndex;\n }\n\n @Listen('language')\n setLanguage() {\n if (translations[this.language]) {\n this.i18n = translations[this.language] as ProxioPriceGroupi18n;\n }\n }\n\n getPriceString(product: ProxioProduct) {\n let price = product.weightAndPriceList ? product?.weightAndPriceList[this.activeWeightIndex]?.item2 : '';\n return price ? this.i18n.from + price : '';\n }\n\n getProductLink(product: ProxioProduct, productWeightGroupList: ProductWeightGroupListItem[]) {\n let productId = productWeightGroupList[this.activeWeightIndex]?.item2;\n let productLink = product.productLink ? product?.productLink : '';\n return productLink ? productLink + (productId ? '?productId=' + productId : '') : '';\n }\n\n isActive(index: number) {\n return index === this.activeWeightIndex;\n }\n\n getCarouselPosition(index: number) {\n switch (index) {\n case this.activeWeightIndex - 2: {\n return -2;\n }\n case this.activeWeightIndex - 1: {\n return -1;\n }\n case this.activeWeightIndex: {\n return 0;\n }\n case this.activeWeightIndex + 1: {\n return 1;\n }\n case this.activeWeightIndex + 2: {\n return 2;\n }\n default:\n return 'outside';\n }\n }\n\n getContainerPosition() {\n let maxIndex = this.data.proxioProduct.weightAndPriceList.length - 1;\n switch (this.activeWeightIndex) {\n case 0: {\n return 'end50';\n }\n case 1: {\n return 'end75';\n }\n case maxIndex - 1: {\n return 'start75';\n }\n case maxIndex: {\n return 'start50';\n }\n default: {\n return 'default';\n }\n }\n }\n\n render() {\n return (\n <Host>\n {this.data?.proxioProduct ? (\n <div class=\"proxio-pricegroup-container\">\n <div class=\"weightcontainer\">\n {this.data.proxioProduct.weightAndPriceList ? (\n <div class=\"weightvaluecontainer\">\n <pn-button\n disabled={this.activeWeightIndex === 0 ? 'disabled' : null}\n icon={arrow_left}\n appearance=\"light\"\n small=\"true\"\n onClick={() => this.setActiveWeightIndex(this.activeWeightIndex - 1)}\n ></pn-button>\n <div class=\"weightradios \" data-carousel-container-position={this.getContainerPosition()}>\n <div class=\"weightline\"></div>\n {this.data.proxioProduct.weightAndPriceList.map((weightItem, index) =>\n this.getCarouselPosition(index) !== null ? (\n <div class=\"weightdata\" data-carousel-position={this.getCarouselPosition(index)} onClick={() => this.setActiveWeightIndex(index)}>\n <input type=\"radio\" id={'weightradio' + index} name=\"weightradio\" value={index} checked={this.isActive(index)} />\n <label htmlFor={'weightradio' + index}>{weightItem.item1}</label>\n </div>\n ) : null,\n )}\n </div>\n <pn-button\n disabled={this.activeWeightIndex === this.data.proxioProduct?.weightAndPriceList?.length - 1 ? 'disabled' : null}\n icon={arrow_right}\n appearance=\"light\"\n small=\"true\"\n onClick={() => this.setActiveWeightIndex(this.activeWeightIndex + 1)}\n ></pn-button>\n </div>\n ) : null}\n </div>\n <pn-proxio-productcard>\n <pn-illustration slot=\"illustrationmobile\" illustration={this.data.proxioProduct.productIcon}></pn-illustration>\n <h2 slot=\"title\">{this.data.proxioProduct.productTitle}</h2>\n <pn-proxio-productcard-description\n slot=\"description\"\n heading={this.data.proxioProduct.productPreamble}\n highlight={this.data.proxioProduct.deliveryDateInformation}\n list={this.data.proxioProduct.productDescriptionBulletListItems}\n ></pn-proxio-productcard-description>\n <div slot=\"information\">\n <pn-proxio-productcard-information\n label={this.i18n.labelMaxDimensions}\n information={this.data.proxioProduct.productPackageDimensionsList as ProductGenericItem[]}\n ></pn-proxio-productcard-information>\n <pn-proxio-productcard-information\n label={this.i18n.labelMaxDimensionsRoll}\n information={this.data.proxioProduct.productRollDimensionsList as ProductGenericItem[]}\n ></pn-proxio-productcard-information>\n </div>\n <div slot=\"bottomtags\">\n {this.data.proxioProduct.usp1 ? <pn-titletag color=\"gray50\">{this.data.proxioProduct.usp1}</pn-titletag> : null}\n {this.data.proxioProduct.usp2 ? <pn-titletag color=\"gray50\">{this.data.proxioProduct.usp2}</pn-titletag> : null}\n {this.data.proxioProduct.usp3 ? <pn-titletag color=\"gray50\">{this.data.proxioProduct.usp3}</pn-titletag> : null}\n </div>\n <pn-illustration slot=\"illustration\" illustration={this.data.proxioProduct.productIcon}></pn-illustration>\n <div slot=\"pricelink\">\n <pn-proxio-productcard-pricelink\n price={this.getPriceString(this.data.proxioProduct)}\n link={this.getProductLink(this.data.proxioProduct, this.data.proxioProduct.productWeightGroupList)}\n linktext={this.data.proxioProduct.productLinkText}\n ></pn-proxio-productcard-pricelink>\n {this.data.relatedProxioProducts\n ? this.data.relatedProxioProducts.map(product => (\n <pn-proxio-productcard-pricelink\n price={this.getPriceString(product)}\n link={product.productLink}\n linktext={product.productLinkText}\n ></pn-proxio-productcard-pricelink>\n ))\n : null}\n </div>\n </pn-proxio-productcard>\n </div>\n ) : null}\n </Host>\n );\n }\n}\n"]}
@@ -9,6 +9,7 @@ export class PnUspPromoter {
9
9
  this.rightAlign = false;
10
10
  this.hideMobileImage = false;
11
11
  }
12
+ hostElement;
12
13
  centerMobileContent() {
13
14
  const slot = this.hostElement.querySelector('[slot="illustration"]');
14
15
  if (this.hideMobileImage || slot == null) {
@@ -1 +1 @@
1
- {"version":3,"file":"pn-usp-promoter.js","sourceRoot":"","sources":["../../../../src/components/widgets/pn-usp-promoter/pn-usp-promoter.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;AAMlE,MAAM,OAAO,aAAa;;uBAGE,IAAI;gCACK,IAAI;wBACZ,IAAI;kCACM,IAAI;yBACZ,KAAK;0BACJ,KAAK;+BACA,KAAK;;IAEhC,mBAAmB;QACzB,MAAM,IAAI,GAAG,IAAI,CAAC,WAAW,CAAC,aAAa,CAAC,uBAAuB,CAAC,CAAC;QACrE,IAAI,IAAI,CAAC,eAAe,IAAI,IAAI,IAAI,IAAI,EAAE,CAAC;YACzC,OAAO,uCAAuC,C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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, Prop, h, Host, Element } from '@stencil/core';\n\n@Component({\n tag: 'pn-usp-promoter',\n styleUrl: 'pn-usp-promoter.scss',\n})\nexport class PnUspPromoter {\n @Element() hostElement: HTMLElement;\n\n @Prop() heading: string = null;\n @Prop() headingExtension: string = null;\n @Prop() bodyText: string = null;\n @Prop() backgroundGradient: string = null;\n @Prop() fullWidth: boolean = false;\n @Prop() rightAlign: boolean = false;\n @Prop() hideMobileImage: boolean = false;\n\n private centerMobileContent() {\n const slot = this.hostElement.querySelector('[slot=\"illustration\"]');\n if (this.hideMobileImage || slot == null) {\n return 'usp-promoter--hide-image-small-screen';\n }\n return \"\";\n }\n\n render() {\n const { fullWidth, rightAlign } = this;\n const classes = [\n 'usp-promoter',\n fullWidth ? \"usp-promoter--full-width\" : \"\",\n rightAlign ? \"usp-promoter--right-align\" : \"\",\n ].join(' ');\n const hasHeadingExtension = this.headingExtension ? \"usp-promoter__heading-extension\" : \"\";\n\n return (\n <Host>\n <div class={` ${classes} ${this.centerMobileContent()}`} style={{ 'background': `${this.backgroundGradient}` }}>\n <div class=\"usp-promoter__content\">\n <slot name=\"illustration\"></slot>\n <div class=\"usp-promoter__content-wrapper\">\n <h2 class={`usp-promoter__content-heading ${hasHeadingExtension}`}>\n <span>{this.heading}</span>\n {this.headingExtension ? <span>{this.headingExtension}</span> : null}\n </h2>\n <p class=\"usp-promoter__content-text\">{this.bodyText}</p>\n <slot name=\"app-store\"></slot>\n <slot name=\"usp-buttons\"></slot>\n </div>\n </div>\n </div>\n </Host>\n );\n }\n}\n"]}
1
+ {"version":3,"file":"pn-usp-promoter.js","sourceRoot":"","sources":["../../../../src/components/widgets/pn-usp-promoter/pn-usp-promoter.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;AAMlE,MA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wBACL,0DAAG,KAAK,EAAC,4BAA4B,IAAE,IAAI,CAAC,QAAQ,CAAK;wBACzD,6DAAM,IAAI,EAAC,WAAW,GAAQ;wBAC9B,6DAAM,IAAI,EAAC,aAAa,GAAQ,CAC5B,CACF,CACF,CACD,CACR,CAAC;IACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, Prop, h, Host, Element } from '@stencil/core';\n\n@Component({\n tag: 'pn-usp-promoter',\n styleUrl: 'pn-usp-promoter.scss',\n})\nexport class PnUspPromoter {\n @Element() hostElement: HTMLElement;\n\n @Prop() heading: string = null;\n @Prop() headingExtension: string = null;\n @Prop() bodyText: string = null;\n @Prop() backgroundGradient: string = null;\n @Prop() fullWidth: boolean = false;\n @Prop() rightAlign: boolean = false;\n @Prop() hideMobileImage: boolean = false;\n\n private centerMobileContent() {\n const slot = this.hostElement.querySelector('[slot=\"illustration\"]');\n if (this.hideMobileImage || slot == null) {\n return 'usp-promoter--hide-image-small-screen';\n }\n return \"\";\n }\n\n render() {\n const { fullWidth, rightAlign } = this;\n const classes = [\n 'usp-promoter',\n fullWidth ? \"usp-promoter--full-width\" : \"\",\n rightAlign ? \"usp-promoter--right-align\" : \"\",\n ].join(' ');\n const hasHeadingExtension = this.headingExtension ? \"usp-promoter__heading-extension\" : \"\";\n\n return (\n <Host>\n <div class={` ${classes} ${this.centerMobileContent()}`} style={{ 'background': `${this.backgroundGradient}` }}>\n <div class=\"usp-promoter__content\">\n <slot name=\"illustration\"></slot>\n <div class=\"usp-promoter__content-wrapper\">\n <h2 class={`usp-promoter__content-heading ${hasHeadingExtension}`}>\n <span>{this.heading}</span>\n {this.headingExtension ? <span>{this.headingExtension}</span> : null}\n </h2>\n <p class=\"usp-promoter__content-text\">{this.bodyText}</p>\n <slot name=\"app-store\"></slot>\n <slot name=\"usp-buttons\"></slot>\n </div>\n </div>\n </div>\n </Host>\n );\n }\n}\n"]}