@ppg_pl/pallete 2.0.20 → 2.0.22
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/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/my-backdrop_8.cjs.entry.js +17 -4
- package/dist/cjs/my-backdrop_8.cjs.entry.js.map +1 -1
- package/dist/cjs/pallete.cjs.js +1 -1
- package/dist/collection/components/my-modal/my-modal.js +6 -2
- package/dist/collection/components/my-modal/my-modal.js.map +1 -1
- package/dist/collection/components/my-search/my-search.js +34 -7
- package/dist/collection/components/my-search/my-search.js.map +1 -1
- package/dist/components/gtmUtils.js +7 -0
- package/dist/components/gtmUtils.js.map +1 -0
- package/dist/components/index2.js +1 -5
- package/dist/components/index2.js.map +1 -1
- package/dist/components/index3.js +2 -1
- package/dist/components/index3.js.map +1 -1
- package/dist/components/my-colorbox2.js +2 -1
- package/dist/components/my-colorbox2.js.map +1 -1
- package/dist/components/my-colorinfo2.js +2 -1
- package/dist/components/my-colorinfo2.js.map +1 -1
- package/dist/components/my-modal2.js +8 -3
- package/dist/components/my-modal2.js.map +1 -1
- package/dist/components/my-search2.js +14 -3
- package/dist/components/my-search2.js.map +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/esm/my-backdrop_8.entry.js +17 -4
- package/dist/esm/my-backdrop_8.entry.js.map +1 -1
- package/dist/esm/pallete.js +1 -1
- package/dist/pallete/p-c49a7a8e.entry.js +2 -0
- package/dist/pallete/p-c49a7a8e.entry.js.map +1 -0
- package/dist/pallete/pallete.esm.js +1 -1
- package/dist/pallete/pallete.esm.js.map +1 -1
- package/dist/types/components/my-search/my-search.d.ts +2 -1
- package/dist/types/components.d.ts +4 -2
- package/package.json +1 -1
- package/www/build/p-c49a7a8e.entry.js +2 -0
- package/www/build/p-c49a7a8e.entry.js.map +1 -0
- package/www/build/pallete.esm.js +1 -1
- package/www/build/pallete.esm.js.map +1 -1
- package/dist/pallete/p-821312c7.entry.js +0 -2
- package/dist/pallete/p-821312c7.entry.js.map +0 -1
- package/www/build/p-821312c7.entry.js +0 -2
- package/www/build/p-821312c7.entry.js.map +0 -1
package/dist/cjs/loader.cjs.js
CHANGED
|
@@ -14,7 +14,7 @@ const patchEsm = () => {
|
|
|
14
14
|
const defineCustomElements = (win, options) => {
|
|
15
15
|
if (typeof window === 'undefined') return Promise.resolve();
|
|
16
16
|
return patchEsm().then(() => {
|
|
17
|
-
return index.bootstrapLazy([["my-backdrop_8.cjs",[[2,"my-component",{"shop":[1],"product":[1],"baselink":[1],"colorname":[1],"show":[32],"readyToClose":[32],"open":[64],"close":[64]},[[0,"readyToCLose","setReadyToCloseHandler"],[0,"close","closeModalHandler"]]],[0,"my-modal",{"shop":[1],"product":[1],"baselink":[1],"selectedcolor":[1],"closeImage":[1,"close-image"],"arrowDown":[1,"arrow-down"],"chunksNum":[32],"data":[32],"preloader":[32],"loading":[32],"colors":[32],"currentColor":[32],"currentIndex":[32],"infoBoxWidth":[32],"boxWidth":[32],"padding":[32],"isMobile":[32],"showRange":[32],"colorCategories":[32],"selectedCategory":[32],"page":[32],"colorIsSelected":[32],"open":[64]},[[0,"closeInfoBox","closeInfoBoxHandler"],[9,"resize","handleResize"],[0,"searchColors","searchColorsHandler"]]],[0,"my-backdrop"],[0,"my-colorinfo",{"currentColor":[16],"shop":[1],"product":[1],"baselink":[1],"data":[16],"isMobile":[4,"is-mobile"],"infoBoxWidth":[2,"info-box-width"],"closeImage":[1,"close-image"]}],[0,"my-colorbox",{"color":[1],"name":[1],"shop":[1],"product":[1],"isActive":[4,"is-active"],"isCategoryActive":[4,"is-category-active"],"isImageInsteadHex":[16]}],[2,"my-loader"],[2,"my-search",{"
|
|
17
|
+
return index.bootstrapLazy([["my-backdrop_8.cjs",[[2,"my-component",{"shop":[1],"product":[1],"baselink":[1],"colorname":[1],"show":[32],"readyToClose":[32],"open":[64],"close":[64]},[[0,"readyToCLose","setReadyToCloseHandler"],[0,"close","closeModalHandler"]]],[0,"my-modal",{"shop":[1],"product":[1],"baselink":[1],"selectedcolor":[1],"closeImage":[1,"close-image"],"arrowDown":[1,"arrow-down"],"chunksNum":[32],"data":[32],"preloader":[32],"loading":[32],"colors":[32],"currentColor":[32],"currentIndex":[32],"infoBoxWidth":[32],"boxWidth":[32],"padding":[32],"isMobile":[32],"showRange":[32],"colorCategories":[32],"selectedCategory":[32],"page":[32],"colorIsSelected":[32],"open":[64]},[[0,"closeInfoBox","closeInfoBoxHandler"],[9,"resize","handleResize"],[0,"searchColors","searchColorsHandler"]]],[0,"my-backdrop"],[0,"my-colorinfo",{"currentColor":[16],"shop":[1],"product":[1],"baselink":[1],"data":[16],"isMobile":[4,"is-mobile"],"infoBoxWidth":[2,"info-box-width"],"closeImage":[1,"close-image"]}],[0,"my-colorbox",{"color":[1],"name":[1],"shop":[1],"product":[1],"isActive":[4,"is-active"],"isCategoryActive":[4,"is-category-active"],"isImageInsteadHex":[16]}],[2,"my-loader"],[2,"my-search",{"productname":[1],"shopname":[1],"isMobile":[4,"is-mobile"],"searchIcon":[1,"search-icon"],"searchText":[32]},[[4,"clearSearchText","clearSearchTextHandler"]]],[0,"my-slider",{"slides":[16],"shop":[1],"product":[1],"color":[1]}]]]], options);
|
|
18
18
|
});
|
|
19
19
|
};
|
|
20
20
|
|
|
@@ -2982,6 +2982,10 @@ const MyModal = class {
|
|
|
2982
2982
|
componentWillLoad() {
|
|
2983
2983
|
this.preloader = true;
|
|
2984
2984
|
this.fetchProductData();
|
|
2985
|
+
setDataLayer({
|
|
2986
|
+
shop: this.shop,
|
|
2987
|
+
product: this.product,
|
|
2988
|
+
});
|
|
2985
2989
|
}
|
|
2986
2990
|
componentWillRender() {
|
|
2987
2991
|
this.displayForMobile();
|
|
@@ -2990,8 +2994,8 @@ const MyModal = class {
|
|
|
2990
2994
|
this.openSeletedColor();
|
|
2991
2995
|
}
|
|
2992
2996
|
render() {
|
|
2993
|
-
var _a, _b
|
|
2994
|
-
return (index$1.h("div", { class: `my-modal`, onMouseEnter: () => this.handleReadyToClose(false), onMouseLeave: () => this.handleReadyToClose(true) }, this.preloader && (index$1.h("div", { class: 'loader' }, index$1.h("my-loader", null))), !this.preloader && this.data && (index$1.h("div", { class: `my-modal__header` }, index$1.h("div", { class: "image-wrapper" }, index$1.h("img", { src: `${APIURL}/assets/${(_a = this.data) === null || _a === void 0 ? void 0 : _a.modalLogo}?access_token=${accessToken}`, alt: "modal-logo" }), !this.preloader && this.data && (index$1.h("p", { class: "my-modal__see-more" }, (_b = this.data) === null || _b === void 0 ? void 0 : _b.modalDescription))), index$1.h("div", { class: "search-wrapper" }, !this.preloader && index$1.h("my-search", {
|
|
2997
|
+
var _a, _b;
|
|
2998
|
+
return (index$1.h("div", { class: `my-modal`, onMouseEnter: () => this.handleReadyToClose(false), onMouseLeave: () => this.handleReadyToClose(true) }, this.preloader && (index$1.h("div", { class: 'loader' }, index$1.h("my-loader", null))), !this.preloader && this.data && (index$1.h("div", { class: `my-modal__header` }, index$1.h("div", { class: "image-wrapper" }, index$1.h("img", { src: `${APIURL}/assets/${(_a = this.data) === null || _a === void 0 ? void 0 : _a.modalLogo}?access_token=${accessToken}`, alt: "modal-logo" }), !this.preloader && this.data && (index$1.h("p", { class: "my-modal__see-more" }, (_b = this.data) === null || _b === void 0 ? void 0 : _b.modalDescription))), index$1.h("div", { class: "search-wrapper" }, !this.preloader && index$1.h("my-search", { shopname: this.shop, productname: this.data.name, isMobile: this.isMobile }), !this.preloader && (index$1.h("button", { class: "my-modal__close", onClick: () => this.closeModalHandler() }, index$1.h("img", { src: index$1.getAssetPath(`./assets/${this.closeImage}`), alt: "closebtn" })))))), index$1.h("div", { class: 'my-modal__wrapper' }, this.loading && index$1.h("my-loader", null), !this.loading && this.colors && (index$1.h("div", { class: 'container_boxes' }, this.colors.list.length > 0 ? (this.chunks(this.colors.list).map((color, index) => {
|
|
2995
2999
|
var _a;
|
|
2996
3000
|
return (index$1.h("div", { key: index, class: "boxes" }, index$1.h("div", { class: "boxes__list" }, color.map((c) => {
|
|
2997
3001
|
var _a;
|
|
@@ -3050,8 +3054,9 @@ const MySearch = class {
|
|
|
3050
3054
|
this.debouncedInputChangeValue = debounce((value) => {
|
|
3051
3055
|
this.fetchColorsByName(value);
|
|
3052
3056
|
this.searchText = value;
|
|
3053
|
-
},
|
|
3054
|
-
this.
|
|
3057
|
+
}, 500);
|
|
3058
|
+
this.productname = undefined;
|
|
3059
|
+
this.shopname = undefined;
|
|
3055
3060
|
this.isMobile = undefined;
|
|
3056
3061
|
this.searchIcon = 'search.svg';
|
|
3057
3062
|
this.searchText = null;
|
|
@@ -3061,6 +3066,14 @@ const MySearch = class {
|
|
|
3061
3066
|
this.debouncedInputChangeValue(value);
|
|
3062
3067
|
}
|
|
3063
3068
|
fetchColorsByNameHandle(newValue) {
|
|
3069
|
+
if (newValue.length >= 3) {
|
|
3070
|
+
setDataLayer({
|
|
3071
|
+
event: 'ColorSearch',
|
|
3072
|
+
shop: this.shopname,
|
|
3073
|
+
product: this.productname,
|
|
3074
|
+
search_term: newValue,
|
|
3075
|
+
});
|
|
3076
|
+
}
|
|
3064
3077
|
this.fetchColorsByName(newValue);
|
|
3065
3078
|
}
|
|
3066
3079
|
clearSearchTextHandler() {
|