@salla.sa/twilight-components 2.12.68 → 2.12.69

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 (60) hide show
  1. package/dist/cjs/{app-globals-537a7062.js → app-globals-36ab7ecf.js} +2 -2
  2. package/dist/cjs/{app-globals-537a7062.js.map → app-globals-36ab7ecf.js.map} +1 -1
  3. package/dist/cjs/loader.cjs.js +2 -2
  4. package/dist/cjs/salla-add-product-button_47.cjs.entry.js +12 -5
  5. package/dist/cjs/salla-add-product-button_47.cjs.entry.js.map +1 -1
  6. package/dist/cjs/salla-contacts.cjs.entry.js +2 -0
  7. package/dist/cjs/salla-contacts.cjs.entry.js.map +1 -1
  8. package/dist/cjs/twilight.cjs.js +2 -2
  9. package/dist/collection/components/salla-bottom-alert/salla-bottom-alert.js +14 -5
  10. package/dist/collection/components/salla-bottom-alert/salla-bottom-alert.js.map +1 -1
  11. package/dist/collection/components/salla-contacts/salla-contacts.js +2 -0
  12. package/dist/collection/components/salla-contacts/salla-contacts.js.map +1 -1
  13. package/dist/components/index.js +1 -1
  14. package/dist/components/index.js.map +1 -1
  15. package/dist/components/salla-bottom-alert.js +14 -5
  16. package/dist/components/salla-bottom-alert.js.map +1 -1
  17. package/dist/components/salla-contacts.js +2 -0
  18. package/dist/components/salla-contacts.js.map +1 -1
  19. package/dist/esm/{app-globals-7795aa55.js → app-globals-3843d7b4.js} +2 -2
  20. package/dist/esm/{app-globals-7795aa55.js.map → app-globals-3843d7b4.js.map} +1 -1
  21. package/dist/esm/loader.js +2 -2
  22. package/dist/esm/salla-add-product-button_47.entry.js +12 -5
  23. package/dist/esm/salla-add-product-button_47.entry.js.map +1 -1
  24. package/dist/esm/salla-contacts.entry.js +2 -0
  25. package/dist/esm/salla-contacts.entry.js.map +1 -1
  26. package/dist/esm/twilight.js +2 -2
  27. package/dist/esm-es5/{app-globals-7795aa55.js → app-globals-3843d7b4.js} +2 -2
  28. package/dist/{twilight/p-14c42ca3.system.js.map → esm-es5/app-globals-3843d7b4.js.map} +1 -1
  29. package/dist/esm-es5/loader.js +1 -1
  30. package/dist/esm-es5/loader.js.map +1 -1
  31. package/dist/esm-es5/salla-add-product-button_47.entry.js +1 -1
  32. package/dist/esm-es5/salla-add-product-button_47.entry.js.map +1 -1
  33. package/dist/esm-es5/salla-contacts.entry.js +1 -1
  34. package/dist/esm-es5/salla-contacts.entry.js.map +1 -1
  35. package/dist/esm-es5/twilight.js +1 -1
  36. package/dist/esm-es5/twilight.js.map +1 -1
  37. package/dist/twilight/{p-0b684f2a.system.entry.js → p-0a6b09fa.system.entry.js} +2 -2
  38. package/dist/twilight/p-0a6b09fa.system.entry.js.map +1 -0
  39. package/dist/twilight/{p-688e0ccc.system.entry.js → p-17637111.system.entry.js} +2 -2
  40. package/dist/twilight/p-17637111.system.entry.js.map +1 -0
  41. package/dist/twilight/p-2059b78a.system.js +5 -0
  42. package/dist/twilight/{p-a8240d5d.system.js.map → p-2059b78a.system.js.map} +1 -1
  43. package/dist/twilight/{p-da02effc.js → p-66395721.js} +2 -2
  44. package/dist/twilight/{p-da02effc.js.map → p-66395721.js.map} +1 -1
  45. package/dist/twilight/{p-14c42ca3.system.js → p-75f5e4ac.system.js} +2 -2
  46. package/dist/{esm-es5/app-globals-7795aa55.js.map → twilight/p-75f5e4ac.system.js.map} +1 -1
  47. package/dist/twilight/{p-8defc948.entry.js → p-902f747a.entry.js} +2 -2
  48. package/dist/twilight/p-902f747a.entry.js.map +1 -0
  49. package/dist/twilight/{p-bd831e45.entry.js → p-ce2fd4cc.entry.js} +2 -2
  50. package/dist/twilight/p-ce2fd4cc.entry.js.map +1 -0
  51. package/dist/twilight/twilight.esm.js +1 -1
  52. package/dist/twilight/twilight.esm.js.map +1 -1
  53. package/dist/twilight/twilight.js +1 -1
  54. package/dist/types/components/salla-bottom-alert/salla-bottom-alert.d.ts +2 -0
  55. package/package.json +4 -4
  56. package/dist/twilight/p-0b684f2a.system.entry.js.map +0 -1
  57. package/dist/twilight/p-688e0ccc.system.entry.js.map +0 -1
  58. package/dist/twilight/p-8defc948.entry.js.map +0 -1
  59. package/dist/twilight/p-a8240d5d.system.js +0 -5
  60. package/dist/twilight/p-bd831e45.entry.js.map +0 -1
@@ -68,6 +68,8 @@ const SallaContacts = class {
68
68
  return `tel:${this.contacts[type]}`;
69
69
  case 'mobile':
70
70
  return `tel:${this.contacts[type]}`;
71
+ case 'whatsapp':
72
+ return salla.url.get('whatsapp/send');
71
73
  case 'email':
72
74
  return `mailto:${this.contacts[type]}`;
73
75
  case 'telegram':
@@ -1 +1 @@
1
- {"file":"salla-contacts.entry.cjs.js","mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,MAAM,gBAAgB,GAAG,iEAAiE;;MCa7E,aAAa;EACxB;;;;;;;;oBAkByB,KAAK,CAAC,MAAM,CAAC,GAAG,CAAC,gBAAgB,CAAC;qBACjC,EAAE,MAAM,EAAE,QAAQ,EAAE,KAAK,EAAE,QAAQ,SAAEA,UAAK,EAAE;IAlBpE,IAAI,CAAC,WAAW,GAAG,CAAA,MAAA,IAAI,CAAC,IAAI,CAAC,aAAa,CAAC,kBAAkB,CAAC,0CAAE,SAAS,KAAI,qFAAqF,CAAC,IAAI,CAAC,SAAS,IAAI,sCAAsC,MAAM,CAAC;IAElO,KAAK,CAAC,OAAO,CAAC;MACZ,IAAI,CAAC,QAAQ,GAAG,KAAK,CAAC,MAAM,CAAC,GAAG,CAAC,gBAAgB,CAAC,CAAC;KACpD,CAAC,CAAC;IAEH,KAAK,CAAC,IAAI,CAAC,QAAQ,CAAC;MAClB,IAAI,CAAC,aAAa,GAAG,KAAK,CAAC,IAAI,CAAC,GAAG,CAAC,sBAAsB,CAAC,CAAC;KAC7D,CAAC,CAAC;GACJ;EAWO,gBAAgB;IACtB,OAAO,MAAM,CAAC,OAAO,CAAC,IAAI,CAAC,QAAQ,CAAC;OACjC,MAAM,CAAC,CAAC,CAAC,IAAI,EAA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IACvB,OAAO,CAAC,KAAK,KAEb;QACEF,sBAAO,IAAI,CAAC,aAAa,OAAU;QACnCA,eAAG,KAAK,EAAC,SAAS,EAAC,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC,OAAO,CAAC,IAAI,CAAC,IAAG,OAAO,CAAC,KAAK,CAAK;OAC3E,CACF,CACC,CACL,CAAC,CACG,EACP;KACH;IACD,QACEA,QAACC,UAAI,IAAC,KAAK,EAAC,YAAY,IACrB,CAAC,IAAI,CAAC,SAAS,IAAID,gBAAI,KAAK,EAAC,kBAAkB,IAAE,IAAI,CAAC,aAAa,CAAM,EAC1EA,iBAAK,KAAK,EAAE;QACV,iBAAiB,EAAE,IAAI;QACvB,4BAA4B,EAAE,IAAI,CAAC,UAAU;QAC7C,0BAA0B,EAAE,CAAC,IAAI,CAAC,UAAU;QAC5C,4BAA4B,EAAE,IAAI,CAAC,SAAS;OAC7C,IAEE,aAAa,CAAC,GAAG,CAAC,CAAC,OAAO,EAAEE,OAAK,MAChCF,iBAAK,GAAG,EAAEE,OAAK,EAAE,EAAE,EAAC,cAAc,EAAC,SAAS,EAAE,IAAI,CAAC,WAAW;SAC3D,OAAO,CAAC,WAAW,EAAE,IAAI,CAAC,cAAc,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;SACvD,OAAO,CAAC,YAAY,EAAE,OAAO,CAAC,KAAK,CAAC,QAAQ,EAAE,CAAC;SAC/C,OAAO,CAAC,WAAW,EAAE,IAAI,CAAC,cAAc,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC,GACpD,CACP,CAAC,CACE,CACD,EACP;GACH;EACD,kBAAkB;;;IAEhB,MAAA,IAAI,CAAC,IAAI,CAAC,aAAa,CAAC,kBAAkB,CAAC,0CAAE,MAAM,EAAE,CAAC;GACvD;;;;;;;","names":["email","h","Host","index"],"sources":["src/components/salla-contacts/salla-contacts.scss?tag=salla-contacts","src/components/salla-contacts/salla-contacts.tsx"],"sourcesContent":[".unicode {\n unicode-bidi: plaintext;\n}","import { Component, Host, h, Prop, State, Element } from '@stencil/core';\nimport mobile from '../../assets/svg/iphone.svg';\nimport whatsapp from '../../assets/svg/whatsapp2.svg';\nimport phone from '../../assets/svg/phone.svg';\nimport telegram from '../../assets/svg/paper-plane-o.svg';\nimport email from '../../assets/svg/mail.svg';\n/**\n * @slot contact - Replaces contact item, has replaceable props `{icon}`, `{value}`.\n */\n@Component({\n tag: 'salla-contacts',\n styleUrl: 'salla-contacts.scss',\n})\nexport class SallaContacts {\n constructor() {\n this.contactSlot = this.host.querySelector('[slot=\"contact\"]')?.innerHTML || `<a href={link} class=\"s-contacts-item\"><span class=\"s-contacts-icon\">{icon}</span>${!this.iconsOnly && \"<span class='unicode'>{value}</span>\"}</a>`;\n\n salla.onReady(() => {\n this.contacts = salla.config.get('store.contacts');\n });\n\n salla.lang.onLoaded(() => {\n this.contactsTitle = salla.lang.get('blocks.footer.social');\n });\n }\n private readonly contactSlot: string;\n @Prop() contactsTitle: string;\n @Prop() hideTitle: boolean;\n @Prop() isHeader: boolean;\n @Prop() horizontal: boolean;\n @Prop() iconsOnly: boolean;\n @Element() host: HTMLElement;\n @State() contacts: any = salla.config.get('store.contacts');\n @State() iconsList: any = { mobile, whatsapp, phone, telegram, email }\n\n private getContactsArray() {\n return Object.entries(this.contacts)\n .filter(([_key, value]) => value !== '')\n .map(([type, value]) => ({ type, value }));\n }\n\n private getContactLink(type) {\n switch (type) {\n case 'phone':\n return `tel:${this.contacts[type]}`; \n case 'mobile':\n return `tel:${this.contacts[type]}`;\n case 'email':\n return `mailto:${this.contacts[type]}`;\n case 'telegram':\n return `https://t.me/${this.contacts[type]}`;\n default:\n return this.contacts[type];\n }\n }\n\n private getContactIcon(type) {\n return this.iconsList[type];\n }\n render() {\n const contactsArray = this.getContactsArray();\n if (this.isHeader && contactsArray && contactsArray.length > 0) {\n return (\n <Host class=\"s-contacts s-contacts-header\">\n {contactsArray.filter((contact) => contact.type == 'phone' || contact.type == 'email').map((contact, index) => (\n <a href={this.getContactLink(contact.type)} key={index} class=\"s-contacts-topnav-link\">\n {contact.type === 'email' ? (\n contact.value\n ) : (\n [\n <span>{this.contactsTitle}: </span>,\n <a class=\"unicode\" href={this.iconsList[contact.type]}>{contact.value}</a>\n ]\n )}\n </a>\n ))}\n </Host>\n );\n }\n return (\n <Host class=\"s-contacts\">\n {!this.hideTitle && <h3 class=\"s-contacts-title\">{this.contactsTitle}</h3>}\n <div class={{\n 's-contacts-list': true,\n 's-contacts-list-horizontal': this.horizontal,\n 's-contacts-list-vertical': !this.horizontal,\n 's-contacts-list-icons-only': this.iconsOnly\n }\n }>\n {contactsArray.map((contact, index) => (\n <div key={index} id=\"contact-slot\" innerHTML={this.contactSlot\n .replace(/\\{icon\\}/g, this.getContactIcon(contact.type))\n .replace(/\\{value\\}/g, contact.value.toString())\n .replace(/\\{link\\}/g, this.getContactLink(contact.type))}>\n </div>\n ))}\n </div>\n </Host>\n );\n }\n componentDidRender() {\n // this.host.querySelectorAll('#contact-slot').forEach(el => el.replaceWith(el.firstChild));\n this.host.querySelector('[slot=\"contact\"]')?.remove();\n }\n}\n\n"],"version":3}
1
+ {"file":"salla-contacts.entry.cjs.js","mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,MAAM,gBAAgB,GAAG,iEAAiE;;MCa7E,aAAa;EACxB;;;;;;;;oBAkByB,KAAK,CAAC,MAAM,CAAC,GAAG,CAAC,gBAAgB,CAAC;qBACjC,EAAE,MAAM,EAAE,QAAQ,EAAE,KAAK,EAAE,QAAQ,SAAEA,UAAK,EAAE;IAlBpE,IAAI,CAAC,WAAW,GAAG,CAAA,MAAA,IAAI,CAAC,IAAI,CAAC,aAAa,CAAC,kBAAkB,CAAC,0CAAE,SAAS,KAAI,qFAAqF,CAAC,IAAI,CAAC,SAAS,IAAI,sCAAsC,MAAM,CAAC;IAElO,KAAK,CAAC,OAAO,CAAC;MACZ,IAAI,CAAC,QAAQ,GAAG,KAAK,CAAC,MAAM,CA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E,OAAO,CAAC,KAAK,CAAC,QAAQ,EAAE,CAAC;SAC/C,OAAO,CAAC,WAAW,EAAE,IAAI,CAAC,cAAc,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC,GACpD,CACP,CAAC,CACE,CACD,EACP;GACH;EACD,kBAAkB;;;IAEhB,MAAA,IAAI,CAAC,IAAI,CAAC,aAAa,CAAC,kBAAkB,CAAC,0CAAE,MAAM,EAAE,CAAC;GACvD;;;;;;;","names":["email","h","Host","index"],"sources":["src/components/salla-contacts/salla-contacts.scss?tag=salla-contacts","src/components/salla-contacts/salla-contacts.tsx"],"sourcesContent":[".unicode {\n unicode-bidi: plaintext;\n}","import { Component, Host, h, Prop, State, Element } from '@stencil/core';\nimport mobile from '../../assets/svg/iphone.svg';\nimport whatsapp from '../../assets/svg/whatsapp2.svg';\nimport phone from '../../assets/svg/phone.svg';\nimport telegram from '../../assets/svg/paper-plane-o.svg';\nimport email from '../../assets/svg/mail.svg';\n/**\n * @slot contact - Replaces contact item, has replaceable props `{icon}`, `{value}`.\n */\n@Component({\n tag: 'salla-contacts',\n styleUrl: 'salla-contacts.scss',\n})\nexport class SallaContacts {\n constructor() {\n this.contactSlot = this.host.querySelector('[slot=\"contact\"]')?.innerHTML || `<a href={link} class=\"s-contacts-item\"><span class=\"s-contacts-icon\">{icon}</span>${!this.iconsOnly && \"<span class='unicode'>{value}</span>\"}</a>`;\n\n salla.onReady(() => {\n this.contacts = salla.config.get('store.contacts');\n });\n\n salla.lang.onLoaded(() => {\n this.contactsTitle = salla.lang.get('blocks.footer.social');\n });\n }\n private readonly contactSlot: string;\n @Prop() contactsTitle: string;\n @Prop() hideTitle: boolean;\n @Prop() isHeader: boolean;\n @Prop() horizontal: boolean;\n @Prop() iconsOnly: boolean;\n @Element() host: HTMLElement;\n @State() contacts: any = salla.config.get('store.contacts');\n @State() iconsList: any = { mobile, whatsapp, phone, telegram, email }\n\n private getContactsArray() {\n return Object.entries(this.contacts)\n .filter(([_key, value]) => value !== '')\n .map(([type, value]) => ({ type, value }));\n }\n\n private getContactLink(type) {\n switch (type) {\n case 'phone':\n return `tel:${this.contacts[type]}`; \n case 'mobile':\n return `tel:${this.contacts[type]}`;\n case 'whatsapp':\n return salla.url.get('whatsapp/send');\n case 'email':\n return `mailto:${this.contacts[type]}`;\n case 'telegram':\n return `https://t.me/${this.contacts[type]}`;\n default:\n return this.contacts[type];\n }\n }\n\n private getContactIcon(type) {\n return this.iconsList[type];\n }\n render() {\n const contactsArray = this.getContactsArray();\n if (this.isHeader && contactsArray && contactsArray.length > 0) {\n return (\n <Host class=\"s-contacts s-contacts-header\">\n {contactsArray.filter((contact) => contact.type == 'phone' || contact.type == 'email').map((contact, index) => (\n <a href={this.getContactLink(contact.type)} key={index} class=\"s-contacts-topnav-link\">\n {contact.type === 'email' ? (\n contact.value\n ) : (\n [\n <span>{this.contactsTitle}: </span>,\n <a class=\"unicode\" href={this.iconsList[contact.type]}>{contact.value}</a>\n ]\n )}\n </a>\n ))}\n </Host>\n );\n }\n return (\n <Host class=\"s-contacts\">\n {!this.hideTitle && <h3 class=\"s-contacts-title\">{this.contactsTitle}</h3>}\n <div class={{\n 's-contacts-list': true,\n 's-contacts-list-horizontal': this.horizontal,\n 's-contacts-list-vertical': !this.horizontal,\n 's-contacts-list-icons-only': this.iconsOnly\n }\n }>\n {contactsArray.map((contact, index) => (\n <div key={index} id=\"contact-slot\" innerHTML={this.contactSlot\n .replace(/\\{icon\\}/g, this.getContactIcon(contact.type))\n .replace(/\\{value\\}/g, contact.value.toString())\n .replace(/\\{link\\}/g, this.getContactLink(contact.type))}>\n </div>\n ))}\n </div>\n </Host>\n );\n }\n componentDidRender() {\n // this.host.querySelectorAll('#contact-slot').forEach(el => el.replaceWith(el.firstChild));\n this.host.querySelector('[slot=\"contact\"]')?.remove();\n }\n}\n\n"],"version":3}
@@ -6,7 +6,7 @@
6
6
  Object.defineProperty(exports, '__esModule', { value: true });
7
7
 
8
8
  const index = require('./index-40f35e63.js');
9
- const appGlobals = require('./app-globals-537a7062.js');
9
+ const appGlobals = require('./app-globals-36ab7ecf.js');
10
10
  require('./_commonjsHelpers-691dd63b.js');
11
11
 
12
12
  /*
@@ -23,7 +23,7 @@ const patchBrowser = () => {
23
23
 
24
24
  patchBrowser().then(options => {
25
25
  appGlobals.globalScripts();
26
- return index.bootstrapLazy(JSON.parse("[[\"salla-products-slider.cjs\",[[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\"],\"productsData\":[32],\"isReady\":[32],\"sourceValueIsValid\":[32],\"hasCustomComponent\":[32],\"apiUrl\":[32],\"parsedSourceValue\":[32]}]]],[\"salla-product-options.cjs\",[[0,\"salla-product-options\",{\"productId\":[2,\"product-id\"],\"options\":[1],\"optionsData\":[32],\"outOfStockText\":[32],\"donationAmount\":[32],\"selectDonationAmount\":[32],\"selectAmount\":[32],\"isCustomDonation\":[32],\"selectedOptions\":[32],\"canDisabled\":[32],\"selectedSkus\":[32],\"selectedOutSkus\":[32],\"getSelectedOptionsData\":[64],\"reportValidity\":[64],\"hasOutOfStockOption\":[64],\"getSelectedOptions\":[64],\"getOption\":[64]}]]],[\"salla-filters.cjs\",[[0,\"salla-filters\",{\"filters\":[1040],\"isSidebarOpen\":[32],\"filtersData\":[32],\"apply\":[32],\"reset\":[32],\"getFilters\":[64],\"applyFilters\":[64],\"resetFilters\":[64]}]]],[\"salla-notifications.cjs\",[[0,\"salla-notifications\",{\"loadMoreText\":[1,\"load-more-text\"],\"itemPerPage\":[2,\"item-per-page\"],\"notifications\":[32],\"pagination\":[32],\"hasInfiniteScroll\":[32],\"total\":[32],\"showPlaceholder\":[32],\"nextPage\":[32],\"no_notifications_trans\":[32],\"load_more_text_trans\":[32]}]]],[\"salla-advertisement.cjs\",[[0,\"salla-advertisement\",{\"position\":[32],\"advertisements\":[32],\"advertIcon\":[32],\"currentSlug\":[32]}]]],[\"salla-apps-icons.cjs\",[[0,\"salla-apps-icons\",{\"hideTitle\":[4,\"hide-title\"],\"appsTitle\":[1,\"apps-title\"],\"vertical\":[4],\"apps\":[32]}]]],[\"salla-contacts.cjs\",[[0,\"salla-contacts\",{\"contactsTitle\":[1,\"contacts-title\"],\"hideTitle\":[4,\"hide-title\"],\"isHeader\":[4,\"is-header\"],\"horizontal\":[4],\"iconsOnly\":[4,\"icons-only\"],\"contacts\":[32],\"iconsList\":[32]}]]],[\"salla-installment.cjs\",[[0,\"salla-installment\",{\"price\":[1],\"language\":[1],\"currency\":[1],\"tamaraIsActive\":[32],\"tabbyIsActive\":[32],\"spotiiIsActive\":[32]}]]],[\"salla-loyalty-prize-item.cjs\",[[0,\"salla-loyalty-prize-item\",{\"item\":[16]}]]],[\"salla-payments.cjs\",[[0,\"salla-payments\",{\"withSbc\":[4,\"with-sbc\"],\"sbcId\":[1,\"sbc-id\"],\"withMadeInKsa\":[4,\"with-made-in-ksa\"],\"payments\":[32],\"placeholderImage\":[32]}]]],[\"salla-products-list.cjs\",[[0,\"salla-products-list\",{\"source\":[1537],\"sourceValue\":[1032,\"source-value\"],\"limit\":[1026],\"sortBy\":[1025,\"sort-by\"],\"filtersResults\":[1540,\"filters-results\"],\"horizontalCards\":[516,\"horizontal-cards\"],\"productCardComponent\":[1,\"product-card-component\"],\"page\":[32],\"nextPage\":[32],\"hasInfiniteScroll\":[32],\"hasCustomComponent\":[32],\"sourceValueIsValid\":[32],\"placeholderText\":[32],\"isReady\":[32],\"showPlaceholder\":[32],\"parsedFilters\":[32],\"setFilters\":[64],\"reload\":[64]}]]],[\"salla-social.cjs\",[[0,\"salla-social\",{\"links\":[32],\"iconsList\":[32]}]]],[\"salla-conditional-fields.cjs\",[[4,\"salla-conditional-fields\",null,[[0,\"change\",\"changeHandler\"]]]]],[\"salla-notification-item.cjs\",[[0,\"salla-notification-item\",{\"notification\":[16]}]]],[\"salla-price-range.cjs\",[[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],\"reset\":[64]}]]],[\"salla-add-product-button_47.cjs\",[[4,\"salla-gifting\",{\"productId\":[2,\"product-id\"],\"widgetTitle\":[1,\"widget-title\"],\"widgetSubtitle\":[1,\"widget-subtitle\"],\"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],\"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],\"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-menu\",{\"source\":[1],\"sourceValue\":[1,\"source-value\"],\"topnav\":[4],\"useReactLink\":[4,\"use-react-link\"],\"menus\":[32],\"hasCustomComponent\":[32],\"setMenuContent\":[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]}],[4,\"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],\"withoutReload\":[4,\"without-reload\"],\"currentTabName\":[32],\"regType\":[32],\"translationLoaded\":[32],\"currentPhone\":[32],\"currentEmail\":[32],\"title\":[32],\"emailErrorMsg\":[32],\"firstNameErrorMsg\":[32],\"lastNameErrorMsg\":[32],\"hasError\":[32],\"errorMessage\":[32],\"dragAndDrop\":[32],\"browseFromFiles\":[32],\"customFields\":[32],\"uploadedImage\":[32],\"open\":[64]},[[8,\"verified\",\"onVerified\"]]],[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]}],[0,\"salla-rating-modal\",{\"orderId\":[2,\"order-id\"],\"order\":[32],\"hasError\":[32],\"errorMessage\":[32],\"translationLoaded\":[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-bottom-alert\",{\"type\":[513],\"icon\":[513],\"message\":[513],\"actionUrl\":[513,\"action-url\"],\"actionLabel\":[513,\"action-label\"],\"storeId\":[32],\"loading\":[32],\"templateData\":[32],\"defaultMessage\":[32],\"defaultActionLabel\":[32],\"storeFeatures\":[32],\"storeDetails\":[32],\"templateInformation\":[32],\"buyTheTemplate\":[32]}],[0,\"salla-comments\",{\"itemId\":[2,\"item-id\"],\"loadMoreText\":[1,\"load-more-text\"],\"hideForm\":[4,\"hide-form\"],\"type\":[1],\"comments\":[32],\"pagination\":[32],\"total\":[32],\"showPlaceholder\":[32],\"nextPage\":[32],\"noComments\":[32],\"comment_title\":[32],\"comment_name\":[32],\"placeholder_text\":[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-profile\",{\"customFields\":[1,\"custom-fields\"],\"userData\":[32],\"userDefinedFields\":[32],\"disableAction\":[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-user-settings\",{\"isNotifiable\":[516,\"is-notifiable\"],\"deactivateAccount\":[32],\"promotionalMsgs\":[32],\"deactivateDesc\":[32],\"promotionalMsgsDesc\":[32],\"sorryForLeavingText\":[32],\"warningText\":[32],\"keepAccount\":[32],\"buttonLoading\":[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\"]]],[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\",{\"items\":[1],\"breadcrumbs\":[32],\"currentPage\":[32],\"isRtl\":[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]}],[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],\"logout\":[32],\"hello\":[32],\"first_name\":[32],\"last_name\":[32],\"avatar\":[32],\"is_loggedIn\":[32],\"badges\":[32],\"hasBadges\":[32],\"OrderUpdate\":[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]}],[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]}],[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]}],[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-comment-item\",{\"comment\":[16],\"has_bought_trans\":[32],\"rated_trans\":[32],\"waiting_approval_trans\":[32],\"has_order_trans\":[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-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]}],[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-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],\"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],\"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],\"position\":[1],\"positionElement\":[16],\"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]}],[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]}],[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-file-upload\",{\"value\":[1537],\"files\":[513],\"height\":[513],\"cartItemId\":[1,\"cart-item-id\"],\"profileImage\":[516,\"profile-image\"],\"name\":[1537],\"payloadName\":[1,\"payload-name\"],\"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\"],\"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],\"instantUpload\":[1028,\"instant-upload\"],\"chunkUploads\":[4,\"chunk-uploads\"],\"chunkForce\":[4,\"chunk-force\"],\"chunkSize\":[2,\"chunk-size\"],\"chunkRetryDelays\":[16],\"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\"],\"setOption\":[64]}],[4,\"salla-list-tile\",{\"href\":[1],\"target\":[1]}],[0,\"salla-progress-bar\",{\"donation\":[1],\"target\":[1026],\"value\":[1026],\"height\":[1025],\"header\":[1025],\"stripped\":[1028],\"message\":[1025],\"unit\":[1025],\"color\":[1025]}],[0,\"salla-rating-stars\",{\"name\":[1],\"size\":[1],\"value\":[2],\"reviews\":[2]}],[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],\"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]}],[0,\"salla-skeleton\",{\"type\":[1],\"width\":[1],\"height\":[1]}],[4,\"salla-placeholder\",{\"icon\":[1],\"alignment\":[1],\"iconSize\":[1,\"icon-size\"],\"translationLoaded\":[32]}],[0,\"salla-tel-input\",{\"phone\":[1025],\"name\":[1],\"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\"]]],[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]}]]],[\"salla-filters-widget.cjs\",[[4,\"salla-filters-widget\",{\"withLoadMore\":[1028,\"with-load-more\"],\"filtersData\":[16],\"option\":[16],\"isOpen\":[32],\"isShowMore\":[32],\"showMoreLabel\":[32],\"showLessLabel\":[32],\"page\":[32],\"setWidgetHeight\":[64],\"reset\":[64],\"showMore\":[64],\"toggleWidget\":[64]}]]]]"), options);
26
+ return index.bootstrapLazy(JSON.parse("[[\"salla-products-slider.cjs\",[[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\"],\"productsData\":[32],\"isReady\":[32],\"sourceValueIsValid\":[32],\"hasCustomComponent\":[32],\"apiUrl\":[32],\"parsedSourceValue\":[32]}]]],[\"salla-product-options.cjs\",[[0,\"salla-product-options\",{\"productId\":[2,\"product-id\"],\"options\":[1],\"optionsData\":[32],\"outOfStockText\":[32],\"donationAmount\":[32],\"selectDonationAmount\":[32],\"selectAmount\":[32],\"isCustomDonation\":[32],\"selectedOptions\":[32],\"canDisabled\":[32],\"selectedSkus\":[32],\"selectedOutSkus\":[32],\"getSelectedOptionsData\":[64],\"reportValidity\":[64],\"hasOutOfStockOption\":[64],\"getSelectedOptions\":[64],\"getOption\":[64]}]]],[\"salla-filters.cjs\",[[0,\"salla-filters\",{\"filters\":[1040],\"isSidebarOpen\":[32],\"filtersData\":[32],\"apply\":[32],\"reset\":[32],\"getFilters\":[64],\"applyFilters\":[64],\"resetFilters\":[64]}]]],[\"salla-notifications.cjs\",[[0,\"salla-notifications\",{\"loadMoreText\":[1,\"load-more-text\"],\"itemPerPage\":[2,\"item-per-page\"],\"notifications\":[32],\"pagination\":[32],\"hasInfiniteScroll\":[32],\"total\":[32],\"showPlaceholder\":[32],\"nextPage\":[32],\"no_notifications_trans\":[32],\"load_more_text_trans\":[32]}]]],[\"salla-advertisement.cjs\",[[0,\"salla-advertisement\",{\"position\":[32],\"advertisements\":[32],\"advertIcon\":[32],\"currentSlug\":[32]}]]],[\"salla-apps-icons.cjs\",[[0,\"salla-apps-icons\",{\"hideTitle\":[4,\"hide-title\"],\"appsTitle\":[1,\"apps-title\"],\"vertical\":[4],\"apps\":[32]}]]],[\"salla-contacts.cjs\",[[0,\"salla-contacts\",{\"contactsTitle\":[1,\"contacts-title\"],\"hideTitle\":[4,\"hide-title\"],\"isHeader\":[4,\"is-header\"],\"horizontal\":[4],\"iconsOnly\":[4,\"icons-only\"],\"contacts\":[32],\"iconsList\":[32]}]]],[\"salla-installment.cjs\",[[0,\"salla-installment\",{\"price\":[1],\"language\":[1],\"currency\":[1],\"tamaraIsActive\":[32],\"tabbyIsActive\":[32],\"spotiiIsActive\":[32]}]]],[\"salla-loyalty-prize-item.cjs\",[[0,\"salla-loyalty-prize-item\",{\"item\":[16]}]]],[\"salla-payments.cjs\",[[0,\"salla-payments\",{\"withSbc\":[4,\"with-sbc\"],\"sbcId\":[1,\"sbc-id\"],\"withMadeInKsa\":[4,\"with-made-in-ksa\"],\"payments\":[32],\"placeholderImage\":[32]}]]],[\"salla-products-list.cjs\",[[0,\"salla-products-list\",{\"source\":[1537],\"sourceValue\":[1032,\"source-value\"],\"limit\":[1026],\"sortBy\":[1025,\"sort-by\"],\"filtersResults\":[1540,\"filters-results\"],\"horizontalCards\":[516,\"horizontal-cards\"],\"productCardComponent\":[1,\"product-card-component\"],\"page\":[32],\"nextPage\":[32],\"hasInfiniteScroll\":[32],\"hasCustomComponent\":[32],\"sourceValueIsValid\":[32],\"placeholderText\":[32],\"isReady\":[32],\"showPlaceholder\":[32],\"parsedFilters\":[32],\"setFilters\":[64],\"reload\":[64]}]]],[\"salla-social.cjs\",[[0,\"salla-social\",{\"links\":[32],\"iconsList\":[32]}]]],[\"salla-conditional-fields.cjs\",[[4,\"salla-conditional-fields\",null,[[0,\"change\",\"changeHandler\"]]]]],[\"salla-notification-item.cjs\",[[0,\"salla-notification-item\",{\"notification\":[16]}]]],[\"salla-price-range.cjs\",[[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],\"reset\":[64]}]]],[\"salla-add-product-button_47.cjs\",[[4,\"salla-gifting\",{\"productId\":[2,\"product-id\"],\"widgetTitle\":[1,\"widget-title\"],\"widgetSubtitle\":[1,\"widget-subtitle\"],\"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],\"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],\"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-menu\",{\"source\":[1],\"sourceValue\":[1,\"source-value\"],\"topnav\":[4],\"useReactLink\":[4,\"use-react-link\"],\"menus\":[32],\"hasCustomComponent\":[32],\"setMenuContent\":[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]}],[4,\"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],\"withoutReload\":[4,\"without-reload\"],\"currentTabName\":[32],\"regType\":[32],\"translationLoaded\":[32],\"currentPhone\":[32],\"currentEmail\":[32],\"title\":[32],\"emailErrorMsg\":[32],\"firstNameErrorMsg\":[32],\"lastNameErrorMsg\":[32],\"hasError\":[32],\"errorMessage\":[32],\"dragAndDrop\":[32],\"browseFromFiles\":[32],\"customFields\":[32],\"uploadedImage\":[32],\"open\":[64]},[[8,\"verified\",\"onVerified\"]]],[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]}],[0,\"salla-rating-modal\",{\"orderId\":[2,\"order-id\"],\"order\":[32],\"hasError\":[32],\"errorMessage\":[32],\"translationLoaded\":[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-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],\"templateInformation\":[32],\"buyTheTemplate\":[32]}],[0,\"salla-comments\",{\"itemId\":[2,\"item-id\"],\"loadMoreText\":[1,\"load-more-text\"],\"hideForm\":[4,\"hide-form\"],\"type\":[1],\"comments\":[32],\"pagination\":[32],\"total\":[32],\"showPlaceholder\":[32],\"nextPage\":[32],\"noComments\":[32],\"comment_title\":[32],\"comment_name\":[32],\"placeholder_text\":[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-profile\",{\"customFields\":[1,\"custom-fields\"],\"userData\":[32],\"userDefinedFields\":[32],\"disableAction\":[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-user-settings\",{\"isNotifiable\":[516,\"is-notifiable\"],\"deactivateAccount\":[32],\"promotionalMsgs\":[32],\"deactivateDesc\":[32],\"promotionalMsgsDesc\":[32],\"sorryForLeavingText\":[32],\"warningText\":[32],\"keepAccount\":[32],\"buttonLoading\":[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\"]]],[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\",{\"items\":[1],\"breadcrumbs\":[32],\"currentPage\":[32],\"isRtl\":[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]}],[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],\"logout\":[32],\"hello\":[32],\"first_name\":[32],\"last_name\":[32],\"avatar\":[32],\"is_loggedIn\":[32],\"badges\":[32],\"hasBadges\":[32],\"OrderUpdate\":[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]}],[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]}],[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]}],[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-comment-item\",{\"comment\":[16],\"has_bought_trans\":[32],\"rated_trans\":[32],\"waiting_approval_trans\":[32],\"has_order_trans\":[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-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]}],[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-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],\"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],\"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],\"position\":[1],\"positionElement\":[16],\"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]}],[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]}],[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-file-upload\",{\"value\":[1537],\"files\":[513],\"height\":[513],\"cartItemId\":[1,\"cart-item-id\"],\"profileImage\":[516,\"profile-image\"],\"name\":[1537],\"payloadName\":[1,\"payload-name\"],\"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\"],\"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],\"instantUpload\":[1028,\"instant-upload\"],\"chunkUploads\":[4,\"chunk-uploads\"],\"chunkForce\":[4,\"chunk-force\"],\"chunkSize\":[2,\"chunk-size\"],\"chunkRetryDelays\":[16],\"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\"],\"setOption\":[64]}],[4,\"salla-list-tile\",{\"href\":[1],\"target\":[1]}],[0,\"salla-progress-bar\",{\"donation\":[1],\"target\":[1026],\"value\":[1026],\"height\":[1025],\"header\":[1025],\"stripped\":[1028],\"message\":[1025],\"unit\":[1025],\"color\":[1025]}],[0,\"salla-rating-stars\",{\"name\":[1],\"size\":[1],\"value\":[2],\"reviews\":[2]}],[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],\"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]}],[0,\"salla-skeleton\",{\"type\":[1],\"width\":[1],\"height\":[1]}],[4,\"salla-placeholder\",{\"icon\":[1],\"alignment\":[1],\"iconSize\":[1,\"icon-size\"],\"translationLoaded\":[32]}],[0,\"salla-tel-input\",{\"phone\":[1025],\"name\":[1],\"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\"]]],[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]}]]],[\"salla-filters-widget.cjs\",[[4,\"salla-filters-widget\",{\"withLoadMore\":[1028,\"with-load-more\"],\"filtersData\":[16],\"option\":[16],\"isOpen\":[32],\"isShowMore\":[32],\"showMoreLabel\":[32],\"showLessLabel\":[32],\"page\":[32],\"setWidgetHeight\":[64],\"reset\":[64],\"showMore\":[64],\"toggleWidget\":[64]}]]]]"), options);
27
27
  });
28
28
 
29
29
  exports.setNonce = index.setNonce;
@@ -7,12 +7,14 @@ import shoppingBag from "../../assets/svg/shopping-bag2.svg";
7
7
  export class SallaBottomAlert {
8
8
  constructor() {
9
9
  this.storeId = salla.config.get('store.id');
10
+ this.template = salla.config.get('store.template');
10
11
  this.loading = false;
11
12
  this.templateData = {};
12
13
  this.defaultMessage = salla.lang.get('common.elements.experimental_and_available_store');
13
14
  this.defaultActionLabel = salla.lang.get('common.elements.know_more');
14
15
  this.storeFeatures = salla.lang.get('common.elements.store_features');
15
16
  this.storeDetails = salla.lang.get('common.elements.store_details');
17
+ this.storePrice = salla.lang.get('common.elements.store_price');
16
18
  this.templateInformation = salla.lang.get('common.elements.template_information');
17
19
  this.buyTheTemplate = salla.lang.get('common.elements.buy_the_template');
18
20
  this.type = 'popup';
@@ -27,6 +29,11 @@ export class SallaBottomAlert {
27
29
  this.storeDetails = salla.lang.get('common.elements.store_details');
28
30
  this.templateInformation = salla.lang.get('common.elements.template_information');
29
31
  this.buyTheTemplate = salla.lang.get('common.elements.buy_the_template');
32
+ salla.helpers.setNested(salla.lang.messages['ar.trans'], 'common.elements.store_price', 'سعر المتجر');
33
+ salla.helpers.setNested(salla.lang.messages['en.trans'], 'common.elements.store_price', 'Store Price');
34
+ setTimeout(() => {
35
+ this.storePrice = salla.lang.get('common.elements.store_price');
36
+ });
30
37
  });
31
38
  }
32
39
  open() {
@@ -57,9 +64,9 @@ export class SallaBottomAlert {
57
64
  }
58
65
  }
59
66
  popup() {
60
- var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r;
67
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s;
61
68
  return (h("salla-modal", { class: "s-bottom-alert-modal", ref: modal => this.modal = modal, "no-padding": true }, Object.keys(this.templateData).length ?
62
- [h("div", { class: "s-bottom-alert-modal-inner s-scrollbar" }, Array.isArray((_a = this.templateData) === null || _a === void 0 ? void 0 : _a.screenshots) && ((_c = (_b = this.templateData) === null || _b === void 0 ? void 0 : _b.screenshots) === null || _c === void 0 ? void 0 : _c.length) ? h("div", { class: "s-bottom-alert-modal-cover" }, h("img", { src: (_d = this.templateData) === null || _d === void 0 ? void 0 : _d.screenshots[0], alt: "" })) : '', h("div", { class: "s-bottom-alert-modal-content" }, ((_e = this.templateData) === null || _e === void 0 ? void 0 : _e.description) ?
69
+ [h("div", { class: "s-bottom-alert-modal-inner s-scrollbar" }, Array.isArray((_a = this.templateData) === null || _a === void 0 ? void 0 : _a.screenshots) && ((_c = (_b = this.templateData) === null || _b === void 0 ? void 0 : _b.screenshots) === null || _c === void 0 ? void 0 : _c.length) ? h("div", { class: "s-bottom-alert-modal-cover" }, h("img", { src: (_d = this.templateData) === null || _d === void 0 ? void 0 : _d.screenshots[0], alt: "" })) : '', h("div", { class: { "s-bottom-alert-modal-content": true, "s-bottom-alert-modal-content-extra-padding": this.templateData.price } }, ((_e = this.templateData) === null || _e === void 0 ? void 0 : _e.description) ?
63
70
  [h("div", { class: "s-bottom-alert-modal-content-title" }, this.storeDetails), h("div", { class: "s-bottom-alert-modal-content-description", innerHTML: (_f = this.templateData) === null || _f === void 0 ? void 0 : _f.description }), h("hr", null)
64
71
  ] : '', ((_g = this.templateData) === null || _g === void 0 ? void 0 : _g.features) ? [h("div", { class: "s-bottom-alert-modal-content-title" }, this.storeFeatures), h("div", { class: "s-bottom-alert-modal-content-features", innerHTML: (_h = this.templateData) === null || _h === void 0 ? void 0 : _h.features })
65
72
  ] : '', Array.isArray((_j = this.templateData) === null || _j === void 0 ? void 0 : _j.screenshots) && ((_l = (_k = this.templateData) === null || _k === void 0 ? void 0 : _k.screenshots) === null || _l === void 0 ? void 0 : _l.length) > 1 ?
@@ -68,11 +75,11 @@ export class SallaBottomAlert {
68
75
  })))
69
76
  : '', ((_o = this.templateData) === null || _o === void 0 ? void 0 : _o.extra_info) ?
70
77
  h("div", { class: "s-bottom-alert-modal-content-description", innerHTML: (_p = this.templateData) === null || _p === void 0 ? void 0 : _p.description })
71
- : '', ((_q = this.templateData) === null || _q === void 0 ? void 0 : _q.link) ?
72
- h("div", { class: "s-bottom-alert-modal-content-footer" }, h("salla-button", { color: 'primary', size: "medium", width: 'wide', href: (_r = this.templateData) === null || _r === void 0 ? void 0 : _r.link }, h("i", { innerHTML: shoppingBag }), this.buyTheTemplate)) : ''))] : ''));
78
+ : ''), ((_q = this.templateData) === null || _q === void 0 ? void 0 : _q.link) ?
79
+ h("div", { class: "s-bottom-alert-modal-content-footer" }, this.templateData.price && h("div", { class: "s-bottom-alert-modal-price-wrapper" }, h("div", null, this.storePrice), h("div", { class: "s-bottom-alert-modal-price-wrapper-amount" }, salla.money((_r = this.templateData) === null || _r === void 0 ? void 0 : _r.price))), h("salla-button", { color: 'primary', size: "medium", width: 'wide', href: (_s = this.templateData) === null || _s === void 0 ? void 0 : _s.link }, h("i", { innerHTML: shoppingBag }), this.buyTheTemplate)) : '')] : ''));
73
80
  }
74
81
  render() {
75
- return (h(Host, { class: "s-bottom-alert-wrapper" }, h("div", { class: "s-bottom-alert-content" }, h("div", { class: "s-bottom-alert-icon" }, this.icon ? h("i", { class: this.icon }) : h("i", { innerHTML: infoIcon })), h("div", { class: "s-bottom-alert-message" }, this.message ? this.message : this.defaultMessage), this.type !== 'banner' ? (h("div", { class: "s-bottom-alert-action" }, h("salla-button", { href: this.actionUrl, size: "medium", onClick: () => this.handleAction(), width: "normal" }, this.actionLabel ? this.actionLabel : this.defaultActionLabel))) : null, this.type === 'popup' ? this.popup() : null)));
82
+ return (h(Host, { class: "s-bottom-alert-wrapper" }, h("div", { class: "s-bottom-alert-content" }, h("div", { class: "s-bottom-alert-icon" }, this.icon ? h("i", { class: this.icon }) : h("i", { innerHTML: infoIcon })), h("div", { class: "s-bottom-alert-message" }, this.message ? (this.message) : typeof this.template == 'object' && Object.keys(this.template).length ? (h("span", null, this.defaultMessage.substring(0, this.defaultMessage.lastIndexOf(" ")), " ", h("span", { class: "s-bottom-alert-message-highlight" }, this.template.developer), " ", h("span", { class: "s-bottom-alert-message-splitter" }, "|"), " ", this.storePrice, ":", " ", h("span", { class: "s-bottom-alert-message-highlight" }, salla.money(this.template.price)))) : (this.defaultMessage)), this.type !== 'banner' ? (h("div", { class: "s-bottom-alert-action" }, h("salla-button", { href: this.actionUrl, size: "medium", onClick: () => this.handleAction(), width: "normal" }, this.actionLabel ? this.actionLabel : this.defaultActionLabel))) : null, this.type === 'popup' ? this.popup() : null)));
76
83
  }
77
84
  static get is() { return "salla-bottom-alert"; }
78
85
  static get originalStyleUrls() {
@@ -178,12 +185,14 @@ export class SallaBottomAlert {
178
185
  static get states() {
179
186
  return {
180
187
  "storeId": {},
188
+ "template": {},
181
189
  "loading": {},
182
190
  "templateData": {},
183
191
  "defaultMessage": {},
184
192
  "defaultActionLabel": {},
185
193
  "storeFeatures": {},
186
194
  "storeDetails": {},
195
+ "storePrice": {},
187
196
  "templateInformation": {},
188
197
  "buyTheTemplate": {}
189
198
  };
@@ -1 +1 @@
1
- {"version":3,"file":"salla-bottom-alert.js","sourceRoot":"","sources":["../../../src/components/salla-bottom-alert/salla-bottom-alert.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AACzE,OAAO,QAAQ,MAAM,2BAA2B,CAAC;AACjD,OAAO,WAAW,MAAM,oCAAoC,CAAC;AAK7D,MAAM,OAAO,gBAAgB;EAC3B;mBAc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YAAY,EAAE,EAClC,KAAK,EAAC,QAAQ,IAEb,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC,IAAI,CAAC,kBAAkB,CACjD,CACX,CACP,CAAC,CAAC,CAAC,IAAI;QAEN,IAAI,CAAC,IAAI,KAAK,OAAO,CAAC,CAAC,CAAC,IAAI,CAAC,KAAK,EAAE,CAAC,CAAC,CAAC,IAAI,CAEzC,CACD,CACR,CAAC;EACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAEF","sourcesContent":["import { Component, Host, h, Element, Prop, State } from '@stencil/core';\nimport infoIcon from '../../assets/svg/info.svg';\nimport shoppingBag from '../../assets/svg/shopping-bag2.svg';\n@Component({\n tag: 'salla-bottom-alert',\n styleUrl: 'salla-bottom-alert.scss',\n})\nexport class SallaBottomAlert {\n constructor() {\n salla.lang.onLoaded(() => {\n this.defaultMessage = salla.lang.get('common.elements.experimental_and_available_store');\n this.defaultActionLabel = salla.lang.get('common.elements.know_more');\n this.storeFeatures = salla.lang.get('common.elements.store_features');\n this.storeDetails = salla.lang.get('common.elements.store_details');\n this.templateInformation = salla.lang.get('common.elements.template_information');\n this.buyTheTemplate = salla.lang.get('common.elements.buy_the_template');\n });\n }\n\n private modal: HTMLSallaModalElement;\n @Element() host: HTMLElement;\n\n @State() storeId: string = salla.config.get('store.id')\n @State() loading: boolean = false\n @State() templateData: any = {}\n @State() defaultMessage: string = salla.lang.get('common.elements.experimental_and_available_store');\n @State() defaultActionLabel: string = salla.lang.get('common.elements.know_more');\n @State() storeFeatures: string = salla.lang.get('common.elements.store_features');\n @State() storeDetails: string = salla.lang.get('common.elements.store_details');\n @State() templateInformation: string = salla.lang.get('common.elements.template_information');\n @State() buyTheTemplate: string = salla.lang.get('common.elements.buy_the_template');\n /**\n * Alert Type\n * */\n @Prop({ reflect: true }) type: 'link' | 'popup' | 'banner' = 'popup';\n\n /**\n * Alert Icon class from salla icons library - ex: sicon-user\n * */\n @Prop({ reflect: true }) icon: string;\n\n /**\n * Alert Message\n * */\n @Prop({ reflect: true }) message: string;\n\n /**\n * Button url - used when type is link\n * */\n @Prop({ reflect: true }) actionUrl: string;\n\n /**\n * Button label - used when type is link and popup\n * */\n @Prop({ reflect: true }) actionLabel: string;\n\n private open() {\n return this.modal.open()\n .then(() => this.handleTemplateRequest())\n }\n\n private handleTemplateRequest() {\n if (Object.keys(this.templateData).length) {\n return;\n }\n this.modal.loading()\n return salla.api.request(`/store/template`, {}, 'get', { 'Store-Identifier': this.storeId })\n .then((res) => {\n this.modal.setTitle(this.templateInformation)\n this.templateData = res.data\n this.modal.stopLoading()\n })\n .catch(() => {\n this.modal.close()\n })\n }\n\n private handleAction() {\n if (this.type === 'link') {\n window.location.href = this.actionUrl;\n }\n\n if (this.type === 'popup') {\n this.open()\n }\n }\n\n popup() {\n return (\n <salla-modal class=\"s-bottom-alert-modal\" ref={modal => this.modal = modal} no-padding>\n {Object.keys(this.templateData).length ?\n [<div class=\"s-bottom-alert-modal-inner s-scrollbar\">\n {Array.isArray(this.templateData?.screenshots) && this.templateData?.screenshots?.length ? <div class=\"s-bottom-alert-modal-cover\">\n <img src={this.templateData?.screenshots[0]} alt=\"\" />\n </div> : ''}\n <div class=\"s-bottom-alert-modal-content\">\n {this.templateData?.description ?\n [<div class=\"s-bottom-alert-modal-content-title\">\n {this.storeDetails}\n </div>,\n <div class=\"s-bottom-alert-modal-content-description\" innerHTML={this.templateData?.description}></div>,\n <hr />\n ] : ''}\n {this.templateData?.features ? [<div class=\"s-bottom-alert-modal-content-title\">\n {this.storeFeatures}\n </div>,\n <div class=\"s-bottom-alert-modal-content-features\" innerHTML={this.templateData?.features}></div>\n ] : ''}\n {Array.isArray(this.templateData?.screenshots) && this.templateData?.screenshots?.length > 1 ?\n <salla-slider id='template-screenshots' type='carousel' class=\"s-bottom-alert-modal-content-screenshots\">\n <div slot='items'>\n {this.templateData?.screenshots.map((screenshot) => {\n return <div class=\"s-bottom-alert-modal-content-screenshot\">\n <img src={screenshot} alt=\"\" />\n </div>\n })}\n </div>\n </salla-slider>\n : ''}\n\n {this.templateData?.extra_info ?\n <div class=\"s-bottom-alert-modal-content-description\" innerHTML={this.templateData?.description}></div>\n : ''}\n\n {this.templateData?.link ?\n <div class=\"s-bottom-alert-modal-content-footer\">\n <salla-button\n color='primary'\n size=\"medium\"\n width='wide'\n href={this.templateData?.link}\n >\n <i innerHTML={shoppingBag}></i>\n {this.buyTheTemplate} \n </salla-button>\n </div> : ''\n }\n\n </div>\n </div>] : ''\n }\n\n </salla-modal>\n )\n }\n render() {\n return (\n <Host class=\"s-bottom-alert-wrapper\">\n <div class=\"s-bottom-alert-content\">\n <div class=\"s-bottom-alert-icon\">\n {this.icon ? <i class={this.icon}></i> : <i innerHTML={infoIcon}></i>}\n </div>\n <div class=\"s-bottom-alert-message\">\n {this.message ? this.message : this.defaultMessage}\n </div>\n {this.type !== 'banner' ? (\n <div class=\"s-bottom-alert-action\">\n <salla-button\n href={this.actionUrl}\n size=\"medium\"\n onClick={() => this.handleAction()}\n width=\"normal\"\n >\n {this.actionLabel ? this.actionLabel : this.defaultActionLabel}\n </salla-button>\n </div>\n ) : null}\n {\n this.type === 'popup' ? this.popup() : null\n }\n </div>\n </Host>\n );\n }\n\n}\n"]}
1
+ {"version":3,"file":"salla-bottom-alert.js","sourceRoot":"","sources":["../../../src/components/salla-bottom-alert/salla-bottom-alert.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AACzE,OAAO,QAAQ,MAAM,2BAA2B,CAAC;AACjD,OAAO,WAAW,MAAM,oCAAoC,CAAC;AAK7D,MAAM,OAAO,gBAAgB;EAC3B;mBAmB2B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B,WAAK,KAAK,EAAC,uBAAuB;UAChC,oBACE,IAAI,EAAE,IAAI,CAAC,SAAS,EACpB,IAAI,EAAC,QAAQ,EACb,OAAO,EAAE,GAAG,EAAE,CAAC,IAAI,CAAC,YAAY,EAAE,EAClC,KAAK,EAAC,QAAQ,IAEb,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC,IAAI,CAAC,kBAAkB,CACjD,CACX,CACP,CAAC,CAAC,CAAC,IAAI;QAEN,IAAI,CAAC,IAAI,KAAK,OAAO,CAAC,CAAC,CAAC,IAAI,CAAC,KAAK,EAAE,CAAC,CAAC,CAAC,IAAI,CAEzC,CACD,CACR,CAAC;EACJ,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAEF","sourcesContent":["import { Component, Host, h, Element, Prop, State } from '@stencil/core';\nimport infoIcon from '../../assets/svg/info.svg';\nimport shoppingBag from '../../assets/svg/shopping-bag2.svg';\n@Component({\n tag: 'salla-bottom-alert',\n styleUrl: 'salla-bottom-alert.scss',\n})\nexport class SallaBottomAlert {\n constructor() {\n salla.lang.onLoaded(() => {\n this.defaultMessage = salla.lang.get('common.elements.experimental_and_available_store');\n this.defaultActionLabel = salla.lang.get('common.elements.know_more');\n this.storeFeatures = salla.lang.get('common.elements.store_features');\n this.storeDetails = salla.lang.get('common.elements.store_details');\n this.templateInformation = salla.lang.get('common.elements.template_information');\n this.buyTheTemplate = salla.lang.get('common.elements.buy_the_template');\n salla.helpers.setNested(salla.lang.messages['ar.trans'], 'common.elements.store_price', 'سعر المتجر');\n salla.helpers.setNested(salla.lang.messages['en.trans'], 'common.elements.store_price', 'Store Price');\n setTimeout(() => {\n this.storePrice = salla.lang.get('common.elements.store_price');\n });\n });\n }\n\n private modal: HTMLSallaModalElement;\n @Element() host: HTMLElement;\n\n @State() storeId: string = salla.config.get('store.id')\n @State() template: any = salla.config.get('store.template')\n @State() loading: boolean = false\n @State() templateData: any = {}\n @State() defaultMessage: string = salla.lang.get('common.elements.experimental_and_available_store');\n @State() defaultActionLabel: string = salla.lang.get('common.elements.know_more');\n @State() storeFeatures: string = salla.lang.get('common.elements.store_features');\n @State() storeDetails: string = salla.lang.get('common.elements.store_details');\n @State() storePrice: string = salla.lang.get('common.elements.store_price');\n @State() templateInformation: string = salla.lang.get('common.elements.template_information');\n @State() buyTheTemplate: string = salla.lang.get('common.elements.buy_the_template');\n /**\n * Alert Type\n * */\n @Prop({ reflect: true }) type: 'link' | 'popup' | 'banner' = 'popup';\n\n /**\n * Alert Icon class from salla icons library - ex: sicon-user\n * */\n @Prop({ reflect: true }) icon: string;\n\n /**\n * Alert Message\n * */\n @Prop({ reflect: true }) message: string;\n\n /**\n * Button url - used when type is link\n * */\n @Prop({ reflect: true }) actionUrl: string;\n\n /**\n * Button label - used when type is link and popup\n * */\n @Prop({ reflect: true }) actionLabel: string;\n\n private open() {\n return this.modal.open()\n .then(() => this.handleTemplateRequest())\n }\n\n private handleTemplateRequest() {\n if (Object.keys(this.templateData).length) {\n return;\n }\n this.modal.loading()\n return salla.api.request(`/store/template`, {}, 'get', { 'Store-Identifier': this.storeId })\n .then((res) => {\n this.modal.setTitle(this.templateInformation)\n this.templateData = res.data\n this.modal.stopLoading()\n })\n .catch(() => {\n this.modal.close()\n })\n }\n\n private handleAction() {\n if (this.type === 'link') {\n window.location.href = this.actionUrl;\n }\n\n if (this.type === 'popup') {\n this.open()\n }\n }\n\n popup() {\n return (\n <salla-modal class=\"s-bottom-alert-modal\" ref={modal => this.modal = modal} no-padding>\n {Object.keys(this.templateData).length ?\n [<div class=\"s-bottom-alert-modal-inner s-scrollbar\">\n {Array.isArray(this.templateData?.screenshots) && this.templateData?.screenshots?.length ? <div class=\"s-bottom-alert-modal-cover\">\n <img src={this.templateData?.screenshots[0]} alt=\"\" />\n </div> : ''}\n <div class={{\"s-bottom-alert-modal-content\": true, \"s-bottom-alert-modal-content-extra-padding\":this.templateData.price}} >\n {this.templateData?.description ?\n [<div class=\"s-bottom-alert-modal-content-title\">\n {this.storeDetails}\n </div>,\n <div class=\"s-bottom-alert-modal-content-description\" innerHTML={this.templateData?.description}></div>,\n <hr />\n ] : ''}\n {this.templateData?.features ? [<div class=\"s-bottom-alert-modal-content-title\">\n {this.storeFeatures}\n </div>,\n <div class=\"s-bottom-alert-modal-content-features\" innerHTML={this.templateData?.features}></div>\n ] : ''}\n {Array.isArray(this.templateData?.screenshots) && this.templateData?.screenshots?.length > 1 ?\n <salla-slider id='template-screenshots' type='carousel' class=\"s-bottom-alert-modal-content-screenshots\">\n <div slot='items'>\n {this.templateData?.screenshots.map((screenshot) => {\n return <div class=\"s-bottom-alert-modal-content-screenshot\">\n <img src={screenshot} alt=\"\" />\n </div>\n })}\n </div>\n </salla-slider>\n : ''}\n\n {this.templateData?.extra_info ?\n <div class=\"s-bottom-alert-modal-content-description\" innerHTML={this.templateData?.description}></div>\n : ''}\n </div>\n {this.templateData?.link ?\n <div class=\"s-bottom-alert-modal-content-footer\">\n {this.templateData.price && <div class=\"s-bottom-alert-modal-price-wrapper\">\n <div>\n {this.storePrice}\n </div>\n <div class=\"s-bottom-alert-modal-price-wrapper-amount\">\n {salla.money(this.templateData?.price)}\n </div>\n </div>}\n <salla-button\n color='primary'\n size=\"medium\"\n width='wide'\n href={this.templateData?.link}\n >\n <i innerHTML={shoppingBag}></i>\n {this.buyTheTemplate}\n </salla-button>\n </div> : ''\n }\n </div>] : ''\n }\n\n </salla-modal>\n )\n }\n render() {\n return (\n <Host class=\"s-bottom-alert-wrapper\">\n <div class=\"s-bottom-alert-content\">\n <div class=\"s-bottom-alert-icon\">\n {this.icon ? <i class={this.icon}></i> : <i innerHTML={infoIcon}></i>}\n </div>\n <div class=\"s-bottom-alert-message\">\n {this.message ? ( this.message ) : typeof this.template == 'object' && Object.keys(this.template).length ? (\n <span>\n {this.defaultMessage.substring(0, this.defaultMessage.lastIndexOf(\" \"))}{\" \"}\n <span class=\"s-bottom-alert-message-highlight\">\n {this.template.developer}\n </span>{\" \"}\n <span class=\"s-bottom-alert-message-splitter\">|</span> {this.storePrice}:{\" \"}\n <span class=\"s-bottom-alert-message-highlight\">\n {salla.money(this.template.price)}\n </span>\n </span>\n ) : (\n this.defaultMessage\n )}\n </div>\n {this.type !== 'banner' ? (\n <div class=\"s-bottom-alert-action\">\n <salla-button\n href={this.actionUrl}\n size=\"medium\"\n onClick={() => this.handleAction()}\n width=\"normal\"\n >\n {this.actionLabel ? this.actionLabel : this.defaultActionLabel}\n </salla-button>\n </div>\n ) : null}\n {\n this.type === 'popup' ? this.popup() : null\n }\n </div>\n </Host>\n );\n }\n\n}\n"]}
@@ -39,6 +39,8 @@ export class SallaContacts {
39
39
  return `tel:${this.contacts[type]}`;
40
40
  case 'mobile':
41
41
  return `tel:${this.contacts[type]}`;
42
+ case 'whatsapp':
43
+ return salla.url.get('whatsapp/send');
42
44
  case 'email':
43
45
  return `mailto:${this.contacts[type]}`;
44
46
  case 'telegram':
@@ -1 +1 @@
1
- {"version":3,"file":"salla-contacts.js","sourceRoot":"","sources":["../../../src/components/salla-contacts/salla-contacts.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,EAAE,IAAI,EAAE,KAAK,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;AACzE,OAAO,MAAM,MAAM,6BAA6B,CAAC;AACjD,OAAO,QAAQ,MAAM,gCAAgC,CAAC;AACtD,OAAO,KAAK,MAAM,4BAA4B,CAAC;AAC/C,OAAO,QAAQ,MAAM,oCAAoC,CAAC;AAC1D,OAAO,KAAK,MAAM,2BAA2B,CAAC;AAC9C;;GAEG;AAKH,MAAM,OAAO,aAAa;EACxB;;;;;;;oBAkByB,KAAK,CAAC,MAAM,CAAC,GAAG,CAAC,gBAAgB,CAAC;qBACjC,EAAE,MAAM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AAI;UACvB,4BAA4B,EAAE,IAAI,CAAC,UAAU;UAC7C,0BAA0B,EAAE,CAAC,IAAI,CAAC,UAAU;UAC5C,4BAA4B,EAAE,IAAI,CAAC,SAAS;SAC7C,IAEE,aAAa,CAAC,GAAG,CAAC,CAAC,OAAO,EAAE,KAAK,EAAE,EAAE,CAAC,CACrC,WAAK,GAAG,EAAE,KAAK,EAAE,EAAE,EAAC,cAAc,EAAC,SAAS,EAAE,IAAI,CAAC,WAAW;WAC3D,OAAO,CAAC,WAAW,EAAE,IAAI,CAAC,cAAc,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;WACvD,OAAO,CAAC,YAAY,EAAE,OAAO,CAAC,KAAK,CAAC,QAAQ,EAAE,CAAC;WAC/C,OAAO,CAAC,WAAW,EAAE,IAAI,CAAC,cAAc,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC,GACpD,CACP,CAAC,CACE,CACD,CACR,CAAC;EACJ,CAAC;EACD,kBAAkB;;IAChB,4FAA4F;IAC5F,MAAA,IAAI,CAAC,IAAI,CAAC,aAAa,CAAC,kBAAkB,CAAC,0CAAE,MAAM,EAAE,CAAC;EACxD,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, Host, h, Prop, State, Element } from '@stencil/core';\nimport mobile from '../../assets/svg/iphone.svg';\nimport whatsapp from '../../assets/svg/whatsapp2.svg';\nimport phone from '../../assets/svg/phone.svg';\nimport telegram from '../../assets/svg/paper-plane-o.svg';\nimport email from '../../assets/svg/mail.svg';\n/**\n * @slot contact - Replaces contact item, has replaceable props `{icon}`, `{value}`.\n */\n@Component({\n tag: 'salla-contacts',\n styleUrl: 'salla-contacts.scss',\n})\nexport class SallaContacts {\n constructor() {\n this.contactSlot = this.host.querySelector('[slot=\"contact\"]')?.innerHTML || `<a href={link} class=\"s-contacts-item\"><span class=\"s-contacts-icon\">{icon}</span>${!this.iconsOnly && \"<span class='unicode'>{value}</span>\"}</a>`;\n\n salla.onReady(() => {\n this.contacts = salla.config.get('store.contacts');\n });\n\n salla.lang.onLoaded(() => {\n this.contactsTitle = salla.lang.get('blocks.footer.social');\n });\n }\n private readonly contactSlot: string;\n @Prop() contactsTitle: string;\n @Prop() hideTitle: boolean;\n @Prop() isHeader: boolean;\n @Prop() horizontal: boolean;\n @Prop() iconsOnly: boolean;\n @Element() host: HTMLElement;\n @State() contacts: any = salla.config.get('store.contacts');\n @State() iconsList: any = { mobile, whatsapp, phone, telegram, email }\n\n private getContactsArray() {\n return Object.entries(this.contacts)\n .filter(([_key, value]) => value !== '')\n .map(([type, value]) => ({ type, value }));\n }\n\n private getContactLink(type) {\n switch (type) {\n case 'phone':\n return `tel:${this.contacts[type]}`; \n case 'mobile':\n return `tel:${this.contacts[type]}`;\n case 'email':\n return `mailto:${this.contacts[type]}`;\n case 'telegram':\n return `https://t.me/${this.contacts[type]}`;\n default:\n return this.contacts[type];\n }\n }\n\n private getContactIcon(type) {\n return this.iconsList[type];\n }\n render() {\n const contactsArray = this.getContactsArray();\n if (this.isHeader && contactsArray && contactsArray.length > 0) {\n return (\n <Host class=\"s-contacts s-contacts-header\">\n {contactsArray.filter((contact) => contact.type == 'phone' || contact.type == 'email').map((contact, index) => (\n <a href={this.getContactLink(contact.type)} key={index} class=\"s-contacts-topnav-link\">\n {contact.type === 'email' ? (\n contact.value\n ) : (\n [\n <span>{this.contactsTitle}: </span>,\n <a class=\"unicode\" href={this.iconsList[contact.type]}>{contact.value}</a>\n ]\n )}\n </a>\n ))}\n </Host>\n );\n }\n return (\n <Host class=\"s-contacts\">\n {!this.hideTitle && <h3 class=\"s-contacts-title\">{this.contactsTitle}</h3>}\n <div class={{\n 's-contacts-list': true,\n 's-contacts-list-horizontal': this.horizontal,\n 's-contacts-list-vertical': !this.horizontal,\n 's-contacts-list-icons-only': this.iconsOnly\n }\n }>\n {contactsArray.map((contact, index) => (\n <div key={index} id=\"contact-slot\" innerHTML={this.contactSlot\n .replace(/\\{icon\\}/g, this.getContactIcon(contact.type))\n .replace(/\\{value\\}/g, contact.value.toString())\n .replace(/\\{link\\}/g, this.getContactLink(contact.type))}>\n </div>\n ))}\n </div>\n </Host>\n );\n }\n componentDidRender() {\n // this.host.querySelectorAll('#contact-slot').forEach(el => el.replaceWith(el.firstChild));\n this.host.querySelector('[slot=\"contact\"]')?.remove();\n }\n}\n\n"]}
1
+ {"version":3,"file":"salla-contacts.js","sourceRoot":"","sources":["../../../src/components/salla-contacts/salla-contacts.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,EAAE,IAAI,EAAE,KAAK,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;AACzE,OAAO,MAAM,MAAM,6BAA6B,CAAC;AACjD,OAAO,QAAQ,MAAM,gCAAgC,CAAC;AACtD,OAAO,KAAK,MAAM,4BAA4B,CAAC;AAC/C,OAAO,QAAQ,MAAM,oCAAoC,CAAC;AAC1D,OAAO,KAAK,MAAM,2BAA2B,CAAC;AAC9C;;GAEG;AAKH,MAAM,OAAO,aAAa;EACxB;;;;;;;oBAkByB,KAAK,CAAC,MAAM,CAAC,GAAG,CAAC,gBAAgB,CAAC;qBACjC,EAAE,MAAM,EAAE,QAAQ,EAAE,KAAK,EAAE,QAAQ,EAAE,KAAK,EAAE;IAlBpE,IAAI,CAAC,WAAW,GAAG,CAAA,MAAA,IAAI,CAAC,IAAI,CAAC,aAAa,CAAC,kBAAkB,CAAC,0CAAE,SAAS,KAAI,qFAAqF,CAAC,IAAI,CAAC,SAAS,IAAI,sCAAsC,MAAM,CAAC;IAElO,KAAK,CAAC,OAAO,CAAC,GAAG,EAAE;MACjB,IAAI,CAAC,QAAQ,GAAG,KAAK,CAAC,MAAM,CAAC,GAAG,CAAC,gBAAgB,CAAC,CAAC;IACrD,CAAC,CAAC,CAAC;IAEH,KAAK,CA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,WAAW,EAAE,IAAI,CAAC,cAAc,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC;WACvD,OAAO,CAAC,YAAY,EAAE,OAAO,CAAC,KAAK,CAAC,QAAQ,EAAE,CAAC;WAC/C,OAAO,CAAC,WAAW,EAAE,IAAI,CAAC,cAAc,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC,GACpD,CACP,CAAC,CACE,CACD,CACR,CAAC;EACJ,CAAC;EACD,kBAAkB;;IAChB,4FAA4F;IAC5F,MAAA,IAAI,CAAC,IAAI,CAAC,aAAa,CAAC,kBAAkB,CAAC,0CAAE,MAAM,EAAE,CAAC;EACxD,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, Host, h, Prop, State, Element } from '@stencil/core';\nimport mobile from '../../assets/svg/iphone.svg';\nimport whatsapp from '../../assets/svg/whatsapp2.svg';\nimport phone from '../../assets/svg/phone.svg';\nimport telegram from '../../assets/svg/paper-plane-o.svg';\nimport email from '../../assets/svg/mail.svg';\n/**\n * @slot contact - Replaces contact item, has replaceable props `{icon}`, `{value}`.\n */\n@Component({\n tag: 'salla-contacts',\n styleUrl: 'salla-contacts.scss',\n})\nexport class SallaContacts {\n constructor() {\n this.contactSlot = this.host.querySelector('[slot=\"contact\"]')?.innerHTML || `<a href={link} class=\"s-contacts-item\"><span class=\"s-contacts-icon\">{icon}</span>${!this.iconsOnly && \"<span class='unicode'>{value}</span>\"}</a>`;\n\n salla.onReady(() => {\n this.contacts = salla.config.get('store.contacts');\n });\n\n salla.lang.onLoaded(() => {\n this.contactsTitle = salla.lang.get('blocks.footer.social');\n });\n }\n private readonly contactSlot: string;\n @Prop() contactsTitle: string;\n @Prop() hideTitle: boolean;\n @Prop() isHeader: boolean;\n @Prop() horizontal: boolean;\n @Prop() iconsOnly: boolean;\n @Element() host: HTMLElement;\n @State() contacts: any = salla.config.get('store.contacts');\n @State() iconsList: any = { mobile, whatsapp, phone, telegram, email }\n\n private getContactsArray() {\n return Object.entries(this.contacts)\n .filter(([_key, value]) => value !== '')\n .map(([type, value]) => ({ type, value }));\n }\n\n private getContactLink(type) {\n switch (type) {\n case 'phone':\n return `tel:${this.contacts[type]}`; \n case 'mobile':\n return `tel:${this.contacts[type]}`;\n case 'whatsapp':\n return salla.url.get('whatsapp/send');\n case 'email':\n return `mailto:${this.contacts[type]}`;\n case 'telegram':\n return `https://t.me/${this.contacts[type]}`;\n default:\n return this.contacts[type];\n }\n }\n\n private getContactIcon(type) {\n return this.iconsList[type];\n }\n render() {\n const contactsArray = this.getContactsArray();\n if (this.isHeader && contactsArray && contactsArray.length > 0) {\n return (\n <Host class=\"s-contacts s-contacts-header\">\n {contactsArray.filter((contact) => contact.type == 'phone' || contact.type == 'email').map((contact, index) => (\n <a href={this.getContactLink(contact.type)} key={index} class=\"s-contacts-topnav-link\">\n {contact.type === 'email' ? (\n contact.value\n ) : (\n [\n <span>{this.contactsTitle}: </span>,\n <a class=\"unicode\" href={this.iconsList[contact.type]}>{contact.value}</a>\n ]\n )}\n </a>\n ))}\n </Host>\n );\n }\n return (\n <Host class=\"s-contacts\">\n {!this.hideTitle && <h3 class=\"s-contacts-title\">{this.contactsTitle}</h3>}\n <div class={{\n 's-contacts-list': true,\n 's-contacts-list-horizontal': this.horizontal,\n 's-contacts-list-vertical': !this.horizontal,\n 's-contacts-list-icons-only': this.iconsOnly\n }\n }>\n {contactsArray.map((contact, index) => (\n <div key={index} id=\"contact-slot\" innerHTML={this.contactSlot\n .replace(/\\{icon\\}/g, this.getContactIcon(contact.type))\n .replace(/\\{value\\}/g, contact.value.toString())\n .replace(/\\{link\\}/g, this.getContactLink(contact.type))}>\n </div>\n ))}\n </div>\n </Host>\n );\n }\n componentDidRender() {\n // this.host.querySelectorAll('#contact-slot').forEach(el => el.replaceWith(el.firstChild));\n this.host.querySelector('[slot=\"contact\"]')?.remove();\n }\n}\n\n"]}