@depict-ai/ui 4.2.0 → 4.2.2
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 +140 -89
- package/ES10/index.d.ts +3 -2
- package/ES10/index.js +140 -89
- package/latest/index.cjs +116 -84
- package/latest/index.d.ts +3 -2
- package/latest/index.js +116 -84
- package/package.json +4 -4
- package/server/ES10/index.cjs +132 -78
- package/server/ES10/index.d.ts +3 -2
- package/server/ES10/index.js +133 -79
- package/server/latest/index.cjs +108 -73
- package/server/latest/index.d.ts +3 -2
- package/server/latest/index.js +109 -74
package/server/latest/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { add_to_version_info as $i7OB2$add_to_version_info, fetch_retry as $i7OB2$fetch_retry, base_url as $i7OB2$base_url, slider_fractional_factory as $i7OB2$slider_fractional_factory, dlog as $i7OB2$dlog, camelCasifyObject as $i7OB2$camelCasifyObject, make_random_classname as $i7OB2$make_random_classname, n_col_styling_with_dist as $i7OB2$n_col_styling_with_dist, catchify as $i7OB2$catchify, layout_get_visible_recs_without_partial_rows as $i7OB2$layout_get_visible_recs_without_partial_rows, layout_get_total_rec_amount_for_row as $i7OB2$layout_get_total_rec_amount_for_row, layout_media_query_header as $i7OB2$layout_media_query_header, report as $i7OB2$report, slider_fading_factory as $i7OB2$slider_fading_factory, Amazing_Slider as $i7OB2$Amazing_Slider, slider_snap_css as $i7OB2$slider_snap_css, observer as $i7OB2$observer, javascript_media_query as $i7OB2$javascript_media_query, queueMacroTask as $i7OB2$queueMacroTask, findMostFrequentItem as $i7OB2$findMostFrequentItem, dwarn as $i7OB2$dwarn, deparallelize_no_drop as $i7OB2$deparallelize_no_drop, ContainedImage as $i7OB2$ContainedImage, standard_price_format as $i7OB2$standard_price_format, make_asyncIterable_exiter as $i7OB2$make_asyncIterable_exiter, href_change_ipns as $i7OB2$href_change_ipns, base64_encode_unicode as $i7OB2$base64_encode_unicode, base64_decode_unicode as $i7OB2$base64_decode_unicode, use_href_accessor as $i7OB2$use_href_accessor, get_session_id as $i7OB2$get_session_id, add_version_query_params as $i7OB2$add_version_query_params, instant_exec_on_suspect_history_change as $i7OB2$instant_exec_on_suspect_history_change, useExpandingContainer as $i7OB2$useExpandingContainer, hex_to_rgb as $i7OB2$hex_to_rgb, relative_luminance_from_rgb as $i7OB2$relative_luminance_from_rgb, snakeCasifyObject as $i7OB2$snakeCasifyObject, sort_obj as $i7OB2$sort_obj, make_url_with_query_params as $i7OB2$make_url_with_query_params, ListenableSet as $i7OB2$ListenableSet1, insert_surfaces as $i7OB2$insert_surfaces } from "@depict-ai/utilishared/latest";
|
|
2
|
-
import { ssr as $i7OB2$ssr, ssrHydrationKey as $i7OB2$ssrHydrationKey, escape as $i7OB2$escape, createComponent as $i7OB2$createComponent, mergeProps as $i7OB2$mergeProps, isServer as $i7OB2$isServer, ssrElement as $i7OB2$ssrElement, ssrClassList as $i7OB2$ssrClassList, insert as $i7OB2$insert, ssrAttribute as $i7OB2$ssrAttribute,
|
|
2
|
+
import { ssr as $i7OB2$ssr, ssrHydrationKey as $i7OB2$ssrHydrationKey, ssrStyle as $i7OB2$ssrStyle, escape as $i7OB2$escape, createComponent as $i7OB2$createComponent, mergeProps as $i7OB2$mergeProps, isServer as $i7OB2$isServer, ssrElement as $i7OB2$ssrElement, ssrClassList as $i7OB2$ssrClassList, insert as $i7OB2$insert, ssrAttribute as $i7OB2$ssrAttribute, spread as $i7OB2$spread, Dynamic as $i7OB2$Dynamic } from "solid-js/web";
|
|
3
3
|
import { createSignal as $i7OB2$createSignal, createMemo as $i7OB2$createMemo, createResource as $i7OB2$createResource, Show as $i7OB2$Show, Suspense as $i7OB2$Suspense, untrack as $i7OB2$untrack, createRenderEffect as $i7OB2$createRenderEffect, Index as $i7OB2$Index, createRoot as $i7OB2$createRoot, onCleanup as $i7OB2$onCleanup, For as $i7OB2$For, getOwner as $i7OB2$getOwner, runWithOwner as $i7OB2$runWithOwner, createEffect as $i7OB2$createEffect, createContext as $i7OB2$createContext, useContext as $i7OB2$useContext, createUniqueId as $i7OB2$createUniqueId, createComputed as $i7OB2$createComputed, ErrorBoundary as $i7OB2$ErrorBoundary, splitProps as $i7OB2$splitProps, mergeProps as $i7OB2$mergeProps1, on as $i7OB2$on, batch as $i7OB2$batch, createSelector as $i7OB2$createSelector, children as $i7OB2$children, createReaction as $i7OB2$createReaction, mapArray as $i7OB2$mapArray } from "solid-js";
|
|
4
4
|
import { ListenableSet as $i7OB2$ListenableSet, catchify as $i7OB2$catchify1, use_href_accessor as $i7OB2$use_href_accessor1, report as $i7OB2$report1 } from "@depict-ai/utilishared/latest";
|
|
5
5
|
import { createStore as $i7OB2$createStore, reconcile as $i7OB2$reconcile } from "solid-js/store";
|
|
@@ -7,7 +7,7 @@ import { createStore as $i7OB2$createStore, reconcile as $i7OB2$reconcile } from
|
|
|
7
7
|
/*! Depict.ai search and product listing SDK */
|
|
8
8
|
import { register_es_version } from "../../multi_import_deduplicator.mjs";
|
|
9
9
|
register_es_version("ui", "latest");
|
|
10
|
-
const $ec291e0010116877$export$83d89fbfd8236492 = "4.2.
|
|
10
|
+
const $ec291e0010116877$export$83d89fbfd8236492 = "4.2.2";
|
|
11
11
|
const $b5cccc8ee7d24677$var$transform_elements = sorted_cols_at_size => {
|
|
12
12
|
const cols_at_size = [];
|
|
13
13
|
for (let i = 0; i < sorted_cols_at_size.length; i++) {
|
|
@@ -1121,21 +1121,24 @@ function $5a6c386e1bde5665$export$b73ed90f0ee50dc3({
|
|
|
1121
1121
|
outerRef_: outerRef_,
|
|
1122
1122
|
animationDuration_: animationDuration_
|
|
1123
1123
|
}) {
|
|
1124
|
-
const variantToUse =
|
|
1125
|
-
|
|
1126
|
-
|
|
1127
|
-
|
|
1124
|
+
const variantToUse = $i7OB2$createMemo(() => {
|
|
1125
|
+
const display = display_();
|
|
1126
|
+
return display?.variant_displays[display?.variant_index];
|
|
1127
|
+
});
|
|
1128
|
+
const imageUrls = () => variantToUse()?.image_urls;
|
|
1129
|
+
const imageUrl = $i7OB2$createMemo(() => imageUrls()?.[0]);
|
|
1130
|
+
const secondaryImageUrl = $i7OB2$createMemo(() => imageUrls()?.[1]);
|
|
1128
1131
|
const [animationIsRunning, setAnimationIsRunning] = textFadeInAnimationRunning_;
|
|
1129
1132
|
const [isExpandedThrottledByOurEffectRun, setIsExpandedThrottledByOurEffectRun] = $i7OB2$createSignal($i7OB2$untrack(isExpanded_));
|
|
1130
1133
|
const [animationEffectExists, setAnimationEffectExists] = $i7OB2$createSignal(false);
|
|
1131
|
-
const [salePrice] = $i7OB2$createResource(() => variantToUse?.sale_price);
|
|
1132
|
-
const [originalPrice] = $i7OB2$createResource(() => variantToUse?.original_price);
|
|
1134
|
+
const [salePrice] = $i7OB2$createResource(() => variantToUse()?.sale_price);
|
|
1135
|
+
const [originalPrice] = $i7OB2$createResource(() => variantToUse()?.original_price);
|
|
1133
1136
|
const isOnSale = $i7OB2$createMemo(() => salePrice.latest !== originalPrice.latest); // .latest doesn't trigger suspense
|
|
1134
1137
|
const FavoriteButton = FavoriteButton_; // Just to get rid of the type error - TS doesn't understand <Show>
|
|
1135
1138
|
return $i7OB2$ssrElement("a", $i7OB2$mergeProps({
|
|
1136
1139
|
"class": "look-item"
|
|
1137
1140
|
}, () => isExpanded_() && !animationIsRunning() ? {
|
|
1138
|
-
href: variantToUse?.page_url
|
|
1141
|
+
href: variantToUse()?.page_url
|
|
1139
1142
|
} : {}), () => ["<!--$-->", $i7OB2$escape($i7OB2$createComponent((0, $i7OB2$Show), {
|
|
1140
1143
|
when: imageUrl,
|
|
1141
1144
|
get fallback() {
|
|
@@ -1144,19 +1147,37 @@ function $5a6c386e1bde5665$export$b73ed90f0ee50dc3({
|
|
|
1144
1147
|
});
|
|
1145
1148
|
},
|
|
1146
1149
|
get children() {
|
|
1147
|
-
return $i7OB2$ssr($5a6c386e1bde5665$var$_tmpl$, $i7OB2$ssrHydrationKey(), $i7OB2$escape($i7OB2$createComponent((0, $
|
|
1148
|
-
|
|
1149
|
-
|
|
1150
|
-
|
|
1150
|
+
return $i7OB2$ssr($5a6c386e1bde5665$var$_tmpl$, $i7OB2$ssrHydrationKey(), $i7OB2$escape($i7OB2$createComponent((0, $i7OB2$Show), {
|
|
1151
|
+
get when() {
|
|
1152
|
+
return imageUrl();
|
|
1153
|
+
},
|
|
1154
|
+
get fallback() {
|
|
1155
|
+
return $i7OB2$createComponent((0, $7f60f09116a3fe61$export$3f37af283f8fb843), {
|
|
1156
|
+
aspectRatio: 1
|
|
1157
|
+
});
|
|
1151
1158
|
},
|
|
1152
|
-
get
|
|
1153
|
-
return
|
|
1159
|
+
get children() {
|
|
1160
|
+
return $i7OB2$createComponent((0, $70bb27cc6be01fc7$export$9d4a4b669b1929ab), {
|
|
1161
|
+
get src() {
|
|
1162
|
+
return imageUrl();
|
|
1163
|
+
},
|
|
1164
|
+
get aspectRatio() {
|
|
1165
|
+
return isExpanded_() ? 0.75 : 1;
|
|
1166
|
+
},
|
|
1167
|
+
get autoAdjustAspectRatio() {
|
|
1168
|
+
return isExpanded_() ? "smoothed" : false;
|
|
1169
|
+
}
|
|
1170
|
+
});
|
|
1154
1171
|
}
|
|
1155
1172
|
})), $i7OB2$escape($i7OB2$createComponent((0, $i7OB2$Show), {
|
|
1156
|
-
when
|
|
1173
|
+
get when() {
|
|
1174
|
+
return secondaryImageUrl();
|
|
1175
|
+
},
|
|
1157
1176
|
get children() {
|
|
1158
1177
|
return $i7OB2$createComponent((0, $70bb27cc6be01fc7$export$9d4a4b669b1929ab), {
|
|
1159
|
-
src
|
|
1178
|
+
get src() {
|
|
1179
|
+
return secondaryImageUrl();
|
|
1180
|
+
},
|
|
1160
1181
|
get aspectRatio() {
|
|
1161
1182
|
return isExpanded_() ? 0.75 : 1;
|
|
1162
1183
|
},
|
|
@@ -1173,10 +1194,10 @@ function $5a6c386e1bde5665$export$b73ed90f0ee50dc3({
|
|
|
1173
1194
|
return (animationEffectExists() ? isExpandedThrottledByOurEffectRun() : isExpanded_()) || animationIsRunning();
|
|
1174
1195
|
},
|
|
1175
1196
|
get children() {
|
|
1176
|
-
return $i7OB2$ssr($5a6c386e1bde5665$var$_tmpl$3, $i7OB2$ssrHydrationKey(), $i7OB2$escape(variantToUse?.title) ?? $i7OB2$escape($i7OB2$createComponent((0, $d134eae24341b4a1$export$89c6019e4baa40b1), {
|
|
1197
|
+
return $i7OB2$ssr($5a6c386e1bde5665$var$_tmpl$3, $i7OB2$ssrHydrationKey(), $i7OB2$escape(variantToUse()?.title) ?? $i7OB2$escape($i7OB2$createComponent((0, $d134eae24341b4a1$export$89c6019e4baa40b1), {
|
|
1177
1198
|
height: "1em",
|
|
1178
1199
|
width: "20ch"
|
|
1179
|
-
})), `d-price ${isOnSale() ? "sale" : ""}`, !variantToUse || salePrice.loading ? $i7OB2$escape($i7OB2$createComponent((0, $d134eae24341b4a1$export$89c6019e4baa40b1), {
|
|
1200
|
+
})), `d-price ${isOnSale() ? "sale" : ""}`, !variantToUse() || salePrice.loading ? $i7OB2$escape($i7OB2$createComponent((0, $d134eae24341b4a1$export$89c6019e4baa40b1), {
|
|
1180
1201
|
height: "1em",
|
|
1181
1202
|
width: "20ch"
|
|
1182
1203
|
})) : $i7OB2$escape(salePrice()), $i7OB2$escape($i7OB2$createComponent((0, $i7OB2$Show), {
|
|
@@ -1184,7 +1205,7 @@ function $5a6c386e1bde5665$export$b73ed90f0ee50dc3({
|
|
|
1184
1205
|
return isOnSale();
|
|
1185
1206
|
},
|
|
1186
1207
|
get children() {
|
|
1187
|
-
return $i7OB2$ssr($5a6c386e1bde5665$var$_tmpl$2, $i7OB2$ssrHydrationKey(), !variantToUse || originalPrice.loading ? $i7OB2$escape($i7OB2$createComponent((0, $d134eae24341b4a1$export$89c6019e4baa40b1), {
|
|
1208
|
+
return $i7OB2$ssr($5a6c386e1bde5665$var$_tmpl$2, $i7OB2$ssrHydrationKey(), !variantToUse() || originalPrice.loading ? $i7OB2$escape($i7OB2$createComponent((0, $d134eae24341b4a1$export$89c6019e4baa40b1), {
|
|
1188
1209
|
height: "1em",
|
|
1189
1210
|
width: "20ch"
|
|
1190
1211
|
})) : $i7OB2$escape(originalPrice()));
|
|
@@ -1242,7 +1263,7 @@ async function $62a8f670f8464532$var$checkIfIsAffectedByChromeBug326498383() {
|
|
|
1242
1263
|
// Passive to make it more likely to run the callback before our timeout if the browser is under high load during the test
|
|
1243
1264
|
{
|
|
1244
1265
|
once: true,
|
|
1245
|
-
passive:
|
|
1266
|
+
passive: false
|
|
1246
1267
|
});
|
|
1247
1268
|
await timeoutPromise;
|
|
1248
1269
|
} catch (e) {
|
|
@@ -1250,7 +1271,7 @@ async function $62a8f670f8464532$var$checkIfIsAffectedByChromeBug326498383() {
|
|
|
1250
1271
|
}
|
|
1251
1272
|
return isAffected;
|
|
1252
1273
|
}
|
|
1253
|
-
var $7555dcad3b8a4632$var$_tmpl$ = ["<div", ' class="scroll-padding"
|
|
1274
|
+
var $7555dcad3b8a4632$var$_tmpl$ = ["<div", ' class="scroll-padding">', "</div>"];
|
|
1254
1275
|
function $7555dcad3b8a4632$export$ebf0b1d4f90c09ae({
|
|
1255
1276
|
displays_: displays_,
|
|
1256
1277
|
FavoriteButton_: FavoriteButton_,
|
|
@@ -1266,31 +1287,42 @@ function $7555dcad3b8a4632$export$ebf0b1d4f90c09ae({
|
|
|
1266
1287
|
// The following three signals just contain the state if the animations are actually running and should only be set by the respective animation code
|
|
1267
1288
|
const textFadeInAnimationRunning = $i7OB2$createSignal(false);
|
|
1268
1289
|
const [getSecondPartAnimationRunning] = textFadeInAnimationRunning;
|
|
1269
|
-
// These expanded variables are what's used to trigger the second and first phase animations
|
|
1270
1290
|
$62a8f670f8464532$export$7b9a0e99f0aeb2f3().then(is => isAffectedByChromeBug = is);
|
|
1271
1291
|
return $i7OB2$createComponent((0, $011607bdf658f807$export$e68cff63f76bd15b), {
|
|
1272
1292
|
get children() {
|
|
1273
1293
|
return $i7OB2$createComponent((0, $i7OB2$Show), {
|
|
1274
1294
|
get when() {
|
|
1275
|
-
return containerWidth_();
|
|
1295
|
+
return containerWidth_() || !displays_;
|
|
1276
1296
|
},
|
|
1277
1297
|
get children() {
|
|
1278
|
-
return $i7OB2$ssr($7555dcad3b8a4632$var$_tmpl$, $i7OB2$ssrHydrationKey(),
|
|
1279
|
-
|
|
1280
|
-
|
|
1281
|
-
|
|
1282
|
-
|
|
1283
|
-
|
|
1284
|
-
|
|
1285
|
-
|
|
1286
|
-
|
|
1287
|
-
|
|
1288
|
-
|
|
1289
|
-
|
|
1290
|
-
|
|
1291
|
-
|
|
1292
|
-
|
|
1293
|
-
|
|
1298
|
+
return $i7OB2$ssr($7555dcad3b8a4632$var$_tmpl$, $i7OB2$ssrHydrationKey(), $i7OB2$ssrElement("div", $i7OB2$mergeProps({
|
|
1299
|
+
get ["class"]() {
|
|
1300
|
+
return `look-overlay ${userWantsExpanded() ? "expanded" : ""} ${!getSecondPartAnimationRunning() && userWantsExpanded() ? "resting-fully-expanded" : ""}`;
|
|
1301
|
+
}
|
|
1302
|
+
}, () => displays_ && {
|
|
1303
|
+
style: `--look-card-width:${containerWidth_()}px;--look-item-height:${lookItemHeight() || 200}px`
|
|
1304
|
+
}), () => $i7OB2$escape($i7OB2$createComponent((0, $i7OB2$Index), {
|
|
1305
|
+
get each() {
|
|
1306
|
+
return displays_ || Array.from({
|
|
1307
|
+
length: 4
|
|
1308
|
+
});
|
|
1309
|
+
},
|
|
1310
|
+
children: (display, index) => {
|
|
1311
|
+
return $i7OB2$createComponent((0, $5a6c386e1bde5665$export$b73ed90f0ee50dc3), {
|
|
1312
|
+
animationDuration_: animationDuration_,
|
|
1313
|
+
display_: display,
|
|
1314
|
+
FavoriteButton_: FavoriteButton_,
|
|
1315
|
+
isExpanded_: userWantsExpanded,
|
|
1316
|
+
textFadeInAnimationRunning_: textFadeInAnimationRunning,
|
|
1317
|
+
outerRef_: el => $i7OB2$createEffect(() => {
|
|
1318
|
+
if (index !== 0) return;
|
|
1319
|
+
const resizeObserver = new ResizeObserver($i7OB2$catchify(records => setLookItemHeight(records.at(-1).contentRect.height)));
|
|
1320
|
+
resizeObserver.observe(el);
|
|
1321
|
+
$i7OB2$onCleanup(() => resizeObserver.disconnect());
|
|
1322
|
+
})
|
|
1323
|
+
});
|
|
1324
|
+
}
|
|
1325
|
+
})), false));
|
|
1294
1326
|
}
|
|
1295
1327
|
});
|
|
1296
1328
|
}
|
|
@@ -1316,18 +1348,22 @@ function $7555dcad3b8a4632$var$scrollingFunctionForChrome(element, targetScrollY
|
|
|
1316
1348
|
// Bootstrap our animation - it will get called right before next frame shall be rendered.
|
|
1317
1349
|
requestAnimationFrame(step);
|
|
1318
1350
|
}
|
|
1319
|
-
var $28ee4f7db3cc44b8$var$_tmpl$ = ["<div", ' class="
|
|
1320
|
-
function $28ee4f7db3cc44b8$export$44809a8a3e867e30(
|
|
1351
|
+
var $28ee4f7db3cc44b8$var$_tmpl$ = ["<div", ' class="', '"></div>'];
|
|
1352
|
+
function $28ee4f7db3cc44b8$export$44809a8a3e867e30({
|
|
1353
|
+
display_: display_,
|
|
1354
|
+
expandedLooksSignal_: [expandedLooks_, setExpandedLooks],
|
|
1355
|
+
FavoriteButton_: FavoriteButton_,
|
|
1356
|
+
placeholderImageAspectRatio_: placeholderImageAspectRatio_,
|
|
1357
|
+
animationDuration_: animationDuration_
|
|
1358
|
+
}) {
|
|
1321
1359
|
// TODO: shopify, run displayTransformers to get dynamic prices
|
|
1322
1360
|
// TODO: format prices
|
|
1323
|
-
const
|
|
1324
|
-
const [coverImage] = display?.image_urls || [];
|
|
1361
|
+
const [coverImage] = display_?.image_urls || [];
|
|
1325
1362
|
const useWantsExpandedSignal_ = $i7OB2$createSignal(false);
|
|
1326
1363
|
const [userWantsExpanded, setUserWantsExpanded] = useWantsExpandedSignal_;
|
|
1327
|
-
const [expandedLooks_, setExpandedLooks] = info?.expandedLooksSignal_ || [];
|
|
1328
1364
|
const supportsHover_ = $dc9262ef6f786812$export$d9f36cf74e24d595("(hover: hover) and (pointer: fine)");
|
|
1329
1365
|
const us = Symbol("look");
|
|
1330
|
-
const container = $i7OB2$ssr($28ee4f7db3cc44b8$var$_tmpl$, $i7OB2$ssrHydrationKey(),
|
|
1366
|
+
const container = $i7OB2$ssr($28ee4f7db3cc44b8$var$_tmpl$, $i7OB2$ssrHydrationKey(), `look-card ${!display_ ? "placeholder" : ""}`);
|
|
1331
1367
|
const containerWidth_ = $2449872a62a75a20$export$ebdc3711f7e02ccd(container);
|
|
1332
1368
|
const clickHandler = $i7OB2$catchify(({
|
|
1333
1369
|
target: target
|
|
@@ -1338,7 +1374,7 @@ function $28ee4f7db3cc44b8$export$44809a8a3e867e30(display, info, FavoriteButton
|
|
|
1338
1374
|
});
|
|
1339
1375
|
addEventListener("click", clickHandler);
|
|
1340
1376
|
$i7OB2$onCleanup(() => removeEventListener("click", clickHandler));
|
|
1341
|
-
$i7OB2$createEffect(() => setExpandedLooks
|
|
1377
|
+
$i7OB2$createEffect(() => setExpandedLooks(prev => {
|
|
1342
1378
|
if (userWantsExpanded()) {
|
|
1343
1379
|
// Close the other expanded looks
|
|
1344
1380
|
prev.clear();
|
|
@@ -1348,41 +1384,41 @@ function $28ee4f7db3cc44b8$export$44809a8a3e867e30(display, info, FavoriteButton
|
|
|
1348
1384
|
return prev;
|
|
1349
1385
|
}));
|
|
1350
1386
|
// Close us if another look expands
|
|
1351
|
-
$i7OB2$createEffect(() =>
|
|
1352
|
-
$i7OB2$insert(container, () => $i7OB2$createComponent((0, $i7OB2$Show), {
|
|
1353
|
-
when:
|
|
1387
|
+
$i7OB2$createEffect(() => !expandedLooks_().has(us) && setUserWantsExpanded(false));
|
|
1388
|
+
$i7OB2$insert(container, () => [$i7OB2$createComponent((0, $i7OB2$Show), {
|
|
1389
|
+
when: display_,
|
|
1354
1390
|
get fallback() {
|
|
1355
1391
|
return $i7OB2$createComponent((0, $7f60f09116a3fe61$export$3f37af283f8fb843), {
|
|
1356
|
-
|
|
1357
|
-
height: "100%"
|
|
1392
|
+
aspectRatio: placeholderImageAspectRatio_
|
|
1358
1393
|
});
|
|
1359
1394
|
},
|
|
1360
1395
|
get children() {
|
|
1361
|
-
return
|
|
1396
|
+
return $i7OB2$createComponent((0, $70bb27cc6be01fc7$export$9d4a4b669b1929ab), {
|
|
1362
1397
|
src: coverImage,
|
|
1363
|
-
aspectRatio:
|
|
1398
|
+
aspectRatio: placeholderImageAspectRatio_,
|
|
1364
1399
|
autoAdjustAspectRatio: true
|
|
1365
|
-
})
|
|
1366
|
-
get displays_() {
|
|
1367
|
-
return display?.displays;
|
|
1368
|
-
},
|
|
1369
|
-
userWantsExpandedSignal_: useWantsExpandedSignal_,
|
|
1370
|
-
containerWidth_: containerWidth_,
|
|
1371
|
-
animationDuration_: animationDuration_,
|
|
1372
|
-
supportsHover_: supportsHover_,
|
|
1373
|
-
FavoriteButton_: FavoriteButton_
|
|
1374
|
-
})];
|
|
1400
|
+
});
|
|
1375
1401
|
}
|
|
1376
|
-
}))
|
|
1402
|
+
}), $i7OB2$createComponent((0, $7555dcad3b8a4632$export$ebf0b1d4f90c09ae), {
|
|
1403
|
+
get displays_() {
|
|
1404
|
+
return display_?.displays;
|
|
1405
|
+
},
|
|
1406
|
+
userWantsExpandedSignal_: useWantsExpandedSignal_,
|
|
1407
|
+
containerWidth_: containerWidth_,
|
|
1408
|
+
animationDuration_: animationDuration_,
|
|
1409
|
+
supportsHover_: supportsHover_,
|
|
1410
|
+
FavoriteButton_: FavoriteButton_
|
|
1411
|
+
})]);
|
|
1377
1412
|
return container;
|
|
1378
1413
|
}
|
|
1379
|
-
var $f577edfe2240eec1$var$_tmpl$ = ["<div", ' class="depict recommendations looks">', "</div>"];
|
|
1414
|
+
var $f577edfe2240eec1$var$_tmpl$ = ["<div", ' class="depict recommendations looks" style="', '">', "</div>"];
|
|
1380
1415
|
let $f577edfe2240eec1$var$expandedLooksSignal_;
|
|
1381
1416
|
function $f577edfe2240eec1$export$1935e6bdfc5ed8ce(props) {
|
|
1382
1417
|
return $16b52438165aafe2$export$23fca46f3143581f(() => {
|
|
1383
1418
|
$f577edfe2240eec1$var$expandedLooksSignal_ ||= $i7OB2$createSignal(new Set(), {
|
|
1384
1419
|
equals: false
|
|
1385
1420
|
});
|
|
1421
|
+
const expandingAnimationDuration = 240;
|
|
1386
1422
|
const grid_spacing_override = $i7OB2$createMemo(() => {
|
|
1387
1423
|
const {
|
|
1388
1424
|
gridSpacing_: gridSpacing_
|
|
@@ -1412,13 +1448,16 @@ function $f577edfe2240eec1$export$1935e6bdfc5ed8ce(props) {
|
|
|
1412
1448
|
return [];
|
|
1413
1449
|
return decoded.listings;
|
|
1414
1450
|
});
|
|
1415
|
-
return $i7OB2$ssr($f577edfe2240eec1$var$_tmpl$, $i7OB2$ssrHydrationKey(), $i7OB2$escape($i7OB2$createComponent((0, $011607bdf658f807$export$e68cff63f76bd15b), {
|
|
1451
|
+
return $i7OB2$ssr($f577edfe2240eec1$var$_tmpl$, $i7OB2$ssrHydrationKey(), $i7OB2$ssrStyle(`--animation-duration: ${expandingAnimationDuration}ms`), $i7OB2$escape($i7OB2$createComponent((0, $011607bdf658f807$export$e68cff63f76bd15b), {
|
|
1416
1452
|
get children() {
|
|
1417
1453
|
return $c4492d24952ed731$export$d41d19e89346fa2({
|
|
1418
|
-
product_card_template_: (display, info) => $28ee4f7db3cc44b8$export$44809a8a3e867e30(
|
|
1419
|
-
|
|
1454
|
+
product_card_template_: (display, info) => $28ee4f7db3cc44b8$export$44809a8a3e867e30({
|
|
1455
|
+
display_: display,
|
|
1456
|
+
FavoriteButton_: props.FavoriteButton_,
|
|
1457
|
+
placeholderImageAspectRatio_: props.imagePlaceholderAspectRatio_,
|
|
1458
|
+
animationDuration_: expandingAnimationDuration,
|
|
1420
1459
|
expandedLooksSignal_: $f577edfe2240eec1$var$expandedLooksSignal_
|
|
1421
|
-
}
|
|
1460
|
+
}),
|
|
1422
1461
|
recommendations_resource_: looksResource,
|
|
1423
1462
|
title_: () => props.title_,
|
|
1424
1463
|
layout_options_: $i7OB2$createMemo(() => ({
|
|
@@ -2511,10 +2550,6 @@ function $5285d2814d0fac0c$export$b94867ecbd698f21({
|
|
|
2511
2550
|
}
|
|
2512
2551
|
function $aea1edf92433e81e$export$fe334901e8bebd57() {
|
|
2513
2552
|
const cleanup_fns = [];
|
|
2514
|
-
$i7OB2$dlog("DISABLING SCROLLING");
|
|
2515
|
-
$i7OB2$onCleanup(() => {
|
|
2516
|
-
console.log("RE-ENABLING SCROLLING");
|
|
2517
|
-
});
|
|
2518
2553
|
const cleanup = () => cleanup_fns.forEach(f => f());
|
|
2519
2554
|
// use an animation to automatically retain the `overflow` values and all other styling
|
|
2520
2555
|
for (const element of [document.documentElement, document.body]) {
|