@depict-ai/ui 4.10.11 → 4.10.12
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/ES10/index.cjs +56 -27
- package/ES10/index.d.ts +25 -5
- package/ES10/index.js +56 -27
- package/latest/index.cjs +54 -27
- package/latest/index.d.ts +25 -5
- package/latest/index.js +54 -27
- package/package.json +4 -4
- package/server/ES10/index.cjs +56 -27
- package/server/ES10/index.d.ts +25 -5
- package/server/ES10/index.js +56 -27
- package/server/latest/index.cjs +54 -27
- package/server/latest/index.d.ts +25 -5
- package/server/latest/index.js +54 -27
package/server/ES10/index.js
CHANGED
|
@@ -10,7 +10,7 @@ import $b8hua$babelruntimehelpersclassPrivateFieldGet from "@babel/runtime/helpe
|
|
|
10
10
|
/*! Depict.ai search and product listing SDK */
|
|
11
11
|
import { register_es_version } from "../../multi_import_deduplicator.mjs";
|
|
12
12
|
register_es_version("ui", "ES10");
|
|
13
|
-
const $8db9a15135765c11$export$83d89fbfd8236492 = "4.10.
|
|
13
|
+
const $8db9a15135765c11$export$83d89fbfd8236492 = "4.10.12";
|
|
14
14
|
function $00a5b94f0c11efbb$export$d9f36cf74e24d595(media_query) {
|
|
15
15
|
const signal = $b8hua$createSignal(false);
|
|
16
16
|
$b8hua$onCleanup($b8hua$javascript_media_query(media_query, _ref => {
|
|
@@ -6481,7 +6481,7 @@ function $4df489344a0f97c7$export$e4b984597b71e989(props) {
|
|
|
6481
6481
|
})));
|
|
6482
6482
|
return container;
|
|
6483
6483
|
}
|
|
6484
|
-
const $98688279b9059f50$var$
|
|
6484
|
+
const $98688279b9059f50$var$defaultCustomUrls = (url, width) => {
|
|
6485
6485
|
var _url$startsWith;
|
|
6486
6486
|
if (url !== null && url !== void 0 && (_url$startsWith = url.startsWith) !== null && _url$startsWith !== void 0 && _url$startsWith.call(url, "https://cdn.shopify.com"))
|
|
6487
6487
|
// The shopify image resizing CDN blocks Cloudflare's image resizer. It's possible that we can't detect shopify image URLs sometimes because they go to the merchant's domain,
|
|
@@ -6491,18 +6491,23 @@ const $98688279b9059f50$var$customUrls = (url, width) => {
|
|
|
6491
6491
|
return "https://app.depict.ai/cdn-cgi/image/width=".concat(width, ",format=auto/").concat(url);
|
|
6492
6492
|
};
|
|
6493
6493
|
function $98688279b9059f50$export$9d4a4b669b1929ab(props) {
|
|
6494
|
+
var _props$imageResizer_;
|
|
6495
|
+
const resolvedCustomUrls = (_props$imageResizer_ = props.imageResizer_) !== null && _props$imageResizer_ !== void 0 ? _props$imageResizer_ : $98688279b9059f50$var$defaultCustomUrls;
|
|
6494
6496
|
return $b8hua$createComponent((0, $4df489344a0f97c7$export$e4b984597b71e989), $b8hua$mergeProps1(props, {
|
|
6495
6497
|
get imgProps() {
|
|
6496
6498
|
return {
|
|
6497
6499
|
...props.imgProps,
|
|
6498
|
-
customUrls:
|
|
6500
|
+
customUrls: resolvedCustomUrls
|
|
6499
6501
|
};
|
|
6500
6502
|
}
|
|
6501
6503
|
}));
|
|
6502
6504
|
}
|
|
6503
6505
|
function $98688279b9059f50$export$140423fa4bfb6d63(props) {
|
|
6504
6506
|
return $b8hua$createComponent((0, $56047603f9d212b6$export$6e5611bc7e57e477), $b8hua$mergeProps1(props, {
|
|
6505
|
-
customUrls
|
|
6507
|
+
get customUrls() {
|
|
6508
|
+
var _props$imageResizer_2;
|
|
6509
|
+
return (_props$imageResizer_2 = props.imageResizer_) !== null && _props$imageResizer_2 !== void 0 ? _props$imageResizer_2 : $98688279b9059f50$var$defaultCustomUrls;
|
|
6510
|
+
}
|
|
6506
6511
|
}));
|
|
6507
6512
|
}
|
|
6508
6513
|
var $3b772ef9a35560fe$var$_tmpl$ = ["<video", ' disablepictureinpicture="true" class="d-standard-content"></video>'];
|
|
@@ -6513,7 +6518,8 @@ function $3b772ef9a35560fe$export$780a853d15174484(_ref) {
|
|
|
6513
6518
|
router_: router_,
|
|
6514
6519
|
setAspectRatioWas_: setAspectRatioWas_,
|
|
6515
6520
|
mediaUrl_: mediaUrl_,
|
|
6516
|
-
aspectRatioWhenAloneInRow_: aspectRatioWhenAloneInRow_
|
|
6521
|
+
aspectRatioWhenAloneInRow_: aspectRatioWhenAloneInRow_,
|
|
6522
|
+
imageResizer_: imageResizer_
|
|
6517
6523
|
} = _ref;
|
|
6518
6524
|
let wroteAspectRatioToContainer = false; // Only write this once so we don't get into a aspect ratio changed -> size changed -> image source changed -> aspect ratio slightly changed infinite loop
|
|
6519
6525
|
const [wrapperSize, setWrapperSize] = $b8hua$createSignal();
|
|
@@ -6567,7 +6573,8 @@ function $3b772ef9a35560fe$export$780a853d15174484(_ref) {
|
|
|
6567
6573
|
},
|
|
6568
6574
|
src: mediaUrl_,
|
|
6569
6575
|
"class": "d-standard-content",
|
|
6570
|
-
onDecoded: () => setHasLoaded(true)
|
|
6576
|
+
onDecoded: () => setHasLoaded(true),
|
|
6577
|
+
imageResizer_: imageResizer_
|
|
6571
6578
|
});
|
|
6572
6579
|
}
|
|
6573
6580
|
}), $b8hua$createComponent((0, $b8hua$Match), {
|
|
@@ -6581,7 +6588,7 @@ function $3b772ef9a35560fe$export$780a853d15174484(_ref) {
|
|
|
6581
6588
|
}
|
|
6582
6589
|
}));
|
|
6583
6590
|
}
|
|
6584
|
-
function $12ff24fdc4b26d88$export$7a92d995f1bf3592(history_content_blocks_, plp_meta, content_blocks_by_row_, router_, products_request_loading_) {
|
|
6591
|
+
function $12ff24fdc4b26d88$export$7a92d995f1bf3592(history_content_blocks_, plp_meta, content_blocks_by_row_, router_, products_request_loading_, imageResizer_) {
|
|
6585
6592
|
let hasSeenContentBlock = false;
|
|
6586
6593
|
const [historyContentBlocks, setHistoryContentBlocks] = history_content_blocks_;
|
|
6587
6594
|
const contentComponents = new Map();
|
|
@@ -6637,7 +6644,8 @@ function $12ff24fdc4b26d88$export$7a92d995f1bf3592(history_content_blocks_, plp_
|
|
|
6637
6644
|
...prev.aspectRatios,
|
|
6638
6645
|
[componentCacheKey]: Math.round(aspectRatio * 100) / 100
|
|
6639
6646
|
}
|
|
6640
|
-
}))
|
|
6647
|
+
})),
|
|
6648
|
+
imageResizer_: imageResizer_
|
|
6641
6649
|
});
|
|
6642
6650
|
contentComponents.set(componentCacheKey, component);
|
|
6643
6651
|
}
|
|
@@ -6702,7 +6710,8 @@ function $4b4b262708b516ee$export$f7d2f673fc2f091d(_ref) {
|
|
|
6702
6710
|
filterModalParent_: filterModalParent_,
|
|
6703
6711
|
showSliderArrow_: showSliderArrow_,
|
|
6704
6712
|
hideCount0FilterOptions_: hideCount0FilterOptions_,
|
|
6705
|
-
switchToFiltersDrawerBreakpoint_: switchToFiltersDrawerBreakpoint_
|
|
6713
|
+
switchToFiltersDrawerBreakpoint_: switchToFiltersDrawerBreakpoint_,
|
|
6714
|
+
imageResizer_: imageResizer_
|
|
6706
6715
|
} = _ref;
|
|
6707
6716
|
let results_for;
|
|
6708
6717
|
let only_show_filters_opener_;
|
|
@@ -6798,7 +6807,7 @@ function $4b4b262708b516ee$export$f7d2f673fc2f091d(_ref) {
|
|
|
6798
6807
|
setMetaRequestsForQuery(prev => prev.set(query.id_type_ + query.id_to_query_for_, listing));
|
|
6799
6808
|
return result;
|
|
6800
6809
|
}));
|
|
6801
|
-
const contentBlocksByRow = $12ff24fdc4b26d88$export$7a92d995f1bf3592(history_content_blocks_, plp_meta, content_blocks_by_row_, router_, () => plp_products_.loading);
|
|
6810
|
+
const contentBlocksByRow = $12ff24fdc4b26d88$export$7a92d995f1bf3592(history_content_blocks_, plp_meta, content_blocks_by_row_, router_, () => plp_products_.loading, imageResizer_);
|
|
6802
6811
|
const countOfProductsForUI = $0728458b46ee9d32$export$a86bc18439445599(plp_products_, all_products_loaded_, currentlyLoadedDisplays);
|
|
6803
6812
|
const available_sortings_ = $b8hua$createMemo(() => {
|
|
6804
6813
|
var _plp_products_, _plp_products_$sorts;
|
|
@@ -7343,7 +7352,8 @@ function $f84b097e079b0a33$export$b73ed90f0ee50dc3(_ref) {
|
|
|
7343
7352
|
outerRef_: outerRef_,
|
|
7344
7353
|
animationDuration_: animationDuration_,
|
|
7345
7354
|
priceFormatting_: priceFormatting_,
|
|
7346
|
-
pseudoRouter_: pseudoRouter_
|
|
7355
|
+
pseudoRouter_: pseudoRouter_,
|
|
7356
|
+
imageResizer_: imageResizer_
|
|
7347
7357
|
} = _ref;
|
|
7348
7358
|
const variantToUse = $b8hua$createMemo(() => {
|
|
7349
7359
|
const display = display_();
|
|
@@ -7409,7 +7419,8 @@ function $f84b097e079b0a33$export$b73ed90f0ee50dc3(_ref) {
|
|
|
7409
7419
|
},
|
|
7410
7420
|
imgProps: {
|
|
7411
7421
|
keyRatioUpdating: true
|
|
7412
|
-
}
|
|
7422
|
+
},
|
|
7423
|
+
imageResizer_: imageResizer_
|
|
7413
7424
|
});
|
|
7414
7425
|
}
|
|
7415
7426
|
})));
|
|
@@ -7562,7 +7573,8 @@ function $275d06a183ca0a29$export$ebf0b1d4f90c09ae(_ref) {
|
|
|
7562
7573
|
supportsHover_: supportsHover_,
|
|
7563
7574
|
priceFormatting_: priceFormatting_,
|
|
7564
7575
|
pseudoRouter_: pseudoRouter_,
|
|
7565
|
-
containerHeight_: containerHeight_
|
|
7576
|
+
containerHeight_: containerHeight_,
|
|
7577
|
+
imageResizer_: imageResizer_
|
|
7566
7578
|
} = _ref;
|
|
7567
7579
|
let isAffectedByChromeBug = false;
|
|
7568
7580
|
// If the user requests the drawer to be expanded or not
|
|
@@ -7598,6 +7610,7 @@ function $275d06a183ca0a29$export$ebf0b1d4f90c09ae(_ref) {
|
|
|
7598
7610
|
userWantsExpandedSignal_: userWantsExpandedSignal_,
|
|
7599
7611
|
textFadeInAnimationRunning_: textFadeInAnimationRunning,
|
|
7600
7612
|
priceFormatting_: priceFormatting_,
|
|
7613
|
+
imageResizer_: imageResizer_,
|
|
7601
7614
|
outerRef_: el => $b8hua$createEffect(() => {
|
|
7602
7615
|
if (index !== 0) return;
|
|
7603
7616
|
const resizeObserver = new ResizeObserver($b8hua$catchify1(records => setLookItemHeight(records.at(-1).contentRect.height)));
|
|
@@ -7641,7 +7654,8 @@ function $22dd375b476673e2$export$44809a8a3e867e30(_ref) {
|
|
|
7641
7654
|
placeholderImageAspectRatio_: placeholderImageAspectRatio_,
|
|
7642
7655
|
animationDuration_: animationDuration_,
|
|
7643
7656
|
priceFormatting_: priceFormatting_,
|
|
7644
|
-
pseudoRouter_: pseudoRouter_
|
|
7657
|
+
pseudoRouter_: pseudoRouter_,
|
|
7658
|
+
imageResizer_: imageResizer_
|
|
7645
7659
|
} = _ref;
|
|
7646
7660
|
let container;
|
|
7647
7661
|
const useWantsExpandedSignal_ = $b8hua$createSignal(false);
|
|
@@ -7709,7 +7723,8 @@ function $22dd375b476673e2$export$44809a8a3e867e30(_ref) {
|
|
|
7709
7723
|
return (_display_ = display_()) === null || _display_ === void 0 ? void 0 : (_display_$image_urls = _display_.image_urls) === null || _display_$image_urls === void 0 ? void 0 : _display_$image_urls[0];
|
|
7710
7724
|
},
|
|
7711
7725
|
aspectRatio: placeholderImageAspectRatio_,
|
|
7712
|
-
autoAdjustAspectRatio: true
|
|
7726
|
+
autoAdjustAspectRatio: true,
|
|
7727
|
+
imageResizer_: imageResizer_
|
|
7713
7728
|
});
|
|
7714
7729
|
}
|
|
7715
7730
|
})), $b8hua$escape($b8hua$createComponent((0, $275d06a183ca0a29$export$ebf0b1d4f90c09ae), {
|
|
@@ -7724,7 +7739,8 @@ function $22dd375b476673e2$export$44809a8a3e867e30(_ref) {
|
|
|
7724
7739
|
FavoriteButton_: FavoriteButton_,
|
|
7725
7740
|
priceFormatting_: priceFormatting_,
|
|
7726
7741
|
pseudoRouter_: pseudoRouter_,
|
|
7727
|
-
containerHeight_: containerHeight_
|
|
7742
|
+
containerHeight_: containerHeight_,
|
|
7743
|
+
imageResizer_: imageResizer_
|
|
7728
7744
|
})));
|
|
7729
7745
|
}
|
|
7730
7746
|
|
|
@@ -7999,7 +8015,8 @@ function $bb34cd283e904784$export$2c9f9bf2092486aa(props) {
|
|
|
7999
8015
|
animationDuration_: expandingAnimationDuration,
|
|
8000
8016
|
expandedLooksSignal_: $bb34cd283e904784$var$expandedLooksSignal_,
|
|
8001
8017
|
priceFormatting_: () => props.priceFormatting_,
|
|
8002
|
-
pseudoRouter_: pseudoRouter
|
|
8018
|
+
pseudoRouter_: pseudoRouter,
|
|
8019
|
+
imageResizer_: props.imageResizer_
|
|
8003
8020
|
}),
|
|
8004
8021
|
recommendations_resource_: looksResource,
|
|
8005
8022
|
title_: () => props.title_,
|
|
@@ -9486,7 +9503,8 @@ function $26db6925469636a4$export$67152d26d4f56ee8(_ref) {
|
|
|
9486
9503
|
merchant_: merchant_,
|
|
9487
9504
|
keyboardNavigationGroupIndex_: keyboardNavigationGroupIndex_,
|
|
9488
9505
|
index_: index_,
|
|
9489
|
-
selected_index_: [read_selected_index_, write_selected_index_]
|
|
9506
|
+
selected_index_: [read_selected_index_, write_selected_index_],
|
|
9507
|
+
imageResizer_: imageResizer_
|
|
9490
9508
|
} = _ref;
|
|
9491
9509
|
const href = $b8hua$createMemo(() => {
|
|
9492
9510
|
var _listing_;
|
|
@@ -9515,7 +9533,8 @@ function $26db6925469636a4$export$67152d26d4f56ee8(_ref) {
|
|
|
9515
9533
|
tabIndex: -1,
|
|
9516
9534
|
get children() {
|
|
9517
9535
|
return $b8hua$ssr($26db6925469636a4$var$_tmpl$, $b8hua$ssrHydrationKey(), $b8hua$escape($b8hua$createComponent($26db6925469636a4$export$ea41102db9bd68c3, {
|
|
9518
|
-
image_urls_: image_urls
|
|
9536
|
+
image_urls_: image_urls,
|
|
9537
|
+
imageResizer_: imageResizer_
|
|
9519
9538
|
})));
|
|
9520
9539
|
}
|
|
9521
9540
|
})), $b8hua$escape($b8hua$createComponent((0, $b8hua$Show), {
|
|
@@ -9545,7 +9564,8 @@ function $26db6925469636a4$export$67152d26d4f56ee8(_ref) {
|
|
|
9545
9564
|
}
|
|
9546
9565
|
function $26db6925469636a4$export$ea41102db9bd68c3(_ref2) {
|
|
9547
9566
|
let {
|
|
9548
|
-
image_urls_: image_urls_
|
|
9567
|
+
image_urls_: image_urls_,
|
|
9568
|
+
imageResizer_: imageResizer_
|
|
9549
9569
|
} = _ref2;
|
|
9550
9570
|
return $b8hua$createComponent((0, $b8hua$Show), {
|
|
9551
9571
|
get when() {
|
|
@@ -9569,7 +9589,8 @@ function $26db6925469636a4$export$ea41102db9bd68c3(_ref2) {
|
|
|
9569
9589
|
},
|
|
9570
9590
|
imgProps: {
|
|
9571
9591
|
style: "object-fit: cover;"
|
|
9572
|
-
}
|
|
9592
|
+
},
|
|
9593
|
+
imageResizer_: imageResizer_
|
|
9573
9594
|
})
|
|
9574
9595
|
});
|
|
9575
9596
|
}
|
|
@@ -9594,7 +9615,8 @@ function $ab401afaded322ab$export$c8d7e00464029b45(_ref) {
|
|
|
9594
9615
|
selected_index_: selected_index_,
|
|
9595
9616
|
modalLayoutStacked_: modalLayoutStacked_,
|
|
9596
9617
|
showPlaceholders_: showPlaceholders_,
|
|
9597
|
-
currently_showing_suggestions_: [, set_currently_showing_suggestions]
|
|
9618
|
+
currently_showing_suggestions_: [, set_currently_showing_suggestions],
|
|
9619
|
+
imageResizer_: imageResizer_
|
|
9598
9620
|
} = _ref;
|
|
9599
9621
|
const listings_by_id = $b8hua$createMemo(() => Object.fromEntries((listing_suggestions_() || []).map(listing => [listing.listing_id, listing])));
|
|
9600
9622
|
const productCards = $b8hua$createComponent((0, $b8hua$For), {
|
|
@@ -9612,7 +9634,8 @@ function $ab401afaded322ab$export$c8d7e00464029b45(_ref) {
|
|
|
9612
9634
|
merchant_: merchant_,
|
|
9613
9635
|
keyboardNavigationGroupIndex_: itemIndex_,
|
|
9614
9636
|
index_: index,
|
|
9615
|
-
selected_index_: selected_index_
|
|
9637
|
+
selected_index_: selected_index_,
|
|
9638
|
+
imageResizer_: imageResizer_
|
|
9616
9639
|
});
|
|
9617
9640
|
}
|
|
9618
9641
|
});
|
|
@@ -9932,7 +9955,8 @@ function $06fcd2a345efd24d$var$RawSearchModalV2(_ref) {
|
|
|
9932
9955
|
sorting_query_param_: sorting_query_param_,
|
|
9933
9956
|
filter_query_param_prefix_: filter_query_param_prefix_,
|
|
9934
9957
|
setSearchFieldOuterWidth_: setSearchFieldOuterWidth_,
|
|
9935
|
-
forceUseDiv_: forceUseDiv_
|
|
9958
|
+
forceUseDiv_: forceUseDiv_,
|
|
9959
|
+
imageResizer_: imageResizer_
|
|
9936
9960
|
} = _ref;
|
|
9937
9961
|
let on_enter_in_search_field_function;
|
|
9938
9962
|
let listingSuggestionsDebounceTimeout;
|
|
@@ -10145,7 +10169,8 @@ function $06fcd2a345efd24d$var$RawSearchModalV2(_ref) {
|
|
|
10145
10169
|
},
|
|
10146
10170
|
imgProps: {
|
|
10147
10171
|
alt: "Product image"
|
|
10148
|
-
}
|
|
10172
|
+
},
|
|
10173
|
+
imageResizer_: imageResizer_
|
|
10149
10174
|
}),
|
|
10150
10175
|
...instant_results_options_
|
|
10151
10176
|
})));
|
|
@@ -10174,7 +10199,8 @@ function $06fcd2a345efd24d$var$RawSearchModalV2(_ref) {
|
|
|
10174
10199
|
selected_index_: selected_index_,
|
|
10175
10200
|
currently_showing_suggestions_: currently_showing_suggestions_,
|
|
10176
10201
|
modalLayoutStacked_: modalLayoutStacked_,
|
|
10177
|
-
showPlaceholders_: () => !suggestions_response_.latest
|
|
10202
|
+
showPlaceholders_: () => !suggestions_response_.latest,
|
|
10203
|
+
imageResizer_: imageResizer_
|
|
10178
10204
|
});
|
|
10179
10205
|
}
|
|
10180
10206
|
});
|
|
@@ -13125,6 +13151,7 @@ class $eb064bc3350276c1$export$ac6237957a15b3f0 {
|
|
|
13125
13151
|
display_transformers: display_transformers,
|
|
13126
13152
|
api: api,
|
|
13127
13153
|
searchModalComponent: searchModalComponent,
|
|
13154
|
+
imageResizer_: imageResizer_,
|
|
13128
13155
|
// Stuff needed for non-standard customer deployments that we shouldn't actually expose
|
|
13129
13156
|
disable_scrolling_during_modal = true,
|
|
13130
13157
|
bottom_distance_under_modal: bottom_distance_under_modal,
|
|
@@ -13288,6 +13315,7 @@ class $eb064bc3350276c1$export$ac6237957a15b3f0 {
|
|
|
13288
13315
|
},
|
|
13289
13316
|
i18n_: i18n_,
|
|
13290
13317
|
enable_category_suggestions_: enable_category_suggestions,
|
|
13318
|
+
imageResizer_: imageResizer_,
|
|
13291
13319
|
disable_scrolling_: disable_scrolling_during_modal,
|
|
13292
13320
|
bottom_distance_under_modal_: bottom_distance_under_modal
|
|
13293
13321
|
}, override_modal_element);
|
|
@@ -14189,7 +14217,8 @@ function $8821a19349c36651$export$e2bf8ce7779e827e(props) {
|
|
|
14189
14217
|
product_card_template_: product_card_template,
|
|
14190
14218
|
sorting_query_param_: sorting_query_param_,
|
|
14191
14219
|
filter_query_param_prefix_: filter_query_param_prefix_,
|
|
14192
|
-
switchToFiltersDrawerBreakpoint_: () => props.switchToFiltersDrawerBreakpoint_
|
|
14220
|
+
switchToFiltersDrawerBreakpoint_: () => props.switchToFiltersDrawerBreakpoint_,
|
|
14221
|
+
imageResizer_: props.imageResizer_
|
|
14193
14222
|
});
|
|
14194
14223
|
}, "Entire CategoryPage failed");
|
|
14195
14224
|
}
|
package/server/latest/index.cjs
CHANGED
|
@@ -109,7 +109,7 @@ $parcel$export(module.exports, "BreadCrumbs", () => $1f4925833f07df29$export$5b7
|
|
|
109
109
|
$parcel$export(module.exports, "QuickLinks", () => $1f4925833f07df29$export$de035477d6fef996);
|
|
110
110
|
$parcel$export(module.exports, "CategoryPage", () => $14f289047713d67a$export$e2bf8ce7779e827e);
|
|
111
111
|
/*! Depict.ai search and product listing SDK */
|
|
112
|
-
const $b757f75811f3261f$export$83d89fbfd8236492 = "4.10.
|
|
112
|
+
const $b757f75811f3261f$export$83d89fbfd8236492 = "4.10.12";
|
|
113
113
|
function $b54e6192d0caa293$export$d9f36cf74e24d595(media_query) {
|
|
114
114
|
const signal = $5vyXB$solidjs.createSignal(false);
|
|
115
115
|
$5vyXB$solidjs.onCleanup($5vyXB$depictaiutilishared.javascript_media_query(media_query, ({
|
|
@@ -6209,7 +6209,7 @@ function $a33065cfed827fc0$export$e4b984597b71e989(props) {
|
|
|
6209
6209
|
})));
|
|
6210
6210
|
return container;
|
|
6211
6211
|
}
|
|
6212
|
-
const $d212a67662c5cf38$var$
|
|
6212
|
+
const $d212a67662c5cf38$var$defaultCustomUrls = (url, width) => {
|
|
6213
6213
|
if (url?.startsWith?.("https://cdn.shopify.com"))
|
|
6214
6214
|
// The shopify image resizing CDN blocks Cloudflare's image resizer. It's possible that we can't detect shopify image URLs sometimes because they go to the merchant's domain,
|
|
6215
6215
|
// but it seems like the URLs returned by the Depict API always goes to the cdn.shopify.com version of an image, so this simple workaround works.
|
|
@@ -6218,18 +6218,21 @@ const $d212a67662c5cf38$var$customUrls = (url, width) => {
|
|
|
6218
6218
|
return `https://app.depict.ai/cdn-cgi/image/width=${width},format=auto/${url}`;
|
|
6219
6219
|
};
|
|
6220
6220
|
function $d212a67662c5cf38$export$9d4a4b669b1929ab(props) {
|
|
6221
|
+
const resolvedCustomUrls = props.imageResizer_ ?? $d212a67662c5cf38$var$defaultCustomUrls;
|
|
6221
6222
|
return $5vyXB$solidjsweb.createComponent((0, $a33065cfed827fc0$export$e4b984597b71e989), $5vyXB$solidjsweb.mergeProps(props, {
|
|
6222
6223
|
get imgProps() {
|
|
6223
6224
|
return {
|
|
6224
6225
|
...props.imgProps,
|
|
6225
|
-
customUrls:
|
|
6226
|
+
customUrls: resolvedCustomUrls
|
|
6226
6227
|
};
|
|
6227
6228
|
}
|
|
6228
6229
|
}));
|
|
6229
6230
|
}
|
|
6230
6231
|
function $d212a67662c5cf38$export$140423fa4bfb6d63(props) {
|
|
6231
6232
|
return $5vyXB$solidjsweb.createComponent((0, $19950faaac026e09$export$6e5611bc7e57e477), $5vyXB$solidjsweb.mergeProps(props, {
|
|
6232
|
-
customUrls
|
|
6233
|
+
get customUrls() {
|
|
6234
|
+
return props.imageResizer_ ?? $d212a67662c5cf38$var$defaultCustomUrls;
|
|
6235
|
+
}
|
|
6233
6236
|
}));
|
|
6234
6237
|
}
|
|
6235
6238
|
var $32c662f618f5d80d$var$_tmpl$ = ["<video", ' disablepictureinpicture="true" class="d-standard-content"></video>'];
|
|
@@ -6239,7 +6242,8 @@ function $32c662f618f5d80d$export$780a853d15174484({
|
|
|
6239
6242
|
router_: router_,
|
|
6240
6243
|
setAspectRatioWas_: setAspectRatioWas_,
|
|
6241
6244
|
mediaUrl_: mediaUrl_,
|
|
6242
|
-
aspectRatioWhenAloneInRow_: aspectRatioWhenAloneInRow_
|
|
6245
|
+
aspectRatioWhenAloneInRow_: aspectRatioWhenAloneInRow_,
|
|
6246
|
+
imageResizer_: imageResizer_
|
|
6243
6247
|
}) {
|
|
6244
6248
|
let wroteAspectRatioToContainer = false; // Only write this once so we don't get into a aspect ratio changed -> size changed -> image source changed -> aspect ratio slightly changed infinite loop
|
|
6245
6249
|
const [wrapperSize, setWrapperSize] = $5vyXB$solidjs.createSignal();
|
|
@@ -6287,7 +6291,8 @@ function $32c662f618f5d80d$export$780a853d15174484({
|
|
|
6287
6291
|
sizeHeight: () => wrapperSize()?.[1]?.() || 0,
|
|
6288
6292
|
src: mediaUrl_,
|
|
6289
6293
|
"class": "d-standard-content",
|
|
6290
|
-
onDecoded: () => setHasLoaded(true)
|
|
6294
|
+
onDecoded: () => setHasLoaded(true),
|
|
6295
|
+
imageResizer_: imageResizer_
|
|
6291
6296
|
});
|
|
6292
6297
|
}
|
|
6293
6298
|
}), $5vyXB$solidjsweb.createComponent((0, $5vyXB$solidjs.Match), {
|
|
@@ -6301,7 +6306,7 @@ function $32c662f618f5d80d$export$780a853d15174484({
|
|
|
6301
6306
|
}
|
|
6302
6307
|
}));
|
|
6303
6308
|
}
|
|
6304
|
-
function $0a80939bf0a1e9cc$export$7a92d995f1bf3592(history_content_blocks_, plp_meta, content_blocks_by_row_, router_, products_request_loading_) {
|
|
6309
|
+
function $0a80939bf0a1e9cc$export$7a92d995f1bf3592(history_content_blocks_, plp_meta, content_blocks_by_row_, router_, products_request_loading_, imageResizer_) {
|
|
6305
6310
|
let hasSeenContentBlock = false;
|
|
6306
6311
|
const [historyContentBlocks, setHistoryContentBlocks] = history_content_blocks_;
|
|
6307
6312
|
const contentComponents = new Map();
|
|
@@ -6356,7 +6361,8 @@ function $0a80939bf0a1e9cc$export$7a92d995f1bf3592(history_content_blocks_, plp_
|
|
|
6356
6361
|
...prev.aspectRatios,
|
|
6357
6362
|
[componentCacheKey]: Math.round(aspectRatio * 100) / 100
|
|
6358
6363
|
}
|
|
6359
|
-
}))
|
|
6364
|
+
})),
|
|
6365
|
+
imageResizer_: imageResizer_
|
|
6360
6366
|
});
|
|
6361
6367
|
contentComponents.set(componentCacheKey, component);
|
|
6362
6368
|
}
|
|
@@ -6418,7 +6424,8 @@ function $840d88a04b2d22a7$export$f7d2f673fc2f091d({
|
|
|
6418
6424
|
filterModalParent_: filterModalParent_,
|
|
6419
6425
|
showSliderArrow_: showSliderArrow_,
|
|
6420
6426
|
hideCount0FilterOptions_: hideCount0FilterOptions_,
|
|
6421
|
-
switchToFiltersDrawerBreakpoint_: switchToFiltersDrawerBreakpoint_
|
|
6427
|
+
switchToFiltersDrawerBreakpoint_: switchToFiltersDrawerBreakpoint_,
|
|
6428
|
+
imageResizer_: imageResizer_
|
|
6422
6429
|
}) {
|
|
6423
6430
|
let results_for;
|
|
6424
6431
|
let only_show_filters_opener_;
|
|
@@ -6514,7 +6521,7 @@ function $840d88a04b2d22a7$export$f7d2f673fc2f091d({
|
|
|
6514
6521
|
setMetaRequestsForQuery(prev => prev.set(query.id_type_ + query.id_to_query_for_, listing));
|
|
6515
6522
|
return result;
|
|
6516
6523
|
}));
|
|
6517
|
-
const contentBlocksByRow = $0a80939bf0a1e9cc$export$7a92d995f1bf3592(history_content_blocks_, plp_meta, content_blocks_by_row_, router_, () => plp_products_.loading);
|
|
6524
|
+
const contentBlocksByRow = $0a80939bf0a1e9cc$export$7a92d995f1bf3592(history_content_blocks_, plp_meta, content_blocks_by_row_, router_, () => plp_products_.loading, imageResizer_);
|
|
6518
6525
|
const countOfProductsForUI = $13796d59ea8af231$export$a86bc18439445599(plp_products_, all_products_loaded_, currentlyLoadedDisplays);
|
|
6519
6526
|
const available_sortings_ = $5vyXB$solidjs.createMemo(() => plp_products_()?.sorts?.map(sort => ({
|
|
6520
6527
|
...sort,
|
|
@@ -7025,7 +7032,8 @@ function $0540c3739b32dc79$export$b73ed90f0ee50dc3({
|
|
|
7025
7032
|
outerRef_: outerRef_,
|
|
7026
7033
|
animationDuration_: animationDuration_,
|
|
7027
7034
|
priceFormatting_: priceFormatting_,
|
|
7028
|
-
pseudoRouter_: pseudoRouter_
|
|
7035
|
+
pseudoRouter_: pseudoRouter_,
|
|
7036
|
+
imageResizer_: imageResizer_
|
|
7029
7037
|
}) {
|
|
7030
7038
|
const variantToUse = $5vyXB$solidjs.createMemo(() => {
|
|
7031
7039
|
const display = display_();
|
|
@@ -7076,7 +7084,8 @@ function $0540c3739b32dc79$export$b73ed90f0ee50dc3({
|
|
|
7076
7084
|
},
|
|
7077
7085
|
imgProps: {
|
|
7078
7086
|
keyRatioUpdating: true
|
|
7079
|
-
}
|
|
7087
|
+
},
|
|
7088
|
+
imageResizer_: imageResizer_
|
|
7080
7089
|
});
|
|
7081
7090
|
}
|
|
7082
7091
|
})));
|
|
@@ -7225,7 +7234,8 @@ function $912d9a717ceee184$export$ebf0b1d4f90c09ae({
|
|
|
7225
7234
|
supportsHover_: supportsHover_,
|
|
7226
7235
|
priceFormatting_: priceFormatting_,
|
|
7227
7236
|
pseudoRouter_: pseudoRouter_,
|
|
7228
|
-
containerHeight_: containerHeight_
|
|
7237
|
+
containerHeight_: containerHeight_,
|
|
7238
|
+
imageResizer_: imageResizer_
|
|
7229
7239
|
}) {
|
|
7230
7240
|
let isAffectedByChromeBug = false;
|
|
7231
7241
|
// If the user requests the drawer to be expanded or not
|
|
@@ -7261,6 +7271,7 @@ function $912d9a717ceee184$export$ebf0b1d4f90c09ae({
|
|
|
7261
7271
|
userWantsExpandedSignal_: userWantsExpandedSignal_,
|
|
7262
7272
|
textFadeInAnimationRunning_: textFadeInAnimationRunning,
|
|
7263
7273
|
priceFormatting_: priceFormatting_,
|
|
7274
|
+
imageResizer_: imageResizer_,
|
|
7264
7275
|
outerRef_: el => $5vyXB$solidjs.createEffect(() => {
|
|
7265
7276
|
if (index !== 0) return;
|
|
7266
7277
|
const resizeObserver = new ResizeObserver($5vyXB$depictaiutilishared.catchify(records => setLookItemHeight(records.at(-1).contentRect.height)));
|
|
@@ -7303,7 +7314,8 @@ function $bda357ff87c46163$export$44809a8a3e867e30({
|
|
|
7303
7314
|
placeholderImageAspectRatio_: placeholderImageAspectRatio_,
|
|
7304
7315
|
animationDuration_: animationDuration_,
|
|
7305
7316
|
priceFormatting_: priceFormatting_,
|
|
7306
|
-
pseudoRouter_: pseudoRouter_
|
|
7317
|
+
pseudoRouter_: pseudoRouter_,
|
|
7318
|
+
imageResizer_: imageResizer_
|
|
7307
7319
|
}) {
|
|
7308
7320
|
let container;
|
|
7309
7321
|
const useWantsExpandedSignal_ = $5vyXB$solidjs.createSignal(false);
|
|
@@ -7368,7 +7380,8 @@ function $bda357ff87c46163$export$44809a8a3e867e30({
|
|
|
7368
7380
|
return display_()?.image_urls?.[0];
|
|
7369
7381
|
},
|
|
7370
7382
|
aspectRatio: placeholderImageAspectRatio_,
|
|
7371
|
-
autoAdjustAspectRatio: true
|
|
7383
|
+
autoAdjustAspectRatio: true,
|
|
7384
|
+
imageResizer_: imageResizer_
|
|
7372
7385
|
});
|
|
7373
7386
|
}
|
|
7374
7387
|
})), $5vyXB$solidjsweb.escape($5vyXB$solidjsweb.createComponent((0, $912d9a717ceee184$export$ebf0b1d4f90c09ae), {
|
|
@@ -7380,7 +7393,8 @@ function $bda357ff87c46163$export$44809a8a3e867e30({
|
|
|
7380
7393
|
FavoriteButton_: FavoriteButton_,
|
|
7381
7394
|
priceFormatting_: priceFormatting_,
|
|
7382
7395
|
pseudoRouter_: pseudoRouter_,
|
|
7383
|
-
containerHeight_: containerHeight_
|
|
7396
|
+
containerHeight_: containerHeight_,
|
|
7397
|
+
imageResizer_: imageResizer_
|
|
7384
7398
|
})));
|
|
7385
7399
|
}
|
|
7386
7400
|
|
|
@@ -7636,7 +7650,8 @@ function $a3bbfa5fdaa39f3a$export$2c9f9bf2092486aa(props) {
|
|
|
7636
7650
|
animationDuration_: expandingAnimationDuration,
|
|
7637
7651
|
expandedLooksSignal_: $a3bbfa5fdaa39f3a$var$expandedLooksSignal_,
|
|
7638
7652
|
priceFormatting_: () => props.priceFormatting_,
|
|
7639
|
-
pseudoRouter_: pseudoRouter
|
|
7653
|
+
pseudoRouter_: pseudoRouter,
|
|
7654
|
+
imageResizer_: props.imageResizer_
|
|
7640
7655
|
}),
|
|
7641
7656
|
recommendations_resource_: looksResource,
|
|
7642
7657
|
title_: () => props.title_,
|
|
@@ -9040,7 +9055,8 @@ function $1f3b5fa875714dea$export$67152d26d4f56ee8({
|
|
|
9040
9055
|
merchant_: merchant_,
|
|
9041
9056
|
keyboardNavigationGroupIndex_: keyboardNavigationGroupIndex_,
|
|
9042
9057
|
index_: index_,
|
|
9043
|
-
selected_index_: [read_selected_index_, write_selected_index_]
|
|
9058
|
+
selected_index_: [read_selected_index_, write_selected_index_],
|
|
9059
|
+
imageResizer_: imageResizer_
|
|
9044
9060
|
}) {
|
|
9045
9061
|
const href = $5vyXB$solidjs.createMemo(() => listing_()?.page_url); // <- could be made reactive getter created in displayTransformers, read it in memo here since it might create computations (for example in the preview-brower), and there's no owner in the onClick handler
|
|
9046
9062
|
const LinkToListing = props => $5vyXB$solidjsweb.ssrElement("a", $5vyXB$solidjsweb.mergeProps(props, {
|
|
@@ -9059,7 +9075,8 @@ function $1f3b5fa875714dea$export$67152d26d4f56ee8({
|
|
|
9059
9075
|
tabIndex: -1,
|
|
9060
9076
|
get children() {
|
|
9061
9077
|
return $5vyXB$solidjsweb.ssr($1f3b5fa875714dea$var$_tmpl$, $5vyXB$solidjsweb.ssrHydrationKey(), $5vyXB$solidjsweb.escape($5vyXB$solidjsweb.createComponent($1f3b5fa875714dea$export$ea41102db9bd68c3, {
|
|
9062
|
-
image_urls_: image_urls
|
|
9078
|
+
image_urls_: image_urls,
|
|
9079
|
+
imageResizer_: imageResizer_
|
|
9063
9080
|
})));
|
|
9064
9081
|
}
|
|
9065
9082
|
})), $5vyXB$solidjsweb.escape($5vyXB$solidjsweb.createComponent((0, $5vyXB$solidjs.Show), {
|
|
@@ -9086,7 +9103,8 @@ function $1f3b5fa875714dea$export$67152d26d4f56ee8({
|
|
|
9086
9103
|
})));
|
|
9087
9104
|
}
|
|
9088
9105
|
function $1f3b5fa875714dea$export$ea41102db9bd68c3({
|
|
9089
|
-
image_urls_: image_urls_
|
|
9106
|
+
image_urls_: image_urls_,
|
|
9107
|
+
imageResizer_: imageResizer_
|
|
9090
9108
|
}) {
|
|
9091
9109
|
return $5vyXB$solidjsweb.createComponent((0, $5vyXB$solidjs.Show), {
|
|
9092
9110
|
get when() {
|
|
@@ -9109,7 +9127,8 @@ function $1f3b5fa875714dea$export$ea41102db9bd68c3({
|
|
|
9109
9127
|
},
|
|
9110
9128
|
imgProps: {
|
|
9111
9129
|
style: "object-fit: cover;"
|
|
9112
|
-
}
|
|
9130
|
+
},
|
|
9131
|
+
imageResizer_: imageResizer_
|
|
9113
9132
|
})
|
|
9114
9133
|
});
|
|
9115
9134
|
}
|
|
@@ -9133,7 +9152,8 @@ function $83e616b38be339e4$export$c8d7e00464029b45({
|
|
|
9133
9152
|
selected_index_: selected_index_,
|
|
9134
9153
|
modalLayoutStacked_: modalLayoutStacked_,
|
|
9135
9154
|
showPlaceholders_: showPlaceholders_,
|
|
9136
|
-
currently_showing_suggestions_: [, set_currently_showing_suggestions]
|
|
9155
|
+
currently_showing_suggestions_: [, set_currently_showing_suggestions],
|
|
9156
|
+
imageResizer_: imageResizer_
|
|
9137
9157
|
}) {
|
|
9138
9158
|
const listings_by_id = $5vyXB$solidjs.createMemo(() => Object.fromEntries((listing_suggestions_() || []).map(listing => [listing.listing_id, listing])));
|
|
9139
9159
|
const productCards = $5vyXB$solidjsweb.createComponent((0, $5vyXB$solidjs.For), {
|
|
@@ -9151,7 +9171,8 @@ function $83e616b38be339e4$export$c8d7e00464029b45({
|
|
|
9151
9171
|
merchant_: merchant_,
|
|
9152
9172
|
keyboardNavigationGroupIndex_: itemIndex_,
|
|
9153
9173
|
index_: index,
|
|
9154
|
-
selected_index_: selected_index_
|
|
9174
|
+
selected_index_: selected_index_,
|
|
9175
|
+
imageResizer_: imageResizer_
|
|
9155
9176
|
});
|
|
9156
9177
|
}
|
|
9157
9178
|
});
|
|
@@ -9460,7 +9481,8 @@ function $11597ae03e703a47$var$RawSearchModalV2({
|
|
|
9460
9481
|
sorting_query_param_: sorting_query_param_,
|
|
9461
9482
|
filter_query_param_prefix_: filter_query_param_prefix_,
|
|
9462
9483
|
setSearchFieldOuterWidth_: setSearchFieldOuterWidth_,
|
|
9463
|
-
forceUseDiv_: forceUseDiv_
|
|
9484
|
+
forceUseDiv_: forceUseDiv_,
|
|
9485
|
+
imageResizer_: imageResizer_
|
|
9464
9486
|
}) {
|
|
9465
9487
|
let on_enter_in_search_field_function;
|
|
9466
9488
|
let listingSuggestionsDebounceTimeout;
|
|
@@ -9666,7 +9688,8 @@ function $11597ae03e703a47$var$RawSearchModalV2({
|
|
|
9666
9688
|
},
|
|
9667
9689
|
imgProps: {
|
|
9668
9690
|
alt: "Product image"
|
|
9669
|
-
}
|
|
9691
|
+
},
|
|
9692
|
+
imageResizer_: imageResizer_
|
|
9670
9693
|
}),
|
|
9671
9694
|
...instant_results_options_
|
|
9672
9695
|
})));
|
|
@@ -9695,7 +9718,8 @@ function $11597ae03e703a47$var$RawSearchModalV2({
|
|
|
9695
9718
|
selected_index_: selected_index_,
|
|
9696
9719
|
currently_showing_suggestions_: currently_showing_suggestions_,
|
|
9697
9720
|
modalLayoutStacked_: modalLayoutStacked_,
|
|
9698
|
-
showPlaceholders_: () => !suggestions_response_.latest
|
|
9721
|
+
showPlaceholders_: () => !suggestions_response_.latest,
|
|
9722
|
+
imageResizer_: imageResizer_
|
|
9699
9723
|
});
|
|
9700
9724
|
}
|
|
9701
9725
|
});
|
|
@@ -12379,6 +12403,7 @@ class $2c61e4cd8229c49a$export$ac6237957a15b3f0 {
|
|
|
12379
12403
|
display_transformers: display_transformers,
|
|
12380
12404
|
api: api,
|
|
12381
12405
|
searchModalComponent: searchModalComponent,
|
|
12406
|
+
imageResizer_: imageResizer_,
|
|
12382
12407
|
// Stuff needed for non-standard customer deployments that we shouldn't actually expose
|
|
12383
12408
|
disable_scrolling_during_modal = true,
|
|
12384
12409
|
bottom_distance_under_modal: bottom_distance_under_modal,
|
|
@@ -12509,6 +12534,7 @@ class $2c61e4cd8229c49a$export$ac6237957a15b3f0 {
|
|
|
12509
12534
|
},
|
|
12510
12535
|
i18n_: i18n_,
|
|
12511
12536
|
enable_category_suggestions_: enable_category_suggestions,
|
|
12537
|
+
imageResizer_: imageResizer_,
|
|
12512
12538
|
disable_scrolling_: disable_scrolling_during_modal,
|
|
12513
12539
|
bottom_distance_under_modal_: bottom_distance_under_modal
|
|
12514
12540
|
}, override_modal_element);
|
|
@@ -13283,7 +13309,8 @@ function $14f289047713d67a$export$e2bf8ce7779e827e(props) {
|
|
|
13283
13309
|
product_card_template_: product_card_template,
|
|
13284
13310
|
sorting_query_param_: sorting_query_param_,
|
|
13285
13311
|
filter_query_param_prefix_: filter_query_param_prefix_,
|
|
13286
|
-
switchToFiltersDrawerBreakpoint_: () => props.switchToFiltersDrawerBreakpoint_
|
|
13312
|
+
switchToFiltersDrawerBreakpoint_: () => props.switchToFiltersDrawerBreakpoint_,
|
|
13313
|
+
imageResizer_: props.imageResizer_
|
|
13287
13314
|
});
|
|
13288
13315
|
}, "Entire CategoryPage failed");
|
|
13289
13316
|
}
|