@salla.sa/twilight-components 2.14.268 → 2.14.269

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 (139) hide show
  1. package/dist/cjs/{app-globals-DCdSMY4P.js → app-globals-B7YAF7ga.js} +1 -1
  2. package/dist/cjs/{filepond-DSrOeCIF.js → filepond-D6XPg5kE.js} +1 -1
  3. package/dist/cjs/{filepond-plugin-file-poster-kTPFjj4a.js → filepond-plugin-file-poster-Ca3ug6Xt.js} +1 -1
  4. package/dist/cjs/{filepond-plugin-file-validate-size-CWcxao8l.js → filepond-plugin-file-validate-size-DS2Mw0bF.js} +1 -1
  5. package/dist/cjs/{filepond-plugin-file-validate-type-CP295r_S.js → filepond-plugin-file-validate-type-i3PdqD02.js} +1 -1
  6. package/dist/cjs/{filepond-plugin-image-edit-B8p_l6WM.js → filepond-plugin-image-edit-BnJ1hRjZ.js} +1 -1
  7. package/dist/cjs/{filepond-plugin-image-exif-orientation-BH0nNaQs.js → filepond-plugin-image-exif-orientation-eA-6o0CQ.js} +1 -1
  8. package/dist/cjs/{filepond-plugin-image-preview-A5H8-Nsz.js → filepond-plugin-image-preview-rPJIbgJl.js} +1 -1
  9. package/dist/cjs/{index-BjUgPABq.js → index-CEuiWga2.js} +2 -2
  10. package/dist/cjs/{index-Dwv0QRlo.js → index-m1BoKmuw.js} +1 -1
  11. package/dist/cjs/loader.cjs.js +2 -2
  12. package/dist/cjs/salla-accordion_4.cjs.entry.js +1 -1
  13. package/dist/cjs/salla-add-product-button_51.cjs.entry.js +24 -14
  14. package/dist/cjs/salla-advertisement.cjs.entry.js +1 -1
  15. package/dist/cjs/salla-app-install-alert.cjs.entry.js +1 -1
  16. package/dist/cjs/salla-apps-icons.cjs.entry.js +1 -1
  17. package/dist/cjs/salla-booking-field_2.cjs.entry.js +1 -1
  18. package/dist/cjs/salla-cart-item-offers.cjs.entry.js +1 -1
  19. package/dist/cjs/salla-conditional-offer.cjs.entry.js +1 -1
  20. package/dist/cjs/salla-contacts.cjs.entry.js +1 -1
  21. package/dist/cjs/salla-filters-widget.cjs.entry.js +1 -1
  22. package/dist/cjs/salla-filters.cjs.entry.js +1 -1
  23. package/dist/cjs/salla-installment.cjs.entry.js +1 -1
  24. package/dist/cjs/salla-loyalty-prize-item.cjs.entry.js +1 -1
  25. package/dist/cjs/salla-loyalty-program.cjs.entry.js +1 -1
  26. package/dist/cjs/salla-metadata.cjs.entry.js +1 -1
  27. package/dist/cjs/salla-notification-item.cjs.entry.js +1 -1
  28. package/dist/cjs/salla-notifications.cjs.entry.js +1 -1
  29. package/dist/cjs/salla-offer.cjs.entry.js +1 -1
  30. package/dist/cjs/salla-order-details-multiple-bundle-product.cjs.entry.js +1 -1
  31. package/dist/cjs/salla-order-details.cjs.entry.js +1 -1
  32. package/dist/cjs/salla-order-summary.cjs.entry.js +1 -1
  33. package/dist/cjs/salla-orders.cjs.entry.js +1 -1
  34. package/dist/cjs/salla-payments.cjs.entry.js +1 -1
  35. package/dist/cjs/salla-price-range.cjs.entry.js +1 -1
  36. package/dist/cjs/salla-product-options.cjs.entry.js +1 -1
  37. package/dist/cjs/salla-review-card.cjs.entry.js +1 -1
  38. package/dist/cjs/salla-reviews-page.cjs.entry.js +1 -1
  39. package/dist/cjs/salla-reviews.cjs.entry.js +1 -1
  40. package/dist/cjs/salla-social.cjs.entry.js +1 -1
  41. package/dist/cjs/salla-tiered-offer.cjs.entry.js +1 -1
  42. package/dist/cjs/salla-tooltip.cjs.entry.js +1 -1
  43. package/dist/cjs/salla-verify.cjs.entry.js +1 -1
  44. package/dist/cjs/salla-wallet.cjs.entry.js +1 -1
  45. package/dist/cjs/twilight.cjs.js +2 -2
  46. package/dist/collection/components/salla-login-modal/salla-login-modal.js +15 -5
  47. package/dist/components/index.js +2 -2
  48. package/dist/components/salla-login-modal.js +15 -5
  49. package/dist/esm/{app-globals-DKMXkUnR.js → app-globals-iDxf7CbG.js} +1 -1
  50. package/dist/esm/{filepond-PEXRwe-a.js → filepond-CkstHAv8.js} +1 -1
  51. package/dist/esm/{filepond-plugin-file-poster-kyH2loNg.js → filepond-plugin-file-poster-YjotDtvM.js} +1 -1
  52. package/dist/esm/{filepond-plugin-file-validate-size-erHt3cr_.js → filepond-plugin-file-validate-size-CfYe9saz.js} +1 -1
  53. package/dist/esm/{filepond-plugin-file-validate-type-gyWa6zhf.js → filepond-plugin-file-validate-type-D11qazvk.js} +1 -1
  54. package/dist/esm/{filepond-plugin-image-edit-ChS32vNL.js → filepond-plugin-image-edit-BkSt-Ki1.js} +1 -1
  55. package/dist/esm/{filepond-plugin-image-exif-orientation-qhVLNALS.js → filepond-plugin-image-exif-orientation-C2zdDQVD.js} +1 -1
  56. package/dist/esm/{filepond-plugin-image-preview-BwgD68LJ.js → filepond-plugin-image-preview-CARveiMV.js} +1 -1
  57. package/dist/esm/{index-Dkrl7rvC.js → index-CW7BJxwK.js} +2 -2
  58. package/dist/esm/{index-Bc4ObK1O.js → index-exk9-UlL.js} +1 -1
  59. package/dist/esm/loader.js +3 -3
  60. package/dist/esm/salla-accordion_4.entry.js +1 -1
  61. package/dist/esm/salla-add-product-button_51.entry.js +24 -14
  62. package/dist/esm/salla-advertisement.entry.js +1 -1
  63. package/dist/esm/salla-app-install-alert.entry.js +1 -1
  64. package/dist/esm/salla-apps-icons.entry.js +1 -1
  65. package/dist/esm/salla-booking-field_2.entry.js +1 -1
  66. package/dist/esm/salla-cart-item-offers.entry.js +1 -1
  67. package/dist/esm/salla-conditional-offer.entry.js +1 -1
  68. package/dist/esm/salla-contacts.entry.js +1 -1
  69. package/dist/esm/salla-filters-widget.entry.js +1 -1
  70. package/dist/esm/salla-filters.entry.js +1 -1
  71. package/dist/esm/salla-installment.entry.js +1 -1
  72. package/dist/esm/salla-loyalty-prize-item.entry.js +1 -1
  73. package/dist/esm/salla-loyalty-program.entry.js +1 -1
  74. package/dist/esm/salla-metadata.entry.js +1 -1
  75. package/dist/esm/salla-notification-item.entry.js +1 -1
  76. package/dist/esm/salla-notifications.entry.js +1 -1
  77. package/dist/esm/salla-offer.entry.js +1 -1
  78. package/dist/esm/salla-order-details-multiple-bundle-product.entry.js +1 -1
  79. package/dist/esm/salla-order-details.entry.js +1 -1
  80. package/dist/esm/salla-order-summary.entry.js +1 -1
  81. package/dist/esm/salla-orders.entry.js +1 -1
  82. package/dist/esm/salla-payments.entry.js +1 -1
  83. package/dist/esm/salla-price-range.entry.js +1 -1
  84. package/dist/esm/salla-product-options.entry.js +1 -1
  85. package/dist/esm/salla-review-card.entry.js +1 -1
  86. package/dist/esm/salla-reviews-page.entry.js +1 -1
  87. package/dist/esm/salla-reviews.entry.js +1 -1
  88. package/dist/esm/salla-social.entry.js +1 -1
  89. package/dist/esm/salla-tiered-offer.entry.js +1 -1
  90. package/dist/esm/salla-tooltip.entry.js +1 -1
  91. package/dist/esm/salla-verify.entry.js +1 -1
  92. package/dist/esm/salla-wallet.entry.js +1 -1
  93. package/dist/esm/twilight.js +3 -3
  94. package/dist/twilight/{p-f6262928.entry.js → p-08965c8a.entry.js} +1 -1
  95. package/dist/twilight/{p-c146c961.entry.js → p-13f3603f.entry.js} +1 -1
  96. package/dist/twilight/{p-3fca5120.entry.js → p-17277556.entry.js} +1 -1
  97. package/dist/twilight/{p-43eeca9d.entry.js → p-1d9eee8d.entry.js} +1 -1
  98. package/dist/twilight/{p-e44dfa5a.entry.js → p-226f53ef.entry.js} +1 -1
  99. package/dist/twilight/{p-8a388d90.entry.js → p-257420f8.entry.js} +1 -1
  100. package/dist/twilight/{p-765187bb.entry.js → p-2c378384.entry.js} +1 -1
  101. package/dist/twilight/{p-61386416.entry.js → p-2cad7c7d.entry.js} +1 -1
  102. package/dist/twilight/{p-3096365c.entry.js → p-4cac426a.entry.js} +1 -1
  103. package/dist/twilight/{p-d2e43463.entry.js → p-502eb830.entry.js} +1 -1
  104. package/dist/twilight/{p-e0541abb.entry.js → p-5b6961cf.entry.js} +1 -1
  105. package/dist/twilight/{p-edac5aa4.entry.js → p-6c518217.entry.js} +1 -1
  106. package/dist/twilight/{p-b2667b1a.entry.js → p-773aad5f.entry.js} +1 -1
  107. package/dist/twilight/{p-c94c1971.entry.js → p-7a78935c.entry.js} +1 -1
  108. package/dist/twilight/{p-94d5abb2.entry.js → p-7c32836f.entry.js} +1 -1
  109. package/dist/twilight/{p-76faa3dc.entry.js → p-7f7f7eea.entry.js} +1 -1
  110. package/dist/twilight/{p-8f1c1e48.entry.js → p-80851455.entry.js} +1 -1
  111. package/dist/twilight/{p-CMIEpBEo.js → p-B6Gr8Kqx.js} +1 -1
  112. package/dist/twilight/{p-Dkrl7rvC.js → p-CW7BJxwK.js} +1 -1
  113. package/dist/twilight/{p-0wo7xVMQ.js → p-D4IjJ5dP.js} +1 -1
  114. package/dist/twilight/{p-Bfh2Ewd2.js → p-DICYBv-S.js} +1 -1
  115. package/dist/twilight/{p-BdZFi-dF.js → p-DVpUP3Ee.js} +1 -1
  116. package/dist/twilight/{p-CMGWNTqw.js → p-Db6gELNJ.js} +1 -1
  117. package/dist/twilight/{p-BOZpx8y8.js → p-Df8sri_v.js} +1 -1
  118. package/dist/twilight/{p-Drf1TOhi.js → p-DuGXoJuk.js} +1 -1
  119. package/dist/twilight/{p-77558f05.entry.js → p-a52a811c.entry.js} +1 -1
  120. package/dist/twilight/{p-2aa837e5.entry.js → p-a875574d.entry.js} +1 -1
  121. package/dist/twilight/{p-f4054651.entry.js → p-ae3ea336.entry.js} +1 -1
  122. package/dist/twilight/{p-6b5e5a40.entry.js → p-b296aaf2.entry.js} +1 -1
  123. package/dist/twilight/{p-d614ac6e.entry.js → p-b753e41d.entry.js} +1 -1
  124. package/dist/twilight/{p-ee72cd10.entry.js → p-bfd2610a.entry.js} +1 -1
  125. package/dist/twilight/{p-DqXHRruO.js → p-cGITsIod.js} +1 -1
  126. package/dist/twilight/{p-02c9b8cd.entry.js → p-ceb52fb8.entry.js} +1 -1
  127. package/dist/twilight/{p-100dc2af.entry.js → p-d00dcdc2.entry.js} +1 -1
  128. package/dist/twilight/{p-ff2c2e92.entry.js → p-d598d23b.entry.js} +1 -1
  129. package/dist/twilight/p-da626246.entry.js +11 -0
  130. package/dist/twilight/{p-231c080a.entry.js → p-ddcf9b97.entry.js} +1 -1
  131. package/dist/twilight/{p-63ea69b0.entry.js → p-e51bf0cd.entry.js} +1 -1
  132. package/dist/twilight/{p-5b7c9c27.entry.js → p-e807c9d9.entry.js} +1 -1
  133. package/dist/twilight/{p-4cf87671.entry.js → p-eafec9e8.entry.js} +1 -1
  134. package/dist/twilight/{p-0f7c48c5.entry.js → p-eba7fe7d.entry.js} +1 -1
  135. package/dist/twilight/{p-c89dfa69.entry.js → p-f3f7f09f.entry.js} +1 -1
  136. package/dist/twilight/{p-C6w77Z-I.js → p-t1jwrj3i.js} +1 -1
  137. package/dist/twilight/twilight.esm.js +1 -1
  138. package/package.json +5 -5
  139. package/dist/twilight/p-a57e243b.entry.js +0 -11
@@ -208,7 +208,8 @@ const SallaLoginModal$1 = /*@__PURE__*/ proxyCustomElement(class SallaLoginModal
208
208
  }
209
209
  async handleIframeStorageAction(value) {
210
210
  let token, cartUserId = salla.storage.get('cart.user_id');
211
- Object.entries(value).filter(item => !salla.storage.get(item[0]))
211
+ let withCartReset = false;
212
+ Object.entries(value).filter(item => !Salla.storage.get(item[0]))
212
213
  .forEach(([key, value]) => {
213
214
  salla.log('Shared storage from accounts domain', key, value);
214
215
  let cleanedValue = (typeof value === 'string') ? value?.replace(/^"|"$/g, '') : value;
@@ -216,17 +217,26 @@ const SallaLoginModal$1 = /*@__PURE__*/ proxyCustomElement(class SallaLoginModal
216
217
  if (key === 'token') {
217
218
  token = cleanedValue;
218
219
  }
219
- if (key === 'user' && cartUserId && cleanedValue.id !== cartUserId) {
220
- salla.cart.reset();
220
+ if (key === 'user' && cartUserId && (cleanedValue.id !== cartUserId)) {
221
+ withCartReset = true;
221
222
  }
222
223
  });
223
224
  if (token) {
224
225
  this.modal.close();
225
- salla.auth.event.tokenFetched(token);
226
- !salla.auth.api.isSessionless() && await salla.auth.api.request('auth/jwt');
226
+ Salla.auth.event.tokenFetched(token);
227
+ try {
228
+ await Salla.cart.api.assign();
229
+ }
230
+ catch (error) {
231
+ Salla.log('Error on assign');
232
+ }
233
+ await Salla.cart.api.assign();
234
+ withCartReset && Salla.cart.reset();
235
+ !Salla.auth.api.isSessionless() && await Salla.auth.api.request('auth/jwt');
227
236
  setTimeout(() => window.location.reload(), 100);
228
237
  return;
229
238
  }
239
+ withCartReset && Salla.cart.reset();
230
240
  }
231
241
  sendMessageToIframe(message) {
232
242
  if (!this.iframe)
@@ -1,7 +1,7 @@
1
1
  /*!
2
2
  * Crafted with ❤ by Salla
3
3
  */
4
- import { L as LazyLoad } from './index-Dkrl7rvC.js';
4
+ import { L as LazyLoad } from './index-CW7BJxwK.js';
5
5
 
6
6
  function appGlobalScript () {
7
7
  // Only initialize it one time for the entire application
@@ -1,7 +1,7 @@
1
1
  /*!
2
2
  * Crafted with ❤ by Salla
3
3
  */
4
- import { a as getDefaultExportFromCjs } from './index-Dkrl7rvC.js';
4
+ import { a as getDefaultExportFromCjs } from './index-CW7BJxwK.js';
5
5
 
6
6
  function _mergeNamespaces(n, m) {
7
7
  m.forEach(function (e) {
@@ -1,7 +1,7 @@
1
1
  /*!
2
2
  * Crafted with ❤ by Salla
3
3
  */
4
- import { a as getDefaultExportFromCjs } from './index-Dkrl7rvC.js';
4
+ import { a as getDefaultExportFromCjs } from './index-CW7BJxwK.js';
5
5
 
6
6
  function _mergeNamespaces(n, m) {
7
7
  m.forEach(function (e) {
@@ -1,7 +1,7 @@
1
1
  /*!
2
2
  * Crafted with ❤ by Salla
3
3
  */
4
- import { a as getDefaultExportFromCjs } from './index-Dkrl7rvC.js';
4
+ import { a as getDefaultExportFromCjs } from './index-CW7BJxwK.js';
5
5
 
6
6
  function _mergeNamespaces(n, m) {
7
7
  m.forEach(function (e) {
@@ -1,7 +1,7 @@
1
1
  /*!
2
2
  * Crafted with ❤ by Salla
3
3
  */
4
- import { a as getDefaultExportFromCjs } from './index-Dkrl7rvC.js';
4
+ import { a as getDefaultExportFromCjs } from './index-CW7BJxwK.js';
5
5
 
6
6
  function _mergeNamespaces(n, m) {
7
7
  m.forEach(function (e) {
@@ -1,7 +1,7 @@
1
1
  /*!
2
2
  * Crafted with ❤ by Salla
3
3
  */
4
- import { a as getDefaultExportFromCjs } from './index-Dkrl7rvC.js';
4
+ import { a as getDefaultExportFromCjs } from './index-CW7BJxwK.js';
5
5
 
6
6
  function _mergeNamespaces(n, m) {
7
7
  m.forEach(function (e) {
@@ -1,7 +1,7 @@
1
1
  /*!
2
2
  * Crafted with ❤ by Salla
3
3
  */
4
- import { a as getDefaultExportFromCjs } from './index-Dkrl7rvC.js';
4
+ import { a as getDefaultExportFromCjs } from './index-CW7BJxwK.js';
5
5
 
6
6
  function _mergeNamespaces(n, m) {
7
7
  m.forEach(function (e) {
@@ -1,7 +1,7 @@
1
1
  /*!
2
2
  * Crafted with ❤ by Salla
3
3
  */
4
- import { a as getDefaultExportFromCjs } from './index-Dkrl7rvC.js';
4
+ import { a as getDefaultExportFromCjs } from './index-CW7BJxwK.js';
5
5
 
6
6
  function _mergeNamespaces(n, m) {
7
7
  m.forEach(function (e) {