@salla.sa/twilight-components 1.4.12 → 1.4.17
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.
- package/README.md +2 -2
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/salla-button_24.cjs.entry.js +18 -15
- package/dist/cjs/twilight-components.cjs.js +1 -1
- package/dist/collection/components/salla-localization-modal/salla-localization-modal.js +1 -1
- package/dist/collection/components/salla-loyalty/salla-loyalty.js +37 -16
- package/dist/collection/components/salla-modal/salla-modal.js +25 -2
- package/dist/collection/components/salla-offer-modal/salla-offer-modal.js +1 -1
- package/dist/collection/components/salla-placeholder/salla-placeholder.js +2 -2
- package/dist/collection/components/salla-rating-modal/salla-rating-modal.js +2 -2
- package/dist/collection/components/salla-scopes/salla-scopes.js +2 -2
- package/dist/collection/components/salla-social-share/salla-social-share.js +1 -1
- package/dist/collection/components/salla-tel-input/salla-tel-input.js +1 -1
- package/dist/collection/global/app.js +1 -1
- package/dist/components/salla-localization-modal.js +1 -1
- package/dist/components/salla-loyalty.js +19 -14
- package/dist/components/salla-modal2.js +7 -2
- package/dist/components/salla-offer-modal.js +1 -1
- package/dist/components/salla-placeholder2.js +2 -2
- package/dist/components/salla-rating-modal.js +2 -2
- package/dist/components/salla-scopes.js +2 -2
- package/dist/components/salla-skeleton.js +1 -48
- package/dist/components/salla-skeleton2.js +53 -0
- package/dist/components/salla-social-share.js +1 -1
- package/dist/components/salla-tel-input2.js +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/esm/salla-button_24.entry.js +18 -15
- package/dist/esm/twilight-components.js +1 -1
- package/dist/twilight-components/p-7e9d843b.entry.js +4 -0
- package/dist/twilight-components/twilight-components.esm.js +1 -1
- package/dist/types/components/salla-modal/salla-modal.d.ts +4 -0
- package/dist/types/components.d.ts +8 -0
- package/example/assets/tailwind.css +81 -0
- package/package.json +1 -1
- package/dist/twilight-components/p-d0415349.entry.js +0 -4
|
@@ -24,6 +24,10 @@ const SallaModal = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
|
|
|
24
24
|
* open the modal on rendering
|
|
25
25
|
*/
|
|
26
26
|
this.visible = false;
|
|
27
|
+
/**
|
|
28
|
+
* open the modal on rendering
|
|
29
|
+
*/
|
|
30
|
+
this.hasSkeleton = false;
|
|
27
31
|
/**
|
|
28
32
|
* Show loading in the middle
|
|
29
33
|
*/
|
|
@@ -125,13 +129,13 @@ const SallaModal = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
|
|
|
125
129
|
};
|
|
126
130
|
}
|
|
127
131
|
getWidth() {
|
|
128
|
-
return this.isLoading ? 'sm' : this.width;
|
|
132
|
+
return this.isLoading ? this.hasSkeleton ? 'md' : 'sm' : this.width;
|
|
129
133
|
}
|
|
130
134
|
//todo:: pref for each modal
|
|
131
135
|
render() {
|
|
132
136
|
this.host.id = this.host.id || 'salla-modal';
|
|
133
137
|
if (this.isLoading) {
|
|
134
|
-
return (h(Host, { class: 'salla-modal s-modal s-modal-container s-hidden', "aria-modal": "true", role: "dialog" }, h("div", { class: "s-modal-overlay", ref: el => this.overlay = el, onClick: () => this.closeModal() }), h("div", { class: "s-modal-wrapper" }, h("span", { class: 's-modal-spacer s-modal-align-' + this.position }, "\u200B"), h("div", { class: 's-modal-body ' + 's-modal-align-' + this.position + ' s-modal-' + this.getWidth() + (this.noPadding ? ' s-modal-nopadding' : ' s-modal-padding') }, h("salla-loading", null), h("div", { class: "s-hidden" }, h("slot", null))))));
|
|
138
|
+
return (h(Host, { class: 'salla-modal s-modal s-modal-container s-hidden', "aria-modal": "true", role: "dialog" }, h("div", { class: "s-modal-overlay", ref: el => this.overlay = el, onClick: () => this.closeModal() }), h("div", { class: "s-modal-wrapper" }, h("span", { class: 's-modal-spacer s-modal-align-' + this.position }, "\u200B"), h("div", { class: 's-modal-body ' + 's-modal-align-' + this.position + ' s-modal-' + this.getWidth() + (this.noPadding ? ' s-modal-nopadding' : ' s-modal-padding') }, h("slot", { name: "loading" }, h("salla-loading", null)), h("div", { class: "s-hidden" }, h("slot", null))))));
|
|
135
139
|
}
|
|
136
140
|
return (h(Host, { class: 'salla-modal s-modal s-modal-container s-hidden', "aria-modal": "true", role: "dialog" }, h("div", { class: "s-modal-overlay", ref: el => this.overlay = el, onClick: () => this.closeModal() }), h("div", { class: "s-modal-wrapper" }, h("span", { class: 's-modal-spacer s-modal-align-' + this.position }, "\u200B"), h("div", { class: 's-modal-body ' + 's-modal-align-' + this.position + ' s-modal-' + this.getWidth() + (this.noPadding ? ' s-modal-nopadding' : ' s-modal-padding') }, h("div", { class: { 's-modal-header': true, 's-modal-is-center': this.icon != '' || this.imageIcon != '' } }, this.isClosable ?
|
|
137
141
|
h("button", { class: "s-modal-close", onClick: () => this.closeModal(), type: "button" }, h("span", { class: "sicon-cancel" }))
|
|
@@ -155,6 +159,7 @@ const SallaModal = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
|
|
|
155
159
|
"width": [513],
|
|
156
160
|
"position": [513],
|
|
157
161
|
"visible": [516],
|
|
162
|
+
"hasSkeleton": [516, "has-skeleton"],
|
|
158
163
|
"isLoading": [1540, "is-loading"],
|
|
159
164
|
"subTitleFirst": [4, "sub-title-first"],
|
|
160
165
|
"noPadding": [4, "no-padding"],
|
|
@@ -76,7 +76,7 @@ const SallaOfferModal$1 = /*@__PURE__*/ proxyCustomElement(class extends HTMLEle
|
|
|
76
76
|
}
|
|
77
77
|
render() {
|
|
78
78
|
var _a, _b;
|
|
79
|
-
return h("salla-modal", {
|
|
79
|
+
return h("salla-modal", { "sub-title-first": true, icon: "sicon-special-discount", "sub-title": this.offer_message, ref: modal => this.modal = modal, "is-loading": this.offer === null }, this.offer !== null
|
|
80
80
|
? [h("div", { class: "s-offer-modal-scrolled-slider-wrap" }, h("div", { class: "s-offer-modal-body s-offer-modal-scrolled-slider" }, ((_a = this.offer.get.categories) === null || _a === void 0 ? void 0 : _a.length) > 0
|
|
81
81
|
? this.offer.get.categories.map(category => h("a", { href: category.urls.customer, class: "s-offer-modal-badge s-offer-modal-slider-item", innerHTML: this.categorySlot
|
|
82
82
|
.replace(/\{name\}/g, category.name)
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* Crafted with ❤ by Salla
|
|
3
3
|
*/
|
|
4
|
-
import { proxyCustomElement, HTMLElement, h } from '@stencil/core/internal/client';
|
|
4
|
+
import { proxyCustomElement, HTMLElement, h, Host } from '@stencil/core/internal/client';
|
|
5
5
|
|
|
6
6
|
const Inbox = `<!-- Generated by IcoMoon.io -->
|
|
7
7
|
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" width="32" height="32" viewBox="0 0 32 32">
|
|
@@ -42,7 +42,7 @@ const SallaPlaceholder = /*@__PURE__*/ proxyCustomElement(class extends HTMLElem
|
|
|
42
42
|
};
|
|
43
43
|
}
|
|
44
44
|
render() {
|
|
45
|
-
return (h(
|
|
45
|
+
return (h(Host, { class: this.alignmentClass() }, h("div", { class: `s-placeholder-icon s-placeholder-icon-${this.iconSize}`, innerHTML: this.icon }), h("div", { class: "s-placeholder-title" }, h("slot", { name: 'title' }, h("span", null, this.default_title))), h("div", { class: "s-placeholder-description" }, h("slot", { name: 'description' }, h("span", null, this.default_description)))));
|
|
46
46
|
}
|
|
47
47
|
static get style() { return sallaPlaceholderCss; }
|
|
48
48
|
}, [4, "salla-placeholder", {
|
|
@@ -156,9 +156,9 @@ const SallaRatingModal$1 = /*@__PURE__*/ proxyCustomElement(class extends HTMLEl
|
|
|
156
156
|
this.showActiveStep(this.thanksTab);
|
|
157
157
|
}
|
|
158
158
|
render() {
|
|
159
|
-
return (h(Host, {
|
|
159
|
+
return (h(Host, { class: "s-rating" }, h("salla-modal", { isLoading: true, width: "md", ref: modal => this.modal = modal }, this.order
|
|
160
160
|
? [h("div", { class: "s-rating-modal-wrapper", ref: el => this.body = el }, this.order.testimonials_enabled ?
|
|
161
|
-
h("div", { class: "rating-outer-form s-rating-modal-step-wrap s-rating-modal-step s-rating-modal-hidden", "data-type": "store" }, h("div", { class: "s-rating-modal-rounded-icon" }, h("img", { src: salla.config.get('store.logo', 'https://assets.salla.sa/cp/assets/images/logo-new.png'), alt: "store name", class: "s-rating-modal-store-logo" })), h("h2", { class: "s-rating-modal-title" }, this.rate_the_store), h("div", { class: "s-rating-modal-stars-company" }, h("salla-rating-stars", { size: "large" })), h("textarea", {
|
|
161
|
+
h("div", { class: "rating-outer-form s-rating-modal-step-wrap s-rating-modal-step s-rating-modal-hidden", "data-type": "store" }, h("div", { class: "s-rating-modal-rounded-icon" }, h("img", { src: salla.config.get('store.logo', 'https://assets.salla.sa/cp/assets/images/logo-new.png'), alt: "store name", class: "s-rating-modal-store-logo" })), h("h2", { class: "s-rating-modal-title" }, this.rate_the_store), h("div", { class: "s-rating-modal-stars-company" }, h("salla-rating-stars", { size: "large" })), h("textarea", { name: "comment", class: "s-rating-modal-comment", placeholder: this.write_store_rate }), h("small", { class: "s-rating-modal-validation-msg" }))
|
|
162
162
|
: '', this.order.products_enabled
|
|
163
163
|
? h("section", { class: "s-rating-modal-step s-rating-modal-hidden", "data-type": "products" }, this.order.products.map((item, index) => h("div", { class: "rating-outer-form s-rating-modal-product", "data-stars-error": this.rate_product_stars }, h("div", { class: "s-rating-modal-product-img-wrap" }, h("img", { src: item.product.thumbnail, alt: item.product.name, class: "s-rating-modal-product-img" })), h("div", { class: "s-rating-modal-product-details" }, h("h3", { class: "s-rating-modal-product-title" }, " ", item.product.name), h("div", { class: "s-rating-modal-stars-product" }, h("salla-rating-stars", { size: "small", name: `products[${index}][rating]` })), h("input", { type: "hidden", name: `products[${index}][product_id]`, value: item.product.id }), h("textarea", { placeholder: this.write_product_rate, name: `products[${index}][comment]`, class: "s-rating-modal-comment" }), h("small", { class: "s-rating-modal-validation-msg" })))))
|
|
164
164
|
: '', this.order.shipping_enabled
|
|
@@ -100,7 +100,7 @@ const SallaScopees = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement
|
|
|
100
100
|
return await salla.scope.change(payload)
|
|
101
101
|
.then(() => {
|
|
102
102
|
salla.storage.set("branch-choosed-before", true);
|
|
103
|
-
|
|
103
|
+
salla.storage.set("scope", this.current_scope.id);
|
|
104
104
|
}).catch(e => console.log(e))
|
|
105
105
|
.finally(() => {
|
|
106
106
|
this.changeBtn.stop();
|
|
@@ -146,7 +146,7 @@ const SallaScopees = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement
|
|
|
146
146
|
return h("div", { class: "s-scopes-footer" }, h("slot", { name: "footer" }, h("salla-button", { ref: btn => this.changeBtn = btn, disabled: !this.current_scope, onClick: () => this.handleSubmit(), class: "s-scopes-submit", "loader-position": "center", width: "wide" }, this.confirmButton)));
|
|
147
147
|
}
|
|
148
148
|
render() {
|
|
149
|
-
return (h(Host, null, h("salla-modal", { ref: modal => this.modal = modal,
|
|
149
|
+
return (h(Host, null, h("salla-modal", { ref: modal => this.modal = modal, isClosable: !!(this.isOpenedBefore || (this.selection == 'optional')), class: "s-scopes-modal", isLoading: true }, h("salla-list-tile", { class: this.originalScopesList.length ? "s-scopes-header block" : "s-hidden" }, h("div", { slot: "icon", class: "s-scopes-header-icon", innerHTML: StoreAlt }), h("div", { slot: "title", class: "s-scopes-header-title" }, this.nowBrowsingFrom), h("div", { slot: "subtitle", class: "s-scopes-header-subtitle" }, !!this.selected_scope ? this.selected_scope.name : "")), h("div", { class: "s-scopes-wrap" }, !!this.originalScopesList.length && h("h4", { class: "s-scopes-title" }, this.getFormTitle()), this.originalScopesList.length > this.searchDisplayLimit ?
|
|
150
150
|
h("div", { class: "s-scopes-search-wrapper" }, h("div", { class: "s-scopes-search-icon", innerHTML: Search }), h("input", { type: "text", class: "s-scopes-search-input", onInput: e => this.handleSearchFieldTyping(e), placeholder: this.scopeSearchPlaceholder }))
|
|
151
151
|
: "", this.scopes.length < 2 ?
|
|
152
152
|
this.placeholderContent()
|
|
@@ -1,54 +1,7 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* Crafted with ❤ by Salla
|
|
3
3
|
*/
|
|
4
|
-
import {
|
|
5
|
-
|
|
6
|
-
const sallaSkeletonCss = ":host{display:block}";
|
|
7
|
-
|
|
8
|
-
const SallaSkeleton$1 = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
|
|
9
|
-
constructor() {
|
|
10
|
-
super();
|
|
11
|
-
this.__registerHost();
|
|
12
|
-
/**
|
|
13
|
-
* Set the shape type of the skeleton is it circle or normal
|
|
14
|
-
*/
|
|
15
|
-
this.type = 'normal';
|
|
16
|
-
/**
|
|
17
|
-
* Set the skeleton width
|
|
18
|
-
*/
|
|
19
|
-
this.width = '100%';
|
|
20
|
-
/**
|
|
21
|
-
* Set the skeleton height
|
|
22
|
-
*/
|
|
23
|
-
this.height = '100%';
|
|
24
|
-
}
|
|
25
|
-
render() {
|
|
26
|
-
const classes = {
|
|
27
|
-
's-skeleton-item': true,
|
|
28
|
-
's-skeleton-item-circular': this.type == 'circle',
|
|
29
|
-
};
|
|
30
|
-
return (h("div", { class: "s-skeleton-wrapper", style: { width: this.width, height: this.height } }, h("div", { class: classes }, "\u00A0")));
|
|
31
|
-
}
|
|
32
|
-
static get style() { return sallaSkeletonCss; }
|
|
33
|
-
}, [0, "salla-skeleton", {
|
|
34
|
-
"type": [1],
|
|
35
|
-
"width": [1],
|
|
36
|
-
"height": [1]
|
|
37
|
-
}]);
|
|
38
|
-
function defineCustomElement$1() {
|
|
39
|
-
if (typeof customElements === "undefined") {
|
|
40
|
-
return;
|
|
41
|
-
}
|
|
42
|
-
const components = ["salla-skeleton"];
|
|
43
|
-
components.forEach(tagName => { switch (tagName) {
|
|
44
|
-
case "salla-skeleton":
|
|
45
|
-
if (!customElements.get(tagName)) {
|
|
46
|
-
customElements.define(tagName, SallaSkeleton$1);
|
|
47
|
-
}
|
|
48
|
-
break;
|
|
49
|
-
} });
|
|
50
|
-
}
|
|
51
|
-
defineCustomElement$1();
|
|
4
|
+
import { S as SallaSkeleton$1, d as defineCustomElement$1 } from './salla-skeleton2.js';
|
|
52
5
|
|
|
53
6
|
const SallaSkeleton = SallaSkeleton$1;
|
|
54
7
|
const defineCustomElement = defineCustomElement$1;
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* Crafted with ❤ by Salla
|
|
3
|
+
*/
|
|
4
|
+
import { proxyCustomElement, HTMLElement, h } from '@stencil/core/internal/client';
|
|
5
|
+
|
|
6
|
+
const sallaSkeletonCss = ":host{display:block}";
|
|
7
|
+
|
|
8
|
+
const SallaSkeleton = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement {
|
|
9
|
+
constructor() {
|
|
10
|
+
super();
|
|
11
|
+
this.__registerHost();
|
|
12
|
+
/**
|
|
13
|
+
* Set the shape type of the skeleton is it circle or normal
|
|
14
|
+
*/
|
|
15
|
+
this.type = 'normal';
|
|
16
|
+
/**
|
|
17
|
+
* Set the skeleton width
|
|
18
|
+
*/
|
|
19
|
+
this.width = '100%';
|
|
20
|
+
/**
|
|
21
|
+
* Set the skeleton height
|
|
22
|
+
*/
|
|
23
|
+
this.height = '100%';
|
|
24
|
+
}
|
|
25
|
+
render() {
|
|
26
|
+
const classes = {
|
|
27
|
+
's-skeleton-item': true,
|
|
28
|
+
's-skeleton-item-circular': this.type == 'circle',
|
|
29
|
+
};
|
|
30
|
+
return (h("div", { class: "s-skeleton-wrapper", style: { width: this.width, height: this.height } }, h("div", { class: classes }, "\u00A0")));
|
|
31
|
+
}
|
|
32
|
+
static get style() { return sallaSkeletonCss; }
|
|
33
|
+
}, [0, "salla-skeleton", {
|
|
34
|
+
"type": [1],
|
|
35
|
+
"width": [1],
|
|
36
|
+
"height": [1]
|
|
37
|
+
}]);
|
|
38
|
+
function defineCustomElement() {
|
|
39
|
+
if (typeof customElements === "undefined") {
|
|
40
|
+
return;
|
|
41
|
+
}
|
|
42
|
+
const components = ["salla-skeleton"];
|
|
43
|
+
components.forEach(tagName => { switch (tagName) {
|
|
44
|
+
case "salla-skeleton":
|
|
45
|
+
if (!customElements.get(tagName)) {
|
|
46
|
+
customElements.define(tagName, SallaSkeleton);
|
|
47
|
+
}
|
|
48
|
+
break;
|
|
49
|
+
} });
|
|
50
|
+
}
|
|
51
|
+
defineCustomElement();
|
|
52
|
+
|
|
53
|
+
export { SallaSkeleton as S, defineCustomElement as d };
|
|
@@ -1427,7 +1427,7 @@ const SallaSocialShare$1 = /*@__PURE__*/ proxyCustomElement(class extends HTMLEl
|
|
|
1427
1427
|
}, '-=200');
|
|
1428
1428
|
}
|
|
1429
1429
|
render() {
|
|
1430
|
-
return (h("div", {
|
|
1430
|
+
return (h("div", { class: "s-social-share-wrapper" }, h("slot", { name: 'widget' }, h("salla-button", { "aria-label": "Share", onClick: () => this.open(), class: "s-social-share-btn", shape: "icon", fill: "outline", color: "light" }, h("i", { class: this.opened ? "sicon-cancel" : "sicon-share-alt" }))), h("ul", { ref: el => this.shareMenu = el, class: "s-social-share-list a2a_kit share" }, this.platforms.map(platform => {
|
|
1431
1431
|
return (h("li", { ref: el => this.platformItem = el }, h("a", { class: `a2a_button_${platform}`, "aria-label": `Share Via ${platform}` }, this.platformIcons.map((icon) => {
|
|
1432
1432
|
if (icon.name === platform) {
|
|
1433
1433
|
return h("span", { class: "s-social-share-icon", innerHTML: icon.icon });
|
|
@@ -1467,7 +1467,7 @@ const SallaTelInput = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement
|
|
|
1467
1467
|
}
|
|
1468
1468
|
;
|
|
1469
1469
|
render() {
|
|
1470
|
-
return (h(Host, {
|
|
1470
|
+
return (h(Host, { class: "s-tel-input" }, h("input", { type: "tel", name: this.name, value: this.phone, ref: el => this.phoneInput = el, class: "s-tel-input-control tel-input s-ltr" }), h("span", { class: "s-tel-input-error-msg", ref: el => this.errorMsg = el }), h("input", { type: "hidden", name: "country_code", value: this.countryCode, ref: el => this.countryCodeInput = el, class: "country_code" })));
|
|
1471
1471
|
}
|
|
1472
1472
|
componentDidLoad() {
|
|
1473
1473
|
this.initTelInput();
|
package/dist/esm/loader.js
CHANGED
|
@@ -13,7 +13,7 @@ const patchEsm = () => {
|
|
|
13
13
|
const defineCustomElements = (win, options) => {
|
|
14
14
|
if (typeof window === 'undefined') return Promise.resolve();
|
|
15
15
|
return patchEsm().then(() => {
|
|
16
|
-
return bootstrapLazy([["salla-button_24",[[4,"salla-loyalty",{"prizePoints":[8,"prize-points"],"customerPoints":[2,"customer-points"],"prizeTitle":[1,"prize-title"],"allowEmail":[4,"allow-email"],"allowMobile":[4,"allow-mobile"],"requireEmail":[4,"require-email"],"guestMessage":[1,"guest-message"],"loyaltyProgram":[32],"buttonLoading":[32],"selectedItem":[32],"askConfirmation":[32],"is_loggedin":[32],"points":[32],"exchange_points":[32],"are_you_sure_to_exchange":[32],"for":[32],"cancel":[32],"confirm":[32],"cart_total_point_summary":[32],"cart_point_exchange_now":[32],"login_button":[32],"open":[64],"close":[64],"resetExchange":[64],"exchangeLoyaltyPoint":[64]}],[4,"salla-product-size-guide",{"guides":[32],"productId":[32],"open":[64],"close":[64]}],[4,"salla-login-modal",{"isEmailAllowed":[1028,"is-email-allowed"],"isMobileAllowed":[1028,"is-mobile-allowed"],"isEmailRequired":[1028,"is-email-required"],"title":[32],"loginTypeTitle":[32],"loginText":[32],"smsLabel":[32],"mobileLabel":[32],"emailLabel":[32],"enterText":[32],"bySMSText":[32],"byEmailText":[32],"emailErrorMsg":[32],"firstNameLabel":[32],"lastNameLabel":[32],"firstNameErrorMsg":[32],"lastNameErrorMsg":[32],"open":[64]},[[8,"verified","onVerified"]]],[4,"salla-scopes",{"selection":[1],"searchDisplayLimit":[2,"search-display-limit"],"mode":[32],"current_scope":[32],"scopes":[32],"originalScopesList":[32],"branchNotFound":[32],"ourServiceIsNotFound":[32],"searchForAvailabilityInOtherBranch":[32],"shoppingFromAnotherBranch":[32],"nowBrowsingFrom":[32],"confirmButton":[32],"scopeSearchPlaceholder":[32],"selected_scope":[32],"isOpenedBefore":[32],"close":[64],"open":[64],"handleSubmit":[64]}],[0,"salla-rating-modal",{"orderId":[2,"order-id"],"order":[32],"open":[64],"close":[64]}],[0,"salla-localization-modal",{"language":[1537],"currency":[1537],"languages":[32],"currencies":[32],"languagesTitle":[32],"currenciesTitle":[32],"isLoading":[32],"open":[64],"close":[64],"submit":[64]}],[0,"salla-offer-modal",{"offer":[32],"offer_name":[32],"offer_message":[32],"offer_expires_in":[32],"remember_my_choice":[32],"add_to_cart":[32],"out_of_stock":[32],"open":[64],"showOffer":[64]}],[0,"salla-search",{"inline":[4],"oval":[4],"height":[2],"results":[32],"placeholder":[32],"noResultsText":[32],"typing":[32],"debounce":[32],"search_term":[32]}],[4,"salla-social-share",{"url":[513],"urlName":[513,"url-name"],"platforms":[16],"opened":[32],"allPlatforms":[32],"platformIcons":[32],"open":[64]}],[4,"salla-infinite-scroll",{"nextPage":[1,"next-page"],"autoload":[1028],"container":[1],"item":[1],"loadMore":[32],"noMore":[32],"failedToLoad":[32]}],[0,"salla-
|
|
16
|
+
return bootstrapLazy([["salla-button_24",[[4,"salla-loyalty",{"prizePoints":[8,"prize-points"],"customerPoints":[2,"customer-points"],"prizeTitle":[1,"prize-title"],"allowEmail":[4,"allow-email"],"allowMobile":[4,"allow-mobile"],"requireEmail":[4,"require-email"],"guestMessage":[1,"guest-message"],"loyaltyProgram":[32],"buttonLoading":[32],"selectedItem":[32],"askConfirmation":[32],"is_loggedin":[32],"points":[32],"exchange_points":[32],"are_you_sure_to_exchange":[32],"for":[32],"cancel":[32],"confirm":[32],"cart_total_point_summary":[32],"cart_point_exchange_now":[32],"login_button":[32],"open":[64],"close":[64],"resetExchange":[64],"exchangeLoyaltyPoint":[64]}],[4,"salla-product-size-guide",{"guides":[32],"productId":[32],"open":[64],"close":[64]}],[4,"salla-login-modal",{"isEmailAllowed":[1028,"is-email-allowed"],"isMobileAllowed":[1028,"is-mobile-allowed"],"isEmailRequired":[1028,"is-email-required"],"title":[32],"loginTypeTitle":[32],"loginText":[32],"smsLabel":[32],"mobileLabel":[32],"emailLabel":[32],"enterText":[32],"bySMSText":[32],"byEmailText":[32],"emailErrorMsg":[32],"firstNameLabel":[32],"lastNameLabel":[32],"firstNameErrorMsg":[32],"lastNameErrorMsg":[32],"open":[64]},[[8,"verified","onVerified"]]],[4,"salla-scopes",{"selection":[1],"searchDisplayLimit":[2,"search-display-limit"],"mode":[32],"current_scope":[32],"scopes":[32],"originalScopesList":[32],"branchNotFound":[32],"ourServiceIsNotFound":[32],"searchForAvailabilityInOtherBranch":[32],"shoppingFromAnotherBranch":[32],"nowBrowsingFrom":[32],"confirmButton":[32],"scopeSearchPlaceholder":[32],"selected_scope":[32],"isOpenedBefore":[32],"close":[64],"open":[64],"handleSubmit":[64]}],[0,"salla-rating-modal",{"orderId":[2,"order-id"],"order":[32],"open":[64],"close":[64]}],[0,"salla-localization-modal",{"language":[1537],"currency":[1537],"languages":[32],"currencies":[32],"languagesTitle":[32],"currenciesTitle":[32],"isLoading":[32],"open":[64],"close":[64],"submit":[64]}],[0,"salla-offer-modal",{"offer":[32],"offer_name":[32],"offer_message":[32],"offer_expires_in":[32],"remember_my_choice":[32],"add_to_cart":[32],"out_of_stock":[32],"open":[64],"showOffer":[64]}],[0,"salla-search",{"inline":[4],"oval":[4],"height":[2],"results":[32],"placeholder":[32],"noResultsText":[32],"typing":[32],"debounce":[32],"search_term":[32]}],[4,"salla-social-share",{"url":[513],"urlName":[513,"url-name"],"platforms":[16],"opened":[32],"allPlatforms":[32],"platformIcons":[32],"open":[64]}],[4,"salla-infinite-scroll",{"nextPage":[1,"next-page"],"autoload":[1028],"container":[1],"item":[1],"loadMore":[32],"noMore":[32],"failedToLoad":[32]}],[0,"salla-product-availability",{"channels":[1],"productId":[2,"product-id"],"isSubscribed":[1028,"is-subscribed"],"subTitle":[32],"mobileLabel":[32],"emailLabel":[32],"emailPlaceholder":[32],"subscribedMessage":[32],"title_":[32],"emailErrorMsg":[32],"isVisitorSubscribed":[32]}],[4,"salla-verify",{"display":[1],"type":[1025],"autoReload":[4,"auto-reload"],"title":[32],"resendAfter":[32],"isProfileVerify":[32],"getCode":[64],"open":[64]}],[4,"salla-swiper",{"loop":[4],"speed":[2],"itemPerView":[8,"item-per-view"],"spaceBetweenItems":[2,"space-between-items"],"direction":[1],"currentIndex":[32],"isLastSlideItem":[32],"isFirstSlideItem":[32]}],[0,"salla-rating-stars",{"name":[1],"size":[1],"value":[2]}],[0,"salla-skeleton",{"type":[1],"width":[1],"height":[1]}],[4,"salla-list-tile",{"href":[1],"target":[1]}],[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,"onSelect","onSelectedTab"]]],[4,"salla-placeholder",{"icon":[1],"alignment":[1],"iconSize":[1,"icon-size"],"default_title":[32],"default_description":[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"],"icon":[1],"iconStyle":[1,"icon-style"],"imageIcon":[1,"image-icon"],"modalTitle":[32],"open":[64],"close":[64],"setTitle":[64],"loading":[64],"stopLoading":[64]}],[4,"salla-button",{"shape":[513],"color":[513],"fill":[513],"size":[513],"width":[513],"loading":[516],"disabled":[516],"loaderPosition":[1,"loader-position"],"href":[1],"load":[64],"stop":[64],"setText":[64],"disable":[64],"enable":[64]}],[0,"salla-loading",{"size":[8],"width":[8],"color":[1],"bgColor":[1,"bg-color"]}]]],["salla-add-product-button",[[4,"salla-add-product-button",{"channels":[513],"quantity":[514],"donatingAmount":[514,"donating-amount"],"productId":[520,"product-id"],"productStatus":[513,"product-status"],"productType":[513,"product-type"]}]]],["salla-conditional-fields",[[4,"salla-conditional-fields",null,[[0,"change","changeHandler"]]]]],["salla-installment",[[0,"salla-installment",{"price":[1],"language":[1],"currency":[1],"tamaraIsActive":[32],"tabbyIsActive":[32],"spotiiIsActive":[32]}]]],["salla-quantity-input",[[4,"salla-quantity-input",{"quantity":[32],"decrease":[64],"increase":[64],"setValue":[64]}]]]], options);
|
|
17
17
|
});
|
|
18
18
|
};
|
|
19
19
|
|
|
@@ -323,7 +323,7 @@ const SallaLocalizationModal = class {
|
|
|
323
323
|
.then(() => url && (window.location.href = url));
|
|
324
324
|
}
|
|
325
325
|
render() {
|
|
326
|
-
return (h("salla-modal", { isLoading: this.isLoading,
|
|
326
|
+
return (h("salla-modal", { isLoading: this.isLoading, class: "s-hidden", ref: modal => this.modal = modal, width: "xs" }, !this.isLoading ?
|
|
327
327
|
h("div", { class: "s-localization-modal-inner" }, this.languages.length > 1 ?
|
|
328
328
|
h("div", { class: "s-localization-modal-section" }, h("label", { class: "s-localization-modal-title" }, this.languagesTitle), h("div", { class: "s-localization-modal-section-inner" }, this.languages.length < 6 ?
|
|
329
329
|
this.languages.map(lang => h("div", { class: "s-localization-modal-item" }, h("input", { class: "s-localization-modal-input", type: "radio", checked: this.language == lang.iso_code, onChange: () => this.language = lang.iso_code, name: "language", id: 'lang-' + lang.code.toLowerCase(), value: lang.code }), h("div", { class: "s-localization-modal-label-slot", id: "language-slot", innerHTML: this.languageSlot
|
|
@@ -705,7 +705,6 @@ const SallaLoyalty = class {
|
|
|
705
705
|
this.modal.open();
|
|
706
706
|
return await salla.loyalty.getProgram()
|
|
707
707
|
.then((response) => {
|
|
708
|
-
console.log("🚀 ~ file: salla-loyalty.tsx ~ line 167 ~ SallaLoyalty ~ .then ~ response", response);
|
|
709
708
|
this.loyaltyProgram = response.data;
|
|
710
709
|
})
|
|
711
710
|
.catch(e => console.log(e))
|
|
@@ -773,12 +772,12 @@ const SallaLoyalty = class {
|
|
|
773
772
|
h("slot", { name: 'widget' }, this.customerPoints ?
|
|
774
773
|
h("salla-list-tile", { class: 's-loyalty-widget' }, h("div", { slot: "icon", class: "s-loyalty-widget-icon", innerHTML: Star2 }), h("div", { slot: "subtitle" }, this.is_loggedin ? this.cart_total_point_summary : this.guestMessage, h("salla-button", { shape: "link", color: "primary", onClick: () => salla.event.dispatch("loyalty::open") }, this.is_loggedin ? this.cart_point_exchange_now : this.login_button))) :
|
|
775
774
|
''),
|
|
776
|
-
h("salla-modal", {
|
|
777
|
-
h("salla-modal", { isLoading: true,
|
|
775
|
+
h("salla-modal", { noPadding: true, position: 'top', width: "sm", ref: modal => this.confirmationModal = modal }, this.getConfirmationModal()),
|
|
776
|
+
h("salla-modal", { isLoading: true, "has-skeleton": true, width: "md", ref: modal => this.modal = modal }, h("div", { slot: "loading" }, h("div", { class: "s-loyalty-skeleton" }, h("salla-list-tile", { class: "s-loyalty-header" }, h("div", { slot: "icon", class: "s-loyalty-header-icon" }, h("salla-skeleton", { type: "circle", height: '6rem', width: '6rem' })), h("div", { slot: "title", class: "s-loyalty-header-title mb-5" }, h("salla-skeleton", { height: '15px', width: '50%' })), h("div", { slot: "subtitle", class: "s-loyalty-header-subtitle" }, h("salla-skeleton", { height: '10px' }), h("salla-skeleton", { height: '10px', width: '75%' }))), h("div", { class: "s-loyalty-skeleton-cards" }, [...Array(3)].map(() => h("div", { class: "s-loyalty-prize-item" }, h("salla-skeleton", { height: '9rem' }), h("div", { class: "s-loyalty-prize-item-title" }, h("salla-skeleton", { height: '15px', width: '75%' })), h("div", { class: "s-loyalty-prize-item-subtitle" }, h("salla-skeleton", { height: '10px', width: '50%' }), h("salla-skeleton", { height: '10px', width: '25%' })), h("div", { class: "s-loyalty-prize-item-points" }, h("salla-skeleton", { height: '15px', width: '100px' }), h("div", { class: "s-loyalty-prize-item-check" }, h("salla-skeleton", { height: '1rem', width: '1rem', type: 'circle' })))))))), !!this.loyaltyProgram ?
|
|
778
777
|
[
|
|
779
778
|
h("salla-list-tile", { id: 's-loyalty-header', class: "s-loyalty-header" }, h("div", { slot: "icon", class: "s-loyalty-header-icon", innerHTML: GiftImg }), h("div", { slot: "title", class: "s-loyalty-header-title" }, this.loyaltyProgram.prize_promotion_title), h("div", { slot: "subtitle", class: "s-loyalty-header-subtitle" }, this.loyaltyProgram.prize_promotion_description)),
|
|
780
779
|
h("salla-tabs", null, this.loyaltyProgram.prizes.map((prize) => h("salla-tab-header", { slot: "header", name: prize.title }, h("span", null, prize.title))), this.loyaltyProgram.prizes.map((prize) => h("salla-tab-content", { slot: "content", name: prize.title }, h("salla-swiper", { "space-between-items": "20" }, prize.items.map((item) => this.prizeItem(item)))))),
|
|
781
|
-
h("salla-button", { disabled: !this.selectedItem, width: "wide", class: "s-loyalty-program-redeem-btn", onClick: () => this.openConfirmation() }, this.exchange_points)
|
|
780
|
+
h("salla-button", { disabled: !this.selectedItem, width: "wide", class: "s-loyalty-program-redeem-btn", onClick: () => this.openConfirmation() }, this.exchange_points),
|
|
782
781
|
]
|
|
783
782
|
: h("salla-placeholder", { class: "s-loyalty-placeholder", alignment: "center" })),
|
|
784
783
|
];
|
|
@@ -807,6 +806,10 @@ const SallaModal = class {
|
|
|
807
806
|
* open the modal on rendering
|
|
808
807
|
*/
|
|
809
808
|
this.visible = false;
|
|
809
|
+
/**
|
|
810
|
+
* open the modal on rendering
|
|
811
|
+
*/
|
|
812
|
+
this.hasSkeleton = false;
|
|
810
813
|
/**
|
|
811
814
|
* Show loading in the middle
|
|
812
815
|
*/
|
|
@@ -908,13 +911,13 @@ const SallaModal = class {
|
|
|
908
911
|
};
|
|
909
912
|
}
|
|
910
913
|
getWidth() {
|
|
911
|
-
return this.isLoading ? 'sm' : this.width;
|
|
914
|
+
return this.isLoading ? this.hasSkeleton ? 'md' : 'sm' : this.width;
|
|
912
915
|
}
|
|
913
916
|
//todo:: pref for each modal
|
|
914
917
|
render() {
|
|
915
918
|
this.host.id = this.host.id || 'salla-modal';
|
|
916
919
|
if (this.isLoading) {
|
|
917
|
-
return (h(Host, { class: 'salla-modal s-modal s-modal-container s-hidden', "aria-modal": "true", role: "dialog" }, h("div", { class: "s-modal-overlay", ref: el => this.overlay = el, onClick: () => this.closeModal() }), h("div", { class: "s-modal-wrapper" }, h("span", { class: 's-modal-spacer s-modal-align-' + this.position }, "\u200B"), h("div", { class: 's-modal-body ' + 's-modal-align-' + this.position + ' s-modal-' + this.getWidth() + (this.noPadding ? ' s-modal-nopadding' : ' s-modal-padding') }, h("salla-loading", null), h("div", { class: "s-hidden" }, h("slot", null))))));
|
|
920
|
+
return (h(Host, { class: 'salla-modal s-modal s-modal-container s-hidden', "aria-modal": "true", role: "dialog" }, h("div", { class: "s-modal-overlay", ref: el => this.overlay = el, onClick: () => this.closeModal() }), h("div", { class: "s-modal-wrapper" }, h("span", { class: 's-modal-spacer s-modal-align-' + this.position }, "\u200B"), h("div", { class: 's-modal-body ' + 's-modal-align-' + this.position + ' s-modal-' + this.getWidth() + (this.noPadding ? ' s-modal-nopadding' : ' s-modal-padding') }, h("slot", { name: "loading" }, h("salla-loading", null)), h("div", { class: "s-hidden" }, h("slot", null))))));
|
|
918
921
|
}
|
|
919
922
|
return (h(Host, { class: 'salla-modal s-modal s-modal-container s-hidden', "aria-modal": "true", role: "dialog" }, h("div", { class: "s-modal-overlay", ref: el => this.overlay = el, onClick: () => this.closeModal() }), h("div", { class: "s-modal-wrapper" }, h("span", { class: 's-modal-spacer s-modal-align-' + this.position }, "\u200B"), h("div", { class: 's-modal-body ' + 's-modal-align-' + this.position + ' s-modal-' + this.getWidth() + (this.noPadding ? ' s-modal-nopadding' : ' s-modal-padding') }, h("div", { class: { 's-modal-header': true, 's-modal-is-center': this.icon != '' || this.imageIcon != '' } }, this.isClosable ?
|
|
920
923
|
h("button", { class: "s-modal-close", onClick: () => this.closeModal(), type: "button" }, h("span", { class: "sicon-cancel" }))
|
|
@@ -1003,7 +1006,7 @@ const SallaOfferModal = class {
|
|
|
1003
1006
|
}
|
|
1004
1007
|
render() {
|
|
1005
1008
|
var _a, _b;
|
|
1006
|
-
return h("salla-modal", {
|
|
1009
|
+
return h("salla-modal", { "sub-title-first": true, icon: "sicon-special-discount", "sub-title": this.offer_message, ref: modal => this.modal = modal, "is-loading": this.offer === null }, this.offer !== null
|
|
1007
1010
|
? [h("div", { class: "s-offer-modal-scrolled-slider-wrap" }, h("div", { class: "s-offer-modal-body s-offer-modal-scrolled-slider" }, ((_a = this.offer.get.categories) === null || _a === void 0 ? void 0 : _a.length) > 0
|
|
1008
1011
|
? this.offer.get.categories.map(category => h("a", { href: category.urls.customer, class: "s-offer-modal-badge s-offer-modal-slider-item", innerHTML: this.categorySlot
|
|
1009
1012
|
.replace(/\{name\}/g, category.name)
|
|
@@ -1106,7 +1109,7 @@ const SallaPlaceholder = class {
|
|
|
1106
1109
|
};
|
|
1107
1110
|
}
|
|
1108
1111
|
render() {
|
|
1109
|
-
return (h(
|
|
1112
|
+
return (h(Host, { class: this.alignmentClass() }, h("div", { class: `s-placeholder-icon s-placeholder-icon-${this.iconSize}`, innerHTML: this.icon }), h("div", { class: "s-placeholder-title" }, h("slot", { name: 'title' }, h("span", null, this.default_title))), h("div", { class: "s-placeholder-description" }, h("slot", { name: 'description' }, h("span", null, this.default_description)))));
|
|
1110
1113
|
}
|
|
1111
1114
|
};
|
|
1112
1115
|
SallaPlaceholder.style = sallaPlaceholderCss;
|
|
@@ -1418,9 +1421,9 @@ const SallaRatingModal = class {
|
|
|
1418
1421
|
this.showActiveStep(this.thanksTab);
|
|
1419
1422
|
}
|
|
1420
1423
|
render() {
|
|
1421
|
-
return (h(Host, {
|
|
1424
|
+
return (h(Host, { class: "s-rating" }, h("salla-modal", { isLoading: true, width: "md", ref: modal => this.modal = modal }, this.order
|
|
1422
1425
|
? [h("div", { class: "s-rating-modal-wrapper", ref: el => this.body = el }, this.order.testimonials_enabled ?
|
|
1423
|
-
h("div", { class: "rating-outer-form s-rating-modal-step-wrap s-rating-modal-step s-rating-modal-hidden", "data-type": "store" }, h("div", { class: "s-rating-modal-rounded-icon" }, h("img", { src: salla.config.get('store.logo', 'https://assets.salla.sa/cp/assets/images/logo-new.png'), alt: "store name", class: "s-rating-modal-store-logo" })), h("h2", { class: "s-rating-modal-title" }, this.rate_the_store), h("div", { class: "s-rating-modal-stars-company" }, h("salla-rating-stars", { size: "large" })), h("textarea", {
|
|
1426
|
+
h("div", { class: "rating-outer-form s-rating-modal-step-wrap s-rating-modal-step s-rating-modal-hidden", "data-type": "store" }, h("div", { class: "s-rating-modal-rounded-icon" }, h("img", { src: salla.config.get('store.logo', 'https://assets.salla.sa/cp/assets/images/logo-new.png'), alt: "store name", class: "s-rating-modal-store-logo" })), h("h2", { class: "s-rating-modal-title" }, this.rate_the_store), h("div", { class: "s-rating-modal-stars-company" }, h("salla-rating-stars", { size: "large" })), h("textarea", { name: "comment", class: "s-rating-modal-comment", placeholder: this.write_store_rate }), h("small", { class: "s-rating-modal-validation-msg" }))
|
|
1424
1427
|
: '', this.order.products_enabled
|
|
1425
1428
|
? h("section", { class: "s-rating-modal-step s-rating-modal-hidden", "data-type": "products" }, this.order.products.map((item, index) => h("div", { class: "rating-outer-form s-rating-modal-product", "data-stars-error": this.rate_product_stars }, h("div", { class: "s-rating-modal-product-img-wrap" }, h("img", { src: item.product.thumbnail, alt: item.product.name, class: "s-rating-modal-product-img" })), h("div", { class: "s-rating-modal-product-details" }, h("h3", { class: "s-rating-modal-product-title" }, " ", item.product.name), h("div", { class: "s-rating-modal-stars-product" }, h("salla-rating-stars", { size: "small", name: `products[${index}][rating]` })), h("input", { type: "hidden", name: `products[${index}][product_id]`, value: item.product.id }), h("textarea", { placeholder: this.write_product_rate, name: `products[${index}][comment]`, class: "s-rating-modal-comment" }), h("small", { class: "s-rating-modal-validation-msg" })))))
|
|
1426
1429
|
: '', this.order.shipping_enabled
|
|
@@ -1593,7 +1596,7 @@ const SallaScopees = class {
|
|
|
1593
1596
|
return await salla.scope.change(payload)
|
|
1594
1597
|
.then(() => {
|
|
1595
1598
|
salla.storage.set("branch-choosed-before", true);
|
|
1596
|
-
|
|
1599
|
+
salla.storage.set("scope", this.current_scope.id);
|
|
1597
1600
|
}).catch(e => console.log(e))
|
|
1598
1601
|
.finally(() => {
|
|
1599
1602
|
this.changeBtn.stop();
|
|
@@ -1639,7 +1642,7 @@ const SallaScopees = class {
|
|
|
1639
1642
|
return h("div", { class: "s-scopes-footer" }, h("slot", { name: "footer" }, h("salla-button", { ref: btn => this.changeBtn = btn, disabled: !this.current_scope, onClick: () => this.handleSubmit(), class: "s-scopes-submit", "loader-position": "center", width: "wide" }, this.confirmButton)));
|
|
1640
1643
|
}
|
|
1641
1644
|
render() {
|
|
1642
|
-
return (h(Host, null, h("salla-modal", { ref: modal => this.modal = modal,
|
|
1645
|
+
return (h(Host, null, h("salla-modal", { ref: modal => this.modal = modal, isClosable: !!(this.isOpenedBefore || (this.selection == 'optional')), class: "s-scopes-modal", isLoading: true }, h("salla-list-tile", { class: this.originalScopesList.length ? "s-scopes-header block" : "s-hidden" }, h("div", { slot: "icon", class: "s-scopes-header-icon", innerHTML: StoreAlt }), h("div", { slot: "title", class: "s-scopes-header-title" }, this.nowBrowsingFrom), h("div", { slot: "subtitle", class: "s-scopes-header-subtitle" }, !!this.selected_scope ? this.selected_scope.name : "")), h("div", { class: "s-scopes-wrap" }, !!this.originalScopesList.length && h("h4", { class: "s-scopes-title" }, this.getFormTitle()), this.originalScopesList.length > this.searchDisplayLimit ?
|
|
1643
1646
|
h("div", { class: "s-scopes-search-wrapper" }, h("div", { class: "s-scopes-search-icon", innerHTML: Search }), h("input", { type: "text", class: "s-scopes-search-input", onInput: e => this.handleSearchFieldTyping(e), placeholder: this.scopeSearchPlaceholder }))
|
|
1644
1647
|
: "", this.scopes.length < 2 ?
|
|
1645
1648
|
this.placeholderContent()
|
|
@@ -3204,7 +3207,7 @@ const SallaSocialShare = class {
|
|
|
3204
3207
|
}, '-=200');
|
|
3205
3208
|
}
|
|
3206
3209
|
render() {
|
|
3207
|
-
return (h("div", {
|
|
3210
|
+
return (h("div", { class: "s-social-share-wrapper" }, h("slot", { name: 'widget' }, h("salla-button", { "aria-label": "Share", onClick: () => this.open(), class: "s-social-share-btn", shape: "icon", fill: "outline", color: "light" }, h("i", { class: this.opened ? "sicon-cancel" : "sicon-share-alt" }))), h("ul", { ref: el => this.shareMenu = el, class: "s-social-share-list a2a_kit share" }, this.platforms.map(platform => {
|
|
3208
3211
|
return (h("li", { ref: el => this.platformItem = el }, h("a", { class: `a2a_button_${platform}`, "aria-label": `Share Via ${platform}` }, this.platformIcons.map((icon) => {
|
|
3209
3212
|
if (icon.name === platform) {
|
|
3210
3213
|
return h("span", { class: "s-social-share-icon", innerHTML: icon.icon });
|
|
@@ -9818,7 +9821,7 @@ const SallaTelInput = class {
|
|
|
9818
9821
|
}
|
|
9819
9822
|
;
|
|
9820
9823
|
render() {
|
|
9821
|
-
return (h(Host, {
|
|
9824
|
+
return (h(Host, { class: "s-tel-input" }, h("input", { type: "tel", name: this.name, value: this.phone, ref: el => this.phoneInput = el, class: "s-tel-input-control tel-input s-ltr" }), h("span", { class: "s-tel-input-error-msg", ref: el => this.errorMsg = el }), h("input", { type: "hidden", name: "country_code", value: this.countryCode, ref: el => this.countryCodeInput = el, class: "country_code" })));
|
|
9822
9825
|
}
|
|
9823
9826
|
componentDidLoad() {
|
|
9824
9827
|
this.initTelInput();
|
|
@@ -16,5 +16,5 @@ const patchBrowser = () => {
|
|
|
16
16
|
};
|
|
17
17
|
|
|
18
18
|
patchBrowser().then(options => {
|
|
19
|
-
return bootstrapLazy([["salla-button_24",[[4,"salla-loyalty",{"prizePoints":[8,"prize-points"],"customerPoints":[2,"customer-points"],"prizeTitle":[1,"prize-title"],"allowEmail":[4,"allow-email"],"allowMobile":[4,"allow-mobile"],"requireEmail":[4,"require-email"],"guestMessage":[1,"guest-message"],"loyaltyProgram":[32],"buttonLoading":[32],"selectedItem":[32],"askConfirmation":[32],"is_loggedin":[32],"points":[32],"exchange_points":[32],"are_you_sure_to_exchange":[32],"for":[32],"cancel":[32],"confirm":[32],"cart_total_point_summary":[32],"cart_point_exchange_now":[32],"login_button":[32],"open":[64],"close":[64],"resetExchange":[64],"exchangeLoyaltyPoint":[64]}],[4,"salla-product-size-guide",{"guides":[32],"productId":[32],"open":[64],"close":[64]}],[4,"salla-login-modal",{"isEmailAllowed":[1028,"is-email-allowed"],"isMobileAllowed":[1028,"is-mobile-allowed"],"isEmailRequired":[1028,"is-email-required"],"title":[32],"loginTypeTitle":[32],"loginText":[32],"smsLabel":[32],"mobileLabel":[32],"emailLabel":[32],"enterText":[32],"bySMSText":[32],"byEmailText":[32],"emailErrorMsg":[32],"firstNameLabel":[32],"lastNameLabel":[32],"firstNameErrorMsg":[32],"lastNameErrorMsg":[32],"open":[64]},[[8,"verified","onVerified"]]],[4,"salla-scopes",{"selection":[1],"searchDisplayLimit":[2,"search-display-limit"],"mode":[32],"current_scope":[32],"scopes":[32],"originalScopesList":[32],"branchNotFound":[32],"ourServiceIsNotFound":[32],"searchForAvailabilityInOtherBranch":[32],"shoppingFromAnotherBranch":[32],"nowBrowsingFrom":[32],"confirmButton":[32],"scopeSearchPlaceholder":[32],"selected_scope":[32],"isOpenedBefore":[32],"close":[64],"open":[64],"handleSubmit":[64]}],[0,"salla-rating-modal",{"orderId":[2,"order-id"],"order":[32],"open":[64],"close":[64]}],[0,"salla-localization-modal",{"language":[1537],"currency":[1537],"languages":[32],"currencies":[32],"languagesTitle":[32],"currenciesTitle":[32],"isLoading":[32],"open":[64],"close":[64],"submit":[64]}],[0,"salla-offer-modal",{"offer":[32],"offer_name":[32],"offer_message":[32],"offer_expires_in":[32],"remember_my_choice":[32],"add_to_cart":[32],"out_of_stock":[32],"open":[64],"showOffer":[64]}],[0,"salla-search",{"inline":[4],"oval":[4],"height":[2],"results":[32],"placeholder":[32],"noResultsText":[32],"typing":[32],"debounce":[32],"search_term":[32]}],[4,"salla-social-share",{"url":[513],"urlName":[513,"url-name"],"platforms":[16],"opened":[32],"allPlatforms":[32],"platformIcons":[32],"open":[64]}],[4,"salla-infinite-scroll",{"nextPage":[1,"next-page"],"autoload":[1028],"container":[1],"item":[1],"loadMore":[32],"noMore":[32],"failedToLoad":[32]}],[0,"salla-
|
|
19
|
+
return bootstrapLazy([["salla-button_24",[[4,"salla-loyalty",{"prizePoints":[8,"prize-points"],"customerPoints":[2,"customer-points"],"prizeTitle":[1,"prize-title"],"allowEmail":[4,"allow-email"],"allowMobile":[4,"allow-mobile"],"requireEmail":[4,"require-email"],"guestMessage":[1,"guest-message"],"loyaltyProgram":[32],"buttonLoading":[32],"selectedItem":[32],"askConfirmation":[32],"is_loggedin":[32],"points":[32],"exchange_points":[32],"are_you_sure_to_exchange":[32],"for":[32],"cancel":[32],"confirm":[32],"cart_total_point_summary":[32],"cart_point_exchange_now":[32],"login_button":[32],"open":[64],"close":[64],"resetExchange":[64],"exchangeLoyaltyPoint":[64]}],[4,"salla-product-size-guide",{"guides":[32],"productId":[32],"open":[64],"close":[64]}],[4,"salla-login-modal",{"isEmailAllowed":[1028,"is-email-allowed"],"isMobileAllowed":[1028,"is-mobile-allowed"],"isEmailRequired":[1028,"is-email-required"],"title":[32],"loginTypeTitle":[32],"loginText":[32],"smsLabel":[32],"mobileLabel":[32],"emailLabel":[32],"enterText":[32],"bySMSText":[32],"byEmailText":[32],"emailErrorMsg":[32],"firstNameLabel":[32],"lastNameLabel":[32],"firstNameErrorMsg":[32],"lastNameErrorMsg":[32],"open":[64]},[[8,"verified","onVerified"]]],[4,"salla-scopes",{"selection":[1],"searchDisplayLimit":[2,"search-display-limit"],"mode":[32],"current_scope":[32],"scopes":[32],"originalScopesList":[32],"branchNotFound":[32],"ourServiceIsNotFound":[32],"searchForAvailabilityInOtherBranch":[32],"shoppingFromAnotherBranch":[32],"nowBrowsingFrom":[32],"confirmButton":[32],"scopeSearchPlaceholder":[32],"selected_scope":[32],"isOpenedBefore":[32],"close":[64],"open":[64],"handleSubmit":[64]}],[0,"salla-rating-modal",{"orderId":[2,"order-id"],"order":[32],"open":[64],"close":[64]}],[0,"salla-localization-modal",{"language":[1537],"currency":[1537],"languages":[32],"currencies":[32],"languagesTitle":[32],"currenciesTitle":[32],"isLoading":[32],"open":[64],"close":[64],"submit":[64]}],[0,"salla-offer-modal",{"offer":[32],"offer_name":[32],"offer_message":[32],"offer_expires_in":[32],"remember_my_choice":[32],"add_to_cart":[32],"out_of_stock":[32],"open":[64],"showOffer":[64]}],[0,"salla-search",{"inline":[4],"oval":[4],"height":[2],"results":[32],"placeholder":[32],"noResultsText":[32],"typing":[32],"debounce":[32],"search_term":[32]}],[4,"salla-social-share",{"url":[513],"urlName":[513,"url-name"],"platforms":[16],"opened":[32],"allPlatforms":[32],"platformIcons":[32],"open":[64]}],[4,"salla-infinite-scroll",{"nextPage":[1,"next-page"],"autoload":[1028],"container":[1],"item":[1],"loadMore":[32],"noMore":[32],"failedToLoad":[32]}],[0,"salla-product-availability",{"channels":[1],"productId":[2,"product-id"],"isSubscribed":[1028,"is-subscribed"],"subTitle":[32],"mobileLabel":[32],"emailLabel":[32],"emailPlaceholder":[32],"subscribedMessage":[32],"title_":[32],"emailErrorMsg":[32],"isVisitorSubscribed":[32]}],[4,"salla-verify",{"display":[1],"type":[1025],"autoReload":[4,"auto-reload"],"title":[32],"resendAfter":[32],"isProfileVerify":[32],"getCode":[64],"open":[64]}],[4,"salla-swiper",{"loop":[4],"speed":[2],"itemPerView":[8,"item-per-view"],"spaceBetweenItems":[2,"space-between-items"],"direction":[1],"currentIndex":[32],"isLastSlideItem":[32],"isFirstSlideItem":[32]}],[0,"salla-rating-stars",{"name":[1],"size":[1],"value":[2]}],[0,"salla-skeleton",{"type":[1],"width":[1],"height":[1]}],[4,"salla-list-tile",{"href":[1],"target":[1]}],[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,"onSelect","onSelectedTab"]]],[4,"salla-placeholder",{"icon":[1],"alignment":[1],"iconSize":[1,"icon-size"],"default_title":[32],"default_description":[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"],"icon":[1],"iconStyle":[1,"icon-style"],"imageIcon":[1,"image-icon"],"modalTitle":[32],"open":[64],"close":[64],"setTitle":[64],"loading":[64],"stopLoading":[64]}],[4,"salla-button",{"shape":[513],"color":[513],"fill":[513],"size":[513],"width":[513],"loading":[516],"disabled":[516],"loaderPosition":[1,"loader-position"],"href":[1],"load":[64],"stop":[64],"setText":[64],"disable":[64],"enable":[64]}],[0,"salla-loading",{"size":[8],"width":[8],"color":[1],"bgColor":[1,"bg-color"]}]]],["salla-add-product-button",[[4,"salla-add-product-button",{"channels":[513],"quantity":[514],"donatingAmount":[514,"donating-amount"],"productId":[520,"product-id"],"productStatus":[513,"product-status"],"productType":[513,"product-type"]}]]],["salla-conditional-fields",[[4,"salla-conditional-fields",null,[[0,"change","changeHandler"]]]]],["salla-installment",[[0,"salla-installment",{"price":[1],"language":[1],"currency":[1],"tamaraIsActive":[32],"tabbyIsActive":[32],"spotiiIsActive":[32]}]]],["salla-quantity-input",[[4,"salla-quantity-input",{"quantity":[32],"decrease":[64],"increase":[64],"setValue":[64]}]]]], options);
|
|
20
20
|
});
|