@salla.sa/twilight-components 2.14.493 → 2.14.495

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 (369) hide show
  1. package/dist/cjs/{filepond-DqhwRQm7.js → filepond-DXx41R2y.js} +1 -1
  2. package/dist/cjs/{filepond-plugin-file-poster-D19muTiF.js → filepond-plugin-file-poster-CwwiKG-i.js} +1 -1
  3. package/dist/cjs/{filepond-plugin-file-validate-size-DbAdnWu5.js → filepond-plugin-file-validate-size-CeCrtqy9.js} +1 -1
  4. package/dist/cjs/{filepond-plugin-file-validate-type-avp8hUs1.js → filepond-plugin-file-validate-type-Ch0TrXhi.js} +1 -1
  5. package/dist/cjs/{filepond-plugin-image-edit-Y4pS7CAo.js → filepond-plugin-image-edit-JX_9deVo.js} +1 -1
  6. package/dist/cjs/{filepond-plugin-image-exif-orientation-C5ctyI6s.js → filepond-plugin-image-exif-orientation-DTCbWfw1.js} +1 -1
  7. package/dist/cjs/{filepond-plugin-image-preview-C9Cy8UAv.js → filepond-plugin-image-preview-DC9e7eeA.js} +1 -1
  8. package/dist/cjs/{functions-D4bL1wnj.js → functions-BNQzf0OA.js} +1 -1
  9. package/dist/cjs/{index-C_qxP6pD.js → index-D5rto5Fh.js} +14 -14
  10. package/dist/cjs/{index-CyG4y8gY.js → index-qIYSQcOD.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 +34 -4
  87. package/dist/cjs/salla-rating-modal.cjs.entry.js +34 -9
  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-BIhk39hN.js} +1 -1
  106. package/dist/cjs/twilight.cjs.js +2 -2
  107. package/dist/cjs/{vanilla-picker-BofbsHQq.js → vanilla-picker-DjtnMq2y.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/collection/components/salla-rating-modal/salla-rating-modal-v2.js +34 -3
  121. package/dist/collection/components/salla-rating-modal/salla-rating-modal.css +32 -0
  122. package/dist/collection/components/salla-rating-modal/salla-rating-modal.js +33 -7
  123. package/dist/components/index.js +2 -2
  124. package/dist/components/salla-loyalty-banner.js +8 -2
  125. package/dist/components/salla-loyalty-exchange-product-card.d.ts +11 -0
  126. package/dist/components/salla-loyalty-exchange-product-card.js +9 -0
  127. package/dist/components/salla-loyalty-exchange-product-card2.js +151 -0
  128. package/dist/components/salla-loyalty-hero2.js +4 -4
  129. package/dist/components/salla-loyalty-panel.js +33 -25
  130. package/dist/components/salla-loyalty-point2.js +5 -5
  131. package/dist/components/salla-loyalty-program.js +30 -22
  132. package/dist/components/salla-loyalty-reward.js +3 -3
  133. package/dist/components/salla-rating-modal-v22.js +34 -3
  134. package/dist/components/salla-rating-modal.js +34 -8
  135. package/dist/components/salla-reward-action2.js +9 -6
  136. package/dist/components/salla-reward-card2.js +2 -2
  137. package/dist/components/salla-reward-details2.js +63 -27
  138. package/dist/components/salla-reward-exchange2.js +5 -9
  139. package/dist/esm/{filepond-Coz90MV8.js → filepond-C3XP8jm1.js} +1 -1
  140. package/dist/esm/{filepond-plugin-file-poster-CiMXS6O6.js → filepond-plugin-file-poster-CDER34Vh.js} +1 -1
  141. package/dist/esm/{filepond-plugin-file-validate-size-DycwNhLB.js → filepond-plugin-file-validate-size-B8vg8-uq.js} +1 -1
  142. package/dist/esm/{filepond-plugin-file-validate-type-BTWmt4Mh.js → filepond-plugin-file-validate-type-CQtYu4Am.js} +1 -1
  143. package/dist/esm/{filepond-plugin-image-edit-DY5Ti-2K.js → filepond-plugin-image-edit-Dde4YKRv.js} +1 -1
  144. package/dist/esm/{filepond-plugin-image-exif-orientation-BxxwFT1Z.js → filepond-plugin-image-exif-orientation-CUBiG0lK.js} +1 -1
  145. package/dist/esm/{filepond-plugin-image-preview-CjBmoCCR.js → filepond-plugin-image-preview-B1GpYhTn.js} +1 -1
  146. package/dist/esm/{functions-DhhgGPcx.js → functions-B2dJX7jB.js} +1 -1
  147. package/dist/esm/{index-DGH40_w6.js → index-BPOLfGlq.js} +14 -14
  148. package/dist/esm/{index-9AaLpeq_.js → index-Ya4_ataG.js} +1 -1
  149. package/dist/esm/loader.js +3 -3
  150. package/dist/esm/salla-accordion-body_2.entry.js +1 -1
  151. package/dist/esm/salla-accordion_6.entry.js +1 -1
  152. package/dist/esm/salla-add-product-button_5.entry.js +1 -1
  153. package/dist/esm/salla-advertisement.entry.js +1 -1
  154. package/dist/esm/salla-alert_2.entry.js +1 -1
  155. package/dist/esm/salla-app-install-alert.entry.js +1 -1
  156. package/dist/esm/salla-apps-icons.entry.js +1 -1
  157. package/dist/esm/salla-badge.entry.js +1 -1
  158. package/dist/esm/salla-booking-field_7.entry.js +10 -10
  159. package/dist/esm/salla-bullet-delivery_2.entry.js +1 -1
  160. package/dist/esm/salla-cart-coupons.entry.js +1 -1
  161. package/dist/esm/salla-cart-item-offers_2.entry.js +1 -1
  162. package/dist/esm/salla-cart-summary-card.entry.js +1 -1
  163. package/dist/esm/salla-cashback-banner.entry.js +1 -1
  164. package/dist/esm/salla-comment-factors.entry.js +1 -1
  165. package/dist/esm/salla-comment-form_8.entry.js +1 -1
  166. package/dist/esm/salla-conditional-offer.entry.js +1 -1
  167. package/dist/esm/salla-contacts.entry.js +1 -1
  168. package/dist/esm/salla-cookies-bar.entry.js +1 -1
  169. package/dist/esm/{salla-count-down.entry.js → salla-count-down_2.entry.js} +204 -2
  170. package/dist/esm/salla-custom-fields.entry.js +1 -1
  171. package/dist/esm/salla-delivery-promise.entry.js +1 -1
  172. package/dist/esm/salla-edit-order-button.entry.js +1 -1
  173. package/dist/esm/salla-filters-widget.entry.js +1 -1
  174. package/dist/esm/salla-filters.entry.js +1 -1
  175. package/dist/esm/salla-fulfillment-methods.entry.js +1 -1
  176. package/dist/esm/salla-gifting.entry.js +1 -1
  177. package/dist/esm/salla-hook.entry.js +1 -1
  178. package/dist/esm/salla-infinite-scroll.entry.js +1 -1
  179. package/dist/esm/salla-installment.entry.js +1 -1
  180. package/dist/esm/salla-list-tile.entry.js +1 -1
  181. package/dist/esm/salla-localization-modal.entry.js +1 -1
  182. package/dist/esm/salla-login-modal.entry.js +1 -1
  183. package/dist/esm/salla-loyalty-banner.entry.js +3 -3
  184. package/dist/esm/{salla-reward-action_4.entry.js → salla-loyalty-exchange-product-card_5.entry.js} +63 -22
  185. package/dist/esm/salla-loyalty-hero_2.entry.js +11 -11
  186. package/dist/esm/salla-loyalty-panel.entry.js +6 -5
  187. package/dist/esm/salla-loyalty-points-banner.entry.js +1 -1
  188. package/dist/esm/salla-loyalty-points-history.entry.js +1 -1
  189. package/dist/esm/salla-loyalty-prize-item.entry.js +1 -1
  190. package/dist/esm/salla-loyalty-program.entry.js +6 -5
  191. package/dist/esm/salla-loyalty-reward.entry.js +5 -5
  192. package/dist/esm/salla-loyalty.entry.js +1 -1
  193. package/dist/esm/salla-maintenance-alert.entry.js +1 -1
  194. package/dist/esm/salla-map_2.entry.js +1 -1
  195. package/dist/esm/salla-menu.entry.js +1 -1
  196. package/dist/esm/salla-metadata.entry.js +1 -1
  197. package/dist/esm/salla-multiple-bundle-product-cart_2.entry.js +1 -1
  198. package/dist/esm/salla-multiple-bundle-product-options-modal_2.entry.js +1 -1
  199. package/dist/esm/salla-multiple-bundle-product.entry.js +1 -1
  200. package/dist/esm/salla-next-order-coupon.entry.js +1 -1
  201. package/dist/esm/salla-notification-item.entry.js +1 -1
  202. package/dist/esm/salla-notifications.entry.js +1 -1
  203. package/dist/esm/salla-offer-modal.entry.js +1 -1
  204. package/dist/esm/salla-offer.entry.js +1 -1
  205. package/dist/esm/salla-order-branch.entry.js +1 -1
  206. package/dist/esm/salla-order-cancel.entry.js +1 -1
  207. package/dist/esm/salla-order-details-multiple-bundle-product.entry.js +1 -1
  208. package/dist/esm/salla-order-details-options.entry.js +1 -1
  209. package/dist/esm/salla-order-details.entry.js +1 -1
  210. package/dist/esm/salla-order-edit-item.entry.js +1 -1
  211. package/dist/esm/salla-order-edit-product-card.entry.js +1 -1
  212. package/dist/esm/salla-order-edit.entry.js +1 -1
  213. package/dist/esm/salla-order-summary.entry.js +1 -1
  214. package/dist/esm/salla-order-totals-card.entry.js +1 -1
  215. package/dist/esm/salla-orders.entry.js +1 -1
  216. package/dist/esm/salla-payments.entry.js +1 -1
  217. package/dist/esm/salla-placeholder.entry.js +1 -1
  218. package/dist/esm/salla-price-range.entry.js +1 -1
  219. package/dist/esm/salla-product-card-embed.entry.js +1 -1
  220. package/dist/esm/{salla-order-options-modal_3.entry.js → salla-product-card_2.entry.js} +2 -204
  221. package/dist/esm/salla-product-size-guide.entry.js +1 -1
  222. package/dist/esm/salla-products-list.entry.js +1 -1
  223. package/dist/esm/salla-quick-order.entry.js +1 -1
  224. package/dist/esm/salla-rating-modal-v2.entry.js +34 -4
  225. package/dist/esm/salla-rating-modal.entry.js +34 -9
  226. package/dist/esm/salla-review-factors-tags.entry.js +1 -1
  227. package/dist/esm/salla-scopes.entry.js +1 -1
  228. package/dist/esm/salla-search.entry.js +1 -1
  229. package/dist/esm/salla-skeleton.entry.js +1 -1
  230. package/dist/esm/salla-slider.entry.js +1 -1
  231. package/dist/esm/salla-social-share.entry.js +1 -1
  232. package/dist/esm/salla-social.entry.js +1 -1
  233. package/dist/esm/salla-tab-content_3.entry.js +1 -1
  234. package/dist/esm/salla-tiered-offer.entry.js +1 -1
  235. package/dist/esm/salla-tooltip.entry.js +1 -1
  236. package/dist/esm/salla-trust-badges.entry.js +1 -1
  237. package/dist/esm/salla-user-menu.entry.js +1 -1
  238. package/dist/esm/salla-user-profile.entry.js +1 -1
  239. package/dist/esm/salla-user-settings.entry.js +1 -1
  240. package/dist/esm/salla-verify.entry.js +1 -1
  241. package/dist/esm/salla-wallet.entry.js +1 -1
  242. package/dist/esm/salla-wishlist-actions.entry.js +1 -1
  243. package/dist/esm/{tracked-promise-ILCl5q9c.js → tracked-promise-CfALRKPO.js} +1 -1
  244. package/dist/esm/twilight.js +3 -3
  245. package/dist/esm/{vanilla-picker-CXWkB9Rj.js → vanilla-picker-E0YuxtRq.js} +1 -1
  246. package/dist/twilight/{p-0ab66850.entry.js → p-111b12b2.entry.js} +1 -1
  247. package/dist/twilight/{p-280b577d.entry.js → p-11d16ea6.entry.js} +1 -1
  248. package/dist/twilight/{p-6c9462be.entry.js → p-15d6eb3d.entry.js} +1 -1
  249. package/dist/twilight/p-172d2910.entry.js +4 -0
  250. package/dist/twilight/{p-d2706f82.entry.js → p-1b2d51ff.entry.js} +1 -1
  251. package/dist/twilight/{p-67a110ca.entry.js → p-1b807a9e.entry.js} +1 -1
  252. package/dist/twilight/{p-a65070ba.entry.js → p-1cecee41.entry.js} +1 -1
  253. package/dist/twilight/{p-be77d488.entry.js → p-20a9fa11.entry.js} +1 -1
  254. package/dist/twilight/{p-835a102e.entry.js → p-23a0f9d3.entry.js} +1 -1
  255. package/dist/twilight/{p-7225f304.entry.js → p-27010b1e.entry.js} +1 -1
  256. package/dist/twilight/{p-c3c0eafb.entry.js → p-2929495e.entry.js} +1 -1
  257. package/dist/twilight/{p-204f6275.entry.js → p-2af31dd1.entry.js} +1 -1
  258. package/dist/twilight/{p-a30673d8.entry.js → p-310b4a53.entry.js} +1 -1
  259. package/dist/twilight/{p-ff572f0c.entry.js → p-317ac575.entry.js} +1 -1
  260. package/dist/twilight/{p-67636846.entry.js → p-31ed558a.entry.js} +1 -1
  261. package/dist/twilight/p-32392cf3.entry.js +4 -0
  262. package/dist/twilight/{p-0a1e3675.entry.js → p-33dd5133.entry.js} +1 -1
  263. package/dist/twilight/{p-e0096a71.entry.js → p-381676b5.entry.js} +1 -1
  264. package/dist/twilight/{p-246ff1db.entry.js → p-397e0798.entry.js} +1 -1
  265. package/dist/twilight/{p-6f89ecd5.entry.js → p-39d11d60.entry.js} +1 -1
  266. package/dist/twilight/{p-f49f7906.entry.js → p-3b0a60fa.entry.js} +1 -1
  267. package/dist/twilight/{p-9ae8d5cc.entry.js → p-3bd795f0.entry.js} +1 -1
  268. package/dist/twilight/{p-051cf8e8.entry.js → p-3d4b0d93.entry.js} +1 -1
  269. package/dist/twilight/{p-fe2dc707.entry.js → p-3e726a15.entry.js} +1 -1
  270. package/dist/twilight/{p-cd3a98b4.entry.js → p-4204adb8.entry.js} +1 -1
  271. package/dist/twilight/{p-6a3e5797.entry.js → p-45948907.entry.js} +1 -1
  272. package/dist/twilight/p-4f2e7ce7.entry.js +4 -0
  273. package/dist/twilight/{p-5d642891.entry.js → p-5671f508.entry.js} +1 -1
  274. package/dist/twilight/{p-f0483d2f.entry.js → p-5ceefb15.entry.js} +1 -1
  275. package/dist/twilight/{p-2b8d6b5c.entry.js → p-5d818495.entry.js} +1 -1
  276. package/dist/twilight/{p-0d012154.entry.js → p-5e23e49c.entry.js} +1 -1
  277. package/dist/twilight/{p-e7ba206e.entry.js → p-61d3bbc8.entry.js} +1 -1
  278. package/dist/twilight/{p-b291c768.entry.js → p-62fb7e9a.entry.js} +1 -1
  279. package/dist/twilight/{p-f888055e.entry.js → p-633a5ed7.entry.js} +1 -1
  280. package/dist/twilight/{p-fb460b15.entry.js → p-63908cf5.entry.js} +1 -1
  281. package/dist/twilight/{p-5eeda026.entry.js → p-6981573a.entry.js} +1 -1
  282. package/dist/twilight/{p-8b775260.entry.js → p-6a44a9db.entry.js} +1 -1
  283. package/dist/twilight/{p-55150c7f.entry.js → p-6d15b4ec.entry.js} +1 -1
  284. package/dist/twilight/{p-acd71b9c.entry.js → p-74386e55.entry.js} +1 -1
  285. package/dist/twilight/{p-03e5d981.entry.js → p-76f8b335.entry.js} +1 -1
  286. package/dist/twilight/p-79b67593.entry.js +4 -0
  287. package/dist/twilight/{p-daff5fee.entry.js → p-7bef3130.entry.js} +1 -1
  288. package/dist/twilight/{p-f3832e61.entry.js → p-847fcbbf.entry.js} +1 -1
  289. package/dist/twilight/{p-8f9578ea.entry.js → p-84986142.entry.js} +1 -1
  290. package/dist/twilight/{p-94e082e5.entry.js → p-88bcb450.entry.js} +1 -1
  291. package/dist/twilight/{p-811f7253.entry.js → p-896b5880.entry.js} +1 -1
  292. package/dist/twilight/{p-0d3f0c5e.entry.js → p-8b1c2efb.entry.js} +1 -1
  293. package/dist/twilight/{p-a971eb6e.entry.js → p-91ed85fa.entry.js} +1 -1
  294. package/dist/twilight/{p-060cb433.entry.js → p-93f0117b.entry.js} +1 -1
  295. package/dist/twilight/{p-f0ba85ef.entry.js → p-940265b8.entry.js} +1 -1
  296. package/dist/twilight/{p-cfc04f03.entry.js → p-94dd1c95.entry.js} +1 -1
  297. package/dist/twilight/{p-3c315245.entry.js → p-99bc3057.entry.js} +1 -1
  298. package/dist/twilight/{p-cc85cbb6.entry.js → p-9a3de1d3.entry.js} +1 -1
  299. package/dist/twilight/p-9b10bc50.entry.js +4 -0
  300. package/dist/twilight/{p-DGH40_w6.js → p-BPOLfGlq.js} +1 -1
  301. package/dist/twilight/{p-Z-0FpgUH.js → p-C2mMQUaR.js} +2 -2
  302. package/dist/twilight/{p-hlvyyBTt.js → p-CTVX-G0K.js} +1 -1
  303. package/dist/twilight/{p-CRL06FLf.js → p-Cm855HOG.js} +1 -1
  304. package/dist/twilight/{p-CswSlMMW.js → p-CqJ_OQmC.js} +1 -1
  305. package/dist/twilight/{p-ulwdkVD6.js → p-CrMqpxVf.js} +1 -1
  306. package/dist/twilight/{p-CRJyselG.js → p-Dag1-FEn.js} +1 -1
  307. package/dist/twilight/{p-D_66TtzK.js → p-DbXwwuth.js} +1 -1
  308. package/dist/twilight/{p-DxUIn207.js → p-Dmvcz29r.js} +1 -1
  309. package/dist/twilight/{p-CXgH1qPi.js → p-KcsFKraQ.js} +1 -1
  310. package/dist/twilight/{p-DMPBYOzv.js → p-_iz5Z_GI.js} +1 -1
  311. package/dist/twilight/{p-d642b334.entry.js → p-a1dc71b9.entry.js} +1 -1
  312. package/dist/twilight/{p-8ec5ca1a.entry.js → p-a731b254.entry.js} +1 -1
  313. package/dist/twilight/{p-d132c3a1.entry.js → p-ac0dedbd.entry.js} +1 -1
  314. package/dist/twilight/{p-2ede3e52.entry.js → p-ad8bb012.entry.js} +1 -1
  315. package/dist/twilight/{p-19bc5aa0.entry.js → p-afd586a0.entry.js} +1 -1
  316. package/dist/twilight/{p-befbb594.entry.js → p-b17f3ab5.entry.js} +1 -1
  317. package/dist/twilight/p-b1c8aea6.entry.js +4 -0
  318. package/dist/twilight/{p-58fd42b9.entry.js → p-b3899e53.entry.js} +1 -1
  319. package/dist/twilight/{p-1a299dab.entry.js → p-b46df798.entry.js} +1 -1
  320. package/dist/twilight/{p-8509e67b.entry.js → p-bc03c4dd.entry.js} +1 -1
  321. package/dist/twilight/{p-a397eadf.entry.js → p-bc4e3609.entry.js} +1 -1
  322. package/dist/twilight/{p-902bab33.entry.js → p-c1290a97.entry.js} +1 -1
  323. package/dist/twilight/{p-04d25025.entry.js → p-c8080b3e.entry.js} +1 -1
  324. package/dist/twilight/{p-8e87f47b.entry.js → p-c915af20.entry.js} +1 -1
  325. package/dist/twilight/{p-3b962591.entry.js → p-ca2435c0.entry.js} +1 -1
  326. package/dist/twilight/{p-e36a05c8.entry.js → p-d26db462.entry.js} +1 -1
  327. package/dist/twilight/{p-843c1499.entry.js → p-d433feae.entry.js} +1 -1
  328. package/dist/twilight/{p-3996a786.entry.js → p-d495c11f.entry.js} +1 -1
  329. package/dist/twilight/p-d72ea99d.entry.js +4 -0
  330. package/dist/twilight/p-d79de49b.entry.js +4 -0
  331. package/dist/twilight/{p-2bd896e8.entry.js → p-dcc21c13.entry.js} +1 -1
  332. package/dist/twilight/{p-206a4605.entry.js → p-e0b5c304.entry.js} +1 -1
  333. package/dist/twilight/{p-9d00311a.entry.js → p-e1ade50f.entry.js} +1 -1
  334. package/dist/twilight/{p-b7ad635b.entry.js → p-e3d8ca11.entry.js} +1 -1
  335. package/dist/twilight/{p-d4bfca23.entry.js → p-e5d401e6.entry.js} +1 -1
  336. package/dist/twilight/{p-7bf35ca7.entry.js → p-e70e2d64.entry.js} +1 -1
  337. package/dist/twilight/{p-38b57477.entry.js → p-ea3ca9b8.entry.js} +1 -1
  338. package/dist/twilight/p-eafcd660.entry.js +4 -0
  339. package/dist/twilight/{p-420cd3bc.entry.js → p-eb06d1c3.entry.js} +1 -1
  340. package/dist/twilight/{p-59d4fd28.entry.js → p-ec6c198d.entry.js} +1 -1
  341. package/dist/twilight/{p-85d51539.entry.js → p-ed19a207.entry.js} +1 -1
  342. package/dist/twilight/{p-7fc61c4c.entry.js → p-f28e7f54.entry.js} +1 -1
  343. package/dist/twilight/p-f319047e.entry.js +4 -0
  344. package/dist/twilight/{p-546c9f58.entry.js → p-f6a45b26.entry.js} +1 -1
  345. package/dist/twilight/{p-dad28a17.entry.js → p-f98986f7.entry.js} +1 -1
  346. package/dist/twilight/{p-5b2d05b7.entry.js → p-fb5ff81c.entry.js} +1 -1
  347. package/dist/twilight/{p-09d7aa92.entry.js → p-fb61b829.entry.js} +1 -1
  348. package/dist/twilight/{p-ffe0dc1e.entry.js → p-fda54504.entry.js} +1 -1
  349. package/dist/twilight/{p-6d17cc72.entry.js → p-fe130150.entry.js} +1 -1
  350. package/dist/twilight/{p-DqVd28X3.js → p-xxhuj_Ip.js} +1 -1
  351. package/dist/twilight/twilight.esm.js +1 -1
  352. package/dist/types/components/salla-loyalty-program/salla-loyalty-exchange-product-card.d.ts +10 -0
  353. package/dist/types/components/salla-loyalty-program/salla-loyalty-panel.d.ts +1 -0
  354. package/dist/types/components/salla-loyalty-program/salla-loyalty-program.d.ts +1 -0
  355. package/dist/types/components/salla-loyalty-program/salla-reward-details.d.ts +9 -0
  356. package/dist/types/components/salla-rating-modal/salla-rating-modal-v2.d.ts +4 -0
  357. package/dist/types/components/salla-rating-modal/salla-rating-modal.d.ts +4 -0
  358. package/dist/types/components.d.ts +33 -0
  359. package/package.json +5 -5
  360. package/dist/twilight/p-180f51ef.entry.js +0 -4
  361. package/dist/twilight/p-55ef75cb.entry.js +0 -4
  362. package/dist/twilight/p-8e84cce0.entry.js +0 -4
  363. package/dist/twilight/p-a2a5a087.entry.js +0 -4
  364. package/dist/twilight/p-ad33426d.entry.js +0 -4
  365. package/dist/twilight/p-bc46608a.entry.js +0 -4
  366. package/dist/twilight/p-bdc874b8.entry.js +0 -4
  367. package/dist/twilight/p-e8e5906a.entry.js +0 -4
  368. package/dist/twilight/p-ee53cba1.entry.js +0 -4
  369. package/dist/twilight/p-f9a495bf.entry.js +0 -4
@@ -1,213 +1,11 @@
1
1
  /*!
2
2
  * Crafted with ❤ by Salla
3
3
  */
4
- import { r as registerInstance, h, a as getElement, H as Host } from './index-DGH40_w6.js';
4
+ import { r as registerInstance, h, H as Host, a as getElement } from './index-BPOLfGlq.js';
5
5
  import { S as Star } from './star2-D4oPi1Ov.js';
6
6
  import { H as Helper } from './Helper-BQ9mvrt9.js';
7
7
  import './anime.es-CgtvEd63.js';
8
8
 
9
- 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}";
10
-
11
- const SallaOrderOptionsModal = class {
12
- constructor(hostRef) {
13
- registerInstance(this, hostRef);
14
- this.resolveFn = null;
15
- this.rejectFn = null;
16
- this.optionsRefs = new Map();
17
- this.changeHandler = null;
18
- /** Sync hook for callers that need to act under the submit user gesture (Apple Pay). */
19
- this.submitCallback = null;
20
- this.orderOptions = [];
21
- this.basePrice = 0;
22
- this.liveTotal = 0;
23
- this.isSubmitting = false;
24
- /** Bumped each open() so the inner <salla-product-options> remounts. */
25
- this.sessionId = 0;
26
- this.paymentMode = 'default';
27
- this.title = '';
28
- this.subtitle = '';
29
- this.submitLabel = '';
30
- this.totalLabel = '';
31
- this.requiredMessage = '';
32
- this.handleClose = () => {
33
- if (this.isSubmitting)
34
- return;
35
- this.rejectFn?.({ reason: 'dismissed' });
36
- this.resolveFn = null;
37
- this.rejectFn = null;
38
- this.detachChangeListener();
39
- this.reset();
40
- };
41
- salla.lang.onLoaded(() => this.loadTranslations());
42
- }
43
- componentWillLoad() {
44
- this.loadTranslations();
45
- }
46
- loadTranslations() {
47
- this.title = salla.lang.get('blocks.order_options.title');
48
- this.subtitle = salla.lang.get('blocks.order_options.subtitle');
49
- this.submitLabel = salla.lang.get('blocks.order_options.continue');
50
- this.totalLabel = salla.lang.get('blocks.order_options.total');
51
- this.requiredMessage = salla.lang.get('blocks.order_options.required_message');
52
- }
53
- /**
54
- * Open the modal. Resolves with selections on submit; rejects on dismiss.
55
- * `onSubmit` fires sync in the submit click (for Apple Pay user-gesture).
56
- * `paymentMode: 'apple-pay'` swaps the footer button for <apple-pay-button>.
57
- */
58
- async open(payload) {
59
- // Normalize here, not in the shared salla-product-options: text/number order options ship no
60
- // `details`, which product-options dereferences unguarded.
61
- this.orderOptions = (Array.isArray(payload.orderOptions) ? payload.orderOptions : [])
62
- .map((o) => ({ ...o, details: o.details ?? [] }));
63
- this.basePrice = Number(payload.basePrice) || 0;
64
- this.liveTotal = this.basePrice + this.seedOptionsPrice(this.orderOptions);
65
- this.isSubmitting = false;
66
- this.sessionId++;
67
- this.optionsRefs.clear();
68
- this.submitCallback = payload.onSubmit ?? null;
69
- this.paymentMode = payload.paymentMode ?? 'default';
70
- await this.modal?.open();
71
- this.attachChangeListener();
72
- return new Promise((resolve, reject) => {
73
- this.resolveFn = resolve;
74
- this.rejectFn = reject;
75
- });
76
- }
77
- async close() {
78
- await this.modal?.close();
79
- }
80
- /** Sync walk of inputs — avoids `await` through the @Method that would consume the AP user gesture. */
81
- collectOrderOptionsSync() {
82
- const result = [];
83
- for (const [, el] of this.optionsRefs) {
84
- if (!el)
85
- continue;
86
- const inputs = el.querySelectorAll('[name^="options["],[name*="[options]["]');
87
- inputs.forEach((input) => {
88
- if (input instanceof HTMLInputElement && (input.type === 'radio' || input.type === 'checkbox') && !input.checked) {
89
- return;
90
- }
91
- const match = input.name.match(/(?:^|\[)options\]?\[(\d+)\]/);
92
- if (!match)
93
- return;
94
- const raw = input.value;
95
- if (raw === '' || raw === null || raw === undefined)
96
- return;
97
- const numeric = Number(raw);
98
- result.push({
99
- id: Number(match[1]),
100
- value: Number.isFinite(numeric) && raw === String(numeric) ? numeric : raw,
101
- });
102
- });
103
- }
104
- return result;
105
- }
106
- /** Sync native validity — keeps the AP user gesture intact. */
107
- validateSync() {
108
- let pass = true;
109
- for (const [, el] of this.optionsRefs) {
110
- if (!el)
111
- continue;
112
- const requiredInputs = el.querySelectorAll('[required]');
113
- requiredInputs.forEach((input) => {
114
- // Mirror salla-product-options.reportValidity(): skip hidden/disabled inputs so a
115
- // required field in a `.hidden` conditional container can't silently block submit.
116
- if (input.disabled || input.closest('.hidden'))
117
- return;
118
- if ('reportValidity' in input && !input.reportValidity())
119
- pass = false;
120
- });
121
- }
122
- return pass;
123
- }
124
- /** Sum the additional_price of any pre-selected details. */
125
- seedOptionsPrice(orderOptions) {
126
- let sum = 0;
127
- orderOptions.forEach((opt) => {
128
- (opt.details || []).forEach((d) => {
129
- if (d.is_selected)
130
- sum += Number(d.additional_price) || 0;
131
- });
132
- });
133
- return sum;
134
- }
135
- /** salla.event.on is global — attach per open, detach on close to avoid stacking. */
136
- attachChangeListener() {
137
- this.detachChangeListener();
138
- this.changeHandler = () => this.recomputeTotal();
139
- salla.event.on('product-options::change', this.changeHandler);
140
- }
141
- detachChangeListener() {
142
- if (!this.changeHandler)
143
- return;
144
- salla.event.off('product-options::change', this.changeHandler);
145
- this.changeHandler = null;
146
- }
147
- async recomputeTotal() {
148
- let selectedPrice = 0;
149
- for (const [, el] of this.optionsRefs) {
150
- if (!el)
151
- continue;
152
- const selected = typeof el.getSelectedOptions === 'function'
153
- ? await el.getSelectedOptions()
154
- : [];
155
- (selected || []).forEach((s) => {
156
- selectedPrice += Number(s.additional_price) || 0;
157
- });
158
- }
159
- this.liveTotal = this.basePrice + selectedPrice;
160
- }
161
- handleSubmit() {
162
- if (this.isSubmitting)
163
- return;
164
- if (!this.validateSync()) {
165
- salla.notify?.error?.(this.requiredMessage);
166
- return;
167
- }
168
- this.isSubmitting = true;
169
- const orderOptions = this.collectOrderOptionsSync();
170
- const total = Math.round(this.liveTotal * 100) / 100;
171
- // Fire onSubmit BEFORE any await — Apple Pay needs the user gesture.
172
- try {
173
- this.submitCallback?.(orderOptions, total);
174
- }
175
- catch (err) {
176
- salla?.logger?.warn?.('order-options modal onSubmit threw', err);
177
- }
178
- this.resolveFn?.({ orderOptions });
179
- this.resolveFn = null;
180
- this.rejectFn = null;
181
- this.submitCallback = null;
182
- this.detachChangeListener();
183
- this.modal?.close().then(() => this.reset());
184
- this.isSubmitting = false;
185
- }
186
- /** Clear options on close so the inner <salla-product-options> unmounts. */
187
- reset() {
188
- this.orderOptions = [];
189
- this.optionsRefs.clear();
190
- this.liveTotal = 0;
191
- }
192
- render() {
193
- // salla.money returns HTML (sicon-sar icon) → render via innerHTML. Round
194
- // first so floating-point sum doesn't show as 1174.3799999999999.
195
- const totalHtml = salla.money(Math.round(this.liveTotal * 100) / 100);
196
- 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) => {
197
- if (!e.detail)
198
- this.handleClose();
199
- } }, 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 => {
200
- if (!el)
201
- return;
202
- this.optionsRefs.set('order-options', el);
203
- // Without seeding, first multi-select toggle wipes pre-selected defaults.
204
- el.seedSelectedOptions?.();
205
- }, "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 })))))));
206
- }
207
- get host() { return getElement(this); }
208
- };
209
- SallaOrderOptionsModal.style = sallaOrderOptionsModalCss;
210
-
211
9
  var Heart = `<!-- Generated by IcoMoon.io -->
212
10
  <svg version="1.1" xmlns="http://www.w3.org/2000/svg" width="32" height="32" viewBox="0 0 32 32">
213
11
  <title>heart</title>
@@ -484,4 +282,4 @@ const SallaProductsSlider = class {
484
282
  };
485
283
  SallaProductsSlider.style = sallaProductsSliderCss;
486
284
 
487
- export { SallaOrderOptionsModal as salla_order_options_modal, SallaProductCard as salla_product_card, SallaProductsSlider as salla_products_slider };
285
+ export { SallaProductCard as salla_product_card, SallaProductsSlider as salla_products_slider };
@@ -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-BPOLfGlq.js';
5
5
 
6
6
  var PencilRuler = `<!-- Generated by IcoMoon.io -->
7
7
  <svg version="1.1" xmlns="http://www.w3.org/2000/svg" width="32" height="32" viewBox="0 0 32 32">
@@ -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-BPOLfGlq.js';
5
5
  import { a as anime } from './anime.es-CgtvEd63.js';
6
6
  import { S as ShoppingBag } from './shopping-bag-DiKTtDW5.js';
7
7
  import { H as Helper } from './Helper-BQ9mvrt9.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-BPOLfGlq.js';
5
5
  import { S as SIiPhoneX } from './iphone-x-CciN5Q_x.js';
6
6
  import { e as email } from './mail-DzAIgzdz.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, f as forceUpdate, h, H as Host, a as getElement } from './index-DGH40_w6.js';
4
+ import { r as registerInstance, f as forceUpdate, h, H as Host, a as getElement } from './index-BPOLfGlq.js';
5
5
  import { S as Star } from './star-CeFAfcTv.js';
6
6
  import { S as ShippingFast } from './shipping-fast-lMgMt31Q.js';
7
7
  import { C as CheckCircle2 } from './check-circle2-BV4kqbdL.js';
@@ -11,7 +11,7 @@ import { W as WhatsappIcon } from './whatsapp2-CgR-T_ZS.js';
11
11
  import { e as email } from './mail-DzAIgzdz.js';
12
12
  import './anime.es-CgtvEd63.js';
13
13
 
14
- const sallaRatingModalCss = ".s-rating-modal-product-details{padding-bottom:0.5rem}.s-rating-modal-comment{margin-top:0.35rem}.s-rating-modal-product{margin-bottom:1rem}.s-rating-modal-product-img{display:block;width:100%;height:100%;object-fit:cover}.s-rating-modal-product-title{font-size:0.95rem;font-weight:600;line-height:1.5;margin:0}.s-rating-modal-stars-product{margin-top:0.5rem}.s-rating-modal-product-details-main{display:flex;align-items:center;margin-bottom:0.5rem;padding-bottom:0;border-bottom:0}.s-rating-modal-product-info-row{display:flex;align-items:center;gap:0.6rem;margin-bottom:0.5rem;padding-bottom:0;border-bottom:0}.s-rating-modal-product-main-review{width:100%;text-align:right}.s-rating-modal-product-rating-rows{display:grid;gap:0.45rem;margin:0.2rem 0 0.7rem}.s-rating-modal-product-rating-row{display:flex;align-items:center;justify-content:space-between;gap:0.75rem;min-height:2rem}.s-rating-modal-product-rating-row salla-rating-stars{flex-shrink:0}.s-rating-modal-product-rating-row .s-rating-stars-wrapper{align-items:center;min-height:1.75rem}.s-rating-modal-product-rating-row .s-rating-stars-label,.s-rating-modal-product-rating-row .s-rating-stars-label-without-tag{min-width:auto;min-height:1.25rem;line-height:1.25rem;font-size:0.8rem;color:#5b6470;white-space:nowrap;text-align:end;transition:opacity 0.15s ease}.s-rating-modal-product-rating-row .s-rating-stars-label--empty,.s-rating-modal-product-rating-row .s-rating-stars-label-without-tag--empty{opacity:0}.s-rating-modal-product-rating-row-main{margin-bottom:0.35rem;padding:0.5rem 0.6rem;border:1px solid #d1d5db;border-radius:0.45rem;background:transparent}.s-rating-modal-product-factor-name{color:#5b6470;font-size:0.9rem;line-height:1.25}.s-rating-modal-product-rating-row-main .s-rating-modal-product-factor-name{font-size:1rem;color:#5b6470}.s-rating-modal-product-factor-required{color:#f87171;margin-inline-start:0.2rem}.s-rating-modal-product-img-wrap{width:5rem;min-width:5rem;height:3.5rem;flex-shrink:0;overflow:hidden;border-radius:0.375rem;background:#f3f4f6}.s-rating-modal-uploader.is-opened{height:auto !important;opacity:1 !important;overflow:visible !important;pointer-events:auto !important;margin-bottom:1rem}";
14
+ const sallaRatingModalCss = ".s-rating-modal-product-details{padding-bottom:0.5rem}.s-rating-modal-comment{margin-top:0.35rem}.s-rating-modal-product{margin-bottom:1rem}.s-rating-modal-product-img{display:block;width:100%;height:100%;object-fit:cover}.s-rating-modal-product-title{font-size:0.95rem;font-weight:600;line-height:1.5;margin:0}.s-rating-modal-stars-product{margin-top:0.5rem}.s-rating-modal-loyalty-points-note-container{display:flex;align-items:center;gap:0.625rem;width:100%;margin-top:1.5rem;margin-bottom:0.75rem;padding:0.75rem;border-radius:0.5rem;background-color:#E6F4EA}.s-rating-modal-loyalty-points-note-icon{display:flex;flex-shrink:0;align-items:center;justify-content:center;width:1.25rem;height:1.25rem;color:#1B7F5C}.s-rating-modal-loyalty-points-note-icon svg{width:1.5rem;height:1.5rem;fill:currentColor}.s-rating-modal-loyalty-points-note-text{flex:1;margin:0;font-size:0.875rem;line-height:1.25rem;color:#1f2937}.s-rating-modal-product-details-main{display:flex;align-items:center;margin-bottom:0.5rem;padding-bottom:0;border-bottom:0}.s-rating-modal-product-info-row{display:flex;align-items:center;gap:0.6rem;margin-bottom:0.5rem;padding-bottom:0;border-bottom:0}.s-rating-modal-product-main-review{width:100%;text-align:right}.s-rating-modal-product-rating-rows{display:grid;gap:0.45rem;margin:0.2rem 0 0.7rem}.s-rating-modal-product-rating-row{display:flex;align-items:center;justify-content:space-between;gap:0.75rem;min-height:2rem}.s-rating-modal-product-rating-row salla-rating-stars{flex-shrink:0}.s-rating-modal-product-rating-row .s-rating-stars-wrapper{align-items:center;min-height:1.75rem}.s-rating-modal-product-rating-row .s-rating-stars-label,.s-rating-modal-product-rating-row .s-rating-stars-label-without-tag{min-width:auto;min-height:1.25rem;line-height:1.25rem;font-size:0.8rem;color:#5b6470;white-space:nowrap;text-align:end;transition:opacity 0.15s ease}.s-rating-modal-product-rating-row .s-rating-stars-label--empty,.s-rating-modal-product-rating-row .s-rating-stars-label-without-tag--empty{opacity:0}.s-rating-modal-product-rating-row-main{margin-bottom:0.35rem;padding:0.5rem 0.6rem;border:1px solid #d1d5db;border-radius:0.45rem;background:transparent}.s-rating-modal-product-factor-name{color:#5b6470;font-size:0.9rem;line-height:1.25}.s-rating-modal-product-rating-row-main .s-rating-modal-product-factor-name{font-size:1rem;color:#5b6470}.s-rating-modal-product-factor-required{color:#f87171;margin-inline-start:0.2rem}.s-rating-modal-product-img-wrap{width:5rem;min-width:5rem;height:3.5rem;flex-shrink:0;overflow:hidden;border-radius:0.375rem;background:#f3f4f6}.s-rating-modal-uploader.is-opened{height:auto !important;opacity:1 !important;overflow:visible !important;pointer-events:auto !important;margin-bottom:1rem}";
15
15
 
16
16
  const SallaRatingModalV2 = class {
17
17
  constructor(hostRef) {
@@ -33,6 +33,7 @@ const SallaRatingModalV2 = class {
33
33
  this.editItem = null;
34
34
  this.allowAttachImages = false;
35
35
  this.allowContactSupport = false;
36
+ this.loyaltyImageRatingPoints = 0;
36
37
  this.dragAndDropFilesLabel = salla.lang.get('common.uploader.drag_and_drop_files');
37
38
  this.contactSubjectLabel = salla.lang.get('pages.rating.contact_subject');
38
39
  this.editReviewLabel = salla.lang.get('pages.rating.edit_review');
@@ -47,6 +48,9 @@ const SallaRatingModalV2 = class {
47
48
  this.contactUsLabel = salla.lang.get('blocks.footer.social');
48
49
  this.requiredFactorsLabel = salla.lang.get('pages.rating.rate_required_factors');
49
50
  this.overallProductRatingLabel = salla.lang.get('pages.rating.overall_product_rating');
51
+ this.loyaltyPointsForImagesLabel = salla.lang.get('pages.rating.loyalty_points_for_images', {
52
+ points: ':points',
53
+ });
50
54
  this.contentRefs = [];
51
55
  this.hiddenInputs = [];
52
56
  this.userFilledFactorKeys = {};
@@ -94,6 +98,8 @@ const SallaRatingModalV2 = class {
94
98
  await setNestedAsync('en.trans', 'pages.rating.rate_required_factors', 'Please rate all required factors to complete your review.');
95
99
  await setNestedAsync('ar.trans', 'pages.rating.overall_product_rating', 'التقييم العام للمنتج');
96
100
  await setNestedAsync('en.trans', 'pages.rating.overall_product_rating', 'Overall product rating');
101
+ await setNestedAsync('ar.trans', 'pages.rating.loyalty_points_for_images', 'اكسب :points نقطة ولاء عند إضافة صور لتقييمك!');
102
+ await setNestedAsync('en.trans', 'pages.rating.loyalty_points_for_images', 'Earn :points loyalty points when adding photos to your review!');
97
103
  this.dragAndDropFilesLabel = salla.lang.get('common.uploader.drag_and_drop_files');
98
104
  this.allowedImagesTypesLabel = salla.lang.get('common.uploader.allowed_images_types');
99
105
  this.threeImagesMax = salla.lang.get('common.uploader.max_three_images');
@@ -107,6 +113,9 @@ const SallaRatingModalV2 = class {
107
113
  this.confirmDeleteBtn = salla.lang.get('common.elements.confirm_delete');
108
114
  this.requiredFactorsLabel = salla.lang.get('pages.rating.rate_required_factors');
109
115
  this.overallProductRatingLabel = salla.lang.get('pages.rating.overall_product_rating');
116
+ this.loyaltyPointsForImagesLabel = salla.lang.get('pages.rating.loyalty_points_for_images', {
117
+ points: ':points',
118
+ });
110
119
  this.contact_body = (store, id, customer) => salla.lang.get('pages.rating.contact_body', { store, id, customer });
111
120
  };
112
121
  setTranslations();
@@ -274,6 +283,7 @@ const SallaRatingModalV2 = class {
274
283
  this.order = res.data;
275
284
  this.productReviewFactors = await this.fetchAllProductReviewFactors(res.data);
276
285
  }))
286
+ .then(() => this.readyUpLoyaltyPoints())
277
287
  .then(() => this.modal.setTitle(`${salla.lang.get('pages.rating.rate_order')} <span class="unicode">(#${this.order.id})</span>`))
278
288
  .then(() => {
279
289
  // Initialize productImages for all products
@@ -304,6 +314,7 @@ const SallaRatingModalV2 = class {
304
314
  this.editFeedbackId = params.feedback_id;
305
315
  try {
306
316
  await this.fetchEditItem(params.feedback_id);
317
+ await this.readyUpLoyaltyPoints();
307
318
  if (this.editType === 'product' && this.editItem?.product?.id) {
308
319
  await this.loadCustomerOrderForEdit();
309
320
  await this.ensureProductFactorsLoaded(this.editItem.product.id);
@@ -630,6 +641,24 @@ const SallaRatingModalV2 = class {
630
641
  let lasName = salla.config.get('user.last_name') || salla.storage.get('user.last_name') || '';
631
642
  return `${firstName} ${lasName}`;
632
643
  }
644
+ async readyUpLoyaltyPoints() {
645
+ const featureEnabled = salla.loyalty?.isFeatureEnabled?.();
646
+ if (!featureEnabled) {
647
+ this.loyaltyImageRatingPoints = 0;
648
+ return;
649
+ }
650
+ const rating_product_points = salla.config.get('store.settings.rating.rating_product_points') || 0;
651
+ const rating_product_with_image_points = salla.config.get('store.settings.rating.rating_product_with_image_points') || 0;
652
+ this.loyaltyImageRatingPoints =
653
+ Number(rating_product_with_image_points) + Number(rating_product_points);
654
+ }
655
+ loyaltyPointsNote() {
656
+ if (!this.loyaltyImageRatingPoints || !this.loyaltyPointsForImagesLabel) {
657
+ return null;
658
+ }
659
+ const svgIcon = (h("svg", { width: "17", height: "17", viewBox: "0 0 17 17", fill: "none", xmlns: "http://www.w3.org/2000/svg" }, h("path", { d: "M10 0C13.6819 0 16.6667 2.98477 16.6667 6.66664C16.6667 9.37047 15.057 11.6984 12.7437 12.7444C11.6978 15.0575 9.3701 16.6666 6.66668 16.6666C2.98477 16.6666 0 13.6819 0 9.99998C0 7.29656 1.60918 4.96894 3.92195 3.92276C4.96827 1.60964 7.29618 0 10 0ZM6.66668 5C3.90524 5 1.66667 7.23856 1.66667 9.99998C1.66667 12.7614 3.90524 15 6.66668 15C9.4281 15 11.6667 12.7614 11.6667 9.99998C11.6667 7.23856 9.4281 5 6.66668 5ZM7.50002 5.83333V6.66664H9.16668V8.33331H5.83333C5.60322 8.33331 5.41667 8.51989 5.41667 8.74998C5.41667 8.95456 5.56407 9.12464 5.75844 9.15998L5.83333 9.16664H7.50002C8.6506 9.16664 9.58335 10.0994 9.58335 11.25C9.58335 12.4006 8.6506 13.3333 7.50002 13.3333V14.1666H5.83333V13.3333H4.16667V11.6666H7.50002C7.7301 11.6666 7.91668 11.4801 7.91668 11.25C7.91668 11.0455 7.76927 10.8753 7.57493 10.8401L7.50002 10.8333H5.83333C4.68274 10.8333 3.75 9.90056 3.75 8.74998C3.75 7.59939 4.68274 6.66664 5.83333 6.66664V5.83333H7.50002ZM10 1.66667C8.51377 1.66667 7.17893 2.31513 6.26313 3.34457C6.39704 3.33736 6.53138 3.33333 6.66668 3.33333C10.3486 3.33333 13.3333 6.3181 13.3333 9.99998C13.3333 10.1356 13.3293 10.2702 13.3213 10.4037C14.3513 9.48814 15 8.15314 15 6.66664C15 3.90524 12.7614 1.66667 10 1.66667Z", fill: "#008C56" })));
660
+ return (h("div", { class: "s-rating-modal-loyalty-points-note-container" }, h("span", { class: "s-rating-modal-loyalty-points-note-icon" }, svgIcon), h("p", { class: "s-rating-modal-loyalty-points-note-text" }, this.loyaltyPointsForImagesLabel.replace(':points', String(this.loyaltyImageRatingPoints)))));
661
+ }
633
662
  normalizeReviewFactorsPayload(payload) {
634
663
  const data = payload?.data ?? payload?.factors;
635
664
  if (!Array.isArray(data)) {
@@ -908,7 +937,7 @@ const SallaRatingModalV2 = class {
908
937
  }, {});
909
938
  }
910
939
  renderProductStep(item, index) {
911
- return (h("section", { class: "s-rating-modal-step s-rating-modal-hidden", "data-type": "products", "data-product-id": item.product.id, key: item.product.id }, h("div", { class: "s-rating-modal-product" }, h("div", { class: "rating-outer-form", "data-stars-error": salla.lang.get('pages.rating.rate_product_stars') }, h("div", { class: "s-rating-modal-product-details" }, h("div", { class: "s-rating-modal-product-info-row" }, h("div", { class: "s-rating-modal-product-img-wrap" }, h("img", { src: item.product.thumbnail, alt: item.product.name, class: "s-rating-modal-product-img" })), h("h3", { class: "s-rating-modal-product-title" }, item.product.name)), this.renderProductReviewFactors(item.product.id, 0, { fieldPrefix: '' }), h("input", { type: "hidden", name: "product_id", value: item.product.id }), h("textarea", { placeholder: salla.lang.get('pages.rating.write_product_rate'), name: "comment", class: "s-rating-modal-comment" }), h("small", { class: "s-rating-modal-validation-msg" }))), this.allowAttachImages && (h("div", { class: "s-rating-modal-uploader is-opened", ref: el => (this.contentRefs[index] = el) }, h("salla-file-upload", { name: "image", maxFilesCount: this.MAX_UPLOAD_LIMIT, imagePreviewHeight: 117, "instant-upload": true, type: "feedback", payloadName: "files[]", id: `file-${item.product.id}`, title: item.product.name, allowMultiple: true, instantUpload: true, accept: "image/png, image/jpeg, image/jpg", url: salla.url.api('upload'), onUploaded: e => {
940
+ return (h("section", { class: "s-rating-modal-step s-rating-modal-hidden", "data-type": "products", "data-product-id": item.product.id, key: item.product.id }, h("div", { class: "s-rating-modal-product" }, this.allowAttachImages && this.loyaltyPointsNote(), h("div", { class: "rating-outer-form", "data-stars-error": salla.lang.get('pages.rating.rate_product_stars') }, h("div", { class: "s-rating-modal-product-details" }, h("div", { class: "s-rating-modal-product-info-row" }, h("div", { class: "s-rating-modal-product-img-wrap" }, h("img", { src: item.product.thumbnail, alt: item.product.name, class: "s-rating-modal-product-img" })), h("h3", { class: "s-rating-modal-product-title" }, item.product.name)), this.renderProductReviewFactors(item.product.id, 0, { fieldPrefix: '' }), h("input", { type: "hidden", name: "product_id", value: item.product.id }), h("textarea", { placeholder: salla.lang.get('pages.rating.write_product_rate'), name: "comment", class: "s-rating-modal-comment" }), h("small", { class: "s-rating-modal-validation-msg" }))), this.allowAttachImages && (h("div", { class: "s-rating-modal-uploader is-opened", ref: el => (this.contentRefs[index] = el) }, h("salla-file-upload", { name: "image", maxFilesCount: this.MAX_UPLOAD_LIMIT, imagePreviewHeight: 117, "instant-upload": true, type: "feedback", payloadName: "files[]", id: `file-${item.product.id}`, title: item.product.name, allowMultiple: true, instantUpload: true, accept: "image/png, image/jpeg, image/jpg", url: salla.url.api('upload'), onUploaded: e => {
912
941
  this.productImages = {
913
942
  ...this.productImages,
914
943
  [item.product.id]: [...(this.productImages[item.product.id] || []), e.detail],
@@ -984,6 +1013,7 @@ const SallaRatingModalV2 = class {
984
1013
  this.currentIndex = 0;
985
1014
  this.submitted = [];
986
1015
  this.scheduleWizardSetup = false;
1016
+ this.loyaltyImageRatingPoints = 0;
987
1017
  }
988
1018
  getDeleteModal() {
989
1019
  return (h("salla-modal", { ref: modal => (this.deleteModal = modal), width: "xs", onModalVisibilityChanged: isOpen => this.resetData(isOpen) }, h("div", { class: "s-rating-modal-delete-wrapper", ref: el => (this.body = el) }, h("h3", null, this.confirmDeletionLabel), h("p", null, this.areYouSureLabel), h("div", { class: "s-rating-modal-delete-actions" }, h("salla-button", { loaderPosition: "center", onClick: () => this.deleteReview() }, this.confirmDeleteBtn), h("salla-button", { color: "danger", fill: "outline", onClick: () => this.deleteModal.close() }, this.cancelLabel)))));
@@ -999,7 +1029,7 @@ const SallaRatingModalV2 = class {
999
1029
  })));
1000
1030
  }
1001
1031
  getEditModal() {
1002
- return (h("salla-modal", { ref: modal => (this.editModal = modal), width: "md", onModalVisibilityChanged: isOpen => this.resetData(isOpen) }, h("div", { class: "s-rating-modal-edit-wrapper", ref: el => (this.body = el) }, this.editType === 'store' && this.editItem ? (h("div", { class: "rating-outer-form s-rating-modal-step-wrap s-rating-modal-step", "data-type": "store", ref: currentTab => (this.currentTab = currentTab) }, h("div", { class: "s-rating-modal-rounded-icon" }, h("img", { src: salla.config.get('store.logo', 'https://assets.salla.sa/cp/assets/images/logo-new.png'), alt: "store name", class: "s-rating-modal-store-logo" })), h("h2", { class: "s-rating-modal-title" }, salla.lang.get('pages.rating.rate_the_store')), h("div", { class: "s-rating-modal-stars-company" }, h("salla-rating-stars", { withLabel: true, size: "large", editable: true, value: this.editItem.stars })), h("textarea", { name: "content", value: this.editItem.content, class: "s-rating-modal-comment", placeholder: salla.lang.get('pages.rating.write_store_rate') }), h("small", { class: "s-rating-modal-validation-msg" }))) : null, this.editType === 'shipping' && this.editItem ? (h("div", { class: "rating-outer-form s-rating-modal-step-wrap s-rating-modal-step", "data-type": "shipping", ref: currentTab => (this.currentTab = currentTab) }, this.editItem.shipping.logo ? (h("div", { class: "s-rating-modal-rounded-icon" }, h("img", { src: this.editItem.shipping.logo, class: "s-rating-modal-shipping-logo", alt: this.editItem.shipping.name }))) : (h("span", { class: "s-rating-modal-icon", innerHTML: ShippingFast })), h("div", { class: "s-rating-modal-title" }, ' ', `${salla.lang.get('pages.rating.rate_shipping')} ${this.editItem.shipping.name}`), h("div", { class: "s-rating-modal-stars-company" }, h("salla-rating-stars", { withLabel: true, size: "large", editable: true, value: this.editItem.stars })), h("textarea", { name: "content", class: "s-rating-modal-comment", value: this.editItem.content, placeholder: salla.lang.get('pages.rating.write_shipping_rate') }), h("small", { class: "s-rating-modal-validation-msg" }))) : null, this.editType == 'product' && this.editItem ? (h("section", { class: "s-rating-modal-step", "data-type": "products", ref: currentTab => (this.currentTab = currentTab) }, h("div", { class: "s-rating-modal-product" }, h("div", { class: "rating-outer-form", "data-stars-error": salla.lang.get('pages.rating.rate_product_stars') }, h("div", { class: "s-rating-modal-product-details" }, h("div", { class: "s-rating-modal-product-info-row" }, h("div", { class: "s-rating-modal-product-img-wrap" }, h("img", { src: this.editItem.product.image.url, alt: this.editItem.product.name, class: "s-rating-modal-product-img" })), h("h3", { class: "s-rating-modal-product-title" }, this.editItem.product.name)), this.renderProductReviewFactors(this.editItem.product.id, 0, {
1032
+ return (h("salla-modal", { ref: modal => (this.editModal = modal), width: "md", onModalVisibilityChanged: isOpen => this.resetData(isOpen) }, h("div", { class: "s-rating-modal-edit-wrapper", ref: el => (this.body = el) }, this.editType === 'store' && this.editItem ? (h("div", { class: "rating-outer-form s-rating-modal-step-wrap s-rating-modal-step", "data-type": "store", ref: currentTab => (this.currentTab = currentTab) }, h("div", { class: "s-rating-modal-rounded-icon" }, h("img", { src: salla.config.get('store.logo', 'https://assets.salla.sa/cp/assets/images/logo-new.png'), alt: "store name", class: "s-rating-modal-store-logo" })), h("h2", { class: "s-rating-modal-title" }, salla.lang.get('pages.rating.rate_the_store')), h("div", { class: "s-rating-modal-stars-company" }, h("salla-rating-stars", { withLabel: true, size: "large", editable: true, value: this.editItem.stars })), h("textarea", { name: "content", value: this.editItem.content, class: "s-rating-modal-comment", placeholder: salla.lang.get('pages.rating.write_store_rate') }), h("small", { class: "s-rating-modal-validation-msg" }))) : null, this.editType === 'shipping' && this.editItem ? (h("div", { class: "rating-outer-form s-rating-modal-step-wrap s-rating-modal-step", "data-type": "shipping", ref: currentTab => (this.currentTab = currentTab) }, this.editItem.shipping.logo ? (h("div", { class: "s-rating-modal-rounded-icon" }, h("img", { src: this.editItem.shipping.logo, class: "s-rating-modal-shipping-logo", alt: this.editItem.shipping.name }))) : (h("span", { class: "s-rating-modal-icon", innerHTML: ShippingFast })), h("div", { class: "s-rating-modal-title" }, ' ', `${salla.lang.get('pages.rating.rate_shipping')} ${this.editItem.shipping.name}`), h("div", { class: "s-rating-modal-stars-company" }, h("salla-rating-stars", { withLabel: true, size: "large", editable: true, value: this.editItem.stars })), h("textarea", { name: "content", class: "s-rating-modal-comment", value: this.editItem.content, placeholder: salla.lang.get('pages.rating.write_shipping_rate') }), h("small", { class: "s-rating-modal-validation-msg" }))) : null, this.editType == 'product' && this.editItem ? (h("section", { class: "s-rating-modal-step", "data-type": "products", ref: currentTab => (this.currentTab = currentTab) }, h("div", { class: "s-rating-modal-product" }, this.allowAttachImages && this.loyaltyPointsNote(), h("div", { class: "rating-outer-form", "data-stars-error": salla.lang.get('pages.rating.rate_product_stars') }, h("div", { class: "s-rating-modal-product-details" }, h("div", { class: "s-rating-modal-product-info-row" }, h("div", { class: "s-rating-modal-product-img-wrap" }, h("img", { src: this.editItem.product.image.url, alt: this.editItem.product.name, class: "s-rating-modal-product-img" })), h("h3", { class: "s-rating-modal-product-title" }, this.editItem.product.name)), this.renderProductReviewFactors(this.editItem.product.id, 0, {
1003
1033
  fieldPrefix: '',
1004
1034
  mainRating: this.editMainRating ?? Number(this.editItem.stars ?? this.editItem.rating),
1005
1035
  factorRatings: this.editFactorRatings,
@@ -1,17 +1,17 @@
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';
5
- import { S as Star } from './star-CeFAfcTv.js';
6
- import { S as ShippingFast } from './shipping-fast-lMgMt31Q.js';
4
+ import { r as registerInstance, h, H as Host, a as getElement } from './index-BPOLfGlq.js';
5
+ import { a as anime } from './anime.es-CgtvEd63.js';
7
6
  import { C as CheckCircle2 } from './check-circle2-BV4kqbdL.js';
8
- import { H as Helper } from './Helper-BQ9mvrt9.js';
9
7
  import { I as ImageIcon } from './image-C-tzSDxw.js';
10
- import { W as WhatsappIcon } from './whatsapp2-CgR-T_ZS.js';
11
8
  import { e as email } from './mail-DzAIgzdz.js';
12
- import { a as anime } from './anime.es-CgtvEd63.js';
9
+ import { S as ShippingFast } from './shipping-fast-lMgMt31Q.js';
10
+ import { S as Star } from './star-CeFAfcTv.js';
11
+ import { W as WhatsappIcon } from './whatsapp2-CgR-T_ZS.js';
12
+ import { H as Helper } from './Helper-BQ9mvrt9.js';
13
13
 
14
- const sallaRatingModalCss = ".s-rating-modal-product-details{padding-bottom:0.5rem}.s-rating-modal-comment{margin-top:0.35rem}.s-rating-modal-product{margin-bottom:1rem}.s-rating-modal-product-img{display:block;width:100%;height:100%;object-fit:cover}.s-rating-modal-product-title{font-size:0.95rem;font-weight:600;line-height:1.5;margin:0}.s-rating-modal-stars-product{margin-top:0.5rem}.s-rating-modal-product-details-main{display:flex;align-items:center;margin-bottom:0.5rem;padding-bottom:0;border-bottom:0}.s-rating-modal-product-info-row{display:flex;align-items:center;gap:0.6rem;margin-bottom:0.5rem;padding-bottom:0;border-bottom:0}.s-rating-modal-product-main-review{width:100%;text-align:right}.s-rating-modal-product-rating-rows{display:grid;gap:0.45rem;margin:0.2rem 0 0.7rem}.s-rating-modal-product-rating-row{display:flex;align-items:center;justify-content:space-between;gap:0.75rem;min-height:2rem}.s-rating-modal-product-rating-row salla-rating-stars{flex-shrink:0}.s-rating-modal-product-rating-row .s-rating-stars-wrapper{align-items:center;min-height:1.75rem}.s-rating-modal-product-rating-row .s-rating-stars-label,.s-rating-modal-product-rating-row .s-rating-stars-label-without-tag{min-width:auto;min-height:1.25rem;line-height:1.25rem;font-size:0.8rem;color:#5b6470;white-space:nowrap;text-align:end;transition:opacity 0.15s ease}.s-rating-modal-product-rating-row .s-rating-stars-label--empty,.s-rating-modal-product-rating-row .s-rating-stars-label-without-tag--empty{opacity:0}.s-rating-modal-product-rating-row-main{margin-bottom:0.35rem;padding:0.5rem 0.6rem;border:1px solid #d1d5db;border-radius:0.45rem;background:transparent}.s-rating-modal-product-factor-name{color:#5b6470;font-size:0.9rem;line-height:1.25}.s-rating-modal-product-rating-row-main .s-rating-modal-product-factor-name{font-size:1rem;color:#5b6470}.s-rating-modal-product-factor-required{color:#f87171;margin-inline-start:0.2rem}.s-rating-modal-product-img-wrap{width:5rem;min-width:5rem;height:3.5rem;flex-shrink:0;overflow:hidden;border-radius:0.375rem;background:#f3f4f6}.s-rating-modal-uploader.is-opened{height:auto !important;opacity:1 !important;overflow:visible !important;pointer-events:auto !important;margin-bottom:1rem}";
14
+ const sallaRatingModalCss = ".s-rating-modal-product-details{padding-bottom:0.5rem}.s-rating-modal-comment{margin-top:0.35rem}.s-rating-modal-product{margin-bottom:1rem}.s-rating-modal-product-img{display:block;width:100%;height:100%;object-fit:cover}.s-rating-modal-product-title{font-size:0.95rem;font-weight:600;line-height:1.5;margin:0}.s-rating-modal-stars-product{margin-top:0.5rem}.s-rating-modal-loyalty-points-note-container{display:flex;align-items:center;gap:0.625rem;width:100%;margin-top:1.5rem;margin-bottom:0.75rem;padding:0.75rem;border-radius:0.5rem;background-color:#E6F4EA}.s-rating-modal-loyalty-points-note-icon{display:flex;flex-shrink:0;align-items:center;justify-content:center;width:1.25rem;height:1.25rem;color:#1B7F5C}.s-rating-modal-loyalty-points-note-icon svg{width:1.5rem;height:1.5rem;fill:currentColor}.s-rating-modal-loyalty-points-note-text{flex:1;margin:0;font-size:0.875rem;line-height:1.25rem;color:#1f2937}.s-rating-modal-product-details-main{display:flex;align-items:center;margin-bottom:0.5rem;padding-bottom:0;border-bottom:0}.s-rating-modal-product-info-row{display:flex;align-items:center;gap:0.6rem;margin-bottom:0.5rem;padding-bottom:0;border-bottom:0}.s-rating-modal-product-main-review{width:100%;text-align:right}.s-rating-modal-product-rating-rows{display:grid;gap:0.45rem;margin:0.2rem 0 0.7rem}.s-rating-modal-product-rating-row{display:flex;align-items:center;justify-content:space-between;gap:0.75rem;min-height:2rem}.s-rating-modal-product-rating-row salla-rating-stars{flex-shrink:0}.s-rating-modal-product-rating-row .s-rating-stars-wrapper{align-items:center;min-height:1.75rem}.s-rating-modal-product-rating-row .s-rating-stars-label,.s-rating-modal-product-rating-row .s-rating-stars-label-without-tag{min-width:auto;min-height:1.25rem;line-height:1.25rem;font-size:0.8rem;color:#5b6470;white-space:nowrap;text-align:end;transition:opacity 0.15s ease}.s-rating-modal-product-rating-row .s-rating-stars-label--empty,.s-rating-modal-product-rating-row .s-rating-stars-label-without-tag--empty{opacity:0}.s-rating-modal-product-rating-row-main{margin-bottom:0.35rem;padding:0.5rem 0.6rem;border:1px solid #d1d5db;border-radius:0.45rem;background:transparent}.s-rating-modal-product-factor-name{color:#5b6470;font-size:0.9rem;line-height:1.25}.s-rating-modal-product-rating-row-main .s-rating-modal-product-factor-name{font-size:1rem;color:#5b6470}.s-rating-modal-product-factor-required{color:#f87171;margin-inline-start:0.2rem}.s-rating-modal-product-img-wrap{width:5rem;min-width:5rem;height:3.5rem;flex-shrink:0;overflow:hidden;border-radius:0.375rem;background:#f3f4f6}.s-rating-modal-uploader.is-opened{height:auto !important;opacity:1 !important;overflow:visible !important;pointer-events:auto !important;margin-bottom:1rem}";
15
15
 
16
16
  const SallaRatingModal = class {
17
17
  constructor(hostRef) {
@@ -27,6 +27,7 @@ const SallaRatingModal = class {
27
27
  this.deleteMode = false;
28
28
  this.shouldOpenDeleteModal = false;
29
29
  this.editItem = null;
30
+ this.loyaltyImageRatingPoints = 0;
30
31
  this.enableNewPopUp = false;
31
32
  this.dragAndDropFilesLabel = salla.lang.get('common.uploader.drag_and_drop_files');
32
33
  this.contactSubjectLabel = salla.lang.get('pages.rating.contact_subject');
@@ -42,6 +43,7 @@ const SallaRatingModal = class {
42
43
  this.updatedSuccessfullyLabel = salla.lang.get("pages.rating.review_updated_successfully");
43
44
  this.deletedSuccessfullyLabel = salla.lang.get("pages.rating.review_deleted_successfully");
44
45
  this.contactUsLabel = salla.lang.get('blocks.footer.social');
46
+ this.loyaltyPointsForImagesLabel = salla.lang.get('pages.rating.loyalty_points_for_images', { points: ':points' });
45
47
  this.allowAttachImages = salla.config.get('store.settings.rating.allow_attach_images');
46
48
  this.allowContactSupport = salla.config.get('store.settings.rating.allow_contact_support');
47
49
  this.contentRefs = [];
@@ -116,6 +118,8 @@ const SallaRatingModal = class {
116
118
  await setNestedAsync('en.trans', 'pages.rating.review_deleted_successfully', 'The review has been successfully deleted.');
117
119
  await setNestedAsync('ar.trans', 'pages.rating.images_count', 'الصور ( :current من أصل :total )');
118
120
  await setNestedAsync('en.trans', 'pages.rating.images_count', 'Images ( :current of :total )');
121
+ await setNestedAsync('ar.trans', 'pages.rating.loyalty_points_for_images', 'اكسب :points نقطة ولاء عند إضافة صور لتقييمك!');
122
+ await setNestedAsync('en.trans', 'pages.rating.loyalty_points_for_images', 'Earn :points loyalty points when adding photos to your review!');
119
123
  await setNestedAsync('ar.trans', 'common.uploader.max_three_images', `.أضف ${this.MAX_UPLOAD_LIMIT} صور كحد أقصى`);
120
124
  await setNestedAsync('en.trans', 'common.uploader.max_three_images', `Add up to ${this.MAX_UPLOAD_LIMIT} images maximum.`);
121
125
  await setNestedAsync('ar.trans', 'common.elements.confirm_delete', 'تأكيد الحذف');
@@ -133,6 +137,7 @@ const SallaRatingModal = class {
133
137
  this.updatedSuccessfullyLabel = salla.lang.get("pages.rating.review_updated_successfully");
134
138
  this.deletedSuccessfullyLabel = salla.lang.get("pages.rating.review_deleted_successfully");
135
139
  this.confirmDeleteBtn = salla.lang.get("common.elements.confirm_delete");
140
+ this.loyaltyPointsForImagesLabel = salla.lang.get('pages.rating.loyalty_points_for_images', { points: ':points' });
136
141
  this.contact_body = (store, id, customer) => salla.lang.get('pages.rating.contact_body', { store, id, customer });
137
142
  };
138
143
  setTranslations();
@@ -157,6 +162,7 @@ const SallaRatingModal = class {
157
162
  return new Promise((resolve) => {
158
163
  setTimeout(() => {
159
164
  this.modal.open().then(() => this.order || salla.api.withoutNotifier(() => salla.rating.api.order(this.orderId ? this.orderId : salla.config.get('page.id'))).then(res => this.order = res.data))
165
+ .then(() => this.readyUpLoyaltyPoints())
160
166
  .then(() => this.modal.setTitle(`${salla.lang.get('pages.rating.rate_order')} <span class="unicode">(#${this.order.id})</span>`))
161
167
  .then(() => {
162
168
  // Initialize productImages for all products
@@ -193,6 +199,7 @@ const SallaRatingModal = class {
193
199
  this.editFeedbackId = params.feedback_id;
194
200
  try {
195
201
  await this.fetchEditItem(params.feedback_id);
202
+ await this.readyUpLoyaltyPoints();
196
203
  this.editModal.open();
197
204
  }
198
205
  catch (e) {
@@ -397,6 +404,24 @@ const SallaRatingModal = class {
397
404
  this.editMode = false;
398
405
  this.deleteMode = false;
399
406
  this.defaultMode = false;
407
+ this.loyaltyImageRatingPoints = 0;
408
+ }
409
+ async readyUpLoyaltyPoints() {
410
+ const featureEnabled = salla.loyalty?.isFeatureEnabled?.();
411
+ if (!featureEnabled) {
412
+ this.loyaltyImageRatingPoints = 0;
413
+ return;
414
+ }
415
+ const rating_product_points = salla.config.get('store.settings.rating.rating_product_points') || 0;
416
+ const rating_product_with_image_points = salla.config.get('store.settings.rating.rating_product_with_image_points') || 0;
417
+ this.loyaltyImageRatingPoints = Number(rating_product_with_image_points) + Number(rating_product_points);
418
+ }
419
+ loyaltyPointsNote() {
420
+ if (!this.loyaltyImageRatingPoints || !this.loyaltyPointsForImagesLabel) {
421
+ return null;
422
+ }
423
+ const svgIcon = (h("svg", { width: "17", height: "17", viewBox: "0 0 17 17", fill: "none", xmlns: "http://www.w3.org/2000/svg" }, h("path", { d: "M10 0C13.6819 0 16.6667 2.98477 16.6667 6.66664C16.6667 9.37047 15.057 11.6984 12.7437 12.7444C11.6978 15.0575 9.3701 16.6666 6.66668 16.6666C2.98477 16.6666 0 13.6819 0 9.99998C0 7.29656 1.60918 4.96894 3.92195 3.92276C4.96827 1.60964 7.29618 0 10 0ZM6.66668 5C3.90524 5 1.66667 7.23856 1.66667 9.99998C1.66667 12.7614 3.90524 15 6.66668 15C9.4281 15 11.6667 12.7614 11.6667 9.99998C11.6667 7.23856 9.4281 5 6.66668 5ZM7.50002 5.83333V6.66664H9.16668V8.33331H5.83333C5.60322 8.33331 5.41667 8.51989 5.41667 8.74998C5.41667 8.95456 5.56407 9.12464 5.75844 9.15998L5.83333 9.16664H7.50002C8.6506 9.16664 9.58335 10.0994 9.58335 11.25C9.58335 12.4006 8.6506 13.3333 7.50002 13.3333V14.1666H5.83333V13.3333H4.16667V11.6666H7.50002C7.7301 11.6666 7.91668 11.4801 7.91668 11.25C7.91668 11.0455 7.76927 10.8753 7.57493 10.8401L7.50002 10.8333H5.83333C4.68274 10.8333 3.75 9.90056 3.75 8.74998C3.75 7.59939 4.68274 6.66664 5.83333 6.66664V5.83333H7.50002ZM10 1.66667C8.51377 1.66667 7.17893 2.31513 6.26313 3.34457C6.39704 3.33736 6.53138 3.33333 6.66668 3.33333C10.3486 3.33333 13.3333 6.3181 13.3333 9.99998C13.3333 10.1356 13.3293 10.2702 13.3213 10.4037C14.3513 9.48814 15 8.15314 15 6.66664C15 3.90524 12.7614 1.66667 10 1.66667Z", fill: "#008C56" })));
424
+ return (h("div", { class: "s-rating-modal-loyalty-points-note-container" }, h("span", { class: "s-rating-modal-loyalty-points-note-icon" }, svgIcon), h("p", { class: "s-rating-modal-loyalty-points-note-text" }, this.loyaltyPointsForImagesLabel.replace(':points', String(this.loyaltyImageRatingPoints)))));
400
425
  }
401
426
  getDeleteModal() {
402
427
  return (h("salla-modal", { ref: modal => this.deleteModal = modal, width: "xs", onModalVisibilityChanged: (isOpen) => this.resetData(isOpen) }, h("div", { class: "s-rating-modal-delete-wrapper", ref: el => this.body = el }, h("h3", null, this.confirmDeletionLabel), h("p", null, this.areYouSureLabel), h("div", { class: "s-rating-modal-delete-actions" }, h("salla-button", { loaderPosition: 'center', onClick: () => this.deleteReview() }, this.confirmDeleteBtn), h("salla-button", { color: 'danger', fill: 'outline', onClick: () => this.deleteModal.close() }, this.cancelLabel)))));
@@ -409,7 +434,7 @@ const SallaRatingModal = class {
409
434
  getEditModal() {
410
435
  return (h("salla-modal", { ref: modal => this.editModal = modal, width: "md", onModalVisibilityChanged: (isOpen) => this.resetData(isOpen) }, h("div", { class: "s-rating-modal-edit-wrapper", ref: el => this.body = el }, this.editType === "store" && this.editItem ? (h("div", { class: "rating-outer-form s-rating-modal-step-wrap s-rating-modal-step", "data-type": "store", ref: currentTab => this.currentTab = currentTab }, h("div", { class: "s-rating-modal-rounded-icon" }, h("img", { src: salla.config.get('store.logo', 'https://assets.salla.sa/cp/assets/images/logo-new.png'), alt: "store name", class: "s-rating-modal-store-logo" })), h("h2", { class: "s-rating-modal-title" }, salla.lang.get('pages.rating.rate_the_store')), h("div", { class: "s-rating-modal-stars-company" }, h("salla-rating-stars", { withLabel: true, size: "large", editable: true, value: this.editItem.stars })), h("textarea", { name: "content", value: this.editItem.content, class: "s-rating-modal-comment", placeholder: salla.lang.get('pages.rating.write_store_rate') }), h("small", { class: "s-rating-modal-validation-msg" }))) : null, this.editType === "shipping" && this.editItem ? (h("div", { class: "rating-outer-form s-rating-modal-step-wrap s-rating-modal-step", "data-type": "shipping", ref: currentTab => this.currentTab = currentTab }, this.editItem.shipping.logo
411
436
  ? h("div", { class: "s-rating-modal-rounded-icon" }, h("img", { src: this.editItem.shipping.logo, class: "s-rating-modal-shipping-logo", alt: this.editItem.shipping.name }))
412
- : h("span", { class: "s-rating-modal-icon", innerHTML: ShippingFast }), h("div", { class: "s-rating-modal-title" }, " ", `${salla.lang.get('pages.rating.rate_shipping')} ${this.editItem.shipping.name}`), h("div", { class: "s-rating-modal-stars-company" }, h("salla-rating-stars", { withLabel: true, size: "large", editable: true, value: this.editItem.stars })), h("textarea", { name: "content", class: "s-rating-modal-comment", value: this.editItem.content, placeholder: salla.lang.get('pages.rating.write_shipping_rate') }), h("small", { class: "s-rating-modal-validation-msg" }))) : null, this.editType == "product" && this.editItem ? h("section", { class: "s-rating-modal-step", "data-type": "products", ref: currentTab => this.currentTab = currentTab }, h("div", { class: "s-rating-modal-product" }, h("div", { class: "rating-outer-form", "data-stars-error": salla.lang.get('pages.rating.rate_product_stars') }, h("div", { class: "s-rating-modal-product-img-wrap" }, h("img", { src: this.editItem.product.image.url, alt: this.editItem.product.name, class: "s-rating-modal-product-img" })), h("div", { class: "s-rating-modal-product-details" }, h("div", { class: "s-rating-modal-product-details-main" }, h("div", null, h("h3", { class: "s-rating-modal-product-title" }, " ", this.editItem.product.name), h("div", { class: "s-rating-modal-stars-product" }, h("salla-rating-stars", { withLabel: true, size: "small", editable: true, value: this.editItem.stars }))), this.allowAttachImages && h("salla-button", { class: "s-comments-item-like-btn mt-0", loaderPosition: 'center', fill: 'outline', size: 'small', onClick: () => this.toggleUploader(1) }, h("span", null, this.editItemImages.length ? this.editImagesLabel : this.addImagesLabel), h("span", { innerHTML: ImageIcon }))), h("textarea", { value: this.editItem.content, placeholder: salla.lang.get('pages.rating.write_product_rate'), name: "content", class: "s-rating-modal-comment" }), h("small", { class: "s-rating-modal-validation-msg" }))), this.allowAttachImages && (h("div", { class: "s-rating-modal-uploader is-closed", ref: (el) => (this.contentRefs[1] = el) }, h("salla-file-upload", { name: "images", allowMultiple: true, maxFilesCount: this.MAX_UPLOAD_LIMIT, imagePreviewHeight: 117, filePosterHeight: 117, "instant-upload": true, type: "feedback", files: JSON.stringify(this.editItemImages), payloadName: "files[]", id: `file-${this.editItem.product.id}`, title: this.editItem.product.name, instantUpload: true, accept: "image/png, image/jpeg, image/jpg", url: salla.url.api('upload'), onUploaded: (e) => {
437
+ : h("span", { class: "s-rating-modal-icon", innerHTML: ShippingFast }), h("div", { class: "s-rating-modal-title" }, " ", `${salla.lang.get('pages.rating.rate_shipping')} ${this.editItem.shipping.name}`), h("div", { class: "s-rating-modal-stars-company" }, h("salla-rating-stars", { withLabel: true, size: "large", editable: true, value: this.editItem.stars })), h("textarea", { name: "content", class: "s-rating-modal-comment", value: this.editItem.content, placeholder: salla.lang.get('pages.rating.write_shipping_rate') }), h("small", { class: "s-rating-modal-validation-msg" }))) : null, this.editType == "product" && this.editItem ? h("section", { class: "s-rating-modal-step", "data-type": "products", ref: currentTab => this.currentTab = currentTab }, h("div", { class: "s-rating-modal-product" }, this.allowAttachImages && this.loyaltyPointsNote(), h("div", { class: "rating-outer-form", "data-stars-error": salla.lang.get('pages.rating.rate_product_stars') }, h("div", { class: "s-rating-modal-product-img-wrap" }, h("img", { src: this.editItem.product.image.url, alt: this.editItem.product.name, class: "s-rating-modal-product-img" })), h("div", { class: "s-rating-modal-product-details" }, h("div", { class: "s-rating-modal-product-details-main" }, h("div", null, h("h3", { class: "s-rating-modal-product-title" }, " ", this.editItem.product.name), h("div", { class: "s-rating-modal-stars-product" }, h("salla-rating-stars", { withLabel: true, size: "small", editable: true, value: this.editItem.stars }))), this.allowAttachImages && h("salla-button", { class: "s-comments-item-like-btn mt-0", loaderPosition: 'center', fill: 'outline', size: 'small', onClick: () => this.toggleUploader(1) }, h("span", null, this.editItemImages.length ? this.editImagesLabel : this.addImagesLabel), h("span", { innerHTML: ImageIcon }))), h("textarea", { value: this.editItem.content, placeholder: salla.lang.get('pages.rating.write_product_rate'), name: "content", class: "s-rating-modal-comment" }), h("small", { class: "s-rating-modal-validation-msg" }))), this.allowAttachImages && (h("div", { class: "s-rating-modal-uploader is-closed", ref: (el) => (this.contentRefs[1] = el) }, h("salla-file-upload", { name: "images", allowMultiple: true, maxFilesCount: this.MAX_UPLOAD_LIMIT, imagePreviewHeight: 117, filePosterHeight: 117, "instant-upload": true, type: "feedback", files: JSON.stringify(this.editItemImages), payloadName: "files[]", id: `file-${this.editItem.product.id}`, title: this.editItem.product.name, instantUpload: true, accept: "image/png, image/jpeg, image/jpg", url: salla.url.api('upload'), onUploaded: (e) => {
413
438
  this.editItemImages = [...this.editItemImages, e.detail];
414
439
  this.hiddenInputs[1].value = this.editItemImages.map(img => img.url).join();
415
440
  }, onRemoved: (e) => {
@@ -436,7 +461,7 @@ const SallaRatingModal = class {
436
461
  ? [h("div", { class: "s-rating-modal-wrapper", ref: el => this.body = el }, this.order?.testimonials_enabled ?
437
462
  h("div", { class: "rating-outer-form s-rating-modal-step-wrap s-rating-modal-step s-rating-modal-hidden", "data-type": "store" }, h("div", { class: "s-rating-modal-rounded-icon" }, h("img", { src: salla.config.get('store.logo', 'https://assets.salla.sa/cp/assets/images/logo-new.png'), alt: "store name", class: "s-rating-modal-store-logo" })), h("h2", { class: "s-rating-modal-title" }, salla.lang.get('pages.rating.rate_the_store')), h("div", { class: "s-rating-modal-stars-company" }, h("salla-rating-stars", { withLabel: true, size: "large" })), h("textarea", { name: "comment", class: "s-rating-modal-comment", placeholder: salla.lang.get('pages.rating.write_store_rate') }), h("small", { class: "s-rating-modal-validation-msg" }))
438
463
  : '', this.order.products_enabled
439
- ? h("section", { class: "s-rating-modal-step s-rating-modal-hidden", "data-type": "products" }, this.order.products.map((item, index) => h("div", { class: "s-rating-modal-product", key: index }, h("div", { class: "rating-outer-form", "data-stars-error": salla.lang.get('pages.rating.rate_product_stars') }, h("div", { class: "s-rating-modal-product-img-wrap" }, h("img", { src: item.product.thumbnail, alt: item.product.name, class: "s-rating-modal-product-img" })), h("div", { class: "s-rating-modal-product-details" }, h("div", { class: "s-rating-modal-product-details-main" }, h("div", null, h("h3", { class: "s-rating-modal-product-title" }, " ", item.product.name), h("div", { class: "s-rating-modal-stars-product" }, h("salla-rating-stars", { withLabel: true, size: "small", name: `products[${index}][rating]` }))), this.allowAttachImages && h("salla-button", { class: "s-comments-item-like-btn mt-0", loaderPosition: 'center', fill: 'outline', size: 'small', onClick: () => this.toggleUploader(index) }, h("span", null, this.addImagesLabel), h("span", { innerHTML: ImageIcon }))), h("input", { type: "hidden", name: `products[${index}][product_id]`, value: item.product.id }), h("textarea", { placeholder: salla.lang.get('pages.rating.write_product_rate'), name: `products[${index}][comment]`, class: "s-rating-modal-comment" }), h("small", { class: "s-rating-modal-validation-msg" }))), this.allowAttachImages && (h("div", { class: "s-rating-modal-uploader is-closed", ref: (el) => (this.contentRefs[index] = el) }, h("salla-file-upload", { name: "image", maxFilesCount: this.MAX_UPLOAD_LIMIT, imagePreviewHeight: 117, "instant-upload": true, type: "feedback", payloadName: "files[]", id: `file-${item.product.id}`, title: item.product.name, allowMultiple: true, instantUpload: true, accept: "image/png, image/jpeg, image/jpg", url: salla.url.api('upload'), onUploaded: (e) => {
464
+ ? h("section", { class: "s-rating-modal-step s-rating-modal-hidden", "data-type": "products" }, this.allowAttachImages && this.loyaltyPointsNote(), this.order.products.map((item, index) => h("div", { class: "s-rating-modal-product", key: index }, h("div", { class: "rating-outer-form", "data-stars-error": salla.lang.get('pages.rating.rate_product_stars') }, h("div", { class: "s-rating-modal-product-img-wrap" }, h("img", { src: item.product.thumbnail, alt: item.product.name, class: "s-rating-modal-product-img" })), h("div", { class: "s-rating-modal-product-details" }, h("div", { class: "s-rating-modal-product-details-main" }, h("div", null, h("h3", { class: "s-rating-modal-product-title" }, " ", item.product.name), h("div", { class: "s-rating-modal-stars-product" }, h("salla-rating-stars", { withLabel: true, size: "small", name: `products[${index}][rating]` }))), this.allowAttachImages && h("salla-button", { class: "s-comments-item-like-btn mt-0", loaderPosition: 'center', fill: 'outline', size: 'small', onClick: () => this.toggleUploader(index) }, h("span", null, this.addImagesLabel), h("span", { innerHTML: ImageIcon }))), h("input", { type: "hidden", name: `products[${index}][product_id]`, value: item.product.id }), h("textarea", { placeholder: salla.lang.get('pages.rating.write_product_rate'), name: `products[${index}][comment]`, class: "s-rating-modal-comment" }), h("small", { class: "s-rating-modal-validation-msg" }))), this.allowAttachImages && (h("div", { class: "s-rating-modal-uploader is-closed", ref: (el) => (this.contentRefs[index] = el) }, h("salla-file-upload", { name: "image", maxFilesCount: this.MAX_UPLOAD_LIMIT, imagePreviewHeight: 117, "instant-upload": true, type: "feedback", payloadName: "files[]", id: `file-${item.product.id}`, title: item.product.name, allowMultiple: true, instantUpload: true, accept: "image/png, image/jpeg, image/jpg", url: salla.url.api('upload'), onUploaded: (e) => {
440
465
  this.productImages = {
441
466
  ...this.productImages,
442
467
  [item.product.id]: [...(this.productImages[item.product.id] || []), e.detail]
@@ -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-BPOLfGlq.js';
5
5
  import { S as Star } from './star2-D4oPi1Ov.js';
6
6
 
7
7
  const CACHE_TTL = 5 * 60 * 1000;
@@ -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-BPOLfGlq.js';
5
5
  import { S as Search } from './search-BscTeWDc.js';
6
6
 
7
7
  var StoreAlt = `<!-- Generated by IcoMoon.io -->
@@ -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-BPOLfGlq.js';
5
5
  import { S as Search } from './search-BscTeWDc.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-BPOLfGlq.js';
5
5
 
6
6
  const sallaSkeletonCss = ":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-BPOLfGlq.js';
5
5
  import { a as ArrowRightIcon, A as ArrowLeftIcon } from './keyboard_arrow_right-Vqpj4CWE.js';
6
6
 
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-BPOLfGlq.js';
5
5
  import { a as anime } from './anime.es-CgtvEd63.js';
6
6
  import { f as facebook, t as twitter } from './facebook-CO-PeZ27.js';
7
7
  import { e as email } from './mail-DzAIgzdz.js';