@depict-ai/ui 4.7.31 → 4.7.32

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.
@@ -111,7 +111,7 @@ $parcel$export(module.exports, "BreadCrumbs", () => $335c02c1241a9ca8$export$5b7
111
111
  $parcel$export(module.exports, "QuickLinks", () => $335c02c1241a9ca8$export$de035477d6fef996);
112
112
  $parcel$export(module.exports, "CategoryPage", () => $c10e33c4681f8c9b$export$e2bf8ce7779e827e);
113
113
  /*! Depict.ai search and product listing SDK */
114
- const $aa1938dec50d6c12$export$83d89fbfd8236492 = "4.7.31";
114
+ const $aa1938dec50d6c12$export$83d89fbfd8236492 = "4.7.32";
115
115
  function $3e17e871e9d0911d$export$d9f36cf74e24d595(media_query) {
116
116
  const signal = $3hooq$solidjs.createSignal(false);
117
117
  $3hooq$solidjs.onCleanup($3hooq$depictaiutilishared.javascript_media_query(media_query, _ref => {
@@ -179,7 +179,7 @@ function $b8a8d61b3ec5f5ac$export$3f37af283f8fb843(props) {
179
179
  }
180
180
  });
181
181
  }
182
- var $f8f375d6245ffff2$var$_tmpl$ = ["<div", ' class="content-block-wrapper" style="', '">', "</div>"];
182
+ var $f8f375d6245ffff2$var$_tmpl$ = ["<div", ' class="', '" style="', '">', "</div>"];
183
183
  function $f8f375d6245ffff2$export$791ef57e62e21c3f(_ref) {
184
184
  let {
185
185
  content_blocks_: incoming_content_blocks,
@@ -311,7 +311,7 @@ function $f8f375d6245ffff2$var$wrap_blocks_in_div(rendered_content_blocks, max_s
311
311
  return !rendering_delayed();
312
312
  },
313
313
  get children() {
314
- return $3hooq$solidjsweb.ssr($f8f375d6245ffff2$var$_tmpl$, $3hooq$solidjsweb.ssrHydrationKey(), "grid-column:" + "span ".concat($3hooq$solidjsweb.escape(final_span_columns(), true)) + (";grid-row:" + "span ".concat($3hooq$solidjsweb.escape(final_span_rows(), true))) + (";spans_columns_variable_name:" + $3hooq$solidjsweb.escape(final_span_columns(), true)), $3hooq$solidjsweb.escape($3hooq$solidjsweb.createComponent($f8f375d6245ffff2$var$RenderContent, {
314
+ return $3hooq$solidjsweb.ssr($f8f375d6245ffff2$var$_tmpl$, $3hooq$solidjsweb.ssrHydrationKey(), "content-block-wrapper ".concat(final_span_columns() === max_span_columns() ? "spans-whole-row" : ""), "grid-column:" + "span ".concat($3hooq$solidjsweb.escape(final_span_columns(), true)) + (";grid-row:" + "span ".concat($3hooq$solidjsweb.escape(final_span_rows(), true))) + (";spans_columns_variable_name:" + $3hooq$solidjsweb.escape(final_span_columns(), true)), $3hooq$solidjsweb.escape($3hooq$solidjsweb.createComponent($f8f375d6245ffff2$var$RenderContent, {
315
315
  get content() {
316
316
  return block.content;
317
317
  }
@@ -8977,7 +8977,8 @@ class $9cbefc32b9dab36d$export$f34314aa9505732e {
8977
8977
  // Please make sure that the signal created by below line always updates AFTER selected_filters_ updates on a "popstate" event. If the filter cache is popped before the selected filters are the code in create_modified_filters() is going to re-calculate search_local_filter_cache without knowing the real value of search_selected_filters, and we'll end up with too few filters in search_local_filter_cache in some cases
8978
8978
  local_filter_cache: [],
8979
8979
  expanded_hierarchical_filters: [],
8980
- scroll_restoration_data: []
8980
+ scroll_restoration_data: [],
8981
+ history_content_blocks: []
8981
8982
  }),
8982
8983
  router_: $parcel$interopDefault($3hooq$babelruntimehelpersclassPrivateFieldGet)(this, $9cbefc32b9dab36d$var$_router),
8983
8984
  prefix_: "category" + unique_instance_key_for_state + "_"
@@ -13296,15 +13297,77 @@ function $8b366fdb0c76194d$var$clear_if_opened_new_tab_with_sideways_url_params_
13296
13297
  });
13297
13298
  tracking_function_for_plp_results(plp_results_);
13298
13299
  }
13299
- var $c19709057a32b2e7$var$_tmpl$ = ["<a", "><img", ' style="', '"></a>'],
13300
- $c19709057a32b2e7$var$_tmpl$2 = ["<a", "><video", ' muted="" autoplay="" playsinline="" loop style="', '"></video></a>'];
13300
+ var $c19709057a32b2e7$var$_tmpl$ = ["<a", ' class="d-standard-content-wrapper"', "><video", ' muted="" autoplay="" playsinline="" loop class="d-standard-content"></video></a>'];
13301
13301
  function $c19709057a32b2e7$export$780a853d15174484(_ref) {
13302
13302
  let {
13303
- contentBlock: contentBlock,
13303
+ contentBlock_: {
13304
+ content: {
13305
+ link: link,
13306
+ type: type,
13307
+ url: mediaUrl
13308
+ }
13309
+ },
13304
13310
  router_: router_
13305
13311
  } = _ref;
13306
- if (contentBlock.content.type === "image") return () => $3hooq$solidjsweb.ssr($c19709057a32b2e7$var$_tmpl$, $3hooq$solidjsweb.ssrHydrationKey() + $3hooq$solidjsweb.ssrAttribute("href", $3hooq$solidjsweb.escape(contentBlock.content.link, true), false), $3hooq$solidjsweb.ssrAttribute("src", $3hooq$solidjsweb.escape(contentBlock.content.url, true), false), "width:100%;height:100%;object-fit:cover;position:absolute;inset:0");
13307
- if (contentBlock.content.type === "video") return () => $3hooq$solidjsweb.ssr($c19709057a32b2e7$var$_tmpl$2, $3hooq$solidjsweb.ssrHydrationKey() + $3hooq$solidjsweb.ssrAttribute("href", $3hooq$solidjsweb.escape(contentBlock.content.link, true), false), $3hooq$solidjsweb.ssrAttribute("src", $3hooq$solidjsweb.escape(contentBlock.content.url, true), false), "width:100%;height:100%;object-fit:cover;position:absolute;inset:0");
13312
+ if (type === "image") {
13313
+ const [wrapperSize, setWrapperSize] = $3hooq$solidjs.createSignal();
13314
+ return $3hooq$solidjsweb.createComponent((0, $3hooq$solidjsweb.Dynamic), $3hooq$solidjsweb.mergeProps({
13315
+ component: link ? "a" : "div",
13316
+ "class": "d-standard-content-wrapper",
13317
+ get onClick() {
13318
+ return $3hooq$depictaiutilisharedlatest.catchify(ev => link && router_.navigate_.go_to_({
13319
+ new_url_: link,
13320
+ is_replace_: false,
13321
+ event_: ev
13322
+ }));
13323
+ }
13324
+ }, link && {
13325
+ href: link
13326
+ }, {
13327
+ get children() {
13328
+ return $3hooq$solidjsweb.createComponent((0, $858fdcf73148519f$export$6e5611bc7e57e477), {
13329
+ get size() {
13330
+ return $3hooq$solidjs.createMemo(() => {
13331
+ var _wrapperSize;
13332
+ return ((_wrapperSize = wrapperSize()) === null || _wrapperSize === void 0 ? void 0 : _wrapperSize()) || 0;
13333
+ });
13334
+ },
13335
+ src: mediaUrl,
13336
+ "class": "d-standard-content"
13337
+ });
13338
+ }
13339
+ }));
13340
+ }
13341
+ if (type === "video") {
13342
+ const pageVisible = $e7a7d2fe8a8217d8$export$54299a3c81f5425();
13343
+ return $3hooq$solidjsweb.ssr($c19709057a32b2e7$var$_tmpl$, $3hooq$solidjsweb.ssrHydrationKey(), $3hooq$solidjsweb.ssrAttribute("href", $3hooq$solidjsweb.escape(link, true), false), $3hooq$solidjsweb.ssrAttribute("src", $3hooq$solidjsweb.escape(mediaUrl, true), false));
13344
+ }
13345
+ }
13346
+ function $0c035bbe7e30b438$export$7a92d995f1bf3592(history_content_blocks_, plp_meta, content_blocks_by_row_, router_) {
13347
+ const [historyContentBlocks, setHistoryContentBlocks] = history_content_blocks_;
13348
+ $3hooq$solidjs.createEffect(() => {
13349
+ var _plp_meta;
13350
+ const serverContentBlock = (_plp_meta = plp_meta()) === null || _plp_meta === void 0 ? void 0 : _plp_meta.content_blocks;
13351
+ if (serverContentBlock && JSON.stringify(serverContentBlock) !== JSON.stringify(historyContentBlocks())) setHistoryContentBlocks(serverContentBlock);
13352
+ });
13353
+ const contentBlocksByRow = $3hooq$solidjs.createMemo(() => {
13354
+ if (content_blocks_by_row_()) return content_blocks_by_row_();
13355
+ const content = [];
13356
+ historyContentBlocks().forEach(row => {
13357
+ const contentBlock = {
13358
+ span_columns: row.span_columns,
13359
+ span_rows: row.span_rows,
13360
+ position: row.position,
13361
+ content: () => $3hooq$solidjsweb.createComponent((0, $c19709057a32b2e7$export$780a853d15174484), {
13362
+ contentBlock_: row,
13363
+ router_: router_
13364
+ })
13365
+ };
13366
+ content[row.row] = contentBlock;
13367
+ });
13368
+ return content;
13369
+ });
13370
+ return contentBlocksByRow;
13308
13371
  }
13309
13372
  var $ede6c70ecdca46fe$var$_tmpl$ = ["<div", ' class="product-count"><!--$-->', "<!--/--> <!--$-->", "<!--/--></div>"],
13310
13373
  $ede6c70ecdca46fe$var$_tmpl$2 = ["<div", "></div>"],
@@ -13334,6 +13397,7 @@ function $ede6c70ecdca46fe$export$f7d2f673fc2f091d(_ref) {
13334
13397
  show_breadcrumbs_: show_breadcrumbs_,
13335
13398
  layout_options_: layout_options_,
13336
13399
  scroll_restoration_data_: scroll_restoration_data_,
13400
+ history_content_blocks_: history_content_blocks_,
13337
13401
  product_card_template_: product_card_template_,
13338
13402
  sideways_filter_clearing_flag_: sideways_filter_clearing_flag_,
13339
13403
  sorting_query_param_: sorting_query_param_,
@@ -13402,24 +13466,7 @@ function $ede6c70ecdca46fe$export$f7d2f673fc2f091d(_ref) {
13402
13466
  }));
13403
13467
  // Make "Get Listing" request to get quicklinks, breadcrumbs, title, etc
13404
13468
  const [plp_meta] = $3hooq$solidjs.createResource(meta_query_base, $3hooq$depictaiutilisharedlatest.catchify(query => depict_api_.get_listing(query)));
13405
- const contentBlocksByRow = $3hooq$solidjs.createMemo(() => {
13406
- var _plp_meta, _plp_meta$content_blo;
13407
- if (content_blocks_by_row_()) return content_blocks_by_row_();
13408
- const content = [];
13409
- (_plp_meta = plp_meta()) === null || _plp_meta === void 0 || (_plp_meta$content_blo = _plp_meta.content_blocks) === null || _plp_meta$content_blo === void 0 || _plp_meta$content_blo.forEach(row => {
13410
- const contentBlock = {
13411
- span_columns: row.span_columns,
13412
- span_rows: row.span_rows,
13413
- position: row.position,
13414
- content: $c19709057a32b2e7$export$780a853d15174484({
13415
- contentBlock: row,
13416
- router_: router_
13417
- })
13418
- };
13419
- content[row.row] = contentBlock;
13420
- });
13421
- return content;
13422
- });
13469
+ const contentBlocksByRow = $0c035bbe7e30b438$export$7a92d995f1bf3592(history_content_blocks_, plp_meta, content_blocks_by_row_, router_);
13423
13470
  const available_sortings_ = $3hooq$solidjs.createMemo(() => {
13424
13471
  var _plp_products_, _plp_products_$sorts;
13425
13472
  return (_plp_products_ = plp_products_()) === null || _plp_products_ === void 0 ? void 0 : (_plp_products_$sorts = _plp_products_.sorts) === null || _plp_products_$sorts === void 0 ? void 0 : _plp_products_$sorts.map(sort => {
@@ -13435,13 +13482,13 @@ function $ede6c70ecdca46fe$export$f7d2f673fc2f091d(_ref) {
13435
13482
  return (_plp_products_2 = plp_products_()) === null || _plp_products_2 === void 0 ? void 0 : _plp_products_2.filters;
13436
13483
  });
13437
13484
  const title = $3hooq$solidjs.createMemo(() => {
13438
- var _plp_meta2;
13439
- return (_plp_meta2 = plp_meta()) === null || _plp_meta2 === void 0 ? void 0 : _plp_meta2.title;
13485
+ var _plp_meta;
13486
+ return (_plp_meta = plp_meta()) === null || _plp_meta === void 0 ? void 0 : _plp_meta.title;
13440
13487
  });
13441
13488
  const crumb_data_ = $ede6c70ecdca46fe$var$add_us_to_crumbs(plp_meta);
13442
13489
  const quicklinks_data_ = $3hooq$solidjs.createMemo(() => {
13443
- var _plp_meta3;
13444
- return (_plp_meta3 = plp_meta()) === null || _plp_meta3 === void 0 ? void 0 : _plp_meta3.quick_links;
13490
+ var _plp_meta2;
13491
+ return (_plp_meta2 = plp_meta()) === null || _plp_meta2 === void 0 ? void 0 : _plp_meta2.quick_links;
13445
13492
  });
13446
13493
  const [sort_or_filter_open_, set_sort_or_filter_open_] = $3hooq$solidjs.createSignal(false);
13447
13494
  const [desktop_filter_elements_, set_desktop_filter_elements] = $3hooq$solidjs.createSignal();
@@ -13707,8 +13754,8 @@ function $ede6c70ecdca46fe$export$f7d2f673fc2f091d(_ref) {
13707
13754
  function $ede6c70ecdca46fe$var$add_us_to_crumbs(plp_meta) {
13708
13755
  const href_accessor = $3hooq$depictaiutilisharedlatest.use_href_accessor();
13709
13756
  return $3hooq$solidjs.createMemo(() => {
13710
- var _plp_meta4;
13711
- const api_value = (_plp_meta4 = plp_meta()) === null || _plp_meta4 === void 0 ? void 0 : _plp_meta4.breadcrumbs;
13757
+ var _plp_meta3;
13758
+ const api_value = (_plp_meta3 = plp_meta()) === null || _plp_meta3 === void 0 ? void 0 : _plp_meta3.breadcrumbs;
13712
13759
  if (!api_value) return api_value;
13713
13760
  return [...api_value, $3hooq$solidjs.mergeProps(plp_meta(), {
13714
13761
  get page_url() {
@@ -13758,7 +13805,8 @@ function $c10e33c4681f8c9b$export$e2bf8ce7779e827e(props) {
13758
13805
  sorting_open: category_sorting_open_,
13759
13806
  expanded_filters: expanded_filters_,
13760
13807
  expanded_hierarchical_filters: expanded_hierarchical_filters_,
13761
- scroll_restoration_data: scroll_restoration_data_
13808
+ scroll_restoration_data: scroll_restoration_data_,
13809
+ history_content_blocks: history_content_blocks_
13762
13810
  } = depict_category.historyStateSignals_;
13763
13811
  const {
13764
13812
  current_sorting_: current_sorting_,
@@ -13810,6 +13858,7 @@ function $c10e33c4681f8c9b$export$e2bf8ce7779e827e(props) {
13810
13858
  sideways_filter_clearing_flag_: sideways_filter_clearing_flag_,
13811
13859
  content_blocks_by_row_: () => props.content_blocks_by_row,
13812
13860
  scroll_restoration_data_: scroll_restoration_data_,
13861
+ history_content_blocks_: history_content_blocks_,
13813
13862
  layout_options_: $3hooq$solidjs.createMemo(() => ({
13814
13863
  cols_at_size: $5401a6698b0c0658$export$6daf8749b65a1b77(props.cols_at_size),
13815
13864
  ...grid_spacing_override(),
@@ -3,7 +3,7 @@ import { report, Amazing_Slider, Display, useExpandingContainer, ColsAtSize, Ele
3
3
  import { SearchFilter, SearchRequestV3, SortModel } from "@depict-ai/types/api/SearchRequestV3";
4
4
  import { ContentLink, SearchResponse, SearchFilter as _SearchFilter1 } from "@depict-ai/types/api/SearchResponse";
5
5
  import { Ancestors, ListingSuggestion, SearchSuggestionsResponseV3 } from "@depict-ai/types/api/SearchSuggestionsResponseV3";
6
- import { ProductListing, GetListingResponse } from "@depict-ai/types/api/GetListingResponse";
6
+ import { ProductListing, GetListingResponse, ContentBlock as _ContentBlock1 } from "@depict-ai/types/api/GetListingResponse";
7
7
  import { ProductListingResponseV3, SearchFilter as _SearchFilter2 } from "@depict-ai/types/api/ProductListingResponseV3";
8
8
  import { SearchSuggestionsRequestV3 } from "@depict-ai/types/api/SearchSuggestionsRequestV3";
9
9
  import { ProductListingRequestV3 } from "@depict-ai/types/api/ProductListingRequestV3";
@@ -11,7 +11,7 @@ import { GetListingRequest } from "@depict-ai/types/api/GetListingRequest";
11
11
  import { BaseSearchRequestV3 } from "@depict-ai/types/api/BaseSearchRequestV3";
12
12
  import { FeaturedInDisplay } from "@depict-ai/types/api/FeaturedInResponseV3";
13
13
  import { SearchFilter as _SearchFilter3 } from "@depict-ai/types/api/SearchRequestV2";
14
- export const version = "4.7.31";
14
+ export const version = "4.7.32";
15
15
  /**
16
16
  * Use `javascript_media_query` but return a reactive accessor instead of taking a callback function
17
17
  */
@@ -108,10 +108,10 @@ export function remap_blocks_to_index<T = () => JSX.Element | Promise<JSX.Elemen
108
108
  })[];
109
109
  n_cols_currently_showing_: number | null;
110
110
  }): {
111
- content_blocks_by_index_: JSX.Element[];
111
+ content_blocks_by_index_: (Awaited<T> | T[])[];
112
112
  readonly displaced_products_?: undefined;
113
113
  } | {
114
- readonly content_blocks_by_index_: JSX.Element[];
114
+ readonly content_blocks_by_index_: (Awaited<T> | T[])[];
115
115
  readonly displaced_products_: (number | (true | undefined)[])[];
116
116
  };
117
117
  /**
@@ -1334,6 +1334,7 @@ export class DepictCategory<InputDisplay extends Display, OutputDisplay extends
1334
1334
  expanded_: boolean;
1335
1335
  }[]>;
1336
1336
  scroll_restoration_data: Signal<ScrollRestorationData>;
1337
+ history_content_blocks: Signal<_ContentBlock1[]>;
1337
1338
  };
1338
1339
  /**
1339
1340
  * Signal representing the currently selected filters. Will update to always reflect the state of the current URL. Calling the setter triggers a navigation (replaceState) to an updated URL.
@@ -1484,7 +1485,7 @@ type OpenModalParams<OriginalDisplay extends Display, OutputDisplay extends Mode
1484
1485
  * Open the modal with support for alignment.
1485
1486
  * @returns {void}
1486
1487
  */
1487
- export const open_modal_with_alignment: <OriginalDisplay extends Display, OutputDisplay extends unknown>(openModalParams: OpenModalParams<OriginalDisplay, OutputDisplay>) => void;
1488
+ export const open_modal_with_alignment: <OriginalDisplay extends Display, OutputDisplay extends ModernDisplay>(openModalParams: OpenModalParams<OriginalDisplay, OutputDisplay>) => void;
1488
1489
  export function open_search_with_shift_slash(open_search: VoidFunction): () => void;
1489
1490
  export interface PageReplacer {
1490
1491
  readonly render_: () => Node_Array;
@@ -1563,5 +1564,5 @@ export function CategoryPage<OriginalDisplay extends Display, OutputDisplay exte
1563
1564
  content_blocks_by_row?: ContentBlocksByRow;
1564
1565
  layout?: PossibleLayout;
1565
1566
  filterModalParent_?: HTMLElement | ShadowRoot;
1566
- }): import("@depict-ai/utilishared").Node_Array;
1567
+ }): import("@depict-ai/utilishared/latest").Node_Array;
1567
1568
  export type { SearchFilter } from "@depict-ai/types/api/SearchRequestV3";
@@ -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.7.31";
13
+ const $8db9a15135765c11$export$83d89fbfd8236492 = "4.7.32";
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 => {
@@ -78,7 +78,7 @@ function $3ab4aa97880fb88d$export$3f37af283f8fb843(props) {
78
78
  }
79
79
  });
80
80
  }
81
- var $ff7feae4dddd6073$var$_tmpl$ = ["<div", ' class="content-block-wrapper" style="', '">', "</div>"];
81
+ var $ff7feae4dddd6073$var$_tmpl$ = ["<div", ' class="', '" style="', '">', "</div>"];
82
82
  function $ff7feae4dddd6073$export$791ef57e62e21c3f(_ref) {
83
83
  let {
84
84
  content_blocks_: incoming_content_blocks,
@@ -210,7 +210,7 @@ function $ff7feae4dddd6073$var$wrap_blocks_in_div(rendered_content_blocks, max_s
210
210
  return !rendering_delayed();
211
211
  },
212
212
  get children() {
213
- return $b8hua$ssr($ff7feae4dddd6073$var$_tmpl$, $b8hua$ssrHydrationKey(), "grid-column:" + "span ".concat($b8hua$escape(final_span_columns(), true)) + (";grid-row:" + "span ".concat($b8hua$escape(final_span_rows(), true))) + (";spans_columns_variable_name:" + $b8hua$escape(final_span_columns(), true)), $b8hua$escape($b8hua$createComponent($ff7feae4dddd6073$var$RenderContent, {
213
+ return $b8hua$ssr($ff7feae4dddd6073$var$_tmpl$, $b8hua$ssrHydrationKey(), "content-block-wrapper ".concat(final_span_columns() === max_span_columns() ? "spans-whole-row" : ""), "grid-column:" + "span ".concat($b8hua$escape(final_span_columns(), true)) + (";grid-row:" + "span ".concat($b8hua$escape(final_span_rows(), true))) + (";spans_columns_variable_name:" + $b8hua$escape(final_span_columns(), true)), $b8hua$escape($b8hua$createComponent($ff7feae4dddd6073$var$RenderContent, {
214
214
  get content() {
215
215
  return block.content;
216
216
  }
@@ -8876,7 +8876,8 @@ class $f5f54892fd0c7d9f$export$f34314aa9505732e {
8876
8876
  // Please make sure that the signal created by below line always updates AFTER selected_filters_ updates on a "popstate" event. If the filter cache is popped before the selected filters are the code in create_modified_filters() is going to re-calculate search_local_filter_cache without knowing the real value of search_selected_filters, and we'll end up with too few filters in search_local_filter_cache in some cases
8877
8877
  local_filter_cache: [],
8878
8878
  expanded_hierarchical_filters: [],
8879
- scroll_restoration_data: []
8879
+ scroll_restoration_data: [],
8880
+ history_content_blocks: []
8880
8881
  }),
8881
8882
  router_: $b8hua$babelruntimehelpersclassPrivateFieldGet(this, $f5f54892fd0c7d9f$var$_router),
8882
8883
  prefix_: "category" + unique_instance_key_for_state + "_"
@@ -13195,15 +13196,77 @@ function $a4777acaffa35a82$var$clear_if_opened_new_tab_with_sideways_url_params_
13195
13196
  });
13196
13197
  tracking_function_for_plp_results(plp_results_);
13197
13198
  }
13198
- var $3b772ef9a35560fe$var$_tmpl$ = ["<a", "><img", ' style="', '"></a>'],
13199
- $3b772ef9a35560fe$var$_tmpl$2 = ["<a", "><video", ' muted="" autoplay="" playsinline="" loop style="', '"></video></a>'];
13199
+ var $3b772ef9a35560fe$var$_tmpl$ = ["<a", ' class="d-standard-content-wrapper"', "><video", ' muted="" autoplay="" playsinline="" loop class="d-standard-content"></video></a>'];
13200
13200
  function $3b772ef9a35560fe$export$780a853d15174484(_ref) {
13201
13201
  let {
13202
- contentBlock: contentBlock,
13202
+ contentBlock_: {
13203
+ content: {
13204
+ link: link,
13205
+ type: type,
13206
+ url: mediaUrl
13207
+ }
13208
+ },
13203
13209
  router_: router_
13204
13210
  } = _ref;
13205
- if (contentBlock.content.type === "image") return () => $b8hua$ssr($3b772ef9a35560fe$var$_tmpl$, $b8hua$ssrHydrationKey() + $b8hua$ssrAttribute("href", $b8hua$escape(contentBlock.content.link, true), false), $b8hua$ssrAttribute("src", $b8hua$escape(contentBlock.content.url, true), false), "width:100%;height:100%;object-fit:cover;position:absolute;inset:0");
13206
- if (contentBlock.content.type === "video") return () => $b8hua$ssr($3b772ef9a35560fe$var$_tmpl$2, $b8hua$ssrHydrationKey() + $b8hua$ssrAttribute("href", $b8hua$escape(contentBlock.content.link, true), false), $b8hua$ssrAttribute("src", $b8hua$escape(contentBlock.content.url, true), false), "width:100%;height:100%;object-fit:cover;position:absolute;inset:0");
13211
+ if (type === "image") {
13212
+ const [wrapperSize, setWrapperSize] = $b8hua$createSignal();
13213
+ return $b8hua$createComponent((0, $b8hua$Dynamic), $b8hua$mergeProps1({
13214
+ component: link ? "a" : "div",
13215
+ "class": "d-standard-content-wrapper",
13216
+ get onClick() {
13217
+ return $b8hua$catchify(ev => link && router_.navigate_.go_to_({
13218
+ new_url_: link,
13219
+ is_replace_: false,
13220
+ event_: ev
13221
+ }));
13222
+ }
13223
+ }, link && {
13224
+ href: link
13225
+ }, {
13226
+ get children() {
13227
+ return $b8hua$createComponent((0, $56047603f9d212b6$export$6e5611bc7e57e477), {
13228
+ get size() {
13229
+ return $b8hua$createMemo(() => {
13230
+ var _wrapperSize;
13231
+ return ((_wrapperSize = wrapperSize()) === null || _wrapperSize === void 0 ? void 0 : _wrapperSize()) || 0;
13232
+ });
13233
+ },
13234
+ src: mediaUrl,
13235
+ "class": "d-standard-content"
13236
+ });
13237
+ }
13238
+ }));
13239
+ }
13240
+ if (type === "video") {
13241
+ const pageVisible = $a35e6f680c5bbc60$export$54299a3c81f5425();
13242
+ return $b8hua$ssr($3b772ef9a35560fe$var$_tmpl$, $b8hua$ssrHydrationKey(), $b8hua$ssrAttribute("href", $b8hua$escape(link, true), false), $b8hua$ssrAttribute("src", $b8hua$escape(mediaUrl, true), false));
13243
+ }
13244
+ }
13245
+ function $12ff24fdc4b26d88$export$7a92d995f1bf3592(history_content_blocks_, plp_meta, content_blocks_by_row_, router_) {
13246
+ const [historyContentBlocks, setHistoryContentBlocks] = history_content_blocks_;
13247
+ $b8hua$createEffect(() => {
13248
+ var _plp_meta;
13249
+ const serverContentBlock = (_plp_meta = plp_meta()) === null || _plp_meta === void 0 ? void 0 : _plp_meta.content_blocks;
13250
+ if (serverContentBlock && JSON.stringify(serverContentBlock) !== JSON.stringify(historyContentBlocks())) setHistoryContentBlocks(serverContentBlock);
13251
+ });
13252
+ const contentBlocksByRow = $b8hua$createMemo(() => {
13253
+ if (content_blocks_by_row_()) return content_blocks_by_row_();
13254
+ const content = [];
13255
+ historyContentBlocks().forEach(row => {
13256
+ const contentBlock = {
13257
+ span_columns: row.span_columns,
13258
+ span_rows: row.span_rows,
13259
+ position: row.position,
13260
+ content: () => $b8hua$createComponent((0, $3b772ef9a35560fe$export$780a853d15174484), {
13261
+ contentBlock_: row,
13262
+ router_: router_
13263
+ })
13264
+ };
13265
+ content[row.row] = contentBlock;
13266
+ });
13267
+ return content;
13268
+ });
13269
+ return contentBlocksByRow;
13207
13270
  }
13208
13271
  var $4b4b262708b516ee$var$_tmpl$ = ["<div", ' class="product-count"><!--$-->', "<!--/--> <!--$-->", "<!--/--></div>"],
13209
13272
  $4b4b262708b516ee$var$_tmpl$2 = ["<div", "></div>"],
@@ -13233,6 +13296,7 @@ function $4b4b262708b516ee$export$f7d2f673fc2f091d(_ref) {
13233
13296
  show_breadcrumbs_: show_breadcrumbs_,
13234
13297
  layout_options_: layout_options_,
13235
13298
  scroll_restoration_data_: scroll_restoration_data_,
13299
+ history_content_blocks_: history_content_blocks_,
13236
13300
  product_card_template_: product_card_template_,
13237
13301
  sideways_filter_clearing_flag_: sideways_filter_clearing_flag_,
13238
13302
  sorting_query_param_: sorting_query_param_,
@@ -13301,24 +13365,7 @@ function $4b4b262708b516ee$export$f7d2f673fc2f091d(_ref) {
13301
13365
  }));
13302
13366
  // Make "Get Listing" request to get quicklinks, breadcrumbs, title, etc
13303
13367
  const [plp_meta] = $b8hua$createResource(meta_query_base, $b8hua$catchify(query => depict_api_.get_listing(query)));
13304
- const contentBlocksByRow = $b8hua$createMemo(() => {
13305
- var _plp_meta, _plp_meta$content_blo;
13306
- if (content_blocks_by_row_()) return content_blocks_by_row_();
13307
- const content = [];
13308
- (_plp_meta = plp_meta()) === null || _plp_meta === void 0 || (_plp_meta$content_blo = _plp_meta.content_blocks) === null || _plp_meta$content_blo === void 0 || _plp_meta$content_blo.forEach(row => {
13309
- const contentBlock = {
13310
- span_columns: row.span_columns,
13311
- span_rows: row.span_rows,
13312
- position: row.position,
13313
- content: $3b772ef9a35560fe$export$780a853d15174484({
13314
- contentBlock: row,
13315
- router_: router_
13316
- })
13317
- };
13318
- content[row.row] = contentBlock;
13319
- });
13320
- return content;
13321
- });
13368
+ const contentBlocksByRow = $12ff24fdc4b26d88$export$7a92d995f1bf3592(history_content_blocks_, plp_meta, content_blocks_by_row_, router_);
13322
13369
  const available_sortings_ = $b8hua$createMemo(() => {
13323
13370
  var _plp_products_, _plp_products_$sorts;
13324
13371
  return (_plp_products_ = plp_products_()) === null || _plp_products_ === void 0 ? void 0 : (_plp_products_$sorts = _plp_products_.sorts) === null || _plp_products_$sorts === void 0 ? void 0 : _plp_products_$sorts.map(sort => {
@@ -13334,13 +13381,13 @@ function $4b4b262708b516ee$export$f7d2f673fc2f091d(_ref) {
13334
13381
  return (_plp_products_2 = plp_products_()) === null || _plp_products_2 === void 0 ? void 0 : _plp_products_2.filters;
13335
13382
  });
13336
13383
  const title = $b8hua$createMemo(() => {
13337
- var _plp_meta2;
13338
- return (_plp_meta2 = plp_meta()) === null || _plp_meta2 === void 0 ? void 0 : _plp_meta2.title;
13384
+ var _plp_meta;
13385
+ return (_plp_meta = plp_meta()) === null || _plp_meta === void 0 ? void 0 : _plp_meta.title;
13339
13386
  });
13340
13387
  const crumb_data_ = $4b4b262708b516ee$var$add_us_to_crumbs(plp_meta);
13341
13388
  const quicklinks_data_ = $b8hua$createMemo(() => {
13342
- var _plp_meta3;
13343
- return (_plp_meta3 = plp_meta()) === null || _plp_meta3 === void 0 ? void 0 : _plp_meta3.quick_links;
13389
+ var _plp_meta2;
13390
+ return (_plp_meta2 = plp_meta()) === null || _plp_meta2 === void 0 ? void 0 : _plp_meta2.quick_links;
13344
13391
  });
13345
13392
  const [sort_or_filter_open_, set_sort_or_filter_open_] = $b8hua$createSignal(false);
13346
13393
  const [desktop_filter_elements_, set_desktop_filter_elements] = $b8hua$createSignal();
@@ -13606,8 +13653,8 @@ function $4b4b262708b516ee$export$f7d2f673fc2f091d(_ref) {
13606
13653
  function $4b4b262708b516ee$var$add_us_to_crumbs(plp_meta) {
13607
13654
  const href_accessor = $b8hua$use_href_accessor1();
13608
13655
  return $b8hua$createMemo(() => {
13609
- var _plp_meta4;
13610
- const api_value = (_plp_meta4 = plp_meta()) === null || _plp_meta4 === void 0 ? void 0 : _plp_meta4.breadcrumbs;
13656
+ var _plp_meta3;
13657
+ const api_value = (_plp_meta3 = plp_meta()) === null || _plp_meta3 === void 0 ? void 0 : _plp_meta3.breadcrumbs;
13611
13658
  if (!api_value) return api_value;
13612
13659
  return [...api_value, $b8hua$mergeProps(plp_meta(), {
13613
13660
  get page_url() {
@@ -13657,7 +13704,8 @@ function $8821a19349c36651$export$e2bf8ce7779e827e(props) {
13657
13704
  sorting_open: category_sorting_open_,
13658
13705
  expanded_filters: expanded_filters_,
13659
13706
  expanded_hierarchical_filters: expanded_hierarchical_filters_,
13660
- scroll_restoration_data: scroll_restoration_data_
13707
+ scroll_restoration_data: scroll_restoration_data_,
13708
+ history_content_blocks: history_content_blocks_
13661
13709
  } = depict_category.historyStateSignals_;
13662
13710
  const {
13663
13711
  current_sorting_: current_sorting_,
@@ -13709,6 +13757,7 @@ function $8821a19349c36651$export$e2bf8ce7779e827e(props) {
13709
13757
  sideways_filter_clearing_flag_: sideways_filter_clearing_flag_,
13710
13758
  content_blocks_by_row_: () => props.content_blocks_by_row,
13711
13759
  scroll_restoration_data_: scroll_restoration_data_,
13760
+ history_content_blocks_: history_content_blocks_,
13712
13761
  layout_options_: $b8hua$createMemo(() => ({
13713
13762
  cols_at_size: $a9c7ba6087881ac2$export$6daf8749b65a1b77(props.cols_at_size),
13714
13763
  ...grid_spacing_override(),
@@ -105,7 +105,7 @@ $parcel$export(module.exports, "BreadCrumbs", () => $1f4925833f07df29$export$5b7
105
105
  $parcel$export(module.exports, "QuickLinks", () => $1f4925833f07df29$export$de035477d6fef996);
106
106
  $parcel$export(module.exports, "CategoryPage", () => $14f289047713d67a$export$e2bf8ce7779e827e);
107
107
  /*! Depict.ai search and product listing SDK */
108
- const $b757f75811f3261f$export$83d89fbfd8236492 = "4.7.31";
108
+ const $b757f75811f3261f$export$83d89fbfd8236492 = "4.7.32";
109
109
  function $b54e6192d0caa293$export$d9f36cf74e24d595(media_query) {
110
110
  const signal = $5vyXB$solidjs.createSignal(false);
111
111
  $5vyXB$solidjs.onCleanup($5vyXB$depictaiutilishared.javascript_media_query(media_query, ({
@@ -166,7 +166,7 @@ function $3bc4a89b971a3af5$export$3f37af283f8fb843(props) {
166
166
  }
167
167
  });
168
168
  }
169
- var $d92f338ba8f9da9b$var$_tmpl$ = ["<div", ' class="content-block-wrapper" style="', '">', "</div>"];
169
+ var $d92f338ba8f9da9b$var$_tmpl$ = ["<div", ' class="', '" style="', '">', "</div>"];
170
170
  function $d92f338ba8f9da9b$export$791ef57e62e21c3f({
171
171
  content_blocks_: incoming_content_blocks,
172
172
  cols_at_size_: cols_at_size_,
@@ -289,7 +289,7 @@ function $d92f338ba8f9da9b$var$wrap_blocks_in_div(rendered_content_blocks, max_s
289
289
  return !rendering_delayed();
290
290
  },
291
291
  get children() {
292
- return $5vyXB$solidjsweb.ssr($d92f338ba8f9da9b$var$_tmpl$, $5vyXB$solidjsweb.ssrHydrationKey(), "grid-column:" + `span ${$5vyXB$solidjsweb.escape(final_span_columns(), true)}` + (";grid-row:" + `span ${$5vyXB$solidjsweb.escape(final_span_rows(), true)}`) + (";spans_columns_variable_name:" + $5vyXB$solidjsweb.escape(final_span_columns(), true)), $5vyXB$solidjsweb.escape($5vyXB$solidjsweb.createComponent($d92f338ba8f9da9b$var$RenderContent, {
292
+ return $5vyXB$solidjsweb.ssr($d92f338ba8f9da9b$var$_tmpl$, $5vyXB$solidjsweb.ssrHydrationKey(), `content-block-wrapper ${final_span_columns() === max_span_columns() ? "spans-whole-row" : ""}`, "grid-column:" + `span ${$5vyXB$solidjsweb.escape(final_span_columns(), true)}` + (";grid-row:" + `span ${$5vyXB$solidjsweb.escape(final_span_rows(), true)}`) + (";spans_columns_variable_name:" + $5vyXB$solidjsweb.escape(final_span_columns(), true)), $5vyXB$solidjsweb.escape($5vyXB$solidjsweb.createComponent($d92f338ba8f9da9b$var$RenderContent, {
293
293
  get content() {
294
294
  return block.content;
295
295
  }
@@ -8396,7 +8396,8 @@ class $48567ac5b39bac56$export$f34314aa9505732e {
8396
8396
  // Please make sure that the signal created by below line always updates AFTER selected_filters_ updates on a "popstate" event. If the filter cache is popped before the selected filters are the code in create_modified_filters() is going to re-calculate search_local_filter_cache without knowing the real value of search_selected_filters, and we'll end up with too few filters in search_local_filter_cache in some cases
8397
8397
  local_filter_cache: [],
8398
8398
  expanded_hierarchical_filters: [],
8399
- scroll_restoration_data: []
8399
+ scroll_restoration_data: [],
8400
+ history_content_blocks: []
8400
8401
  }),
8401
8402
  router_: this.#router,
8402
8403
  prefix_: "category" + unique_instance_key_for_state + "_"
@@ -12334,14 +12335,72 @@ function $ef972f5c10b1c5b4$var$clear_if_opened_new_tab_with_sideways_url_params_
12334
12335
  });
12335
12336
  tracking_function_for_plp_results(plp_results_);
12336
12337
  }
12337
- var $32c662f618f5d80d$var$_tmpl$ = ["<a", "><img", ' style="', '"></a>'],
12338
- $32c662f618f5d80d$var$_tmpl$2 = ["<a", "><video", ' muted="" autoplay="" playsinline="" loop style="', '"></video></a>'];
12338
+ var $32c662f618f5d80d$var$_tmpl$ = ["<a", ' class="d-standard-content-wrapper"', "><video", ' muted="" autoplay="" playsinline="" loop class="d-standard-content"></video></a>'];
12339
12339
  function $32c662f618f5d80d$export$780a853d15174484({
12340
- contentBlock: contentBlock,
12340
+ contentBlock_: {
12341
+ content: {
12342
+ link: link,
12343
+ type: type,
12344
+ url: mediaUrl
12345
+ }
12346
+ },
12341
12347
  router_: router_
12342
12348
  }) {
12343
- if (contentBlock.content.type === "image") return () => $5vyXB$solidjsweb.ssr($32c662f618f5d80d$var$_tmpl$, $5vyXB$solidjsweb.ssrHydrationKey() + $5vyXB$solidjsweb.ssrAttribute("href", $5vyXB$solidjsweb.escape(contentBlock.content.link, true), false), $5vyXB$solidjsweb.ssrAttribute("src", $5vyXB$solidjsweb.escape(contentBlock.content.url, true), false), "width:100%;height:100%;object-fit:cover;position:absolute;inset:0");
12344
- if (contentBlock.content.type === "video") return () => $5vyXB$solidjsweb.ssr($32c662f618f5d80d$var$_tmpl$2, $5vyXB$solidjsweb.ssrHydrationKey() + $5vyXB$solidjsweb.ssrAttribute("href", $5vyXB$solidjsweb.escape(contentBlock.content.link, true), false), $5vyXB$solidjsweb.ssrAttribute("src", $5vyXB$solidjsweb.escape(contentBlock.content.url, true), false), "width:100%;height:100%;object-fit:cover;position:absolute;inset:0");
12349
+ if (type === "image") {
12350
+ const [wrapperSize, setWrapperSize] = $5vyXB$solidjs.createSignal();
12351
+ return $5vyXB$solidjsweb.createComponent((0, $5vyXB$solidjsweb.Dynamic), $5vyXB$solidjsweb.mergeProps({
12352
+ component: link ? "a" : "div",
12353
+ "class": "d-standard-content-wrapper",
12354
+ get onClick() {
12355
+ return $5vyXB$depictaiutilisharedlatest.catchify(ev => link && router_.navigate_.go_to_({
12356
+ new_url_: link,
12357
+ is_replace_: false,
12358
+ event_: ev
12359
+ }));
12360
+ }
12361
+ }, link && {
12362
+ href: link
12363
+ }, {
12364
+ get children() {
12365
+ return $5vyXB$solidjsweb.createComponent((0, $19950faaac026e09$export$6e5611bc7e57e477), {
12366
+ get size() {
12367
+ return $5vyXB$solidjs.createMemo(() => wrapperSize()?.() || 0);
12368
+ },
12369
+ src: mediaUrl,
12370
+ "class": "d-standard-content"
12371
+ });
12372
+ }
12373
+ }));
12374
+ }
12375
+ if (type === "video") {
12376
+ const pageVisible = $55cbacb79d3e0cea$export$54299a3c81f5425();
12377
+ return $5vyXB$solidjsweb.ssr($32c662f618f5d80d$var$_tmpl$, $5vyXB$solidjsweb.ssrHydrationKey(), $5vyXB$solidjsweb.ssrAttribute("href", $5vyXB$solidjsweb.escape(link, true), false), $5vyXB$solidjsweb.ssrAttribute("src", $5vyXB$solidjsweb.escape(mediaUrl, true), false));
12378
+ }
12379
+ }
12380
+ function $0a80939bf0a1e9cc$export$7a92d995f1bf3592(history_content_blocks_, plp_meta, content_blocks_by_row_, router_) {
12381
+ const [historyContentBlocks, setHistoryContentBlocks] = history_content_blocks_;
12382
+ $5vyXB$solidjs.createEffect(() => {
12383
+ const serverContentBlock = plp_meta()?.content_blocks;
12384
+ if (serverContentBlock && JSON.stringify(serverContentBlock) !== JSON.stringify(historyContentBlocks())) setHistoryContentBlocks(serverContentBlock);
12385
+ });
12386
+ const contentBlocksByRow = $5vyXB$solidjs.createMemo(() => {
12387
+ if (content_blocks_by_row_()) return content_blocks_by_row_();
12388
+ const content = [];
12389
+ historyContentBlocks().forEach(row => {
12390
+ const contentBlock = {
12391
+ span_columns: row.span_columns,
12392
+ span_rows: row.span_rows,
12393
+ position: row.position,
12394
+ content: () => $5vyXB$solidjsweb.createComponent((0, $32c662f618f5d80d$export$780a853d15174484), {
12395
+ contentBlock_: row,
12396
+ router_: router_
12397
+ })
12398
+ };
12399
+ content[row.row] = contentBlock;
12400
+ });
12401
+ return content;
12402
+ });
12403
+ return contentBlocksByRow;
12345
12404
  }
12346
12405
  var $840d88a04b2d22a7$var$_tmpl$ = ["<div", ' class="product-count"><!--$-->', "<!--/--> <!--$-->", "<!--/--></div>"],
12347
12406
  $840d88a04b2d22a7$var$_tmpl$2 = ["<div", "></div>"],
@@ -12370,6 +12429,7 @@ function $840d88a04b2d22a7$export$f7d2f673fc2f091d({
12370
12429
  show_breadcrumbs_: show_breadcrumbs_,
12371
12430
  layout_options_: layout_options_,
12372
12431
  scroll_restoration_data_: scroll_restoration_data_,
12432
+ history_content_blocks_: history_content_blocks_,
12373
12433
  product_card_template_: product_card_template_,
12374
12434
  sideways_filter_clearing_flag_: sideways_filter_clearing_flag_,
12375
12435
  sorting_query_param_: sorting_query_param_,
@@ -12438,23 +12498,7 @@ function $840d88a04b2d22a7$export$f7d2f673fc2f091d({
12438
12498
  }));
12439
12499
  // Make "Get Listing" request to get quicklinks, breadcrumbs, title, etc
12440
12500
  const [plp_meta] = $5vyXB$solidjs.createResource(meta_query_base, $5vyXB$depictaiutilisharedlatest.catchify(query => depict_api_.get_listing(query)));
12441
- const contentBlocksByRow = $5vyXB$solidjs.createMemo(() => {
12442
- if (content_blocks_by_row_()) return content_blocks_by_row_();
12443
- const content = [];
12444
- plp_meta()?.content_blocks?.forEach(row => {
12445
- const contentBlock = {
12446
- span_columns: row.span_columns,
12447
- span_rows: row.span_rows,
12448
- position: row.position,
12449
- content: $32c662f618f5d80d$export$780a853d15174484({
12450
- contentBlock: row,
12451
- router_: router_
12452
- })
12453
- };
12454
- content[row.row] = contentBlock;
12455
- });
12456
- return content;
12457
- });
12501
+ const contentBlocksByRow = $0a80939bf0a1e9cc$export$7a92d995f1bf3592(history_content_blocks_, plp_meta, content_blocks_by_row_, router_);
12458
12502
  const available_sortings_ = $5vyXB$solidjs.createMemo(() => plp_products_()?.sorts?.map(sort => ({
12459
12503
  ...sort,
12460
12504
  order: sort.order ?? "desc"
@@ -12763,7 +12807,8 @@ function $14f289047713d67a$export$e2bf8ce7779e827e(props) {
12763
12807
  sorting_open: category_sorting_open_,
12764
12808
  expanded_filters: expanded_filters_,
12765
12809
  expanded_hierarchical_filters: expanded_hierarchical_filters_,
12766
- scroll_restoration_data: scroll_restoration_data_
12810
+ scroll_restoration_data: scroll_restoration_data_,
12811
+ history_content_blocks: history_content_blocks_
12767
12812
  } = depict_category.historyStateSignals_;
12768
12813
  const {
12769
12814
  current_sorting_: current_sorting_,
@@ -12809,6 +12854,7 @@ function $14f289047713d67a$export$e2bf8ce7779e827e(props) {
12809
12854
  sideways_filter_clearing_flag_: sideways_filter_clearing_flag_,
12810
12855
  content_blocks_by_row_: () => props.content_blocks_by_row,
12811
12856
  scroll_restoration_data_: scroll_restoration_data_,
12857
+ history_content_blocks_: history_content_blocks_,
12812
12858
  layout_options_: $5vyXB$solidjs.createMemo(() => ({
12813
12859
  cols_at_size: $4e04be41243c3d80$export$6daf8749b65a1b77(props.cols_at_size),
12814
12860
  ...grid_spacing_override(),