vviinn-widgets 2.4.3 → 2.4.4
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/{app-globals-474864e0.js → app-globals-af9e1c96.js} +1 -1
- package/dist/cjs/cropper-handler.cjs.entry.js +1 -1
- package/dist/cjs/{customized-slots-0aa6c3d6.js → customized-slots-dc70586b.js} +1 -1
- package/dist/cjs/highlight-box_22.cjs.entry.js +4 -4
- package/dist/cjs/{imageSearch.store-076370bf.js → imageSearch.store-e11fb912.js} +1 -1
- package/dist/cjs/{index-61403ab1.js → index-07d3d672.js} +1 -1
- package/dist/cjs/{index-34d20028.js → index-135d1612.js} +14 -1
- package/dist/cjs/{index-a87f1a44.js → index-7e558d0b.js} +1 -1
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/vviinn-carousel_3.cjs.entry.js +15 -19
- package/dist/cjs/vviinn-error.cjs.entry.js +1 -1
- package/dist/cjs/vviinn-preloader.cjs.entry.js +2 -2
- package/dist/cjs/vviinn-recommendations-sidebar.cjs.entry.js +2 -2
- package/dist/cjs/vviinn-vpr-button.cjs.entry.js +2 -2
- package/dist/cjs/vviinn-vps-button.cjs.entry.js +3 -3
- package/dist/cjs/vviinn-vps-widget.cjs.entry.js +11 -7
- package/dist/cjs/vviinn-widgets.cjs.js +2 -2
- package/dist/collection/components/vviinn-product-card/vviinn-product-card.js +4 -12
- package/dist/collection/components/vviinn-vpr-widget/vviinn-vpr-vidget.js +8 -4
- package/dist/collection/components/vviinn-vps-widget/vviinn-vps-widget.js +8 -4
- package/dist/esm/{app-globals-3888cd41.js → app-globals-c988b07f.js} +1 -1
- package/dist/esm/cropper-handler.entry.js +1 -1
- package/dist/esm/{customized-slots-863113e2.js → customized-slots-62974f69.js} +1 -1
- package/dist/esm/highlight-box_22.entry.js +4 -4
- package/dist/esm/{imageSearch.store-b516d12e.js → imageSearch.store-5e2c3094.js} +1 -1
- package/dist/esm/{index-2f8fb0fe.js → index-412e5674.js} +13 -2
- package/dist/esm/{index-56c062df.js → index-4600de03.js} +1 -1
- package/dist/esm/{index-36978848.js → index-d0a661ce.js} +1 -1
- package/dist/esm/loader.js +2 -2
- package/dist/esm/vviinn-carousel_3.entry.js +15 -19
- package/dist/esm/vviinn-error.entry.js +1 -1
- package/dist/esm/vviinn-preloader.entry.js +2 -2
- package/dist/esm/vviinn-recommendations-sidebar.entry.js +2 -2
- package/dist/esm/vviinn-vpr-button.entry.js +2 -2
- package/dist/esm/vviinn-vps-button.entry.js +3 -3
- package/dist/esm/vviinn-vps-widget.entry.js +11 -7
- package/dist/esm/vviinn-widgets.js +2 -2
- package/dist/types/components/vviinn-vpr-widget/vviinn-vpr-vidget.d.ts +1 -1
- package/dist/types/components/vviinn-vps-widget/vviinn-vps-widget.d.ts +1 -1
- package/dist/vviinn-widgets/{p-c853cba8.js → p-11d26656.js} +1 -1
- package/dist/vviinn-widgets/{p-9cc6f0dd.entry.js → p-1bf0bfea.entry.js} +1 -1
- package/dist/vviinn-widgets/p-34d7d8fa.entry.js +1 -0
- package/dist/vviinn-widgets/p-521ba041.entry.js +1 -0
- package/dist/vviinn-widgets/{p-47183c9a.js → p-545ef9fd.js} +1 -1
- package/dist/vviinn-widgets/{p-f9410382.entry.js → p-62060afb.entry.js} +1 -1
- package/dist/vviinn-widgets/{p-0a9cee09.entry.js → p-79de17a4.entry.js} +1 -1
- package/{www/build/p-606ff863.js → dist/vviinn-widgets/p-7ec49ce4.js} +1 -1
- package/dist/vviinn-widgets/{p-2e6ecda7.entry.js → p-8ddb0d28.entry.js} +1 -1
- package/dist/vviinn-widgets/{p-d8d49616.entry.js → p-916817f8.entry.js} +1 -1
- package/{www/build/p-ac0a2989.js → dist/vviinn-widgets/p-9abc276d.js} +1 -1
- package/dist/vviinn-widgets/{p-b547a6d0.entry.js → p-b8932639.entry.js} +1 -1
- package/{www/build/p-535611cd.entry.js → dist/vviinn-widgets/p-c26d41ac.entry.js} +1 -1
- package/{www/build/p-28678772.js → dist/vviinn-widgets/p-d3b98fa3.js} +1 -1
- package/dist/vviinn-widgets/{p-b4caf042.js → p-eff93fbd.js} +1 -1
- package/dist/vviinn-widgets/vviinn-widgets.esm.js +1 -1
- package/package.json +1 -1
- package/www/build/{p-c853cba8.js → p-11d26656.js} +1 -1
- package/www/build/{p-9cc6f0dd.entry.js → p-1bf0bfea.entry.js} +1 -1
- package/www/build/p-34d7d8fa.entry.js +1 -0
- package/www/build/p-521ba041.entry.js +1 -0
- package/www/build/{p-47183c9a.js → p-545ef9fd.js} +1 -1
- package/www/build/{p-f9410382.entry.js → p-62060afb.entry.js} +1 -1
- package/www/build/{p-0a9cee09.entry.js → p-79de17a4.entry.js} +1 -1
- package/{dist/vviinn-widgets/p-606ff863.js → www/build/p-7ec49ce4.js} +1 -1
- package/www/build/p-8bfb73d1.js +1 -0
- package/www/build/{p-2e6ecda7.entry.js → p-8ddb0d28.entry.js} +1 -1
- package/www/build/{p-d8d49616.entry.js → p-916817f8.entry.js} +1 -1
- package/{dist/vviinn-widgets/p-ac0a2989.js → www/build/p-9abc276d.js} +1 -1
- package/www/build/p-a67898be.css +1 -0
- package/www/build/{p-b547a6d0.entry.js → p-b8932639.entry.js} +1 -1
- package/{dist/vviinn-widgets/p-535611cd.entry.js → www/build/p-c26d41ac.entry.js} +1 -1
- package/{dist/vviinn-widgets/p-28678772.js → www/build/p-d3b98fa3.js} +1 -1
- package/www/build/{p-b4caf042.js → p-eff93fbd.js} +1 -1
- package/www/build/vviinn-widgets.esm.js +1 -1
- package/www/index.html +1 -1
- package/dist/vviinn-widgets/p-ad29e9c5.entry.js +0 -1
- package/dist/vviinn-widgets/p-d2097302.entry.js +0 -1
- package/www/build/p-7c313f33.js +0 -125
- package/www/build/p-ad29e9c5.entry.js +0 -1
- package/www/build/p-d2097302.entry.js +0 -1
- package/www/build/p-e0153ae2.css +0 -6
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-07d3d672.js');
|
|
6
6
|
const Handler = require('./Handler-d1a8a86a.js');
|
|
7
7
|
|
|
8
8
|
const cropperHandlerCss = ":host{--size:20px;background:transparent;border:4px solid white;box-sizing:content-box;display:block;height:var(--size);touch-action:none;position:absolute;width:var(--size);z-index:4;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}:host(.disabled){opacity:0.25}:host(.nw-resize){border-bottom:none;border-right:none;top:0;left:0}:host(.ne-resize){border-left:none;border-bottom:none;right:0;top:0}:host(.sw-resize){border-right:none;border-top:none;left:0;bottom:0}:host(.se-resize){border-left:none;border-top:none;bottom:0;right:0}";
|
|
@@ -2,11 +2,11 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
6
|
-
const imageSearch_store = require('./imageSearch.store-
|
|
5
|
+
const index = require('./index-07d3d672.js');
|
|
6
|
+
const imageSearch_store = require('./imageSearch.store-e11fb912.js');
|
|
7
7
|
const Handler = require('./Handler-d1a8a86a.js');
|
|
8
|
-
const index$1 = require('./index-
|
|
9
|
-
const customizedSlots = require('./customized-slots-
|
|
8
|
+
const index$1 = require('./index-7e558d0b.js');
|
|
9
|
+
const customizedSlots = require('./customized-slots-dc70586b.js');
|
|
10
10
|
|
|
11
11
|
// -------------------------------------------------------------------------------------
|
|
12
12
|
// -------------------------------------------------------------------------------------
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
const index = require('./index-
|
|
3
|
+
const index = require('./index-07d3d672.js');
|
|
4
4
|
const Handler = require('./Handler-d1a8a86a.js');
|
|
5
5
|
|
|
6
6
|
var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
|
|
@@ -21,7 +21,7 @@ function _interopNamespace(e) {
|
|
|
21
21
|
}
|
|
22
22
|
|
|
23
23
|
const NAMESPACE = 'vviinn-widgets';
|
|
24
|
-
const Env = /* vviinn-widgets */ {"packageVersion":"2.4.
|
|
24
|
+
const Env = /* vviinn-widgets */ {"packageVersion":"2.4.4","packageName":"vviinn-widgets","environment":"local"};
|
|
25
25
|
|
|
26
26
|
let scopeId;
|
|
27
27
|
let hostTagName;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
const imageSearch_store = require('./imageSearch.store-
|
|
3
|
+
const imageSearch_store = require('./imageSearch.store-e11fb912.js');
|
|
4
4
|
|
|
5
5
|
// Unique ID creation requires a high quality random # generator. In the browser we therefore
|
|
6
6
|
// require the crypto API and do not support built-in fallback to lower quality random number
|
|
@@ -3172,6 +3172,7 @@ const createTrackingEvent = (widget) => (eventData) => {
|
|
|
3172
3172
|
return Object.assign(Object.assign({}, eventData), widget);
|
|
3173
3173
|
};
|
|
3174
3174
|
|
|
3175
|
+
const PRODUCT_CLICK_EVENT_TYPE = "product_click_event";
|
|
3175
3176
|
const PRODUCT_VIEW_EVENT_TYPE = "product_view_event";
|
|
3176
3177
|
const FILTER_EVENT_EVENT_TYPE = "filter_event";
|
|
3177
3178
|
const SEARCH_EVENT_EVENT_TYPE = "search_event";
|
|
@@ -3190,6 +3191,14 @@ const vpsProductView = {
|
|
|
3190
3191
|
widget: "VPS",
|
|
3191
3192
|
typ: PRODUCT_VIEW_EVENT_TYPE,
|
|
3192
3193
|
};
|
|
3194
|
+
const vprProductClick = {
|
|
3195
|
+
widget: "VPR",
|
|
3196
|
+
typ: PRODUCT_CLICK_EVENT_TYPE,
|
|
3197
|
+
};
|
|
3198
|
+
const vpsProductClick = {
|
|
3199
|
+
widget: "VPS",
|
|
3200
|
+
typ: PRODUCT_CLICK_EVENT_TYPE,
|
|
3201
|
+
};
|
|
3193
3202
|
|
|
3194
3203
|
const searchEvent = {
|
|
3195
3204
|
widget: "VPS",
|
|
@@ -3207,12 +3216,16 @@ const vpsWidget = {
|
|
|
3207
3216
|
|
|
3208
3217
|
const createProductViewVprEvent = createTrackingEvent(vprProductView);
|
|
3209
3218
|
const createProductViewVpsEvent = createTrackingEvent(vpsProductView);
|
|
3219
|
+
const createProductClickVprEvent = createTrackingEvent(vprProductClick);
|
|
3220
|
+
const createProductClickVpsEvent = createTrackingEvent(vpsProductClick);
|
|
3210
3221
|
const createWidgetVprEvent = createTrackingEvent(vprWidget);
|
|
3211
3222
|
const createWidgetVpsEvent = createTrackingEvent(vpsWidget);
|
|
3212
3223
|
const createSearchEvent = createTrackingEvent(searchEvent);
|
|
3213
3224
|
const createFilterEvent = createTrackingEvent(filterEvent);
|
|
3214
3225
|
|
|
3215
3226
|
exports.createFilterEvent = createFilterEvent;
|
|
3227
|
+
exports.createProductClickVprEvent = createProductClickVprEvent;
|
|
3228
|
+
exports.createProductClickVpsEvent = createProductClickVpsEvent;
|
|
3216
3229
|
exports.createProductViewVprEvent = createProductViewVprEvent;
|
|
3217
3230
|
exports.createProductViewVpsEvent = createProductViewVpsEvent;
|
|
3218
3231
|
exports.createSearchEvent = createSearchEvent;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
const index = require('./index-
|
|
3
|
+
const index = require('./index-07d3d672.js');
|
|
4
4
|
|
|
5
5
|
const ArrowIcon = () => (index.h("svg", { width: "12", height: "20", fill: "none", xmlns: "http://www.w3.org/2000/svg" },
|
|
6
6
|
index.h("path", { d: "M0 10 10 0l1.4 1.4L2.8 10l8.6 8.6L10 20 0 10Z" })));
|
package/dist/cjs/loader.cjs.js
CHANGED
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
6
|
-
const appGlobals = require('./app-globals-
|
|
5
|
+
const index = require('./index-07d3d672.js');
|
|
6
|
+
const appGlobals = require('./app-globals-af9e1c96.js');
|
|
7
7
|
|
|
8
8
|
/*
|
|
9
9
|
Stencil Client Patch Esm v2.9.0 | MIT Licensed | https://stenciljs.com
|
|
@@ -2,11 +2,11 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
6
|
-
const imageSearch_store = require('./imageSearch.store-
|
|
7
|
-
const index$1 = require('./index-
|
|
5
|
+
const index = require('./index-07d3d672.js');
|
|
6
|
+
const imageSearch_store = require('./imageSearch.store-e11fb912.js');
|
|
7
|
+
const index$1 = require('./index-7e558d0b.js');
|
|
8
8
|
const Handler = require('./Handler-d1a8a86a.js');
|
|
9
|
-
const index$2 = require('./index-
|
|
9
|
+
const index$2 = require('./index-135d1612.js');
|
|
10
10
|
|
|
11
11
|
const vviinnCarouselCss = ":host{--vviinn-progressbar-width:0;--vviinn-carousel-item-width:150px;--vviinn-carousel-columns-internal:var(--vviinn-carousel-columns, 4);--vviinn-carousel-image-width-system:140px}.body{display:flex;position:relative;width:var(--vviinn-carousel-content-width);flex-direction:column}.content-wrapper *{box-sizing:border-box}.content-wrapper{overflow-y:hidden;overflow-x:auto;flex-grow:1}.bullets{margin-top:16px;display:flex;flex-direction:row;grid-gap:24px;justify-content:center}.bullet{width:10px;height:10px;background:#E0E0E0;border-radius:50%;cursor:pointer}.bullet.active{background:#161616}.content:not(.show-scrollbar),.content.grid{scrollbar-color:#fff0 #fff0}.content:not(.show-scrollbar)::-webkit-scrollbar,.content.grid::-webkit-scrollbar{opacity:0}.content{display:flex;flex-direction:row;grid-gap:8px;-ms-scroll-snap-type:x mandatory;scroll-snap-type:x mandatory;overflow-y:hidden;overflow-x:auto;flex-grow:1;padding-bottom:16px}.content.left>*{scroll-snap-align:start}.content.right>*{scroll-snap-align:end}:host(.continuity) button{border-radius:2px}:host(.grid) button{border-radius:50%}button{align-items:center;background-color:white;border:none;box-shadow:0px 2px 6px rgba(0, 0, 0, 0.15);cursor:pointer;display:grid;height:40px;justify-items:center;position:absolute;top:calc(50% - 20px);width:40px;z-index:1;padding:0;margin:0}button{fill:#525252}button.prev svg{transform:rotate(180deg);margin-left:-5px}.prev{left:0}.next{right:0}.items-group{display:grid;grid-gap:16px;grid-template-columns:repeat(var(--vviinn-carousel-columns-internal), 1fr);min-width:100%}vviinn-product-card::part(price-container){text-align:center}:host(.classic) vviinn-product-card::part(title),:host(.classic) vviinn-product-card::part(brand),:host(.classic) vviinn-product-card::part(type){text-align:center}@media (max-width: 480px){:host(.modern) button{display:none}.items-group{grid-template-columns:repeat(2, 1fr)}}";
|
|
12
12
|
|
|
@@ -341,7 +341,7 @@ let VviinnProductCard = class {
|
|
|
341
341
|
connectedCallback() {
|
|
342
342
|
this.productData = {
|
|
343
343
|
product: this.productId,
|
|
344
|
-
rank: this.index
|
|
344
|
+
rank: this.index,
|
|
345
345
|
};
|
|
346
346
|
}
|
|
347
347
|
intersectionCallback(data) {
|
|
@@ -355,19 +355,11 @@ let VviinnProductCard = class {
|
|
|
355
355
|
this.recommendationLoad.emit(this.productData);
|
|
356
356
|
this.intersectionObserver.observe(this.el);
|
|
357
357
|
const links = this.el.shadowRoot.querySelectorAll("a");
|
|
358
|
-
links.forEach((link) => link.addEventListener("
|
|
358
|
+
links.forEach((link) => link.addEventListener("click", (event) => {
|
|
359
|
+
event.preventDefault();
|
|
360
|
+
event.stopImmediatePropagation();
|
|
359
361
|
this.recommendationClick.emit(this.productData);
|
|
360
|
-
if (window.ga) {
|
|
361
|
-
event.preventDefault();
|
|
362
|
-
}
|
|
363
362
|
imageSearch_store._function.pipe(getAnalyticsModule, imageSearch_store.Option.match(() => null, (analytics) => analytics.sendClick(this.getProduct())));
|
|
364
|
-
if (window.ga) {
|
|
365
|
-
ga("send", "event", "UX", "click", "Results", {
|
|
366
|
-
hitCallback: function () {
|
|
367
|
-
document.location.href = this.deeplink;
|
|
368
|
-
},
|
|
369
|
-
});
|
|
370
|
-
}
|
|
371
363
|
}));
|
|
372
364
|
}
|
|
373
365
|
getProduct() {
|
|
@@ -1085,9 +1077,13 @@ let VviinnVprWidget = class {
|
|
|
1085
1077
|
const recommendationViewEvent = index$2.createProductViewVprEvent(Object.assign({ session_id: this.uiSessionId }, detail));
|
|
1086
1078
|
this.trackingApi.trackEvent(recommendationViewEvent);
|
|
1087
1079
|
}
|
|
1088
|
-
trackRecommendationClick({ detail }) {
|
|
1089
|
-
const recommendationClickEvent = index$2.
|
|
1090
|
-
this.trackingApi.trackEvent(recommendationClickEvent);
|
|
1080
|
+
async trackRecommendationClick({ detail }) {
|
|
1081
|
+
const recommendationClickEvent = index$2.createProductClickVprEvent(Object.assign({ session_id: this.uiSessionId }, detail));
|
|
1082
|
+
await this.trackingApi.trackEvent(recommendationClickEvent);
|
|
1083
|
+
const product = this.recommendations.find((r) => r.productId === detail.product);
|
|
1084
|
+
if (!product || !product.deeplink)
|
|
1085
|
+
return;
|
|
1086
|
+
window.location.href = product.deeplink;
|
|
1091
1087
|
}
|
|
1092
1088
|
connectedCallback() {
|
|
1093
1089
|
imageSearch_store.state.apiPath = this.apiPath;
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
5
|
+
const index = require('./index-07d3d672.js');
|
|
6
6
|
|
|
7
7
|
const vviinnErrorCss = ":host{background:#F4F4F4;border-radius:8px;display:grid;grid-gap:20px;padding:24px;text-align:center}::slotted(svg){display:grid;align-self:center}::slotted(h4){margin:unset;font-weight:600;font-size:18px;line-height:24px}::slotted(span){font-size:14px;line-height:20px}::slotted(button){-webkit-appearance:none;-moz-appearance:none;appearance:none;border:none;background:transparent;color:var(--color-primary, var(--color-primary-system));font-weight:600;font-size:16px;line-height:20px;cursor:pointer}";
|
|
8
8
|
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
6
|
-
const imageSearch_store = require('./imageSearch.store-
|
|
5
|
+
const index = require('./index-07d3d672.js');
|
|
6
|
+
const imageSearch_store = require('./imageSearch.store-e11fb912.js');
|
|
7
7
|
require('./Handler-d1a8a86a.js');
|
|
8
8
|
|
|
9
9
|
const vviinnPreloaderCss = ":host{--preloader-size:24px;--preloader-width:calc(var(--preloader-size) / 6);transform-origin:center;-webkit-animation:rotate 3s linear infinite;animation:rotate 3s linear infinite;border:var(--preloader-width) solid white;border-radius:50%;border-top-color:transparent;display:none;outline:0;width:var(--preloader-size);height:var(--preloader-size);box-sizing:border-box}:host(.active){display:flex}@-webkit-keyframes rotate{from{transform:rotate(-360deg)}to{transform:rotate(360deg)}}@keyframes rotate{from{transform:rotate(-360deg)}to{transform:rotate(360deg)}}";
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
6
|
-
const index$1 = require('./index-
|
|
5
|
+
const index = require('./index-07d3d672.js');
|
|
6
|
+
const index$1 = require('./index-7e558d0b.js');
|
|
7
7
|
|
|
8
8
|
const recommendationsSidebarCss = ":host{--vviinn-carousel-columns:0;box-sizing:border-box;display:block;display:flex;height:100vh;left:0;position:fixed;top:0;transition:background 0.1s ease-in-out;width:100vw}:host(.open){background:rgba(0, 0, 0, 0.2)}:host(.bottom){flex-direction:column;justify-content:end}:host(.right){flex-direction:row;justify-content:flex-end}header{position:relative;text-align:center;padding:32px}header.contains-source-img{display:grid;justify-items:center;grid-gap:12px}img.source-image{width:64px;height:64px;border-radius:50%;box-shadow:0px 2px 4px rgba(0, 0, 0, 0.15);padding:8px}:host(.right) header{box-shadow:0px 2px 6px rgba(0, 0, 0, 0.1)}main{padding:0 24px}:host(.right) main{overflow:auto}.sidebar{background:white;box-sizing:border-box;display:flex;flex-direction:column}:host(.bottom.idle) .sidebar,:host(.bottom.closed) .sidebar{transform:translateY(100%)}:host(.bottom.closed) .sidebar{-webkit-animation-name:slideOutFromBottom;animation-name:slideOutFromBottom;-webkit-animation-duration:0.5s;animation-duration:0.5s;-webkit-animation-fill-mode:forwards;animation-fill-mode:forwards}:host(.bottom.open) .sidebar{-webkit-animation-name:slideInFromBottom;animation-name:slideInFromBottom;-webkit-animation-duration:0.5s;animation-duration:0.5s;-webkit-animation-fill-mode:forwards;animation-fill-mode:forwards}:host(.right.idle) .sidebar{transform:translateX(100%)}:host(.right.closed) .sidebar{-webkit-animation-name:slideOutFromRight;animation-name:slideOutFromRight;-webkit-animation-duration:0.5s;animation-duration:0.5s;-webkit-animation-fill-mode:forwards;animation-fill-mode:forwards}:host(.right.open) .sidebar{-webkit-animation-name:slideInFromRight;animation-name:slideInFromRight;-webkit-animation-duration:0.5s;animation-duration:0.5s;-webkit-animation-fill-mode:forwards;animation-fill-mode:forwards}:host(.right) .sidebar{max-width:480px}:host(.right) vviinn-vpr-widget::part(recommendations-grid){display:grid;grid-template-columns:repeat(2, 1fr);grid-gap:24px}:host(.right) vviinn-vpr-widget{overflow:auto}:host(.right) vviinn-vpr-widget::part(image){border:none}.title{font-style:normal;font-weight:500;font-size:28px;line-height:40px;text-align:center;color:#000000}vviinn-vpr-widget::part(title),vviinn-vpr-widget::part(brand),vviinn-vpr-widget::part(type){text-align:left}vviinn-vpr-widget::part(price-container){align-self:start}.close-sidebar{background:transparent;border:none;cursor:pointer;margin:0;padding:0;position:absolute;right:24px;top:24px}@-webkit-keyframes slideInFromBottom{from{transform:translateY(100%)}to{transform:translateY(0)}}@keyframes slideInFromBottom{from{transform:translateY(100%)}to{transform:translateY(0)}}@-webkit-keyframes slideOutFromBottom{from{transform:translateY(0)}to{transform:translateY(100%)}}@keyframes slideOutFromBottom{from{transform:translateY(0)}to{transform:translateY(100%)}}@-webkit-keyframes slideInFromRight{from{transform:translateX(100%)}to{transform:translateX(0)}}@keyframes slideInFromRight{from{transform:translateX(100%)}to{transform:translateX(0)}}@-webkit-keyframes slideOutFromRight{from{transform:translateX(0)}to{transform:translateX(100%)}}@keyframes slideOutFromRight{from{transform:translateX(0)}to{transform:translateX(100%)}}";
|
|
9
9
|
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
6
|
-
const index$1 = require('./index-
|
|
5
|
+
const index = require('./index-07d3d672.js');
|
|
6
|
+
const index$1 = require('./index-7e558d0b.js');
|
|
7
7
|
|
|
8
8
|
const vviinnVprButtonCss = ":host{display:block}.open-button{align-items:center;background:rgba(255, 255, 255, 0.8);border-radius:50%;border:none;box-shadow:0px 2px 6px rgba(0, 0, 0, 0.15);box-sizing:border-box;cursor:pointer;display:grid;height:40px;justify-items:center;padding:0;width:40px;transition:all 0.25s ease-in-out}.open-button:hover{box-shadow:0px 2px 6px rgba(0, 0, 0, 0.25)}.open-button:focus{border:2px solid rgba(15, 98, 254, 0.5);outline:none}.open-button:active{background:#F4F4F4;outline:none}";
|
|
9
9
|
|
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
6
|
-
const index$1 = require('./index-
|
|
7
|
-
const customizedSlots = require('./customized-slots-
|
|
5
|
+
const index = require('./index-07d3d672.js');
|
|
6
|
+
const index$1 = require('./index-7e558d0b.js');
|
|
7
|
+
const customizedSlots = require('./customized-slots-dc70586b.js');
|
|
8
8
|
|
|
9
9
|
const vviinnVpsButtonCss = ":host{cursor:pointer}";
|
|
10
10
|
|
|
@@ -2,10 +2,10 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
const index = require('./index-
|
|
6
|
-
const imageSearch_store = require('./imageSearch.store-
|
|
7
|
-
const customizedSlots = require('./customized-slots-
|
|
8
|
-
const index$1 = require('./index-
|
|
5
|
+
const index = require('./index-07d3d672.js');
|
|
6
|
+
const imageSearch_store = require('./imageSearch.store-e11fb912.js');
|
|
7
|
+
const customizedSlots = require('./customized-slots-dc70586b.js');
|
|
8
|
+
const index$1 = require('./index-135d1612.js');
|
|
9
9
|
require('./Handler-d1a8a86a.js');
|
|
10
10
|
|
|
11
11
|
const vviinnVpsWidgetCss = ":host{--color-primary-system:#0F62FE;--color-primary-hover-system:#014CDA;--color-icons-system:#2F8EDF;--spacer:8px}:host{display:block}.hidden{visibility:hidden;height:1px}vviinn-overlayed-modal.first-screen::part(title),vviinn-overlayed-modal.first-screen::part(secondary-action){visibility:hidden}.start-page{display:grid;grid-template-columns:repeat(2, 1fr);min-height:580px}.start-page_block{align-content:start;border-right:1px solid #F4F4F4;display:grid;padding:48px}.start-page_block.error{align-content:center}#onboarding-block{border-right:unset;box-sizing:border-box;grid-gap:24px;overflow-y:auto;position:relative;width:100%}vviinn-teaser{margin-bottom:32px;margin-top:-24px}vviinn-image-selector{align-items:center;background:var(--color-primary, var(--color-primary-system));border-color:var(--color-primary, var(--color-primary-system));border-radius:2px;color:white;display:grid;font-size:16px;font-weight:600;height:56px;justify-items:center;margin-bottom:16px;transition:background 0.1s ease-in-out}vviinn-image-selector:hover{background:var(--color-primary-hover, var(--color-primary-hover-system));border-color:var(--color-primary-hover, var(--color-primary-hover-system))}vviinn-image-selector:active{border-color:black}.upload-button-content{display:grid;align-items:center;justify-items:start;justify-content:center;grid-template-columns:-webkit-max-content auto;grid-template-columns:max-content auto;grid-gap:16px}.results-page{display:grid;grid-template-columns:336px auto;box-sizing:border-box}.results-page>*{padding:24px;box-sizing:border-box}.products{align-content:center;align-items:start;box-sizing:border-box;display:grid;grid-gap:32px 16px;grid-template-columns:repeat(auto-fill, minmax(152px, 1fr));justify-items:center;padding:24px;padding-right:0;position:absolute;width:calc(100% - 16px)}.products.hidden{display:none}vviinn-empty-results{width:280px;align-self:center;justify-self:center}.products-wrapper{display:grid;overflow-y:auto;overflow-x:hidden;padding:unset;position:relative;width:100%}.image-wrapper{border-right:1px solid #F4F4F4;display:grid;grid-template-rows:-webkit-min-content 170px;grid-template-rows:min-content 170px;grid-gap:24px;min-width:100%}.onboarding-wrapper{position:absolute;width:100%;padding:48px;box-sizing:border-box;display:grid;grid-gap:64px;padding-bottom:24px}vviinn-product-card{gap:0;width:100%}vviinn-product-card::part(image){border:1px solid #eaeaea;margin-bottom:8px}vviinn-product-card::part(price-container),vviinn-product-card::part(deeplink),vviinn-product-card::part(title){align-self:start}search-filters span{display:none}search-filters::part(filter){background:#F4F4F4;border-radius:4px;border:1px solid #F4F4F4;box-sizing:border-box;color:#161616;font-size:14px;font-weight:600;line-height:20px}search-filters::part(show-more-filters){border:1px solid #f4f4f4;border-radius:4px;box-sizing:border-box;color:#161616;font-size:14px;font-weight:600;line-height:20px;padding:6px 16px}search-filters::part(show-more-filters):hover{background:#EAEAEA}search-filters::part(filter):hover{background:#EAEAEA}search-filters::part(filter):focus{outline:none;border:1px solid var(--color-primary, var(--color-primary-system))}search-filters::part(filter active){background:rgba(15, 98, 254, 0.15);color:var(--color-primary, var(--color-primary-system))}.filters-wrapper{overflow:auto}.results-page:not(.active){display:none}.nothing-found{display:grid;grid-gap:64px;justify-self:center;padding-top:64px;padding-bottom:16px;position:absolute;width:60%}@media (max-width: 768px){.start-page_block{padding:24px}.onboarding-wrapper{padding:24px}}@media (max-width: 640px){.start-page{grid-template-rows:-webkit-min-content;grid-template-rows:min-content;grid-template-columns:unset;grid-gap:48px;padding:24px 0 48px 0}}@media (max-width: 640px) and (min-width: 415px){.onboarding-wrapper{position:unset}#onboarding-block{overflow:unset}.start-page.active{height:1px;overflow:auto}}@media (max-width: 415px){.results-page>*{box-sizing:border-box;padding:24px}vviinn-slide{padding-bottom:48px}.start-page_block:last-of-type{border-right:unset;overflow-y:unset;position:static;box-sizing:border-box;width:unset}.start-page_block{padding:0 24px}vviinn-teaser{margin-top:24px}.onboarding-wrapper{position:static;width:unset;padding:unset;box-sizing:border-box}.results-page{grid-template-columns:unset;grid-template-rows:-webkit-min-content auto;grid-template-rows:min-content auto}.image{margin-bottom:8px}.image-wrapper{grid-template-rows:-webkit-min-content auto;grid-template-rows:min-content auto;width:100%}.products-wrapper{align-content:start;position:static;overflow-y:unset;width:100%;padding-top:0}.products{position:static;padding:0;width:unset;grid-gap:32px 16px;justify-content:center}.nothing-found{position:static;grid-gap:64px;padding:unset;align-content:start;width:unset}}@media (max-width: 320px){.products{grid-template-columns:unset}}vviinn-wrong-format,vviinn-server-error{width:280px;align-self:center;justify-self:center}";
|
|
@@ -40,9 +40,13 @@ let VviinnVpsWidget = class {
|
|
|
40
40
|
const recommendationViewEvent = index$1.createProductViewVpsEvent(Object.assign({ session_id: this.uiSessionId }, detail));
|
|
41
41
|
this.trackingApi.trackEvent(recommendationViewEvent);
|
|
42
42
|
}
|
|
43
|
-
trackRecommendationClick({ detail }) {
|
|
44
|
-
const recommendationClickEvent = index$1.
|
|
45
|
-
this.trackingApi.trackEvent(recommendationClickEvent);
|
|
43
|
+
async trackRecommendationClick({ detail }) {
|
|
44
|
+
const recommendationClickEvent = index$1.createProductClickVpsEvent(Object.assign({ sessionId: this.uiSessionId }, detail));
|
|
45
|
+
await this.trackingApi.trackEvent(recommendationClickEvent);
|
|
46
|
+
const product = imageSearch_store.imageSearchState.results.find((r) => r.productId === detail.product);
|
|
47
|
+
if (!product || !product.deeplink)
|
|
48
|
+
return;
|
|
49
|
+
window.location.href = product.deeplink;
|
|
46
50
|
}
|
|
47
51
|
trachSearchAreaChanges() {
|
|
48
52
|
const searchEvent = index$1.createSearchEvent({
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
const index = require('./index-
|
|
4
|
-
const appGlobals = require('./app-globals-
|
|
3
|
+
const index = require('./index-07d3d672.js');
|
|
4
|
+
const appGlobals = require('./app-globals-af9e1c96.js');
|
|
5
5
|
|
|
6
6
|
/*
|
|
7
7
|
Stencil Client Patch Browser v2.9.0 | MIT Licensed | https://stenciljs.com
|
|
@@ -37,7 +37,7 @@ export class VviinnProductCard {
|
|
|
37
37
|
connectedCallback() {
|
|
38
38
|
this.productData = {
|
|
39
39
|
product: this.productId,
|
|
40
|
-
rank: this.index
|
|
40
|
+
rank: this.index,
|
|
41
41
|
};
|
|
42
42
|
}
|
|
43
43
|
intersectionCallback(data) {
|
|
@@ -51,19 +51,11 @@ export class VviinnProductCard {
|
|
|
51
51
|
this.recommendationLoad.emit(this.productData);
|
|
52
52
|
this.intersectionObserver.observe(this.el);
|
|
53
53
|
const links = this.el.shadowRoot.querySelectorAll("a");
|
|
54
|
-
links.forEach((link) => link.addEventListener("
|
|
54
|
+
links.forEach((link) => link.addEventListener("click", (event) => {
|
|
55
|
+
event.preventDefault();
|
|
56
|
+
event.stopImmediatePropagation();
|
|
55
57
|
this.recommendationClick.emit(this.productData);
|
|
56
|
-
if (window.ga) {
|
|
57
|
-
event.preventDefault();
|
|
58
|
-
}
|
|
59
58
|
pipe(getAnalyticsModule, O.match(() => null, (analytics) => analytics.sendClick(this.getProduct())));
|
|
60
|
-
if (window.ga) {
|
|
61
|
-
ga("send", "event", "UX", "click", "Results", {
|
|
62
|
-
hitCallback: function () {
|
|
63
|
-
document.location.href = this.deeplink;
|
|
64
|
-
},
|
|
65
|
-
});
|
|
66
|
-
}
|
|
67
59
|
}));
|
|
68
60
|
}
|
|
69
61
|
getProduct() {
|
|
@@ -9,7 +9,7 @@ import { imageSearchState } from "../../store/imageSearch.store";
|
|
|
9
9
|
import { Subject } from "rxjs";
|
|
10
10
|
import { v4 as uuidv4 } from "uuid";
|
|
11
11
|
import { createTrackingApi } from "../../openApi";
|
|
12
|
-
import { createProductViewVprEvent, createWidgetVprEvent, } from "../../tracking";
|
|
12
|
+
import { createProductClickVprEvent, createProductViewVprEvent, createWidgetVprEvent, } from "../../tracking";
|
|
13
13
|
/**
|
|
14
14
|
* @part product-card - product card itself
|
|
15
15
|
* @part title - title inside product card
|
|
@@ -68,9 +68,13 @@ export class VviinnVprWidget {
|
|
|
68
68
|
const recommendationViewEvent = createProductViewVprEvent(Object.assign({ session_id: this.uiSessionId }, detail));
|
|
69
69
|
this.trackingApi.trackEvent(recommendationViewEvent);
|
|
70
70
|
}
|
|
71
|
-
trackRecommendationClick({ detail }) {
|
|
72
|
-
const recommendationClickEvent =
|
|
73
|
-
this.trackingApi.trackEvent(recommendationClickEvent);
|
|
71
|
+
async trackRecommendationClick({ detail }) {
|
|
72
|
+
const recommendationClickEvent = createProductClickVprEvent(Object.assign({ session_id: this.uiSessionId }, detail));
|
|
73
|
+
await this.trackingApi.trackEvent(recommendationClickEvent);
|
|
74
|
+
const product = this.recommendations.find((r) => r.productId === detail.product);
|
|
75
|
+
if (!product || !product.deeplink)
|
|
76
|
+
return;
|
|
77
|
+
window.location.href = product.deeplink;
|
|
74
78
|
}
|
|
75
79
|
connectedCallback() {
|
|
76
80
|
state.apiPath = this.apiPath;
|
|
@@ -5,7 +5,7 @@ import * as O from "fp-ts/lib/Option";
|
|
|
5
5
|
import { slotChangeListener } from "../customized-slots";
|
|
6
6
|
import { v4 as uuidv4 } from "uuid";
|
|
7
7
|
import { createTrackingApi } from "../../openApi";
|
|
8
|
-
import { createFilterEvent, createProductViewVpsEvent, createSearchEvent, createWidgetVpsEvent, } from "../../tracking";
|
|
8
|
+
import { createFilterEvent, createProductClickVpsEvent, createProductViewVpsEvent, createSearchEvent, createWidgetVpsEvent, } from "../../tracking";
|
|
9
9
|
/**
|
|
10
10
|
* @prop --color-primary: color used for action button, slider bullets and selected detected object;
|
|
11
11
|
*
|
|
@@ -58,9 +58,13 @@ export class VviinnVpsWidget {
|
|
|
58
58
|
const recommendationViewEvent = createProductViewVpsEvent(Object.assign({ session_id: this.uiSessionId }, detail));
|
|
59
59
|
this.trackingApi.trackEvent(recommendationViewEvent);
|
|
60
60
|
}
|
|
61
|
-
trackRecommendationClick({ detail }) {
|
|
62
|
-
const recommendationClickEvent =
|
|
63
|
-
this.trackingApi.trackEvent(recommendationClickEvent);
|
|
61
|
+
async trackRecommendationClick({ detail }) {
|
|
62
|
+
const recommendationClickEvent = createProductClickVpsEvent(Object.assign({ sessionId: this.uiSessionId }, detail));
|
|
63
|
+
await this.trackingApi.trackEvent(recommendationClickEvent);
|
|
64
|
+
const product = imageSearchState.results.find((r) => r.productId === detail.product);
|
|
65
|
+
if (!product || !product.deeplink)
|
|
66
|
+
return;
|
|
67
|
+
window.location.href = product.deeplink;
|
|
64
68
|
}
|
|
65
69
|
trachSearchAreaChanges() {
|
|
66
70
|
const searchEvent = createSearchEvent({
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { r as registerInstance, h, H as Host } from './index-
|
|
1
|
+
import { r as registerInstance, h, H as Host } from './index-4600de03.js';
|
|
2
2
|
import { q as getCursorValue } from './Handler-639a4cb3.js';
|
|
3
3
|
|
|
4
4
|
const cropperHandlerCss = ":host{--size:20px;background:transparent;border:4px solid white;box-sizing:content-box;display:block;height:var(--size);touch-action:none;position:absolute;width:var(--size);z-index:4;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}:host(.disabled){opacity:0.25}:host(.nw-resize){border-bottom:none;border-right:none;top:0;left:0}:host(.ne-resize){border-left:none;border-bottom:none;right:0;top:0}:host(.sw-resize){border-right:none;border-top:none;left:0;bottom:0}:host(.se-resize){border-left:none;border-top:none;bottom:0;right:0}";
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { r as registerInstance, h, H as Host, c as createEvent, g as getElement } from './index-
|
|
2
|
-
import { O as Option, j as sequenceToOption, i as imageSearchState, a as _function, t as transform, k as move, l as makeRectangularSearchRequest, n as fromAlt, o as foldValueObject, p as scaleWithSized, q as center, r as detectedObjectEq, u as toFile, v as processSelectedFile, E as Either, w as match, x as fromImage, y as dimensionsFromImage, z as scaleByLargestSide, N as NonEmptyArray } from './imageSearch.store-
|
|
1
|
+
import { r as registerInstance, h, H as Host, c as createEvent, g as getElement } from './index-4600de03.js';
|
|
2
|
+
import { O as Option, j as sequenceToOption, i as imageSearchState, a as _function, t as transform, k as move, l as makeRectangularSearchRequest, n as fromAlt, o as foldValueObject, p as scaleWithSized, q as center, r as detectedObjectEq, u as toFile, v as processSelectedFile, E as Either, w as match, x as fromImage, y as dimensionsFromImage, z as scaleByLargestSide, N as NonEmptyArray } from './imageSearch.store-5e2c3094.js';
|
|
3
3
|
import { p as pipe, m as pointDiffSemigroup, o as fromMouseEvent } from './Handler-639a4cb3.js';
|
|
4
|
-
import { c as CheckIcon, O as OnboardingCard1Icon, d as OnboardingCard2Icon, e as OnboardingCard3Icon, A as ArrowIcon } from './index-
|
|
5
|
-
import { s as slotChangeListener } from './customized-slots-
|
|
4
|
+
import { c as CheckIcon, O as OnboardingCard1Icon, d as OnboardingCard2Icon, e as OnboardingCard3Icon, A as ArrowIcon } from './index-d0a661ce.js';
|
|
5
|
+
import { s as slotChangeListener } from './customized-slots-62974f69.js';
|
|
6
6
|
|
|
7
7
|
// -------------------------------------------------------------------------------------
|
|
8
8
|
// -------------------------------------------------------------------------------------
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { a as getRenderingRef, f as forceUpdate } from './index-
|
|
1
|
+
import { a as getRenderingRef, f as forceUpdate } from './index-4600de03.js';
|
|
2
2
|
import { t as tuple, i as isNone$1, l as left$1, r as right$1, a as isLeft$1, b as identity, p as pipe, n as none$1, s as some$1, f as first, c as flow, d as struct, e as last, g as pointSumSemigroup, H as HandlerDirection, h as fromRectangle, j as isSome, k as fromRectangle$1 } from './Handler-639a4cb3.js';
|
|
3
3
|
|
|
4
4
|
var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { e as commonjsGlobal, h as createCommonjsModule } from './imageSearch.store-
|
|
1
|
+
import { e as commonjsGlobal, h as createCommonjsModule } from './imageSearch.store-5e2c3094.js';
|
|
2
2
|
|
|
3
3
|
// Unique ID creation requires a high quality random # generator. In the browser we therefore
|
|
4
4
|
// require the crypto API and do not support built-in fallback to lower quality random number
|
|
@@ -3170,6 +3170,7 @@ const createTrackingEvent = (widget) => (eventData) => {
|
|
|
3170
3170
|
return Object.assign(Object.assign({}, eventData), widget);
|
|
3171
3171
|
};
|
|
3172
3172
|
|
|
3173
|
+
const PRODUCT_CLICK_EVENT_TYPE = "product_click_event";
|
|
3173
3174
|
const PRODUCT_VIEW_EVENT_TYPE = "product_view_event";
|
|
3174
3175
|
const FILTER_EVENT_EVENT_TYPE = "filter_event";
|
|
3175
3176
|
const SEARCH_EVENT_EVENT_TYPE = "search_event";
|
|
@@ -3188,6 +3189,14 @@ const vpsProductView = {
|
|
|
3188
3189
|
widget: "VPS",
|
|
3189
3190
|
typ: PRODUCT_VIEW_EVENT_TYPE,
|
|
3190
3191
|
};
|
|
3192
|
+
const vprProductClick = {
|
|
3193
|
+
widget: "VPR",
|
|
3194
|
+
typ: PRODUCT_CLICK_EVENT_TYPE,
|
|
3195
|
+
};
|
|
3196
|
+
const vpsProductClick = {
|
|
3197
|
+
widget: "VPS",
|
|
3198
|
+
typ: PRODUCT_CLICK_EVENT_TYPE,
|
|
3199
|
+
};
|
|
3191
3200
|
|
|
3192
3201
|
const searchEvent = {
|
|
3193
3202
|
widget: "VPS",
|
|
@@ -3205,9 +3214,11 @@ const vpsWidget = {
|
|
|
3205
3214
|
|
|
3206
3215
|
const createProductViewVprEvent = createTrackingEvent(vprProductView);
|
|
3207
3216
|
const createProductViewVpsEvent = createTrackingEvent(vpsProductView);
|
|
3217
|
+
const createProductClickVprEvent = createTrackingEvent(vprProductClick);
|
|
3218
|
+
const createProductClickVpsEvent = createTrackingEvent(vpsProductClick);
|
|
3208
3219
|
const createWidgetVprEvent = createTrackingEvent(vprWidget);
|
|
3209
3220
|
const createWidgetVpsEvent = createTrackingEvent(vpsWidget);
|
|
3210
3221
|
const createSearchEvent = createTrackingEvent(searchEvent);
|
|
3211
3222
|
const createFilterEvent = createTrackingEvent(filterEvent);
|
|
3212
3223
|
|
|
3213
|
-
export {
|
|
3224
|
+
export { createProductClickVprEvent as a, createTrackingApi as b, createProductViewVprEvent as c, createWidgetVprEvent as d, createProductViewVpsEvent as e, createProductClickVpsEvent as f, createSearchEvent as g, createFilterEvent as h, createWidgetVpsEvent as i, v4 as v };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
const NAMESPACE = 'vviinn-widgets';
|
|
2
|
-
const Env = /* vviinn-widgets */ {"packageVersion":"2.4.
|
|
2
|
+
const Env = /* vviinn-widgets */ {"packageVersion":"2.4.4","packageName":"vviinn-widgets","environment":"local"};
|
|
3
3
|
|
|
4
4
|
let scopeId;
|
|
5
5
|
let hostTagName;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { h } from './index-
|
|
1
|
+
import { h } from './index-4600de03.js';
|
|
2
2
|
|
|
3
3
|
const ArrowIcon = () => (h("svg", { width: "12", height: "20", fill: "none", xmlns: "http://www.w3.org/2000/svg" },
|
|
4
4
|
h("path", { d: "M0 10 10 0l1.4 1.4L2.8 10l8.6 8.6L10 20 0 10Z" })));
|
package/dist/esm/loader.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { p as promiseResolve, b as bootstrapLazy } from './index-
|
|
2
|
-
import { g as globalScripts } from './app-globals-
|
|
1
|
+
import { p as promiseResolve, b as bootstrapLazy } from './index-4600de03.js';
|
|
2
|
+
import { g as globalScripts } from './app-globals-c988b07f.js';
|
|
3
3
|
|
|
4
4
|
/*
|
|
5
5
|
Stencil Client Patch Esm v2.9.0 | MIT Licensed | https://stenciljs.com
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { r as registerInstance, h, H as Host, g as getElement, c as createEvent } from './index-
|
|
2
|
-
import { _ as _Array, O as Option, S as Semigroup, a as _function, E as Either, i as imageSearchState, s as state, c as chainW, m as makeRequest, f as fromEither, g as getApiPath, b as createInitGetRequest, d as sequenceT, A as Apply, T as TaskEither } from './imageSearch.store-
|
|
3
|
-
import { C as ChevronIcon } from './index-
|
|
1
|
+
import { r as registerInstance, h, H as Host, g as getElement, c as createEvent } from './index-4600de03.js';
|
|
2
|
+
import { _ as _Array, O as Option, S as Semigroup, a as _function, E as Either, i as imageSearchState, s as state, c as chainW, m as makeRequest, f as fromEither, g as getApiPath, b as createInitGetRequest, d as sequenceT, A as Apply, T as TaskEither } from './imageSearch.store-5e2c3094.js';
|
|
3
|
+
import { C as ChevronIcon } from './index-d0a661ce.js';
|
|
4
4
|
import { p as pipe } from './Handler-639a4cb3.js';
|
|
5
|
-
import { c as createProductViewVprEvent, v as v4,
|
|
5
|
+
import { c as createProductViewVprEvent, a as createProductClickVprEvent, v as v4, b as createTrackingApi, d as createWidgetVprEvent } from './index-412e5674.js';
|
|
6
6
|
|
|
7
7
|
const vviinnCarouselCss = ":host{--vviinn-progressbar-width:0;--vviinn-carousel-item-width:150px;--vviinn-carousel-columns-internal:var(--vviinn-carousel-columns, 4);--vviinn-carousel-image-width-system:140px}.body{display:flex;position:relative;width:var(--vviinn-carousel-content-width);flex-direction:column}.content-wrapper *{box-sizing:border-box}.content-wrapper{overflow-y:hidden;overflow-x:auto;flex-grow:1}.bullets{margin-top:16px;display:flex;flex-direction:row;grid-gap:24px;justify-content:center}.bullet{width:10px;height:10px;background:#E0E0E0;border-radius:50%;cursor:pointer}.bullet.active{background:#161616}.content:not(.show-scrollbar),.content.grid{scrollbar-color:#fff0 #fff0}.content:not(.show-scrollbar)::-webkit-scrollbar,.content.grid::-webkit-scrollbar{opacity:0}.content{display:flex;flex-direction:row;grid-gap:8px;-ms-scroll-snap-type:x mandatory;scroll-snap-type:x mandatory;overflow-y:hidden;overflow-x:auto;flex-grow:1;padding-bottom:16px}.content.left>*{scroll-snap-align:start}.content.right>*{scroll-snap-align:end}:host(.continuity) button{border-radius:2px}:host(.grid) button{border-radius:50%}button{align-items:center;background-color:white;border:none;box-shadow:0px 2px 6px rgba(0, 0, 0, 0.15);cursor:pointer;display:grid;height:40px;justify-items:center;position:absolute;top:calc(50% - 20px);width:40px;z-index:1;padding:0;margin:0}button{fill:#525252}button.prev svg{transform:rotate(180deg);margin-left:-5px}.prev{left:0}.next{right:0}.items-group{display:grid;grid-gap:16px;grid-template-columns:repeat(var(--vviinn-carousel-columns-internal), 1fr);min-width:100%}vviinn-product-card::part(price-container){text-align:center}:host(.classic) vviinn-product-card::part(title),:host(.classic) vviinn-product-card::part(brand),:host(.classic) vviinn-product-card::part(type){text-align:center}@media (max-width: 480px){:host(.modern) button{display:none}.items-group{grid-template-columns:repeat(2, 1fr)}}";
|
|
8
8
|
|
|
@@ -337,7 +337,7 @@ let VviinnProductCard = class {
|
|
|
337
337
|
connectedCallback() {
|
|
338
338
|
this.productData = {
|
|
339
339
|
product: this.productId,
|
|
340
|
-
rank: this.index
|
|
340
|
+
rank: this.index,
|
|
341
341
|
};
|
|
342
342
|
}
|
|
343
343
|
intersectionCallback(data) {
|
|
@@ -351,19 +351,11 @@ let VviinnProductCard = class {
|
|
|
351
351
|
this.recommendationLoad.emit(this.productData);
|
|
352
352
|
this.intersectionObserver.observe(this.el);
|
|
353
353
|
const links = this.el.shadowRoot.querySelectorAll("a");
|
|
354
|
-
links.forEach((link) => link.addEventListener("
|
|
354
|
+
links.forEach((link) => link.addEventListener("click", (event) => {
|
|
355
|
+
event.preventDefault();
|
|
356
|
+
event.stopImmediatePropagation();
|
|
355
357
|
this.recommendationClick.emit(this.productData);
|
|
356
|
-
if (window.ga) {
|
|
357
|
-
event.preventDefault();
|
|
358
|
-
}
|
|
359
358
|
_function.pipe(getAnalyticsModule, Option.match(() => null, (analytics) => analytics.sendClick(this.getProduct())));
|
|
360
|
-
if (window.ga) {
|
|
361
|
-
ga("send", "event", "UX", "click", "Results", {
|
|
362
|
-
hitCallback: function () {
|
|
363
|
-
document.location.href = this.deeplink;
|
|
364
|
-
},
|
|
365
|
-
});
|
|
366
|
-
}
|
|
367
359
|
}));
|
|
368
360
|
}
|
|
369
361
|
getProduct() {
|
|
@@ -1081,9 +1073,13 @@ let VviinnVprWidget = class {
|
|
|
1081
1073
|
const recommendationViewEvent = createProductViewVprEvent(Object.assign({ session_id: this.uiSessionId }, detail));
|
|
1082
1074
|
this.trackingApi.trackEvent(recommendationViewEvent);
|
|
1083
1075
|
}
|
|
1084
|
-
trackRecommendationClick({ detail }) {
|
|
1085
|
-
const recommendationClickEvent =
|
|
1086
|
-
this.trackingApi.trackEvent(recommendationClickEvent);
|
|
1076
|
+
async trackRecommendationClick({ detail }) {
|
|
1077
|
+
const recommendationClickEvent = createProductClickVprEvent(Object.assign({ session_id: this.uiSessionId }, detail));
|
|
1078
|
+
await this.trackingApi.trackEvent(recommendationClickEvent);
|
|
1079
|
+
const product = this.recommendations.find((r) => r.productId === detail.product);
|
|
1080
|
+
if (!product || !product.deeplink)
|
|
1081
|
+
return;
|
|
1082
|
+
window.location.href = product.deeplink;
|
|
1087
1083
|
}
|
|
1088
1084
|
connectedCallback() {
|
|
1089
1085
|
state.apiPath = this.apiPath;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { r as registerInstance, h, H as Host } from './index-
|
|
1
|
+
import { r as registerInstance, h, H as Host } from './index-4600de03.js';
|
|
2
2
|
|
|
3
3
|
const vviinnErrorCss = ":host{background:#F4F4F4;border-radius:8px;display:grid;grid-gap:20px;padding:24px;text-align:center}::slotted(svg){display:grid;align-self:center}::slotted(h4){margin:unset;font-weight:600;font-size:18px;line-height:24px}::slotted(span){font-size:14px;line-height:20px}::slotted(button){-webkit-appearance:none;-moz-appearance:none;appearance:none;border:none;background:transparent;color:var(--color-primary, var(--color-primary-system));font-weight:600;font-size:16px;line-height:20px;cursor:pointer}";
|
|
4
4
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { r as registerInstance, h, H as Host } from './index-
|
|
2
|
-
import { i as imageSearchState } from './imageSearch.store-
|
|
1
|
+
import { r as registerInstance, h, H as Host } from './index-4600de03.js';
|
|
2
|
+
import { i as imageSearchState } from './imageSearch.store-5e2c3094.js';
|
|
3
3
|
import './Handler-639a4cb3.js';
|
|
4
4
|
|
|
5
5
|
const vviinnPreloaderCss = ":host{--preloader-size:24px;--preloader-width:calc(var(--preloader-size) / 6);transform-origin:center;-webkit-animation:rotate 3s linear infinite;animation:rotate 3s linear infinite;border:var(--preloader-width) solid white;border-radius:50%;border-top-color:transparent;display:none;outline:0;width:var(--preloader-size);height:var(--preloader-size);box-sizing:border-box}:host(.active){display:flex}@-webkit-keyframes rotate{from{transform:rotate(-360deg)}to{transform:rotate(360deg)}}@keyframes rotate{from{transform:rotate(-360deg)}to{transform:rotate(360deg)}}";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { r as registerInstance, c as createEvent, h, H as Host, g as getElement } from './index-
|
|
2
|
-
import { b as CrossIcon } from './index-
|
|
1
|
+
import { r as registerInstance, c as createEvent, h, H as Host, g as getElement } from './index-4600de03.js';
|
|
2
|
+
import { b as CrossIcon } from './index-d0a661ce.js';
|
|
3
3
|
|
|
4
4
|
const recommendationsSidebarCss = ":host{--vviinn-carousel-columns:0;box-sizing:border-box;display:block;display:flex;height:100vh;left:0;position:fixed;top:0;transition:background 0.1s ease-in-out;width:100vw}:host(.open){background:rgba(0, 0, 0, 0.2)}:host(.bottom){flex-direction:column;justify-content:end}:host(.right){flex-direction:row;justify-content:flex-end}header{position:relative;text-align:center;padding:32px}header.contains-source-img{display:grid;justify-items:center;grid-gap:12px}img.source-image{width:64px;height:64px;border-radius:50%;box-shadow:0px 2px 4px rgba(0, 0, 0, 0.15);padding:8px}:host(.right) header{box-shadow:0px 2px 6px rgba(0, 0, 0, 0.1)}main{padding:0 24px}:host(.right) main{overflow:auto}.sidebar{background:white;box-sizing:border-box;display:flex;flex-direction:column}:host(.bottom.idle) .sidebar,:host(.bottom.closed) .sidebar{transform:translateY(100%)}:host(.bottom.closed) .sidebar{-webkit-animation-name:slideOutFromBottom;animation-name:slideOutFromBottom;-webkit-animation-duration:0.5s;animation-duration:0.5s;-webkit-animation-fill-mode:forwards;animation-fill-mode:forwards}:host(.bottom.open) .sidebar{-webkit-animation-name:slideInFromBottom;animation-name:slideInFromBottom;-webkit-animation-duration:0.5s;animation-duration:0.5s;-webkit-animation-fill-mode:forwards;animation-fill-mode:forwards}:host(.right.idle) .sidebar{transform:translateX(100%)}:host(.right.closed) .sidebar{-webkit-animation-name:slideOutFromRight;animation-name:slideOutFromRight;-webkit-animation-duration:0.5s;animation-duration:0.5s;-webkit-animation-fill-mode:forwards;animation-fill-mode:forwards}:host(.right.open) .sidebar{-webkit-animation-name:slideInFromRight;animation-name:slideInFromRight;-webkit-animation-duration:0.5s;animation-duration:0.5s;-webkit-animation-fill-mode:forwards;animation-fill-mode:forwards}:host(.right) .sidebar{max-width:480px}:host(.right) vviinn-vpr-widget::part(recommendations-grid){display:grid;grid-template-columns:repeat(2, 1fr);grid-gap:24px}:host(.right) vviinn-vpr-widget{overflow:auto}:host(.right) vviinn-vpr-widget::part(image){border:none}.title{font-style:normal;font-weight:500;font-size:28px;line-height:40px;text-align:center;color:#000000}vviinn-vpr-widget::part(title),vviinn-vpr-widget::part(brand),vviinn-vpr-widget::part(type){text-align:left}vviinn-vpr-widget::part(price-container){align-self:start}.close-sidebar{background:transparent;border:none;cursor:pointer;margin:0;padding:0;position:absolute;right:24px;top:24px}@-webkit-keyframes slideInFromBottom{from{transform:translateY(100%)}to{transform:translateY(0)}}@keyframes slideInFromBottom{from{transform:translateY(100%)}to{transform:translateY(0)}}@-webkit-keyframes slideOutFromBottom{from{transform:translateY(0)}to{transform:translateY(100%)}}@keyframes slideOutFromBottom{from{transform:translateY(0)}to{transform:translateY(100%)}}@-webkit-keyframes slideInFromRight{from{transform:translateX(100%)}to{transform:translateX(0)}}@keyframes slideInFromRight{from{transform:translateX(100%)}to{transform:translateX(0)}}@-webkit-keyframes slideOutFromRight{from{transform:translateX(0)}to{transform:translateX(100%)}}@keyframes slideOutFromRight{from{transform:translateX(0)}to{transform:translateX(100%)}}";
|
|
5
5
|
|