@salla.sa/twilight-components 2.14.493 → 2.14.494

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 (363) hide show
  1. package/dist/cjs/{filepond-DqhwRQm7.js → filepond-CYww4tEC.js} +1 -1
  2. package/dist/cjs/{filepond-plugin-file-poster-D19muTiF.js → filepond-plugin-file-poster-DPW9mW_l.js} +1 -1
  3. package/dist/cjs/{filepond-plugin-file-validate-size-DbAdnWu5.js → filepond-plugin-file-validate-size-CK2KIHil.js} +1 -1
  4. package/dist/cjs/{filepond-plugin-file-validate-type-avp8hUs1.js → filepond-plugin-file-validate-type-CPvzHnlO.js} +1 -1
  5. package/dist/cjs/{filepond-plugin-image-edit-Y4pS7CAo.js → filepond-plugin-image-edit-DfYj0utx.js} +1 -1
  6. package/dist/cjs/{filepond-plugin-image-exif-orientation-C5ctyI6s.js → filepond-plugin-image-exif-orientation-BPH4xTYe.js} +1 -1
  7. package/dist/cjs/{filepond-plugin-image-preview-C9Cy8UAv.js → filepond-plugin-image-preview-BbB7wI4M.js} +1 -1
  8. package/dist/cjs/{functions-D4bL1wnj.js → functions-C3W0O3Qh.js} +1 -1
  9. package/dist/cjs/{index-C_qxP6pD.js → index-BQKhP5JS.js} +14 -14
  10. package/dist/cjs/{index-CyG4y8gY.js → index-CQRzEmek.js} +1 -1
  11. package/dist/cjs/loader.cjs.js +2 -2
  12. package/dist/cjs/salla-accordion-body_2.cjs.entry.js +1 -1
  13. package/dist/cjs/salla-accordion_6.cjs.entry.js +1 -1
  14. package/dist/cjs/salla-add-product-button_5.cjs.entry.js +1 -1
  15. package/dist/cjs/salla-advertisement.cjs.entry.js +1 -1
  16. package/dist/cjs/salla-alert_2.cjs.entry.js +1 -1
  17. package/dist/cjs/salla-app-install-alert.cjs.entry.js +1 -1
  18. package/dist/cjs/salla-apps-icons.cjs.entry.js +1 -1
  19. package/dist/cjs/salla-badge.cjs.entry.js +1 -1
  20. package/dist/cjs/salla-booking-field_7.cjs.entry.js +10 -10
  21. package/dist/cjs/salla-bullet-delivery_2.cjs.entry.js +1 -1
  22. package/dist/cjs/salla-cart-coupons.cjs.entry.js +1 -1
  23. package/dist/cjs/salla-cart-item-offers_2.cjs.entry.js +1 -1
  24. package/dist/cjs/salla-cart-summary-card.cjs.entry.js +1 -1
  25. package/dist/cjs/salla-cashback-banner.cjs.entry.js +1 -1
  26. package/dist/cjs/salla-comment-factors.cjs.entry.js +1 -1
  27. package/dist/cjs/salla-comment-form_8.cjs.entry.js +1 -1
  28. package/dist/cjs/salla-conditional-offer.cjs.entry.js +1 -1
  29. package/dist/cjs/salla-contacts.cjs.entry.js +1 -1
  30. package/dist/cjs/salla-cookies-bar.cjs.entry.js +1 -1
  31. package/dist/cjs/{salla-count-down.cjs.entry.js → salla-count-down_2.cjs.entry.js} +204 -1
  32. package/dist/cjs/salla-custom-fields.cjs.entry.js +1 -1
  33. package/dist/cjs/salla-delivery-promise.cjs.entry.js +1 -1
  34. package/dist/cjs/salla-edit-order-button.cjs.entry.js +1 -1
  35. package/dist/cjs/salla-filters-widget.cjs.entry.js +1 -1
  36. package/dist/cjs/salla-filters.cjs.entry.js +1 -1
  37. package/dist/cjs/salla-fulfillment-methods.cjs.entry.js +1 -1
  38. package/dist/cjs/salla-gifting.cjs.entry.js +1 -1
  39. package/dist/cjs/salla-hook.cjs.entry.js +1 -1
  40. package/dist/cjs/salla-infinite-scroll.cjs.entry.js +1 -1
  41. package/dist/cjs/salla-installment.cjs.entry.js +1 -1
  42. package/dist/cjs/salla-list-tile.cjs.entry.js +1 -1
  43. package/dist/cjs/salla-localization-modal.cjs.entry.js +1 -1
  44. package/dist/cjs/salla-login-modal.cjs.entry.js +1 -1
  45. package/dist/cjs/salla-loyalty-banner.cjs.entry.js +3 -3
  46. package/dist/cjs/{salla-reward-action_4.cjs.entry.js → salla-loyalty-exchange-product-card_5.cjs.entry.js} +63 -21
  47. package/dist/cjs/salla-loyalty-hero_2.cjs.entry.js +11 -11
  48. package/dist/cjs/salla-loyalty-panel.cjs.entry.js +6 -5
  49. package/dist/cjs/salla-loyalty-points-banner.cjs.entry.js +1 -1
  50. package/dist/cjs/salla-loyalty-points-history.cjs.entry.js +1 -1
  51. package/dist/cjs/salla-loyalty-prize-item.cjs.entry.js +1 -1
  52. package/dist/cjs/salla-loyalty-program.cjs.entry.js +6 -5
  53. package/dist/cjs/salla-loyalty-reward.cjs.entry.js +5 -5
  54. package/dist/cjs/salla-loyalty.cjs.entry.js +1 -1
  55. package/dist/cjs/salla-maintenance-alert.cjs.entry.js +1 -1
  56. package/dist/cjs/salla-map_2.cjs.entry.js +1 -1
  57. package/dist/cjs/salla-menu.cjs.entry.js +1 -1
  58. package/dist/cjs/salla-metadata.cjs.entry.js +1 -1
  59. package/dist/cjs/salla-multiple-bundle-product-cart_2.cjs.entry.js +1 -1
  60. package/dist/cjs/salla-multiple-bundle-product-options-modal_2.cjs.entry.js +1 -1
  61. package/dist/cjs/salla-multiple-bundle-product.cjs.entry.js +1 -1
  62. package/dist/cjs/salla-next-order-coupon.cjs.entry.js +1 -1
  63. package/dist/cjs/salla-notification-item.cjs.entry.js +1 -1
  64. package/dist/cjs/salla-notifications.cjs.entry.js +1 -1
  65. package/dist/cjs/salla-offer-modal.cjs.entry.js +1 -1
  66. package/dist/cjs/salla-offer.cjs.entry.js +1 -1
  67. package/dist/cjs/salla-order-branch.cjs.entry.js +1 -1
  68. package/dist/cjs/salla-order-cancel.cjs.entry.js +1 -1
  69. package/dist/cjs/salla-order-details-multiple-bundle-product.cjs.entry.js +1 -1
  70. package/dist/cjs/salla-order-details-options.cjs.entry.js +1 -1
  71. package/dist/cjs/salla-order-details.cjs.entry.js +1 -1
  72. package/dist/cjs/salla-order-edit-item.cjs.entry.js +1 -1
  73. package/dist/cjs/salla-order-edit-product-card.cjs.entry.js +1 -1
  74. package/dist/cjs/salla-order-edit.cjs.entry.js +1 -1
  75. package/dist/cjs/salla-order-summary.cjs.entry.js +1 -1
  76. package/dist/cjs/salla-order-totals-card.cjs.entry.js +1 -1
  77. package/dist/cjs/salla-orders.cjs.entry.js +1 -1
  78. package/dist/cjs/salla-payments.cjs.entry.js +1 -1
  79. package/dist/cjs/salla-placeholder.cjs.entry.js +1 -1
  80. package/dist/cjs/salla-price-range.cjs.entry.js +1 -1
  81. package/dist/cjs/salla-product-card-embed.cjs.entry.js +1 -1
  82. package/dist/cjs/{salla-order-options-modal_3.cjs.entry.js → salla-product-card_2.cjs.entry.js} +1 -204
  83. package/dist/cjs/salla-product-size-guide.cjs.entry.js +1 -1
  84. package/dist/cjs/salla-products-list.cjs.entry.js +1 -1
  85. package/dist/cjs/salla-quick-order.cjs.entry.js +1 -1
  86. package/dist/cjs/salla-rating-modal-v2.cjs.entry.js +1 -1
  87. package/dist/cjs/salla-rating-modal.cjs.entry.js +1 -1
  88. package/dist/cjs/salla-review-factors-tags.cjs.entry.js +1 -1
  89. package/dist/cjs/salla-scopes.cjs.entry.js +1 -1
  90. package/dist/cjs/salla-search.cjs.entry.js +1 -1
  91. package/dist/cjs/salla-skeleton.cjs.entry.js +1 -1
  92. package/dist/cjs/salla-slider.cjs.entry.js +1 -1
  93. package/dist/cjs/salla-social-share.cjs.entry.js +1 -1
  94. package/dist/cjs/salla-social.cjs.entry.js +1 -1
  95. package/dist/cjs/salla-tab-content_3.cjs.entry.js +1 -1
  96. package/dist/cjs/salla-tiered-offer.cjs.entry.js +1 -1
  97. package/dist/cjs/salla-tooltip.cjs.entry.js +1 -1
  98. package/dist/cjs/salla-trust-badges.cjs.entry.js +1 -1
  99. package/dist/cjs/salla-user-menu.cjs.entry.js +1 -1
  100. package/dist/cjs/salla-user-profile.cjs.entry.js +1 -1
  101. package/dist/cjs/salla-user-settings.cjs.entry.js +1 -1
  102. package/dist/cjs/salla-verify.cjs.entry.js +1 -1
  103. package/dist/cjs/salla-wallet.cjs.entry.js +1 -1
  104. package/dist/cjs/salla-wishlist-actions.cjs.entry.js +1 -1
  105. package/dist/cjs/{tracked-promise-B35EnX6x.js → tracked-promise-DYGNjn0V.js} +1 -1
  106. package/dist/cjs/twilight.cjs.js +2 -2
  107. package/dist/cjs/{vanilla-picker-BofbsHQq.js → vanilla-picker-CVraU_Ic.js} +1 -1
  108. package/dist/collection/collection-manifest.json +1 -0
  109. package/dist/collection/components/salla-loyalty-program/salla-loyalty-exchange-product-card.js +72 -0
  110. package/dist/collection/components/salla-loyalty-program/salla-loyalty-hero.js +3 -3
  111. package/dist/collection/components/salla-loyalty-program/salla-loyalty-panel.js +4 -2
  112. package/dist/collection/components/salla-loyalty-program/salla-loyalty-point.js +4 -4
  113. package/dist/collection/components/salla-loyalty-program/salla-loyalty-program.css +48 -0
  114. package/dist/collection/components/salla-loyalty-program/salla-loyalty-program.js +3 -1
  115. package/dist/collection/components/salla-loyalty-program/salla-loyalty-reward.js +2 -2
  116. package/dist/collection/components/salla-loyalty-program/salla-reward-action.js +1 -4
  117. package/dist/collection/components/salla-loyalty-program/salla-reward-card.js +1 -1
  118. package/dist/collection/components/salla-loyalty-program/salla-reward-details.js +58 -5
  119. package/dist/collection/components/salla-loyalty-program/salla-reward-exchange.js +1 -5
  120. package/dist/components/index.js +2 -2
  121. package/dist/components/salla-loyalty-banner.js +8 -2
  122. package/dist/components/salla-loyalty-exchange-product-card.d.ts +11 -0
  123. package/dist/components/salla-loyalty-exchange-product-card.js +9 -0
  124. package/dist/components/salla-loyalty-exchange-product-card2.js +151 -0
  125. package/dist/components/salla-loyalty-hero2.js +4 -4
  126. package/dist/components/salla-loyalty-panel.js +33 -25
  127. package/dist/components/salla-loyalty-point2.js +5 -5
  128. package/dist/components/salla-loyalty-program.js +30 -22
  129. package/dist/components/salla-loyalty-reward.js +3 -3
  130. package/dist/components/salla-reward-action2.js +9 -6
  131. package/dist/components/salla-reward-card2.js +2 -2
  132. package/dist/components/salla-reward-details2.js +63 -27
  133. package/dist/components/salla-reward-exchange2.js +5 -9
  134. package/dist/esm/{filepond-Coz90MV8.js → filepond-V-9YwoVf.js} +1 -1
  135. package/dist/esm/{filepond-plugin-file-poster-CiMXS6O6.js → filepond-plugin-file-poster-BBE8fAHq.js} +1 -1
  136. package/dist/esm/{filepond-plugin-file-validate-size-DycwNhLB.js → filepond-plugin-file-validate-size-CR9iK259.js} +1 -1
  137. package/dist/esm/{filepond-plugin-file-validate-type-BTWmt4Mh.js → filepond-plugin-file-validate-type-B4eStrHv.js} +1 -1
  138. package/dist/esm/{filepond-plugin-image-edit-DY5Ti-2K.js → filepond-plugin-image-edit-B84jjo8b.js} +1 -1
  139. package/dist/esm/{filepond-plugin-image-exif-orientation-BxxwFT1Z.js → filepond-plugin-image-exif-orientation-BAaD5wJD.js} +1 -1
  140. package/dist/esm/{filepond-plugin-image-preview-CjBmoCCR.js → filepond-plugin-image-preview-Bn4GgIpr.js} +1 -1
  141. package/dist/esm/{functions-DhhgGPcx.js → functions-Btrtoght.js} +1 -1
  142. package/dist/esm/{index-DGH40_w6.js → index-3omad4sF.js} +14 -14
  143. package/dist/esm/{index-9AaLpeq_.js → index-Co4ZrgLC.js} +1 -1
  144. package/dist/esm/loader.js +3 -3
  145. package/dist/esm/salla-accordion-body_2.entry.js +1 -1
  146. package/dist/esm/salla-accordion_6.entry.js +1 -1
  147. package/dist/esm/salla-add-product-button_5.entry.js +1 -1
  148. package/dist/esm/salla-advertisement.entry.js +1 -1
  149. package/dist/esm/salla-alert_2.entry.js +1 -1
  150. package/dist/esm/salla-app-install-alert.entry.js +1 -1
  151. package/dist/esm/salla-apps-icons.entry.js +1 -1
  152. package/dist/esm/salla-badge.entry.js +1 -1
  153. package/dist/esm/salla-booking-field_7.entry.js +10 -10
  154. package/dist/esm/salla-bullet-delivery_2.entry.js +1 -1
  155. package/dist/esm/salla-cart-coupons.entry.js +1 -1
  156. package/dist/esm/salla-cart-item-offers_2.entry.js +1 -1
  157. package/dist/esm/salla-cart-summary-card.entry.js +1 -1
  158. package/dist/esm/salla-cashback-banner.entry.js +1 -1
  159. package/dist/esm/salla-comment-factors.entry.js +1 -1
  160. package/dist/esm/salla-comment-form_8.entry.js +1 -1
  161. package/dist/esm/salla-conditional-offer.entry.js +1 -1
  162. package/dist/esm/salla-contacts.entry.js +1 -1
  163. package/dist/esm/salla-cookies-bar.entry.js +1 -1
  164. package/dist/esm/{salla-count-down.entry.js → salla-count-down_2.entry.js} +204 -2
  165. package/dist/esm/salla-custom-fields.entry.js +1 -1
  166. package/dist/esm/salla-delivery-promise.entry.js +1 -1
  167. package/dist/esm/salla-edit-order-button.entry.js +1 -1
  168. package/dist/esm/salla-filters-widget.entry.js +1 -1
  169. package/dist/esm/salla-filters.entry.js +1 -1
  170. package/dist/esm/salla-fulfillment-methods.entry.js +1 -1
  171. package/dist/esm/salla-gifting.entry.js +1 -1
  172. package/dist/esm/salla-hook.entry.js +1 -1
  173. package/dist/esm/salla-infinite-scroll.entry.js +1 -1
  174. package/dist/esm/salla-installment.entry.js +1 -1
  175. package/dist/esm/salla-list-tile.entry.js +1 -1
  176. package/dist/esm/salla-localization-modal.entry.js +1 -1
  177. package/dist/esm/salla-login-modal.entry.js +1 -1
  178. package/dist/esm/salla-loyalty-banner.entry.js +3 -3
  179. package/dist/esm/{salla-reward-action_4.entry.js → salla-loyalty-exchange-product-card_5.entry.js} +63 -22
  180. package/dist/esm/salla-loyalty-hero_2.entry.js +11 -11
  181. package/dist/esm/salla-loyalty-panel.entry.js +6 -5
  182. package/dist/esm/salla-loyalty-points-banner.entry.js +1 -1
  183. package/dist/esm/salla-loyalty-points-history.entry.js +1 -1
  184. package/dist/esm/salla-loyalty-prize-item.entry.js +1 -1
  185. package/dist/esm/salla-loyalty-program.entry.js +6 -5
  186. package/dist/esm/salla-loyalty-reward.entry.js +5 -5
  187. package/dist/esm/salla-loyalty.entry.js +1 -1
  188. package/dist/esm/salla-maintenance-alert.entry.js +1 -1
  189. package/dist/esm/salla-map_2.entry.js +1 -1
  190. package/dist/esm/salla-menu.entry.js +1 -1
  191. package/dist/esm/salla-metadata.entry.js +1 -1
  192. package/dist/esm/salla-multiple-bundle-product-cart_2.entry.js +1 -1
  193. package/dist/esm/salla-multiple-bundle-product-options-modal_2.entry.js +1 -1
  194. package/dist/esm/salla-multiple-bundle-product.entry.js +1 -1
  195. package/dist/esm/salla-next-order-coupon.entry.js +1 -1
  196. package/dist/esm/salla-notification-item.entry.js +1 -1
  197. package/dist/esm/salla-notifications.entry.js +1 -1
  198. package/dist/esm/salla-offer-modal.entry.js +1 -1
  199. package/dist/esm/salla-offer.entry.js +1 -1
  200. package/dist/esm/salla-order-branch.entry.js +1 -1
  201. package/dist/esm/salla-order-cancel.entry.js +1 -1
  202. package/dist/esm/salla-order-details-multiple-bundle-product.entry.js +1 -1
  203. package/dist/esm/salla-order-details-options.entry.js +1 -1
  204. package/dist/esm/salla-order-details.entry.js +1 -1
  205. package/dist/esm/salla-order-edit-item.entry.js +1 -1
  206. package/dist/esm/salla-order-edit-product-card.entry.js +1 -1
  207. package/dist/esm/salla-order-edit.entry.js +1 -1
  208. package/dist/esm/salla-order-summary.entry.js +1 -1
  209. package/dist/esm/salla-order-totals-card.entry.js +1 -1
  210. package/dist/esm/salla-orders.entry.js +1 -1
  211. package/dist/esm/salla-payments.entry.js +1 -1
  212. package/dist/esm/salla-placeholder.entry.js +1 -1
  213. package/dist/esm/salla-price-range.entry.js +1 -1
  214. package/dist/esm/salla-product-card-embed.entry.js +1 -1
  215. package/dist/esm/{salla-order-options-modal_3.entry.js → salla-product-card_2.entry.js} +2 -204
  216. package/dist/esm/salla-product-size-guide.entry.js +1 -1
  217. package/dist/esm/salla-products-list.entry.js +1 -1
  218. package/dist/esm/salla-quick-order.entry.js +1 -1
  219. package/dist/esm/salla-rating-modal-v2.entry.js +1 -1
  220. package/dist/esm/salla-rating-modal.entry.js +1 -1
  221. package/dist/esm/salla-review-factors-tags.entry.js +1 -1
  222. package/dist/esm/salla-scopes.entry.js +1 -1
  223. package/dist/esm/salla-search.entry.js +1 -1
  224. package/dist/esm/salla-skeleton.entry.js +1 -1
  225. package/dist/esm/salla-slider.entry.js +1 -1
  226. package/dist/esm/salla-social-share.entry.js +1 -1
  227. package/dist/esm/salla-social.entry.js +1 -1
  228. package/dist/esm/salla-tab-content_3.entry.js +1 -1
  229. package/dist/esm/salla-tiered-offer.entry.js +1 -1
  230. package/dist/esm/salla-tooltip.entry.js +1 -1
  231. package/dist/esm/salla-trust-badges.entry.js +1 -1
  232. package/dist/esm/salla-user-menu.entry.js +1 -1
  233. package/dist/esm/salla-user-profile.entry.js +1 -1
  234. package/dist/esm/salla-user-settings.entry.js +1 -1
  235. package/dist/esm/salla-verify.entry.js +1 -1
  236. package/dist/esm/salla-wallet.entry.js +1 -1
  237. package/dist/esm/salla-wishlist-actions.entry.js +1 -1
  238. package/dist/esm/{tracked-promise-ILCl5q9c.js → tracked-promise-BPB6hr9g.js} +1 -1
  239. package/dist/esm/twilight.js +3 -3
  240. package/dist/esm/{vanilla-picker-CXWkB9Rj.js → vanilla-picker-CN8ge6Yh.js} +1 -1
  241. package/dist/twilight/p-03d231a1.entry.js +4 -0
  242. package/dist/twilight/p-07b25f79.entry.js +4 -0
  243. package/dist/twilight/{p-daff5fee.entry.js → p-07cd3153.entry.js} +1 -1
  244. package/dist/twilight/{p-5d642891.entry.js → p-07feb752.entry.js} +1 -1
  245. package/dist/twilight/p-0838e0cc.entry.js +4 -0
  246. package/dist/twilight/{p-8f9578ea.entry.js → p-08a065d6.entry.js} +1 -1
  247. package/dist/twilight/{p-fb460b15.entry.js → p-0a0f2340.entry.js} +1 -1
  248. package/dist/twilight/{p-bc46608a.entry.js → p-0c55c5ed.entry.js} +1 -1
  249. package/dist/twilight/{p-94e082e5.entry.js → p-1072161d.entry.js} +1 -1
  250. package/dist/twilight/{p-67636846.entry.js → p-12d180be.entry.js} +1 -1
  251. package/dist/twilight/{p-7225f304.entry.js → p-13e1c331.entry.js} +1 -1
  252. package/dist/twilight/{p-8b775260.entry.js → p-16d6ee9b.entry.js} +1 -1
  253. package/dist/twilight/{p-04d25025.entry.js → p-18005312.entry.js} +1 -1
  254. package/dist/twilight/{p-051cf8e8.entry.js → p-185a97f2.entry.js} +1 -1
  255. package/dist/twilight/{p-0d012154.entry.js → p-19c8a5d5.entry.js} +1 -1
  256. package/dist/twilight/{p-03e5d981.entry.js → p-1beb481d.entry.js} +1 -1
  257. package/dist/twilight/p-1qlEgGio.js +4 -0
  258. package/dist/twilight/{p-843c1499.entry.js → p-2c86bd20.entry.js} +1 -1
  259. package/dist/twilight/{p-2ede3e52.entry.js → p-30b7deca.entry.js} +1 -1
  260. package/dist/twilight/{p-e7ba206e.entry.js → p-3157e3dd.entry.js} +1 -1
  261. package/dist/twilight/{p-8e84cce0.entry.js → p-32467a9d.entry.js} +1 -1
  262. package/dist/twilight/{p-6a3e5797.entry.js → p-342dad15.entry.js} +1 -1
  263. package/dist/twilight/{p-902bab33.entry.js → p-34741bf4.entry.js} +1 -1
  264. package/dist/twilight/{p-a397eadf.entry.js → p-3a54d785.entry.js} +1 -1
  265. package/dist/twilight/{p-b291c768.entry.js → p-3ae98980.entry.js} +1 -1
  266. package/dist/twilight/{p-d2706f82.entry.js → p-3d005581.entry.js} +1 -1
  267. package/dist/twilight/{p-280b577d.entry.js → p-3e01a221.entry.js} +1 -1
  268. package/dist/twilight/{p-DGH40_w6.js → p-3omad4sF.js} +1 -1
  269. package/dist/twilight/{p-6f89ecd5.entry.js → p-44d95774.entry.js} +1 -1
  270. package/dist/twilight/{p-a30673d8.entry.js → p-52556f85.entry.js} +1 -1
  271. package/dist/twilight/p-56a74d0a.entry.js +4 -0
  272. package/dist/twilight/{p-55150c7f.entry.js → p-574c57c6.entry.js} +1 -1
  273. package/dist/twilight/{p-cc85cbb6.entry.js → p-57ace49d.entry.js} +1 -1
  274. package/dist/twilight/{p-8e87f47b.entry.js → p-57b87240.entry.js} +1 -1
  275. package/dist/twilight/p-5877797d.entry.js +4 -0
  276. package/dist/twilight/{p-206a4605.entry.js → p-59cf3d1c.entry.js} +1 -1
  277. package/dist/twilight/{p-420cd3bc.entry.js → p-59cf6efb.entry.js} +1 -1
  278. package/dist/twilight/{p-3996a786.entry.js → p-5acaee73.entry.js} +1 -1
  279. package/dist/twilight/{p-67a110ca.entry.js → p-6740cfb1.entry.js} +1 -1
  280. package/dist/twilight/{p-f3832e61.entry.js → p-67a304d4.entry.js} +1 -1
  281. package/dist/twilight/{p-2bd896e8.entry.js → p-6a7d7c6f.entry.js} +1 -1
  282. package/dist/twilight/{p-b7ad635b.entry.js → p-6aad9abe.entry.js} +1 -1
  283. package/dist/twilight/{p-cfc04f03.entry.js → p-6c4d7933.entry.js} +1 -1
  284. package/dist/twilight/{p-58fd42b9.entry.js → p-6e9b255e.entry.js} +1 -1
  285. package/dist/twilight/{p-246ff1db.entry.js → p-729e2abe.entry.js} +1 -1
  286. package/dist/twilight/{p-811f7253.entry.js → p-754d042b.entry.js} +1 -1
  287. package/dist/twilight/p-77676a5d.entry.js +4 -0
  288. package/dist/twilight/p-783d1a70.entry.js +4 -0
  289. package/dist/twilight/{p-cd3a98b4.entry.js → p-7971bc45.entry.js} +1 -1
  290. package/dist/twilight/{p-8ec5ca1a.entry.js → p-7bb21315.entry.js} +1 -1
  291. package/dist/twilight/{p-546c9f58.entry.js → p-7bb28f60.entry.js} +1 -1
  292. package/dist/twilight/{p-a65070ba.entry.js → p-7fae4a20.entry.js} +1 -1
  293. package/dist/twilight/{p-7fc61c4c.entry.js → p-82b38a08.entry.js} +1 -1
  294. package/dist/twilight/{p-3b962591.entry.js → p-842e61d7.entry.js} +1 -1
  295. package/dist/twilight/{p-204f6275.entry.js → p-85f9d064.entry.js} +1 -1
  296. package/dist/twilight/{p-9d00311a.entry.js → p-927448a3.entry.js} +1 -1
  297. package/dist/twilight/{p-ffe0dc1e.entry.js → p-92d68ba1.entry.js} +1 -1
  298. package/dist/twilight/{p-5b2d05b7.entry.js → p-94af7c15.entry.js} +1 -1
  299. package/dist/twilight/{p-6c9462be.entry.js → p-9a862593.entry.js} +1 -1
  300. package/dist/twilight/p-9c302701.entry.js +4 -0
  301. package/dist/twilight/{p-acd71b9c.entry.js → p-9d734c16.entry.js} +1 -1
  302. package/dist/twilight/{p-85d51539.entry.js → p-9d745f77.entry.js} +1 -1
  303. package/dist/twilight/{p-c3c0eafb.entry.js → p-9f1c78ac.entry.js} +1 -1
  304. package/dist/twilight/{p-f0ba85ef.entry.js → p-9f6081d4.entry.js} +1 -1
  305. package/dist/twilight/{p-CswSlMMW.js → p-B1S798Uj.js} +1 -1
  306. package/dist/twilight/{p-ulwdkVD6.js → p-BlJJbPc3.js} +1 -1
  307. package/dist/twilight/{p-DMPBYOzv.js → p-CAqUTN8N.js} +1 -1
  308. package/dist/twilight/{p-DxUIn207.js → p-CXp5fcIv.js} +1 -1
  309. package/dist/twilight/{p-hlvyyBTt.js → p-CwlNfhff.js} +1 -1
  310. package/dist/twilight/{p-CRL06FLf.js → p-DnsL3smj.js} +1 -1
  311. package/dist/twilight/{p-D_66TtzK.js → p-DzgGIUvs.js} +1 -1
  312. package/dist/twilight/{p-DqVd28X3.js → p-MT8XYsK6.js} +1 -1
  313. package/dist/twilight/{p-CRJyselG.js → p-RH6Ze2WQ.js} +1 -1
  314. package/dist/twilight/{p-Z-0FpgUH.js → p-YpsE7YiS.js} +2 -2
  315. package/dist/twilight/{p-dad28a17.entry.js → p-a65a1d76.entry.js} +1 -1
  316. package/dist/twilight/p-b25643cf.entry.js +4 -0
  317. package/dist/twilight/{p-be77d488.entry.js → p-bddef859.entry.js} +1 -1
  318. package/dist/twilight/{p-3c315245.entry.js → p-bdef80a3.entry.js} +1 -1
  319. package/dist/twilight/{p-f49f7906.entry.js → p-c2ab62c6.entry.js} +1 -1
  320. package/dist/twilight/{p-d132c3a1.entry.js → p-c6e28a21.entry.js} +1 -1
  321. package/dist/twilight/{p-a971eb6e.entry.js → p-c842401c.entry.js} +1 -1
  322. package/dist/twilight/{p-7bf35ca7.entry.js → p-c850756e.entry.js} +1 -1
  323. package/dist/twilight/{p-ff572f0c.entry.js → p-d00c74c3.entry.js} +1 -1
  324. package/dist/twilight/{p-19bc5aa0.entry.js → p-d20eb5fe.entry.js} +1 -1
  325. package/dist/twilight/{p-fe2dc707.entry.js → p-d30dc29a.entry.js} +1 -1
  326. package/dist/twilight/{p-befbb594.entry.js → p-d5f7fc7c.entry.js} +1 -1
  327. package/dist/twilight/{p-09d7aa92.entry.js → p-d5ffbaa7.entry.js} +1 -1
  328. package/dist/twilight/{p-835a102e.entry.js → p-d63d41cc.entry.js} +1 -1
  329. package/dist/twilight/{p-f0483d2f.entry.js → p-d71e3ca9.entry.js} +1 -1
  330. package/dist/twilight/{p-2b8d6b5c.entry.js → p-d7c3072b.entry.js} +1 -1
  331. package/dist/twilight/{p-e36a05c8.entry.js → p-d9685d52.entry.js} +1 -1
  332. package/dist/twilight/{p-9ae8d5cc.entry.js → p-dda98c7a.entry.js} +1 -1
  333. package/dist/twilight/{p-5eeda026.entry.js → p-df605d75.entry.js} +1 -1
  334. package/dist/twilight/{p-f888055e.entry.js → p-e03e1c15.entry.js} +1 -1
  335. package/dist/twilight/{p-1a299dab.entry.js → p-e260af73.entry.js} +1 -1
  336. package/dist/twilight/{p-0a1e3675.entry.js → p-e58f50ac.entry.js} +1 -1
  337. package/dist/twilight/{p-8509e67b.entry.js → p-ec7b9c48.entry.js} +1 -1
  338. package/dist/twilight/{p-38b57477.entry.js → p-ef15918c.entry.js} +1 -1
  339. package/dist/twilight/p-f06c0fe7.entry.js +4 -0
  340. package/dist/twilight/{p-e0096a71.entry.js → p-f2ba00a7.entry.js} +1 -1
  341. package/dist/twilight/{p-060cb433.entry.js → p-fb94ea64.entry.js} +1 -1
  342. package/dist/twilight/{p-d4bfca23.entry.js → p-fdc41755.entry.js} +1 -1
  343. package/dist/twilight/{p-0d3f0c5e.entry.js → p-fdd6cba3.entry.js} +1 -1
  344. package/dist/twilight/{p-0ab66850.entry.js → p-feebbd16.entry.js} +1 -1
  345. package/dist/twilight/{p-59d4fd28.entry.js → p-ff5240b5.entry.js} +1 -1
  346. package/dist/twilight/twilight.esm.js +1 -1
  347. package/dist/types/components/salla-loyalty-program/salla-loyalty-exchange-product-card.d.ts +10 -0
  348. package/dist/types/components/salla-loyalty-program/salla-loyalty-panel.d.ts +1 -0
  349. package/dist/types/components/salla-loyalty-program/salla-loyalty-program.d.ts +1 -0
  350. package/dist/types/components/salla-loyalty-program/salla-reward-details.d.ts +9 -0
  351. package/dist/types/components.d.ts +33 -0
  352. package/package.json +5 -5
  353. package/dist/twilight/p-180f51ef.entry.js +0 -4
  354. package/dist/twilight/p-55ef75cb.entry.js +0 -4
  355. package/dist/twilight/p-6d17cc72.entry.js +0 -4
  356. package/dist/twilight/p-CXgH1qPi.js +0 -4
  357. package/dist/twilight/p-a2a5a087.entry.js +0 -4
  358. package/dist/twilight/p-ad33426d.entry.js +0 -4
  359. package/dist/twilight/p-bdc874b8.entry.js +0 -4
  360. package/dist/twilight/p-d642b334.entry.js +0 -4
  361. package/dist/twilight/p-e8e5906a.entry.js +0 -4
  362. package/dist/twilight/p-ee53cba1.entry.js +0 -4
  363. package/dist/twilight/p-f9a495bf.entry.js +0 -4
@@ -1,7 +1,7 @@
1
1
  /*!
2
2
  * Crafted with ❤ by Salla
3
3
  */
4
- import { r as registerInstance, h, H as Host } from './index-DGH40_w6.js';
4
+ import { r as registerInstance, h, H as Host, a as getElement } from './index-3omad4sF.js';
5
5
 
6
6
  const sallaCountDownCss = ".s-count-down-horizontal{background-color:rgba(0, 0, 0, 0.06);background-color:color-mix(in srgb, var(--color-primary) 10%, transparent)}";
7
7
 
@@ -237,4 +237,206 @@ const SallaCountDown = class {
237
237
  };
238
238
  SallaCountDown.style = sallaCountDownCss;
239
239
 
240
- export { SallaCountDown as salla_count_down };
240
+ const sallaOrderOptionsModalCss = ".s-order-options-modal-host .s-modal-header-inner,.s-order-options-modal-host .s-modal-header-content,.s-order-options-modal-host .s-modal-title{text-align:start !important}.s-order-options-modal-apple-pay{display:block;width:100%;--apple-pay-button-width:100%;--apple-pay-button-height:44px;--apple-pay-button-border-radius:0.75rem}.s-order-options-modal-apple-pay-wrap{display:flex;flex-direction:column;gap:0.75rem;width:100%}.s-order-options-modal-apple-pay-total{display:flex;align-items:center;justify-content:space-between;gap:0.5rem}.s-order-options-modal-apple-pay-label,.s-order-options-modal-apple-pay-amount{font-size:1.125rem;line-height:1.5rem;font-weight:700;color:#111827}";
241
+
242
+ const SallaOrderOptionsModal = class {
243
+ constructor(hostRef) {
244
+ registerInstance(this, hostRef);
245
+ this.resolveFn = null;
246
+ this.rejectFn = null;
247
+ this.optionsRefs = new Map();
248
+ this.changeHandler = null;
249
+ /** Sync hook for callers that need to act under the submit user gesture (Apple Pay). */
250
+ this.submitCallback = null;
251
+ this.orderOptions = [];
252
+ this.basePrice = 0;
253
+ this.liveTotal = 0;
254
+ this.isSubmitting = false;
255
+ /** Bumped each open() so the inner <salla-product-options> remounts. */
256
+ this.sessionId = 0;
257
+ this.paymentMode = 'default';
258
+ this.title = '';
259
+ this.subtitle = '';
260
+ this.submitLabel = '';
261
+ this.totalLabel = '';
262
+ this.requiredMessage = '';
263
+ this.handleClose = () => {
264
+ if (this.isSubmitting)
265
+ return;
266
+ this.rejectFn?.({ reason: 'dismissed' });
267
+ this.resolveFn = null;
268
+ this.rejectFn = null;
269
+ this.detachChangeListener();
270
+ this.reset();
271
+ };
272
+ salla.lang.onLoaded(() => this.loadTranslations());
273
+ }
274
+ componentWillLoad() {
275
+ this.loadTranslations();
276
+ }
277
+ loadTranslations() {
278
+ this.title = salla.lang.get('blocks.order_options.title');
279
+ this.subtitle = salla.lang.get('blocks.order_options.subtitle');
280
+ this.submitLabel = salla.lang.get('blocks.order_options.continue');
281
+ this.totalLabel = salla.lang.get('blocks.order_options.total');
282
+ this.requiredMessage = salla.lang.get('blocks.order_options.required_message');
283
+ }
284
+ /**
285
+ * Open the modal. Resolves with selections on submit; rejects on dismiss.
286
+ * `onSubmit` fires sync in the submit click (for Apple Pay user-gesture).
287
+ * `paymentMode: 'apple-pay'` swaps the footer button for <apple-pay-button>.
288
+ */
289
+ async open(payload) {
290
+ // Normalize here, not in the shared salla-product-options: text/number order options ship no
291
+ // `details`, which product-options dereferences unguarded.
292
+ this.orderOptions = (Array.isArray(payload.orderOptions) ? payload.orderOptions : [])
293
+ .map((o) => ({ ...o, details: o.details ?? [] }));
294
+ this.basePrice = Number(payload.basePrice) || 0;
295
+ this.liveTotal = this.basePrice + this.seedOptionsPrice(this.orderOptions);
296
+ this.isSubmitting = false;
297
+ this.sessionId++;
298
+ this.optionsRefs.clear();
299
+ this.submitCallback = payload.onSubmit ?? null;
300
+ this.paymentMode = payload.paymentMode ?? 'default';
301
+ await this.modal?.open();
302
+ this.attachChangeListener();
303
+ return new Promise((resolve, reject) => {
304
+ this.resolveFn = resolve;
305
+ this.rejectFn = reject;
306
+ });
307
+ }
308
+ async close() {
309
+ await this.modal?.close();
310
+ }
311
+ /** Sync walk of inputs — avoids `await` through the @Method that would consume the AP user gesture. */
312
+ collectOrderOptionsSync() {
313
+ const result = [];
314
+ for (const [, el] of this.optionsRefs) {
315
+ if (!el)
316
+ continue;
317
+ const inputs = el.querySelectorAll('[name^="options["],[name*="[options]["]');
318
+ inputs.forEach((input) => {
319
+ if (input instanceof HTMLInputElement && (input.type === 'radio' || input.type === 'checkbox') && !input.checked) {
320
+ return;
321
+ }
322
+ const match = input.name.match(/(?:^|\[)options\]?\[(\d+)\]/);
323
+ if (!match)
324
+ return;
325
+ const raw = input.value;
326
+ if (raw === '' || raw === null || raw === undefined)
327
+ return;
328
+ const numeric = Number(raw);
329
+ result.push({
330
+ id: Number(match[1]),
331
+ value: Number.isFinite(numeric) && raw === String(numeric) ? numeric : raw,
332
+ });
333
+ });
334
+ }
335
+ return result;
336
+ }
337
+ /** Sync native validity — keeps the AP user gesture intact. */
338
+ validateSync() {
339
+ let pass = true;
340
+ for (const [, el] of this.optionsRefs) {
341
+ if (!el)
342
+ continue;
343
+ const requiredInputs = el.querySelectorAll('[required]');
344
+ requiredInputs.forEach((input) => {
345
+ // Mirror salla-product-options.reportValidity(): skip hidden/disabled inputs so a
346
+ // required field in a `.hidden` conditional container can't silently block submit.
347
+ if (input.disabled || input.closest('.hidden'))
348
+ return;
349
+ if ('reportValidity' in input && !input.reportValidity())
350
+ pass = false;
351
+ });
352
+ }
353
+ return pass;
354
+ }
355
+ /** Sum the additional_price of any pre-selected details. */
356
+ seedOptionsPrice(orderOptions) {
357
+ let sum = 0;
358
+ orderOptions.forEach((opt) => {
359
+ (opt.details || []).forEach((d) => {
360
+ if (d.is_selected)
361
+ sum += Number(d.additional_price) || 0;
362
+ });
363
+ });
364
+ return sum;
365
+ }
366
+ /** salla.event.on is global — attach per open, detach on close to avoid stacking. */
367
+ attachChangeListener() {
368
+ this.detachChangeListener();
369
+ this.changeHandler = () => this.recomputeTotal();
370
+ salla.event.on('product-options::change', this.changeHandler);
371
+ }
372
+ detachChangeListener() {
373
+ if (!this.changeHandler)
374
+ return;
375
+ salla.event.off('product-options::change', this.changeHandler);
376
+ this.changeHandler = null;
377
+ }
378
+ async recomputeTotal() {
379
+ let selectedPrice = 0;
380
+ for (const [, el] of this.optionsRefs) {
381
+ if (!el)
382
+ continue;
383
+ const selected = typeof el.getSelectedOptions === 'function'
384
+ ? await el.getSelectedOptions()
385
+ : [];
386
+ (selected || []).forEach((s) => {
387
+ selectedPrice += Number(s.additional_price) || 0;
388
+ });
389
+ }
390
+ this.liveTotal = this.basePrice + selectedPrice;
391
+ }
392
+ handleSubmit() {
393
+ if (this.isSubmitting)
394
+ return;
395
+ if (!this.validateSync()) {
396
+ salla.notify?.error?.(this.requiredMessage);
397
+ return;
398
+ }
399
+ this.isSubmitting = true;
400
+ const orderOptions = this.collectOrderOptionsSync();
401
+ const total = Math.round(this.liveTotal * 100) / 100;
402
+ // Fire onSubmit BEFORE any await — Apple Pay needs the user gesture.
403
+ try {
404
+ this.submitCallback?.(orderOptions, total);
405
+ }
406
+ catch (err) {
407
+ salla?.logger?.warn?.('order-options modal onSubmit threw', err);
408
+ }
409
+ this.resolveFn?.({ orderOptions });
410
+ this.resolveFn = null;
411
+ this.rejectFn = null;
412
+ this.submitCallback = null;
413
+ this.detachChangeListener();
414
+ this.modal?.close().then(() => this.reset());
415
+ this.isSubmitting = false;
416
+ }
417
+ /** Clear options on close so the inner <salla-product-options> unmounts. */
418
+ reset() {
419
+ this.orderOptions = [];
420
+ this.optionsRefs.clear();
421
+ this.liveTotal = 0;
422
+ }
423
+ render() {
424
+ // salla.money returns HTML (sicon-sar icon) → render via innerHTML. Round
425
+ // first so floating-point sum doesn't show as 1174.3799999999999.
426
+ const totalHtml = salla.money(Math.round(this.liveTotal * 100) / 100);
427
+ return (h("salla-modal", { key: 'a7b7c31da2f5fd9f5f3ee601052f84e512368cee', ref: el => (this.modal = el), class: "s-order-options-modal-host", width: "md", "modal-title": this.title, onModalVisibilityChanged: (e) => {
428
+ if (!e.detail)
429
+ this.handleClose();
430
+ } }, h("div", { key: '9a44c4dcec6f0e49a65217b1e1e2cd19ccc80c76', class: "s-order-options-modal-body" }, h("p", { key: '66c41a32e2130db4dc1aa402a31cfd6d519544b3', class: "s-order-options-modal-subtitle" }, this.subtitle), h("div", { key: 'fffe868427973b6426b8a2f8f33f48c017dfb7fb', class: "s-order-options-modal-fields" }, this.orderOptions.length > 0 && (h("salla-product-options", { key: this.sessionId, ref: el => {
431
+ if (!el)
432
+ return;
433
+ this.optionsRefs.set('order-options', el);
434
+ // Without seeding, first multi-select toggle wipes pre-selected defaults.
435
+ el.seedSelectedOptions?.();
436
+ }, "product-id": `order-options-${this.orderOptions[0]?.id}`, "unique-key": "order-options", options: JSON.stringify(this.orderOptions), "hide-out-label": "1", "no-padding": true })))), h("div", { key: '36f3a18380f05a8420d4bc32fa643bf596ac16fb', slot: "footer", class: "s-order-options-modal-footer" }, this.paymentMode === 'apple-pay' ? (h("div", { class: "s-order-options-modal-apple-pay-wrap" }, h("div", { class: "s-order-options-modal-apple-pay-total" }, h("span", { class: "s-order-options-modal-apple-pay-label" }, this.totalLabel), h("span", { class: "s-order-options-modal-apple-pay-amount", innerHTML: totalHtml })), h("apple-pay-button", { locale: salla?.config?.get?.('user.language_code') || 'ar', buttonstyle: "black", type: "buy", class: "s-order-options-modal-apple-pay", onClick: () => this.handleSubmit() }))) : (h("salla-button", { type: "button", color: "primary", fill: "solid", width: "wide", loading: this.isSubmitting, onClick: () => this.handleSubmit() }, h("span", { class: "s-order-options-modal-cta-content" }, h("span", { class: "s-order-options-modal-cta-text" }, this.submitLabel), h("span", { class: "s-order-options-modal-cta-total", innerHTML: totalHtml })))))));
437
+ }
438
+ get host() { return getElement(this); }
439
+ };
440
+ SallaOrderOptionsModal.style = sallaOrderOptionsModalCss;
441
+
442
+ export { SallaCountDown as salla_count_down, SallaOrderOptionsModal as salla_order_options_modal };
@@ -1,7 +1,7 @@
1
1
  /*!
2
2
  * Crafted with ❤ by Salla
3
3
  */
4
- import { r as registerInstance, c as createEvent, h } from './index-DGH40_w6.js';
4
+ import { r as registerInstance, c as createEvent, h } from './index-3omad4sF.js';
5
5
  import { C as CameraIcon } from './camera-C6jIkM-X.js';
6
6
  import { F as FormFieldTypes } from './interfaces-OF8QcbMM.js';
7
7
 
@@ -1,7 +1,7 @@
1
1
  /*!
2
2
  * Crafted with ❤ by Salla
3
3
  */
4
- import { r as registerInstance, h, H as Host, a as getElement } from './index-DGH40_w6.js';
4
+ import { r as registerInstance, h, H as Host, a as getElement } from './index-3omad4sF.js';
5
5
 
6
6
  const DEBUG_KEY = 'salla-delivery-promise-debug';
7
7
  function log(message, data) {
@@ -1,7 +1,7 @@
1
1
  /*!
2
2
  * Crafted with ❤ by Salla
3
3
  */
4
- import { r as registerInstance, h, H as Host } from './index-DGH40_w6.js';
4
+ import { r as registerInstance, h, H as Host } from './index-3omad4sF.js';
5
5
 
6
6
  const sallaEditOrderButtonCss = ":host{display:block}";
7
7
 
@@ -1,7 +1,7 @@
1
1
  /*!
2
2
  * Crafted with ❤ by Salla
3
3
  */
4
- import { r as registerInstance, c as createEvent, h, H as Host, a as getElement } from './index-DGH40_w6.js';
4
+ import { r as registerInstance, c as createEvent, h, H as Host, a as getElement } from './index-3omad4sF.js';
5
5
  import { H as Helper } from './Helper-BQ9mvrt9.js';
6
6
  import { F as FilterOptionTypes } from './interfaces-DL4h2bc3.js';
7
7
  import './anime.es-CgtvEd63.js';
@@ -1,7 +1,7 @@
1
1
  /*!
2
2
  * Crafted with ❤ by Salla
3
3
  */
4
- import { r as registerInstance, c as createEvent, h, H as Host, a as getElement } from './index-DGH40_w6.js';
4
+ import { r as registerInstance, c as createEvent, h, H as Host, a as getElement } from './index-3omad4sF.js';
5
5
  import { F as FilterOptionTypes } from './interfaces-DL4h2bc3.js';
6
6
  import { H as Helper } from './Helper-BQ9mvrt9.js';
7
7
  import './anime.es-CgtvEd63.js';
@@ -1,7 +1,7 @@
1
1
  /*!
2
2
  * Crafted with ❤ by Salla
3
3
  */
4
- import { r as registerInstance, h, H as Host } from './index-DGH40_w6.js';
4
+ import { r as registerInstance, h, H as Host } from './index-3omad4sF.js';
5
5
 
6
6
  const SallaFulfillmentMethods = class {
7
7
  constructor(hostRef) {
@@ -1,7 +1,7 @@
1
1
  /*!
2
2
  * Crafted with ❤ by Salla
3
3
  */
4
- import { r as registerInstance, h } from './index-DGH40_w6.js';
4
+ import { r as registerInstance, h } from './index-3omad4sF.js';
5
5
  import { a as anime } from './anime.es-CgtvEd63.js';
6
6
  import { a as arrowLeft } from './arrow-left-BedNk7k1.js';
7
7
  import { S as SICancel } from './cancel-8Tsmrwno.js';
@@ -1,7 +1,7 @@
1
1
  /*!
2
2
  * Crafted with ❤ by Salla
3
3
  */
4
- import { r as registerInstance, h, H as Host, a as getElement } from './index-DGH40_w6.js';
4
+ import { r as registerInstance, h, H as Host, a as getElement } from './index-3omad4sF.js';
5
5
 
6
6
  const SallaHook = class {
7
7
  constructor(hostRef) {
@@ -1,7 +1,7 @@
1
1
  /*!
2
2
  * Crafted with ❤ by Salla
3
3
  */
4
- import { r as registerInstance, h, H as Host, a as getElement } from './index-DGH40_w6.js';
4
+ import { r as registerInstance, h, H as Host, a as getElement } from './index-3omad4sF.js';
5
5
  import { H as Helper } from './Helper-BQ9mvrt9.js';
6
6
  import './anime.es-CgtvEd63.js';
7
7
 
@@ -1,7 +1,7 @@
1
1
  /*!
2
2
  * Crafted with ❤ by Salla
3
3
  */
4
- import { r as registerInstance, h, H as Host, a as getElement } from './index-DGH40_w6.js';
4
+ import { r as registerInstance, h, H as Host, a as getElement } from './index-3omad4sF.js';
5
5
 
6
6
  const sallaInstallmentCss = "salla-installment:empty{display:none}#tabbyPromoWrapper{background:white;border-radius:0.375rem;transition:box-shadow 0.5s cubic-bezier(0.4, 0, 0.2, 1);margin-bottom:20px;border:unset !important;font-weight:500}.salla-y #tabbyPromoWrapper{border:1px solid var(--color-grey-dark);border-radius:12px}#tabbyPromoWrapper:hover{box-shadow:0 0 rgba(0, 0, 0, 0), 0 0 rgba(0, 0, 0, 0), 5px 10px 30px rgba(43, 45, 52, 0.0509803922)}#tabbyPromoWrapper #tabbyPromo *{font-family:var(--font-main)}#tabbyPromoWrapper #tabbyPromo>div>div{max-width:none;box-shadow:none;border:none}#tabbyPromoWrapper #tabbyPromo .tabby-promo-snippet{max-width:100%;min-height:100px;padding:18px 20px;border:none !important}#tabbyPromoWrapper #tabbyPromo .tabby-promo-snippet__text,#tabbyPromoWrapper #tabbyPromo .tabby-promo-snippet__link{font-size:var(--font-sm);color:var(--color-text) !important}#tabbyPromoWrapper #tabbyPromo .tabby-promo-snippet__link{font-weight:bold}.tabby-promo-wrapper #tabby-promo{font-family:var(--font-main) !important}.tabby-promo-wrapper #tabby-promo .tabby-promo__feature-title{font-size:var(--font-md)}.tabby-promo-wrapper #tabby-promo .tabby-promo__feature-desc{font-size:var(--font-sm);line-height:20px}.tamara-product-widget{margin-bottom:20px}.tamara-product-widget,.spotii-wrapper{min-height:100px;position:relative;color:var(--main-text-color);font-size:var(--font-sm);line-height:1.25;padding:20px 20px 20px 115px !important;background:white;border-radius:0.375rem;transition:box-shadow 0.5s cubic-bezier(0.4, 0, 0.2, 1);border:unset !important;font-family:inherit !important;font-weight:500}.salla-y .tamara-product-widget,.salla-y .spotii-wrapper{border-radius:12px;border:1px solid var(--color-grey-dark)}.tamara-product-widget:hover,.spotii-wrapper:hover{box-shadow:0 0 rgba(0, 0, 0, 0), 0 0 rgba(0, 0, 0, 0), 5px 10px 30px rgba(43, 45, 52, 0.0509803922)}.tamara-product-widget .spotii-logo,.spotii-wrapper .spotii-logo{float:left;margin:0 0 0 -75px}.ltr .tamara-product-widget,.ltr .spotii-wrapper{text-align:left;padding:18px 100px 18px 20px !important}.ltr .tamara-product-widget .spotii-logo,.ltr .spotii-wrapper .spotii-logo{float:right;margin:0 -75px 0 0}.ltr .tamara-product-widget .spotii-product-widget,.ltr .spotii-wrapper .spotii-product-widget{text-align:left !important}.spotii-wrapper{margin-bottom:20px}.spotii-wrapper .spotii-promo{font-size:var(--font-md)}.spotii-wrapper .spotii-product-widget{font-size:var(--font-sm) !important;margin-top:10px}.tamara-product-widget .tamara-logo{position:absolute;left:20px !important;top:35px !important;margin:0 !important;height:24px !important}.ltr .tamara-product-widget .tamara-logo{right:20px !important;left:auto !important}.tamara-product-widget span{font-family:var(--font-main);font-size:var(--font-sm);color:var(--color-text)}.tamara-product-widget span:last-child{display:block;position:relative;margin-top:8px}.tamara-popup__wrap{overflow:auto !important}.s-installment-mispay-wrapper,.s-installment-madfu-wrapper,.s-installment-emkan-wrapper,.s-installment-rajehi-wrapper{font-size:14px;text-align:right;padding:20px;gap:42px;line-height:22px;color:rgb(0, 0, 0);min-width:100%;box-sizing:border-box;position:relative;background-color:white;border-radius:10px;margin:15px 0;display:flex;transition:box-shadow 0.5s cubic-bezier(0.4, 0, 0.2, 1)}.s-installment-mispay-wrapper:hover,.s-installment-madfu-wrapper:hover,.s-installment-emkan-wrapper:hover,.s-installment-rajehi-wrapper:hover{box-shadow:0 0 rgba(0, 0, 0, 0), 0 0 rgba(0, 0, 0, 0), 5px 10px 30px rgba(43, 45, 52, 0.0509803922)}.s-installment-mispay-content,.s-installment-madfu-content,.s-installment-emkan-content,.s-installment-rajehi-content{display:flex;flex-direction:row-reverse;width:100%;justify-content:space-between;align-items:center;gap:1rem}.s-installment-mispay-content-text,.s-installment-madfu-content-text,.s-installment-emkan-content-text,.s-installment-rajehi-content-text{color:var(--main-text-color);font-size:14px;font-weight:500;margin:0 16px 0 0;width:80%;left:14px;text-align:left}.s-installment-mispay-content img,.s-installment-madfu-content img,.s-installment-emkan-content img,.s-installment-rajehi-content img{height:28px;width:70px;display:inline-block;max-height:100%;vertical-align:middle;fill:none;stroke:unset;width:auto}.rtl .s-installment-mispay-content-text,.rtl .s-installment-madfu-content-text,.rtl .s-installment-emkan-content-text,.rtl .s-installment-rajehi-content-text{right:14px;text-align:right;margin:0 0 0 16px}.rtl .s-installment-mispay-content img,.rtl .s-installment-madfu-content img,.rtl .s-installment-emkan-content img,.rtl .s-installment-rajehi-content img{left:14px !important}.ltr .s-installment-mispay-content img,.ltr .s-installment-madfu-content img,.ltr .s-installment-emkan-content img,.ltr .s-installment-rajehi-content img{right:14px !important}.s-installment-rajehi-content img{width:70px !important;height:40px !important}.s-installment-emkan-content img{height:35px !important}.s-installment-klarna-wrapper{background:white;border-radius:0.375rem;transition:box-shadow 0.5s cubic-bezier(0.4, 0, 0.2, 1);margin-bottom:20px;padding:10px}.salla-y .s-installment-klarna-wrapper{border:1px solid var(--color-grey-dark);border-radius:12px}.s-installment-klarna-wrapper:hover{box-shadow:0 0 rgba(0, 0, 0, 0), 0 0 rgba(0, 0, 0, 0), 5px 10px 30px rgba(43, 45, 52, 0.0509803922)}";
7
7
 
@@ -1,7 +1,7 @@
1
1
  /*!
2
2
  * Crafted with ❤ by Salla
3
3
  */
4
- import { r as registerInstance, h, H as Host } from './index-DGH40_w6.js';
4
+ import { r as registerInstance, h, H as Host } from './index-3omad4sF.js';
5
5
 
6
6
  const sallaListTileCss = "";
7
7
 
@@ -1,7 +1,7 @@
1
1
  /*!
2
2
  * Crafted with ❤ by Salla
3
3
  */
4
- import { r as registerInstance, h, a as getElement } from './index-DGH40_w6.js';
4
+ import { r as registerInstance, h, a as getElement } from './index-3omad4sF.js';
5
5
 
6
6
  const SallaLocalizationModal = class {
7
7
  constructor(hostRef) {
@@ -1,7 +1,7 @@
1
1
  /*!
2
2
  * Crafted with ❤ by Salla
3
3
  */
4
- import { r as registerInstance, h, F as Fragment, a as getElement } from './index-DGH40_w6.js';
4
+ import { r as registerInstance, h, F as Fragment, a as getElement } from './index-3omad4sF.js';
5
5
 
6
6
  const sallaLoginModalCss = "iframe{-moz-transition:height 0.3s;-ms-transition:height 0.3s;-o-transition:height 0.3s;-webkit-transition:height 0.3s;transition:height 0.3s;width:100%}";
7
7
 
@@ -1,11 +1,11 @@
1
1
  /*!
2
2
  * Crafted with ❤ by Salla
3
3
  */
4
- import { r as registerInstance, h, a as getElement } from './index-DGH40_w6.js';
4
+ import { r as registerInstance, h, a as getElement } from './index-3omad4sF.js';
5
5
  import { S as SIGift } from './gift-CXRKXFgT.js';
6
- import { T as TrackedPromise } from './tracked-promise-ILCl5q9c.js';
6
+ import { T as TrackedPromise } from './tracked-promise-BPB6hr9g.js';
7
7
 
8
- const sallaLoyaltyProgramCss = "";
8
+ const sallaLoyaltyProgramCss = "@media (max-width: 639px){.s-loyalty-program-modal .s-modal-body{position:relative !important;left:unset !important;bottom:unset !important;max-height:100dvh;overflow-y:auto !important}}.s-loyalty-exchange-card salla-product-card .s-product-card-image,.s-loyalty-exchange-card custom-salla-product-card .s-product-card-image{flex:none;aspect-ratio:1;overflow:hidden}.s-loyalty-exchange-card-btn{padding:0 1.25rem 1.25rem;margin-top:0.75rem}.s-loyalty-program-reward-details-products-grid{display:flex;flex-wrap:wrap;gap:1rem;margin-top:0.75rem}.s-loyalty-program-reward-details-products-grid>*{flex:1 1 100%;min-width:0;touch-action:pan-y}@media (min-width: 640px){.s-loyalty-program-reward-details-products-grid>*{flex-basis:calc((100% - 1rem) / 2)}}@media (min-width: 768px){.s-loyalty-program-reward-details-products-grid>*{flex-basis:calc((100% - 2rem) / 3)}}.s-loyalty-program-reward-details-products-grid>*:only-child{max-width:320px;margin-inline:auto}.s-loyalty-program-reward-details-products-grid:has(>*:nth-child(3))>*{flex-grow:0}";
9
9
 
10
10
  var __decorate = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
11
11
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
@@ -1,15 +1,34 @@
1
1
  /*!
2
2
  * Crafted with ❤ by Salla
3
3
  */
4
- import { r as registerInstance, c as createEvent, h, H as Host } from './index-DGH40_w6.js';
5
- import { c as closeModals, b as brand_path, f as formattedPointsJsx } from './functions-DhhgGPcx.js';
4
+ import { r as registerInstance, c as createEvent, h, H as Host } from './index-3omad4sF.js';
5
+ import { c as closeModals, b as brand_path, f as formattedPointsJsx } from './functions-Btrtoght.js';
6
6
  import { S as SIGift } from './gift-CXRKXFgT.js';
7
7
  import { S as SITag } from './tag-cgSL_BIo.js';
8
8
  import { S as SICheck } from './check-BZp0rKEO.js';
9
9
  import { S as SICancel } from './cancel-8Tsmrwno.js';
10
- import { T as TrackedPromise } from './tracked-promise-ILCl5q9c.js';
10
+ import { T as TrackedPromise } from './tracked-promise-BPB6hr9g.js';
11
11
 
12
- const sallaLoyaltyProgramCss$3 = "";
12
+ const sallaLoyaltyProgramCss$4 = "@media (max-width: 639px){.s-loyalty-program-modal .s-modal-body{position:relative !important;left:unset !important;bottom:unset !important;max-height:100dvh;overflow-y:auto !important}}.s-loyalty-exchange-card salla-product-card .s-product-card-image,.s-loyalty-exchange-card custom-salla-product-card .s-product-card-image{flex:none;aspect-ratio:1;overflow:hidden}.s-loyalty-exchange-card-btn{padding:0 1.25rem 1.25rem;margin-top:0.75rem}.s-loyalty-program-reward-details-products-grid{display:flex;flex-wrap:wrap;gap:1rem;margin-top:0.75rem}.s-loyalty-program-reward-details-products-grid>*{flex:1 1 100%;min-width:0;touch-action:pan-y}@media (min-width: 640px){.s-loyalty-program-reward-details-products-grid>*{flex-basis:calc((100% - 1rem) / 2)}}@media (min-width: 768px){.s-loyalty-program-reward-details-products-grid>*{flex-basis:calc((100% - 2rem) / 3)}}.s-loyalty-program-reward-details-products-grid>*:only-child{max-width:320px;margin-inline:auto}.s-loyalty-program-reward-details-products-grid:has(>*:nth-child(3))>*{flex-grow:0}";
13
+
14
+ const SallaLoyaltyExchangeProductCard = class {
15
+ constructor(hostRef) {
16
+ registerInstance(this, hostRef);
17
+ this.loyaltyProductExchange = createEvent(this, "loyaltyProductExchange");
18
+ }
19
+ componentWillLoad() {
20
+ this.hasCustomCard = !!customElements.get('custom-salla-product-card');
21
+ }
22
+ render() {
23
+ const product = typeof this.product === 'string' ? JSON.parse(this.product) : this.product;
24
+ return (h("div", { key: 'a60d337ebcf226318d449a4319906a71a9ab1e92', class: "s-loyalty-exchange-card" }, this.hasCustomCard
25
+ ? h("custom-salla-product-card", { product: product, hideAddBtn: true })
26
+ : h("salla-product-card", { "hide-add-btn": true, product: product }), h("div", { key: '77a0cff2bf5fce5c017493a0769e266eeeaaa01c', class: "s-loyalty-exchange-card-btn" }, h("salla-button", { key: '941c82bb35bfd116a13292ddf5425645c3d61ad7', fill: "outline", width: "wide", onClick: () => this.loyaltyProductExchange.emit({ productId: product.id }) }, salla.lang.get('pages.loyalty_program.redeem_reward')))));
27
+ }
28
+ };
29
+ SallaLoyaltyExchangeProductCard.style = sallaLoyaltyProgramCss$4;
30
+
31
+ const sallaLoyaltyProgramCss$3 = "@media (max-width: 639px){.s-loyalty-program-modal .s-modal-body{position:relative !important;left:unset !important;bottom:unset !important;max-height:100dvh;overflow-y:auto !important}}.s-loyalty-exchange-card salla-product-card .s-product-card-image,.s-loyalty-exchange-card custom-salla-product-card .s-product-card-image{flex:none;aspect-ratio:1;overflow:hidden}.s-loyalty-exchange-card-btn{padding:0 1.25rem 1.25rem;margin-top:0.75rem}.s-loyalty-program-reward-details-products-grid{display:flex;flex-wrap:wrap;gap:1rem;margin-top:0.75rem}.s-loyalty-program-reward-details-products-grid>*{flex:1 1 100%;min-width:0;touch-action:pan-y}@media (min-width: 640px){.s-loyalty-program-reward-details-products-grid>*{flex-basis:calc((100% - 1rem) / 2)}}@media (min-width: 768px){.s-loyalty-program-reward-details-products-grid>*{flex-basis:calc((100% - 2rem) / 3)}}.s-loyalty-program-reward-details-products-grid>*:only-child{max-width:320px;margin-inline:auto}.s-loyalty-program-reward-details-products-grid:has(>*:nth-child(3))>*{flex-grow:0}";
13
32
 
14
33
  const SallaRewardAction = class {
15
34
  constructor(hostRef) {
@@ -36,10 +55,7 @@ const SallaRewardAction = class {
36
55
  if (!this.isClickable(this.prize)) {
37
56
  return null;
38
57
  }
39
- return (h("div", { class: "s-loyalty-program-rewards-modal-action" }, this.isShopNow(this.prize) ? (h("a", { href: this.prize.prize_url || salla.url.get(''), class: {
40
- 's-loyalty-program-rewards-action-base': true,
41
- 's-loyalty-program-rewards-action-on': true,
42
- } }, salla.lang.get('pages.loyalty_program.shop_now'))) : (h("button", { onClick: this.handleClick, class: {
58
+ return (h("div", { class: "s-loyalty-program-rewards-modal-action" }, this.isShopNow(this.prize) ? (h("salla-button", { fill: "outline", color: "light", class: "s-loyalty-program-rewards-action-base", onClick: () => closeModals() }, salla.lang.get('common.elements.cancel'))) : (h("button", { onClick: this.handleClick, class: {
43
59
  's-loyalty-program-rewards-action-base': true,
44
60
  's-loyalty-program-rewards-action-on': true,
45
61
  } }, salla.lang.get('pages.loyalty_program.redeem_reward')))));
@@ -47,7 +63,7 @@ const SallaRewardAction = class {
47
63
  };
48
64
  SallaRewardAction.style = sallaLoyaltyProgramCss$3;
49
65
 
50
- const sallaLoyaltyProgramCss$2 = "";
66
+ const sallaLoyaltyProgramCss$2 = "@media (max-width: 639px){.s-loyalty-program-modal .s-modal-body{position:relative !important;left:unset !important;bottom:unset !important;max-height:100dvh;overflow-y:auto !important}}.s-loyalty-exchange-card salla-product-card .s-product-card-image,.s-loyalty-exchange-card custom-salla-product-card .s-product-card-image{flex:none;aspect-ratio:1;overflow:hidden}.s-loyalty-exchange-card-btn{padding:0 1.25rem 1.25rem;margin-top:0.75rem}.s-loyalty-program-reward-details-products-grid{display:flex;flex-wrap:wrap;gap:1rem;margin-top:0.75rem}.s-loyalty-program-reward-details-products-grid>*{flex:1 1 100%;min-width:0;touch-action:pan-y}@media (min-width: 640px){.s-loyalty-program-reward-details-products-grid>*{flex-basis:calc((100% - 1rem) / 2)}}@media (min-width: 768px){.s-loyalty-program-reward-details-products-grid>*{flex-basis:calc((100% - 2rem) / 3)}}.s-loyalty-program-reward-details-products-grid>*:only-child{max-width:320px;margin-inline:auto}.s-loyalty-program-reward-details-products-grid:has(>*:nth-child(3))>*{flex-grow:0}";
51
67
 
52
68
  const SallaRewardCard = class {
53
69
  constructor(hostRef) {
@@ -56,12 +72,12 @@ const SallaRewardCard = class {
56
72
  this.actionClick = createEvent(this, "actionClick");
57
73
  }
58
74
  render() {
59
- return (h(Host, { key: 'b27c707b6ac03d037d2f019131a654bcda65dd6e', class: "s-loyalty-program-reward-host" }, h("div", { key: '9606c3ad2ea7ead1f4ab2db8e148a90d43c69902', class: "s-loyalty-program-reward-container" }, h("div", { key: 'f7b6f60847b86dbb6f2b05209ab2db8eabbbd931', onClick: (e) => this.areaClick.emit(e), role: "button" }, h("div", { key: '6cd912d2c6b5c2b12ab5b4ba431ca0c965d0518b', class: "s-loyalty-program-reward-img" }, h("img", { key: 'b4f844fe1064b8ca6f5666765d92a7924fe2ad74', alt: "", src: this.prize.image || salla.url.cdn('images/s-empty.png'), class: "s-loyalty-program-rewards-img" })), h("div", { key: 'fd61d1ff64f2097fe2f696dacbb57f6c84db5339', class: "s-loyalty-program-reward-content" }, h("div", { key: 'fa1d404d5b02fe0027cef018f2eeb6e0bd109c2c', class: "s-loyalty-program-reward-points" }, h("salla-badge", { key: '29dad65f9b1f41a1698da49d113a0f9b0086210e', size: "xs" }, h("span", { key: '99526fabe82feef8ef777bfbcde868399c44e2db', innerHTML: SIGift }), h("span", { key: '94a3ed106aad1b14438227d8914695b1a18e8f64', class: "s-loyalty-program-rewards-points", innerHTML: salla.lang.choice('pages.loyalty_program.points', this.prize.cost_points) }))), h("div", { key: '1e8e12541bfd7acd303f89008f2e48c9f183c83a', class: "s-loyalty-program-reward-title" }, h("span", { key: '746377627b01443a712a52f1016c29b41eaa1ad5' }, this.prize.group_title)), h("div", { key: '1f09736c18b0be21b67e1713a44f94722bbdb09d', class: "s-loyalty-program-reward-name" }, h("div", { key: '18c26f3fe19b4e6ff28bda4d18cdb253f795792b', class: "s-loyalty-program-rewards-name", id: `prize-${this.prize.id}` }, this.prize.name, this.prize.description ? `: ${this.prize.description}` : '')))), h("div", { key: '7a814db57ae3bfad6aaba12cdab17b0e900e9080', class: "p-4" }, h("slot", { key: '0ce627f221262d54f4cda4d1a50cb2d1a6197d06', name: "action" }, h("button", { key: '10f0e39d0ecc79d84674efb0a7389430da979160', onClick: (e) => this.actionClick.emit(e.detail), class: "s-loyalty-program-rewards-action-base s-loyalty-program-rewards-action-on" }, salla.lang.get('pages.loyalty_program.show_reward')))))));
75
+ return (h(Host, { key: '9b1eecb431ab26fc6bfbd89d511294a230dd2aa9', class: "s-loyalty-program-reward-host" }, h("div", { key: '0793104978291566c136eb0e5b841224f97f25b6', class: "s-loyalty-program-reward-container" }, h("div", { key: 'f4572e5480d51f041af3e3b95bdfcc3a952c395e', onClick: (e) => this.areaClick.emit(e), role: "button" }, h("div", { key: 'ba3e6d1583219bfba80903d8b45a02c6f862efd2', class: "s-loyalty-program-reward-img" }, h("img", { key: '36e26b8fcf8d2f094b0ab990ad96c3722e23d4fd', alt: "", src: this.prize.image || salla.url.cdn('images/s-empty.png'), class: "s-loyalty-program-rewards-img" })), h("div", { key: 'b7f042b124044e8ca7eee15341d08ef175013b18', class: "s-loyalty-program-reward-content" }, h("div", { key: 'd3274d9bf3f53dfdc87e4f11cddd2abae5288333', class: "s-loyalty-program-reward-points" }, h("salla-badge", { key: '4db76994541536d16e11a7e34bce9e06ce9aff4b', size: "xs" }, h("span", { key: 'a565b786c683bc5b076036c81494137ccaef0c18', innerHTML: SIGift }), h("span", { key: '481a4016c7ccea49a860df2a7b3a322302a2e5ad', class: "s-loyalty-program-rewards-points", innerHTML: salla.lang.choice('pages.loyalty_program.points', this.prize.cost_points) }))), h("div", { key: '5820431c80d0eee99da2592ef29685710b73a048', class: "s-loyalty-program-reward-title" }, h("span", { key: '82b99ec1244890b19930686c228ca56ecee7191b' }, this.prize.group_title)), h("div", { key: '08bc6a5f88365c23e07a20b858b4cda5430eb363', class: "s-loyalty-program-reward-name" }, h("div", { key: 'dd4ce5ed0097a746b91c74cdab38ca557c55194d', class: "s-loyalty-program-rewards-name", id: `prize-${this.prize.id}` }, this.prize.name, this.prize.description ? `: ${this.prize.description}` : '')))), h("div", { key: 'ae7cd30ae6794f0957db6cfca3a69403b5996183', class: "p-4" }, h("slot", { key: '41a4cce4cb28d91d038754f69ea42b25fda6427a', name: "action" }, h("button", { key: '353da11c1197ed3dafd85282cd3343c21f55c80b', onClick: (e) => this.actionClick.emit(e.detail), class: "s-loyalty-program-rewards-action-base s-loyalty-program-rewards-action-on" }, salla.lang.get('pages.loyalty_program.show_reward')))))));
60
76
  }
61
77
  };
62
78
  SallaRewardCard.style = sallaLoyaltyProgramCss$2;
63
79
 
64
- const sallaLoyaltyProgramCss$1 = "";
80
+ const sallaLoyaltyProgramCss$1 = "@media (max-width: 639px){.s-loyalty-program-modal .s-modal-body{position:relative !important;left:unset !important;bottom:unset !important;max-height:100dvh;overflow-y:auto !important}}.s-loyalty-exchange-card salla-product-card .s-product-card-image,.s-loyalty-exchange-card custom-salla-product-card .s-product-card-image{flex:none;aspect-ratio:1;overflow:hidden}.s-loyalty-exchange-card-btn{padding:0 1.25rem 1.25rem;margin-top:0.75rem}.s-loyalty-program-reward-details-products-grid{display:flex;flex-wrap:wrap;gap:1rem;margin-top:0.75rem}.s-loyalty-program-reward-details-products-grid>*{flex:1 1 100%;min-width:0;touch-action:pan-y}@media (min-width: 640px){.s-loyalty-program-reward-details-products-grid>*{flex-basis:calc((100% - 1rem) / 2)}}@media (min-width: 768px){.s-loyalty-program-reward-details-products-grid>*{flex-basis:calc((100% - 2rem) / 3)}}.s-loyalty-program-reward-details-products-grid>*:only-child{max-width:320px;margin-inline:auto}.s-loyalty-program-reward-details-products-grid:has(>*:nth-child(3))>*{flex-grow:0}";
65
81
 
66
82
  var __decorate$1 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
67
83
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
@@ -78,10 +94,16 @@ const SallaRewardDetails = class {
78
94
  constructor(hostRef) {
79
95
  registerInstance(this, hostRef);
80
96
  this.actionClick = createEvent(this, "actionClick");
97
+ this.productActionClick = createEvent(this, "productActionClick");
81
98
  this.refreshKey = Date.now();
99
+ this.includedProductsData = [];
100
+ }
101
+ handleProductExchange(e) {
102
+ this.productActionClick.emit({ productId: e.detail.productId });
82
103
  }
83
104
  handlePrizeChange() {
84
105
  this.refreshKey = Date.now();
106
+ this.fetchIncludedProducts();
85
107
  }
86
108
  componentWillLoad() {
87
109
  if (this.category.status === 'idle') {
@@ -90,6 +112,23 @@ const SallaRewardDetails = class {
90
112
  if (this.brand.status === 'idle') {
91
113
  this.brand();
92
114
  }
115
+ this.fetchIncludedProducts();
116
+ }
117
+ async fetchIncludedProducts() {
118
+ this.includedProductsData = [];
119
+ const ids = this.prize?.included_product_ids;
120
+ if (!ids?.length)
121
+ return;
122
+ const requestedPrize = this.prize;
123
+ try {
124
+ const response = await salla.api.withoutNotifier(() => salla.product.api.fetch({ source: 'selected', source_value: ids }));
125
+ if (this.prize === requestedPrize) {
126
+ this.includedProductsData = response.data || [];
127
+ }
128
+ }
129
+ catch {
130
+ this.includedProductsData = [];
131
+ }
93
132
  }
94
133
  getTermsAndConditions() {
95
134
  const minimumAmount = Number((this.prize.order_minimum_amount || '0').split('.')[0]) || 0;
@@ -168,23 +207,29 @@ const SallaRewardDetails = class {
168
207
  getProductsJsx(items, title) {
169
208
  return !items?.length ? '' : h("div", { class: "s-loyalty-program-reward-details-items-products s-loyalty-program-slider-arrows-edges" }, h("h2", null, title), h("salla-products-slider", { source: "selected", sourceValue: JSON.stringify(items), "slider-config": '{"loop":false,"slidesPerView":"auto","freeMode":true,"spaceBetween":0,"breakpoints":{"768":{"slidesPerView":3,"freeMode":false,"speed":300}}}' }));
170
209
  }
210
+ getIncludedProductsJsx(title) {
211
+ const products = this.includedProductsData;
212
+ if (!products?.length)
213
+ return '';
214
+ return (h("div", { class: c('reward-details-items-products') }, h("h2", null, title), h("div", { class: c('reward-details-products-grid') }, products.map(product => h("salla-loyalty-exchange-product-card", { product: product })))));
215
+ }
171
216
  render() {
172
217
  const termsAndConditions = this.getTermsAndConditions();
173
- return (h("div", { key: 'b448be9380e1b0226e0e1bf4f2383190769de152', class: "s-loyalty-program-reward-modal" }, h("div", { key: '16087a27ea5cef2738f07745ac2b830ea07ab4ce', class: "s-loyalty-program-points-modal-header" }, h("h1", { key: 'f03dde8a72339ce561298cf27b524f9a69a1fd3c', class: "s-loyalty-program-points-modal-info" }, !salla.url.is_page('cart') ? ''
218
+ return (h("div", { key: 'e75387a83bdf558f087bfda4f8c7db15bf97ac5d', class: "s-loyalty-program-reward-modal" }, h("div", { key: '89caf02d9b28996177b5bc23a711986ad9da9208', class: "s-loyalty-program-points-modal-header" }, h("h1", { key: '455d0a2e6f5c08dbbdf063c1f243e7e041deb788', class: "s-loyalty-program-points-modal-info" }, !salla.url.is_page('cart') ? ''
174
219
  : h("button", { class: "s-loyalty-program-back-btn", onClick: () => closeModals(() => salla.event.dispatch('modal::open', 'loyalty-rewards-modal')) }, h("span", { class: {
175
220
  'sicon-arrow-right': document.documentElement.getAttribute('dir') === 'rtl',
176
221
  'sicon-arrow-left': document.documentElement.getAttribute('dir') === 'ltr',
177
- } })), this.prize.name)), h("div", { key: '94e4c042eda800d4127e98af05399aefd8cf162c', class: "s-loyalty-program-modal-scrollable-content" }, h("div", { key: '5e847cbfd2aefe88baaddd991ac9a3c9d5be4318', class: "s-loyalty-program-reward-details-header" }, h("div", { key: '67fa2b255a10ada08cd780f204d8bc958b2562df', class: "s-loyalty-program-aspect-container" }, h("img", { key: '06298fbe666f161ace6f8bd70ead43ff4647f912', src: this.prize.image, alt: this.prize.name })), h("salla-badge", { key: '2d5fb82811dfced1eb558baa01ddb83bf8271312', size: "sm", bg: "light" }, h("span", { key: 'bb9d7cf72ea6bc88eaed97e62465c85b3628de0d', innerHTML: SIGift }), h("span", { key: '87bd5622040b555ab70de43ffb7a6fa06cb4b45a', class: "s-loyalty-program-points-badge-points" }, formattedPointsJsx(this.prize.cost_points)))), !termsAndConditions.length ? '' : h("div", { class: "s-loyalty-program-terms-and-conditions" }, h("h1", { class: "s-loyalty-program-terms-and-conditions-heading" }, salla.lang.get('pages.loyalty_program.terms_and_conditions')), h("ul", { class: "s-loyalty-program-terms-and-conditions-list" }, termsAndConditions.map(([title, points]) => (h("li", { class: "s-loyalty-program-terms-and-conditions-item" }, h("span", { class: "s-loyalty-program-terms-and-conditions-content" }, title), h("span", { class: "s-loyalty-program-terms-and-conditions-content" }, points)))))), h("div", { key: '8b9ae2745e2134b41c8bc1c9bce8bc449774fd48', class: "s-loyalty-program-reward-info-message" }, h("h1", { key: 'd5e6f1f591a09144d9d15bf32457ca22f8438b82', class: "s-loyalty-program-reward-info-message-heading" }, salla.lang.get('pages.loyalty_program.how_to_benefit_from_this_reward')), h("p", { key: '00c63a4b0dafecd45141b2627f3cf00df9b77e83', class: "s-loyalty-program-reward-info-message-content" }, this.getItemsMarkersText())), (this.prize.key === 'FREE_SHIPPING' || this.getItemsMarkers('both') === '000000') ? '' : h("div", { class: "s-loyalty-program-reward-details" }, h("salla-tabs", { key: this.refreshKey }, this.getItemsMarkers('included') === '000' ? '' : [
222
+ } })), this.prize.name)), h("div", { key: '1e65d03e52071802ec396cc4838bdaf135303494', class: "s-loyalty-program-modal-scrollable-content" }, h("div", { key: 'f6869249b21464296725644acd9a593fb6c5ea30', class: "s-loyalty-program-reward-details-header" }, h("div", { key: 'c93dfe4c362421f7f7d5938a86d043e6ee0f2369', class: "s-loyalty-program-aspect-container" }, h("img", { key: '0c86bde982fd627939e47b9cf1eed02285a041f1', src: this.prize.image, alt: this.prize.name })), h("salla-badge", { key: '2be3695ee888ef65e0fec106e4b7845abc25491b', size: "sm", bg: "light" }, h("span", { key: '193ce34305780ecc2fd78d4e2d8572da06a0ebda', innerHTML: SIGift }), h("span", { key: 'aee708c7b484afa29392fe25768ae48051c8b211', class: "s-loyalty-program-points-badge-points" }, formattedPointsJsx(this.prize.cost_points)))), !termsAndConditions.length ? '' : h("div", { class: "s-loyalty-program-terms-and-conditions" }, h("h1", { class: "s-loyalty-program-terms-and-conditions-heading" }, salla.lang.get('pages.loyalty_program.terms_and_conditions')), h("ul", { class: "s-loyalty-program-terms-and-conditions-list" }, termsAndConditions.map(([title, points]) => (h("li", { class: "s-loyalty-program-terms-and-conditions-item" }, h("span", { class: "s-loyalty-program-terms-and-conditions-content" }, title), h("span", { class: "s-loyalty-program-terms-and-conditions-content" }, points)))))), h("div", { key: 'add5d8a427511f9554f5d13a88bc5a4994021477', class: "s-loyalty-program-reward-info-message" }, h("h1", { key: '723dd37428176057e6d9e315e2a29528df9b8b1f', class: "s-loyalty-program-reward-info-message-heading" }, salla.lang.get('pages.loyalty_program.how_to_benefit_from_this_reward')), h("p", { key: 'ef1d7ea6af657ff4810c257d378aac35c106de66', class: "s-loyalty-program-reward-info-message-content" }, this.getItemsMarkersText())), (this.prize.key === 'FREE_SHIPPING' || this.getItemsMarkers('both') === '000000') ? '' : h("div", { class: "s-loyalty-program-reward-details" }, h("salla-tabs", { key: this.refreshKey }, this.getItemsMarkers('included') === '000' ? '' : [
178
223
  h("salla-tab-header", { slot: "header", name: "included", style: {
179
224
  display: this.getItemsMarkers('excluded') === '000' ? 'none' : 'block',
180
225
  } }, h("span", { class: "s-loyalty-program-reward-details-tab-icon", innerHTML: SICheck }), h("span", null, salla.lang.get(`pages.loyalty_program.included`))),
181
- h("salla-tab-content", { slot: "content", name: "included" }, h("div", { class: "s-loyalty-program-reward-details-items-wrapper" }, this.getCategoriesJsx(this.getIncludedItems(this.prize.categories, this.prize.included_category_ids), salla.lang.get('pages.loyalty_program.included_categories')), this.getBrandsJsx(this.getIncludedItems(this.prize.brands, this.prize.included_brand_ids), salla.lang.get('pages.loyalty_program.included_brands')), this.getProductsJsx(this.getProductIds(this.prize.included_product_ids), salla.lang.get('pages.loyalty_program.included_products')))),
226
+ h("salla-tab-content", { slot: "content", name: "included" }, h("div", { class: "s-loyalty-program-reward-details-items-wrapper" }, this.getCategoriesJsx(this.getIncludedItems(this.prize.categories, this.prize.included_category_ids), salla.lang.get('pages.loyalty_program.included_categories')), this.getBrandsJsx(this.getIncludedItems(this.prize.brands, this.prize.included_brand_ids), salla.lang.get('pages.loyalty_program.included_brands')), this.getIncludedProductsJsx(salla.lang.get('pages.loyalty_program.included_products')))),
182
227
  ], this.getItemsMarkers('excluded') === '000' ? '' : [
183
228
  h("salla-tab-header", { slot: "header", name: "excluded", style: {
184
229
  display: this.getItemsMarkers('included') === '000' ? 'none' : 'block',
185
230
  } }, h("span", { class: "s-loyalty-program-reward-details-tab-icon", innerHTML: SICancel }), h("span", null, salla.lang.get(`pages.loyalty_program.excluded`))),
186
231
  h("salla-tab-content", { slot: "content", name: "excluded" }, h("div", { class: "s-loyalty-program-reward-details-items-wrapper" }, this.getCategoriesJsx(this.getIncludedItems(this.prize.excludedCategories, this.prize.excluded_category_ids), salla.lang.get('pages.loyalty_program.excluded_categories')), this.getBrandsJsx(this.getIncludedItems(this.prize.excludedBrands, this.prize.excluded_brand_ids), salla.lang.get('pages.loyalty_program.excluded_brands')), this.getProductsJsx(this.getProductIds(this.prize.excluded_product_ids), salla.lang.get('pages.loyalty_program.excluded_products')))),
187
- ]))), h("salla-reward-action", { key: 'd4ccecb2463fd6c06957f40e7865b1d12158b4bd', onActionClick: e => this.actionClick.emit(e.detail), prize: this.prize })));
232
+ ]))), h("salla-reward-action", { key: 'd1a0304c5229958d4a135affae27bb62c7419cd8', onActionClick: e => this.actionClick.emit(e.detail), prize: this.prize })));
188
233
  }
189
234
  static get watchers() { return {
190
235
  "prize": ["handlePrizeChange"]
@@ -202,7 +247,7 @@ __decorate$1([
202
247
  ], SallaRewardDetails.prototype, "brand", void 0);
203
248
  SallaRewardDetails.style = sallaLoyaltyProgramCss$1;
204
249
 
205
- const sallaLoyaltyProgramCss = "";
250
+ const sallaLoyaltyProgramCss = "@media (max-width: 639px){.s-loyalty-program-modal .s-modal-body{position:relative !important;left:unset !important;bottom:unset !important;max-height:100dvh;overflow-y:auto !important}}.s-loyalty-exchange-card salla-product-card .s-product-card-image,.s-loyalty-exchange-card custom-salla-product-card .s-product-card-image{flex:none;aspect-ratio:1;overflow:hidden}.s-loyalty-exchange-card-btn{padding:0 1.25rem 1.25rem;margin-top:0.75rem}.s-loyalty-program-reward-details-products-grid{display:flex;flex-wrap:wrap;gap:1rem;margin-top:0.75rem}.s-loyalty-program-reward-details-products-grid>*{flex:1 1 100%;min-width:0;touch-action:pan-y}@media (min-width: 640px){.s-loyalty-program-reward-details-products-grid>*{flex-basis:calc((100% - 1rem) / 2)}}@media (min-width: 768px){.s-loyalty-program-reward-details-products-grid>*{flex-basis:calc((100% - 2rem) / 3)}}.s-loyalty-program-reward-details-products-grid>*:only-child{max-width:320px;margin-inline:auto}.s-loyalty-program-reward-details-products-grid:has(>*:nth-child(3))>*{flex-grow:0}";
206
251
 
207
252
  var __decorate = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
208
253
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
@@ -243,11 +288,7 @@ const SallaRewardExchange = class {
243
288
  this.reset(0);
244
289
  }
245
290
  render() {
246
- return (h(Host, { key: 'b1e4fe9368655f389e403b2676191b46f71d49b7' }, h("div", { key: '19b8bbffa591f22608d56e8e932d7f013f6cd868', class: "s-loyalty-program-exchange-heading" }, h("div", { key: '290214db26895ba481de364299afd115b3a501cc', class: "s-loyalty-program-circle-base s-loyalty-program-circle-size-xl s-loyalty-program-circle-variant-fill" }, h("span", { key: 'd59c1b1f7683db554856950b6ec919bb48c402dd', innerHTML: SIGift })), h("h2", { key: '51a4abff2e593279cc5c9ce9dd47f7ed05533325' }, salla.lang.get('pages.loyalty_program.redeem_reward')), h("p", { key: '8a16577bce81552878cdcae4e60ce8e8719b3ed0' }, salla.lang.get('pages.loyalty_program.redeem_confirmation'), " ", h("span", { key: 'c05bdc04cbac8dc530c49bb49eca6119d2653b63' }, "(", this.prize.cost_points, " ", salla.lang.get('pages.loyalty_program.point'), ")"), " ", salla.lang.get('pages.loyalty_program.for'), " ", h("span", { key: 'ce3e88fde9f2434cabf75f7a3f622da539b5d310' }, "(", this.prize.name, ")"))), h("div", { key: 'ac51de5c34119eb79c1a8c2d06c201e4da3d7a0d', class: "s-loyalty-program-exchange-btns" }, h("button", { key: '9386b4a3d43a05fe9141561c7421b2b23ddb5a1e', class: "s-loyalty-program-rewards-action-base s-loyalty-program-rewards-action-confirm", onClick: () => this.handleConfirm() }, h("span", { key: '88d7658b7715932ff8200f79de5dd8864b00db15', style: {
247
- opacity: this.exchange.status !== 'pending' ? '1' : '0',
248
- } }, salla.lang.get('common.elements.confirm')), h("span", { key: '80c30140959693b3d98dc2162e45d4089e81eb6b', class: "s-loyalty-program-exchange-loading", style: {
249
- opacity: this.exchange.status === 'pending' ? '1' : '0',
250
- } }, h("salla-loading", { key: '516e36b4271d8da0ad711732aa991a45633edea5', color: "primary", size: 24 }))), h("button", { key: '4642c008c656a662bd277829ef80db37cffa0b1a', class: "s-loyalty-program-rewards-action-base s-loyalty-program-rewards-action-cancel", onClick: () => this.handleCancel() }, salla.lang.get('common.elements.cancel')))));
291
+ return (h(Host, { key: '12288db4227af2c833b80a0a4b4df9192c56a9f4' }, h("div", { key: '0bb5b3037fb091e9f4b96e709ad6df3f97b7d7af', class: "s-loyalty-program-exchange-heading" }, h("div", { key: '5161c1961bd08e626e33780cf01efe5000d8e939', class: "s-loyalty-program-circle-base s-loyalty-program-circle-size-xl s-loyalty-program-circle-variant-fill" }, h("span", { key: '83429d754f37b2112ba2201b54a51349a98947df', innerHTML: SIGift })), h("h2", { key: '0437972cf3b853271042de844cb70bc49dd04abf' }, salla.lang.get('pages.loyalty_program.redeem_reward')), h("p", { key: '14c0dbd4b29d73082ee71703c0a794447f9ee40e' }, salla.lang.get('pages.loyalty_program.redeem_confirmation'), " ", h("span", { key: '9128f2c88f20536ca5ddae84b2160024bb8b2fe9' }, "(", this.prize.cost_points, " ", salla.lang.get('pages.loyalty_program.point'), ")"), " ", salla.lang.get('pages.loyalty_program.for'), " ", h("span", { key: 'e323f1dbb02caf7e385ac68d3cb74b84a5e062da' }, "(", this.prize.name, ")"))), h("div", { key: 'e5895bd3e62bacf86077fe85932e85f4a313e9f6', class: "s-loyalty-program-exchange-btns" }, h("salla-button", { key: 'df88cc68a2a265fc5a0e9a84be7159d028cc22a9', width: "wide", loading: this.exchange.status === 'pending', onClick: () => this.handleConfirm() }, salla.lang.get('common.elements.confirm')), h("salla-button", { key: 'a99305e2bcde52b63da0b1102f3bd626d256ebbf', width: "wide", fill: "outline", color: "danger", onClick: () => this.handleCancel() }, salla.lang.get('common.elements.cancel')))));
251
292
  }
252
293
  };
253
294
  __decorate([
@@ -255,4 +296,4 @@ __decorate([
255
296
  ], SallaRewardExchange.prototype, "exchange", void 0);
256
297
  SallaRewardExchange.style = sallaLoyaltyProgramCss;
257
298
 
258
- export { SallaRewardAction as salla_reward_action, SallaRewardCard as salla_reward_card, SallaRewardDetails as salla_reward_details, SallaRewardExchange as salla_reward_exchange };
299
+ export { SallaLoyaltyExchangeProductCard as salla_loyalty_exchange_product_card, SallaRewardAction as salla_reward_action, SallaRewardCard as salla_reward_card, SallaRewardDetails as salla_reward_details, SallaRewardExchange as salla_reward_exchange };