@salla.sa/twilight-components 2.14.574 → 2.14.576

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 (348) hide show
  1. package/dist/cjs/{filepond-BqzmHqFG.js → filepond-pMiRtx1x.js} +1 -1
  2. package/dist/cjs/{filepond-plugin-file-poster-Rc_hYm4g.js → filepond-plugin-file-poster-DxsZ8Mch.js} +1 -1
  3. package/dist/cjs/{filepond-plugin-file-validate-size-MQOyXwCH.js → filepond-plugin-file-validate-size-B6fa4wXz.js} +1 -1
  4. package/dist/cjs/{filepond-plugin-file-validate-type-0_gq-gig.js → filepond-plugin-file-validate-type-BEggFpci.js} +1 -1
  5. package/dist/cjs/{filepond-plugin-image-edit-DjWvYOF_.js → filepond-plugin-image-edit-BDwSySal.js} +1 -1
  6. package/dist/cjs/{filepond-plugin-image-exif-orientation-BGNpJuyh.js → filepond-plugin-image-exif-orientation-HE8n94tY.js} +1 -1
  7. package/dist/cjs/{filepond-plugin-image-preview-BoPR2rRr.js → filepond-plugin-image-preview-C-CaMrlm.js} +1 -1
  8. package/dist/cjs/{index-BGm5j5Zj.js → index-B3IyDlYG.js} +2 -2
  9. package/dist/cjs/{intlTelInput-CIZvknP0.js → intlTelInput-CeiHZwpn.js} +1 -1
  10. package/dist/cjs/loader.cjs.js +2 -2
  11. package/dist/cjs/salla-accordion-body_2.cjs.entry.js +1 -1
  12. package/dist/cjs/salla-accordion_6.cjs.entry.js +1 -1
  13. package/dist/cjs/salla-add-product-button_5.cjs.entry.js +1 -1
  14. package/dist/cjs/salla-advertisement.cjs.entry.js +1 -1
  15. package/dist/cjs/salla-alert_2.cjs.entry.js +1 -1
  16. package/dist/cjs/salla-app-install-alert.cjs.entry.js +1 -1
  17. package/dist/cjs/salla-applied-filters.cjs.entry.js +1 -1
  18. package/dist/cjs/salla-apps-icons.cjs.entry.js +1 -1
  19. package/dist/cjs/salla-attachment-view_9.cjs.entry.js +10 -10
  20. package/dist/cjs/salla-badge.cjs.entry.js +1 -1
  21. package/dist/cjs/salla-basket-gap.cjs.entry.js +1 -1
  22. package/dist/cjs/salla-bullet-delivery_3.cjs.entry.js +1 -1
  23. package/dist/cjs/salla-cart-coupons.cjs.entry.js +1 -1
  24. package/dist/cjs/salla-cart-item-offers_2.cjs.entry.js +1 -1
  25. package/dist/cjs/salla-cart-summary-card.cjs.entry.js +1 -1
  26. package/dist/cjs/salla-cashback-banner.cjs.entry.js +1 -1
  27. package/dist/cjs/salla-comment-factors.cjs.entry.js +1 -1
  28. package/dist/cjs/salla-comment-form_9.cjs.entry.js +1 -1
  29. package/dist/cjs/salla-conditional-offer.cjs.entry.js +1 -1
  30. package/dist/cjs/salla-contacts.cjs.entry.js +1 -1
  31. package/dist/cjs/salla-cookies-bar.cjs.entry.js +1 -1
  32. package/dist/cjs/salla-count-down.cjs.entry.js +1 -1
  33. package/dist/cjs/salla-custom-fields.cjs.entry.js +1 -1
  34. package/dist/cjs/salla-delivery-promise.cjs.entry.js +1 -1
  35. package/dist/cjs/salla-edit-order-button.cjs.entry.js +1 -1
  36. package/dist/cjs/salla-filters-widget.cjs.entry.js +1 -1
  37. package/dist/cjs/salla-filters.cjs.entry.js +1 -1
  38. package/dist/cjs/salla-fulfillment-methods.cjs.entry.js +1 -1
  39. package/dist/cjs/salla-gift-card-redeem.cjs.entry.js +1 -1
  40. package/dist/cjs/salla-gifting.cjs.entry.js +1 -1
  41. package/dist/cjs/salla-hook.cjs.entry.js +1 -1
  42. package/dist/cjs/salla-infinite-scroll.cjs.entry.js +1 -1
  43. package/dist/cjs/salla-installment.cjs.entry.js +1 -1
  44. package/dist/cjs/salla-list-tile.cjs.entry.js +1 -1
  45. package/dist/cjs/salla-localization-modal.cjs.entry.js +1 -1
  46. package/dist/cjs/salla-login-modal.cjs.entry.js +1 -1
  47. package/dist/cjs/salla-loyalty-banner_10.cjs.entry.js +1 -1
  48. package/dist/cjs/salla-loyalty-exchange-product-card.cjs.entry.js +1 -1
  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.cjs.entry.js +1 -1
  53. package/dist/cjs/salla-maintenance-alert.cjs.entry.js +1 -1
  54. package/dist/cjs/salla-map_3.cjs.entry.js +1 -1
  55. package/dist/cjs/salla-menu.cjs.entry.js +1 -1
  56. package/dist/cjs/salla-metadata.cjs.entry.js +1 -1
  57. package/dist/cjs/salla-multiple-bundle-product-cart_2.cjs.entry.js +1 -1
  58. package/dist/cjs/salla-multiple-bundle-product-options-modal_2.cjs.entry.js +1 -1
  59. package/dist/cjs/salla-multiple-bundle-product.cjs.entry.js +1 -1
  60. package/dist/cjs/salla-next-order-coupon.cjs.entry.js +1 -1
  61. package/dist/cjs/salla-notification-item_2.cjs.entry.js +1 -1
  62. package/dist/cjs/salla-offer-modal.cjs.entry.js +30 -4
  63. package/dist/cjs/salla-offer.cjs.entry.js +132 -24
  64. package/dist/cjs/salla-order-branch.cjs.entry.js +1 -1
  65. package/dist/cjs/salla-order-cancel.cjs.entry.js +1 -1
  66. package/dist/cjs/salla-order-details-multiple-bundle-product.cjs.entry.js +1 -1
  67. package/dist/cjs/salla-order-details-options.cjs.entry.js +1 -1
  68. package/dist/cjs/salla-order-details.cjs.entry.js +1 -1
  69. package/dist/cjs/salla-order-edit-item.cjs.entry.js +1 -1
  70. package/dist/cjs/salla-order-edit-product-card.cjs.entry.js +1 -1
  71. package/dist/cjs/salla-order-edit.cjs.entry.js +1 -1
  72. package/dist/cjs/salla-order-options-modal.cjs.entry.js +1 -1
  73. package/dist/cjs/salla-order-shipments.cjs.entry.js +1 -1
  74. package/dist/cjs/salla-order-summary.cjs.entry.js +1 -1
  75. package/dist/cjs/salla-order-totals-card.cjs.entry.js +1 -1
  76. package/dist/cjs/salla-orders.cjs.entry.js +38 -13
  77. package/dist/cjs/salla-payments.cjs.entry.js +1 -1
  78. package/dist/cjs/salla-placeholder.cjs.entry.js +1 -1
  79. package/dist/cjs/salla-price-range.cjs.entry.js +1 -1
  80. package/dist/cjs/salla-product-card-embed.cjs.entry.js +1 -1
  81. package/dist/cjs/salla-product-card.cjs.entry.js +1 -1
  82. package/dist/cjs/salla-product-size-guide.cjs.entry.js +1 -1
  83. package/dist/cjs/salla-products-list.cjs.entry.js +1 -1
  84. package/dist/cjs/salla-products-slider.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-review-order-item.cjs.entry.js +1 -1
  90. package/dist/cjs/salla-scopes.cjs.entry.js +1 -1
  91. package/dist/cjs/salla-search-product-card.cjs.entry.js +1 -1
  92. package/dist/cjs/salla-search.cjs.entry.js +1 -1
  93. package/dist/cjs/salla-skeleton.cjs.entry.js +1 -1
  94. package/dist/cjs/salla-social-share.cjs.entry.js +1 -1
  95. package/dist/cjs/salla-social.cjs.entry.js +1 -1
  96. package/dist/cjs/salla-tab-content_3.cjs.entry.js +1 -1
  97. package/dist/cjs/salla-tiered-offer.cjs.entry.js +1 -1
  98. package/dist/cjs/salla-tooltip.cjs.entry.js +1 -1
  99. package/dist/cjs/salla-trust-badges.cjs.entry.js +1 -1
  100. package/dist/cjs/salla-user-menu.cjs.entry.js +1 -1
  101. package/dist/cjs/salla-user-profile.cjs.entry.js +1 -1
  102. package/dist/cjs/salla-user-settings.cjs.entry.js +1 -1
  103. package/dist/cjs/salla-verify.cjs.entry.js +1 -1
  104. package/dist/cjs/salla-wallet.cjs.entry.js +1 -1
  105. package/dist/cjs/salla-wishlist-actions.cjs.entry.js +1 -1
  106. package/dist/cjs/salla-wishlist-summary.cjs.entry.js +1 -1
  107. package/dist/cjs/translate-BeU1QX_r.js +20 -0
  108. package/dist/cjs/twilight.cjs.js +2 -2
  109. package/dist/cjs/{vanilla-picker-BwaB87Xi.js → vanilla-picker-DBIBI2Jr.js} +1 -1
  110. package/dist/collection/Helpers/translate.js +16 -0
  111. package/dist/collection/components/salla-offer/salla-offer.css +86 -0
  112. package/dist/collection/components/salla-offer/salla-offer.js +135 -22
  113. package/dist/collection/components/salla-offer-modal/salla-offer-modal.css +32 -0
  114. package/dist/collection/components/salla-offer-modal/salla-offer-modal.js +28 -2
  115. package/dist/collection/components/salla-orders/salla-orders.js +39 -12
  116. package/dist/components/index.js +2 -2
  117. package/dist/components/salla-offer-modal.js +29 -3
  118. package/dist/components/salla-offer.js +136 -23
  119. package/dist/components/salla-orders.js +39 -12
  120. package/dist/components/translate.js +18 -0
  121. package/dist/esm/{filepond-DcoYtlMX.js → filepond-C6VyLUVF.js} +1 -1
  122. package/dist/esm/{filepond-plugin-file-poster-CBcS6Ln1.js → filepond-plugin-file-poster-BfFqi2TO.js} +1 -1
  123. package/dist/esm/{filepond-plugin-file-validate-size-HuNTwpc9.js → filepond-plugin-file-validate-size-BBqb56CB.js} +1 -1
  124. package/dist/esm/{filepond-plugin-file-validate-type-BOjEfXdn.js → filepond-plugin-file-validate-type-O67G3mL2.js} +1 -1
  125. package/dist/esm/{filepond-plugin-image-edit-BL7zREI5.js → filepond-plugin-image-edit-CGZyNJxN.js} +1 -1
  126. package/dist/esm/{filepond-plugin-image-exif-orientation-BJgL9era.js → filepond-plugin-image-exif-orientation-DA7fGQP3.js} +1 -1
  127. package/dist/esm/{filepond-plugin-image-preview-DPUJHFk0.js → filepond-plugin-image-preview-BijvA1XW.js} +1 -1
  128. package/dist/esm/{index-BXNtVhVe.js → index-VyEjj_Gx.js} +2 -2
  129. package/dist/esm/{intlTelInput-wU6Kly2g.js → intlTelInput-DE-bT5KJ.js} +1 -1
  130. package/dist/esm/loader.js +3 -3
  131. package/dist/esm/salla-accordion-body_2.entry.js +1 -1
  132. package/dist/esm/salla-accordion_6.entry.js +1 -1
  133. package/dist/esm/salla-add-product-button_5.entry.js +1 -1
  134. package/dist/esm/salla-advertisement.entry.js +1 -1
  135. package/dist/esm/salla-alert_2.entry.js +1 -1
  136. package/dist/esm/salla-app-install-alert.entry.js +1 -1
  137. package/dist/esm/salla-applied-filters.entry.js +1 -1
  138. package/dist/esm/salla-apps-icons.entry.js +1 -1
  139. package/dist/esm/salla-attachment-view_9.entry.js +10 -10
  140. package/dist/esm/salla-badge.entry.js +1 -1
  141. package/dist/esm/salla-basket-gap.entry.js +1 -1
  142. package/dist/esm/salla-bullet-delivery_3.entry.js +1 -1
  143. package/dist/esm/salla-cart-coupons.entry.js +1 -1
  144. package/dist/esm/salla-cart-item-offers_2.entry.js +1 -1
  145. package/dist/esm/salla-cart-summary-card.entry.js +1 -1
  146. package/dist/esm/salla-cashback-banner.entry.js +1 -1
  147. package/dist/esm/salla-comment-factors.entry.js +1 -1
  148. package/dist/esm/salla-comment-form_9.entry.js +1 -1
  149. package/dist/esm/salla-conditional-offer.entry.js +1 -1
  150. package/dist/esm/salla-contacts.entry.js +1 -1
  151. package/dist/esm/salla-cookies-bar.entry.js +1 -1
  152. package/dist/esm/salla-count-down.entry.js +1 -1
  153. package/dist/esm/salla-custom-fields.entry.js +1 -1
  154. package/dist/esm/salla-delivery-promise.entry.js +1 -1
  155. package/dist/esm/salla-edit-order-button.entry.js +1 -1
  156. package/dist/esm/salla-filters-widget.entry.js +1 -1
  157. package/dist/esm/salla-filters.entry.js +1 -1
  158. package/dist/esm/salla-fulfillment-methods.entry.js +1 -1
  159. package/dist/esm/salla-gift-card-redeem.entry.js +1 -1
  160. package/dist/esm/salla-gifting.entry.js +1 -1
  161. package/dist/esm/salla-hook.entry.js +1 -1
  162. package/dist/esm/salla-infinite-scroll.entry.js +1 -1
  163. package/dist/esm/salla-installment.entry.js +1 -1
  164. package/dist/esm/salla-list-tile.entry.js +1 -1
  165. package/dist/esm/salla-localization-modal.entry.js +1 -1
  166. package/dist/esm/salla-login-modal.entry.js +1 -1
  167. package/dist/esm/salla-loyalty-banner_10.entry.js +1 -1
  168. package/dist/esm/salla-loyalty-exchange-product-card.entry.js +1 -1
  169. package/dist/esm/salla-loyalty-points-banner.entry.js +1 -1
  170. package/dist/esm/salla-loyalty-points-history.entry.js +1 -1
  171. package/dist/esm/salla-loyalty-prize-item.entry.js +1 -1
  172. package/dist/esm/salla-loyalty.entry.js +1 -1
  173. package/dist/esm/salla-maintenance-alert.entry.js +1 -1
  174. package/dist/esm/salla-map_3.entry.js +1 -1
  175. package/dist/esm/salla-menu.entry.js +1 -1
  176. package/dist/esm/salla-metadata.entry.js +1 -1
  177. package/dist/esm/salla-multiple-bundle-product-cart_2.entry.js +1 -1
  178. package/dist/esm/salla-multiple-bundle-product-options-modal_2.entry.js +1 -1
  179. package/dist/esm/salla-multiple-bundle-product.entry.js +1 -1
  180. package/dist/esm/salla-next-order-coupon.entry.js +1 -1
  181. package/dist/esm/salla-notification-item_2.entry.js +1 -1
  182. package/dist/esm/salla-offer-modal.entry.js +30 -4
  183. package/dist/esm/salla-offer.entry.js +132 -24
  184. package/dist/esm/salla-order-branch.entry.js +1 -1
  185. package/dist/esm/salla-order-cancel.entry.js +1 -1
  186. package/dist/esm/salla-order-details-multiple-bundle-product.entry.js +1 -1
  187. package/dist/esm/salla-order-details-options.entry.js +1 -1
  188. package/dist/esm/salla-order-details.entry.js +1 -1
  189. package/dist/esm/salla-order-edit-item.entry.js +1 -1
  190. package/dist/esm/salla-order-edit-product-card.entry.js +1 -1
  191. package/dist/esm/salla-order-edit.entry.js +1 -1
  192. package/dist/esm/salla-order-options-modal.entry.js +1 -1
  193. package/dist/esm/salla-order-shipments.entry.js +1 -1
  194. package/dist/esm/salla-order-summary.entry.js +1 -1
  195. package/dist/esm/salla-order-totals-card.entry.js +1 -1
  196. package/dist/esm/salla-orders.entry.js +38 -13
  197. package/dist/esm/salla-payments.entry.js +1 -1
  198. package/dist/esm/salla-placeholder.entry.js +1 -1
  199. package/dist/esm/salla-price-range.entry.js +1 -1
  200. package/dist/esm/salla-product-card-embed.entry.js +1 -1
  201. package/dist/esm/salla-product-card.entry.js +1 -1
  202. package/dist/esm/salla-product-size-guide.entry.js +1 -1
  203. package/dist/esm/salla-products-list.entry.js +1 -1
  204. package/dist/esm/salla-products-slider.entry.js +1 -1
  205. package/dist/esm/salla-quick-order.entry.js +1 -1
  206. package/dist/esm/salla-rating-modal-v2.entry.js +1 -1
  207. package/dist/esm/salla-rating-modal.entry.js +1 -1
  208. package/dist/esm/salla-review-factors-tags.entry.js +1 -1
  209. package/dist/esm/salla-review-order-item.entry.js +1 -1
  210. package/dist/esm/salla-scopes.entry.js +1 -1
  211. package/dist/esm/salla-search-product-card.entry.js +1 -1
  212. package/dist/esm/salla-search.entry.js +1 -1
  213. package/dist/esm/salla-skeleton.entry.js +1 -1
  214. package/dist/esm/salla-social-share.entry.js +1 -1
  215. package/dist/esm/salla-social.entry.js +1 -1
  216. package/dist/esm/salla-tab-content_3.entry.js +1 -1
  217. package/dist/esm/salla-tiered-offer.entry.js +1 -1
  218. package/dist/esm/salla-tooltip.entry.js +1 -1
  219. package/dist/esm/salla-trust-badges.entry.js +1 -1
  220. package/dist/esm/salla-user-menu.entry.js +1 -1
  221. package/dist/esm/salla-user-profile.entry.js +1 -1
  222. package/dist/esm/salla-user-settings.entry.js +1 -1
  223. package/dist/esm/salla-verify.entry.js +1 -1
  224. package/dist/esm/salla-wallet.entry.js +1 -1
  225. package/dist/esm/salla-wishlist-actions.entry.js +1 -1
  226. package/dist/esm/salla-wishlist-summary.entry.js +1 -1
  227. package/dist/esm/translate-CrSV-tno.js +18 -0
  228. package/dist/esm/twilight.js +3 -3
  229. package/dist/esm/{vanilla-picker-CFcUgW74.js → vanilla-picker-BVwvMAEs.js} +1 -1
  230. package/dist/twilight/{p-0d18b6f2.entry.js → p-02df3435.entry.js} +1 -1
  231. package/dist/twilight/{p-bee482ce.entry.js → p-08bcc8c6.entry.js} +1 -1
  232. package/dist/twilight/{p-6fe398ae.entry.js → p-0987a1bf.entry.js} +1 -1
  233. package/dist/twilight/{p-1a4028e2.entry.js → p-09ab0b69.entry.js} +1 -1
  234. package/dist/twilight/{p-c67dcc94.entry.js → p-10da5fab.entry.js} +1 -1
  235. package/dist/twilight/{p-0a135b25.entry.js → p-12bcfd57.entry.js} +1 -1
  236. package/dist/twilight/{p-98137b26.entry.js → p-140bf9e1.entry.js} +1 -1
  237. package/dist/twilight/{p-6210a661.entry.js → p-15fd28e8.entry.js} +1 -1
  238. package/dist/twilight/{p-ab97de5d.entry.js → p-19c39465.entry.js} +1 -1
  239. package/dist/twilight/{p-88f762de.entry.js → p-1b2ce7bb.entry.js} +1 -1
  240. package/dist/twilight/{p-d1520e68.entry.js → p-22efe055.entry.js} +1 -1
  241. package/dist/twilight/{p-4563fd77.entry.js → p-237ee8db.entry.js} +1 -1
  242. package/dist/twilight/{p-a57e299a.entry.js → p-2438d7e1.entry.js} +1 -1
  243. package/dist/twilight/{p-12822eba.entry.js → p-26105855.entry.js} +1 -1
  244. package/dist/twilight/p-29bc507d.entry.js +4 -0
  245. package/dist/twilight/{p-76403e24.entry.js → p-2aa87b3c.entry.js} +1 -1
  246. package/dist/twilight/{p-70147959.entry.js → p-2d43aaae.entry.js} +1 -1
  247. package/dist/twilight/{p-6d56ebac.entry.js → p-354f6595.entry.js} +1 -1
  248. package/dist/twilight/p-370939c2.entry.js +4 -0
  249. package/dist/twilight/{p-fd6aed5e.entry.js → p-38f82c85.entry.js} +1 -1
  250. package/dist/twilight/{p-c5f087a3.entry.js → p-4198d092.entry.js} +1 -1
  251. package/dist/twilight/{p-9f23104d.entry.js → p-47ddfc87.entry.js} +1 -1
  252. package/dist/twilight/{p-e63f5b80.entry.js → p-4abd6abc.entry.js} +1 -1
  253. package/dist/twilight/{p-c0c23759.entry.js → p-4bcf0187.entry.js} +1 -1
  254. package/dist/twilight/{p-9282b995.entry.js → p-55469fd9.entry.js} +1 -1
  255. package/dist/twilight/{p-eccd8aa9.entry.js → p-55afe19f.entry.js} +1 -1
  256. package/dist/twilight/{p-a581c552.entry.js → p-565f021e.entry.js} +1 -1
  257. package/dist/twilight/{p-dedfcc58.entry.js → p-58398f44.entry.js} +1 -1
  258. package/dist/twilight/{p-6665f42e.entry.js → p-63a287b4.entry.js} +1 -1
  259. package/dist/twilight/{p-900f78b6.entry.js → p-63af5354.entry.js} +1 -1
  260. package/dist/twilight/{p-f583571c.entry.js → p-66be47ec.entry.js} +1 -1
  261. package/dist/twilight/{p-38806031.entry.js → p-6c4d3288.entry.js} +1 -1
  262. package/dist/twilight/{p-71ec3f8a.entry.js → p-6d46f977.entry.js} +1 -1
  263. package/dist/twilight/{p-3e7a7eb0.entry.js → p-70577d8b.entry.js} +1 -1
  264. package/dist/twilight/{p-043b2382.entry.js → p-724be00d.entry.js} +1 -1
  265. package/dist/twilight/{p-e50b99cb.entry.js → p-76843521.entry.js} +1 -1
  266. package/dist/twilight/{p-aec3d7ce.entry.js → p-7d4c9e95.entry.js} +1 -1
  267. package/dist/twilight/{p-f48ada4a.entry.js → p-7ef406e5.entry.js} +1 -1
  268. package/dist/twilight/{p-6b378bcd.entry.js → p-7f38bccf.entry.js} +1 -1
  269. package/dist/twilight/{p-e9cc9f4f.entry.js → p-80cf8042.entry.js} +1 -1
  270. package/dist/twilight/{p-b0671070.entry.js → p-82186e1c.entry.js} +1 -1
  271. package/dist/twilight/{p-747153bc.entry.js → p-85a81ddd.entry.js} +1 -1
  272. package/dist/twilight/{p-de3eeec4.entry.js → p-85d5c0b6.entry.js} +1 -1
  273. package/dist/twilight/{p-bd89bcf5.entry.js → p-88918b1b.entry.js} +1 -1
  274. package/dist/twilight/{p-48f47f92.entry.js → p-90033ecc.entry.js} +1 -1
  275. package/dist/twilight/{p-8666489e.entry.js → p-915965eb.entry.js} +1 -1
  276. package/dist/twilight/{p-a0c5bc92.entry.js → p-9417b38b.entry.js} +1 -1
  277. package/dist/twilight/{p-dc9b9ef7.entry.js → p-95494a3d.entry.js} +1 -1
  278. package/dist/twilight/{p-ac2926d9.entry.js → p-9a0ad6b4.entry.js} +1 -1
  279. package/dist/twilight/{p-43124a9d.entry.js → p-9df6ef40.entry.js} +1 -1
  280. package/dist/twilight/{p-78a84f80.entry.js → p-9eebb417.entry.js} +1 -1
  281. package/dist/twilight/{p-6142183b.entry.js → p-9f485845.entry.js} +1 -1
  282. package/dist/twilight/p-BB5KMFvk.js +9 -0
  283. package/dist/twilight/{p-CMcDoqmG.js → p-BZQPZ7Vk.js} +1 -1
  284. package/dist/twilight/{p-BFib9jF0.js → p-BqBflUu5.js} +1 -1
  285. package/dist/twilight/{p-CPkPdW2Q.js → p-CVE_4GIW.js} +1 -1
  286. package/dist/twilight/p-CrSV-tno.js +4 -0
  287. package/dist/twilight/{p-CDojVREu.js → p-Dht_HSXg.js} +2 -2
  288. package/dist/twilight/{p-BpnCDmiM.js → p-DtngMbK9.js} +1 -1
  289. package/dist/twilight/{p-C3JsXKHY.js → p-MofCSty6.js} +1 -1
  290. package/dist/twilight/{p-BXNtVhVe.js → p-VyEjj_Gx.js} +1 -1
  291. package/dist/twilight/{p-COQlWLWv.js → p-XWoqFS1d.js} +1 -1
  292. package/dist/twilight/{p-a34258d2.entry.js → p-a185519a.entry.js} +1 -1
  293. package/dist/twilight/{p-91e4594d.entry.js → p-a291f319.entry.js} +1 -1
  294. package/dist/twilight/{p-52c31b1a.entry.js → p-a2bf4487.entry.js} +1 -1
  295. package/dist/twilight/{p-f4583bb2.entry.js → p-a4ba6008.entry.js} +1 -1
  296. package/dist/twilight/{p-c163a216.entry.js → p-a5dc1d5e.entry.js} +1 -1
  297. package/dist/twilight/{p-987a75aa.entry.js → p-a8f4fa9e.entry.js} +1 -1
  298. package/dist/twilight/{p-e6233f15.entry.js → p-a990b069.entry.js} +1 -1
  299. package/dist/twilight/{p-0bcaa1af.entry.js → p-b06b0973.entry.js} +1 -1
  300. package/dist/twilight/{p-2e08cf78.entry.js → p-b35956cc.entry.js} +1 -1
  301. package/dist/twilight/{p-853b2efe.entry.js → p-b3a36e11.entry.js} +1 -1
  302. package/dist/twilight/{p-90aa29f3.entry.js → p-b7e14e40.entry.js} +1 -1
  303. package/dist/twilight/{p-8f3642d1.entry.js → p-b930b2ba.entry.js} +1 -1
  304. package/dist/twilight/{p-70eaceea.entry.js → p-b9e85434.entry.js} +1 -1
  305. package/dist/twilight/{p-9dfe1ec1.entry.js → p-bb2c9ac9.entry.js} +1 -1
  306. package/dist/twilight/{p-bb0bc7ed.entry.js → p-bb83242c.entry.js} +1 -1
  307. package/dist/twilight/{p-9cca8055.entry.js → p-bc1251f6.entry.js} +1 -1
  308. package/dist/twilight/{p-f174afea.entry.js → p-c032ca19.entry.js} +1 -1
  309. package/dist/twilight/{p-44899fd8.entry.js → p-c1f9932b.entry.js} +1 -1
  310. package/dist/twilight/{p-23540811.entry.js → p-c593919c.entry.js} +1 -1
  311. package/dist/twilight/{p-9979ada5.entry.js → p-c63be3cf.entry.js} +1 -1
  312. package/dist/twilight/{p-817cfe1a.entry.js → p-c6e6daf9.entry.js} +1 -1
  313. package/dist/twilight/{p-d702af41.entry.js → p-c95f4657.entry.js} +1 -1
  314. package/dist/twilight/{p-b11508cb.entry.js → p-ca7cd467.entry.js} +1 -1
  315. package/dist/twilight/{p-9d667925.entry.js → p-cbaa45a4.entry.js} +1 -1
  316. package/dist/twilight/{p-1ea4c8e4.entry.js → p-ceae3b17.entry.js} +1 -1
  317. package/dist/twilight/{p-16b9ea73.entry.js → p-d0445027.entry.js} +1 -1
  318. package/dist/twilight/{p-565eda17.entry.js → p-d4466357.entry.js} +1 -1
  319. package/dist/twilight/{p-8e114c27.entry.js → p-d59a53f5.entry.js} +1 -1
  320. package/dist/twilight/{p-7a099b00.entry.js → p-d5d8230d.entry.js} +1 -1
  321. package/dist/twilight/{p-79f495b7.entry.js → p-d6c4c0f7.entry.js} +1 -1
  322. package/dist/twilight/{p-b0ff401e.entry.js → p-dcba291c.entry.js} +1 -1
  323. package/dist/twilight/{p-bc2203b6.entry.js → p-e2d0eb4c.entry.js} +1 -1
  324. package/dist/twilight/p-e6803d06.entry.js +4 -0
  325. package/dist/twilight/{p-2ee3c58e.entry.js → p-ec378cee.entry.js} +1 -1
  326. package/dist/twilight/{p-b5329852.entry.js → p-f059fb37.entry.js} +1 -1
  327. package/dist/twilight/{p-3ae64529.entry.js → p-f12fc91c.entry.js} +1 -1
  328. package/dist/twilight/{p-d365bd72.entry.js → p-f1d0d4da.entry.js} +1 -1
  329. package/dist/twilight/{p-1853b5ba.entry.js → p-f265b4ea.entry.js} +1 -1
  330. package/dist/twilight/{p-50a88286.entry.js → p-f291fd6b.entry.js} +1 -1
  331. package/dist/twilight/{p-fc0a3c91.entry.js → p-f7063e39.entry.js} +1 -1
  332. package/dist/twilight/{p-dbd9523b.entry.js → p-f7f35e00.entry.js} +1 -1
  333. package/dist/twilight/{p-e77d6649.entry.js → p-f889b4d2.entry.js} +1 -1
  334. package/dist/twilight/{p-bdb558a2.entry.js → p-faa90387.entry.js} +1 -1
  335. package/dist/twilight/{p-f7e38710.entry.js → p-fe8cb1d6.entry.js} +1 -1
  336. package/dist/twilight/{p-D9StCBh9.js → p-k8NfWBBa.js} +2 -2
  337. package/dist/twilight/twilight.esm.js +1 -1
  338. package/dist/types/Helpers/translate.d.ts +10 -0
  339. package/dist/types/components/salla-offer/salla-offer.d.ts +52 -1
  340. package/dist/types/components/salla-offer-modal/offer-schema.d.ts +12 -0
  341. package/dist/types/components/salla-offer-modal/salla-offer-modal.d.ts +7 -0
  342. package/dist/types/components/salla-orders/interface.d.ts +2 -0
  343. package/dist/types/components/salla-orders/salla-orders.d.ts +5 -1
  344. package/package.json +5 -5
  345. package/dist/twilight/p-02eccebc.entry.js +0 -4
  346. package/dist/twilight/p-1bcacd6b.entry.js +0 -4
  347. package/dist/twilight/p-22087f33.entry.js +0 -4
  348. package/dist/twilight/p-b84FyDqk.js +0 -9
@@ -1,4 +1,4 @@
1
1
  /*!
2
2
  * Crafted with ❤ by Salla
3
3
  */
4
- import{r as t,h as a,F as s,a as e}from"./p-BXNtVhVe.js";const i=class{constructor(a){t(this,a),this.isMobileAllowed=!0,this.isEmailRequired=!1,this.supportWebAuth=!0,this.withoutReload=!1,this.source="",this.htmlElement=document.documentElement,this.messages=[],this.isClosable=!0,this.iframeLoaded=!1,this.scrolling="no",this.direction=document.dir,this.canRenderIframe=!1,salla.event.on("login::open",(t=>this.onLoginOpen(t))),salla.event.on("modal::close",(t=>{this.iframe&&this.sendMessageToIframe({source:"login",type:"modal_closed",data:t})})),salla.onReady((()=>{this.api=salla.config.get("store.api"),this.storeId=salla.config.get("store.id")}))}onLoginOpen(t){salla.mobile?.isNativeLoginEnabled?.()||(this.isEmailAllowed||this.isMobileAllowed?(this.source=t?.source??!1,this.withoutReload=t?.withoutReload??this.withoutReload,this.open(t),this.openModal()):salla.logger.warn("Please enable atleast one login type to use this component."))}componentDidLoad(){window.addEventListener("message",(t=>{if(!this.isTrustedMessage(t)||"login"!=t.data?.source)return;if(!this.inline&&!this.canRenderIframe)return;salla.log("salla-account:: recived an event",t.data);let a=t.data?.type?.replace("iframe::",""),s=t.data.message;if("ready"==a)return s.isPasskeyPage?void this.createPassKey.postMessage({source:"login",type:"init_passkey_page",data:{token:salla.storage.get("token"),store_id:salla.config.get("store.id"),locale:salla.config.get("user.language_code"),redirect:salla.config.get("store.url")}},salla.config.get("login.url")):void this.handleIframeReadyAction();if("height"==a)return this.iframe.height=s?.height+"px";if("storage"==a)return this.handleIframeStorageAction(s);if("scrolling"==a)return this.scrolling=s,void(this.isClosable=!1);if("direction"==a)return document.dir=this.direction=s?"rtl":"ltr";if("notify"==a)return salla.notify[s.type](s.message);if("authenticated"==a||"authenticated_web_auth"==a)return!s?.withoutClose&&this.close(),salla.auth.api.handlAfterAuthenticatedResponse(s,this.supportWebAuth).then((()=>!(s?.withoutReload||this.withoutReload)&&setTimeout((()=>window.location.reload()),1e3)));if("dispatchEvent"!=a||"auth::verified"!=s.event){if("dispatchEvent"==a)return salla.event.emit(s.event,...s.payload);if("reload"==a)return s?.withClose&&this.modal.close(),window.location.reload();if("open_page"===a){if(!this.isSafeUrl(s?.url))return;return window.location.href=s.url}if("open_passkey_page"!==a)return"guest-checkout"===a?this.handleGuestCheckout():void("close"==a&&this.close());this.createPassKey=window.open(`${salla.config.get("login.url")}/create-passkey`)}else salla.log("Ignored dispatchEvent `auth::verified` from iframe")})),this.observeDarkModeChanges(),setTimeout((()=>Salla.event.emit("salla-login::ready")),1)}async open(t=null){return Salla.config.isGuest()?this.modal.open():this.withoutReload?void 0:location.reload()}close(){Salla.event.emit("salla-login::closing"),this.modal.close(),this.iframeLoaded=!1,this.canRenderIframe=!1,this.host.dispatchEvent(new CustomEvent("salla-login:closed",{cancelable:!0,bubbles:!0,detail:null})),Salla.event.emit("salla-login::closed")}handleIframeReadyAction(){this.sendInitMessage(),this.sendMessageToIframe({source:"login",type:"width",data:document.body.clientWidth})}observeDarkModeChanges(){new MutationObserver((t=>{t.forEach((t=>{"class"===t.attributeName&&this.sendMessageToIframe({source:"login",type:"darkMode",data:{isDark:!!this.htmlElement.classList.contains("dark")}})}))})).observe(this.htmlElement,{attributes:!0})}async handleIframeStorageAction(t){let a,s=salla.storage.get("cart.user_id"),e=!1;if(Object.entries(t).filter((t=>!Salla.storage.get(t[0]))).forEach((([t,i])=>{salla.log("Shared storage from accounts domain",t,i);let l="string"==typeof i?i?.replace(/^"|"$/g,""):i;salla.storage.set(t,l),"token"===t&&(a=l),"user"===t&&s&&l.id!==s&&(e=!0)})),a){this.modal.close(),Salla.auth.event.tokenFetched(a);try{await Salla.api.cart.assign()}catch(t){Salla.log("Error on assign after handle iframe",t)}e&&Salla.cart.reset();try{!Salla.auth.api.isSessionless()&&await Salla.auth.api.request("auth/jwt"),Salla.auth.api.canRedirect()?setTimeout((()=>window.location.reload()),100):await Salla.auth.event.loggedIn({data:{token:a}}).then((()=>Salla.auth.api.afterUserLogin()))}catch(t){this.modal.open(),Salla.log("Error on request auth/jwt after handle iframe",t)}}else e&&Salla.cart.reset()}isTrustedMessage(t){if(!(this.iframe&&t.source===this.iframe.contentWindow||this.createPassKey&&t.source===this.createPassKey))return!1;let a;try{a=new URL(salla.config.get("login.url","https://accounts.salla.com")).origin}catch(t){a="https://accounts.salla.com"}return t.origin===a}isSafeUrl(t){if("string"!=typeof t||!t)return!1;try{const{protocol:a}=new URL(t,location.href);return"https:"===a||"http:"===a}catch(t){return!1}}sendMessageToIframe(t){if(this.iframe)return this.iframe.contentWindow.postMessage(t,"*")}sendInitMessage(){let t=this.headers;try{t="string"==typeof t?JSON.parse(t):t}catch(a){console.error("Failed to parse headers!",this.headers,a),t=void 0}const a={user:salla.storage.get("user"),s_translations:salla.storage.get("s_translations"),token:salla.storage.get("token")};a.user||delete a.user,a.s_translations||delete a.s_translations,a.token||delete a.token,this.sendMessageToIframe({source:"login",type:"init",data:{id:this.storeId,lang:salla.lang.locale,isDark:!!this.htmlElement.classList.contains("dark"),apiUrl:this.api?.replace(/\/+$/,""),supportWebAuth:this.supportWebAuth,withoutReload:this.withoutReload,inline:this.inline,settings:salla.config.all(),headers:t,storage:a}})}async handleGuestCheckout(){if(this.modal.close(),salla.config.isGuest())return salla.cart.submit(!1,!0)}openModal(){this.canRenderIframe||(this.canRenderIframe=!0),this.modal.open()}render(){if(!Salla.config.isUser())return this.inline?this.getLoginDom():a("salla-modal",{class:"s-login-modal",ref:t=>this.modal=t,width:"xs"},this.getLoginDom())}getLoginDom(){if(this.canRenderIframe)return a(s,null,a("iframe",{src:`${salla.config.get("login.url","https://accounts.salla.com")}?src=${this.source}&version=${salla.config.get("login.version","0.1.78")}`,title:"Salla Login",class:"hide-scroll",loading:"lazy",ref:t=>{this.iframe=t},allow:"publickey-credentials-get; publickey-credentials-create",scrolling:this.scrolling,frameborder:"0",width:"100%"}))}get host(){return e(this)}};i.style="/*!twlt*/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%}.inline{display:inline}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}";export{i as salla_login_modal}
4
+ import{r as t,h as a,F as s,a as e}from"./p-VyEjj_Gx.js";const i=class{constructor(a){t(this,a),this.isMobileAllowed=!0,this.isEmailRequired=!1,this.supportWebAuth=!0,this.withoutReload=!1,this.source="",this.htmlElement=document.documentElement,this.messages=[],this.isClosable=!0,this.iframeLoaded=!1,this.scrolling="no",this.direction=document.dir,this.canRenderIframe=!1,salla.event.on("login::open",(t=>this.onLoginOpen(t))),salla.event.on("modal::close",(t=>{this.iframe&&this.sendMessageToIframe({source:"login",type:"modal_closed",data:t})})),salla.onReady((()=>{this.api=salla.config.get("store.api"),this.storeId=salla.config.get("store.id")}))}onLoginOpen(t){salla.mobile?.isNativeLoginEnabled?.()||(this.isEmailAllowed||this.isMobileAllowed?(this.source=t?.source??!1,this.withoutReload=t?.withoutReload??this.withoutReload,this.open(t),this.openModal()):salla.logger.warn("Please enable atleast one login type to use this component."))}componentDidLoad(){window.addEventListener("message",(t=>{if(!this.isTrustedMessage(t)||"login"!=t.data?.source)return;if(!this.inline&&!this.canRenderIframe)return;salla.log("salla-account:: recived an event",t.data);let a=t.data?.type?.replace("iframe::",""),s=t.data.message;if("ready"==a)return s.isPasskeyPage?void this.createPassKey.postMessage({source:"login",type:"init_passkey_page",data:{token:salla.storage.get("token"),store_id:salla.config.get("store.id"),locale:salla.config.get("user.language_code"),redirect:salla.config.get("store.url")}},salla.config.get("login.url")):void this.handleIframeReadyAction();if("height"==a)return this.iframe.height=s?.height+"px";if("storage"==a)return this.handleIframeStorageAction(s);if("scrolling"==a)return this.scrolling=s,void(this.isClosable=!1);if("direction"==a)return document.dir=this.direction=s?"rtl":"ltr";if("notify"==a)return salla.notify[s.type](s.message);if("authenticated"==a||"authenticated_web_auth"==a)return!s?.withoutClose&&this.close(),salla.auth.api.handlAfterAuthenticatedResponse(s,this.supportWebAuth).then((()=>!(s?.withoutReload||this.withoutReload)&&setTimeout((()=>window.location.reload()),1e3)));if("dispatchEvent"!=a||"auth::verified"!=s.event){if("dispatchEvent"==a)return salla.event.emit(s.event,...s.payload);if("reload"==a)return s?.withClose&&this.modal.close(),window.location.reload();if("open_page"===a){if(!this.isSafeUrl(s?.url))return;return window.location.href=s.url}if("open_passkey_page"!==a)return"guest-checkout"===a?this.handleGuestCheckout():void("close"==a&&this.close());this.createPassKey=window.open(`${salla.config.get("login.url")}/create-passkey`)}else salla.log("Ignored dispatchEvent `auth::verified` from iframe")})),this.observeDarkModeChanges(),setTimeout((()=>Salla.event.emit("salla-login::ready")),1)}async open(t=null){return Salla.config.isGuest()?this.modal.open():this.withoutReload?void 0:location.reload()}close(){Salla.event.emit("salla-login::closing"),this.modal.close(),this.iframeLoaded=!1,this.canRenderIframe=!1,this.host.dispatchEvent(new CustomEvent("salla-login:closed",{cancelable:!0,bubbles:!0,detail:null})),Salla.event.emit("salla-login::closed")}handleIframeReadyAction(){this.sendInitMessage(),this.sendMessageToIframe({source:"login",type:"width",data:document.body.clientWidth})}observeDarkModeChanges(){new MutationObserver((t=>{t.forEach((t=>{"class"===t.attributeName&&this.sendMessageToIframe({source:"login",type:"darkMode",data:{isDark:!!this.htmlElement.classList.contains("dark")}})}))})).observe(this.htmlElement,{attributes:!0})}async handleIframeStorageAction(t){let a,s=salla.storage.get("cart.user_id"),e=!1;if(Object.entries(t).filter((t=>!Salla.storage.get(t[0]))).forEach((([t,i])=>{salla.log("Shared storage from accounts domain",t,i);let l="string"==typeof i?i?.replace(/^"|"$/g,""):i;salla.storage.set(t,l),"token"===t&&(a=l),"user"===t&&s&&l.id!==s&&(e=!0)})),a){this.modal.close(),Salla.auth.event.tokenFetched(a);try{await Salla.api.cart.assign()}catch(t){Salla.log("Error on assign after handle iframe",t)}e&&Salla.cart.reset();try{!Salla.auth.api.isSessionless()&&await Salla.auth.api.request("auth/jwt"),Salla.auth.api.canRedirect()?setTimeout((()=>window.location.reload()),100):await Salla.auth.event.loggedIn({data:{token:a}}).then((()=>Salla.auth.api.afterUserLogin()))}catch(t){this.modal.open(),Salla.log("Error on request auth/jwt after handle iframe",t)}}else e&&Salla.cart.reset()}isTrustedMessage(t){if(!(this.iframe&&t.source===this.iframe.contentWindow||this.createPassKey&&t.source===this.createPassKey))return!1;let a;try{a=new URL(salla.config.get("login.url","https://accounts.salla.com")).origin}catch(t){a="https://accounts.salla.com"}return t.origin===a}isSafeUrl(t){if("string"!=typeof t||!t)return!1;try{const{protocol:a}=new URL(t,location.href);return"https:"===a||"http:"===a}catch(t){return!1}}sendMessageToIframe(t){if(this.iframe)return this.iframe.contentWindow.postMessage(t,"*")}sendInitMessage(){let t=this.headers;try{t="string"==typeof t?JSON.parse(t):t}catch(a){console.error("Failed to parse headers!",this.headers,a),t=void 0}const a={user:salla.storage.get("user"),s_translations:salla.storage.get("s_translations"),token:salla.storage.get("token")};a.user||delete a.user,a.s_translations||delete a.s_translations,a.token||delete a.token,this.sendMessageToIframe({source:"login",type:"init",data:{id:this.storeId,lang:salla.lang.locale,isDark:!!this.htmlElement.classList.contains("dark"),apiUrl:this.api?.replace(/\/+$/,""),supportWebAuth:this.supportWebAuth,withoutReload:this.withoutReload,inline:this.inline,settings:salla.config.all(),headers:t,storage:a}})}async handleGuestCheckout(){if(this.modal.close(),salla.config.isGuest())return salla.cart.submit(!1,!0)}openModal(){this.canRenderIframe||(this.canRenderIframe=!0),this.modal.open()}render(){if(!Salla.config.isUser())return this.inline?this.getLoginDom():a("salla-modal",{class:"s-login-modal",ref:t=>this.modal=t,width:"xs"},this.getLoginDom())}getLoginDom(){if(this.canRenderIframe)return a(s,null,a("iframe",{src:`${salla.config.get("login.url","https://accounts.salla.com")}?src=${this.source}&version=${salla.config.get("login.version","0.1.78")}`,title:"Salla Login",class:"hide-scroll",loading:"lazy",ref:t=>{this.iframe=t},allow:"publickey-credentials-get; publickey-credentials-create",scrolling:this.scrolling,frameborder:"0",width:"100%"}))}get host(){return e(this)}};i.style="/*!twlt*/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%}.inline{display:inline}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}";export{i as salla_login_modal}