@depict-ai/ui 4.3.1 → 4.3.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.
@@ -1,13 +1,13 @@
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, 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
- 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";
1
+ import { add_to_version_info as $i7OB2$add_to_version_info, fetch_retry as $i7OB2$fetch_retry, base_url as $i7OB2$base_url, dwarn as $i7OB2$dwarn, 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, standard_price_format as $i7OB2$standard_price_format, instant_exec_on_suspect_history_change as $i7OB2$instant_exec_on_suspect_history_change, deparallelize_no_drop as $i7OB2$deparallelize_no_drop, ContainedImage as $i7OB2$ContainedImage, 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, 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, ssrStyle as $i7OB2$ssrStyle, escape as $i7OB2$escape, createComponent as $i7OB2$createComponent, mergeProps as $i7OB2$mergeProps1, 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
+ import { createSignal as $i7OB2$createSignal, createMemo as $i7OB2$createMemo, createResource as $i7OB2$createResource, createEffect as $i7OB2$createEffect, mergeProps as $i7OB2$mergeProps, 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, createContext as $i7OB2$createContext, useContext as $i7OB2$useContext, createUniqueId as $i7OB2$createUniqueId, createComputed as $i7OB2$createComputed, ErrorBoundary as $i7OB2$ErrorBoundary, splitProps as $i7OB2$splitProps, 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";
6
6
 
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.3.1";
10
+ const $ec291e0010116877$export$83d89fbfd8236492 = "4.3.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++) {
@@ -414,7 +414,7 @@ var $c8d5ff4524619fcd$var$_tmpl$ = ["<div", ' class="', '">', "</div>"],
414
414
  $c8d5ff4524619fcd$var$_tmpl$2 = ["<style", ' type="text/css">', "</style>"];
415
415
  function $c8d5ff4524619fcd$export$d21e32dfedac04be(props) {
416
416
  const container_class = "x" + $i7OB2$createUniqueId();
417
- const container_element_ = $i7OB2$ssrElement("div", $i7OB2$mergeProps(() => props.element_attributes, {
417
+ const container_element_ = $i7OB2$ssrElement("div", $i7OB2$mergeProps1(() => props.element_attributes, {
418
418
  classList: {
419
419
  [container_class]: true
420
420
  }
@@ -606,7 +606,7 @@ function $c4492d24952ed731$export$d41d19e89346fa2({
606
606
  } = slider;
607
607
  const Layout = props => $c8d5ff4524619fcd$export$445d8d3f5f706a40(props, insert_here, true);
608
608
  // Do like this, so we don't have to call mergeProps ourselves
609
- $i7OB2$createComponent(Layout, $i7OB2$mergeProps({
609
+ $i7OB2$createComponent(Layout, $i7OB2$mergeProps1({
610
610
  rows: "all",
611
611
  layout: "slider"
612
612
  }, layout_options_));
@@ -873,7 +873,7 @@ function $e8ffe11ed01df0fe$export$6e5611bc7e57e477(props) {
873
873
  });
874
874
  // Work around https://github.com/solidjs/solid/issues/1828
875
875
  const img = new Image(); // Need to use new Image or browser might not start loading image before it's in the DOM
876
- const [, otherAttributes] = $i7OB2$splitProps(props, ["resolutions", "size", "src", "srcSet", "loading", "customUrls" // Can't have properties ending on underscore because the property name mangling will get confused by this <-
876
+ const [, otherAttributes] = $i7OB2$splitProps(props, ["resolutions", "size", "src", "srcSet", "loading", "keyRatioUpdating", "customUrls" // Can't have properties ending on underscore because the property name mangling will get confused by this <-
877
877
  ]);
878
878
 
879
879
  const [hasSetSize, setHasSetSize] = $i7OB2$createSignal(false);
@@ -889,7 +889,7 @@ function $e8ffe11ed01df0fe$export$6e5611bc7e57e477(props) {
889
889
  if (loading === "force-lazy") return true;
890
890
  return loading === "lazy" && !isPrioritisedImage();
891
891
  });
892
- const modifiedOtherAttributes = $i7OB2$mergeProps1(otherAttributes, {
892
+ const modifiedOtherAttributes = $i7OB2$mergeProps(otherAttributes, {
893
893
  get loading() {
894
894
  return shouldActuallyEnableLazyLoading() ? "lazy" : undefined;
895
895
  }
@@ -929,13 +929,18 @@ function $e8ffe11ed01df0fe$export$6e5611bc7e57e477(props) {
929
929
  let hasDecodedFastPath = false;
930
930
  let timeoutSet = false;
931
931
  let gotCleanedUp = false;
932
+ let srcJustChanged = true;
932
933
  img.classList.add("s-responsive-image");
933
934
  if (listingContext) {
934
935
  let prevValue;
935
936
  const aspectRatios = listingContext[$e8ffe11ed01df0fe$export$f8945274f08a3105] ||= new Set();
936
937
  const [, setMostPrevalentAspectRatio] = listingContext[$e8ffe11ed01df0fe$export$6066eb417ed2e9f7] ||= $i7OB2$createSignal();
937
938
  img.addEventListener("load", $i7OB2$catchify(() => {
938
- // Save our aspect ratio whenever it changes, so that we can base the containers on the most dominant aspect ratio, used in SearchModalV2
939
+ if (props.keyRatioUpdating) {
940
+ if (!srcJustChanged) return;
941
+ srcJustChanged = false;
942
+ }
943
+ // Save our aspect ratio whenever it changes, so that we can base the containers on the most dominant aspect ratio, used in SearchModalV2 and LookItem
939
944
  const aspectRatio_ = img.naturalWidth / img.naturalHeight;
940
945
  if (prevValue) aspectRatios.delete(prevValue);
941
946
  const newValue = !isNaN(aspectRatio_) ? {
@@ -953,7 +958,11 @@ function $e8ffe11ed01df0fe$export$6e5611bc7e57e477(props) {
953
958
  $i7OB2$onCleanup(() => prevValue && aspectRatios.delete(prevValue));
954
959
  }
955
960
  $i7OB2$onCleanup(() => gotCleanedUp = true);
956
- $i7OB2$spread(img, $i7OB2$mergeProps1(modifiedOtherAttributes), false, true);
961
+ $i7OB2$spread(img, $i7OB2$mergeProps(modifiedOtherAttributes), false, true);
962
+ $i7OB2$createRenderEffect(() => {
963
+ props.src;
964
+ srcJustChanged = true;
965
+ });
957
966
  $i7OB2$createEffect(() => {
958
967
  if (!props.size()) return; // wait until we have a size, run every time the size changes
959
968
  if (timeoutSet) return;
@@ -1023,48 +1032,22 @@ function $660070e2a394b3c3$export$e4b984597b71e989(props) {
1023
1032
  const [mostPrevalentAspectRatio] = context ?
1024
1033
  // If the context exists we have to create the signal here as getting it here would be too late when it's created by ShopifyResponsiveImg below
1025
1034
  context[(0, $e8ffe11ed01df0fe$export$6066eb417ed2e9f7)] ||= $i7OB2$createSignal() : [];
1026
- const [aspectRatio, setAspectRatio] = $i7OB2$createSignal($i7OB2$untrack(() => props.aspectRatio));
1027
1035
  const container = $f18d425032111270$export$94026ee33dbabc26({
1028
1036
  // Write getters manually instead of using JSX, so we can do more complex logic in the aspectRatio getter without increasing bundle size
1029
1037
  get class() {
1030
1038
  return props.class;
1031
1039
  },
1032
1040
  get aspectRatio() {
1033
- return aspectRatio();
1041
+ if (props.autoAdjustAspectRatio) {
1042
+ const targetRatio = mostPrevalentAspectRatio?.();
1043
+ if (targetRatio != undefined) return `var(${(0, $bb15dfb548a7666e$export$8a2234b5b1a5ebd4)}, ${targetRatio})`;
1044
+ }
1045
+ return props.aspectRatio;
1034
1046
  }
1035
1047
  });
1036
1048
  const owner = $i7OB2$getOwner();
1037
1049
  let createdSizeAccessor = false;
1038
1050
  let wasCleanedUp = false;
1039
- let timeout;
1040
- $i7OB2$createEffect(() => {
1041
- const {
1042
- autoAdjustAspectRatio: autoAdjustAspectRatio
1043
- } = props;
1044
- if (autoAdjustAspectRatio) {
1045
- const targetRatio = mostPrevalentAspectRatio?.();
1046
- if (targetRatio != undefined) {
1047
- const targetValue = `var(${(0, $bb15dfb548a7666e$export$8a2234b5b1a5ebd4)}, ${targetRatio})`;
1048
- const updateAspectRatio = $i7OB2$catchify(() => setAspectRatio(targetValue));
1049
- if (autoAdjustAspectRatio === "smoothed") {
1050
- if (!timeout)
1051
- // If we don't have a timeout yet, also update instantly. This is so that the aspect ratio does get set at the start of a transition, if it changes (when using smoothing).
1052
- updateAspectRatio();
1053
- clearTimeout(timeout);
1054
- timeout = setTimeout(() => {
1055
- timeout = undefined;
1056
- updateAspectRatio();
1057
- }, 500);
1058
- return;
1059
- }
1060
- return updateAspectRatio();
1061
- }
1062
- } else {
1063
- clearTimeout(timeout);
1064
- timeout = undefined;
1065
- }
1066
- setAspectRatio(props.aspectRatio);
1067
- });
1068
1051
  $i7OB2$createEffect(() => {
1069
1052
  if (currentImageSize() || wasCleanedUp) return; // We get into the effect when onCleanup is called if we don't have wasCleanedUp
1070
1053
  // ensure we always have a size accessor
@@ -1078,7 +1061,7 @@ function $660070e2a394b3c3$export$e4b984597b71e989(props) {
1078
1061
  $i7OB2$queueMacroTask(() => setCurrentImageSize()); // unset the size accessor next event loop iteration, so that all onCleanup's have time to run, since the effects run more aggressively and can create a size accessor with a cleaned up owner otherwise
1079
1062
  });
1080
1063
 
1081
- $i7OB2$insert(container, $i7OB2$createComponent((0, $e8ffe11ed01df0fe$export$6e5611bc7e57e477), $i7OB2$mergeProps({
1064
+ $i7OB2$insert(container, $i7OB2$createComponent((0, $e8ffe11ed01df0fe$export$6e5611bc7e57e477), $i7OB2$mergeProps1({
1082
1065
  get size() {
1083
1066
  return $i7OB2$createMemo(() => currentImageSize()?.() || 0);
1084
1067
  },
@@ -1093,7 +1076,7 @@ function $660070e2a394b3c3$export$e4b984597b71e989(props) {
1093
1076
  return container;
1094
1077
  }
1095
1078
  function $70bb27cc6be01fc7$export$9d4a4b669b1929ab(props) {
1096
- return $i7OB2$createComponent((0, $660070e2a394b3c3$export$e4b984597b71e989), $i7OB2$mergeProps(props, {
1079
+ return $i7OB2$createComponent((0, $660070e2a394b3c3$export$e4b984597b71e989), $i7OB2$mergeProps1(props, {
1097
1080
  get imgProps() {
1098
1081
  return {
1099
1082
  ...props.imgProps,
@@ -1110,6 +1093,12 @@ function $70bb27cc6be01fc7$export$9d4a4b669b1929ab(props) {
1110
1093
  }
1111
1094
  }));
1112
1095
  }
1096
+ function $8c0f86cb3e266eeb$export$a71e92cfbb498adc(props) {
1097
+ return $i7OB2$createMemo(() => {
1098
+ const price_formatting = props.price_formatting_;
1099
+ return $i7OB2$standard_price_format(props.price_, price_formatting.places_after_comma_, price_formatting.decimal_places_delimiter_, price_formatting.thousands_delimiter_);
1100
+ });
1101
+ }
1113
1102
  var $5a6c386e1bde5665$var$_tmpl$ = ["<div", ' class="img-wrapper">', "</div>"],
1114
1103
  $5a6c386e1bde5665$var$_tmpl$2 = ["<span", ' class="d-price original">', "</span>"],
1115
1104
  $5a6c386e1bde5665$var$_tmpl$3 = ["<div", ' class="right-part"><div class="text-container"><span class="d-title line-clamp">', '</span><span class="', '">', "</span><!--$-->", "<!--/--></div><!--$-->", "<!--/--></div>"];
@@ -1119,7 +1108,9 @@ function $5a6c386e1bde5665$export$b73ed90f0ee50dc3({
1119
1108
  isExpanded_: isExpanded_,
1120
1109
  textFadeInAnimationRunning_: textFadeInAnimationRunning_,
1121
1110
  outerRef_: outerRef_,
1122
- animationDuration_: animationDuration_
1111
+ animationDuration_: animationDuration_,
1112
+ priceFormatting_: priceFormatting_,
1113
+ pseudoRouter_: pseudoRouter_
1123
1114
  }) {
1124
1115
  const variantToUse = $i7OB2$createMemo(() => {
1125
1116
  const display = display_();
@@ -1131,12 +1122,14 @@ function $5a6c386e1bde5665$export$b73ed90f0ee50dc3({
1131
1122
  const [animationEffectExists, setAnimationEffectExists] = $i7OB2$createSignal(false);
1132
1123
  const [salePrice] = $i7OB2$createResource(() => variantToUse()?.sale_price);
1133
1124
  const [originalPrice] = $i7OB2$createResource(() => variantToUse()?.original_price);
1134
- const isOnSale = $i7OB2$createMemo(() => salePrice.latest !== originalPrice.latest); // .latest doesn't trigger suspense
1125
+ const isOnSale = $i7OB2$createMemo(() => !salePrice.loading && !originalPrice.loading && salePrice.latest !== originalPrice.latest); // .latest doesn't trigger suspense after the initial load
1126
+ const enableLink = $i7OB2$createMemo(() => isExpanded_() && !animationIsRunning());
1127
+ const href = $i7OB2$createMemo(() => variantToUse()?.page_url);
1135
1128
  const FavoriteButton = FavoriteButton_; // Just to get rid of the type error - TS doesn't understand <Show>
1136
- return $i7OB2$ssrElement("a", $i7OB2$mergeProps({
1129
+ return $i7OB2$ssrElement("a", $i7OB2$mergeProps1({
1137
1130
  "class": "look-item"
1138
- }, () => isExpanded_() && !animationIsRunning() ? {
1139
- href: variantToUse()?.page_url
1131
+ }, () => enableLink() ? {
1132
+ href: href()
1140
1133
  } : {}), () => ["<!--$-->", $i7OB2$escape($i7OB2$createComponent((0, $i7OB2$Show), {
1141
1134
  when: imageUrl,
1142
1135
  get fallback() {
@@ -1163,7 +1156,10 @@ function $5a6c386e1bde5665$export$b73ed90f0ee50dc3({
1163
1156
  return isExpanded_() ? 0.75 : 1;
1164
1157
  },
1165
1158
  get autoAdjustAspectRatio() {
1166
- return isExpanded_() ? "smoothed" : false;
1159
+ return isExpanded_();
1160
+ },
1161
+ imgProps: {
1162
+ keyRatioUpdating: true
1167
1163
  }
1168
1164
  });
1169
1165
  }
@@ -1177,18 +1173,66 @@ function $5a6c386e1bde5665$export$b73ed90f0ee50dc3({
1177
1173
  return $i7OB2$ssr($5a6c386e1bde5665$var$_tmpl$3, $i7OB2$ssrHydrationKey(), $i7OB2$escape(variantToUse()?.title) ?? $i7OB2$escape($i7OB2$createComponent((0, $d134eae24341b4a1$export$89c6019e4baa40b1), {
1178
1174
  height: "1em",
1179
1175
  width: "20ch"
1180
- })), `d-price ${isOnSale() ? "sale" : ""}`, !variantToUse() || salePrice.loading ? $i7OB2$escape($i7OB2$createComponent((0, $d134eae24341b4a1$export$89c6019e4baa40b1), {
1181
- height: "1em",
1182
- width: "20ch"
1183
- })) : $i7OB2$escape(salePrice()), $i7OB2$escape($i7OB2$createComponent((0, $i7OB2$Show), {
1176
+ })), `d-price ${isOnSale() ? "sale" : ""}`, $i7OB2$escape($i7OB2$createComponent((0, $i7OB2$Show), {
1184
1177
  get when() {
1185
- return isOnSale();
1178
+ return variantToUse() && !salePrice.loading;
1186
1179
  },
1187
- get children() {
1188
- return $i7OB2$ssr($5a6c386e1bde5665$var$_tmpl$2, $i7OB2$ssrHydrationKey(), !variantToUse() || originalPrice.loading ? $i7OB2$escape($i7OB2$createComponent((0, $d134eae24341b4a1$export$89c6019e4baa40b1), {
1180
+ get fallback() {
1181
+ return $i7OB2$createComponent((0, $d134eae24341b4a1$export$89c6019e4baa40b1), {
1189
1182
  height: "1em",
1190
1183
  width: "20ch"
1191
- })) : $i7OB2$escape(originalPrice()));
1184
+ });
1185
+ },
1186
+ get children() {
1187
+ return $i7OB2$createComponent((0, $i7OB2$Show), {
1188
+ get when() {
1189
+ return salePrice.latest;
1190
+ },
1191
+ get children() {
1192
+ return [priceFormatting_().pre_, $i7OB2$createComponent((0, $8c0f86cb3e266eeb$export$a71e92cfbb498adc), {
1193
+ get price_() {
1194
+ return salePrice();
1195
+ },
1196
+ get price_formatting_() {
1197
+ return priceFormatting_();
1198
+ }
1199
+ }), priceFormatting_().post_];
1200
+ }
1201
+ });
1202
+ }
1203
+ })), $i7OB2$escape($i7OB2$createComponent((0, $i7OB2$Show), {
1204
+ get when() {
1205
+ return isOnSale();
1206
+ },
1207
+ get children() {
1208
+ return $i7OB2$ssr($5a6c386e1bde5665$var$_tmpl$2, $i7OB2$ssrHydrationKey(), $i7OB2$escape($i7OB2$createComponent((0, $i7OB2$Show), {
1209
+ get when() {
1210
+ return variantToUse() && !originalPrice.loading;
1211
+ },
1212
+ get fallback() {
1213
+ return $i7OB2$createComponent((0, $d134eae24341b4a1$export$89c6019e4baa40b1), {
1214
+ height: "1em",
1215
+ width: "20ch"
1216
+ });
1217
+ },
1218
+ get children() {
1219
+ return $i7OB2$createComponent((0, $i7OB2$Show), {
1220
+ get when() {
1221
+ return salePrice.latest;
1222
+ },
1223
+ get children() {
1224
+ return [priceFormatting_().pre_, $i7OB2$createComponent((0, $8c0f86cb3e266eeb$export$a71e92cfbb498adc), {
1225
+ get price_() {
1226
+ return originalPrice();
1227
+ },
1228
+ get price_formatting_() {
1229
+ return priceFormatting_();
1230
+ }
1231
+ }), priceFormatting_().post_];
1232
+ }
1233
+ });
1234
+ }
1235
+ })));
1192
1236
  }
1193
1237
  })), $i7OB2$escape($i7OB2$createComponent((0, $i7OB2$Show), {
1194
1238
  when: FavoriteButton_,
@@ -1258,7 +1302,9 @@ function $7555dcad3b8a4632$export$ebf0b1d4f90c09ae({
1258
1302
  userWantsExpandedSignal_: [userWantsExpanded, setUserWantsExpanded],
1259
1303
  containerWidth_: containerWidth_,
1260
1304
  animationDuration_: animationDuration_,
1261
- supportsHover_: supportsHover_
1305
+ supportsHover_: supportsHover_,
1306
+ priceFormatting_: priceFormatting_,
1307
+ pseudoRouter_: pseudoRouter_
1262
1308
  }) {
1263
1309
  let isAffectedByChromeBug = false;
1264
1310
  // If the user requests the drawer to be expanded or not
@@ -1275,7 +1321,7 @@ function $7555dcad3b8a4632$export$ebf0b1d4f90c09ae({
1275
1321
  return containerWidth_() || !displays_;
1276
1322
  },
1277
1323
  get children() {
1278
- return $i7OB2$ssr($7555dcad3b8a4632$var$_tmpl$, $i7OB2$ssrHydrationKey(), $i7OB2$ssrElement("div", $i7OB2$mergeProps({
1324
+ return $i7OB2$ssr($7555dcad3b8a4632$var$_tmpl$, $i7OB2$ssrHydrationKey(), $i7OB2$ssrElement("div", $i7OB2$mergeProps1({
1279
1325
  get ["class"]() {
1280
1326
  return `look-overlay ${userWantsExpanded() ? "expanded" : ""} ${!getSecondPartAnimationRunning() && userWantsExpanded() ? "resting-fully-expanded" : ""}`;
1281
1327
  }
@@ -1289,11 +1335,13 @@ function $7555dcad3b8a4632$export$ebf0b1d4f90c09ae({
1289
1335
  },
1290
1336
  children: (display, index) => {
1291
1337
  return $i7OB2$createComponent((0, $5a6c386e1bde5665$export$b73ed90f0ee50dc3), {
1338
+ pseudoRouter_: pseudoRouter_,
1292
1339
  animationDuration_: animationDuration_,
1293
1340
  display_: display,
1294
1341
  FavoriteButton_: FavoriteButton_,
1295
1342
  isExpanded_: userWantsExpanded,
1296
1343
  textFadeInAnimationRunning_: textFadeInAnimationRunning,
1344
+ priceFormatting_: priceFormatting_,
1297
1345
  outerRef_: el => $i7OB2$createEffect(() => {
1298
1346
  if (index !== 0) return;
1299
1347
  const resizeObserver = new ResizeObserver($i7OB2$catchify(records => setLookItemHeight(records.at(-1).contentRect.height)));
@@ -1334,10 +1382,10 @@ function $28ee4f7db3cc44b8$export$44809a8a3e867e30({
1334
1382
  expandedLooksSignal_: [expandedLooks_, setExpandedLooks],
1335
1383
  FavoriteButton_: FavoriteButton_,
1336
1384
  placeholderImageAspectRatio_: placeholderImageAspectRatio_,
1337
- animationDuration_: animationDuration_
1385
+ animationDuration_: animationDuration_,
1386
+ priceFormatting_: priceFormatting_,
1387
+ pseudoRouter_: pseudoRouter_
1338
1388
  }) {
1339
- // TODO: shopify, run displayTransformers to get dynamic prices
1340
- // TODO: format prices
1341
1389
  const [coverImage] = display_?.image_urls || [];
1342
1390
  const useWantsExpandedSignal_ = $i7OB2$createSignal(false);
1343
1391
  const [userWantsExpanded, setUserWantsExpanded] = useWantsExpandedSignal_;
@@ -1369,7 +1417,7 @@ function $28ee4f7db3cc44b8$export$44809a8a3e867e30({
1369
1417
  when: display_,
1370
1418
  get fallback() {
1371
1419
  return $i7OB2$createComponent((0, $7f60f09116a3fe61$export$3f37af283f8fb843), {
1372
- aspectRatio: placeholderImageAspectRatio_
1420
+ aspectRatio: `var(${(0, $bb15dfb548a7666e$export$8a2234b5b1a5ebd4)}, ${placeholderImageAspectRatio_})`
1373
1421
  });
1374
1422
  },
1375
1423
  get children() {
@@ -1387,10 +1435,124 @@ function $28ee4f7db3cc44b8$export$44809a8a3e867e30({
1387
1435
  containerWidth_: containerWidth_,
1388
1436
  animationDuration_: animationDuration_,
1389
1437
  supportsHover_: supportsHover_,
1390
- FavoriteButton_: FavoriteButton_
1438
+ FavoriteButton_: FavoriteButton_,
1439
+ priceFormatting_: priceFormatting_,
1440
+ pseudoRouter_: pseudoRouter_
1391
1441
  })]);
1392
1442
  return container;
1393
1443
  }
1444
+
1445
+ /**
1446
+ * This function is used to determine if the user is trying to open a link in a new tab or window, and we therefore should not single page navigate
1447
+ * @param clickEvent The click event that triggered the navigation
1448
+ */
1449
+ function $a281666e5c15c2ec$export$29d28dadc2d6b631(clickEvent) {
1450
+ return clickEvent?.button ||
1451
+ // if not zero it's a wheel click which opens in new tab
1452
+ clickEvent?.metaKey ||
1453
+ // if true, cmd button on macOS which opens in new tab
1454
+ clickEvent?.ctrlKey ||
1455
+ // if true, ctrl button on windows or linux which opens in new tab
1456
+ clickEvent?.shiftKey // if true, shift button on windows, linux or macOS which opens in a new window
1457
+ ;
1458
+ }
1459
+
1460
+ class $4fd2ba03703a7d92$export$7e1297a3a19f10d8 {
1461
+ /**
1462
+ * Function that will be called when we want to navigate, or a string saying it's not an SPA. You can change this OTG
1463
+ */ /**
1464
+ * We store listing_id in history.state and do operate on this both here and in js-ui, this is the key to be used which js-ui provides
1465
+ */
1466
+ #throwing_on_navigation(...args) {
1467
+ const {
1468
+ on_navigation_: on_navigation_
1469
+ } = this;
1470
+ if (typeof on_navigation_ !== "function") throw new Error("on_navigation_ is not a function");
1471
+ // make sure that we don't accidentally catchify if the SDK consumer has fucked up
1472
+ try {
1473
+ return on_navigation_(...args);
1474
+ } catch (e) {
1475
+ queueMicrotask(() => {
1476
+ throw e;
1477
+ });
1478
+ }
1479
+ }
1480
+ /**
1481
+ * Vue has async router that needs to be awaited (it navigates after a microtask)
1482
+ * This standardises waiting for all kinds of routers
1483
+ */
1484
+ #get_navigation_happened_promise(is_replace) {
1485
+ return new Promise(resolve => {
1486
+ const handler = what_happened => {
1487
+ if (what_happened === (is_replace ? "replaceState" : "pushState")) {
1488
+ resolve();
1489
+ (0, $i7OB2$instant_exec_on_suspect_history_change).delete(handler);
1490
+ }
1491
+ };
1492
+ (0, $i7OB2$instant_exec_on_suspect_history_change).add(handler);
1493
+ });
1494
+ }
1495
+ navigate_ = {
1496
+ /**
1497
+ * Call this if you *just* want to replace the state object in history.state
1498
+ */
1499
+ replace_state_: new_state => {
1500
+ // This doesn't break any router, so we just do this directly for now, since many don't expose an interface for changing the state
1501
+ globalThis?.history?.replaceState(new_state, "");
1502
+ },
1503
+ /**
1504
+ * Call this to change the URL
1505
+ * @param new_url_ new URL to go to
1506
+ * @param event_ event if you have this in a click handler, will not do anything on cmd/ctrl or non-left click then
1507
+ * @param force_spa_navigation_ if you want to force SPA navigation even if on_navigation_ is set to "hard_navigation". You should only set this to true for inter-SDK-page navigations
1508
+ * @param is_replace_ if you want to replace the current URL in history instead of pushing a new one
1509
+ * @param listing_id_ If you are navigating to a category and know the listing_id of, please provide it. This is for making a better devEx in js-ui
1510
+ */
1511
+ go_to_: $i7OB2$catchify(async ({
1512
+ new_url_: raw_new_url,
1513
+ event_: event_,
1514
+ force_spa_navigation_: force_spa_navigation_,
1515
+ is_replace_: is_replace_,
1516
+ listing_query_: listing_query_,
1517
+ scroll = true
1518
+ }) => {
1519
+ const new_url_ = raw_new_url instanceof URL ? raw_new_url : new URL(raw_new_url, location.origin);
1520
+ const wants_hard_navigation = this.on_navigation_ === "hard_navigation";
1521
+ if ($a281666e5c15c2ec$export$29d28dadc2d6b631(event_)) return;
1522
+ const different_origin = new_url_.origin !== location.origin;
1523
+ if (wants_hard_navigation && (!force_spa_navigation_ || different_origin)) {
1524
+ if (force_spa_navigation_ && different_origin)
1525
+ // If we call history.pushState on a different origin, it will throw an error, so fallback to hard navigations
1526
+ $i7OB2$dwarn("Can't single page navigate to", new_url_.href, "due to different origin, this MIGHT mean you should fix the URLs");
1527
+ if (!event_)
1528
+ // If we haven't gotten an event, nothing will happen by not calling prevent default, so we need to change the URL
1529
+ location.assign(new_url_);
1530
+ return;
1531
+ }
1532
+ event_?.preventDefault();
1533
+ const promise = this.#get_navigation_happened_promise(true);
1534
+ if (force_spa_navigation_ && wants_hard_navigation) {
1535
+ // Don't allow hard navigation if we're forcing SPA navigation, which we do for things where PageReplacer can be used for performance
1536
+ const new_state = history.state;
1537
+ if (listing_query_) {
1538
+ // In JS-UI we need to know the listing_id of the current category, therefore push it into state
1539
+ if (!this.listing_query_state_key) $i7OB2$report(new Error("listing_query_state_key is not set"), "error");
1540
+ new_state[this.listing_query_state_key] = listing_query_;
1541
+ }
1542
+ history[is_replace_ ? "replaceState" : "pushState"](new_state, "", new_url_);
1543
+ } else this.#throwing_on_navigation.call(this, {
1544
+ is_replace: is_replace_,
1545
+ new_url: new_url_ instanceof URL ? new_url_ : new URL(new_url_, location.origin),
1546
+ scroll: scroll
1547
+ });
1548
+ await promise;
1549
+ })
1550
+ };
1551
+ constructor(on_navigation, listing_query_state_key) {
1552
+ this.listing_query_state_key = listing_query_state_key;
1553
+ this.on_navigation_ = on_navigation;
1554
+ }
1555
+ }
1394
1556
  var $f577edfe2240eec1$var$_tmpl$ = ["<div", ' class="depict recommendations looks" style="', '">', "</div>"];
1395
1557
  let $f577edfe2240eec1$var$expandedLooksSignal_;
1396
1558
  function $f577edfe2240eec1$export$1935e6bdfc5ed8ce(props) {
@@ -1399,6 +1561,7 @@ function $f577edfe2240eec1$export$1935e6bdfc5ed8ce(props) {
1399
1561
  equals: false
1400
1562
  });
1401
1563
  const expandingAnimationDuration = 240;
1564
+ const pseudoRouter = new (0, $4fd2ba03703a7d92$export$7e1297a3a19f10d8)("hard_navigation");
1402
1565
  const grid_spacing_override = $i7OB2$createMemo(() => {
1403
1566
  const {
1404
1567
  gridSpacing_: gridSpacing_
@@ -1424,19 +1587,35 @@ function $f577edfe2240eec1$export$1935e6bdfc5ed8ce(props) {
1424
1587
  });
1425
1588
  const decoded = await response?.json?.().catch(() => false);
1426
1589
  if (!decoded)
1427
- // If network fails, make sure to return empty array adn SolidRecommendationSlider will remove its elements
1590
+ // If network fails, make sure to return empty array and SolidRecommendationSlider will remove its elements
1428
1591
  return [];
1429
- return decoded.listings;
1592
+ const {
1593
+ listings: listings
1594
+ } = decoded;
1595
+ const baseData = {
1596
+ merchant: merchant,
1597
+ market: market,
1598
+ locale: locale
1599
+ };
1600
+ return $f577edfe2240eec1$var$runDisplayTransformersForLooks(baseData, listings, props.displayTransformers_);
1601
+ });
1602
+ $i7OB2$createEffect(() => {
1603
+ const {
1604
+ onNavigation_: onNavigation_
1605
+ } = props;
1606
+ if (onNavigation_) pseudoRouter.on_navigation_ = onNavigation_;
1430
1607
  });
1431
1608
  return $i7OB2$ssr($f577edfe2240eec1$var$_tmpl$, $i7OB2$ssrHydrationKey(), $i7OB2$ssrStyle(`--animation-duration: ${expandingAnimationDuration}ms`), $i7OB2$escape($i7OB2$createComponent((0, $011607bdf658f807$export$e68cff63f76bd15b), {
1432
1609
  get children() {
1433
1610
  return $c4492d24952ed731$export$d41d19e89346fa2({
1434
- product_card_template_: (display, info) => $28ee4f7db3cc44b8$export$44809a8a3e867e30({
1611
+ product_card_template_: display => $28ee4f7db3cc44b8$export$44809a8a3e867e30({
1435
1612
  display_: display,
1436
1613
  FavoriteButton_: props.FavoriteButton_,
1437
1614
  placeholderImageAspectRatio_: props.imagePlaceholderAspectRatio_,
1438
1615
  animationDuration_: expandingAnimationDuration,
1439
- expandedLooksSignal_: $f577edfe2240eec1$var$expandedLooksSignal_
1616
+ expandedLooksSignal_: $f577edfe2240eec1$var$expandedLooksSignal_,
1617
+ priceFormatting_: () => props.priceFormatting_,
1618
+ pseudoRouter_: pseudoRouter
1440
1619
  }),
1441
1620
  recommendations_resource_: looksResource,
1442
1621
  title_: () => props.title_,
@@ -1449,6 +1628,53 @@ function $f577edfe2240eec1$export$1935e6bdfc5ed8ce(props) {
1449
1628
  })));
1450
1629
  }, "LookSlider failed");
1451
1630
  }
1631
+ async function $f577edfe2240eec1$var$runDisplayTransformersForLooks(baseData, listings, displayTransformers) {
1632
+ try {
1633
+ const {
1634
+ products: productTransformer,
1635
+ categories: providedListingTransformer
1636
+ } = displayTransformers || {};
1637
+ if (!productTransformer && !providedListingTransformer) return listings;
1638
+ const listingTransformer = providedListingTransformer || (({
1639
+ data: data
1640
+ }) => data);
1641
+ const displaysToTransform = [];
1642
+ const displayIdsPerListingId = {};
1643
+ const transformedListingsPromise = listingTransformer({
1644
+ ...baseData,
1645
+ data: listings.map(({
1646
+ displays: displays,
1647
+ ...listing
1648
+ }) => {
1649
+ // Populate our displays by id and displayIdToListings object in the .map where we add ancestors to the listings, for peak efficiency
1650
+ for (let i = 0; i < displays.length; i++) {
1651
+ const display = displays[i];
1652
+ const uniqueIdOfDisplay = $16351e4c87b90b3d$export$548d053aba053d79(display);
1653
+ displaysToTransform.push(display);
1654
+ (displayIdsPerListingId[listing.listing_id] ||= []).push(uniqueIdOfDisplay);
1655
+ }
1656
+ return {
1657
+ ...listing,
1658
+ ancestors: []
1659
+ };
1660
+ })
1661
+ });
1662
+ // This allows the person providing the displayTransformer to re-order and remove displays
1663
+ const transformedProducts = productTransformer ? await productTransformer({
1664
+ ...baseData,
1665
+ displays: displaysToTransform
1666
+ }) : displaysToTransform;
1667
+ const transformedListings = await transformedListingsPromise;
1668
+ const transformedDisplayById = Object.fromEntries(transformedProducts.map(display => [$16351e4c87b90b3d$export$548d053aba053d79(display), display]));
1669
+ return transformedListings.map(listing => $i7OB2$mergeProps(listing, {
1670
+ // use mergeProps because in preview browser we add getters in this object, that would be called too early otherwise
1671
+ displays: (displayIdsPerListingId[listing.listing_id] || []).map(displayId => transformedDisplayById[displayId]).filter(v => v)
1672
+ }));
1673
+ } catch (e) {
1674
+ $i7OB2$dwarn("Displaytransformers threw", e);
1675
+ return [];
1676
+ }
1677
+ }
1452
1678
  const $90980bd87c9960f9$export$3064e1e8c6513da3 = new Set();
1453
1679
  let $90980bd87c9960f9$var$has_ran = false;
1454
1680
  function $90980bd87c9960f9$export$5162a71f252e6122() {
@@ -1489,21 +1715,6 @@ function $90980bd87c9960f9$var$starts_with_any_prefix(key) {
1489
1715
  }
1490
1716
  }
1491
1717
 
1492
- /**
1493
- * This function is used to determine if the user is trying to open a link in a new tab or window, and we therefore should not single page navigate
1494
- * @param clickEvent The click event that triggered the navigation
1495
- */
1496
- function $a281666e5c15c2ec$export$29d28dadc2d6b631(clickEvent) {
1497
- return clickEvent?.button ||
1498
- // if not zero it's a wheel click which opens in new tab
1499
- clickEvent?.metaKey ||
1500
- // if true, cmd button on macOS which opens in new tab
1501
- clickEvent?.ctrlKey ||
1502
- // if true, ctrl button on windows or linux which opens in new tab
1503
- clickEvent?.shiftKey // if true, shift button on windows, linux or macOS which opens in a new window
1504
- ;
1505
- }
1506
-
1507
1718
  /**
1508
1719
  * Symbol used to identify the version of a SearchModal function. Values right now: 1 = 1st gen classic modal, 2 = second gen modal
1509
1720
  */
@@ -1543,12 +1754,6 @@ function $d8dbf52fea1773e2$export$f50b88e2a00918b5(fn) {
1543
1754
  }
1544
1755
  };
1545
1756
  }
1546
- function $8c0f86cb3e266eeb$export$a71e92cfbb498adc(props) {
1547
- return $i7OB2$createMemo(() => {
1548
- const price_formatting = props.price_formatting_;
1549
- return $i7OB2$standard_price_format(props.price_, price_formatting.places_after_comma_, price_formatting.decimal_places_delimiter_, price_formatting.thousands_delimiter_);
1550
- });
1551
- }
1552
1757
  function $f4125ce4984deee6$export$fb40a80c530e5f2b(selectedIndex, groupIndex, indexInGroup) {
1553
1758
  const isSelected = $i7OB2$createMemo(() => {
1554
1759
  const selectedValue = selectedIndex();
@@ -1855,7 +2060,7 @@ function $694b7f90501fea4c$export$5d2caaa6b530761c() {
1855
2060
  }
1856
2061
  var $19976a74d273070d$var$_tmpl$ = '<path d="M11.669 10.531l9.156-9.156a.78.78 0 0 0 .237-.569c0-.221-.079-.412-.237-.569A.8.8 0 0 0 20.24 0a.77.77 0 0 0-.569.237l-9.14 9.14-9.14-9.14A.79.79 0 0 0 .807 0a.77.77 0 0 0-.569.237A.78.78 0 0 0 0 .807a.77.77 0 0 0 .237.569l9.156 9.156-9.156 9.14c-.159.157-.237.349-.237.569s.079.412.237.569c.085.085.174.148.268.19a1.095 1.095 0 0 0 .316.048.894.894 0 0 0 .285-.048.84.84 0 0 0 .285-.19l9.139-9.14 9.14 9.14a.894.894 0 0 0 .268.19 1.049 1.049 0 0 0 .301.048.941.941 0 0 0 .301-.048.84.84 0 0 0 .285-.19.78.78 0 0 0 .237-.569c0-.221-.079-.412-.237-.569z"></path>';
1857
2062
  function $19976a74d273070d$export$3b621d86b1566b2(props = {}) {
1858
- return $i7OB2$ssrElement("svg", $i7OB2$mergeProps({
2063
+ return $i7OB2$ssrElement("svg", $i7OB2$mergeProps1({
1859
2064
  xmlns: "http://www.w3.org/2000/svg",
1860
2065
  width: "21.064",
1861
2066
  height: "21.064",
@@ -1955,7 +2160,7 @@ function $f3213c0640246d58$export$ba17c5b7e6dda39f({
1955
2160
  }
1956
2161
  var $16f0ed5ea30d8d9c$var$_tmpl$ = '<path d="M19.811 20.174l-6.234-6.809a7.96 7.96 0 0 0 .923-1.179c.274-.424.502-.865.687-1.323a8.04 8.04 0 0 0 .42-1.436 7.88 7.88 0 0 0 .144-1.507c0-.526-.051-1.042-.154-1.548-.096-.506-.243-.995-.441-1.466s-.441-.919-.728-1.343a8.28 8.28 0 0 0-.984-1.21 7.86 7.86 0 0 0-1.2-.984A7.56 7.56 0 0 0 10.89.651C10.418.453 9.929.302 9.423.2S8.401.046 7.875.046 6.833.097 6.327.2 5.332.453 4.86.651a7.56 7.56 0 0 0-1.354.718c-.431.287-.831.615-1.2.984a8.28 8.28 0 0 0-.984 1.21 7.73 7.73 0 0 0-.728 1.343c-.198.472-.349.96-.451 1.466A8.31 8.31 0 0 0 0 7.921a8.31 8.31 0 0 0 .144 1.548c.103.506.253.995.451 1.466a8.08 8.08 0 0 0 .728 1.354 7.86 7.86 0 0 0 .984 1.2 7.54 7.54 0 0 0 1.2.995c.431.287.882.53 1.354.728.472.191.96.338 1.466.441a8.31 8.31 0 0 0 1.548.144c.451 0 .896-.038 1.333-.113a7.83 7.83 0 0 0 1.282-.328 7.55 7.55 0 0 0 1.2-.533 8.08 8.08 0 0 0 1.107-.749l6.245 6.809a.45.45 0 0 0 .174.123.55.55 0 0 0 .205.041.61.61 0 0 0 .195-.031c.061-.021.116-.055.164-.102.109-.096.164-.219.164-.369.007-.144-.038-.267-.133-.369zM1.046 7.921c0-.937.178-1.818.533-2.646.362-.834.851-1.559 1.466-2.174.622-.615 1.347-1.101 2.174-1.456.827-.362 1.712-.543 2.656-.543s1.829.181 2.656.543c.827.355 1.548.841 2.164 1.456.622.615 1.111 1.34 1.466 2.174a6.52 6.52 0 0 1 .543 2.646c0 .943-.181 1.829-.543 2.656a6.89 6.89 0 0 1-1.466 2.174c-.615.615-1.336 1.104-2.164 1.466-.827.356-1.712.533-2.656.533s-1.829-.178-2.656-.533c-.827-.362-1.552-.851-2.174-1.466-.615-.622-1.104-1.347-1.466-2.174-.355-.827-.533-1.712-.533-2.656z"></path>';
1957
2162
  function $16f0ed5ea30d8d9c$export$82eafebb825fc23f(props = {}) {
1958
- return $i7OB2$ssrElement("svg", $i7OB2$mergeProps({
2163
+ return $i7OB2$ssrElement("svg", $i7OB2$mergeProps1({
1959
2164
  xmlns: "http://www.w3.org/2000/svg",
1960
2165
  width: "20",
1961
2166
  height: "22",
@@ -1964,7 +2169,7 @@ function $16f0ed5ea30d8d9c$export$82eafebb825fc23f(props = {}) {
1964
2169
  }
1965
2170
  var $190927650b4840eb$var$_tmpl$ = '<path d="M56 26.455a13.71 13.71 0 0 0-9.578 3.967A13.71 13.71 0 0 0 42.455 40v176a13.71 13.71 0 0 0 3.967 9.578A13.71 13.71 0 0 0 56 229.545h144A13.71 13.71 0 0 0 213.545 216V88a2.456 2.456 0 0 1 0-.002c.001-1.452-.597-2.895-1.623-3.922l-55.998-55.998a5.61 5.61 0 0 0-3.922-1.623 2.456 2.456 0 0 1-.002 0zm0 11.09h88A2.456 2.456 0 0 1 146.455 40v48c0 2.903 2.642 5.545 5.545 5.545h48A2.456 2.456 0 0 1 202.455 96v120a2.456 2.456 0 0 1-2.455 2.455H56A2.456 2.456 0 0 1 53.545 216V40A2.456 2.456 0 0 1 56 37.545zm103.061 11.498a2.456 2.456 0 0 1 2.676.531l28.689 28.689a2.456 2.456 0 0 1-1.736 4.191H160A2.456 2.456 0 0 1 157.545 80V51.311a2.456 2.456 0 0 1 1.516-2.268zM96 130.455c-2.903 0-5.545 2.642-5.545 5.545s2.642 5.545 5.545 5.545h64c2.903 0 5.545-2.642 5.545-5.545s-2.642-5.545-5.545-5.545zm0 32c-2.903 0-5.545 2.642-5.545 5.545s2.642 5.545 5.545 5.545h64c2.903 0 5.545-2.642 5.545-5.545s-2.642-5.545-5.545-5.545z"></path>';
1966
2171
  function $190927650b4840eb$export$605674723bcc715c(props = {}) {
1967
- return $i7OB2$ssrElement("svg", $i7OB2$mergeProps({
2172
+ return $i7OB2$ssrElement("svg", $i7OB2$mergeProps1({
1968
2173
  xmlns: "http://www.w3.org/2000/svg",
1969
2174
  width: "32",
1970
2175
  height: "32",
@@ -2519,7 +2724,7 @@ function $5285d2814d0fac0c$export$b94867ecbd698f21({
2519
2724
  get children() {
2520
2725
  return $i7OB2$ssr($5285d2814d0fac0c$var$_tmpl$, $i7OB2$ssrHydrationKey(), $i7OB2$ssrAttribute("aria-label", $i7OB2$escape(i18n_.back_(), true), false), $i7OB2$escape($i7OB2$createComponent(BackIcon_, {})));
2521
2726
  }
2522
- })), `query ${!!on_back_ ? "has-adjacent-back-button" : ""}`, $i7OB2$ssrAttribute("aria-label", $i7OB2$escape(i18n_.search_field_field_aria_label_(), true), false) + $i7OB2$ssrAttribute("value", $i7OB2$escape(search_field_value_[0](), true), false) + $i7OB2$ssrAttribute("placeholder", $i7OB2$escape(i18n_.placeholder_text_(), true), false), $i7OB2$ssrAttribute("title", $i7OB2$escape(i18n_.clear_filters_query_sorting_after_submit_(), true), false), $i7OB2$ssrStyle($i7OB2$createMemo(() => search_field_value_[0]() ? "" : "display: none")()), $i7OB2$escape($i7OB2$createComponent((0, $19976a74d273070d$export$3b621d86b1566b2), {})), $i7OB2$ssrElement("button", $i7OB2$mergeProps({
2727
+ })), `query ${!!on_back_ ? "has-adjacent-back-button" : ""}`, $i7OB2$ssrAttribute("aria-label", $i7OB2$escape(i18n_.search_field_field_aria_label_(), true), false) + $i7OB2$ssrAttribute("value", $i7OB2$escape(search_field_value_[0](), true), false) + $i7OB2$ssrAttribute("placeholder", $i7OB2$escape(i18n_.placeholder_text_(), true), false), $i7OB2$ssrAttribute("title", $i7OB2$escape(i18n_.clear_filters_query_sorting_after_submit_(), true), false), $i7OB2$ssrStyle($i7OB2$createMemo(() => search_field_value_[0]() ? "" : "display: none")()), $i7OB2$escape($i7OB2$createComponent((0, $19976a74d273070d$export$3b621d86b1566b2), {})), $i7OB2$ssrElement("button", $i7OB2$mergeProps1({
2523
2728
  "class": "submit major",
2524
2729
  type: "button"
2525
2730
  }, () => isNewModal ? {
@@ -3038,7 +3243,7 @@ function $4ce5b8892775b62d$export$67152d26d4f56ee8({
3038
3243
  selected_index_: [read_selected_index_, write_selected_index_]
3039
3244
  }) {
3040
3245
  const href = $i7OB2$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
3041
- const LinkToListing = props => $i7OB2$ssrElement("a", $i7OB2$mergeProps(props, {
3246
+ const LinkToListing = props => $i7OB2$ssrElement("a", $i7OB2$mergeProps1(props, {
3042
3247
  get href() {
3043
3248
  return href();
3044
3249
  }
@@ -3328,7 +3533,7 @@ function $2f3171b02c8f4a5d$export$af1fb307bbba2417({
3328
3533
  $i7OB2$createComputed($i7OB2$on(search_field_value_[0], () => !suggestions_updating_blocked() && set_selected_index(undefined), {
3329
3534
  defer: true
3330
3535
  })); // reset autocomplete position if query changes
3331
- return [$i7OB2$createComponent((0, $903297121898e5ff$export$d4994a86c6235f72), $i7OB2$mergeProps(sharedSuggestionProps, {
3536
+ return [$i7OB2$createComponent((0, $903297121898e5ff$export$d4994a86c6235f72), $i7OB2$mergeProps1(sharedSuggestionProps, {
3332
3537
  get title_() {
3333
3538
  return i18n_.popular_;
3334
3539
  },
@@ -3338,7 +3543,7 @@ function $2f3171b02c8f4a5d$export$af1fb307bbba2417({
3338
3543
  return itemIndexes_.suggestionsIndex_;
3339
3544
  },
3340
3545
  showPlaceholders_: () => showPlaceholders() || noResults_() && !noResultsPopularSuggestions.latest
3341
- })), $i7OB2$createComponent((0, $903297121898e5ff$export$d4994a86c6235f72), $i7OB2$mergeProps(sharedSuggestionProps, {
3546
+ })), $i7OB2$createComponent((0, $903297121898e5ff$export$d4994a86c6235f72), $i7OB2$mergeProps1(sharedSuggestionProps, {
3342
3547
  get title_() {
3343
3548
  return i18n_.previous_;
3344
3549
  },
@@ -3349,7 +3554,7 @@ function $2f3171b02c8f4a5d$export$af1fb307bbba2417({
3349
3554
  },
3350
3555
  extraTitleRowElements_: () => $i7OB2$ssr($2f3171b02c8f4a5d$var$_tmpl$, $i7OB2$ssrHydrationKey(), $i7OB2$escape(i18n_.clear_all_from_filter_crumbs_())),
3351
3556
  showPlaceholders_: () => false
3352
- })), $i7OB2$createComponent((0, $903297121898e5ff$export$d4994a86c6235f72), $i7OB2$mergeProps(sharedSuggestionProps, {
3557
+ })), $i7OB2$createComponent((0, $903297121898e5ff$export$d4994a86c6235f72), $i7OB2$mergeProps1(sharedSuggestionProps, {
3353
3558
  get title_() {
3354
3559
  return i18n_.content_;
3355
3560
  },
@@ -3750,7 +3955,7 @@ function $024fbc0a2d796fad$export$b2539bed5023c21c(props) {
3750
3955
  return $i7OB2$createComponent($024fbc0a2d796fad$var$TabsContext.Provider, {
3751
3956
  value: new (0, $i7OB2$ListenableSet)(),
3752
3957
  get children() {
3753
- return $i7OB2$createComponent($024fbc0a2d796fad$var$ActualTabs, $i7OB2$mergeProps(props, {
3958
+ return $i7OB2$createComponent($024fbc0a2d796fad$var$ActualTabs, $i7OB2$mergeProps1(props, {
3754
3959
  get children() {
3755
3960
  return props.children;
3756
3961
  }
@@ -3780,7 +3985,7 @@ function $024fbc0a2d796fad$var$ActualTabs(props) {
3780
3985
  },
3781
3986
  children: item => {
3782
3987
  const weSelected = $i7OB2$createMemo(() => isSelected(item().id));
3783
- return $i7OB2$createComponent((0, $i7OB2$Dynamic), $i7OB2$mergeProps({
3988
+ return $i7OB2$createComponent((0, $i7OB2$Dynamic), $i7OB2$mergeProps1({
3784
3989
  get component() {
3785
3990
  return props.AnchorComponent;
3786
3991
  },
@@ -3859,7 +4064,7 @@ function $024fbc0a2d796fad$export$3e41faf802a29e71(props) {
3859
4064
  if (!currentTabs) throw new Error("Tab must be a child of Tabs");
3860
4065
  const id = $i7OB2$createUniqueId();
3861
4066
  const ourSet = currentTabs;
3862
- const extendedProps = $i7OB2$mergeProps1({
4067
+ const extendedProps = $i7OB2$mergeProps({
3863
4068
  id: id
3864
4069
  }, props);
3865
4070
  ourSet.add(extendedProps);
@@ -3973,102 +4178,6 @@ function $ca6f574bd8772184$var$history_state_change(signals, entries, state) {
3973
4178
  }
3974
4179
  });
3975
4180
  }
3976
- class $4fd2ba03703a7d92$export$7e1297a3a19f10d8 {
3977
- /**
3978
- * Function that will be called when we want to navigate, or a string saying it's not an SPA. You can change this OTG
3979
- */ /**
3980
- * We store listing_id in history.state and do operate on this both here and in js-ui, this is the key to be used which js-ui provides
3981
- */
3982
- #throwing_on_navigation(...args) {
3983
- const {
3984
- on_navigation_: on_navigation_
3985
- } = this;
3986
- if (typeof on_navigation_ !== "function") throw new Error("on_navigation_ is not a function");
3987
- // make sure that we don't accidentally catchify if the SDK consumer has fucked up
3988
- try {
3989
- return on_navigation_(...args);
3990
- } catch (e) {
3991
- queueMicrotask(() => {
3992
- throw e;
3993
- });
3994
- }
3995
- }
3996
- /**
3997
- * Vue has async router that needs to be awaited (it navigates after a microtask)
3998
- * This standardises waiting for all kinds of routers
3999
- */
4000
- #get_navigation_happened_promise(is_replace) {
4001
- return new Promise(resolve => {
4002
- const handler = what_happened => {
4003
- if (what_happened === (is_replace ? "replaceState" : "pushState")) {
4004
- resolve();
4005
- (0, $i7OB2$instant_exec_on_suspect_history_change).delete(handler);
4006
- }
4007
- };
4008
- (0, $i7OB2$instant_exec_on_suspect_history_change).add(handler);
4009
- });
4010
- }
4011
- navigate_ = {
4012
- /**
4013
- * Call this if you *just* want to replace the state object in history.state
4014
- */
4015
- replace_state_: new_state => {
4016
- // This doesn't break any router, so we just do this directly for now, since many don't expose an interface for changing the state
4017
- globalThis?.history?.replaceState(new_state, "");
4018
- },
4019
- /**
4020
- * Call this to change the URL
4021
- * @param new_url_ new URL to go to
4022
- * @param event_ event if you have this in a click handler, will not do anything on cmd/ctrl or non-left click then
4023
- * @param force_spa_navigation_ if you want to force SPA navigation even if on_navigation_ is set to "hard_navigation". You should only set this to true for inter-SDK-page navigations
4024
- * @param is_replace_ if you want to replace the current URL in history instead of pushing a new one
4025
- * @param listing_id_ If you are navigating to a category and know the listing_id of, please provide it. This is for making a better devEx in js-ui
4026
- */
4027
- go_to_: $i7OB2$catchify(async ({
4028
- new_url_: raw_new_url,
4029
- event_: event_,
4030
- force_spa_navigation_: force_spa_navigation_,
4031
- is_replace_: is_replace_,
4032
- listing_query_: listing_query_,
4033
- scroll = true
4034
- }) => {
4035
- const new_url_ = raw_new_url instanceof URL ? raw_new_url : new URL(raw_new_url, location.origin);
4036
- const wants_hard_navigation = this.on_navigation_ === "hard_navigation";
4037
- if ($a281666e5c15c2ec$export$29d28dadc2d6b631(event_)) return;
4038
- const different_origin = new_url_.origin !== location.origin;
4039
- if (wants_hard_navigation && (!force_spa_navigation_ || different_origin)) {
4040
- if (force_spa_navigation_ && different_origin)
4041
- // If we call history.pushState on a different origin, it will throw an error, so fallback to hard navigations
4042
- $i7OB2$dwarn("Can't single page navigate to", new_url_.href, "due to different origin, this MIGHT mean you should fix the URLs");
4043
- if (!event_)
4044
- // If we haven't gotten an event, nothing will happen by not calling prevent default, so we need to change the URL
4045
- location.assign(new_url_);
4046
- return;
4047
- }
4048
- event_?.preventDefault();
4049
- const promise = this.#get_navigation_happened_promise(true);
4050
- if (force_spa_navigation_ && wants_hard_navigation) {
4051
- // Don't allow hard navigation if we're forcing SPA navigation, which we do for things where PageReplacer can be used for performance
4052
- const new_state = history.state;
4053
- if (listing_query_) {
4054
- // In JS-UI we need to know the listing_id of the current category, therefore push it into state
4055
- if (!this.listing_query_state_key) $i7OB2$report(new Error("listing_query_state_key is not set"), "error");
4056
- new_state[this.listing_query_state_key] = listing_query_;
4057
- }
4058
- history[is_replace_ ? "replaceState" : "pushState"](new_state, "", new_url_);
4059
- } else this.#throwing_on_navigation.call(this, {
4060
- is_replace: is_replace_,
4061
- new_url: new_url_ instanceof URL ? new_url_ : new URL(new_url_, location.origin),
4062
- scroll: scroll
4063
- });
4064
- await promise;
4065
- })
4066
- };
4067
- constructor(on_navigation, listing_query_state_key) {
4068
- this.listing_query_state_key = listing_query_state_key;
4069
- this.on_navigation_ = on_navigation;
4070
- }
4071
- }
4072
4181
  var $2a26c8ff1ef1fe75$var$_tmpl$ = ["<div", ' class="image-container">', "</div>"];
4073
4182
  function $2a26c8ff1ef1fe75$export$41e1a079d40a0d58(props) {
4074
4183
  const [display] = $i7OB2$createResource(() => ({
@@ -4162,7 +4271,7 @@ function $3da8afe3ed57cf34$export$7da560f849543dff({
4162
4271
  get children() {
4163
4272
  return $i7OB2$ssr($3da8afe3ed57cf34$var$_tmpl$, $i7OB2$ssrHydrationKey(), $i7OB2$escape(title()));
4164
4273
  }
4165
- }), $i7OB2$ssr($3da8afe3ed57cf34$var$_tmpl$2, $i7OB2$ssrHydrationKey(), $i7OB2$escape($a458486f22b22f63$export$a2cc176055f8f08()), $i7OB2$escape($i7OB2$createComponent((0, $c8d5ff4524619fcd$export$d21e32dfedac04be), $i7OB2$mergeProps({
4274
+ }), $i7OB2$ssr($3da8afe3ed57cf34$var$_tmpl$2, $i7OB2$ssrHydrationKey(), $i7OB2$escape($a458486f22b22f63$export$a2cc176055f8f08()), $i7OB2$escape($i7OB2$createComponent((0, $c8d5ff4524619fcd$export$d21e32dfedac04be), $i7OB2$mergeProps1({
4166
4275
  get rows() {
4167
4276
  return rows_object_();
4168
4277
  },
@@ -4446,7 +4555,7 @@ function $8560c919ff763930$var$ActualShopTheLookButton(props) {
4446
4555
  const button = $i7OB2$ssrElement("button", localProps.buttonAttributes, () => $i7OB2$escape(localProps?.buttonAttributes?.children) || "Shop the look", true);
4447
4556
  $i7OB2$createEffect(() => button.style.display = displayStyleValue()); // Set our attributes like this, so we allow total control over the button from the outside via buttonAttributes
4448
4557
  $i7OB2$createEffect(() => !hasAnythingToShow() && closeModal()); // close modal if we ever get into the state of having it open and not having anything to show
4449
- $8560c919ff763930$var$modalProps = $i7OB2$mergeProps1(partForModal, {
4558
+ $8560c919ff763930$var$modalProps = $i7OB2$mergeProps(partForModal, {
4450
4559
  products_to_shop_: products_to_shop_
4451
4560
  });
4452
4561
  button.addEventListener("click", openModal);
@@ -4862,7 +4971,7 @@ const $49b79728e7d9e2a1$export$48513f6b9f8ce62d = props => {
4862
4971
  };
4863
4972
  var $f8a56ba74eedd0c6$var$_tmpl$ = '<path d="M10.173 5.548H5.5V.875c0-.075-.027-.14-.081-.193S5.301.601 5.226.601s-.14.027-.193.081-.081.118-.081.193v4.673H.274c-.075 0-.14.027-.193.081A.27.27 0 0 0 0 5.827c0 .075.027.14.081.193s.118.081.193.081h4.678v4.673c0 .075.027.14.081.193s.118.081.193.081.14-.027.193-.081.081-.118.081-.193V6.101h4.673a.27.27 0 0 0 .199-.081c.054-.054.08-.118.08-.193a.27.27 0 0 0-.279-.279z" fill="#000"></path>';
4864
4973
  function $f8a56ba74eedd0c6$export$f21ab0717a89c77f(props) {
4865
- return $i7OB2$ssrElement("svg", $i7OB2$mergeProps(props, {
4974
+ return $i7OB2$ssrElement("svg", $i7OB2$mergeProps1(props, {
4866
4975
  xmlns: "http://www.w3.org/2000/svg",
4867
4976
  width: "11",
4868
4977
  height: "12"
@@ -6033,7 +6142,7 @@ const $93716a9ad0dea854$export$414f6a19d38e655c = ({
6033
6142
  const MakeButton = attributes => {
6034
6143
  const label = $i7OB2$createMemo(() => value().name_ || value().value_ + "");
6035
6144
  const count_zero = $i7OB2$createMemo(() => value().count_ === 0);
6036
- return $i7OB2$ssrElement("button", $i7OB2$mergeProps(attributes, {
6145
+ return $i7OB2$ssrElement("button", $i7OB2$mergeProps1(attributes, {
6037
6146
  get disabled() {
6038
6147
  return count_zero() && !is_selected();
6039
6148
  },
@@ -6333,7 +6442,7 @@ var $12497d09ef87296e$export$2e2bcd8739ae039 = {
6333
6442
  };
6334
6443
  var $9bc34983fc5f7bdb$var$_tmpl$ = '<path d="M4.617 12.738a.48.48 0 0 1-.164-.027c-.051-.023-.094-.055-.129-.098L.125 8.414A.39.39 0 0 1 0 8.117c0-.113.039-.211.125-.293s.18-.125.293-.125.215.043.297.125l3.902 3.902L16.086.262c.082-.082.18-.125.297-.125s.211.043.293.125.125.184.125.301-.043.215-.125.297L4.914 12.613c-.039.043-.086.078-.141.098s-.102.027-.156.027zm0 0"></path>';
6335
6444
  function $9bc34983fc5f7bdb$export$f2ca6fc699ca1fb4(props = {}) {
6336
- return $i7OB2$ssrElement("svg", $i7OB2$mergeProps({
6445
+ return $i7OB2$ssrElement("svg", $i7OB2$mergeProps1({
6337
6446
  xmlns: "http://www.w3.org/2000/svg",
6338
6447
  width: "16.8",
6339
6448
  height: "14"
@@ -7256,7 +7365,7 @@ class $7fa23e2a0079eca4$export$e015ed2f2950f2e3 {
7256
7365
  // Filter out our transformed ancestors
7257
7366
  const transformedAncestors = Object.fromEntries(transformerResult.filter(item => item.is_suggestion === false).map(item => [item.listing_id, item]));
7258
7367
  // Add the now transformed ancestors into the ancestors of the listing suggestions
7259
- const transformedSuggestions = transformerResult.filter(item => item.is_suggestion !== false).map(item => $i7OB2$mergeProps1(item, {
7368
+ const transformedSuggestions = transformerResult.filter(item => item.is_suggestion !== false).map(item => $i7OB2$mergeProps(item, {
7260
7369
  // Use mergeProps instead of spread since page_url and other properties could be a getter that solid components should call
7261
7370
  ancestors: item.ancestors.map(ancestor => {
7262
7371
  const newAncestor = transformedAncestors[ancestor.listing_id];
@@ -7787,7 +7896,7 @@ function $172e1b898d457050$export$7de92c4c2205ebf3({
7787
7896
  return (0, $7747fe1a8c5652e3$export$6c9030e511152266) + get_showing_recommendation_rows() * Math.max(...possible_num_columns);
7788
7897
  });
7789
7898
  // Don't tear down elements every time one updates the page - don't put them within <Show>
7790
- const elements = $i7OB2$ssr($172e1b898d457050$var$_tmpl$, $i7OB2$ssrHydrationKey(), $i7OB2$escape(i18n_.search_recs_title_()), $i7OB2$escape($a458486f22b22f63$export$a2cc176055f8f08()), $i7OB2$escape($i7OB2$createComponent((0, $c8d5ff4524619fcd$export$d21e32dfedac04be), $i7OB2$mergeProps({
7899
+ const elements = $i7OB2$ssr($172e1b898d457050$var$_tmpl$, $i7OB2$ssrHydrationKey(), $i7OB2$escape(i18n_.search_recs_title_()), $i7OB2$escape($a458486f22b22f63$export$a2cc176055f8f08()), $i7OB2$escape($i7OB2$createComponent((0, $c8d5ff4524619fcd$export$d21e32dfedac04be), $i7OB2$mergeProps1({
7791
7900
  rows: rows_object,
7792
7901
  layout: "grid",
7793
7902
  element_attributes: {
@@ -8607,7 +8716,7 @@ var $6dee9211e57ac31a$var$_tmpl$ = ["<style", ' type="text/css">', "</style>"];
8607
8716
  const $6dee9211e57ac31a$export$c500183c31c2b22e = "--spans-columns";
8608
8717
  function $6dee9211e57ac31a$export$ab6b147eec64fea5(props) {
8609
8718
  const container_class = "x" + $i7OB2$createUniqueId();
8610
- const container_element_ = $i7OB2$ssrElement("div", $i7OB2$mergeProps(() => props.element_attributes, {
8719
+ const container_element_ = $i7OB2$ssrElement("div", $i7OB2$mergeProps1(() => props.element_attributes, {
8611
8720
  classList: {
8612
8721
  [container_class]: true
8613
8722
  }
@@ -8857,7 +8966,7 @@ function $e7a7eb102ddc0c79$var$wrap_blocks_in_div(rendered_content_blocks, max_s
8857
8966
  })));
8858
8967
  }
8859
8968
  });
8860
- return $i7OB2$mergeProps1(block, {
8969
+ return $i7OB2$mergeProps(block, {
8861
8970
  // Create content divs for the blocks with as much fine-grained diffing as possible?
8862
8971
  content: () => {
8863
8972
  // Sneaky on-demand rendering, so we don't render more blocks than we can show: we have the rendered value here and don't return a function that renders because if our block would be moved around we'd be guaranteed to re-render
@@ -9092,7 +9201,7 @@ function $2d25e42846eac370$export$3925f87b1545cfc6({
9092
9201
  } = slider;
9093
9202
  const Layout = props => $c8d5ff4524619fcd$export$445d8d3f5f706a40(props, insert_here, true);
9094
9203
  // Do like this, so we don't have to call mergeProps ourselves
9095
- $i7OB2$createComponent(Layout, $i7OB2$mergeProps(layout_options_, {
9204
+ $i7OB2$createComponent(Layout, $i7OB2$mergeProps1(layout_options_, {
9096
9205
  rows: "all",
9097
9206
  get cols_at_size() {
9098
9207
  return modified_cols_at_size();
@@ -9238,7 +9347,7 @@ function $68a258a92b88f02f$export$1f1775a58da589b5({
9238
9347
  var $e1bb71e65e01a3a0$var$_tmpl$ = '<path d="M6.199 10.254a.35.35 0 0 0-.496 0L3.5 12.453V.348a.35.35 0 0 0-.7 0v12.105L.598 10.254c-.137-.137-.359-.137-.492 0a.35.35 0 0 0 0 .492l2.797 2.801a.35.35 0 0 0 .496 0L6.2 10.746c.137-.137.137-.355 0-.492zM9.449 3.5H8.051a.35.35 0 0 1-.352-.352V1.75c0-.191.156-.352.352-.352h1.398c.195 0 .352.16.352.352v1.398a.35.35 0 0 1-.352.352zm-1.051-.699h.703v-.699h-.703zm0 0"></path>',
9239
9348
  $e1bb71e65e01a3a0$var$_tmpl$2 = '<path d="M10.852 6.301H8.051a.35.35 0 0 1-.352-.352V4.551a.35.35 0 0 1 .352-.352h2.801a.35.35 0 0 1 .348.352v1.398a.35.35 0 0 1-.348.352zm-2.453-.699H10.5v-.703H8.398zm3.851 3.5H8.051c-.195 0-.352-.16-.352-.352V7.352A.35.35 0 0 1 8.051 7h4.199c.191 0 .352.156.352.352V8.75c0 .191-.16.352-.352.352zm-3.852-.703h3.5V7.7h-3.5zm5.25 3.499H8.051a.35.35 0 0 1-.352-.348v-1.402a.35.35 0 0 1 .352-.348h5.598a.35.35 0 0 1 .352.348v1.402a.35.35 0 0 1-.352.348zm-5.25-.699H13.3V10.5H8.398zm0 0"></path>';
9240
9349
  function $e1bb71e65e01a3a0$export$da32f7add8a22e86(props = {}) {
9241
- return $i7OB2$ssrElement("svg", $i7OB2$mergeProps({
9350
+ return $i7OB2$ssrElement("svg", $i7OB2$mergeProps1({
9242
9351
  xmlns: "http://www.w3.org/2000/svg",
9243
9352
  width: "14",
9244
9353
  height: "14",
@@ -9247,7 +9356,7 @@ function $e1bb71e65e01a3a0$export$da32f7add8a22e86(props = {}) {
9247
9356
  }
9248
9357
  var $05fbe84eb34564ec$var$_tmpl$ = '<path d="M6.199 10.254a.35.35 0 0 0-.496 0L3.5 12.453V.348a.35.35 0 0 0-.7 0v12.105L.598 10.254c-.137-.137-.359-.137-.492 0a.35.35 0 0 0 0 .492l2.797 2.801a.35.35 0 0 0 .496 0L6.2 10.746c.137-.137.137-.355 0-.492zm3.25 1.644H8.051a.35.35 0 0 1-.352-.348v-1.402a.35.35 0 0 1 .352-.348h1.398a.35.35 0 0 1 .352.348v1.402a.35.35 0 0 1-.352.348zm-1.051-.699h.703V10.5h-.703zm2.454-2.097H8.051c-.195 0-.352-.16-.352-.352V7.352A.35.35 0 0 1 8.051 7h2.801a.35.35 0 0 1 .348.352V8.75c0 .191-.156.352-.348.352zm-2.453-.703H10.5V7.7H8.398zm3.851-2.098H8.051a.35.35 0 0 1-.352-.352V4.551a.35.35 0 0 1 .352-.352h4.199c.191 0 .352.156.352.352v1.398c0 .195-.16.352-.352.352zm-3.852-.699h3.5v-.703h-3.5zm5.25-2.102H8.051a.35.35 0 0 1-.352-.352V1.75c0-.191.156-.352.352-.352h5.598c.195 0 .352.16.352.352v1.398a.35.35 0 0 1-.352.352zm-5.25-.699H13.3v-.699H8.398zm0 0"></path>';
9249
9358
  function $05fbe84eb34564ec$export$d10e63059ddb9fd4(props = {}) {
9250
- return $i7OB2$ssrElement("svg", $i7OB2$mergeProps({
9359
+ return $i7OB2$ssrElement("svg", $i7OB2$mergeProps1({
9251
9360
  xmlns: "http://www.w3.org/2000/svg",
9252
9361
  width: "14",
9253
9362
  height: "14",
@@ -9360,7 +9469,7 @@ function $757dac7f7c6c5241$export$9bf11afa910f536e({
9360
9469
  })));
9361
9470
  },
9362
9471
  get children() {
9363
- return $i7OB2$ssr($757dac7f7c6c5241$var$_tmpl$5, $i7OB2$ssrHydrationKey(), $i7OB2$escape($i7OB2$createComponent((0, $fab07f52c9861732$export$3f1a388cc0d8fed7), $i7OB2$mergeProps(args_for_filtering_, {
9472
+ return $i7OB2$ssr($757dac7f7c6c5241$var$_tmpl$5, $i7OB2$ssrHydrationKey(), $i7OB2$escape($i7OB2$createComponent((0, $fab07f52c9861732$export$3f1a388cc0d8fed7), $i7OB2$mergeProps1(args_for_filtering_, {
9364
9473
  are_in_modal_: true
9365
9474
  }))));
9366
9475
  }
@@ -9916,7 +10025,7 @@ function $b2bf2cdcff8142d8$export$f631859cab12b342({
9916
10025
  if (content_result_) return $i7OB2$ssrElement("a", attributes, () => $i7OB2$escape(children), true);
9917
10026
  return $i7OB2$ssrElement("div", attributes, () => $i7OB2$escape(children), true);
9918
10027
  };
9919
- return $i7OB2$ssr($b2bf2cdcff8142d8$var$_tmpl$2, $i7OB2$ssrHydrationKey(), $i7OB2$escape($i7OB2$createComponent(LinkIfPossible, $i7OB2$mergeProps(make_link_attributes, {
10028
+ return $i7OB2$ssr($b2bf2cdcff8142d8$var$_tmpl$2, $i7OB2$ssrHydrationKey(), $i7OB2$escape($i7OB2$createComponent(LinkIfPossible, $i7OB2$mergeProps1(make_link_attributes, {
9920
10029
  tabIndex: "-1",
9921
10030
  get children() {
9922
10031
  return $i7OB2$createComponent((0, $190927650b4840eb$export$605674723bcc715c), {
@@ -9924,7 +10033,7 @@ function $b2bf2cdcff8142d8$export$f631859cab12b342({
9924
10033
  height: "28"
9925
10034
  });
9926
10035
  }
9927
- }))), $i7OB2$escape($i7OB2$createComponent(LinkIfPossible, $i7OB2$mergeProps({
10036
+ }))), $i7OB2$escape($i7OB2$createComponent(LinkIfPossible, $i7OB2$mergeProps1({
9928
10037
  "class": "content-title line-clamp"
9929
10038
  }, make_link_attributes, {
9930
10039
  get title() {
@@ -10059,7 +10168,7 @@ function $49de9d31aeea1b5e$export$6d0c9c22f6652669({
10059
10168
  return (0, $f8c929beb82c512b$export$2452208c79fe93ea).content;
10060
10169
  },
10061
10170
  number_of_results_: num_results
10062
- })), $i7OB2$escape($i7OB2$createComponent((0, $c8d5ff4524619fcd$export$d21e32dfedac04be), $i7OB2$mergeProps({
10171
+ })), $i7OB2$escape($i7OB2$createComponent((0, $c8d5ff4524619fcd$export$d21e32dfedac04be), $i7OB2$mergeProps1({
10063
10172
  layout: "grid",
10064
10173
  element_attributes: {
10065
10174
  class: "cards"
@@ -10431,7 +10540,7 @@ function $7097477c78a89208$export$a54ec244c8863715({
10431
10540
  });
10432
10541
  const [sort_and_filter_element_, set_sort_and_filter_element_] = $i7OB2$createSignal();
10433
10542
  const no_results_text_ = $i7OB2$createMemo(() => (search_results_()?.content_search_links?.length ? i18n_.no_products_ : i18n_.no_results_text_)());
10434
- const results_for = $i7OB2$createComponent((0, $f8c929beb82c512b$export$9dd50d35b9d94fdf), $i7OB2$mergeProps({
10543
+ const results_for = $i7OB2$createComponent((0, $f8c929beb82c512b$export$9dd50d35b9d94fdf), $i7OB2$mergeProps1({
10435
10544
  get type() {
10436
10545
  return (0, $f8c929beb82c512b$export$2452208c79fe93ea).products;
10437
10546
  },
@@ -12160,7 +12269,7 @@ function $df5d81d0fe61ff21$var$add_us_to_crumbs(plp_meta) {
12160
12269
  return $i7OB2$createMemo(() => {
12161
12270
  const api_value = plp_meta()?.breadcrumbs;
12162
12271
  if (!api_value) return api_value;
12163
- return [...api_value, $i7OB2$mergeProps1(plp_meta(), {
12272
+ return [...api_value, $i7OB2$mergeProps(plp_meta(), {
12164
12273
  get page_url() {
12165
12274
  return href_accessor();
12166
12275
  }