@depict-ai/ui 2.1.17 → 2.1.19
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 -18
- package/ES10/index.d.ts +15 -10
- package/ES10/index.js +57 -19
- package/latest/index.cjs +56 -18
- package/latest/index.d.ts +15 -10
- package/latest/index.js +57 -19
- package/package.json +3 -3
- package/server/ES10/index.cjs +35 -10
- package/server/ES10/index.d.ts +15 -10
- package/server/ES10/index.js +36 -11
- package/server/latest/index.cjs +35 -10
- package/server/latest/index.d.ts +15 -10
- package/server/latest/index.js +36 -11
package/server/latest/index.cjs
CHANGED
|
@@ -70,7 +70,7 @@ $parcel$export(module.exports, "defaultColsAtSize", () => $a3280f0aad997933$expo
|
|
|
70
70
|
$parcel$export(module.exports, "defaultCategoryTitlePlugin", () => $a3280f0aad997933$export$7bf543b9d9be2c22);
|
|
71
71
|
$parcel$export(module.exports, "version", () => $b757f75811f3261f$export$83d89fbfd8236492);
|
|
72
72
|
/*! Depict.ai search and product listing SDK */
|
|
73
|
-
const $b757f75811f3261f$export$83d89fbfd8236492 = "2.1.
|
|
73
|
+
const $b757f75811f3261f$export$83d89fbfd8236492 = "2.1.19";
|
|
74
74
|
const $1ab22f2cd39b3061$var$fallback_operator = "in";
|
|
75
75
|
const $1ab22f2cd39b3061$var$fallback_token = "";
|
|
76
76
|
const $1ab22f2cd39b3061$var$legacy_filter_prefix = "filter_";
|
|
@@ -257,9 +257,9 @@ function $84798aaa863a4909$export$e68cff63f76bd15b(props) {
|
|
|
257
257
|
function $84798aaa863a4909$export$8d0c4fdbb05a2f2e() {
|
|
258
258
|
return $5vyXB$solidjs.useContext($84798aaa863a4909$var$ListingContext);
|
|
259
259
|
}
|
|
260
|
-
const $93304d59a9747aa6$var$_tmpl$ = ["<div", ' style="', '"></div>
|
|
260
|
+
const $93304d59a9747aa6$var$_tmpl$ = ["<div", ' style="', '"', "></div>"];
|
|
261
261
|
function $93304d59a9747aa6$export$94026ee33dbabc26(props) {
|
|
262
|
-
return $5vyXB$solidjsweb.ssr($93304d59a9747aa6$var$_tmpl$, $5vyXB$solidjsweb.ssrHydrationKey(), $5vyXB$solidjsweb.ssrStyle(`position:relative;width:100%;padding-bottom:${1 / props.aspectRatio * 100}%`));
|
|
262
|
+
return $5vyXB$solidjsweb.ssr($93304d59a9747aa6$var$_tmpl$, $5vyXB$solidjsweb.ssrHydrationKey(), $5vyXB$solidjsweb.ssrStyle(`position:relative;width:100%;padding-bottom:${1 / props.aspectRatio * 100}%`), $5vyXB$solidjsweb.ssrAttribute("class", $5vyXB$solidjsweb.escape(props.class, true), false));
|
|
263
263
|
}
|
|
264
264
|
function $19950faaac026e09$export$e6fffe67d4cdd848(whatToWatch) {
|
|
265
265
|
const [size, setSize] = $5vyXB$solidjs.createSignal(0);
|
|
@@ -418,6 +418,9 @@ function $a33065cfed827fc0$export$e4b984597b71e989(props) {
|
|
|
418
418
|
const container = $5vyXB$solidjsweb.createComponent((0, $93304d59a9747aa6$export$94026ee33dbabc26), {
|
|
419
419
|
get aspectRatio() {
|
|
420
420
|
return props.aspectRatio;
|
|
421
|
+
},
|
|
422
|
+
get ["class"]() {
|
|
423
|
+
return props.class;
|
|
421
424
|
}
|
|
422
425
|
});
|
|
423
426
|
const owner = $5vyXB$solidjs.getOwner();
|
|
@@ -922,16 +925,26 @@ function $f48d0fbb00835aaa$export$445d8d3f5f706a40(props, container_element, ins
|
|
|
922
925
|
if (insert_after_container) container_element.after(style_element);
|
|
923
926
|
return [container_element, view_more_button_container(), view_less_button_container(), style_element];
|
|
924
927
|
}
|
|
928
|
+
const $363ce4d1d71041aa$var$_tmpl$ = ["<h2", ' class="recs-title">', "</h2>"];
|
|
925
929
|
function $363ce4d1d71041aa$export$d41d19e89346fa2({
|
|
926
930
|
recommendations_resource_: recommendations_resource_,
|
|
927
931
|
product_card_template_: product_card_template_,
|
|
928
932
|
layout_options_: layout_options_,
|
|
929
933
|
merchant_: merchant_,
|
|
930
|
-
market_: market_
|
|
934
|
+
market_: market_,
|
|
935
|
+
title_: title_
|
|
931
936
|
}) {
|
|
932
937
|
const is_showing_something = $5vyXB$solidjs.createMemo(() => recommendations_resource_.loading || recommendations_resource_()?.length);
|
|
938
|
+
const title = $5vyXB$solidjs.createMemo(() => title_?.()); // In case getter/accessor creates elements, don't create them twice
|
|
933
939
|
const num_placeholders_ = () => 20;
|
|
934
|
-
const slider = $5vyXB$solidjsweb.createComponent((0, $
|
|
940
|
+
const slider = [$5vyXB$solidjsweb.createComponent((0, $5vyXB$solidjs.Show), {
|
|
941
|
+
get when() {
|
|
942
|
+
return title();
|
|
943
|
+
},
|
|
944
|
+
get children() {
|
|
945
|
+
return $5vyXB$solidjsweb.ssr($363ce4d1d71041aa$var$_tmpl$, $5vyXB$solidjsweb.ssrHydrationKey(), $5vyXB$solidjsweb.escape(title()));
|
|
946
|
+
}
|
|
947
|
+
}), $5vyXB$solidjsweb.createComponent((0, $a0e53f99354809d9$export$6649caad96ef8870), {
|
|
935
948
|
arrow_height_: 25,
|
|
936
949
|
arrow_width_: 12.5,
|
|
937
950
|
disable_fading_: true,
|
|
@@ -970,7 +983,7 @@ function $363ce4d1d71041aa$export$d41d19e89346fa2({
|
|
|
970
983
|
}
|
|
971
984
|
});
|
|
972
985
|
}
|
|
973
|
-
});
|
|
986
|
+
})];
|
|
974
987
|
return $5vyXB$solidjsweb.createComponent((0, $5vyXB$solidjs.Show), {
|
|
975
988
|
get when() {
|
|
976
989
|
return is_showing_something();
|
|
@@ -1036,6 +1049,7 @@ function $72f96c4782db0b1b$export$9574e176201e5e8d(props) {
|
|
|
1036
1049
|
recommendations_resource_: recommendations_resource_,
|
|
1037
1050
|
market_: () => props.market,
|
|
1038
1051
|
merchant_: () => props.merchant,
|
|
1052
|
+
title_: () => props.title,
|
|
1039
1053
|
layout_options_: $5vyXB$solidjs.createMemo(() => ({
|
|
1040
1054
|
cols_at_size: $4e04be41243c3d80$export$6daf8749b65a1b77(props.cols_at_size),
|
|
1041
1055
|
...grid_spacing_override()
|
|
@@ -1045,18 +1059,28 @@ function $72f96c4782db0b1b$export$9574e176201e5e8d(props) {
|
|
|
1045
1059
|
})));
|
|
1046
1060
|
}, "RecommendationSlider failed");
|
|
1047
1061
|
}
|
|
1048
|
-
const $b8e79813f4f7ebe4$var$_tmpl$ = ["<
|
|
1062
|
+
const $b8e79813f4f7ebe4$var$_tmpl$ = ["<h2", ' class="recs-title">', "</h2>"],
|
|
1063
|
+
$b8e79813f4f7ebe4$var$_tmpl$2 = ["<div", ' class="recommendation-grid"><!--$-->', "<!--/--><!--$-->", "<!--/--></div>"];
|
|
1049
1064
|
function $b8e79813f4f7ebe4$export$7da560f849543dff({
|
|
1050
1065
|
recommendations_resource_: recommendations_resource_,
|
|
1051
1066
|
product_card_template_: product_card_template_,
|
|
1052
1067
|
layout_options_: layout_options_,
|
|
1053
1068
|
merchant_: merchant_,
|
|
1054
1069
|
market_: market_,
|
|
1055
|
-
rows_object_: rows_object_
|
|
1070
|
+
rows_object_: rows_object_,
|
|
1071
|
+
title_: title_
|
|
1056
1072
|
}) {
|
|
1057
1073
|
const is_showing_something = $5vyXB$solidjs.createMemo(() => recommendations_resource_.loading || recommendations_resource_()?.length);
|
|
1074
|
+
const title = $5vyXB$solidjs.createMemo(() => title_?.()); // In case getter/accessor creates elements, don't create them twice
|
|
1058
1075
|
const num_placeholders_ = () => 20;
|
|
1059
|
-
const elements = $5vyXB$solidjsweb.
|
|
1076
|
+
const elements = [$5vyXB$solidjsweb.createComponent((0, $5vyXB$solidjs.Show), {
|
|
1077
|
+
get when() {
|
|
1078
|
+
return title();
|
|
1079
|
+
},
|
|
1080
|
+
get children() {
|
|
1081
|
+
return $5vyXB$solidjsweb.ssr($b8e79813f4f7ebe4$var$_tmpl$, $5vyXB$solidjsweb.ssrHydrationKey(), $5vyXB$solidjsweb.escape(title()));
|
|
1082
|
+
}
|
|
1083
|
+
}), $5vyXB$solidjsweb.ssr($b8e79813f4f7ebe4$var$_tmpl$2, $5vyXB$solidjsweb.ssrHydrationKey(), $5vyXB$solidjsweb.escape($fc23d7668ae0011d$export$a2cc176055f8f08()), $5vyXB$solidjsweb.escape($5vyXB$solidjsweb.createComponent((0, $f48d0fbb00835aaa$export$d21e32dfedac04be), $5vyXB$solidjsweb.mergeProps({
|
|
1060
1084
|
get rows() {
|
|
1061
1085
|
return rows_object_();
|
|
1062
1086
|
},
|
|
@@ -1087,7 +1111,7 @@ function $b8e79813f4f7ebe4$export$7da560f849543dff({
|
|
|
1087
1111
|
}
|
|
1088
1112
|
});
|
|
1089
1113
|
}
|
|
1090
|
-
}))));
|
|
1114
|
+
}))))];
|
|
1091
1115
|
return $5vyXB$solidjsweb.createComponent((0, $5vyXB$solidjs.Show), {
|
|
1092
1116
|
get when() {
|
|
1093
1117
|
return is_showing_something();
|
|
@@ -1137,6 +1161,7 @@ function $1f8dbf7e28b3eff2$export$9756467d34d91cdb(props) {
|
|
|
1137
1161
|
recommendations_resource_: recommendations_resource_,
|
|
1138
1162
|
market_: () => props.market,
|
|
1139
1163
|
merchant_: () => props.merchant,
|
|
1164
|
+
title_: () => props.title,
|
|
1140
1165
|
layout_options_: $5vyXB$solidjs.createMemo(() => ({
|
|
1141
1166
|
cols_at_size: $4e04be41243c3d80$export$6daf8749b65a1b77(props.cols_at_size),
|
|
1142
1167
|
...grid_spacing_override()
|
package/server/latest/index.d.ts
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { JSX, Accessor, Signal, Setter } from "solid-js";
|
|
2
2
|
import { report, Display, Amazing_Slider, ColsAtSize, Elem, ModernDisplay, Node_Array } from "@depict-ai/utilishared/latest";
|
|
3
|
-
import { SearchFilter,
|
|
3
|
+
import { SearchFilter, SearchRequestV2 } from "@depict-ai/types/api/SearchRequestV2";
|
|
4
4
|
import { SearchFilter as _SearchFilter1, ContentLink, SearchResponse } from "@depict-ai/types/api/SearchResponse";
|
|
5
|
-
import { BaseCategoryDisplay,
|
|
5
|
+
import { BaseCategoryDisplay, ProductListingResponseV2 } from "@depict-ai/types/api/ProductListingResponseV2";
|
|
6
6
|
import { CategorySuggestion, SearchSuggestionsResponse } from "@depict-ai/types/api/SearchSuggestionsResponse";
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
7
|
+
import { BaseSearchRequestV2 } from "@depict-ai/types/api/BaseSearchRequestV2";
|
|
8
|
+
import { SearchSuggestionsRequestV2 } from "@depict-ai/types/api/SearchSuggestionsRequestV2";
|
|
9
9
|
import { ProductListingRequestV2 } from "@depict-ai/types/api/ProductListingRequestV2";
|
|
10
|
-
export const version = "2.1.
|
|
10
|
+
export const version = "2.1.19";
|
|
11
11
|
/**
|
|
12
12
|
* Use `javascript_media_query` but return a reactive accessor instead of taking a callback function
|
|
13
13
|
*/
|
|
@@ -145,6 +145,7 @@ export function useListing(): Record<symbol, any> | undefined;
|
|
|
145
145
|
*/
|
|
146
146
|
export function ImageContainer(props: {
|
|
147
147
|
aspectRatio: number;
|
|
148
|
+
class?: string;
|
|
148
149
|
}): HTMLDivElement;
|
|
149
150
|
/**
|
|
150
151
|
* Returns an accessor that will update when the size of the provided element changes, to be used with ResponsiveImg
|
|
@@ -173,10 +174,12 @@ export const shopifyContainedImageContextSymbol: unique symbol;
|
|
|
173
174
|
* This works because the listings (recs, search, plp) all are wrapped in `<ListingProvider>`'s. This means all components rendered within can use `useListing` to get an object to write data to that will be the same for all components rendered within that listing. The first instance of this component rendered within a listing puts a ResizeObserver on its div and the other components then just set the sizes attribute of their image to that.
|
|
174
175
|
* @property src image source
|
|
175
176
|
* @property aspectRatio aspect ratio of the image
|
|
177
|
+
* @property class extra class to add to the container
|
|
176
178
|
*/
|
|
177
179
|
export function ShopifyContainedImage(props: {
|
|
178
180
|
src: string;
|
|
179
181
|
aspectRatio: number;
|
|
182
|
+
class?: string;
|
|
180
183
|
}): HTMLDivElement;
|
|
181
184
|
/** @jsxImportSource solid-js */
|
|
182
185
|
export function GenericSliderArrowButton(props?: {
|
|
@@ -242,6 +245,7 @@ type RecommendationSliderBaseProps<T extends Display> = {
|
|
|
242
245
|
grid_spacing: SDKGridSpacing;
|
|
243
246
|
cols_at_size: SDKColsAtSize;
|
|
244
247
|
recommendations: Promise<T[]>;
|
|
248
|
+
title?: JSX.Element;
|
|
245
249
|
};
|
|
246
250
|
/**
|
|
247
251
|
* Render a grid with provided recommendations. displayTransformers will not be applied for this since you yourself provide the displays. Options are reactive.
|
|
@@ -260,6 +264,7 @@ export function RecommendationSlider<T extends Display>(props: {
|
|
|
260
264
|
type RecommendationGridBaseProps<T extends Display> = {
|
|
261
265
|
grid_spacing: SDKGridSpacing;
|
|
262
266
|
cols_at_size: SDKColsAtSize;
|
|
267
|
+
title?: JSX.Element;
|
|
263
268
|
recommendations: Promise<T[]>;
|
|
264
269
|
view_more_button?: {
|
|
265
270
|
text: string;
|
|
@@ -650,7 +655,7 @@ type ReplaceBaseCategoryDisplay<T> = T extends BaseCategoryDisplay ? BaseCategor
|
|
|
650
655
|
type _AddPageUrlToDisplay1<T extends any[]> = (T[number] & {
|
|
651
656
|
page_url: string;
|
|
652
657
|
})[];
|
|
653
|
-
type ProductListingResponseAfterURLCreator = { [K in keyof
|
|
658
|
+
type ProductListingResponseAfterURLCreator = { [K in keyof ProductListingResponseV2]: K extends "displays" ? _AddPageUrlToDisplay1<ProductListingResponseV2[K]> : K extends "breadcrumb" | "quick_links" ? ReplaceBaseCategoryDisplay<ProductListingResponseV2[K]> : K extends "filters" ? AddActualFieldToFilters<ProductListingResponseV2[K]> : ProductListingResponseV2[K] };
|
|
654
659
|
type DepictAPIConstructorOptions<InputDisplay extends Display, OutputDisplay extends ModernDisplay | never> = {
|
|
655
660
|
get_metadata?: () => Promise<{
|
|
656
661
|
[k: string]: string;
|
|
@@ -667,16 +672,16 @@ export class DepictAPI<InputDisplay extends Display, OutputDisplay extends Moder
|
|
|
667
672
|
page_url_creator: PageURLCreator<ModernDisplay, OutputDisplay> | undefined;
|
|
668
673
|
display_transformers: DisplayTransformers<ModernDisplay, OutputDisplay> | undefined;
|
|
669
674
|
constructor(options: DepictAPIConstructorOptions<InputDisplay, OutputDisplay>);
|
|
670
|
-
suggest(input_req:
|
|
675
|
+
suggest(input_req: SearchSuggestionsRequestV2): Promise<SearchSuggestionsResponseAfterURLCreator & {
|
|
671
676
|
failed?: true;
|
|
672
677
|
}>;
|
|
673
|
-
query(input_req:
|
|
678
|
+
query(input_req: SearchRequestV2): Promise<SearchResponseAfterURLCreator & {
|
|
674
679
|
failed?: true;
|
|
675
680
|
}>;
|
|
676
681
|
list(input_req: ProductListingRequestV2): Promise<ProductListingResponseAfterURLCreator & {
|
|
677
682
|
failed?: true;
|
|
678
683
|
}>;
|
|
679
|
-
get_recommended<T extends Display>(input_req:
|
|
684
|
+
get_recommended<T extends Display>(input_req: BaseSearchRequestV2): Promise<{
|
|
680
685
|
displays: T[];
|
|
681
686
|
} & {
|
|
682
687
|
failed?: true | undefined;
|
|
@@ -1139,4 +1144,4 @@ export const defaultCategoryTitlePlugin: ({
|
|
|
1139
1144
|
category_title_: import("solid-js").Accessor<string | undefined>;
|
|
1140
1145
|
product_count_: import("solid-js").JSX.Element;
|
|
1141
1146
|
}) => import("solid-js").JSX.Element;
|
|
1142
|
-
export type { SearchFilter } from "@depict-ai/types/api/
|
|
1147
|
+
export type { SearchFilter } from "@depict-ai/types/api/SearchRequestV2";
|
package/server/latest/index.js
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { add_to_version_info as $i7OB2$add_to_version_info, base64_encode_unicode as $i7OB2$base64_encode_unicode, base64_decode_unicode as $i7OB2$base64_decode_unicode, dlog as $i7OB2$dlog, queueMacroTask as $i7OB2$queueMacroTask, catchify as $i7OB2$catchify, is_safari as $i7OB2$is_safari, observer as $i7OB2$observer, dwarn as $i7OB2$dwarn, Amazing_Slider as $i7OB2$Amazing_Slider, slider_snap_css as $i7OB2$slider_snap_css, slider_fading_factory as $i7OB2$slider_fading_factory, slider_fractional_factory as $i7OB2$slider_fractional_factory, camelCasifyObject as $i7OB2$camelCasifyObject, make_random_classname as $i7OB2$make_random_classname, n_col_styling_with_dist as $i7OB2$n_col_styling_with_dist, 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, useExpandingContainer as $i7OB2$useExpandingContainer, standard_price_format as $i7OB2$standard_price_format, hex_to_rgb as $i7OB2$hex_to_rgb, relative_luminance_from_rgb as $i7OB2$relative_luminance_from_rgb, fetch_recs as $i7OB2$fetch_recs, snakeCasifyObject as $i7OB2$snakeCasifyObject, instant_exec_on_suspect_history_change as $i7OB2$instant_exec_on_suspect_history_change, base_url as $i7OB2$base_url, get_depict_id as $i7OB2$get_depict_id, get_user_id as $i7OB2$get_user_id, get_session_id as $i7OB2$get_session_id, sort_obj as $i7OB2$sort_obj, fetch_retry as $i7OB2$fetch_retry, add_version_query_params as $i7OB2$add_version_query_params, make_url_with_query_params as $i7OB2$make_url_with_query_params, edit_current_page_meta_tags as $i7OB2$edit_current_page_meta_tags, javascript_media_query as $i7OB2$javascript_media_query, use_href_accessor as $i7OB2$use_href_accessor, make_asyncIterable_exiter as $i7OB2$make_asyncIterable_exiter, href_change_ipns as $i7OB2$href_change_ipns, ContainedImage as $i7OB2$ContainedImage, deparallelize_no_drop as $i7OB2$deparallelize_no_drop, ListenableSet as $i7OB2$ListenableSet, insert_surfaces as $i7OB2$insert_surfaces } from "@depict-ai/utilishared/latest";
|
|
2
|
-
import { createComponent as $i7OB2$createComponent, insert as $i7OB2$insert, ssr as $i7OB2$ssr, ssrHydrationKey as $i7OB2$ssrHydrationKey, ssrStyle as $i7OB2$ssrStyle,
|
|
2
|
+
import { createComponent as $i7OB2$createComponent, insert as $i7OB2$insert, ssr as $i7OB2$ssr, ssrHydrationKey as $i7OB2$ssrHydrationKey, ssrStyle as $i7OB2$ssrStyle, ssrAttribute as $i7OB2$ssrAttribute, escape as $i7OB2$escape, spread as $i7OB2$spread, mergeProps as $i7OB2$mergeProps1, isServer as $i7OB2$isServer, ssrElement as $i7OB2$ssrElement, ssrClassList as $i7OB2$ssrClassList, Dynamic as $i7OB2$Dynamic } from "solid-js/web";
|
|
3
3
|
import { createSignal as $i7OB2$createSignal, getOwner as $i7OB2$getOwner, createEffect as $i7OB2$createEffect, runWithOwner as $i7OB2$runWithOwner, onCleanup as $i7OB2$onCleanup, createMemo as $i7OB2$createMemo, createContext as $i7OB2$createContext, useContext as $i7OB2$useContext, mergeProps as $i7OB2$mergeProps, Show as $i7OB2$Show, createResource as $i7OB2$createResource, Suspense as $i7OB2$Suspense, untrack as $i7OB2$untrack, createRenderEffect as $i7OB2$createRenderEffect, Index as $i7OB2$Index, createRoot as $i7OB2$createRoot, For as $i7OB2$For, createUniqueId as $i7OB2$createUniqueId, createComputed as $i7OB2$createComputed, ErrorBoundary as $i7OB2$ErrorBoundary, batch as $i7OB2$batch, on as $i7OB2$on, createReaction as $i7OB2$createReaction, mapArray as $i7OB2$mapArray } from "solid-js";
|
|
4
4
|
import { createStore as $i7OB2$createStore, reconcile as $i7OB2$reconcile } from "solid-js/store";
|
|
5
5
|
|
|
6
6
|
/*! Depict.ai search and product listing SDK */
|
|
7
7
|
import { register_es_version } from "../../multi_import_deduplicator.mjs";
|
|
8
8
|
register_es_version("ui", "latest");
|
|
9
|
-
const $ec291e0010116877$export$83d89fbfd8236492 = "2.1.
|
|
9
|
+
const $ec291e0010116877$export$83d89fbfd8236492 = "2.1.19";
|
|
10
10
|
const $4147651646da990a$var$fallback_operator = "in";
|
|
11
11
|
const $4147651646da990a$var$fallback_token = "";
|
|
12
12
|
const $4147651646da990a$var$legacy_filter_prefix = "filter_";
|
|
@@ -193,9 +193,9 @@ function $011607bdf658f807$export$e68cff63f76bd15b(props) {
|
|
|
193
193
|
function $011607bdf658f807$export$8d0c4fdbb05a2f2e() {
|
|
194
194
|
return $i7OB2$useContext($011607bdf658f807$var$ListingContext);
|
|
195
195
|
}
|
|
196
|
-
const $f18d425032111270$var$_tmpl$ = ["<div", ' style="', '"></div>
|
|
196
|
+
const $f18d425032111270$var$_tmpl$ = ["<div", ' style="', '"', "></div>"];
|
|
197
197
|
function $f18d425032111270$export$94026ee33dbabc26(props) {
|
|
198
|
-
return $i7OB2$ssr($f18d425032111270$var$_tmpl$, $i7OB2$ssrHydrationKey(), $i7OB2$ssrStyle(`position:relative;width:100%;padding-bottom:${1 / props.aspectRatio * 100}%`));
|
|
198
|
+
return $i7OB2$ssr($f18d425032111270$var$_tmpl$, $i7OB2$ssrHydrationKey(), $i7OB2$ssrStyle(`position:relative;width:100%;padding-bottom:${1 / props.aspectRatio * 100}%`), $i7OB2$ssrAttribute("class", $i7OB2$escape(props.class, true), false));
|
|
199
199
|
}
|
|
200
200
|
function $e8ffe11ed01df0fe$export$e6fffe67d4cdd848(whatToWatch) {
|
|
201
201
|
const [size, setSize] = $i7OB2$createSignal(0);
|
|
@@ -354,6 +354,9 @@ function $660070e2a394b3c3$export$e4b984597b71e989(props) {
|
|
|
354
354
|
const container = $i7OB2$createComponent((0, $f18d425032111270$export$94026ee33dbabc26), {
|
|
355
355
|
get aspectRatio() {
|
|
356
356
|
return props.aspectRatio;
|
|
357
|
+
},
|
|
358
|
+
get ["class"]() {
|
|
359
|
+
return props.class;
|
|
357
360
|
}
|
|
358
361
|
});
|
|
359
362
|
const owner = $i7OB2$getOwner();
|
|
@@ -858,16 +861,26 @@ function $c8d5ff4524619fcd$export$445d8d3f5f706a40(props, container_element, ins
|
|
|
858
861
|
if (insert_after_container) container_element.after(style_element);
|
|
859
862
|
return [container_element, view_more_button_container(), view_less_button_container(), style_element];
|
|
860
863
|
}
|
|
864
|
+
const $c4492d24952ed731$var$_tmpl$ = ["<h2", ' class="recs-title">', "</h2>"];
|
|
861
865
|
function $c4492d24952ed731$export$d41d19e89346fa2({
|
|
862
866
|
recommendations_resource_: recommendations_resource_,
|
|
863
867
|
product_card_template_: product_card_template_,
|
|
864
868
|
layout_options_: layout_options_,
|
|
865
869
|
merchant_: merchant_,
|
|
866
|
-
market_: market_
|
|
870
|
+
market_: market_,
|
|
871
|
+
title_: title_
|
|
867
872
|
}) {
|
|
868
873
|
const is_showing_something = $i7OB2$createMemo(() => recommendations_resource_.loading || recommendations_resource_()?.length);
|
|
874
|
+
const title = $i7OB2$createMemo(() => title_?.()); // In case getter/accessor creates elements, don't create them twice
|
|
869
875
|
const num_placeholders_ = () => 20;
|
|
870
|
-
const slider = $i7OB2$createComponent((0, $
|
|
876
|
+
const slider = [$i7OB2$createComponent((0, $i7OB2$Show), {
|
|
877
|
+
get when() {
|
|
878
|
+
return title();
|
|
879
|
+
},
|
|
880
|
+
get children() {
|
|
881
|
+
return $i7OB2$ssr($c4492d24952ed731$var$_tmpl$, $i7OB2$ssrHydrationKey(), $i7OB2$escape(title()));
|
|
882
|
+
}
|
|
883
|
+
}), $i7OB2$createComponent((0, $f32e14878e75af51$export$6649caad96ef8870), {
|
|
871
884
|
arrow_height_: 25,
|
|
872
885
|
arrow_width_: 12.5,
|
|
873
886
|
disable_fading_: true,
|
|
@@ -906,7 +919,7 @@ function $c4492d24952ed731$export$d41d19e89346fa2({
|
|
|
906
919
|
}
|
|
907
920
|
});
|
|
908
921
|
}
|
|
909
|
-
});
|
|
922
|
+
})];
|
|
910
923
|
return $i7OB2$createComponent((0, $i7OB2$Show), {
|
|
911
924
|
get when() {
|
|
912
925
|
return is_showing_something();
|
|
@@ -972,6 +985,7 @@ function $ee116da074deb002$export$9574e176201e5e8d(props) {
|
|
|
972
985
|
recommendations_resource_: recommendations_resource_,
|
|
973
986
|
market_: () => props.market,
|
|
974
987
|
merchant_: () => props.merchant,
|
|
988
|
+
title_: () => props.title,
|
|
975
989
|
layout_options_: $i7OB2$createMemo(() => ({
|
|
976
990
|
cols_at_size: $b5cccc8ee7d24677$export$6daf8749b65a1b77(props.cols_at_size),
|
|
977
991
|
...grid_spacing_override()
|
|
@@ -981,18 +995,28 @@ function $ee116da074deb002$export$9574e176201e5e8d(props) {
|
|
|
981
995
|
})));
|
|
982
996
|
}, "RecommendationSlider failed");
|
|
983
997
|
}
|
|
984
|
-
const $3da8afe3ed57cf34$var$_tmpl$ = ["<
|
|
998
|
+
const $3da8afe3ed57cf34$var$_tmpl$ = ["<h2", ' class="recs-title">', "</h2>"],
|
|
999
|
+
$3da8afe3ed57cf34$var$_tmpl$2 = ["<div", ' class="recommendation-grid"><!--$-->', "<!--/--><!--$-->", "<!--/--></div>"];
|
|
985
1000
|
function $3da8afe3ed57cf34$export$7da560f849543dff({
|
|
986
1001
|
recommendations_resource_: recommendations_resource_,
|
|
987
1002
|
product_card_template_: product_card_template_,
|
|
988
1003
|
layout_options_: layout_options_,
|
|
989
1004
|
merchant_: merchant_,
|
|
990
1005
|
market_: market_,
|
|
991
|
-
rows_object_: rows_object_
|
|
1006
|
+
rows_object_: rows_object_,
|
|
1007
|
+
title_: title_
|
|
992
1008
|
}) {
|
|
993
1009
|
const is_showing_something = $i7OB2$createMemo(() => recommendations_resource_.loading || recommendations_resource_()?.length);
|
|
1010
|
+
const title = $i7OB2$createMemo(() => title_?.()); // In case getter/accessor creates elements, don't create them twice
|
|
994
1011
|
const num_placeholders_ = () => 20;
|
|
995
|
-
const elements = $i7OB2$
|
|
1012
|
+
const elements = [$i7OB2$createComponent((0, $i7OB2$Show), {
|
|
1013
|
+
get when() {
|
|
1014
|
+
return title();
|
|
1015
|
+
},
|
|
1016
|
+
get children() {
|
|
1017
|
+
return $i7OB2$ssr($3da8afe3ed57cf34$var$_tmpl$, $i7OB2$ssrHydrationKey(), $i7OB2$escape(title()));
|
|
1018
|
+
}
|
|
1019
|
+
}), $i7OB2$ssr($3da8afe3ed57cf34$var$_tmpl$2, $i7OB2$ssrHydrationKey(), $i7OB2$escape($a458486f22b22f63$export$a2cc176055f8f08()), $i7OB2$escape($i7OB2$createComponent((0, $c8d5ff4524619fcd$export$d21e32dfedac04be), $i7OB2$mergeProps1({
|
|
996
1020
|
get rows() {
|
|
997
1021
|
return rows_object_();
|
|
998
1022
|
},
|
|
@@ -1023,7 +1047,7 @@ function $3da8afe3ed57cf34$export$7da560f849543dff({
|
|
|
1023
1047
|
}
|
|
1024
1048
|
});
|
|
1025
1049
|
}
|
|
1026
|
-
}))));
|
|
1050
|
+
}))))];
|
|
1027
1051
|
return $i7OB2$createComponent((0, $i7OB2$Show), {
|
|
1028
1052
|
get when() {
|
|
1029
1053
|
return is_showing_something();
|
|
@@ -1073,6 +1097,7 @@ function $9ea5383493360761$export$9756467d34d91cdb(props) {
|
|
|
1073
1097
|
recommendations_resource_: recommendations_resource_,
|
|
1074
1098
|
market_: () => props.market,
|
|
1075
1099
|
merchant_: () => props.merchant,
|
|
1100
|
+
title_: () => props.title,
|
|
1076
1101
|
layout_options_: $i7OB2$createMemo(() => ({
|
|
1077
1102
|
cols_at_size: $b5cccc8ee7d24677$export$6daf8749b65a1b77(props.cols_at_size),
|
|
1078
1103
|
...grid_spacing_override()
|