@salla.sa/twilight-components 2.14.171 → 2.14.172

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 (275) hide show
  1. package/dist/cjs/{app-globals-CoUrP7Bc.js → app-globals-Bk9IDSPX.js} +3 -3
  2. package/dist/cjs/{app-globals-CoUrP7Bc.js.map → app-globals-Bk9IDSPX.js.map} +1 -1
  3. package/dist/cjs/{index-C0Vb2Bnd.js → index-B1jJnKON.js} +4 -4
  4. package/dist/cjs/{index-C0Vb2Bnd.js.map → index-B1jJnKON.js.map} +1 -1
  5. package/dist/cjs/loader.cjs.js +2 -2
  6. package/dist/cjs/salla-add-product-button_49.cjs.entry.js +1 -1
  7. package/dist/cjs/salla-advertisement.cjs.entry.js +1 -1
  8. package/dist/cjs/salla-app-install-alert.cjs.entry.js +1 -1
  9. package/dist/cjs/salla-apps-icons.cjs.entry.js +1 -1
  10. package/dist/cjs/salla-booking-field.salla-conditional-fields.entry.cjs.js.map +1 -1
  11. package/dist/cjs/salla-booking-field_2.cjs.entry.js +2 -2
  12. package/dist/cjs/salla-booking-field_2.cjs.entry.js.map +1 -1
  13. package/dist/cjs/salla-cart-item-offers.cjs.entry.js +1 -1
  14. package/dist/cjs/salla-conditional-offer.cjs.entry.js +1 -1
  15. package/dist/cjs/salla-contacts.cjs.entry.js +1 -1
  16. package/dist/cjs/salla-filters-widget.cjs.entry.js +1 -1
  17. package/dist/cjs/salla-filters.cjs.entry.js +1 -1
  18. package/dist/cjs/salla-installment.cjs.entry.js +1 -1
  19. package/dist/cjs/salla-loyalty-prize-item.cjs.entry.js +1 -1
  20. package/dist/cjs/salla-metadata.cjs.entry.js +1 -1
  21. package/dist/cjs/salla-notification-item.cjs.entry.js +1 -1
  22. package/dist/cjs/salla-notifications.cjs.entry.js +1 -1
  23. package/dist/cjs/salla-offer.cjs.entry.js +1 -1
  24. package/dist/cjs/salla-order-summary.cjs.entry.js +1 -1
  25. package/dist/cjs/salla-orders.cjs.entry.js +1 -1
  26. package/dist/cjs/salla-payments.cjs.entry.js +1 -1
  27. package/dist/cjs/salla-price-range.cjs.entry.js +1 -1
  28. package/dist/cjs/salla-product-options.cjs.entry.js +1 -1
  29. package/dist/cjs/salla-review-card.cjs.entry.js +1 -1
  30. package/dist/cjs/salla-reviews-page.cjs.entry.js +1 -1
  31. package/dist/cjs/salla-reviews.cjs.entry.js +1 -1
  32. package/dist/cjs/salla-social.cjs.entry.js +1 -1
  33. package/dist/cjs/salla-tooltip.cjs.entry.js +1 -1
  34. package/dist/cjs/salla-verify.cjs.entry.js +1 -1
  35. package/dist/cjs/salla-wallet.cjs.entry.js +1 -1
  36. package/dist/cjs/twilight.cjs.js +2 -2
  37. package/dist/collection/components/salla-booking-field/salla-booking-field.js +1 -1
  38. package/dist/collection/components/salla-booking-field/salla-booking-field.js.map +1 -1
  39. package/dist/components/index.js +2 -2
  40. package/dist/components/index.js.map +1 -1
  41. package/dist/components/salla-booking-field2.js +1 -1
  42. package/dist/components/salla-booking-field2.js.map +1 -1
  43. package/dist/esm/{app-globals-CSF3zqJZ.js → app-globals-BlWInTtE.js} +3 -3
  44. package/dist/esm/{app-globals-CSF3zqJZ.js.map → app-globals-BlWInTtE.js.map} +1 -1
  45. package/dist/esm/{index-LiUkE7QA.js → index-CayW-agT.js} +4 -4
  46. package/dist/esm/{index-LiUkE7QA.js.map → index-CayW-agT.js.map} +1 -1
  47. package/dist/esm/loader.js +3 -3
  48. package/dist/esm/salla-add-product-button_49.entry.js +1 -1
  49. package/dist/esm/salla-advertisement.entry.js +1 -1
  50. package/dist/esm/salla-app-install-alert.entry.js +1 -1
  51. package/dist/esm/salla-apps-icons.entry.js +1 -1
  52. package/dist/esm/salla-booking-field.salla-conditional-fields.entry.js.map +1 -1
  53. package/dist/esm/salla-booking-field_2.entry.js +2 -2
  54. package/dist/esm/salla-booking-field_2.entry.js.map +1 -1
  55. package/dist/esm/salla-cart-item-offers.entry.js +1 -1
  56. package/dist/esm/salla-conditional-offer.entry.js +1 -1
  57. package/dist/esm/salla-contacts.entry.js +1 -1
  58. package/dist/esm/salla-filters-widget.entry.js +1 -1
  59. package/dist/esm/salla-filters.entry.js +1 -1
  60. package/dist/esm/salla-installment.entry.js +1 -1
  61. package/dist/esm/salla-loyalty-prize-item.entry.js +1 -1
  62. package/dist/esm/salla-metadata.entry.js +1 -1
  63. package/dist/esm/salla-notification-item.entry.js +1 -1
  64. package/dist/esm/salla-notifications.entry.js +1 -1
  65. package/dist/esm/salla-offer.entry.js +1 -1
  66. package/dist/esm/salla-order-summary.entry.js +1 -1
  67. package/dist/esm/salla-orders.entry.js +1 -1
  68. package/dist/esm/salla-payments.entry.js +1 -1
  69. package/dist/esm/salla-price-range.entry.js +1 -1
  70. package/dist/esm/salla-product-options.entry.js +1 -1
  71. package/dist/esm/salla-review-card.entry.js +1 -1
  72. package/dist/esm/salla-reviews-page.entry.js +1 -1
  73. package/dist/esm/salla-reviews.entry.js +1 -1
  74. package/dist/esm/salla-social.entry.js +1 -1
  75. package/dist/esm/salla-tooltip.entry.js +1 -1
  76. package/dist/esm/salla-verify.entry.js +1 -1
  77. package/dist/esm/salla-wallet.entry.js +1 -1
  78. package/dist/esm/twilight.js +3 -3
  79. package/dist/esm-es5/{app-globals-CSF3zqJZ.js → app-globals-BlWInTtE.js} +2 -2
  80. package/dist/esm-es5/{app-globals-CSF3zqJZ.js.map → app-globals-BlWInTtE.js.map} +1 -1
  81. package/dist/esm-es5/{index-LiUkE7QA.js → index-CayW-agT.js} +3 -3
  82. package/dist/esm-es5/{index-LiUkE7QA.js.map → index-CayW-agT.js.map} +1 -1
  83. package/dist/esm-es5/loader.js +1 -1
  84. package/dist/esm-es5/salla-add-product-button_49.entry.js +1 -1
  85. package/dist/esm-es5/salla-advertisement.entry.js +1 -1
  86. package/dist/esm-es5/salla-app-install-alert.entry.js +1 -1
  87. package/dist/esm-es5/salla-apps-icons.entry.js +1 -1
  88. package/dist/esm-es5/salla-booking-field.salla-conditional-fields.entry.js.map +1 -1
  89. package/dist/esm-es5/salla-booking-field_2.entry.js +1 -1
  90. package/dist/esm-es5/salla-booking-field_2.entry.js.map +1 -1
  91. package/dist/esm-es5/salla-cart-item-offers.entry.js +1 -1
  92. package/dist/esm-es5/salla-conditional-offer.entry.js +1 -1
  93. package/dist/esm-es5/salla-contacts.entry.js +1 -1
  94. package/dist/esm-es5/salla-filters-widget.entry.js +1 -1
  95. package/dist/esm-es5/salla-filters.entry.js +1 -1
  96. package/dist/esm-es5/salla-installment.entry.js +1 -1
  97. package/dist/esm-es5/salla-loyalty-prize-item.entry.js +1 -1
  98. package/dist/esm-es5/salla-metadata.entry.js +1 -1
  99. package/dist/esm-es5/salla-notification-item.entry.js +1 -1
  100. package/dist/esm-es5/salla-notifications.entry.js +1 -1
  101. package/dist/esm-es5/salla-offer.entry.js +1 -1
  102. package/dist/esm-es5/salla-order-summary.entry.js +1 -1
  103. package/dist/esm-es5/salla-orders.entry.js +1 -1
  104. package/dist/esm-es5/salla-payments.entry.js +1 -1
  105. package/dist/esm-es5/salla-price-range.entry.js +1 -1
  106. package/dist/esm-es5/salla-product-options.entry.js +1 -1
  107. package/dist/esm-es5/salla-review-card.entry.js +1 -1
  108. package/dist/esm-es5/salla-reviews-page.entry.js +1 -1
  109. package/dist/esm-es5/salla-reviews.entry.js +1 -1
  110. package/dist/esm-es5/salla-social.entry.js +1 -1
  111. package/dist/esm-es5/salla-tooltip.entry.js +1 -1
  112. package/dist/esm-es5/salla-verify.entry.js +1 -1
  113. package/dist/esm-es5/salla-wallet.entry.js +1 -1
  114. package/dist/esm-es5/twilight.js +1 -1
  115. package/dist/twilight/{p-9141f034.entry.js → p-0649d076.entry.js} +2 -2
  116. package/dist/twilight/{p-41a0c995.system.entry.js → p-1696a245.system.entry.js} +2 -2
  117. package/dist/twilight/{p-dc49a423.entry.js → p-19f533ec.entry.js} +2 -2
  118. package/dist/twilight/{p-3f9cd841.entry.js → p-1dd178a2.entry.js} +2 -2
  119. package/dist/twilight/{p-02844499.entry.js → p-20bdcd53.entry.js} +2 -2
  120. package/dist/twilight/{p-a5f6800a.entry.js → p-247636ef.entry.js} +2 -2
  121. package/dist/twilight/{p-12bfaebb.entry.js → p-269ebd5d.entry.js} +2 -2
  122. package/dist/twilight/{p-aecbfd1d.entry.js → p-29e96484.entry.js} +2 -2
  123. package/dist/twilight/p-29e96484.entry.js.map +1 -0
  124. package/dist/twilight/{p-e9bf33ee.system.entry.js → p-2a10bff2.system.entry.js} +2 -2
  125. package/dist/twilight/{p-edf6d3c2.entry.js → p-2d0c2877.entry.js} +2 -2
  126. package/dist/twilight/{p-27fa210f.system.entry.js → p-2da442c2.system.entry.js} +2 -2
  127. package/dist/twilight/{p-bf53423f.system.entry.js → p-3093ea8e.system.entry.js} +2 -2
  128. package/dist/twilight/{p-8d6211ec.entry.js → p-316e3ea9.entry.js} +2 -2
  129. package/dist/twilight/{p-97314074.entry.js → p-33963e7d.entry.js} +2 -2
  130. package/dist/twilight/{p-2c6b0290.entry.js → p-37a3c661.entry.js} +2 -2
  131. package/dist/twilight/{p-e34ad807.entry.js → p-41480e7b.entry.js} +2 -2
  132. package/dist/twilight/{p-8ff9f4d9.entry.js → p-41ecc4f7.entry.js} +2 -2
  133. package/dist/twilight/{p-d5ce6328.system.entry.js → p-44a213de.system.entry.js} +2 -2
  134. package/dist/twilight/p-4ced9aab.entry.js +5 -0
  135. package/dist/twilight/{p-0736f49e.system.entry.js → p-4fb112e6.system.entry.js} +2 -2
  136. package/dist/twilight/{p-733cb343.entry.js → p-51195e76.entry.js} +2 -2
  137. package/dist/twilight/{p-d7f60971.system.entry.js → p-54bd7e18.system.entry.js} +2 -2
  138. package/dist/twilight/{p-e287bf7a.system.entry.js → p-611b6013.system.entry.js} +2 -2
  139. package/dist/twilight/{p-ab2e6e46.system.entry.js → p-679bb855.system.entry.js} +2 -2
  140. package/dist/twilight/{p-65518c0a.system.entry.js → p-67fe618e.system.entry.js} +2 -2
  141. package/dist/twilight/{p-1d364b10.system.entry.js → p-69ec9ac8.system.entry.js} +2 -2
  142. package/dist/twilight/{p-4d3191f1.system.entry.js → p-740b39fc.system.entry.js} +2 -2
  143. package/dist/twilight/{p-573b6006.entry.js → p-756fe45d.entry.js} +2 -2
  144. package/dist/twilight/{p-a1ce8510.system.entry.js → p-7ddf00a9.system.entry.js} +2 -2
  145. package/dist/twilight/{p-d6c38604.system.entry.js → p-86dd7e02.system.entry.js} +2 -2
  146. package/dist/twilight/{p-3c82a2ea.entry.js → p-8c9ae8bd.entry.js} +2 -2
  147. package/dist/twilight/{p-8f046206.system.entry.js → p-8e242779.system.entry.js} +2 -2
  148. package/dist/twilight/{p-aef8742e.entry.js → p-9361e7a2.entry.js} +2 -2
  149. package/dist/twilight/p-952a8078.entry.js +5 -0
  150. package/dist/twilight/{p-f8478e12.entry.js → p-9ca8c6b6.entry.js} +7 -7
  151. package/dist/twilight/{p-4b94b4d5.system.entry.js → p-9d750b3d.system.entry.js} +2 -2
  152. package/dist/twilight/{p-DBJi00fV.system.js.map → p-B3wutB2s.system.js.map} +1 -1
  153. package/dist/twilight/{p-CLu8tbvy.system.js.map → p-BYBYDro2.system.js.map} +1 -1
  154. package/dist/twilight/{p-C7fl3xeP.system.js.map → p-BeVJFUxX.system.js.map} +1 -1
  155. package/dist/twilight/{p-DJxn4O4E.system.js.map → p-BmwlZkRw.system.js.map} +1 -1
  156. package/dist/twilight/{p-BjC8fmj6.system.js → p-BuezmX1t.system.js} +2 -2
  157. package/dist/twilight/{p-BjC8fmj6.system.js.map → p-BuezmX1t.system.js.map} +1 -1
  158. package/dist/twilight/{p-Om_u4Egx.system.js.map → p-BuxFmGAL.system.js.map} +1 -1
  159. package/dist/twilight/{p-DyTZuKIw.system.js.map → p-Bxsqm2ye.system.js.map} +1 -1
  160. package/dist/twilight/{p-CNOk3SrL.system.js.map → p-C2OoabIm.system.js.map} +1 -1
  161. package/dist/twilight/{p-BnJBAsTe.system.js.map → p-C4gOv56I.system.js.map} +1 -1
  162. package/dist/twilight/{p-CK-QWMoJ.system.js.map → p-C7B9pjwv.system.js.map} +1 -1
  163. package/dist/twilight/{p-WXH08GLX.system.js.map → p-CCr4sv_K.system.js.map} +1 -1
  164. package/dist/twilight/{p-BuUD_anz.system.js.map → p-CECjqlBg.system.js.map} +1 -1
  165. package/dist/twilight/p-CPIDPWPd.system.js.map +1 -0
  166. package/dist/twilight/{p-80ECHVzY.system.js.map → p-CT4XUl4u.system.js.map} +1 -1
  167. package/dist/twilight/{p-Dw0aLYK1.system.js.map → p-CT7GoHDG.system.js.map} +1 -1
  168. package/dist/twilight/{p-LiUkE7QA.js → p-CayW-agT.js} +3 -3
  169. package/dist/twilight/{p-LiUkE7QA.js.map → p-CayW-agT.js.map} +1 -1
  170. package/dist/twilight/{p-CDy0KAOd.system.js.map → p-Ccj3kuAD.system.js.map} +1 -1
  171. package/dist/twilight/{p-BRyMdU18.system.js.map → p-CeyDIaJF.system.js.map} +1 -1
  172. package/dist/twilight/{p-Drwx-n0N.system.js.map → p-CjXAM86c.system.js.map} +1 -1
  173. package/dist/twilight/{p-D-0D-Csi.system.js → p-CmumtzEL.system.js} +3 -3
  174. package/dist/twilight/{p-D-0D-Csi.system.js.map → p-CmumtzEL.system.js.map} +1 -1
  175. package/dist/twilight/{p-BgqCi424.system.js.map → p-D4ot6EsS.system.js.map} +1 -1
  176. package/dist/twilight/{p-Bdm0DMVs.system.js.map → p-DEOECcHf.system.js.map} +1 -1
  177. package/dist/twilight/{p-Bjw432F2.system.js.map → p-DUKloBXK.system.js.map} +1 -1
  178. package/dist/twilight/{p-DEYXxIq_.system.js.map → p-Dg8Ywiaf.system.js.map} +1 -1
  179. package/dist/twilight/{p-CHrCH5-b.system.js.map → p-Dmm2RXZq.system.js.map} +1 -1
  180. package/dist/twilight/{p-D4qzuSae.system.js.map → p-DraNKP6B.system.js.map} +1 -1
  181. package/dist/twilight/{p-DJ4xzdd6.system.js.map → p-DzJCsxNk.system.js.map} +1 -1
  182. package/dist/twilight/{p-BcXA9D_n.system.js → p-FxRE-bWf.system.js} +2 -2
  183. package/dist/twilight/{p-BcXA9D_n.system.js.map → p-FxRE-bWf.system.js.map} +1 -1
  184. package/dist/twilight/{p-B41fVqSK.js → p-PnQHllOh.js} +2 -2
  185. package/dist/twilight/{p-B41fVqSK.js.map → p-PnQHllOh.js.map} +1 -1
  186. package/dist/twilight/{p-CKJsTcpM.system.js.map → p-UOO6uSKD.system.js.map} +1 -1
  187. package/dist/twilight/{p-Oac7J1zA.system.js.map → p-W3JU15BC.system.js.map} +1 -1
  188. package/dist/twilight/{p-b905ab43.system.entry.js → p-a78387e7.system.entry.js} +6 -6
  189. package/dist/twilight/{p-524f35f6.entry.js → p-aa6a0113.entry.js} +2 -2
  190. package/dist/twilight/p-ad02a471.system.entry.js +5 -0
  191. package/dist/twilight/{p-8d39c410.entry.js → p-b63bc4db.entry.js} +2 -2
  192. package/dist/twilight/{p-7222192c.entry.js → p-b72f268b.entry.js} +2 -2
  193. package/dist/twilight/{p-8e2e5da6.system.entry.js → p-c70ed29b.system.entry.js} +2 -2
  194. package/dist/twilight/{p-228e378a.system.entry.js → p-cdc147d2.system.entry.js} +2 -2
  195. package/dist/twilight/{p-702258d0.entry.js → p-d0912efd.entry.js} +2 -2
  196. package/dist/twilight/{p-b5d67a2f.system.entry.js → p-d14e40fe.system.entry.js} +2 -2
  197. package/dist/twilight/{p-e776a27b.system.entry.js → p-d2c834be.system.entry.js} +2 -2
  198. package/dist/twilight/{p-fd05b59d.system.entry.js → p-d56a7bd9.system.entry.js} +2 -2
  199. package/dist/twilight/{p-1e6cc35c.entry.js → p-d600f506.entry.js} +2 -2
  200. package/dist/twilight/{p-2780506f.system.entry.js → p-db68e58b.system.entry.js} +2 -2
  201. package/dist/twilight/p-db68e58b.system.entry.js.map +1 -0
  202. package/dist/twilight/{p-0398e027.system.entry.js → p-e061a1f5.system.entry.js} +2 -2
  203. package/dist/twilight/{p-c58c7583.entry.js → p-e084e3c4.entry.js} +2 -2
  204. package/dist/twilight/{p-872e0e93.entry.js → p-e9ca7e7c.entry.js} +2 -2
  205. package/dist/twilight/{p-5d01641c.system.entry.js → p-ee97bc7b.system.entry.js} +2 -2
  206. package/dist/twilight/{p-09f9b1c7.system.entry.js → p-f5ce1227.system.entry.js} +2 -2
  207. package/dist/twilight/{p-c37c4334.system.entry.js → p-fb9cd621.system.entry.js} +2 -2
  208. package/dist/twilight/{p-ea280e73.entry.js → p-fdd3788a.entry.js} +2 -2
  209. package/dist/twilight/{p-C0YKkJRc.system.js.map → p-hIDulQlu.system.js.map} +1 -1
  210. package/dist/twilight/{p-CjFQPix4.system.js.map → p-qziIzWVk.system.js.map} +1 -1
  211. package/dist/twilight/{p-BPkmPLyb.system.js.map → p-y427D1HL.system.js.map} +1 -1
  212. package/dist/twilight/salla-booking-field.salla-conditional-fields.entry.esm.js.map +1 -1
  213. package/dist/twilight/twilight.esm.js +1 -1
  214. package/dist/twilight/twilight.js +1 -1
  215. package/package.json +5 -5
  216. package/dist/twilight/p-2780506f.system.entry.js.map +0 -1
  217. package/dist/twilight/p-30d8107f.system.entry.js +0 -5
  218. package/dist/twilight/p-93c132a7.entry.js +0 -5
  219. package/dist/twilight/p-D1W-OG00.system.js.map +0 -1
  220. package/dist/twilight/p-aecbfd1d.entry.js.map +0 -1
  221. package/dist/twilight/p-f77d0e8b.entry.js +0 -5
  222. /package/dist/twilight/{p-9141f034.entry.js.map → p-0649d076.entry.js.map} +0 -0
  223. /package/dist/twilight/{p-41a0c995.system.entry.js.map → p-1696a245.system.entry.js.map} +0 -0
  224. /package/dist/twilight/{p-dc49a423.entry.js.map → p-19f533ec.entry.js.map} +0 -0
  225. /package/dist/twilight/{p-3f9cd841.entry.js.map → p-1dd178a2.entry.js.map} +0 -0
  226. /package/dist/twilight/{p-02844499.entry.js.map → p-20bdcd53.entry.js.map} +0 -0
  227. /package/dist/twilight/{p-a5f6800a.entry.js.map → p-247636ef.entry.js.map} +0 -0
  228. /package/dist/twilight/{p-12bfaebb.entry.js.map → p-269ebd5d.entry.js.map} +0 -0
  229. /package/dist/twilight/{p-e9bf33ee.system.entry.js.map → p-2a10bff2.system.entry.js.map} +0 -0
  230. /package/dist/twilight/{p-edf6d3c2.entry.js.map → p-2d0c2877.entry.js.map} +0 -0
  231. /package/dist/twilight/{p-27fa210f.system.entry.js.map → p-2da442c2.system.entry.js.map} +0 -0
  232. /package/dist/twilight/{p-bf53423f.system.entry.js.map → p-3093ea8e.system.entry.js.map} +0 -0
  233. /package/dist/twilight/{p-8d6211ec.entry.js.map → p-316e3ea9.entry.js.map} +0 -0
  234. /package/dist/twilight/{p-97314074.entry.js.map → p-33963e7d.entry.js.map} +0 -0
  235. /package/dist/twilight/{p-2c6b0290.entry.js.map → p-37a3c661.entry.js.map} +0 -0
  236. /package/dist/twilight/{p-e34ad807.entry.js.map → p-41480e7b.entry.js.map} +0 -0
  237. /package/dist/twilight/{p-8ff9f4d9.entry.js.map → p-41ecc4f7.entry.js.map} +0 -0
  238. /package/dist/twilight/{p-d5ce6328.system.entry.js.map → p-44a213de.system.entry.js.map} +0 -0
  239. /package/dist/twilight/{p-f77d0e8b.entry.js.map → p-4ced9aab.entry.js.map} +0 -0
  240. /package/dist/twilight/{p-0736f49e.system.entry.js.map → p-4fb112e6.system.entry.js.map} +0 -0
  241. /package/dist/twilight/{p-733cb343.entry.js.map → p-51195e76.entry.js.map} +0 -0
  242. /package/dist/twilight/{p-d7f60971.system.entry.js.map → p-54bd7e18.system.entry.js.map} +0 -0
  243. /package/dist/twilight/{p-e287bf7a.system.entry.js.map → p-611b6013.system.entry.js.map} +0 -0
  244. /package/dist/twilight/{p-ab2e6e46.system.entry.js.map → p-679bb855.system.entry.js.map} +0 -0
  245. /package/dist/twilight/{p-65518c0a.system.entry.js.map → p-67fe618e.system.entry.js.map} +0 -0
  246. /package/dist/twilight/{p-1d364b10.system.entry.js.map → p-69ec9ac8.system.entry.js.map} +0 -0
  247. /package/dist/twilight/{p-4d3191f1.system.entry.js.map → p-740b39fc.system.entry.js.map} +0 -0
  248. /package/dist/twilight/{p-573b6006.entry.js.map → p-756fe45d.entry.js.map} +0 -0
  249. /package/dist/twilight/{p-a1ce8510.system.entry.js.map → p-7ddf00a9.system.entry.js.map} +0 -0
  250. /package/dist/twilight/{p-d6c38604.system.entry.js.map → p-86dd7e02.system.entry.js.map} +0 -0
  251. /package/dist/twilight/{p-3c82a2ea.entry.js.map → p-8c9ae8bd.entry.js.map} +0 -0
  252. /package/dist/twilight/{p-8f046206.system.entry.js.map → p-8e242779.system.entry.js.map} +0 -0
  253. /package/dist/twilight/{p-aef8742e.entry.js.map → p-9361e7a2.entry.js.map} +0 -0
  254. /package/dist/twilight/{p-93c132a7.entry.js.map → p-952a8078.entry.js.map} +0 -0
  255. /package/dist/twilight/{p-f8478e12.entry.js.map → p-9ca8c6b6.entry.js.map} +0 -0
  256. /package/dist/twilight/{p-4b94b4d5.system.entry.js.map → p-9d750b3d.system.entry.js.map} +0 -0
  257. /package/dist/twilight/{p-b905ab43.system.entry.js.map → p-a78387e7.system.entry.js.map} +0 -0
  258. /package/dist/twilight/{p-524f35f6.entry.js.map → p-aa6a0113.entry.js.map} +0 -0
  259. /package/dist/twilight/{p-30d8107f.system.entry.js.map → p-ad02a471.system.entry.js.map} +0 -0
  260. /package/dist/twilight/{p-8d39c410.entry.js.map → p-b63bc4db.entry.js.map} +0 -0
  261. /package/dist/twilight/{p-7222192c.entry.js.map → p-b72f268b.entry.js.map} +0 -0
  262. /package/dist/twilight/{p-8e2e5da6.system.entry.js.map → p-c70ed29b.system.entry.js.map} +0 -0
  263. /package/dist/twilight/{p-228e378a.system.entry.js.map → p-cdc147d2.system.entry.js.map} +0 -0
  264. /package/dist/twilight/{p-702258d0.entry.js.map → p-d0912efd.entry.js.map} +0 -0
  265. /package/dist/twilight/{p-b5d67a2f.system.entry.js.map → p-d14e40fe.system.entry.js.map} +0 -0
  266. /package/dist/twilight/{p-e776a27b.system.entry.js.map → p-d2c834be.system.entry.js.map} +0 -0
  267. /package/dist/twilight/{p-fd05b59d.system.entry.js.map → p-d56a7bd9.system.entry.js.map} +0 -0
  268. /package/dist/twilight/{p-1e6cc35c.entry.js.map → p-d600f506.entry.js.map} +0 -0
  269. /package/dist/twilight/{p-0398e027.system.entry.js.map → p-e061a1f5.system.entry.js.map} +0 -0
  270. /package/dist/twilight/{p-c58c7583.entry.js.map → p-e084e3c4.entry.js.map} +0 -0
  271. /package/dist/twilight/{p-872e0e93.entry.js.map → p-e9ca7e7c.entry.js.map} +0 -0
  272. /package/dist/twilight/{p-5d01641c.system.entry.js.map → p-ee97bc7b.system.entry.js.map} +0 -0
  273. /package/dist/twilight/{p-09f9b1c7.system.entry.js.map → p-f5ce1227.system.entry.js.map} +0 -0
  274. /package/dist/twilight/{p-c37c4334.system.entry.js.map → p-fb9cd621.system.entry.js.map} +0 -0
  275. /package/dist/twilight/{p-ea280e73.entry.js.map → p-fdd3788a.entry.js.map} +0 -0
@@ -1 +1 @@
1
- {"version":3,"file":"salla-booking-field.salla-conditional-fields.entry.esm.js","sources":["src/components/salla-booking-field/salla-booking-field.scss?tag=salla-booking-field","src/components/salla-booking-field/salla-booking-field.tsx","src/components/salla-conditional-fields/salla-conditional-fields.tsx"],"sourcesContent":[":host {\n display: block;\n}\n","import { Component, Host, Prop, h, Element, State, Event, EventEmitter } from '@stencil/core';\nimport { Option, Reservation } from './interfaces';\nimport BookingTime from '../../assets/svg/calendar-time.svg';\nimport Calendar from '../../assets/svg/calendar.svg';\nimport TimeIcon from '../../assets/svg/time.svg';\n\n@Component({\n tag: 'salla-booking-field',\n styleUrl: 'salla-booking-field.scss',\n})\nexport class SallaBookingField {\n /**\n * The booking option configuration\n */\n @Prop() option: Option;\n /**\n * The ID of the product for which the booking is being made\n */\n @Prop() productId: number;\n @Element() host: HTMLElement;\n @State() bookNowLabel: string = salla.lang.get('pages.cart.book_an_appointment', 'حجز موعد');\n @State() editLabel: string = salla.lang.get('pages.cart.edit_an_appointment', 'تعديل الموعد');\n @State() bookedLabel: string = salla.lang.get('pages.cart.booked_successfully', 'تمت اضافة الموعد بنجاح');\n @State() selectDate: string = salla.lang.get('pages.cart.select_appointment_date', 'حدد تاريخ الموعد');\n @State() bookingUrl: string = '';\n @State() iframeReady: boolean = false;\n @State() reservations: Reservation[] = [];\n @State() reservationsInput: HTMLInputElement;\n\n /**\n * Event emitted when the input is invalid.\n */\n @Event() invalidInput: EventEmitter<any>;\n\n private modal: HTMLSallaModalElement;\n private iframe: HTMLIFrameElement;\n\n constructor() {\n // Load translations\n salla.lang.onLoaded(() => this.setTranslations());\n // Register event listeners\n Salla.event.on('booking::open', (data) => this.handleBookingOpen(data));\n }\n\n private async setTranslations() {\n const setNestedAsync = (lang, key, value) => {\n return new Promise((resolve) => {\n salla.helpers.setNested(salla.lang.messages[lang], key, value);\n resolve(true);\n });\n };\n\n await setNestedAsync('ar.trans', 'pages.cart.book_an_appointment', 'حجز موعد');\n await setNestedAsync('en.trans', 'pages.cart.book_an_appointment', 'Book an Appointment');\n await setNestedAsync('ar.trans', 'pages.cart.edit_an_appointment', 'تعديل الموعد');\n await setNestedAsync('en.trans', 'pages.cart.edit_an_appointment', 'Edit an Appointment');\n await setNestedAsync('ar.trans', 'pages.cart.booked_successfully', 'تمت اضافة الموعد بنجاح');\n await setNestedAsync('en.trans', 'pages.cart.booked_successfully', 'Booked Successfully');\n await setNestedAsync('ar.trans', 'pages.cart.select_appointment_date', 'حدد تاريخ الموعد');\n await setNestedAsync('en.trans', 'pages.cart.select_appointment_date', 'Select appointment date');\n\n this.bookNowLabel = salla.lang.get('pages.cart.book_an_appointment');\n this.editLabel = salla.lang.get('pages.cart.edit_an_appointment');\n this.bookedLabel = salla.lang.get('pages.cart.booked_successfully');\n this.selectDate = salla.lang.get('pages.cart.select_appointment_date');\n }\n\n private openBookingModal(event: any, afterReload = false) {\n if (afterReload && (!event.detail || typeof event.detail !== 'number' || event.detail !== this.productId)) {\n return;\n }\n if (salla.config.isGuest()) {\n this.setAfterReloadEvent('booking::open-after-reload', this.productId);\n salla.event.dispatch('login::open');\n return;\n }\n salla.booking.add(this.productId, false)\n .then((resp) => {\n if (resp.data.redirect.to !== 'booking') {\n throw new Error('Unexpected redirect!');\n }\n salla.event.dispatch('booking::open', { url: resp.data.redirect.url, id: this.productId });\n })\n .catch((error) => {\n salla.error(salla.lang.get('common.errors.error_occurred'));\n salla.logger.error(error.response || error);\n });\n }\n\n private handleBookingOpen(data) {\n if (data.id !== this.productId) return;\n this.bookingUrl = salla.url.addParamToUrl('product_id', data.id, data.url);\n this.iframeReady = true;\n setTimeout(() => {\n this.modal.setTitle(this.selectDate);\n this.modal.open();\n }, 100);\n }\n\n private setAfterReloadEvent(event, payload) {\n salla.storage.set('afterReloadEvent', { event, payload });\n }\n\n private emitAfterReloadEvent() {\n const eventDetails = salla.storage.get('afterReloadEvent');\n if (eventDetails && eventDetails.event) {\n const customEvent = new CustomEvent(eventDetails.event, {\n detail: eventDetails.payload\n });\n window.dispatchEvent(customEvent)\n salla.storage.remove('afterReloadEvent');\n }\n }\n\n componentWillLoad() {\n if (this.option && this.option.details.length) {\n this.reservations = this.option.details;\n }\n }\n\n componentDidLoad() {\n window.addEventListener('booking::open-after-reload', (event) => this.openBookingModal(event, true));\n this.emitAfterReloadEvent();\n window.addEventListener('message', this.handleMessageEvent.bind(this));\n this.reservationsInput.addEventListener('invalid', e => this.invalidInput.emit(e));\n this.reservationsInput.addEventListener('input', () => {\n this.reservationsInput.setCustomValidity('');\n this.reservationsInput.reportValidity();\n });\n }\n\n private handleMessageEvent(event) {\n if (event.data.source !== 'booking') return;\n const action = event.data.type;\n const value = event.data.message;\n if (localStorage.getItem('debug')) console.log(`Received an action:${action}`, event.data);\n\n if (action === 'error') {\n if (value.fields?.reservation) {\n salla.notify.error(value.fields.reservation[0]);\n return;\n }\n const errorList = Object.values(value.fields || [value.message]).flat().map(error => `<li>${error}</li>`).join('');\n salla.notify.error(`<ul>${errorList}</ul>`);\n }\n\n if (action === 'success') {\n if (Number(value.productId) !== Number(this.productId)) return;\n this.reservations = value.data.reservations.map(schedule => {\n if (schedule.time && schedule.time.length > 0) {\n const timeSlot = schedule.time[0];\n return {\n date: schedule.date,\n day: schedule.day,\n from_timestamp: timeSlot.from,\n to_timestamp: timeSlot.to,\n };\n }\n return null;\n }).filter(item => item !== null);\n\n salla.notify.success(this.bookedLabel);\n this.modal?.close();\n setTimeout(() => window.location.reload());\n }\n\n if (action === 'height') {\n this.iframe.height = value?.height + 'px';\n }\n }\n\n private bookingModal() {\n return (\n <salla-modal class=\"s-booking-field-modal\" ref={modal => (this.modal = modal)} width=\"md\" position=\"middle\" noPadding>\n <iframe ref={iframe => (this.iframe = iframe)} src={this.bookingUrl} frameborder=\"0\"></iframe>\n </salla-modal>\n );\n }\n\n renderReservationDate(reservation: Reservation) {\n return (\n <span class={reservation.from_timestamp ? 's-booking-field-reservations-has-time' : ''}>\n <i class=\"s-booking-field-reservations-icon\" innerHTML={Calendar}></i>\n {reservation.date}\n </span>\n );\n }\n\n renderReservationTime(reservation: Reservation) {\n if (!reservation.from_timestamp) return '';\n return (\n <span class=\"s-booking-field-reservations-time\">\n <i class=\"s-booking-field-reservations-icon\" innerHTML={TimeIcon}></i>\n <span>\n {reservation.from_timestamp} - {reservation.to_timestamp}\n </span>\n </span>\n );\n }\n\n render() {\n return (\n <Host>\n <div class=\"s-booking-field-main\">\n {this.option.required || this.reservations.length > 0 ? <div class=\"s-booking-field-price\">\n <span>{salla.money(this.option.price)}</span>\n </div> : ''}\n <salla-button class=\"s-booking-field-book-now\" size=\"small\" loaderPosition=\"center\" fill=\"outline\" onClick={event => this.openBookingModal(event, false)}>\n <span class=\"s-booking-field-book-now-content\">\n <span innerHTML={BookingTime}></span>\n {this.reservations.length ? this.editLabel : this.bookNowLabel}\n </span>\n </salla-button>\n </div>\n {this.reservations.length > 0 && (\n <div class=\"s-booking-field-reservations\">\n {this.reservations.map((reservation, index) => (\n <div key={index} class=\"s-booking-field-reservations-item\">\n {this.renderReservationDate(reservation)}\n {this.renderReservationTime(reservation)}\n </div>\n ))}\n </div>\n )}\n <input\n class=\"s-hidden\"\n name={this.option.name}\n required={this.option.required}\n value={JSON.stringify(this.reservations) === '[]' ? '' : JSON.stringify(this.reservations)}\n ref={reservations => this.reservationsInput = reservations}\n />\n {this.iframeReady && this.bookingModal()}\n </Host>\n );\n }\n}\n","import { Component, Element, Host, Listen, h } from '@stencil/core';\n\n/**\n * its to easy to use, currenlty its support select & checkbox input as trigger for show/hide the dom\n * the dom you can put it like this data-show-when=\"{name of the field} {= or !=} {value of the field}\"\n */\n@Component({\n tag: 'salla-conditional-fields'\n})\nexport class SallaConditionalFields {\n\n @Element() host: HTMLElement;\n\n private hideAllOptions(optionId) {\n this.host.querySelectorAll(`[data-show-when^=\"options[${optionId}\"]`).forEach((field: HTMLElement) => {\n field.classList.add('hidden');\n this.hideAllOptions(field.dataset.optionId);\n this.disableInputs(field);\n });\n }\n\n private disableInputs(field) {\n field.querySelectorAll('[name]').forEach((input) => {\n\n input.setAttribute('disabled', '');\n input.removeAttribute('required');\n if (input?.tagName?.toLowerCase() === 'select') {\n input.value = ''\n }\n if (['checkbox'].includes(input.getAttribute('type')) && input.hasOwnProperty('checked')) {\n // @ts-ignore\n input.checked = false;\n }\n });\n }\n \n @Listen('change')\n changeHandler(event) {\n salla.event.emit('salla-onditional-fields::change', event);\n salla.log('Received the change event: ', event);\n\n if (!event.target || !['SELECT'].includes(event.target.tagName) && !['checkbox', 'radio'].includes(event.target.getAttribute('type'))) {\n salla.log('Ignore the change because is not a supported input: ' + (event?.target?.tagName || 'N/A'));\n return;\n }\n\n let optionId = event.target.name.replace('[]', '');\n let isMultiple = event.target.getAttribute('type') === 'checkbox';\n let isRadio = event.target.getAttribute('type') === 'radio';\n\n salla.log('Trying to find all elements with condition:', `[data-show-when^=\"${optionId}\"]`);\n\n this.host.querySelectorAll(`[data-show-when^=\"${optionId}\"]`)\n .forEach((field: HTMLElement) => {\n let isEqual = !field?.dataset.showWhen.includes('!=');\n let value = field?.dataset.showWhen.replace(/(.*)(=|!=)(.*)/gm, '$3').trim();\n let isSelected;\n if (isMultiple) {\n let selectedValues = Array.from(this.host.querySelectorAll(`input[name=\"${event.target.name}\"]:checked`), e => (e as HTMLInputElement)?.value);\n isSelected = selectedValues.includes(value.toString());\n } else if (isRadio) {\n // Handle radio inputs.\n isSelected = event.target.checked && event.target.value === value;\n } else {\n isSelected = value === event.target.value;\n }\n\n salla.log('The input is ', isMultiple ? 'Multiple' : isRadio ? 'Radio' : 'Single', ' value:', isSelected);\n\n let showTheInput = (isEqual && isSelected) || (!isEqual && !isSelected);\n if (showTheInput) {\n field.classList.remove('hidden');\n field.querySelectorAll('[name]').forEach((input) => {\n input.removeAttribute('disabled');\n\n const closestProductOption = (input as HTMLInputElement).closest('.s-product-options-option') as HTMLElement;\n if (closestProductOption.dataset.optionRequired === 'true') {\n input.setAttribute('required', '');\n }\n\n if (input.getAttribute('type') === 'checkbox') {\n const checkboxes = Array.from(document.querySelectorAll(`input[type=\"checkbox\"][name=\"${input.getAttribute('name')}\"]`)) as HTMLInputElement[];\n const isAnyChecked = checkboxes.some((checkbox) => checkbox.checked);\n if (isAnyChecked) {\n checkboxes.forEach((checkbox) => {\n checkbox.removeAttribute('required');\n });\n }\n }\n });\n } else {\n this.hideAllOptions(field.dataset.optionId);\n field.classList.add('hidden');\n this.disableInputs(field);\n }\n });\n } \n\n componentDidRender() {\n this.host.querySelectorAll(`[data-show-when]`).forEach((field) => {\n // @ts-ignore\n let optionName = field?.dataset?.showWhen.replace(/(.*)(=|!=)(.*)/gm, '$1').trim();\n if (!optionName) {\n return;\n }\n\n this.changeHandler({\n target: this.host.querySelector('[name^=\"' + optionName + '\"]')\n })\n });\n }\n\n render() {\n return (\n <Host>\n <slot></slot>\n </Host>\n );\n }\n}\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,MAAM,oBAAoB,GAAG,sBAAsB;;MCUtC,iBA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/D,aAAA,CAAC;AACJ,SAAC,CAAC;;IAGJ,MAAM,GAAA;QACJ,QACE,EAAC,IAAI,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,EACH,CAAa,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,CAAA,CACR;;;;;;;"}
1
+ {"version":3,"file":"salla-booking-field.salla-conditional-fields.entry.esm.js","sources":["src/components/salla-booking-field/salla-booking-field.scss?tag=salla-booking-field","src/components/salla-booking-field/salla-booking-field.tsx","src/components/salla-conditional-fields/salla-conditional-fields.tsx"],"sourcesContent":[":host {\n display: block;\n}\n","import { Component, Host, Prop, h, Element, State, Event, EventEmitter } from '@stencil/core';\nimport { Option, Reservation } from './interfaces';\nimport BookingTime from '../../assets/svg/calendar-time.svg';\nimport Calendar from '../../assets/svg/calendar.svg';\nimport TimeIcon from '../../assets/svg/time.svg';\n\n@Component({\n tag: 'salla-booking-field',\n styleUrl: 'salla-booking-field.scss',\n})\nexport class SallaBookingField {\n /**\n * The booking option configuration\n */\n @Prop() option: Option;\n /**\n * The ID of the product for which the booking is being made\n */\n @Prop() productId: number;\n @Element() host: HTMLElement;\n @State() bookNowLabel: string = salla.lang.get('pages.cart.book_an_appointment', 'حجز موعد');\n @State() editLabel: string = salla.lang.get('pages.cart.edit_an_appointment', 'تعديل الموعد');\n @State() bookedLabel: string = salla.lang.get('pages.cart.booked_successfully', 'تمت اضافة الموعد بنجاح');\n @State() selectDate: string = salla.lang.get('pages.cart.select_appointment_date', 'حدد تاريخ الموعد');\n @State() bookingUrl: string = '';\n @State() iframeReady: boolean = false;\n @State() reservations: Reservation[] = [];\n @State() reservationsInput: HTMLInputElement;\n\n /**\n * Event emitted when the input is invalid.\n */\n @Event() invalidInput: EventEmitter<any>;\n\n private modal: HTMLSallaModalElement;\n private iframe: HTMLIFrameElement;\n\n constructor() {\n // Load translations\n salla.lang.onLoaded(() => this.setTranslations());\n // Register event listeners\n Salla.event.on('booking::open', (data) => this.handleBookingOpen(data));\n }\n\n private async setTranslations() {\n const setNestedAsync = (lang, key, value) => {\n return new Promise((resolve) => {\n salla.helpers.setNested(salla.lang.messages[lang], key, value);\n resolve(true);\n });\n };\n\n await setNestedAsync('ar.trans', 'pages.cart.book_an_appointment', 'حجز موعد');\n await setNestedAsync('en.trans', 'pages.cart.book_an_appointment', 'Book an Appointment');\n await setNestedAsync('ar.trans', 'pages.cart.edit_an_appointment', 'تعديل الموعد');\n await setNestedAsync('en.trans', 'pages.cart.edit_an_appointment', 'Edit an Appointment');\n await setNestedAsync('ar.trans', 'pages.cart.booked_successfully', 'تمت اضافة الموعد بنجاح');\n await setNestedAsync('en.trans', 'pages.cart.booked_successfully', 'Booked Successfully');\n await setNestedAsync('ar.trans', 'pages.cart.select_appointment_date', 'حدد تاريخ الموعد');\n await setNestedAsync('en.trans', 'pages.cart.select_appointment_date', 'Select appointment date');\n\n this.bookNowLabel = salla.lang.get('pages.cart.book_an_appointment');\n this.editLabel = salla.lang.get('pages.cart.edit_an_appointment');\n this.bookedLabel = salla.lang.get('pages.cart.booked_successfully');\n this.selectDate = salla.lang.get('pages.cart.select_appointment_date');\n }\n\n private openBookingModal(event: any, afterReload = false) {\n if (afterReload && (!event.detail || typeof event.detail !== 'number' || event.detail !== this.productId)) {\n return;\n }\n if (salla.config.isGuest()) {\n this.setAfterReloadEvent('booking::open-after-reload', this.productId);\n salla.event.dispatch('login::open');\n return;\n }\n salla.booking.add(this.productId, false)\n .then((resp) => {\n if (resp.data.redirect.to !== 'booking') {\n throw new Error('Unexpected redirect!');\n }\n salla.event.dispatch('booking::open', { url: resp.data.redirect.url, id: this.productId });\n })\n .catch((error) => {\n salla.error(salla.lang.get('common.errors.error_occurred'));\n salla.logger.error(error.response || error);\n });\n }\n\n private handleBookingOpen(data) {\n if (data.id !== this.productId) return;\n this.bookingUrl = salla.url.addParamToUrl('product_id', data.id, data.url);\n this.iframeReady = true;\n setTimeout(() => {\n this.modal.setTitle(this.selectDate);\n this.modal.open();\n }, 100);\n }\n\n private setAfterReloadEvent(event, payload) {\n salla.storage.set('afterReloadEvent', { event, payload });\n }\n\n private emitAfterReloadEvent() {\n const eventDetails = salla.storage.get('afterReloadEvent');\n if (eventDetails && eventDetails.event) {\n const customEvent = new CustomEvent(eventDetails.event, {\n detail: eventDetails.payload\n });\n window.dispatchEvent(customEvent)\n salla.storage.remove('afterReloadEvent');\n }\n }\n\n componentWillLoad() {\n if (this.option && this.option.details.length) {\n this.reservations = this.option.details;\n }\n }\n\n componentDidLoad() {\n window.addEventListener('booking::open-after-reload', (event) => this.openBookingModal(event, true));\n this.emitAfterReloadEvent();\n window.addEventListener('message', this.handleMessageEvent.bind(this));\n this.reservationsInput.addEventListener('invalid', e => this.invalidInput.emit(e));\n this.reservationsInput.addEventListener('input', () => {\n this.reservationsInput.setCustomValidity('');\n this.reservationsInput.reportValidity();\n });\n }\n\n private handleMessageEvent(event) {\n if (event.data.source !== 'booking') return;\n const action = event.data.type;\n const value = event.data.message;\n if (localStorage.getItem('debug')) console.log(`Received an action:${action}`, event.data);\n\n if (action === 'error') {\n if (value.fields?.reservation) {\n salla.notify.error(value.fields.reservation[0]);\n return;\n }\n const errorList = Object.values(value.fields || [value.message]).flat().map(error => `<li>${error}</li>`).join('');\n salla.notify.error(`<ul>${errorList}</ul>`);\n }\n\n if (action === 'success') {\n if (Number(value.productId) !== Number(this.productId)) return;\n this.reservations = value.data.reservations.map(schedule => {\n if (schedule.time && schedule.time.length > 0) {\n const timeSlot = schedule.time[0];\n return {\n date: schedule.date,\n day: schedule.day,\n from_timestamp: timeSlot.from,\n to_timestamp: timeSlot.to,\n };\n }\n return null;\n }).filter(item => item !== null);\n\n salla.notify.success(this.bookedLabel);\n this.modal?.close();\n setTimeout(() => window.location.reload());\n }\n\n if (action === 'height') {\n this.iframe.height = value?.height + 'px';\n }\n }\n\n private bookingModal() {\n return (\n <salla-modal class=\"s-booking-field-modal\" ref={modal => (this.modal = modal)} width=\"md\" position=\"middle\" noPadding>\n <iframe ref={iframe => (this.iframe = iframe)} src={this.bookingUrl} frameborder=\"0\"></iframe>\n </salla-modal>\n );\n }\n\n renderReservationDate(reservation: Reservation) {\n return (\n <span class={reservation.from_timestamp ? 's-booking-field-reservations-has-time' : ''}>\n <i class=\"s-booking-field-reservations-icon\" innerHTML={Calendar}></i>\n {reservation.date}\n </span>\n );\n }\n\n renderReservationTime(reservation: Reservation) {\n if (!reservation.from_timestamp) return '';\n return (\n <span class=\"s-booking-field-reservations-time\">\n <i class=\"s-booking-field-reservations-icon\" innerHTML={TimeIcon}></i>\n <span>\n {reservation.from_timestamp} - {reservation.to_timestamp}\n </span>\n </span>\n );\n }\n\n render() {\n return (\n <Host>\n <div class=\"s-booking-field-main\">\n {this.option.required || this.reservations.length > 0 ? <div class=\"s-booking-field-price\">\n <span innerHTML={salla.money(this.option.price)}></span>\n </div> : ''}\n <salla-button class=\"s-booking-field-book-now\" size=\"small\" loaderPosition=\"center\" fill=\"outline\" onClick={event => this.openBookingModal(event, false)}>\n <span class=\"s-booking-field-book-now-content\">\n <span innerHTML={BookingTime}></span>\n {this.reservations.length ? this.editLabel : this.bookNowLabel}\n </span>\n </salla-button>\n </div>\n {this.reservations.length > 0 && (\n <div class=\"s-booking-field-reservations\">\n {this.reservations.map((reservation, index) => (\n <div key={index} class=\"s-booking-field-reservations-item\">\n {this.renderReservationDate(reservation)}\n {this.renderReservationTime(reservation)}\n </div>\n ))}\n </div>\n )}\n <input\n class=\"s-hidden\"\n name={this.option.name}\n required={this.option.required}\n value={JSON.stringify(this.reservations) === '[]' ? '' : JSON.stringify(this.reservations)}\n ref={reservations => this.reservationsInput = reservations}\n />\n {this.iframeReady && this.bookingModal()}\n </Host>\n );\n }\n}\n","import { Component, Element, Host, Listen, h } from '@stencil/core';\n\n/**\n * its to easy to use, currenlty its support select & checkbox input as trigger for show/hide the dom\n * the dom you can put it like this data-show-when=\"{name of the field} {= or !=} {value of the field}\"\n */\n@Component({\n tag: 'salla-conditional-fields'\n})\nexport class SallaConditionalFields {\n\n @Element() host: HTMLElement;\n\n private hideAllOptions(optionId) {\n this.host.querySelectorAll(`[data-show-when^=\"options[${optionId}\"]`).forEach((field: HTMLElement) => {\n field.classList.add('hidden');\n this.hideAllOptions(field.dataset.optionId);\n this.disableInputs(field);\n });\n }\n\n private disableInputs(field) {\n field.querySelectorAll('[name]').forEach((input) => {\n\n input.setAttribute('disabled', '');\n input.removeAttribute('required');\n if (input?.tagName?.toLowerCase() === 'select') {\n input.value = ''\n }\n if (['checkbox'].includes(input.getAttribute('type')) && input.hasOwnProperty('checked')) {\n // @ts-ignore\n input.checked = false;\n }\n });\n }\n \n @Listen('change')\n changeHandler(event) {\n salla.event.emit('salla-onditional-fields::change', event);\n salla.log('Received the change event: ', event);\n\n if (!event.target || !['SELECT'].includes(event.target.tagName) && !['checkbox', 'radio'].includes(event.target.getAttribute('type'))) {\n salla.log('Ignore the change because is not a supported input: ' + (event?.target?.tagName || 'N/A'));\n return;\n }\n\n let optionId = event.target.name.replace('[]', '');\n let isMultiple = event.target.getAttribute('type') === 'checkbox';\n let isRadio = event.target.getAttribute('type') === 'radio';\n\n salla.log('Trying to find all elements with condition:', `[data-show-when^=\"${optionId}\"]`);\n\n this.host.querySelectorAll(`[data-show-when^=\"${optionId}\"]`)\n .forEach((field: HTMLElement) => {\n let isEqual = !field?.dataset.showWhen.includes('!=');\n let value = field?.dataset.showWhen.replace(/(.*)(=|!=)(.*)/gm, '$3').trim();\n let isSelected;\n if (isMultiple) {\n let selectedValues = Array.from(this.host.querySelectorAll(`input[name=\"${event.target.name}\"]:checked`), e => (e as HTMLInputElement)?.value);\n isSelected = selectedValues.includes(value.toString());\n } else if (isRadio) {\n // Handle radio inputs.\n isSelected = event.target.checked && event.target.value === value;\n } else {\n isSelected = value === event.target.value;\n }\n\n salla.log('The input is ', isMultiple ? 'Multiple' : isRadio ? 'Radio' : 'Single', ' value:', isSelected);\n\n let showTheInput = (isEqual && isSelected) || (!isEqual && !isSelected);\n if (showTheInput) {\n field.classList.remove('hidden');\n field.querySelectorAll('[name]').forEach((input) => {\n input.removeAttribute('disabled');\n\n const closestProductOption = (input as HTMLInputElement).closest('.s-product-options-option') as HTMLElement;\n if (closestProductOption.dataset.optionRequired === 'true') {\n input.setAttribute('required', '');\n }\n\n if (input.getAttribute('type') === 'checkbox') {\n const checkboxes = Array.from(document.querySelectorAll(`input[type=\"checkbox\"][name=\"${input.getAttribute('name')}\"]`)) as HTMLInputElement[];\n const isAnyChecked = checkboxes.some((checkbox) => checkbox.checked);\n if (isAnyChecked) {\n checkboxes.forEach((checkbox) => {\n checkbox.removeAttribute('required');\n });\n }\n }\n });\n } else {\n this.hideAllOptions(field.dataset.optionId);\n field.classList.add('hidden');\n this.disableInputs(field);\n }\n });\n } \n\n componentDidRender() {\n this.host.querySelectorAll(`[data-show-when]`).forEach((field) => {\n // @ts-ignore\n let optionName = field?.dataset?.showWhen.replace(/(.*)(=|!=)(.*)/gm, '$1').trim();\n if (!optionName) {\n return;\n }\n\n this.changeHandler({\n target: this.host.querySelector('[name^=\"' + optionName + '\"]')\n })\n });\n }\n\n render() {\n return (\n <Host>\n <slot></slot>\n </Host>\n );\n }\n}\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,MAAM,oBAAoB,GAAG,sBAAsB;;MCUtC,iBAAiB,GAAA,MAAA;AA2B5B,IAAA,WAAA,CAAA,OAAA,EAAA;;;AAjBS,QAAA,IAAY,CAAA,YAAA,GAAW,KAAK,CAAC,IAAI,CAAC,GAAG,CAAC,gCAAgC,EAAE,UAAU,CAAC;AACnF,QAAA,IAAS,CAAA,SAAA,GAAW,KAAK,CAAC,IAAI,CAAC,GAAG,CAAC,gCAAgC,EAAE,cAAc,CAAC;AACpF,QAAA,IAAW,CAAA,WAAA,GAAW,KAAK,CAAC,IAAI,CAAC,GAAG,CAAC,gCAAgC,EAAE,wBAAwB,CAAC;AAChG,QAAA,IAAU,CAAA,UAAA,GAAW,KAAK,CAAC,IAA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A,UAAU,CAAC,OAAO,CAAC,CAAC,QAAQ,KAAI;AAC9B,gCAAA,QAAQ,CAAC,eAAe,CAAC,UAAU,CAAC;AACtC,6BAAC,CAAC;;;AAGR,iBAAC,CAAC;;iBACG;gBACL,IAAI,CAAC,cAAc,CAAC,KAAK,CAAC,OAAO,CAAC,QAAQ,CAAC;AAC3C,gBAAA,KAAK,CAAC,SAAS,CAAC,GAAG,CAAC,QAAQ,CAAC;AAC7B,gBAAA,IAAI,CAAC,aAAa,CAAC,KAAK,CAAC;;AAE7B,SAAC,CAAC;;IAGN,kBAAkB,GAAA;AAChB,QAAA,IAAI,CAAC,IAAI,CAAC,gBAAgB,CAAC,CAAA,gBAAA,CAAkB,CAAC,CAAC,OAAO,CAAC,CAAC,KAAK,KAAI;;;YAE/D,IAAI,UAAU,GAAG,CAAA,EAAA,GAAA,KAAK,aAAL,KAAK,KAAA,MAAA,GAAA,MAAA,GAAL,KAAK,CAAE,OAAO,0CAAE,QAAQ,CAAC,OAAO,CAAC,kBAAkB,EAAE,IAAI,CAAA,CAAE,IAAI,EAAE;YAClF,IAAI,CAAC,UAAU,EAAE;gBACf;;YAGF,IAAI,CAAC,aAAa,CAAC;AACjB,gBAAA,MAAM,EAAE,IAAI,CAAC,IAAI,CAAC,aAAa,CAAC,UAAU,GAAG,UAAU,GAAG,IAAI;AAC/D,aAAA,CAAC;AACJ,SAAC,CAAC;;IAGJ,MAAM,GAAA;QACJ,QACE,EAAC,IAAI,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,EACH,CAAa,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,CAAA,CACR;;;;;;;"}
@@ -1,5 +1,5 @@
1
1
  /*!
2
2
  * Crafted with ❤ by Salla
3
3
  */
4
- import{p as e,b as a}from"./p-LiUkE7QA.js";export{s as setNonce}from"./p-LiUkE7QA.js";import{g as t}from"./p-B41fVqSK.js";var l=()=>{const a=import.meta.url;const t={};if(a!==""){t.resourcesUrl=new URL(".",a).href}return e(t)};l().then((async e=>{await t();return a(JSON.parse('[["p-702258d0",[[0,"salla-offer",{"productCardComponent":[1,"product-card-component"],"offersList":[32],"userCurrency":[32],"isMultipleBank":[32],"title":[32],"currentPage":[32],"hasCustomComponent":[32],"isBankOffer":[32],"canRender":[32],"showOffer":[32],"offer_with_price_text":[32],"with_discount_text":[32],"product_discount_text":[32],"special_offer_text":[32],"multipleBankOfferTitleText":[32],"multipleBankOfferTitleDescription":[32],"buy_quantity_text":[32]}]]],["p-ea280e73",[[0,"salla-product-options",{"productId":[2,"product-id"],"options":[1],"hideOutLabel":[1,"hide-out-label"],"uniqueKey":[1,"unique-key"],"config":[1],"optionsData":[32],"outOfStockText":[32],"donationAmount":[32],"selectDonationAmount":[32],"selectAmount":[32],"isCustomDonation":[32],"selectedOptions":[32],"canDisabled":[32],"selectedSkus":[32],"selectedOutSkus":[32],"disableCardValue":[32],"availableDigitalCardValues":[32],"setOptionsData":[64],"getSelectedOptionsData":[64],"reportValidity":[64],"hasOutOfStockOption":[64],"getSelectedOptions":[64],"getOption":[64]}]]],["p-733cb343",[[0,"salla-filters",{"filters":[1040],"isSidebarOpen":[32],"filtersData":[32],"apply":[32],"reset":[32],"getFilters":[64],"applyFilters":[64],"resetFilters":[64]}]]],["p-8d6211ec",[[4,"salla-verify",{"display":[1],"type":[1025],"autoReload":[4,"auto-reload"],"supportWebAuth":[4,"support-web-auth"],"translationLoaded":[32],"title":[32],"resendAfter":[32],"hasError":[32],"errorMessage":[32],"isProfileVerify":[32],"getCode":[64],"open":[64]}]]],["p-a5f6800a",[[0,"salla-notifications",{"loadMoreText":[1,"load-more-text"],"itemPerPage":[2,"item-per-page"],"pagination":[32],"total":[32],"showPlaceholder":[32],"nextPage":[32],"no_notifications_trans":[32],"load_more_text_trans":[32]}]]],["p-3f9cd841",[[0,"salla-order-summary",{"orderId":[514,"order-id"],"codeCopied":[32],"noItemFound":[32],"order_items":[32]}]]],["p-c58c7583",[[0,"salla-reviews",{"displayAllLink":[516,"display-all-link"],"source":[513],"sourceValue":[513,"source-value"],"limit":[514],"type":[1],"sort":[1],"hideCustomerInfo":[4,"hide-customer-info"],"reviews":[32],"isRTL":[32],"showReviews":[32],"testimonialText":[32],"displayAllLinkText":[32]}]]],["p-9141f034",[[0,"salla-reviews-page",{"reviews":[32],"isLoading":[32],"pagination":[32],"sort":[32]}]]],["p-e34ad807",[[0,"salla-wallet",{"transactionsArray":[32],"balance":[32],"isLoading":[32],"nextPageUrl":[32]}]]],["p-93c132a7",[[0,"salla-conditional-offer",{"offer":[32],"products":[32],"isLoading":[32],"canRender":[32]}]]],["p-8d39c410",[[0,"salla-orders",{"params":[16],"loadMoreText":[1,"load-more-text"],"orderNumberText":[32],"totalOrderText":[32],"orderDateText":[32],"orderStatusText":[32],"noOrderText":[32],"load_more_text_trans":[32],"languageCode":[32],"orders":[32],"pagination":[32],"hasInfiniteScroll":[32],"total":[32],"nextPage":[32],"showPlaceholder":[32]}]]],["p-97314074",[[0,"salla-advertisement",{"position":[32],"advertisements":[32],"advertIcon":[32],"currentSlug":[32]}]]],["p-aef8742e",[[0,"salla-app-install-alert",{"data":[32],"ctaLink":[32],"open":[32],"closing":[32]}]]],["p-3c82a2ea",[[0,"salla-apps-icons",{"hideTitle":[4,"hide-title"],"appsTitle":[1,"apps-title"],"vertical":[4],"apps":[32]}]]],["p-1e6cc35c",[[0,"salla-cart-item-offers",{"quantity":[2],"offers":[1],"itemId":[2,"item-id"],"productPrice":[2,"product-price"],"internalQuantity":[32],"internalOffers":[32],"internalProductPrice":[32],"showAll":[32],"freeLabel":[32],"receivedOffer":[32],"discountAmountLabel":[32],"showMoreOffers":[32]}]]],["p-8ff9f4d9",[[0,"salla-contacts",{"contactsTitle":[1025,"contacts-title"],"hideTitle":[4,"hide-title"],"isHeader":[4,"is-header"],"horizontal":[4],"iconsOnly":[4,"icons-only"],"contacts":[32],"iconsList":[32]}]]],["p-524f35f6",[[0,"salla-installment",{"price":[1],"language":[1],"currency":[1],"country":[1],"tabbyIsActive":[32],"spotiiIsActive":[32],"tamaraIsActive":[32],"mispayActive":[32],"emkanIsActive":[32],"madfuActive":[32],"rajehiIsActive":[32],"installment_sheria_text":[32]}]]],["p-f77d0e8b",[[0,"salla-loyalty-prize-item",{"item":[16]}]]],["p-edf6d3c2",[[0,"salla-metadata",{"entity":[1],"entityId":[8,"entity-id"],"specs":[32],"download":[32]}]]],["p-872e0e93",[[0,"salla-payments",{"exclude":[1040]}]]],["p-02844499",[[0,"salla-social",{"links":[32],"iconsList":[32]}]]],["p-2c6b0290",[[4,"salla-filters-widget",{"withLoadMore":[1028,"with-load-more"],"filtersData":[16,"filters-data"],"option":[16],"isOpen":[32],"isShowMore":[32],"showMoreLabel":[32],"showLessLabel":[32],"page":[32],"setWidgetHeight":[64],"reset":[64],"showMore":[64],"toggleWidget":[64]}]]],["p-12bfaebb",[[0,"salla-notification-item",{"notification":[16]}]]],["p-573b6006",[[0,"salla-review-card",{"review":[16],"currentSlide":[32],"purchasedCount":[32],"showPurchaseCount":[32]}]]],["p-dc49a423",[[4,"salla-tooltip",{"text":[1],"targetId":[1,"target-id"],"show":[32]},[[9,"mouseover","handleMouseOver"],[9,"mouseout","handleMouseOut"]]]]],["p-f8478e12",[[0,"salla-offer-modal",{"offer":[32],"offer_name":[32],"offer_message":[32],"hasError":[32],"errorMessage":[32],"productID":[32],"offer_type":[32],"translationLoaded":[32],"addToCartLabel":[32],"open":[64],"showOffer":[64]}],[4,"salla-gifting",{"productId":[2,"product-id"],"widgetTitle":[1,"widget-title"],"widgetSubtitle":[1,"widget-subtitle"],"physicalProducts":[4,"physical-products"],"vertical":[4],"sectionTitle":[32],"sectionSubtitle":[32],"sectionBtnText":[32],"giftDetails":[32],"selectImageForYourGift":[32],"selectImageOrUpload":[32],"selectGiftMessage":[32],"giftCustomText":[32],"textId":[32],"incorrectGiftText":[32],"nextStep":[32],"senderNameLabel":[32],"receiverNameFieldLabel":[32],"receiverMobileFieldLabel":[32],"receiverCountryFieldLabel":[32],"ksa":[32],"selectCity":[32],"selectCityInfo":[32],"receiverCityFieldLabel":[32],"receiverEmailFieldLabel":[32],"emailPlaceholder":[32],"sendLater":[32],"selectSendDateAndTime":[32],"canNotEditOrderAfterSelectDate":[32],"sendGift":[32],"donationRequired":[32],"currentStep":[32],"showCalendar":[32],"showGiftText":[32],"currentLang":[32],"parentClass":[32],"errors":[32],"gift":[32],"selectedGiftTextOption":[32],"showTextArea":[32],"selectedImage":[32],"uploadedImage":[32],"selectedText":[32],"senderName":[32],"errorMessage":[32],"hasError":[32],"quantity":[32],"deliveryDate":[32],"timeZone":[32],"receiverName":[32],"receiverMobile":[32],"receiverCountryCode":[32],"receiverEmail":[32],"hostId":[32],"receiverCity":[32],"open":[64],"close":[64],"goToStep2":[64]}],[4,"salla-loyalty",{"prizePoints":[1544,"prize-points"],"customerPoints":[1538,"customer-points"],"prizeTitle":[1537,"prize-title"],"allowEmail":[4,"allow-email"],"allowMobile":[4,"allow-mobile"],"requireEmail":[4,"require-email"],"guestMessage":[1025,"guest-message"],"loyaltyProgram":[32],"buttonLoading":[32],"selectedItem":[32],"askConfirmation":[32],"is_loggedin":[32],"hasError":[32],"errorMessage":[32],"translationLoaded":[32],"open":[64],"close":[64],"resetExchange":[64],"exchangeLoyaltyPoint":[64]}],[0,"salla-comments",{"itemId":[2,"item-id"],"loadMoreText":[1,"load-more-text"],"hideForm":[4,"hide-form"],"blockTitle":[1,"block-title"],"hideTitle":[4,"hide-title"],"type":[1],"showFormAvatar":[4,"show-form-avatar"],"hideBought":[4,"hide-bought"],"sort":[1],"testimonials":[4],"comments":[32],"pagination":[32],"total":[32],"showPlaceholder":[32],"nextPage":[32],"mostHelpfulLabel":[32],"noComments":[32],"comment_title":[32],"comment_name":[32],"placeholder_text":[32],"showRatingSummary":[32],"allowLikes":[32],"reload":[64]}],[4,"salla-product-size-guide",{"guides":[32],"productId":[32],"placeholder_title":[32],"placeholder_description":[32],"modal_title":[32],"hasError":[32],"open":[64],"close":[64]}],[0,"salla-rating-modal",{"orderId":[2,"order-id"],"order":[32],"hasError":[32],"showContactWidget":[32],"errorMessage":[32],"dragAndDropFilesLabel":[32],"contactSubjectLabel":[32],"editReviewLabel":[32],"allowedImagesTypesLabel":[32],"addImagesLabel":[32],"editImagesLabel":[32],"threeImagesMax":[32],"areYouSureLabel":[32],"confirmDeletionLabel":[32],"cancelLabel":[32],"confirmDeleteBtn":[32],"updatedSuccessfullyLabel":[32],"deletedSuccessfullyLabel":[32],"allowAttachImages":[32],"allowContactSupport":[32],"contactUsLabel":[32],"images":[32],"productImages":[32],"editItemImages":[32],"contact_body":[32],"editMode":[32],"defaultMode":[32],"deleteMode":[32],"shouldOpenDeleteModal":[32],"editType":[32],"editFeedbackId":[32],"deleteFeedbackId":[32],"editItem":[32],"open":[64],"close":[64]}],[4,"salla-scopes",{"selection":[1],"searchDisplayLimit":[2,"search-display-limit"],"translationLoaded":[32],"mode":[32],"current_scope":[32],"scopes":[32],"originalScopesList":[32],"selected_scope":[32],"isOpenedBefore":[32],"hasError":[32],"loading":[32],"close":[64],"open":[64],"handleSubmit":[64]}],[0,"salla-localization-modal",{"language":[1537],"currency":[1537],"translationLoaded":[32],"languages":[32],"currencies":[32],"hasError":[32],"errorMessage":[32],"open":[64],"close":[64],"submit":[64]}],[0,"salla-user-profile",{"customFields":[1,"custom-fields"],"minAge":[2,"min-age"],"userData":[32],"isEditable":[32],"userDefinedFields":[32],"disableAction":[32],"isLoading":[32],"first_name_trans":[32],"last_name_trans":[32],"birthday_trans":[32],"birthday_placeholder_trans":[32],"gender_trans":[32],"gender_placeholder_trans":[32],"male_trans":[32],"female_trans":[32],"email_trans":[32],"mobile_trans":[32],"save_btn_trans":[32],"drag_and_drop_trans":[32],"browse_trans":[32],"email_required_trans":[32],"invalid_email_trans":[32],"setCustomFields":[64]}],[0,"salla-bottom-alert",{"type":[513],"icon":[513],"message":[513],"actionUrl":[513,"action-url"],"actionLabel":[513,"action-label"],"storeId":[32],"template":[32],"loading":[32],"templateData":[32],"defaultMessage":[32],"defaultActionLabel":[32],"storeFeatures":[32],"storeDetails":[32],"storePrice":[32],"theDeveloper":[32],"templateInformation":[32],"buyTheTemplate":[32],"isRtl":[32]}],[0,"salla-quick-order",{"quickOrderTitle":[1025,"quick-order-title"],"subTitle":[1025,"sub-title"],"payButtonTitle":[1025,"pay-button-title"],"confirmPayButtonTitle":[1025,"confirm-pay-button-title"],"agreementText":[1025,"agreement-text"],"isEmailRequired":[1028,"is-email-required"],"productId":[1025,"product-id"],"thanksMessage":[1025,"thanks-message"],"quickOrderStyle":[1025,"quick-order-style"],"user":[32],"isAvailable":[32],"oneClick":[32],"expanded":[32],"isTermsRequired":[32],"countryCode":[32],"submitSucess":[32],"placeHolderEmail":[32],"emailOptional":[32],"agreementShowText":[32],"agreementModalHead":[32],"userNameLabel":[32],"termsChecked":[32]}],[0,"salla-user-settings",{"deactivateAccount":[32],"promotionalMsgs":[32],"hideMyName":[32],"hideMyNameDesc":[32],"deactivateDesc":[32],"promotionalMsgsDesc":[32],"sorryForLeavingText":[32],"warningText":[32],"keepAccount":[32],"buttonLoading":[32],"canHideName":[32],"isHiddenName":[32],"isNotifiable":[32]}],[0,"salla-search",{"inline":[4],"oval":[4],"height":[2],"maxWords":[2,"max-words"],"showAction":[4,"show-action"],"translationLoaded":[32],"results":[32],"loading":[32],"typing":[32],"debounce":[32],"search_term":[32]},[[0,"keydown","handleKeyDown"]],{"search_term":["handleSearch"]}],[0,"salla-login-modal",{"isEmailAllowed":[1028,"is-email-allowed"],"isMobileAllowed":[1028,"is-mobile-allowed"],"isEmailRequired":[1028,"is-email-required"],"supportWebAuth":[516,"support-web-auth"],"inline":[516],"storeId":[1032,"store-id"],"api":[1],"headers":[1025],"withoutReload":[1028,"without-reload"],"messages":[32],"isClosable":[32],"iframeLoaded":[32],"scrolling":[32],"direction":[32],"canRenderIframe":[32],"open":[64]}],[0,"salla-menu",{"source":[1],"sourceValue":[1,"source-value"],"topnav":[4],"useReactLink":[4,"use-react-link"],"limit":[2],"menus":[32]}],[4,"salla-social-share",{"url":[513],"urlName":[513,"url-name"],"platforms":[513],"opened":[32],"allPlatforms":[32],"platformIcons":[32],"convertedPlatforms":[32],"open":[64],"refresh":[64]}],[0,"salla-breadcrumb",{"breadcrumbs":[32]}],[4,"salla-cart-summary",{"showCartLabel":[4,"show-cart-label"],"cartSummaryCount":[32],"cartSummaryTotal":[32],"cartLabel":[32],"animateToCart":[64]}],[4,"salla-infinite-scroll",{"nextPage":[1,"next-page"],"autoload":[1028],"container":[1],"loadMoreText":[1,"load-more-text"],"item":[1],"loadMore":[32],"noMore":[32],"failedToLoad":[32]}],[0,"salla-maintenance-alert",{"title":[32],"message":[32],"buttonTitle":[32]}],[4,"salla-quantity-input",{"cartItemId":[8,"cart-item-id"],"quantity":[32],"fireChangeEvent":[32],"decrease":[64],"increase":[64],"setValue":[64]},null,{"quantity":["watchPropHandler"]}],[4,"salla-user-menu",{"inline":[516],"avatarOnly":[516,"avatar-only"],"showHeader":[516,"show-header"],"relativeDropdown":[516,"relative-dropdown"],"accountLoading":[32],"opened":[32],"notifications":[32],"orders":[32],"pending_orders":[32],"wishlist":[32],"profile":[32],"rating":[32],"wallet":[32],"logout":[32],"hello":[32],"first_name":[32],"last_name":[32],"avatar":[32],"is_loggedIn":[32],"badges":[32],"hasBadges":[32],"OrderUpdate":[32]}],[0,"salla-products-slider",{"blockTitle":[1,"block-title"],"subTitle":[1,"sub-title"],"sliderId":[1,"slider-id"],"displayAllUrl":[1,"display-all-url"],"autoplay":[1028],"source":[1537],"sourceValue":[1,"source-value"],"limit":[1026],"sliderConfig":[520,"slider-config"],"productCardComponent":[1,"product-card-component"],"includes":[1040],"productsData":[32],"isReady":[32],"sourceValueIsValid":[32],"hasCustomComponent":[32],"apiUrl":[32],"parsedSourceValue":[32]}],[4,"salla-map",{"name":[1],"required":[4],"readonly":[4],"searchable":[1028],"lat":[1026],"lng":[1026],"apiKey":[1025,"api-key"],"modalTitle":[1,"modal-title"],"zoom":[1026],"theme":[1025],"modalActivityTitle":[32],"confirmButtonTitle":[32],"locateButtonTitle":[32],"locateButtonEdit":[32],"searchPlaceholder":[32],"searchInputValue":[32],"formattedAddress":[32],"geolocationError":[32],"searchInput":[32],"mapInput":[32],"mapElement":[32],"selectedLat":[32],"selectedLng":[32],"open":[64]}],[0,"salla-reviews-summary",{"itemId":[2,"item-id"],"data":[32],"canRender":[32],"basedOnLabel":[32],"recommendedLabel":[32],"showRatingSummary":[32],"recommendationOnly":[32],"showRecommendation":[32]}],[0,"salla-comment-form",{"type":[1537],"showAvatar":[4,"show-avatar"],"itemId":[1544,"item-id"],"placeholder":[32],"submitText":[32],"canComment":[32]}],[4,"salla-color-picker",{"name":[1],"required":[4],"color":[1537],"format":[1],"showCancelButton":[4,"show-cancel-button"],"showTextField":[4,"show-text-field"],"enableAlpha":[4,"enable-alpha"],"widgetColor":[32],"setPickerOption":[64],"movePopUp":[64],"setColorValue":[64],"openPicker":[64],"closePicker":[64],"destroyPicker":[64]}],[0,"salla-products-list",{"source":[1537],"sourceValue":[1032,"source-value"],"limit":[1026],"sortBy":[1025,"sort-by"],"filtersResults":[1540,"filters-results"],"horizontalCards":[516,"horizontal-cards"],"rowCards":[516,"row-cards"],"autoload":[1028],"loadMoreText":[1,"load-more-text"],"productCardComponent":[1,"product-card-component"],"includes":[1040],"page":[32],"nextPage":[32],"hasInfiniteScroll":[32],"hasCustomComponent":[32],"sourceValueIsValid":[32],"placeholderText":[32],"endOfText":[32],"failedLoadMore":[32],"currentPage":[32],"currentCategoryIdFilter":[32],"isReady":[32],"showPlaceholder":[32],"switchToNormalBehavior":[32],"parsedFilters":[32],"filtersSnapshot":[32],"setFilters":[64],"reload":[64]}],[0,"salla-comment-item",{"comment":[16],"hideBought":[16,"hide-bought"],"has_bought_trans":[32],"rated_trans":[32],"waiting_approval_trans":[32],"has_order_trans":[32],"allowLikes":[32],"allowAttachImages":[32],"helpfulLabel":[32],"likesCount":[32],"likedComments":[32]}],[4,"salla-tab-content",{"name":[1],"isSelected":[32],"getChild":[64]}],[4,"salla-tab-header",{"name":[1],"activeClass":[1,"active-class"],"height":[8],"centered":[4],"isSelected":[32],"getChild":[64]}],[4,"salla-tabs",{"backgroundColor":[1,"background-color"],"vertical":[4]},[[0,"tabSelected","onSelectedTab"]]],[4,"salla-product-card",{"product":[1],"horizontal":[4],"shadowOnHover":[4,"shadow-on-hover"],"hideAddBtn":[4,"hide-add-btn"],"fullImage":[4,"full-image"],"minimal":[4],"isSpecial":[4,"is-special"],"showQuantity":[4,"show-quantity"],"productData":[32],"fitImageHeight":[32],"remained":[32],"outOfStock":[32],"donationAmount":[32],"startingPrice":[32],"addToCart":[32],"placeholder":[32]}],[0,"salla-datetime-picker",{"value":[1537],"required":[4],"name":[513],"placeholder":[1],"allowInput":[4,"allow-input"],"allowInvalidPreload":[4,"allow-invalid-preload"],"altFormat":[1,"alt-format"],"altInput":[4,"alt-input"],"altInputClass":[1,"alt-input-class"],"appendTo":[16,"append-to"],"ariaDateFormat":[1,"aria-date-format"],"autoFillDefaultTime":[4,"auto-fill-default-time"],"clickOpens":[4,"click-opens"],"closeOnSelect":[4,"close-on-select"],"conjunction":[1],"dateFormat":[1,"date-format"],"defaultDate":[8,"default-date"],"defaultHour":[2,"default-hour"],"defaultMinute":[2,"default-minute"],"defaultSeconds":[2,"default-seconds"],"disable":[16],"disableMobile":[4,"disable-mobile"],"enable":[16],"enableSeconds":[4,"enable-seconds"],"enableTime":[4,"enable-time"],"formatDate":[16,"format-date"],"hourIncrement":[2,"hour-increment"],"inline":[4],"locale":[1],"maxDate":[8,"max-date"],"maxTime":[8,"max-time"],"minDate":[8,"min-date"],"minTime":[8,"min-time"],"minuteIncrement":[2,"minute-increment"],"mode":[1],"monthSelectorType":[1,"month-selector-type"],"nextArrow":[1,"next-arrow"],"noCalendar":[4,"no-calendar"],"dateParser":[16,"date-parser"],"position":[1],"positionElement":[16,"position-element"],"prevArrow":[1,"prev-arrow"],"shorthandCurrentMonth":[4,"shorthand-current-month"],"static":[4],"showMonths":[2,"show-months"],"time_24hr":[4,"time_-2-4hr"],"weekNumbers":[4,"week-numbers"],"wrap":[4],"disabled":[4]}],[4,"salla-add-product-button",{"channels":[513],"subscribedOptions":[1,"subscribed-options"],"quickBuy":[1540,"quick-buy"],"quantity":[514],"donatingAmount":[514,"donating-amount"],"notifyOptionsAvailability":[516,"notify-options-availability"],"productId":[520,"product-id"],"supportStickyBar":[516,"support-sticky-bar"],"productStatus":[513,"product-status"],"productType":[513,"product-type"],"hasOutOfStockOption":[32],"hasSubscribedOptions":[32],"selectedOptions":[32],"showQuickBuy":[32],"isApplePayActive":[32],"buyNowText":[32]}],[0,"salla-count-down",{"date":[1],"boxed":[4],"size":[1],"color":[1],"labeled":[4],"endText":[1,"end-text"],"digits":[1],"endOfDay":[4,"end-of-day"],"daysLabel":[32],"hoursLabel":[32],"minutesLabel":[32],"secondsLabel":[32],"endLabel":[32],"invalidDate":[32],"offerEnded":[32],"countInterval":[32],"days":[32],"hours":[32],"minutes":[32],"seconds":[32],"endCountDown":[64]}],[0,"salla-file-upload",{"value":[1544],"files":[513],"height":[513],"cartItemId":[1,"cart-item-id"],"profileImage":[516,"profile-image"],"name":[1537],"payloadName":[1,"payload-name"],"type":[1],"accept":[1537],"fileId":[2,"file-id"],"url":[1025],"method":[1],"formData":[1,"form-data"],"required":[4],"maxFileSize":[1,"max-file-size"],"disabled":[4],"allowDrop":[4,"allow-drop"],"allowBrowse":[4,"allow-browse"],"allowPaste":[4,"allow-paste"],"allowMultiple":[4,"allow-multiple"],"allowReplace":[4,"allow-replace"],"allowRevert":[4,"allow-revert"],"allowRemove":[4,"allow-remove"],"allowProcess":[4,"allow-process"],"allowReorder":[4,"allow-reorder"],"allowImagePreview":[4,"allow-image-preview"],"imagePreviewHeight":[2,"image-preview-height"],"filePosterHeight":[2,"file-poster-height"],"storeAsFile":[4,"store-as-file"],"forceRevert":[4,"force-revert"],"maxFilesCount":[2,"max-files-count"],"maxParallelUploads":[2,"max-parallel-uploads"],"checkValidity":[4,"check-validity"],"itemInsertLocation":[1,"item-insert-location"],"itemInsertInterval":[2,"item-insert-interval"],"credits":[4],"dropOnPage":[4,"drop-on-page"],"dropOnElement":[4,"drop-on-element"],"dropValidation":[4,"drop-validation"],"ignoredFiles":[16,"ignored-files"],"instantUpload":[1028,"instant-upload"],"chunkUploads":[4,"chunk-uploads"],"chunkForce":[4,"chunk-force"],"chunkSize":[2,"chunk-size"],"chunkRetryDelays":[16,"chunk-retry-delays"],"labelDecimalSeparator":[1,"label-decimal-separator"],"labelThousandsSeparator":[1,"label-thousands-separator"],"labelIdle":[1025,"label-idle"],"iconRemove":[1,"icon-remove"],"iconProcess":[1,"icon-process"],"iconRetry":[1,"icon-retry"],"iconUndo":[1,"icon-undo"],"max_images_count":[32],"max_count_hint":[32],"uploadedFiles":[32],"isListScrollerListenerAdded":[32],"showMaxCountHint":[32],"setOption":[64]}],[4,"salla-list-tile",{"href":[1],"target":[1]}],[0,"salla-product-availability",{"channels":[1],"notifyOptionsAvailability":[4,"notify-options-availability"],"productId":[2,"product-id"],"isSubscribed":[1028,"is-subscribed"],"translationLoaded":[32],"title_":[32],"isVisitorSubscribed":[32]},null,{"channels":["channelsWatcher"]}],[0,"salla-quick-buy",{"type":[1025],"productId":[1025,"product-id"],"cartId":[1025,"cart-id"],"amount":[1538],"currency":[1025],"options":[16],"isRequireShipping":[1028,"is-require-shipping"],"applePayOnly":[1028,"apple-pay-only"],"isApplePayActive":[32],"quickBuy":[32]}],[0,"salla-progress-bar",{"donation":[1],"target":[1026],"value":[1026],"height":[1025],"header":[1025],"stripped":[1028],"message":[1025],"unit":[1025],"color":[1025],"hideUnits":[4,"hide-units"]}],[0,"salla-rating-stars",{"name":[1],"size":[1],"value":[2],"reviews":[2],"withLabel":[4,"with-label"],"editable":[4],"translationsLoaded":[32],"labels":[32],"reviewLabel":[32],"selectedStar":[32]}],[4,"salla-placeholder",{"icon":[1],"alignment":[1],"iconSize":[1,"icon-size"],"translationLoaded":[32]}],[0,"salla-skeleton",{"type":[1],"width":[1],"height":[1]}],[4,"salla-slider",{"blockTitle":[513,"block-title"],"listenToThumbnailsOption":[516,"listen-to-thumbnails-option"],"blockSubtitle":[513,"block-subtitle"],"displayAllUrl":[513,"display-all-url"],"arrowsCentered":[516,"arrows-centered"],"verticalThumbs":[516,"vertical-thumbs"],"gridThumbs":[516,"grid-thumbs"],"vertical":[516],"autoHeight":[516,"auto-height"],"showControls":[516,"show-controls"],"controlsOuter":[516,"controls-outer"],"showThumbsControls":[4,"show-thumbs-controls"],"autoPlay":[4,"auto-play"],"slidesPerView":[1,"slides-per-view"],"pagination":[4],"centered":[4],"loop":[4],"direction":[1537],"type":[1],"sliderConfig":[520,"slider-config"],"thumbsConfig":[520,"thumbs-config"],"currentIndex":[32],"isEnd":[32],"isBeginning":[32],"swiperScript":[32],"displayAllTitle":[32],"windowWidth":[32],"sliderInstance":[64],"slideTo":[64],"slideNext":[64],"slidePrev":[64],"slideToLoop":[64],"slideNextLoop":[64],"slidePrevLoop":[64],"slideReset":[64],"slideToClosest":[64],"update":[64],"updateAutoHeight":[64],"updateSlides":[64],"updateProgress":[64],"updateSlidesClasses":[64],"getSlides":[64],"updateSize":[64],"sliderInit":[64],"thumbsSliderInstance":[64],"thumbsSliderInit":[64],"thumbsSliderUpdate":[64],"thumbsSliderUpdateSlides":[64],"getThumbsUpdateSize":[64],"thumbsSlideTo":[64],"getThumbsSlides":[64]}],[0,"salla-tel-input",{"phone":[1025],"autofocus":[516],"name":[1],"disabled":[4],"countryCode":[1025,"country-code"],"mobileRequired":[32],"countryCodeLabel":[32],"mobileLabel":[32],"tooShort":[32],"tooLong":[32],"invalidCountryCode":[32],"invalidNumber":[32],"errorMap":[32],"getValues":[64],"isValid":[64]}],[4,"salla-modal",{"isClosable":[1028,"is-closable"],"width":[513],"position":[513],"visible":[516],"hasSkeleton":[516,"has-skeleton"],"isLoading":[1540,"is-loading"],"subTitleFirst":[4,"sub-title-first"],"noPadding":[4,"no-padding"],"subTitle":[1,"sub-title"],"centered":[4],"iconStyle":[1,"icon-style"],"modalTitle":[32],"open":[64],"close":[64],"setTitle":[64],"loading":[64],"stopLoading":[64]},[[0,"keyup","handleKeyUp"]],{"visible":["handleVisible"]}],[0,"salla-loading",{"size":[8],"width":[8],"color":[1],"bgColor":[1,"bg-color"]}],[4,"salla-button",{"shape":[513],"color":[513],"fill":[513],"size":[513],"width":[513],"loading":[516],"disabled":[516],"loaderPosition":[1,"loader-position"],"href":[1],"type":[513],"load":[64],"stop":[64],"setText":[64],"disable":[64],"enable":[64]}]]],["p-aecbfd1d",[[0,"salla-booking-field",{"option":[16],"productId":[2,"product-id"],"bookNowLabel":[32],"editLabel":[32],"bookedLabel":[32],"selectDate":[32],"bookingUrl":[32],"iframeReady":[32],"reservations":[32],"reservationsInput":[32]}],[4,"salla-conditional-fields",null,[[0,"change","changeHandler"]]]]],["p-7222192c",[[0,"salla-price-range",{"minPrice":[1032,"min-price"],"maxPrice":[1032,"max-price"],"option":[16],"filtersData":[520,"filters-data"],"min":[32],"max":[32],"priceOptions":[32],"moreThanLabel":[32],"lessThanLabel":[32],"toLabel":[32],"fromLabel":[32],"typing":[32],"isMin":[32],"isRTL":[32],"reset":[64]}]]]]'),e)}));
4
+ import{p as e,b as a}from"./p-CayW-agT.js";export{s as setNonce}from"./p-CayW-agT.js";import{g as t}from"./p-PnQHllOh.js";var l=()=>{const a=import.meta.url;const t={};if(a!==""){t.resourcesUrl=new URL(".",a).href}return e(t)};l().then((async e=>{await t();return a(JSON.parse('[["p-d0912efd",[[0,"salla-offer",{"productCardComponent":[1,"product-card-component"],"offersList":[32],"userCurrency":[32],"isMultipleBank":[32],"title":[32],"currentPage":[32],"hasCustomComponent":[32],"isBankOffer":[32],"canRender":[32],"showOffer":[32],"offer_with_price_text":[32],"with_discount_text":[32],"product_discount_text":[32],"special_offer_text":[32],"multipleBankOfferTitleText":[32],"multipleBankOfferTitleDescription":[32],"buy_quantity_text":[32]}]]],["p-fdd3788a",[[0,"salla-product-options",{"productId":[2,"product-id"],"options":[1],"hideOutLabel":[1,"hide-out-label"],"uniqueKey":[1,"unique-key"],"config":[1],"optionsData":[32],"outOfStockText":[32],"donationAmount":[32],"selectDonationAmount":[32],"selectAmount":[32],"isCustomDonation":[32],"selectedOptions":[32],"canDisabled":[32],"selectedSkus":[32],"selectedOutSkus":[32],"disableCardValue":[32],"availableDigitalCardValues":[32],"setOptionsData":[64],"getSelectedOptionsData":[64],"reportValidity":[64],"hasOutOfStockOption":[64],"getSelectedOptions":[64],"getOption":[64]}]]],["p-51195e76",[[0,"salla-filters",{"filters":[1040],"isSidebarOpen":[32],"filtersData":[32],"apply":[32],"reset":[32],"getFilters":[64],"applyFilters":[64],"resetFilters":[64]}]]],["p-316e3ea9",[[4,"salla-verify",{"display":[1],"type":[1025],"autoReload":[4,"auto-reload"],"supportWebAuth":[4,"support-web-auth"],"translationLoaded":[32],"title":[32],"resendAfter":[32],"hasError":[32],"errorMessage":[32],"isProfileVerify":[32],"getCode":[64],"open":[64]}]]],["p-247636ef",[[0,"salla-notifications",{"loadMoreText":[1,"load-more-text"],"itemPerPage":[2,"item-per-page"],"pagination":[32],"total":[32],"showPlaceholder":[32],"nextPage":[32],"no_notifications_trans":[32],"load_more_text_trans":[32]}]]],["p-1dd178a2",[[0,"salla-order-summary",{"orderId":[514,"order-id"],"codeCopied":[32],"noItemFound":[32],"order_items":[32]}]]],["p-e084e3c4",[[0,"salla-reviews",{"displayAllLink":[516,"display-all-link"],"source":[513],"sourceValue":[513,"source-value"],"limit":[514],"type":[1],"sort":[1],"hideCustomerInfo":[4,"hide-customer-info"],"reviews":[32],"isRTL":[32],"showReviews":[32],"testimonialText":[32],"displayAllLinkText":[32]}]]],["p-0649d076",[[0,"salla-reviews-page",{"reviews":[32],"isLoading":[32],"pagination":[32],"sort":[32]}]]],["p-41480e7b",[[0,"salla-wallet",{"transactionsArray":[32],"balance":[32],"isLoading":[32],"nextPageUrl":[32]}]]],["p-952a8078",[[0,"salla-conditional-offer",{"offer":[32],"products":[32],"isLoading":[32],"canRender":[32]}]]],["p-b63bc4db",[[0,"salla-orders",{"params":[16],"loadMoreText":[1,"load-more-text"],"orderNumberText":[32],"totalOrderText":[32],"orderDateText":[32],"orderStatusText":[32],"noOrderText":[32],"load_more_text_trans":[32],"languageCode":[32],"orders":[32],"pagination":[32],"hasInfiniteScroll":[32],"total":[32],"nextPage":[32],"showPlaceholder":[32]}]]],["p-33963e7d",[[0,"salla-advertisement",{"position":[32],"advertisements":[32],"advertIcon":[32],"currentSlug":[32]}]]],["p-9361e7a2",[[0,"salla-app-install-alert",{"data":[32],"ctaLink":[32],"open":[32],"closing":[32]}]]],["p-8c9ae8bd",[[0,"salla-apps-icons",{"hideTitle":[4,"hide-title"],"appsTitle":[1,"apps-title"],"vertical":[4],"apps":[32]}]]],["p-d600f506",[[0,"salla-cart-item-offers",{"quantity":[2],"offers":[1],"itemId":[2,"item-id"],"productPrice":[2,"product-price"],"internalQuantity":[32],"internalOffers":[32],"internalProductPrice":[32],"showAll":[32],"freeLabel":[32],"receivedOffer":[32],"discountAmountLabel":[32],"showMoreOffers":[32]}]]],["p-41ecc4f7",[[0,"salla-contacts",{"contactsTitle":[1025,"contacts-title"],"hideTitle":[4,"hide-title"],"isHeader":[4,"is-header"],"horizontal":[4],"iconsOnly":[4,"icons-only"],"contacts":[32],"iconsList":[32]}]]],["p-aa6a0113",[[0,"salla-installment",{"price":[1],"language":[1],"currency":[1],"country":[1],"tabbyIsActive":[32],"spotiiIsActive":[32],"tamaraIsActive":[32],"mispayActive":[32],"emkanIsActive":[32],"madfuActive":[32],"rajehiIsActive":[32],"installment_sheria_text":[32]}]]],["p-4ced9aab",[[0,"salla-loyalty-prize-item",{"item":[16]}]]],["p-2d0c2877",[[0,"salla-metadata",{"entity":[1],"entityId":[8,"entity-id"],"specs":[32],"download":[32]}]]],["p-e9ca7e7c",[[0,"salla-payments",{"exclude":[1040]}]]],["p-20bdcd53",[[0,"salla-social",{"links":[32],"iconsList":[32]}]]],["p-37a3c661",[[4,"salla-filters-widget",{"withLoadMore":[1028,"with-load-more"],"filtersData":[16,"filters-data"],"option":[16],"isOpen":[32],"isShowMore":[32],"showMoreLabel":[32],"showLessLabel":[32],"page":[32],"setWidgetHeight":[64],"reset":[64],"showMore":[64],"toggleWidget":[64]}]]],["p-269ebd5d",[[0,"salla-notification-item",{"notification":[16]}]]],["p-756fe45d",[[0,"salla-review-card",{"review":[16],"currentSlide":[32],"purchasedCount":[32],"showPurchaseCount":[32]}]]],["p-19f533ec",[[4,"salla-tooltip",{"text":[1],"targetId":[1,"target-id"],"show":[32]},[[9,"mouseover","handleMouseOver"],[9,"mouseout","handleMouseOut"]]]]],["p-9ca8c6b6",[[0,"salla-offer-modal",{"offer":[32],"offer_name":[32],"offer_message":[32],"hasError":[32],"errorMessage":[32],"productID":[32],"offer_type":[32],"translationLoaded":[32],"addToCartLabel":[32],"open":[64],"showOffer":[64]}],[4,"salla-gifting",{"productId":[2,"product-id"],"widgetTitle":[1,"widget-title"],"widgetSubtitle":[1,"widget-subtitle"],"physicalProducts":[4,"physical-products"],"vertical":[4],"sectionTitle":[32],"sectionSubtitle":[32],"sectionBtnText":[32],"giftDetails":[32],"selectImageForYourGift":[32],"selectImageOrUpload":[32],"selectGiftMessage":[32],"giftCustomText":[32],"textId":[32],"incorrectGiftText":[32],"nextStep":[32],"senderNameLabel":[32],"receiverNameFieldLabel":[32],"receiverMobileFieldLabel":[32],"receiverCountryFieldLabel":[32],"ksa":[32],"selectCity":[32],"selectCityInfo":[32],"receiverCityFieldLabel":[32],"receiverEmailFieldLabel":[32],"emailPlaceholder":[32],"sendLater":[32],"selectSendDateAndTime":[32],"canNotEditOrderAfterSelectDate":[32],"sendGift":[32],"donationRequired":[32],"currentStep":[32],"showCalendar":[32],"showGiftText":[32],"currentLang":[32],"parentClass":[32],"errors":[32],"gift":[32],"selectedGiftTextOption":[32],"showTextArea":[32],"selectedImage":[32],"uploadedImage":[32],"selectedText":[32],"senderName":[32],"errorMessage":[32],"hasError":[32],"quantity":[32],"deliveryDate":[32],"timeZone":[32],"receiverName":[32],"receiverMobile":[32],"receiverCountryCode":[32],"receiverEmail":[32],"hostId":[32],"receiverCity":[32],"open":[64],"close":[64],"goToStep2":[64]}],[4,"salla-loyalty",{"prizePoints":[1544,"prize-points"],"customerPoints":[1538,"customer-points"],"prizeTitle":[1537,"prize-title"],"allowEmail":[4,"allow-email"],"allowMobile":[4,"allow-mobile"],"requireEmail":[4,"require-email"],"guestMessage":[1025,"guest-message"],"loyaltyProgram":[32],"buttonLoading":[32],"selectedItem":[32],"askConfirmation":[32],"is_loggedin":[32],"hasError":[32],"errorMessage":[32],"translationLoaded":[32],"open":[64],"close":[64],"resetExchange":[64],"exchangeLoyaltyPoint":[64]}],[0,"salla-comments",{"itemId":[2,"item-id"],"loadMoreText":[1,"load-more-text"],"hideForm":[4,"hide-form"],"blockTitle":[1,"block-title"],"hideTitle":[4,"hide-title"],"type":[1],"showFormAvatar":[4,"show-form-avatar"],"hideBought":[4,"hide-bought"],"sort":[1],"testimonials":[4],"comments":[32],"pagination":[32],"total":[32],"showPlaceholder":[32],"nextPage":[32],"mostHelpfulLabel":[32],"noComments":[32],"comment_title":[32],"comment_name":[32],"placeholder_text":[32],"showRatingSummary":[32],"allowLikes":[32],"reload":[64]}],[4,"salla-product-size-guide",{"guides":[32],"productId":[32],"placeholder_title":[32],"placeholder_description":[32],"modal_title":[32],"hasError":[32],"open":[64],"close":[64]}],[0,"salla-rating-modal",{"orderId":[2,"order-id"],"order":[32],"hasError":[32],"showContactWidget":[32],"errorMessage":[32],"dragAndDropFilesLabel":[32],"contactSubjectLabel":[32],"editReviewLabel":[32],"allowedImagesTypesLabel":[32],"addImagesLabel":[32],"editImagesLabel":[32],"threeImagesMax":[32],"areYouSureLabel":[32],"confirmDeletionLabel":[32],"cancelLabel":[32],"confirmDeleteBtn":[32],"updatedSuccessfullyLabel":[32],"deletedSuccessfullyLabel":[32],"allowAttachImages":[32],"allowContactSupport":[32],"contactUsLabel":[32],"images":[32],"productImages":[32],"editItemImages":[32],"contact_body":[32],"editMode":[32],"defaultMode":[32],"deleteMode":[32],"shouldOpenDeleteModal":[32],"editType":[32],"editFeedbackId":[32],"deleteFeedbackId":[32],"editItem":[32],"open":[64],"close":[64]}],[4,"salla-scopes",{"selection":[1],"searchDisplayLimit":[2,"search-display-limit"],"translationLoaded":[32],"mode":[32],"current_scope":[32],"scopes":[32],"originalScopesList":[32],"selected_scope":[32],"isOpenedBefore":[32],"hasError":[32],"loading":[32],"close":[64],"open":[64],"handleSubmit":[64]}],[0,"salla-localization-modal",{"language":[1537],"currency":[1537],"translationLoaded":[32],"languages":[32],"currencies":[32],"hasError":[32],"errorMessage":[32],"open":[64],"close":[64],"submit":[64]}],[0,"salla-user-profile",{"customFields":[1,"custom-fields"],"minAge":[2,"min-age"],"userData":[32],"isEditable":[32],"userDefinedFields":[32],"disableAction":[32],"isLoading":[32],"first_name_trans":[32],"last_name_trans":[32],"birthday_trans":[32],"birthday_placeholder_trans":[32],"gender_trans":[32],"gender_placeholder_trans":[32],"male_trans":[32],"female_trans":[32],"email_trans":[32],"mobile_trans":[32],"save_btn_trans":[32],"drag_and_drop_trans":[32],"browse_trans":[32],"email_required_trans":[32],"invalid_email_trans":[32],"setCustomFields":[64]}],[0,"salla-bottom-alert",{"type":[513],"icon":[513],"message":[513],"actionUrl":[513,"action-url"],"actionLabel":[513,"action-label"],"storeId":[32],"template":[32],"loading":[32],"templateData":[32],"defaultMessage":[32],"defaultActionLabel":[32],"storeFeatures":[32],"storeDetails":[32],"storePrice":[32],"theDeveloper":[32],"templateInformation":[32],"buyTheTemplate":[32],"isRtl":[32]}],[0,"salla-quick-order",{"quickOrderTitle":[1025,"quick-order-title"],"subTitle":[1025,"sub-title"],"payButtonTitle":[1025,"pay-button-title"],"confirmPayButtonTitle":[1025,"confirm-pay-button-title"],"agreementText":[1025,"agreement-text"],"isEmailRequired":[1028,"is-email-required"],"productId":[1025,"product-id"],"thanksMessage":[1025,"thanks-message"],"quickOrderStyle":[1025,"quick-order-style"],"user":[32],"isAvailable":[32],"oneClick":[32],"expanded":[32],"isTermsRequired":[32],"countryCode":[32],"submitSucess":[32],"placeHolderEmail":[32],"emailOptional":[32],"agreementShowText":[32],"agreementModalHead":[32],"userNameLabel":[32],"termsChecked":[32]}],[0,"salla-user-settings",{"deactivateAccount":[32],"promotionalMsgs":[32],"hideMyName":[32],"hideMyNameDesc":[32],"deactivateDesc":[32],"promotionalMsgsDesc":[32],"sorryForLeavingText":[32],"warningText":[32],"keepAccount":[32],"buttonLoading":[32],"canHideName":[32],"isHiddenName":[32],"isNotifiable":[32]}],[0,"salla-search",{"inline":[4],"oval":[4],"height":[2],"maxWords":[2,"max-words"],"showAction":[4,"show-action"],"translationLoaded":[32],"results":[32],"loading":[32],"typing":[32],"debounce":[32],"search_term":[32]},[[0,"keydown","handleKeyDown"]],{"search_term":["handleSearch"]}],[0,"salla-login-modal",{"isEmailAllowed":[1028,"is-email-allowed"],"isMobileAllowed":[1028,"is-mobile-allowed"],"isEmailRequired":[1028,"is-email-required"],"supportWebAuth":[516,"support-web-auth"],"inline":[516],"storeId":[1032,"store-id"],"api":[1],"headers":[1025],"withoutReload":[1028,"without-reload"],"messages":[32],"isClosable":[32],"iframeLoaded":[32],"scrolling":[32],"direction":[32],"canRenderIframe":[32],"open":[64]}],[0,"salla-menu",{"source":[1],"sourceValue":[1,"source-value"],"topnav":[4],"useReactLink":[4,"use-react-link"],"limit":[2],"menus":[32]}],[4,"salla-social-share",{"url":[513],"urlName":[513,"url-name"],"platforms":[513],"opened":[32],"allPlatforms":[32],"platformIcons":[32],"convertedPlatforms":[32],"open":[64],"refresh":[64]}],[0,"salla-breadcrumb",{"breadcrumbs":[32]}],[4,"salla-cart-summary",{"showCartLabel":[4,"show-cart-label"],"cartSummaryCount":[32],"cartSummaryTotal":[32],"cartLabel":[32],"animateToCart":[64]}],[4,"salla-infinite-scroll",{"nextPage":[1,"next-page"],"autoload":[1028],"container":[1],"loadMoreText":[1,"load-more-text"],"item":[1],"loadMore":[32],"noMore":[32],"failedToLoad":[32]}],[0,"salla-maintenance-alert",{"title":[32],"message":[32],"buttonTitle":[32]}],[4,"salla-quantity-input",{"cartItemId":[8,"cart-item-id"],"quantity":[32],"fireChangeEvent":[32],"decrease":[64],"increase":[64],"setValue":[64]},null,{"quantity":["watchPropHandler"]}],[4,"salla-user-menu",{"inline":[516],"avatarOnly":[516,"avatar-only"],"showHeader":[516,"show-header"],"relativeDropdown":[516,"relative-dropdown"],"accountLoading":[32],"opened":[32],"notifications":[32],"orders":[32],"pending_orders":[32],"wishlist":[32],"profile":[32],"rating":[32],"wallet":[32],"logout":[32],"hello":[32],"first_name":[32],"last_name":[32],"avatar":[32],"is_loggedIn":[32],"badges":[32],"hasBadges":[32],"OrderUpdate":[32]}],[0,"salla-products-slider",{"blockTitle":[1,"block-title"],"subTitle":[1,"sub-title"],"sliderId":[1,"slider-id"],"displayAllUrl":[1,"display-all-url"],"autoplay":[1028],"source":[1537],"sourceValue":[1,"source-value"],"limit":[1026],"sliderConfig":[520,"slider-config"],"productCardComponent":[1,"product-card-component"],"includes":[1040],"productsData":[32],"isReady":[32],"sourceValueIsValid":[32],"hasCustomComponent":[32],"apiUrl":[32],"parsedSourceValue":[32]}],[4,"salla-map",{"name":[1],"required":[4],"readonly":[4],"searchable":[1028],"lat":[1026],"lng":[1026],"apiKey":[1025,"api-key"],"modalTitle":[1,"modal-title"],"zoom":[1026],"theme":[1025],"modalActivityTitle":[32],"confirmButtonTitle":[32],"locateButtonTitle":[32],"locateButtonEdit":[32],"searchPlaceholder":[32],"searchInputValue":[32],"formattedAddress":[32],"geolocationError":[32],"searchInput":[32],"mapInput":[32],"mapElement":[32],"selectedLat":[32],"selectedLng":[32],"open":[64]}],[0,"salla-reviews-summary",{"itemId":[2,"item-id"],"data":[32],"canRender":[32],"basedOnLabel":[32],"recommendedLabel":[32],"showRatingSummary":[32],"recommendationOnly":[32],"showRecommendation":[32]}],[0,"salla-comment-form",{"type":[1537],"showAvatar":[4,"show-avatar"],"itemId":[1544,"item-id"],"placeholder":[32],"submitText":[32],"canComment":[32]}],[4,"salla-color-picker",{"name":[1],"required":[4],"color":[1537],"format":[1],"showCancelButton":[4,"show-cancel-button"],"showTextField":[4,"show-text-field"],"enableAlpha":[4,"enable-alpha"],"widgetColor":[32],"setPickerOption":[64],"movePopUp":[64],"setColorValue":[64],"openPicker":[64],"closePicker":[64],"destroyPicker":[64]}],[0,"salla-products-list",{"source":[1537],"sourceValue":[1032,"source-value"],"limit":[1026],"sortBy":[1025,"sort-by"],"filtersResults":[1540,"filters-results"],"horizontalCards":[516,"horizontal-cards"],"rowCards":[516,"row-cards"],"autoload":[1028],"loadMoreText":[1,"load-more-text"],"productCardComponent":[1,"product-card-component"],"includes":[1040],"page":[32],"nextPage":[32],"hasInfiniteScroll":[32],"hasCustomComponent":[32],"sourceValueIsValid":[32],"placeholderText":[32],"endOfText":[32],"failedLoadMore":[32],"currentPage":[32],"currentCategoryIdFilter":[32],"isReady":[32],"showPlaceholder":[32],"switchToNormalBehavior":[32],"parsedFilters":[32],"filtersSnapshot":[32],"setFilters":[64],"reload":[64]}],[0,"salla-comment-item",{"comment":[16],"hideBought":[16,"hide-bought"],"has_bought_trans":[32],"rated_trans":[32],"waiting_approval_trans":[32],"has_order_trans":[32],"allowLikes":[32],"allowAttachImages":[32],"helpfulLabel":[32],"likesCount":[32],"likedComments":[32]}],[4,"salla-tab-content",{"name":[1],"isSelected":[32],"getChild":[64]}],[4,"salla-tab-header",{"name":[1],"activeClass":[1,"active-class"],"height":[8],"centered":[4],"isSelected":[32],"getChild":[64]}],[4,"salla-tabs",{"backgroundColor":[1,"background-color"],"vertical":[4]},[[0,"tabSelected","onSelectedTab"]]],[4,"salla-product-card",{"product":[1],"horizontal":[4],"shadowOnHover":[4,"shadow-on-hover"],"hideAddBtn":[4,"hide-add-btn"],"fullImage":[4,"full-image"],"minimal":[4],"isSpecial":[4,"is-special"],"showQuantity":[4,"show-quantity"],"productData":[32],"fitImageHeight":[32],"remained":[32],"outOfStock":[32],"donationAmount":[32],"startingPrice":[32],"addToCart":[32],"placeholder":[32]}],[0,"salla-datetime-picker",{"value":[1537],"required":[4],"name":[513],"placeholder":[1],"allowInput":[4,"allow-input"],"allowInvalidPreload":[4,"allow-invalid-preload"],"altFormat":[1,"alt-format"],"altInput":[4,"alt-input"],"altInputClass":[1,"alt-input-class"],"appendTo":[16,"append-to"],"ariaDateFormat":[1,"aria-date-format"],"autoFillDefaultTime":[4,"auto-fill-default-time"],"clickOpens":[4,"click-opens"],"closeOnSelect":[4,"close-on-select"],"conjunction":[1],"dateFormat":[1,"date-format"],"defaultDate":[8,"default-date"],"defaultHour":[2,"default-hour"],"defaultMinute":[2,"default-minute"],"defaultSeconds":[2,"default-seconds"],"disable":[16],"disableMobile":[4,"disable-mobile"],"enable":[16],"enableSeconds":[4,"enable-seconds"],"enableTime":[4,"enable-time"],"formatDate":[16,"format-date"],"hourIncrement":[2,"hour-increment"],"inline":[4],"locale":[1],"maxDate":[8,"max-date"],"maxTime":[8,"max-time"],"minDate":[8,"min-date"],"minTime":[8,"min-time"],"minuteIncrement":[2,"minute-increment"],"mode":[1],"monthSelectorType":[1,"month-selector-type"],"nextArrow":[1,"next-arrow"],"noCalendar":[4,"no-calendar"],"dateParser":[16,"date-parser"],"position":[1],"positionElement":[16,"position-element"],"prevArrow":[1,"prev-arrow"],"shorthandCurrentMonth":[4,"shorthand-current-month"],"static":[4],"showMonths":[2,"show-months"],"time_24hr":[4,"time_-2-4hr"],"weekNumbers":[4,"week-numbers"],"wrap":[4],"disabled":[4]}],[4,"salla-add-product-button",{"channels":[513],"subscribedOptions":[1,"subscribed-options"],"quickBuy":[1540,"quick-buy"],"quantity":[514],"donatingAmount":[514,"donating-amount"],"notifyOptionsAvailability":[516,"notify-options-availability"],"productId":[520,"product-id"],"supportStickyBar":[516,"support-sticky-bar"],"productStatus":[513,"product-status"],"productType":[513,"product-type"],"hasOutOfStockOption":[32],"hasSubscribedOptions":[32],"selectedOptions":[32],"showQuickBuy":[32],"isApplePayActive":[32],"buyNowText":[32]}],[0,"salla-count-down",{"date":[1],"boxed":[4],"size":[1],"color":[1],"labeled":[4],"endText":[1,"end-text"],"digits":[1],"endOfDay":[4,"end-of-day"],"daysLabel":[32],"hoursLabel":[32],"minutesLabel":[32],"secondsLabel":[32],"endLabel":[32],"invalidDate":[32],"offerEnded":[32],"countInterval":[32],"days":[32],"hours":[32],"minutes":[32],"seconds":[32],"endCountDown":[64]}],[0,"salla-file-upload",{"value":[1544],"files":[513],"height":[513],"cartItemId":[1,"cart-item-id"],"profileImage":[516,"profile-image"],"name":[1537],"payloadName":[1,"payload-name"],"type":[1],"accept":[1537],"fileId":[2,"file-id"],"url":[1025],"method":[1],"formData":[1,"form-data"],"required":[4],"maxFileSize":[1,"max-file-size"],"disabled":[4],"allowDrop":[4,"allow-drop"],"allowBrowse":[4,"allow-browse"],"allowPaste":[4,"allow-paste"],"allowMultiple":[4,"allow-multiple"],"allowReplace":[4,"allow-replace"],"allowRevert":[4,"allow-revert"],"allowRemove":[4,"allow-remove"],"allowProcess":[4,"allow-process"],"allowReorder":[4,"allow-reorder"],"allowImagePreview":[4,"allow-image-preview"],"imagePreviewHeight":[2,"image-preview-height"],"filePosterHeight":[2,"file-poster-height"],"storeAsFile":[4,"store-as-file"],"forceRevert":[4,"force-revert"],"maxFilesCount":[2,"max-files-count"],"maxParallelUploads":[2,"max-parallel-uploads"],"checkValidity":[4,"check-validity"],"itemInsertLocation":[1,"item-insert-location"],"itemInsertInterval":[2,"item-insert-interval"],"credits":[4],"dropOnPage":[4,"drop-on-page"],"dropOnElement":[4,"drop-on-element"],"dropValidation":[4,"drop-validation"],"ignoredFiles":[16,"ignored-files"],"instantUpload":[1028,"instant-upload"],"chunkUploads":[4,"chunk-uploads"],"chunkForce":[4,"chunk-force"],"chunkSize":[2,"chunk-size"],"chunkRetryDelays":[16,"chunk-retry-delays"],"labelDecimalSeparator":[1,"label-decimal-separator"],"labelThousandsSeparator":[1,"label-thousands-separator"],"labelIdle":[1025,"label-idle"],"iconRemove":[1,"icon-remove"],"iconProcess":[1,"icon-process"],"iconRetry":[1,"icon-retry"],"iconUndo":[1,"icon-undo"],"max_images_count":[32],"max_count_hint":[32],"uploadedFiles":[32],"isListScrollerListenerAdded":[32],"showMaxCountHint":[32],"setOption":[64]}],[4,"salla-list-tile",{"href":[1],"target":[1]}],[0,"salla-product-availability",{"channels":[1],"notifyOptionsAvailability":[4,"notify-options-availability"],"productId":[2,"product-id"],"isSubscribed":[1028,"is-subscribed"],"translationLoaded":[32],"title_":[32],"isVisitorSubscribed":[32]},null,{"channels":["channelsWatcher"]}],[0,"salla-quick-buy",{"type":[1025],"productId":[1025,"product-id"],"cartId":[1025,"cart-id"],"amount":[1538],"currency":[1025],"options":[16],"isRequireShipping":[1028,"is-require-shipping"],"applePayOnly":[1028,"apple-pay-only"],"isApplePayActive":[32],"quickBuy":[32]}],[0,"salla-progress-bar",{"donation":[1],"target":[1026],"value":[1026],"height":[1025],"header":[1025],"stripped":[1028],"message":[1025],"unit":[1025],"color":[1025],"hideUnits":[4,"hide-units"]}],[0,"salla-rating-stars",{"name":[1],"size":[1],"value":[2],"reviews":[2],"withLabel":[4,"with-label"],"editable":[4],"translationsLoaded":[32],"labels":[32],"reviewLabel":[32],"selectedStar":[32]}],[4,"salla-placeholder",{"icon":[1],"alignment":[1],"iconSize":[1,"icon-size"],"translationLoaded":[32]}],[0,"salla-skeleton",{"type":[1],"width":[1],"height":[1]}],[4,"salla-slider",{"blockTitle":[513,"block-title"],"listenToThumbnailsOption":[516,"listen-to-thumbnails-option"],"blockSubtitle":[513,"block-subtitle"],"displayAllUrl":[513,"display-all-url"],"arrowsCentered":[516,"arrows-centered"],"verticalThumbs":[516,"vertical-thumbs"],"gridThumbs":[516,"grid-thumbs"],"vertical":[516],"autoHeight":[516,"auto-height"],"showControls":[516,"show-controls"],"controlsOuter":[516,"controls-outer"],"showThumbsControls":[4,"show-thumbs-controls"],"autoPlay":[4,"auto-play"],"slidesPerView":[1,"slides-per-view"],"pagination":[4],"centered":[4],"loop":[4],"direction":[1537],"type":[1],"sliderConfig":[520,"slider-config"],"thumbsConfig":[520,"thumbs-config"],"currentIndex":[32],"isEnd":[32],"isBeginning":[32],"swiperScript":[32],"displayAllTitle":[32],"windowWidth":[32],"sliderInstance":[64],"slideTo":[64],"slideNext":[64],"slidePrev":[64],"slideToLoop":[64],"slideNextLoop":[64],"slidePrevLoop":[64],"slideReset":[64],"slideToClosest":[64],"update":[64],"updateAutoHeight":[64],"updateSlides":[64],"updateProgress":[64],"updateSlidesClasses":[64],"getSlides":[64],"updateSize":[64],"sliderInit":[64],"thumbsSliderInstance":[64],"thumbsSliderInit":[64],"thumbsSliderUpdate":[64],"thumbsSliderUpdateSlides":[64],"getThumbsUpdateSize":[64],"thumbsSlideTo":[64],"getThumbsSlides":[64]}],[0,"salla-tel-input",{"phone":[1025],"autofocus":[516],"name":[1],"disabled":[4],"countryCode":[1025,"country-code"],"mobileRequired":[32],"countryCodeLabel":[32],"mobileLabel":[32],"tooShort":[32],"tooLong":[32],"invalidCountryCode":[32],"invalidNumber":[32],"errorMap":[32],"getValues":[64],"isValid":[64]}],[4,"salla-modal",{"isClosable":[1028,"is-closable"],"width":[513],"position":[513],"visible":[516],"hasSkeleton":[516,"has-skeleton"],"isLoading":[1540,"is-loading"],"subTitleFirst":[4,"sub-title-first"],"noPadding":[4,"no-padding"],"subTitle":[1,"sub-title"],"centered":[4],"iconStyle":[1,"icon-style"],"modalTitle":[32],"open":[64],"close":[64],"setTitle":[64],"loading":[64],"stopLoading":[64]},[[0,"keyup","handleKeyUp"]],{"visible":["handleVisible"]}],[0,"salla-loading",{"size":[8],"width":[8],"color":[1],"bgColor":[1,"bg-color"]}],[4,"salla-button",{"shape":[513],"color":[513],"fill":[513],"size":[513],"width":[513],"loading":[516],"disabled":[516],"loaderPosition":[1,"loader-position"],"href":[1],"type":[513],"load":[64],"stop":[64],"setText":[64],"disable":[64],"enable":[64]}]]],["p-29e96484",[[0,"salla-booking-field",{"option":[16],"productId":[2,"product-id"],"bookNowLabel":[32],"editLabel":[32],"bookedLabel":[32],"selectDate":[32],"bookingUrl":[32],"iframeReady":[32],"reservations":[32],"reservationsInput":[32]}],[4,"salla-conditional-fields",null,[[0,"change","changeHandler"]]]]],["p-b72f268b",[[0,"salla-price-range",{"minPrice":[1032,"min-price"],"maxPrice":[1032,"max-price"],"option":[16],"filtersData":[520,"filters-data"],"min":[32],"max":[32],"priceOptions":[32],"moreThanLabel":[32],"lessThanLabel":[32],"toLabel":[32],"fromLabel":[32],"typing":[32],"isMin":[32],"isRTL":[32],"reset":[64]}]]]]'),e)}));
5
5
  //# sourceMappingURL=twilight.esm.js.map
@@ -115,7 +115,7 @@ DOMTokenList
115
115
  var resourcesUrl = scriptElm ? scriptElm.getAttribute('data-resources-url') || scriptElm.src : '';
116
116
  var start = function() {
117
117
  // if src is not present then origin is "null", and new URL() throws TypeError: Failed to construct 'URL': Invalid base URL
118
- var url = new URL('./p-BcXA9D_n.system.js', new URL(resourcesUrl, window.location.origin !== 'null' ? window.location.origin : undefined));
118
+ var url = new URL('./p-FxRE-bWf.system.js', new URL(resourcesUrl, window.location.origin !== 'null' ? window.location.origin : undefined));
119
119
  System.import(url.href);
120
120
  };
121
121
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@salla.sa/twilight-components",
3
- "version": "2.14.171",
3
+ "version": "2.14.172",
4
4
  "license": "GPL-3.0",
5
5
  "author": "Salla Team <support@salla.dev> (https://salla.dev)",
6
6
  "bugs": {
@@ -80,9 +80,9 @@
80
80
  "typescript": "^5.4.5"
81
81
  },
82
82
  "dependencies": {
83
- "@salla.sa/applepay": "2.14.171",
84
- "@salla.sa/twilight": "2.14.171",
85
- "@salla.sa/twilight-tailwind-theme": "2.14.171",
83
+ "@salla.sa/applepay": "2.14.172",
84
+ "@salla.sa/twilight": "2.14.172",
85
+ "@salla.sa/twilight-tailwind-theme": "2.14.172",
86
86
  "@types/node": "^20.4.8",
87
87
  "animejs": "^3.2.2",
88
88
  "filepond": "^4.30.6",
@@ -100,5 +100,5 @@
100
100
  "vanilla-lazyload": "^17.8.5",
101
101
  "vanilla-picker": "^2.12.2"
102
102
  },
103
- "gitHead": "094b62869b983cfb8dbfd9a551b76df000297d70"
103
+ "gitHead": "17584ec1a5167f8d1bc7683839985c616ef6d7a0"
104
104
  }
@@ -1 +0,0 @@
1
- {"version":3,"names":["sallaBookingFieldCss","SallaBookingField","exports","class_1","hostRef","_this","this","bookNowLabel","salla","lang","get","editLabel","bookedLabel","selectDate","bookingUrl","iframeReady","reservations","onLoaded","setTranslations","Salla","event","on","data","handleBookingOpen","prototype","setNestedAsync","key","value","Promise","resolve","helpers","setNested","messages","_c","sent","openBookingModal","afterReload","detail","productId","config","isGuest","setAfterReloadEvent","dispatch","booking","add","then","resp","redirect","to","Error","url","id","catch","error","logger","response","addParamToUrl","setTimeout","modal","setTitle","open","payload","storage","set","emitAfterReloadEvent","eventDetails","customEvent","CustomEvent","window","dispatchEvent","remove","componentWillLoad","option","details","length","componentDidLoad","addEventListener","handleMessageEvent","bind","reservationsInput","e","invalidInput","emit","setCustomValidity","reportValidity","source","action","type","message","localStorage","getItem","console","log","concat","_a","fields","reservation","notify","errorList","Object","values","flat","map","join","Number","schedule","time","timeSlot","date","day","from_timestamp","from","to_timestamp","filter","item","success","_b","close","location","reload","iframe","height","bookingModal","h","class","ref","width","position","noPadding","src","frameborder","renderReservationDate","innerHTML","Calendar","renderReservationTime","TimeIcon","render","Host","required","money","price","size","loaderPosition","fill","onClick","BookingTime","index","name","JSON","stringify","SallaConditionalFields","class_2","hideAllOptions","optionId","host","querySelectorAll","forEach","field","classList","dataset","disableInputs","input","setAttribute","removeAttribute","tagName","toLowerCase","includes","getAttribute","hasOwnProperty","checked","changeHandler","target","replace","isMultiple","isRadio","isEqual","showWhen","trim","isSelected","selectedValues","Array","toString","showTheInput","closestProductOption","closest","optionRequired","checkboxes","document","isAnyChecked","some","checkbox","componentDidRender","optionName","querySelector"],"sources":["src/components/salla-booking-field/salla-booking-field.scss?tag=salla-booking-field","src/components/salla-booking-field/salla-booking-field.tsx","src/components/salla-conditional-fields/salla-conditional-fields.tsx"],"sourcesContent":[":host {\n display: block;\n}\n","import { Component, Host, Prop, h, Element, State, Event, EventEmitter } from '@stencil/core';\nimport { Option, Reservation } from './interfaces';\nimport BookingTime from '../../assets/svg/calendar-time.svg';\nimport Calendar from '../../assets/svg/calendar.svg';\nimport TimeIcon from '../../assets/svg/time.svg';\n\n@Component({\n tag: 'salla-booking-field',\n styleUrl: 'salla-booking-field.scss',\n})\nexport class SallaBookingField {\n /**\n * The booking option configuration\n */\n @Prop() option: Option;\n /**\n * The ID of the product for which the booking is being made\n */\n @Prop() productId: number;\n @Element() host: HTMLElement;\n @State() bookNowLabel: string = salla.lang.get('pages.cart.book_an_appointment', 'حجز موعد');\n @State() editLabel: string = salla.lang.get('pages.cart.edit_an_appointment', 'تعديل الموعد');\n @State() bookedLabel: string = salla.lang.get('pages.cart.booked_successfully', 'تمت اضافة الموعد بنجاح');\n @State() selectDate: string = salla.lang.get('pages.cart.select_appointment_date', 'حدد تاريخ الموعد');\n @State() bookingUrl: string = '';\n @State() iframeReady: boolean = false;\n @State() reservations: Reservation[] = [];\n @State() reservationsInput: HTMLInputElement;\n\n /**\n * Event emitted when the input is invalid.\n */\n @Event() invalidInput: EventEmitter<any>;\n\n private modal: HTMLSallaModalElement;\n private iframe: HTMLIFrameElement;\n\n constructor() {\n // Load translations\n salla.lang.onLoaded(() => this.setTranslations());\n // Register event listeners\n Salla.event.on('booking::open', (data) => this.handleBookingOpen(data));\n }\n\n private async setTranslations() {\n const setNestedAsync = (lang, key, value) => {\n return new Promise((resolve) => {\n salla.helpers.setNested(salla.lang.messages[lang], key, value);\n resolve(true);\n });\n };\n\n await setNestedAsync('ar.trans', 'pages.cart.book_an_appointment', 'حجز موعد');\n await setNestedAsync('en.trans', 'pages.cart.book_an_appointment', 'Book an Appointment');\n await setNestedAsync('ar.trans', 'pages.cart.edit_an_appointment', 'تعديل الموعد');\n await setNestedAsync('en.trans', 'pages.cart.edit_an_appointment', 'Edit an Appointment');\n await setNestedAsync('ar.trans', 'pages.cart.booked_successfully', 'تمت اضافة الموعد بنجاح');\n await setNestedAsync('en.trans', 'pages.cart.booked_successfully', 'Booked Successfully');\n await setNestedAsync('ar.trans', 'pages.cart.select_appointment_date', 'حدد تاريخ الموعد');\n await setNestedAsync('en.trans', 'pages.cart.select_appointment_date', 'Select appointment date');\n\n this.bookNowLabel = salla.lang.get('pages.cart.book_an_appointment');\n this.editLabel = salla.lang.get('pages.cart.edit_an_appointment');\n this.bookedLabel = salla.lang.get('pages.cart.booked_successfully');\n this.selectDate = salla.lang.get('pages.cart.select_appointment_date');\n }\n\n private openBookingModal(event: any, afterReload = false) {\n if (afterReload && (!event.detail || typeof event.detail !== 'number' || event.detail !== this.productId)) {\n return;\n }\n if (salla.config.isGuest()) {\n this.setAfterReloadEvent('booking::open-after-reload', this.productId);\n salla.event.dispatch('login::open');\n return;\n }\n salla.booking.add(this.productId, false)\n .then((resp) => {\n if (resp.data.redirect.to !== 'booking') {\n throw new Error('Unexpected redirect!');\n }\n salla.event.dispatch('booking::open', { url: resp.data.redirect.url, id: this.productId });\n })\n .catch((error) => {\n salla.error(salla.lang.get('common.errors.error_occurred'));\n salla.logger.error(error.response || error);\n });\n }\n\n private handleBookingOpen(data) {\n if (data.id !== this.productId) return;\n this.bookingUrl = salla.url.addParamToUrl('product_id', data.id, data.url);\n this.iframeReady = true;\n setTimeout(() => {\n this.modal.setTitle(this.selectDate);\n this.modal.open();\n }, 100);\n }\n\n private setAfterReloadEvent(event, payload) {\n salla.storage.set('afterReloadEvent', { event, payload });\n }\n\n private emitAfterReloadEvent() {\n const eventDetails = salla.storage.get('afterReloadEvent');\n if (eventDetails && eventDetails.event) {\n const customEvent = new CustomEvent(eventDetails.event, {\n detail: eventDetails.payload\n });\n window.dispatchEvent(customEvent)\n salla.storage.remove('afterReloadEvent');\n }\n }\n\n componentWillLoad() {\n if (this.option && this.option.details.length) {\n this.reservations = this.option.details;\n }\n }\n\n componentDidLoad() {\n window.addEventListener('booking::open-after-reload', (event) => this.openBookingModal(event, true));\n this.emitAfterReloadEvent();\n window.addEventListener('message', this.handleMessageEvent.bind(this));\n this.reservationsInput.addEventListener('invalid', e => this.invalidInput.emit(e));\n this.reservationsInput.addEventListener('input', () => {\n this.reservationsInput.setCustomValidity('');\n this.reservationsInput.reportValidity();\n });\n }\n\n private handleMessageEvent(event) {\n if (event.data.source !== 'booking') return;\n const action = event.data.type;\n const value = event.data.message;\n if (localStorage.getItem('debug')) console.log(`Received an action:${action}`, event.data);\n\n if (action === 'error') {\n if (value.fields?.reservation) {\n salla.notify.error(value.fields.reservation[0]);\n return;\n }\n const errorList = Object.values(value.fields || [value.message]).flat().map(error => `<li>${error}</li>`).join('');\n salla.notify.error(`<ul>${errorList}</ul>`);\n }\n\n if (action === 'success') {\n if (Number(value.productId) !== Number(this.productId)) return;\n this.reservations = value.data.reservations.map(schedule => {\n if (schedule.time && schedule.time.length > 0) {\n const timeSlot = schedule.time[0];\n return {\n date: schedule.date,\n day: schedule.day,\n from_timestamp: timeSlot.from,\n to_timestamp: timeSlot.to,\n };\n }\n return null;\n }).filter(item => item !== null);\n\n salla.notify.success(this.bookedLabel);\n this.modal?.close();\n setTimeout(() => window.location.reload());\n }\n\n if (action === 'height') {\n this.iframe.height = value?.height + 'px';\n }\n }\n\n private bookingModal() {\n return (\n <salla-modal class=\"s-booking-field-modal\" ref={modal => (this.modal = modal)} width=\"md\" position=\"middle\" noPadding>\n <iframe ref={iframe => (this.iframe = iframe)} src={this.bookingUrl} frameborder=\"0\"></iframe>\n </salla-modal>\n );\n }\n\n renderReservationDate(reservation: Reservation) {\n return (\n <span class={reservation.from_timestamp ? 's-booking-field-reservations-has-time' : ''}>\n <i class=\"s-booking-field-reservations-icon\" innerHTML={Calendar}></i>\n {reservation.date}\n </span>\n );\n }\n\n renderReservationTime(reservation: Reservation) {\n if (!reservation.from_timestamp) return '';\n return (\n <span class=\"s-booking-field-reservations-time\">\n <i class=\"s-booking-field-reservations-icon\" innerHTML={TimeIcon}></i>\n <span>\n {reservation.from_timestamp} - {reservation.to_timestamp}\n </span>\n </span>\n );\n }\n\n render() {\n return (\n <Host>\n <div class=\"s-booking-field-main\">\n {this.option.required || this.reservations.length > 0 ? <div class=\"s-booking-field-price\">\n <span>{salla.money(this.option.price)}</span>\n </div> : ''}\n <salla-button class=\"s-booking-field-book-now\" size=\"small\" loaderPosition=\"center\" fill=\"outline\" onClick={event => this.openBookingModal(event, false)}>\n <span class=\"s-booking-field-book-now-content\">\n <span innerHTML={BookingTime}></span>\n {this.reservations.length ? this.editLabel : this.bookNowLabel}\n </span>\n </salla-button>\n </div>\n {this.reservations.length > 0 && (\n <div class=\"s-booking-field-reservations\">\n {this.reservations.map((reservation, index) => (\n <div key={index} class=\"s-booking-field-reservations-item\">\n {this.renderReservationDate(reservation)}\n {this.renderReservationTime(reservation)}\n </div>\n ))}\n </div>\n )}\n <input\n class=\"s-hidden\"\n name={this.option.name}\n required={this.option.required}\n value={JSON.stringify(this.reservations) === '[]' ? '' : JSON.stringify(this.reservations)}\n ref={reservations => this.reservationsInput = reservations}\n />\n {this.iframeReady && this.bookingModal()}\n </Host>\n );\n }\n}\n","import { Component, Element, Host, Listen, h } from '@stencil/core';\n\n/**\n * its to easy to use, currenlty its support select & checkbox input as trigger for show/hide the dom\n * the dom you can put it like this data-show-when=\"{name of the field} {= or !=} {value of the field}\"\n */\n@Component({\n tag: 'salla-conditional-fields'\n})\nexport class SallaConditionalFields {\n\n @Element() host: HTMLElement;\n\n private hideAllOptions(optionId) {\n this.host.querySelectorAll(`[data-show-when^=\"options[${optionId}\"]`).forEach((field: HTMLElement) => {\n field.classList.add('hidden');\n this.hideAllOptions(field.dataset.optionId);\n this.disableInputs(field);\n });\n }\n\n private disableInputs(field) {\n field.querySelectorAll('[name]').forEach((input) => {\n\n input.setAttribute('disabled', '');\n input.removeAttribute('required');\n if (input?.tagName?.toLowerCase() === 'select') {\n input.value = ''\n }\n if (['checkbox'].includes(input.getAttribute('type')) && input.hasOwnProperty('checked')) {\n // @ts-ignore\n input.checked = false;\n }\n });\n }\n \n @Listen('change')\n changeHandler(event) {\n salla.event.emit('salla-onditional-fields::change', event);\n salla.log('Received the change event: ', event);\n\n if (!event.target || !['SELECT'].includes(event.target.tagName) && !['checkbox', 'radio'].includes(event.target.getAttribute('type'))) {\n salla.log('Ignore the change because is not a supported input: ' + (event?.target?.tagName || 'N/A'));\n return;\n }\n\n let optionId = event.target.name.replace('[]', '');\n let isMultiple = event.target.getAttribute('type') === 'checkbox';\n let isRadio = event.target.getAttribute('type') === 'radio';\n\n salla.log('Trying to find all elements with condition:', `[data-show-when^=\"${optionId}\"]`);\n\n this.host.querySelectorAll(`[data-show-when^=\"${optionId}\"]`)\n .forEach((field: HTMLElement) => {\n let isEqual = !field?.dataset.showWhen.includes('!=');\n let value = field?.dataset.showWhen.replace(/(.*)(=|!=)(.*)/gm, '$3').trim();\n let isSelected;\n if (isMultiple) {\n let selectedValues = Array.from(this.host.querySelectorAll(`input[name=\"${event.target.name}\"]:checked`), e => (e as HTMLInputElement)?.value);\n isSelected = selectedValues.includes(value.toString());\n } else if (isRadio) {\n // Handle radio inputs.\n isSelected = event.target.checked && event.target.value === value;\n } else {\n isSelected = value === event.target.value;\n }\n\n salla.log('The input is ', isMultiple ? 'Multiple' : isRadio ? 'Radio' : 'Single', ' value:', isSelected);\n\n let showTheInput = (isEqual && isSelected) || (!isEqual && !isSelected);\n if (showTheInput) {\n field.classList.remove('hidden');\n field.querySelectorAll('[name]').forEach((input) => {\n input.removeAttribute('disabled');\n\n const closestProductOption = (input as HTMLInputElement).closest('.s-product-options-option') as HTMLElement;\n if (closestProductOption.dataset.optionRequired === 'true') {\n input.setAttribute('required', '');\n }\n\n if (input.getAttribute('type') === 'checkbox') {\n const checkboxes = Array.from(document.querySelectorAll(`input[type=\"checkbox\"][name=\"${input.getAttribute('name')}\"]`)) as HTMLInputElement[];\n const isAnyChecked = checkboxes.some((checkbox) => checkbox.checked);\n if (isAnyChecked) {\n checkboxes.forEach((checkbox) => {\n checkbox.removeAttribute('required');\n });\n }\n }\n });\n } else {\n this.hideAllOptions(field.dataset.optionId);\n field.classList.add('hidden');\n this.disableInputs(field);\n }\n });\n } \n\n componentDidRender() {\n this.host.querySelectorAll(`[data-show-when]`).forEach((field) => {\n // @ts-ignore\n let optionName = field?.dataset?.showWhen.replace(/(.*)(=|!=)(.*)/gm, '$1').trim();\n if (!optionName) {\n return;\n }\n\n this.changeHandler({\n target: this.host.querySelector('[name^=\"' + optionName + '\"]')\n })\n });\n }\n\n render() {\n return (\n <Host>\n <slot></slot>\n </Host>\n );\n }\n}\n"],"mappings":";;;+tFAAA,IAAMA,EAAuB,uB,ICUhBC,EAAiBC,EAAA,iCA2B5B,SAAAC,EAAAC,GAAA,IAAAC,EAAAC,K,mDAjBSA,KAAYC,aAAWC,MAAMC,KAAKC,IAAI,iCAAkC,YACxEJ,KAASK,UAAWH,MAAMC,KAAKC,IAAI,iCAAkC,gBACrEJ,KAAWM,YAAWJ,MAAMC,KAAKC,IAAI,iCAAkC,0BACvEJ,KAAUO,WAAWL,MAAMC,KAAKC,IAAI,qCAAsC,oBAC1EJ,KAAUQ,WAAW,GACrBR,KAAWS,YAAY,MACvBT,KAAYU,aAAkB,GAarCR,MAAMC,KAAKQ,UAAS,WAAM,OAAAZ,EAAKa,iBAAL,IAE1BC,MAAMC,MAAMC,GAAG,iBAAiB,SAACC,GAAS,OAAAjB,EAAKkB,kBAAkBD,EAAvB,GAC3C,CAEanB,EAAAqB,UAAAN,gBAAN,W,kHACAO,EAAiB,SAAChB,EAAMiB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KqK,cAAc,CACjBC,OAAQtK,EAAKqJ,KAAKuC,cAAc,WAAaD,EAAa,OAE9D,G,EAGFzC,EAAA/H,UAAAgH,OAAA,WACE,OACEb,EAACc,EAAI,CAAA/G,IAAA,4CACHiG,EAAa,QAAAjG,IAAA,6C,yHA1Gc,G","ignoreList":[]}
@@ -1,5 +0,0 @@
1
- /*!
2
- * Crafted with ❤ by Salla
3
- */
4
- System.register(["./p-D-0D-Csi.system.js"],(function(s){"use strict";var t,n,a,i;return{setters:[function(s){t=s.r;n=s.h;a=s.H;i=s.g}],execute:function(){var r=":host{display:block}";var e=s("salla_apps_icons",function(){function s(s){var n=this;t(this,s);var a;this.apps=salla.config.get("store.apps");this.appSlot=((a=this.host.querySelector('[slot="app"]'))===null||a===void 0?void 0:a.innerHTML)||"<img alt={name} src={icon} />";salla.onReady((function(){n.apps=salla.config.get("store.apps")}));salla.lang.onLoaded((function(){n.appsTitle=salla.lang.get("blocks.footer.download_apps")}))}s.prototype.getAppsArray=function(){return Object.entries(this.apps).map((function(s){var t=s[0],n=s[1];return{name:t,value:n}}))};s.prototype.componentWillLoad=function(){return new Promise((function(s){return salla.onReady(s)}))};s.prototype.render=function(){var s=this;var t=this.getAppsArray();if(Array.isArray(t)&&!t.length){return}return n(a,{class:"s-apps-icons"},!this.hideTitle&&n("h3",null,this.appsTitle),n("div",{class:{"s-apps-icons-list":true,vertical:this.vertical}},t.map((function(t,a){return n("a",{key:a,href:t.value,rel:"noreferrer",target:"_blank",class:"s-apps-icons-item",id:"app-slot",innerHTML:s.appSlot.replace(/\{icon\}/g,salla.url.cdn("images/".concat(t.name,".png"))).replace(/\{name\}/g,t.name)})}))))};s.prototype.componentDidRender=function(){var s;(s=this.host.querySelector('[slot="app"]'))===null||s===void 0?void 0:s.remove()};Object.defineProperty(s.prototype,"host",{get:function(){return i(this)},enumerable:false,configurable:true});return s}());e.style=r}}}));
5
- //# sourceMappingURL=p-30d8107f.system.entry.js.map
@@ -1,5 +0,0 @@
1
- /*!
2
- * Crafted with ❤ by Salla
3
- */
4
- import{r as i,h as t,H as e}from"./p-LiUkE7QA.js";var s;(function(i){i["PERCENTAGE"]="percentage";i["FIXED"]="fixed";i["FREE_PRODUCT"]="free_product"})(s||(s={}));var o;(function(i){i["PRODUCT_COUNT"]="products_count";i["PRODUCT_PURCHASE"]="order_amount"})(o||(o={}));const n=":host{display:block}";const a=class{constructor(t){i(this,t);this.offer=null;this.products={};this.isLoading=true;this.canRender=true}componentWillLoad(){salla.onReady().then((()=>{var i,t,e;if(!((i=salla.config.get("store.features"))===null||i===void 0?void 0:i.includes("conditional-offer"))||salla.storage.get("cart")!==""&&!((e=(t=salla.storage.get("cart"))===null||t===void 0?void 0:t.summary)===null||e===void 0?void 0:e.count)){throw new Error("feature or cart object does not existed")}})).then((()=>salla.api.cart.offers())).then((({data:i})=>{this.offer=i.find((i=>i.type==="conditional"));if(!this.offer){throw new Error("No conditional offer has been activated in the merchant dashboard")}this.offer.details.discounts.unshift({value:0,min_spend:0});return this.updateInitialOfferValue()})).then((()=>this.getProducts())).then((()=>salla.event.on("cart::updated",(i=>this.updateOfferValues(i))))).catch((i=>{this.canRender=false;salla.logger.warn("salla-conditional-offer:: ",i)})).finally((()=>{this.isLoading=false}))}getProducts(){const i=this.offer.details.discounts.filter((({type:i})=>i===s.FREE_PRODUCT)).map((({value:i})=>i));if(i.length>0){return salla.product.fetch({source:"selected",source_value:i}).then((({data:i})=>{i.forEach((({id:i,url:t,image:e})=>{this.products[i]={url:t,image:e}}))}))}}updateInitialOfferValue(){return salla.api.cart.details().then((({data:{cart:i}})=>this.updateOfferValues(i)))}updateOfferValues({items:i,sub_total:t}){var e;const s=this.offer.details.based_on===o.PRODUCT_COUNT?i.reduce(((i,{quantity:t})=>i+t),0):t;this.offer=Object.assign(Object.assign({},this.offer),{details:Object.assign(Object.assign({},(e=this.offer)===null||e===void 0?void 0:e.details),{current_value:s})});return this.offer}getCheckpointContent(i){var e,o;if(i.type===s.PERCENTAGE)return`${i.value}%`;if(i.type===s.FIXED)return salla.money(i.value);if(i.type!==s.FREE_PRODUCT){salla.logger.error(`salla-conditional-offer:: unexpected type (${i.type})!`);return""}const n=this.products[i.value];if(!n){salla.logger.error(`salla-conditional-offer:: there is no product with id (${i.value})!`);return""}return t("a",{class:"s-conditional-offer-product-link",href:n.url},t("img",{class:"s-conditional-offer-checkpoint-image-content",loading:"lazy",decoding:"async",alt:((e=n===null||n===void 0?void 0:n.image)===null||e===void 0?void 0:e.alt)||"",src:(o=n===null||n===void 0?void 0:n.image)===null||o===void 0?void 0:o.url}))}getOfferType(i){var t;const e=(t=this.offer.details)===null||t===void 0?void 0:t.based_on;if(e===o.PRODUCT_COUNT)return salla.lang.choice("blocks.header.products_count",i.min_spend);if(e===o.PRODUCT_PURCHASE)return salla.money(i.min_spend);salla.logger.warn(`salla-conditional-offer:: Unexpected offer detail's based_on value: ${e}`);return`${i.min_spend}`}clamp(i,t,e){return Math.max(t,Math.min(i,e))}mapValueRanges(i,t,e,s,o){const n=(i-t)*(o-s)/(e-t)+s;if(n===Number.POSITIVE_INFINITY)return 100;if(n===Number.NEGATIVE_INFINITY)return 0;return this.clamp(n,0,100)}getCheckPointView(i,e){var s,o;const n=this.offer.details.discounts.findIndex((({min_spend:t})=>t===i.min_spend));const a=(o=(s=this.offer.details.discounts[n-1])===null||s===void 0?void 0:s.min_spend)!==null&&o!==void 0?o:0;const l=this.mapValueRanges(this.offer.details.current_value,a,i.min_spend,0,100);const r=i.min_spend<=this.offer.details.current_value;return t("div",{class:"s-conditional-offer-checkpoint-container"},e>0?[t("div",{key:"progress-line",class:"s-conditional-offer-progress-line-container"},t("div",{class:"s-conditional-offer-progress-line-inactive"}),t("div",{class:"s-conditional-offer-progress-line-active",style:{width:`${l}%`}})),t("div",{key:"checkpoint",class:`s-conditional-offer-checkpoint ${r?"s-conditional-offer-active-checkpoint":""}`},t("div",{class:`s-conditional-offer-item-avatar-content ${r?"active":""}`,innerHTML:this.products&&this.getCheckpointContent(i)}),t("div",{class:`s-conditional-offer-checkpoint-label ${r?"active":""}`,innerHTML:this.getOfferType(i)}))]:t("div",{key:"label",class:{"s-conditional-offer-checkpoint-label":true,"first-checkpoint":e===0,active:r},innerHTML:this.getOfferType(i)}))}getLoadingSkeletonView(){return t(e,{class:"s-conditional-offer-container"},t("div",{class:"s-conditional-offer-skeleton-inner-container"},t("div",{class:"s-conditional-offer-skeleton-subtitle"},t("salla-skeleton",{height:"16px",width:"30%"})),t("div",{class:"s-conditional-offer-skeleton-subtitle"},t("salla-skeleton",{height:"16px",width:"35%"})),t("div",{class:"s-conditional-offer-skeleton-checkpoints-wrapper"},Array(3).fill(null).map((()=>[t("salla-skeleton",{key:"checkpoint-line",height:"8px"}),t("div",{key:"checkpoint"},t("salla-skeleton",{height:"60px",width:"60px",type:"circle"}))])))))}render(){if(!this.canRender)return null;if(this.isLoading)return this.getLoadingSkeletonView();return t(e,{class:"s-conditional-offer-container"},t("div",{class:"s-conditional-offer-title-wrapper"},t("div",{class:"s-conditional-offer-title"},this.offer.title),this.offer.description?t("div",{class:"s-conditional-offer-subtitle"},this.offer.description," ",t("i",{class:"sicon-information"})):null),t("div",{class:"s-conditional-offer-progress-container"},this.offer.details.discounts.map(((i,e)=>t("div",{class:{"flex-1":e>0},key:i.min_spend},this.getCheckPointView(i,e))))))}};a.style=n;export{a as salla_conditional_offer};
5
- //# sourceMappingURL=p-93c132a7.entry.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"p-D1W-OG00.system.js","sources":["src/components/salla-booking-field/salla-booking-field.scss?tag=salla-booking-field","src/components/salla-booking-field/salla-booking-field.tsx","src/components/salla-conditional-fields/salla-conditional-fields.tsx"],"sourcesContent":[":host {\n display: block;\n}\n","import { Component, Host, Prop, h, Element, State, Event, EventEmitter } from '@stencil/core';\nimport { Option, Reservation } from './interfaces';\nimport BookingTime from '../../assets/svg/calendar-time.svg';\nimport Calendar from '../../assets/svg/calendar.svg';\nimport TimeIcon from '../../assets/svg/time.svg';\n\n@Component({\n tag: 'salla-booking-field',\n styleUrl: 'salla-booking-field.scss',\n})\nexport class SallaBookingField {\n /**\n * The booking option configuration\n */\n @Prop() option: Option;\n /**\n * The ID of the product for which the booking is being made\n */\n @Prop() productId: number;\n @Element() host: HTMLElement;\n @State() bookNowLabel: string = salla.lang.get('pages.cart.book_an_appointment', 'حجز موعد');\n @State() editLabel: string = salla.lang.get('pages.cart.edit_an_appointment', 'تعديل الموعد');\n @State() bookedLabel: string = salla.lang.get('pages.cart.booked_successfully', 'تمت اضافة الموعد بنجاح');\n @State() selectDate: string = salla.lang.get('pages.cart.select_appointment_date', 'حدد تاريخ الموعد');\n @State() bookingUrl: string = '';\n @State() iframeReady: boolean = false;\n @State() reservations: Reservation[] = [];\n @State() reservationsInput: HTMLInputElement;\n\n /**\n * Event emitted when the input is invalid.\n */\n @Event() invalidInput: EventEmitter<any>;\n\n private modal: HTMLSallaModalElement;\n private iframe: HTMLIFrameElement;\n\n constructor() {\n // Load translations\n salla.lang.onLoaded(() => this.setTranslations());\n // Register event listeners\n Salla.event.on('booking::open', (data) => this.handleBookingOpen(data));\n }\n\n private async setTranslations() {\n const setNestedAsync = (lang, key, value) => {\n return new Promise((resolve) => {\n salla.helpers.setNested(salla.lang.messages[lang], key, value);\n resolve(true);\n });\n };\n\n await setNestedAsync('ar.trans', 'pages.cart.book_an_appointment', 'حجز موعد');\n await setNestedAsync('en.trans', 'pages.cart.book_an_appointment', 'Book an Appointment');\n await setNestedAsync('ar.trans', 'pages.cart.edit_an_appointment', 'تعديل الموعد');\n await setNestedAsync('en.trans', 'pages.cart.edit_an_appointment', 'Edit an Appointment');\n await setNestedAsync('ar.trans', 'pages.cart.booked_successfully', 'تمت اضافة الموعد بنجاح');\n await setNestedAsync('en.trans', 'pages.cart.booked_successfully', 'Booked Successfully');\n await setNestedAsync('ar.trans', 'pages.cart.select_appointment_date', 'حدد تاريخ الموعد');\n await setNestedAsync('en.trans', 'pages.cart.select_appointment_date', 'Select appointment date');\n\n this.bookNowLabel = salla.lang.get('pages.cart.book_an_appointment');\n this.editLabel = salla.lang.get('pages.cart.edit_an_appointment');\n this.bookedLabel = salla.lang.get('pages.cart.booked_successfully');\n this.selectDate = salla.lang.get('pages.cart.select_appointment_date');\n }\n\n private openBookingModal(event: any, afterReload = false) {\n if (afterReload && (!event.detail || typeof event.detail !== 'number' || event.detail !== this.productId)) {\n return;\n }\n if (salla.config.isGuest()) {\n this.setAfterReloadEvent('booking::open-after-reload', this.productId);\n salla.event.dispatch('login::open');\n return;\n }\n salla.booking.add(this.productId, false)\n .then((resp) => {\n if (resp.data.redirect.to !== 'booking') {\n throw new Error('Unexpected redirect!');\n }\n salla.event.dispatch('booking::open', { url: resp.data.redirect.url, id: this.productId });\n })\n .catch((error) => {\n salla.error(salla.lang.get('common.errors.error_occurred'));\n salla.logger.error(error.response || error);\n });\n }\n\n private handleBookingOpen(data) {\n if (data.id !== this.productId) return;\n this.bookingUrl = salla.url.addParamToUrl('product_id', data.id, data.url);\n this.iframeReady = true;\n setTimeout(() => {\n this.modal.setTitle(this.selectDate);\n this.modal.open();\n }, 100);\n }\n\n private setAfterReloadEvent(event, payload) {\n salla.storage.set('afterReloadEvent', { event, payload });\n }\n\n private emitAfterReloadEvent() {\n const eventDetails = salla.storage.get('afterReloadEvent');\n if (eventDetails && eventDetails.event) {\n const customEvent = new CustomEvent(eventDetails.event, {\n detail: eventDetails.payload\n });\n window.dispatchEvent(customEvent)\n salla.storage.remove('afterReloadEvent');\n }\n }\n\n componentWillLoad() {\n if (this.option && this.option.details.length) {\n this.reservations = this.option.details;\n }\n }\n\n componentDidLoad() {\n window.addEventListener('booking::open-after-reload', (event) => this.openBookingModal(event, true));\n this.emitAfterReloadEvent();\n window.addEventListener('message', this.handleMessageEvent.bind(this));\n this.reservationsInput.addEventListener('invalid', e => this.invalidInput.emit(e));\n this.reservationsInput.addEventListener('input', () => {\n this.reservationsInput.setCustomValidity('');\n this.reservationsInput.reportValidity();\n });\n }\n\n private handleMessageEvent(event) {\n if (event.data.source !== 'booking') return;\n const action = event.data.type;\n const value = event.data.message;\n if (localStorage.getItem('debug')) console.log(`Received an action:${action}`, event.data);\n\n if (action === 'error') {\n if (value.fields?.reservation) {\n salla.notify.error(value.fields.reservation[0]);\n return;\n }\n const errorList = Object.values(value.fields || [value.message]).flat().map(error => `<li>${error}</li>`).join('');\n salla.notify.error(`<ul>${errorList}</ul>`);\n }\n\n if (action === 'success') {\n if (Number(value.productId) !== Number(this.productId)) return;\n this.reservations = value.data.reservations.map(schedule => {\n if (schedule.time && schedule.time.length > 0) {\n const timeSlot = schedule.time[0];\n return {\n date: schedule.date,\n day: schedule.day,\n from_timestamp: timeSlot.from,\n to_timestamp: timeSlot.to,\n };\n }\n return null;\n }).filter(item => item !== null);\n\n salla.notify.success(this.bookedLabel);\n this.modal?.close();\n setTimeout(() => window.location.reload());\n }\n\n if (action === 'height') {\n this.iframe.height = value?.height + 'px';\n }\n }\n\n private bookingModal() {\n return (\n <salla-modal class=\"s-booking-field-modal\" ref={modal => (this.modal = modal)} width=\"md\" position=\"middle\" noPadding>\n <iframe ref={iframe => (this.iframe = iframe)} src={this.bookingUrl} frameborder=\"0\"></iframe>\n </salla-modal>\n );\n }\n\n renderReservationDate(reservation: Reservation) {\n return (\n <span class={reservation.from_timestamp ? 's-booking-field-reservations-has-time' : ''}>\n <i class=\"s-booking-field-reservations-icon\" innerHTML={Calendar}></i>\n {reservation.date}\n </span>\n );\n }\n\n renderReservationTime(reservation: Reservation) {\n if (!reservation.from_timestamp) return '';\n return (\n <span class=\"s-booking-field-reservations-time\">\n <i class=\"s-booking-field-reservations-icon\" innerHTML={TimeIcon}></i>\n <span>\n {reservation.from_timestamp} - {reservation.to_timestamp}\n </span>\n </span>\n );\n }\n\n render() {\n return (\n <Host>\n <div class=\"s-booking-field-main\">\n {this.option.required || this.reservations.length > 0 ? <div class=\"s-booking-field-price\">\n <span>{salla.money(this.option.price)}</span>\n </div> : ''}\n <salla-button class=\"s-booking-field-book-now\" size=\"small\" loaderPosition=\"center\" fill=\"outline\" onClick={event => this.openBookingModal(event, false)}>\n <span class=\"s-booking-field-book-now-content\">\n <span innerHTML={BookingTime}></span>\n {this.reservations.length ? this.editLabel : this.bookNowLabel}\n </span>\n </salla-button>\n </div>\n {this.reservations.length > 0 && (\n <div class=\"s-booking-field-reservations\">\n {this.reservations.map((reservation, index) => (\n <div key={index} class=\"s-booking-field-reservations-item\">\n {this.renderReservationDate(reservation)}\n {this.renderReservationTime(reservation)}\n </div>\n ))}\n </div>\n )}\n <input\n class=\"s-hidden\"\n name={this.option.name}\n required={this.option.required}\n value={JSON.stringify(this.reservations) === '[]' ? '' : JSON.stringify(this.reservations)}\n ref={reservations => this.reservationsInput = reservations}\n />\n {this.iframeReady && this.bookingModal()}\n </Host>\n );\n }\n}\n","import { Component, Element, Host, Listen, h } from '@stencil/core';\n\n/**\n * its to easy to use, currenlty its support select & checkbox input as trigger for show/hide the dom\n * the dom you can put it like this data-show-when=\"{name of the field} {= or !=} {value of the field}\"\n */\n@Component({\n tag: 'salla-conditional-fields'\n})\nexport class SallaConditionalFields {\n\n @Element() host: HTMLElement;\n\n private hideAllOptions(optionId) {\n this.host.querySelectorAll(`[data-show-when^=\"options[${optionId}\"]`).forEach((field: HTMLElement) => {\n field.classList.add('hidden');\n this.hideAllOptions(field.dataset.optionId);\n this.disableInputs(field);\n });\n }\n\n private disableInputs(field) {\n field.querySelectorAll('[name]').forEach((input) => {\n\n input.setAttribute('disabled', '');\n input.removeAttribute('required');\n if (input?.tagName?.toLowerCase() === 'select') {\n input.value = ''\n }\n if (['checkbox'].includes(input.getAttribute('type')) && input.hasOwnProperty('checked')) {\n // @ts-ignore\n input.checked = false;\n }\n });\n }\n \n @Listen('change')\n changeHandler(event) {\n salla.event.emit('salla-onditional-fields::change', event);\n salla.log('Received the change event: ', event);\n\n if (!event.target || !['SELECT'].includes(event.target.tagName) && !['checkbox', 'radio'].includes(event.target.getAttribute('type'))) {\n salla.log('Ignore the change because is not a supported input: ' + (event?.target?.tagName || 'N/A'));\n return;\n }\n\n let optionId = event.target.name.replace('[]', '');\n let isMultiple = event.target.getAttribute('type') === 'checkbox';\n let isRadio = event.target.getAttribute('type') === 'radio';\n\n salla.log('Trying to find all elements with condition:', `[data-show-when^=\"${optionId}\"]`);\n\n this.host.querySelectorAll(`[data-show-when^=\"${optionId}\"]`)\n .forEach((field: HTMLElement) => {\n let isEqual = !field?.dataset.showWhen.includes('!=');\n let value = field?.dataset.showWhen.replace(/(.*)(=|!=)(.*)/gm, '$3').trim();\n let isSelected;\n if (isMultiple) {\n let selectedValues = Array.from(this.host.querySelectorAll(`input[name=\"${event.target.name}\"]:checked`), e => (e as HTMLInputElement)?.value);\n isSelected = selectedValues.includes(value.toString());\n } else if (isRadio) {\n // Handle radio inputs.\n isSelected = event.target.checked && event.target.value === value;\n } else {\n isSelected = value === event.target.value;\n }\n\n salla.log('The input is ', isMultiple ? 'Multiple' : isRadio ? 'Radio' : 'Single', ' value:', isSelected);\n\n let showTheInput = (isEqual && isSelected) || (!isEqual && !isSelected);\n if (showTheInput) {\n field.classList.remove('hidden');\n field.querySelectorAll('[name]').forEach((input) => {\n input.removeAttribute('disabled');\n\n const closestProductOption = (input as HTMLInputElement).closest('.s-product-options-option') as HTMLElement;\n if (closestProductOption.dataset.optionRequired === 'true') {\n input.setAttribute('required', '');\n }\n\n if (input.getAttribute('type') === 'checkbox') {\n const checkboxes = Array.from(document.querySelectorAll(`input[type=\"checkbox\"][name=\"${input.getAttribute('name')}\"]`)) as HTMLInputElement[];\n const isAnyChecked = checkboxes.some((checkbox) => checkbox.checked);\n if (isAnyChecked) {\n checkboxes.forEach((checkbox) => {\n checkbox.removeAttribute('required');\n });\n }\n }\n });\n } else {\n this.hideAllOptions(field.dataset.optionId);\n field.classList.add('hidden');\n this.disableInputs(field);\n }\n });\n } \n\n componentDidRender() {\n this.host.querySelectorAll(`[data-show-when]`).forEach((field) => {\n // @ts-ignore\n let optionName = field?.dataset?.showWhen.replace(/(.*)(=|!=)(.*)/gm, '$1').trim();\n if (!optionName) {\n return;\n }\n\n this.changeHandler({\n target: this.host.querySelector('[name^=\"' + optionName + '\"]')\n })\n });\n }\n\n render() {\n return (\n <Host>\n <slot></slot>\n </Host>\n );\n }\n}\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MAAA,MAAM,oBAAoB,GAAG,sBAAsB;;YCUtC,iBAAiB,kCAAA,MAAA;MA2B5B,IAAA,WAAA,CAAA,OAAA,EAAA;;;MAjBS,QAAA,IAAY,CAAA,YAAA,GAAW,KAAK,CAAC,IAAI,CAAC,GAAG,CAAC,gCAAgC,EAAE,UAAU,CAAC;MACnF,QAAA,IAAS,CAAA,SAAA,GAAW,KAAK,CAAC,IAAI,CAAC,GAAG,CAAC,gCAAgC,EAAE,cAAc,CAAC;MACpF,QAAA,IAAW,CAAA,WAAA,GAAW,KAAK,CAAC,IAAI,CAAC,GAAG,CAAC,gCAAgC,EAAE,wBAAwB,CAAC;MAChG,QAAA,IAAU,CAAA,UAAA,GAAW,KAAK,CAAC,IAAI,CAAC,GAAG,CAAC,oCAAoC,EAAE,kBAAkB,CAAC;MAC7F,QAAA,IAAU,CAAA,UAAA,GAAW,EAAE;MACvB,QAAA,IAAW,CAAA,WAAA,GAAY,KAAK;MAC5B,QAAA,IAAY,CAAA,YAAA,GAAkB,EAAE;;MAavC,QAAA,KAAK,CAAC,IAAI,CAAC,QAAQ,CAAC,MAAM,IAAI,CAAC,eAAe,EAAE,CAAC;;MAEjD,QAAA,KAAK,CAAC,KAAK,CAAC,EAAE,CAAC,eAAe,EAAE,CAAC,IAAI,KAAK,IAAI,CAAC,iBAAiB,CAAC,IAAI,CAAC,CAAC;MACxE;MAEO,IAAA,MAAM,eAAe,GAAA;cAC3B,MAAM,cAAc,GAAG,CAAC,IAAI,EAAE,GAAG,EAAE,KAAK,KAAI;MAC1C,YAAA,OAAO,IAAI,OAAO,CAAC,CA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AA,EAAA,GAAA,KAAK,aAAL,KAAK,KAAA,MAAA,GAAA,MAAA,GAAL,KAAK,CAAE,OAAO,0CAAE,QAAQ,CAAC,OAAO,CAAC,kBAAkB,EAAE,IAAI,CAAA,CAAE,IAAI,EAAE;kBAClF,IAAI,CAAC,UAAU,EAAE;sBACf;;kBAGF,IAAI,CAAC,aAAa,CAAC;MACjB,gBAAA,MAAM,EAAE,IAAI,CAAC,IAAI,CAAC,aAAa,CAAC,UAAU,GAAG,UAAU,GAAG,IAAI;MAC/D,aAAA,CAAC;MACJ,SAAC,CAAC;;UAGJ,MAAM,GAAA;cACJ,QACE,EAAC,IAAI,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,EACH,CAAa,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,CAAA,CACR;;;;;;;;;;;"}
@@ -1 +0,0 @@
1
- {"version":3,"names":["sallaBookingFieldCss","SallaBookingField","constructor","hostRef","this","bookNowLabel","salla","lang","get","editLabel","bookedLabel","selectDate","bookingUrl","iframeReady","reservations","onLoaded","setTranslations","Salla","event","on","data","handleBookingOpen","setNestedAsync","key","value","Promise","resolve","helpers","setNested","messages","openBookingModal","afterReload","detail","productId","config","isGuest","setAfterReloadEvent","dispatch","booking","add","then","resp","redirect","to","Error","url","id","catch","error","logger","response","addParamToUrl","setTimeout","modal","setTitle","open","payload","storage","set","emitAfterReloadEvent","eventDetails","customEvent","CustomEvent","window","dispatchEvent","remove","componentWillLoad","option","details","length","componentDidLoad","addEventListener","handleMessageEvent","bind","reservationsInput","e","invalidInput","emit","setCustomValidity","reportValidity","source","action","type","message","localStorage","getItem","console","log","_a","fields","reservation","notify","errorList","Object","values","flat","map","join","Number","schedule","time","timeSlot","date","day","from_timestamp","from","to_timestamp","filter","item","success","_b","close","location","reload","iframe","height","bookingModal","h","class","ref","width","position","noPadding","src","frameborder","renderReservationDate","innerHTML","Calendar","renderReservationTime","TimeIcon","render","Host","required","money","price","size","loaderPosition","fill","onClick","BookingTime","index","name","JSON","stringify","SallaConditionalFields","hideAllOptions","optionId","host","querySelectorAll","forEach","field","classList","dataset","disableInputs","input","setAttribute","removeAttribute","tagName","toLowerCase","includes","getAttribute","hasOwnProperty","checked","changeHandler","target","replace","isMultiple","isRadio","isEqual","showWhen","trim","isSelected","selectedValues","Array","toString","showTheInput","closestProductOption","closest","optionRequired","checkboxes","document","isAnyChecked","some","checkbox","componentDidRender","optionName","querySelector"],"sources":["src/components/salla-booking-field/salla-booking-field.scss?tag=salla-booking-field","src/components/salla-booking-field/salla-booking-field.tsx","src/components/salla-conditional-fields/salla-conditional-fields.tsx"],"sourcesContent":[":host {\n display: block;\n}\n","import { Component, Host, Prop, h, Element, State, Event, EventEmitter } from '@stencil/core';\nimport { Option, Reservation } from './interfaces';\nimport BookingTime from '../../assets/svg/calendar-time.svg';\nimport Calendar from '../../assets/svg/calendar.svg';\nimport TimeIcon from '../../assets/svg/time.svg';\n\n@Component({\n tag: 'salla-booking-field',\n styleUrl: 'salla-booking-field.scss',\n})\nexport class SallaBookingField {\n /**\n * The booking option configuration\n */\n @Prop() option: Option;\n /**\n * The ID of the product for which the booking is being made\n */\n @Prop() productId: number;\n @Element() host: HTMLElement;\n @State() bookNowLabel: string = salla.lang.get('pages.cart.book_an_appointment', 'حجز موعد');\n @State() editLabel: string = salla.lang.get('pages.cart.edit_an_appointment', 'تعديل الموعد');\n @State() bookedLabel: string = salla.lang.get('pages.cart.booked_successfully', 'تمت اضافة الموعد بنجاح');\n @State() selectDate: string = salla.lang.get('pages.cart.select_appointment_date', 'حدد تاريخ الموعد');\n @State() bookingUrl: string = '';\n @State() iframeReady: boolean = false;\n @State() reservations: Reservation[] = [];\n @State() reservationsInput: HTMLInputElement;\n\n /**\n * Event emitted when the input is invalid.\n */\n @Event() invalidInput: EventEmitter<any>;\n\n private modal: HTMLSallaModalElement;\n private iframe: HTMLIFrameElement;\n\n constructor() {\n // Load translations\n salla.lang.onLoaded(() => this.setTranslations());\n // Register event listeners\n Salla.event.on('booking::open', (data) => this.handleBookingOpen(data));\n }\n\n private async setTranslations() {\n const setNestedAsync = (lang, key, value) => {\n return new Promise((resolve) => {\n salla.helpers.setNested(salla.lang.messages[lang], key, value);\n resolve(true);\n });\n };\n\n await setNestedAsync('ar.trans', 'pages.cart.book_an_appointment', 'حجز موعد');\n await setNestedAsync('en.trans', 'pages.cart.book_an_appointment', 'Book an Appointment');\n await setNestedAsync('ar.trans', 'pages.cart.edit_an_appointment', 'تعديل الموعد');\n await setNestedAsync('en.trans', 'pages.cart.edit_an_appointment', 'Edit an Appointment');\n await setNestedAsync('ar.trans', 'pages.cart.booked_successfully', 'تمت اضافة الموعد بنجاح');\n await setNestedAsync('en.trans', 'pages.cart.booked_successfully', 'Booked Successfully');\n await setNestedAsync('ar.trans', 'pages.cart.select_appointment_date', 'حدد تاريخ الموعد');\n await setNestedAsync('en.trans', 'pages.cart.select_appointment_date', 'Select appointment date');\n\n this.bookNowLabel = salla.lang.get('pages.cart.book_an_appointment');\n this.editLabel = salla.lang.get('pages.cart.edit_an_appointment');\n this.bookedLabel = salla.lang.get('pages.cart.booked_successfully');\n this.selectDate = salla.lang.get('pages.cart.select_appointment_date');\n }\n\n private openBookingModal(event: any, afterReload = false) {\n if (afterReload && (!event.detail || typeof event.detail !== 'number' || event.detail !== this.productId)) {\n return;\n }\n if (salla.config.isGuest()) {\n this.setAfterReloadEvent('booking::open-after-reload', this.productId);\n salla.event.dispatch('login::open');\n return;\n }\n salla.booking.add(this.productId, false)\n .then((resp) => {\n if (resp.data.redirect.to !== 'booking') {\n throw new Error('Unexpected redirect!');\n }\n salla.event.dispatch('booking::open', { url: resp.data.redirect.url, id: this.productId });\n })\n .catch((error) => {\n salla.error(salla.lang.get('common.errors.error_occurred'));\n salla.logger.error(error.response || error);\n });\n }\n\n private handleBookingOpen(data) {\n if (data.id !== this.productId) return;\n this.bookingUrl = salla.url.addParamToUrl('product_id', data.id, data.url);\n this.iframeReady = true;\n setTimeout(() => {\n this.modal.setTitle(this.selectDate);\n this.modal.open();\n }, 100);\n }\n\n private setAfterReloadEvent(event, payload) {\n salla.storage.set('afterReloadEvent', { event, payload });\n }\n\n private emitAfterReloadEvent() {\n const eventDetails = salla.storage.get('afterReloadEvent');\n if (eventDetails && eventDetails.event) {\n const customEvent = new CustomEvent(eventDetails.event, {\n detail: eventDetails.payload\n });\n window.dispatchEvent(customEvent)\n salla.storage.remove('afterReloadEvent');\n }\n }\n\n componentWillLoad() {\n if (this.option && this.option.details.length) {\n this.reservations = this.option.details;\n }\n }\n\n componentDidLoad() {\n window.addEventListener('booking::open-after-reload', (event) => this.openBookingModal(event, true));\n this.emitAfterReloadEvent();\n window.addEventListener('message', this.handleMessageEvent.bind(this));\n this.reservationsInput.addEventListener('invalid', e => this.invalidInput.emit(e));\n this.reservationsInput.addEventListener('input', () => {\n this.reservationsInput.setCustomValidity('');\n this.reservationsInput.reportValidity();\n });\n }\n\n private handleMessageEvent(event) {\n if (event.data.source !== 'booking') return;\n const action = event.data.type;\n const value = event.data.message;\n if (localStorage.getItem('debug')) console.log(`Received an action:${action}`, event.data);\n\n if (action === 'error') {\n if (value.fields?.reservation) {\n salla.notify.error(value.fields.reservation[0]);\n return;\n }\n const errorList = Object.values(value.fields || [value.message]).flat().map(error => `<li>${error}</li>`).join('');\n salla.notify.error(`<ul>${errorList}</ul>`);\n }\n\n if (action === 'success') {\n if (Number(value.productId) !== Number(this.productId)) return;\n this.reservations = value.data.reservations.map(schedule => {\n if (schedule.time && schedule.time.length > 0) {\n const timeSlot = schedule.time[0];\n return {\n date: schedule.date,\n day: schedule.day,\n from_timestamp: timeSlot.from,\n to_timestamp: timeSlot.to,\n };\n }\n return null;\n }).filter(item => item !== null);\n\n salla.notify.success(this.bookedLabel);\n this.modal?.close();\n setTimeout(() => window.location.reload());\n }\n\n if (action === 'height') {\n this.iframe.height = value?.height + 'px';\n }\n }\n\n private bookingModal() {\n return (\n <salla-modal class=\"s-booking-field-modal\" ref={modal => (this.modal = modal)} width=\"md\" position=\"middle\" noPadding>\n <iframe ref={iframe => (this.iframe = iframe)} src={this.bookingUrl} frameborder=\"0\"></iframe>\n </salla-modal>\n );\n }\n\n renderReservationDate(reservation: Reservation) {\n return (\n <span class={reservation.from_timestamp ? 's-booking-field-reservations-has-time' : ''}>\n <i class=\"s-booking-field-reservations-icon\" innerHTML={Calendar}></i>\n {reservation.date}\n </span>\n );\n }\n\n renderReservationTime(reservation: Reservation) {\n if (!reservation.from_timestamp) return '';\n return (\n <span class=\"s-booking-field-reservations-time\">\n <i class=\"s-booking-field-reservations-icon\" innerHTML={TimeIcon}></i>\n <span>\n {reservation.from_timestamp} - {reservation.to_timestamp}\n </span>\n </span>\n );\n }\n\n render() {\n return (\n <Host>\n <div class=\"s-booking-field-main\">\n {this.option.required || this.reservations.length > 0 ? <div class=\"s-booking-field-price\">\n <span>{salla.money(this.option.price)}</span>\n </div> : ''}\n <salla-button class=\"s-booking-field-book-now\" size=\"small\" loaderPosition=\"center\" fill=\"outline\" onClick={event => this.openBookingModal(event, false)}>\n <span class=\"s-booking-field-book-now-content\">\n <span innerHTML={BookingTime}></span>\n {this.reservations.length ? this.editLabel : this.bookNowLabel}\n </span>\n </salla-button>\n </div>\n {this.reservations.length > 0 && (\n <div class=\"s-booking-field-reservations\">\n {this.reservations.map((reservation, index) => (\n <div key={index} class=\"s-booking-field-reservations-item\">\n {this.renderReservationDate(reservation)}\n {this.renderReservationTime(reservation)}\n </div>\n ))}\n </div>\n )}\n <input\n class=\"s-hidden\"\n name={this.option.name}\n required={this.option.required}\n value={JSON.stringify(this.reservations) === '[]' ? '' : JSON.stringify(this.reservations)}\n ref={reservations => this.reservationsInput = reservations}\n />\n {this.iframeReady && this.bookingModal()}\n </Host>\n );\n }\n}\n","import { Component, Element, Host, Listen, h } from '@stencil/core';\n\n/**\n * its to easy to use, currenlty its support select & checkbox input as trigger for show/hide the dom\n * the dom you can put it like this data-show-when=\"{name of the field} {= or !=} {value of the field}\"\n */\n@Component({\n tag: 'salla-conditional-fields'\n})\nexport class SallaConditionalFields {\n\n @Element() host: HTMLElement;\n\n private hideAllOptions(optionId) {\n this.host.querySelectorAll(`[data-show-when^=\"options[${optionId}\"]`).forEach((field: HTMLElement) => {\n field.classList.add('hidden');\n this.hideAllOptions(field.dataset.optionId);\n this.disableInputs(field);\n });\n }\n\n private disableInputs(field) {\n field.querySelectorAll('[name]').forEach((input) => {\n\n input.setAttribute('disabled', '');\n input.removeAttribute('required');\n if (input?.tagName?.toLowerCase() === 'select') {\n input.value = ''\n }\n if (['checkbox'].includes(input.getAttribute('type')) && input.hasOwnProperty('checked')) {\n // @ts-ignore\n input.checked = false;\n }\n });\n }\n \n @Listen('change')\n changeHandler(event) {\n salla.event.emit('salla-onditional-fields::change', event);\n salla.log('Received the change event: ', event);\n\n if (!event.target || !['SELECT'].includes(event.target.tagName) && !['checkbox', 'radio'].includes(event.target.getAttribute('type'))) {\n salla.log('Ignore the change because is not a supported input: ' + (event?.target?.tagName || 'N/A'));\n return;\n }\n\n let optionId = event.target.name.replace('[]', '');\n let isMultiple = event.target.getAttribute('type') === 'checkbox';\n let isRadio = event.target.getAttribute('type') === 'radio';\n\n salla.log('Trying to find all elements with condition:', `[data-show-when^=\"${optionId}\"]`);\n\n this.host.querySelectorAll(`[data-show-when^=\"${optionId}\"]`)\n .forEach((field: HTMLElement) => {\n let isEqual = !field?.dataset.showWhen.includes('!=');\n let value = field?.dataset.showWhen.replace(/(.*)(=|!=)(.*)/gm, '$3').trim();\n let isSelected;\n if (isMultiple) {\n let selectedValues = Array.from(this.host.querySelectorAll(`input[name=\"${event.target.name}\"]:checked`), e => (e as HTMLInputElement)?.value);\n isSelected = selectedValues.includes(value.toString());\n } else if (isRadio) {\n // Handle radio inputs.\n isSelected = event.target.checked && event.target.value === value;\n } else {\n isSelected = value === event.target.value;\n }\n\n salla.log('The input is ', isMultiple ? 'Multiple' : isRadio ? 'Radio' : 'Single', ' value:', isSelected);\n\n let showTheInput = (isEqual && isSelected) || (!isEqual && !isSelected);\n if (showTheInput) {\n field.classList.remove('hidden');\n field.querySelectorAll('[name]').forEach((input) => {\n input.removeAttribute('disabled');\n\n const closestProductOption = (input as HTMLInputElement).closest('.s-product-options-option') as HTMLElement;\n if (closestProductOption.dataset.optionRequired === 'true') {\n input.setAttribute('required', '');\n }\n\n if (input.getAttribute('type') === 'checkbox') {\n const checkboxes = Array.from(document.querySelectorAll(`input[type=\"checkbox\"][name=\"${input.getAttribute('name')}\"]`)) as HTMLInputElement[];\n const isAnyChecked = checkboxes.some((checkbox) => checkbox.checked);\n if (isAnyChecked) {\n checkboxes.forEach((checkbox) => {\n checkbox.removeAttribute('required');\n });\n }\n }\n });\n } else {\n this.hideAllOptions(field.dataset.optionId);\n field.classList.add('hidden');\n this.disableInputs(field);\n }\n });\n } \n\n componentDidRender() {\n this.host.querySelectorAll(`[data-show-when]`).forEach((field) => {\n // @ts-ignore\n let optionName = field?.dataset?.showWhen.replace(/(.*)(=|!=)(.*)/gm, '$1').trim();\n if (!optionName) {\n return;\n }\n\n this.changeHandler({\n target: this.host.querySelector('[name^=\"' + optionName + '\"]')\n })\n });\n }\n\n render() {\n return (\n <Host>\n <slot></slot>\n </Host>\n );\n }\n}\n"],"mappings":";;;0nFAAA,MAAMA,EAAuB,uB,MCUhBC,EAAiB,MA2B5B,WAAAC,CAAAC,G,mDAjBSC,KAAYC,aAAWC,MAAMC,KAAKC,IAAI,iCAAkC,YACxEJ,KAASK,UAAWH,MAAMC,KAAKC,IAAI,iCAAkC,gBACrEJ,KAAWM,YAAWJ,MAAMC,KAAKC,IAAI,iCAAkC,0BACvEJ,KAAUO,WAAWL,MAAMC,KAAKC,IAAI,qCAAsC,oBAC1EJ,KAAUQ,WAAW,GACrBR,KAAWS,YAAY,MACvBT,KAAYU,aAAkB,GAarCR,MAAMC,KAAKQ,UAAS,IAAMX,KAAKY,oBAE/BC,MAAMC,MAAMC,GAAG,iBAAkBC,GAAShB,KAAKiB,kBAAkBD,IAClE,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