@depict-ai/ui 4.10.20 → 4.10.22

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.
@@ -115,7 +115,7 @@ $parcel$export(module.exports, "BreadCrumbs", () => $335c02c1241a9ca8$export$5b7
115
115
  $parcel$export(module.exports, "QuickLinks", () => $335c02c1241a9ca8$export$de035477d6fef996);
116
116
  $parcel$export(module.exports, "CategoryPage", () => $c10e33c4681f8c9b$export$e2bf8ce7779e827e);
117
117
  /*! Depict.ai search and product listing SDK */
118
- const $aa1938dec50d6c12$export$83d89fbfd8236492 = "4.10.20";
118
+ const $aa1938dec50d6c12$export$83d89fbfd8236492 = "4.10.22";
119
119
  function $3e17e871e9d0911d$export$d9f36cf74e24d595(media_query) {
120
120
  const signal = $3hooq$solidjs.createSignal(false);
121
121
  $3hooq$solidjs.onCleanup($3hooq$depictaiutilishared.javascript_media_query(media_query, _ref => {
@@ -1046,8 +1046,15 @@ function $0d3ee7000f047e67$export$a1fd619a4743ca08(_ref) {
1046
1046
  setFirstResultInViewport(Math.min(...intersecting) + 1); // +1 because we want to start counting at 1
1047
1047
  setLastResultsInViewport(Math.max(...intersecting) + 1);
1048
1048
  });
1049
- return renderedDisplays_;
1049
+ // Content blocks placed after the last product (but still in its row) have no product card to render in front of, so render them after the cards once there are no more products to load
1050
+ const trailingContentBlocks_ = $3hooq$solidjs.createMemo(() => {
1051
+ var _content_blocks_, _content_blocks_$trai;
1052
+ if (!all_products_loaded_[0]()) return [];
1053
+ return (content_blocks_ === null || content_blocks_ === void 0 ? void 0 : (_content_blocks_ = content_blocks_()) === null || _content_blocks_ === void 0 ? void 0 : (_content_blocks_$trai = _content_blocks_.trailing_) === null || _content_blocks_$trai === void 0 ? void 0 : _content_blocks_$trai.call(_content_blocks_, displays_by_key_().size)) || [];
1054
+ });
1055
+ return [renderedDisplays_, trailingContentBlocks_]; // Regarding the as unknown: https://github.com/solidjs/solid/releases/tag/v1.7.0
1050
1056
  }
1057
+
1051
1058
  var $6c2c739b113a8ddf$var$_tmpl$ = ["<div", ' class="', '">', "</div>"],
1052
1059
  $6c2c739b113a8ddf$var$_tmpl$2 = ["<style", ' type="text/css">', "</style>"];
1053
1060
  function $6c2c739b113a8ddf$export$d21e32dfedac04be(props) {
@@ -1365,10 +1372,18 @@ function $f8f375d6245ffff2$export$791ef57e62e21c3f(_ref) {
1365
1372
  set_top_row_shortened_by_(blocks_in_top_row_taken - 1); // minus one because the content block wrapper also is an element
1366
1373
  });
1367
1374
 
1368
- return $3hooq$solidjs.createMemo(() => $f8f375d6245ffff2$export$92aa5d691d588f3f({
1375
+ const remapped_ = $3hooq$solidjs.createMemo(() => $f8f375d6245ffff2$export$92aa5d691d588f3f({
1369
1376
  wrapped_blocks_: get_wrapped_blocks_(),
1370
1377
  n_cols_currently_showing_: n_cols_currently_showing_()
1371
- }).content_blocks_by_index_);
1378
+ }));
1379
+ const content_blocks_by_index_ = $3hooq$solidjs.createMemo(() => remapped_().content_blocks_by_index_);
1380
+ return Object.assign(content_blocks_by_index_, {
1381
+ trailing_: product_count => $f8f375d6245ffff2$export$b94605e5b3ce01c({
1382
+ ...remapped_(),
1383
+ n_cols_currently_showing_: n_cols_currently_showing_(),
1384
+ product_count: product_count
1385
+ })
1386
+ });
1372
1387
  }
1373
1388
  function $f8f375d6245ffff2$export$92aa5d691d588f3f(_ref2) {
1374
1389
  let {
@@ -1377,13 +1392,16 @@ function $f8f375d6245ffff2$export$92aa5d691d588f3f(_ref2) {
1377
1392
  } = _ref2;
1378
1393
  // This computation should be quite cheap since it just moves around things into an array
1379
1394
  const content_blocks_by_index_ = [];
1395
+ const rows_by_index_ = []; // the row of each block at each index of content_blocks_by_index_, in the same order
1380
1396
  const constructed_block_arrays = new WeakSet();
1381
1397
  // Need to keep track of products displaced by blocks above when mapping rows to indexes in the actual grid
1382
1398
  const displaced_products_ = []; // undefined = is product, true = is content block if number instead of tuple number indicates content blocks in that row. Index in first array is row, index in second array is column
1383
1399
  if (!n_cols_currently_showing_)
1384
1400
  // Nope out of here if we don't know how many columns are showing
1385
1401
  return {
1386
- content_blocks_by_index_: content_blocks_by_index_
1402
+ content_blocks_by_index_: content_blocks_by_index_,
1403
+ rows_by_index_: rows_by_index_,
1404
+ displaced_products_: displaced_products_
1387
1405
  };
1388
1406
  for (let i = 0; i < wrapped_blocks_.length; i++) {
1389
1407
  // i = row to show at
@@ -1431,6 +1449,7 @@ function $f8f375d6245ffff2$export$92aa5d691d588f3f(_ref2) {
1431
1449
  content_blocks_by_index_[final_target_index] = array;
1432
1450
  }
1433
1451
  } else content_blocks_by_index_[final_target_index] = block_content;
1452
+ (rows_by_index_[final_target_index] || (rows_by_index_[final_target_index] = [])).push(i);
1434
1453
  // Update displacement
1435
1454
  for (let j = 0; j < span_rows; j++) {
1436
1455
  var _ref3;
@@ -1440,9 +1459,46 @@ function $f8f375d6245ffff2$export$92aa5d691d588f3f(_ref2) {
1440
1459
  }
1441
1460
  return {
1442
1461
  content_blocks_by_index_: content_blocks_by_index_,
1462
+ rows_by_index_: rows_by_index_,
1443
1463
  displaced_products_: displaced_products_
1444
1464
  };
1445
1465
  }
1466
+ function $f8f375d6245ffff2$export$b94605e5b3ce01c(_ref4) {
1467
+ let {
1468
+ content_blocks_by_index_: content_blocks_by_index_,
1469
+ rows_by_index_: rows_by_index_,
1470
+ displaced_products_: displaced_products_,
1471
+ n_cols_currently_showing_: n_cols_currently_showing_,
1472
+ product_count: product_count
1473
+ } = _ref4;
1474
+ const trailing = [];
1475
+ if (!n_cols_currently_showing_ || product_count <= 0) return trailing;
1476
+ // Find the row the last product lands in: each row has room for the columns that blocks don't take up
1477
+ let last_product_row = 0;
1478
+ for (let seen_products = 0;; last_product_row++) {
1479
+ const row = displaced_products_[last_product_row];
1480
+ const taken_by_blocks = typeof row === "number" ? row : row ? row.filter(item => item).length : 0;
1481
+ seen_products += Math.max(0, n_cols_currently_showing_ - taken_by_blocks);
1482
+ if (seen_products >= product_count) break;
1483
+ // Rows past the ones blocks take up all have room for products, so we're done by then at the latest
1484
+ if (last_product_row >= displaced_products_.length + product_count) break;
1485
+ }
1486
+ for (let i = product_count; i < content_blocks_by_index_.length; i++) {
1487
+ var _rows$;
1488
+ const block = content_blocks_by_index_[i];
1489
+ if (block === undefined) continue;
1490
+ const rows = rows_by_index_[i] || [];
1491
+ if (Array.isArray(block) && rows.length > 1) {
1492
+ // Several blocks share this index (e.g. the end of one row and the start of the next): keep the ones in the last product's row
1493
+ const in_last_row = block.filter((_, j) => rows[j] <= last_product_row);
1494
+ if (in_last_row.length) trailing.push(in_last_row);
1495
+ continue;
1496
+ }
1497
+ if (((_rows$ = rows[0]) !== null && _rows$ !== void 0 ? _rows$ : Infinity) > last_product_row) continue; // a row below the last product's row: keep it hidden
1498
+ trailing.push(block);
1499
+ }
1500
+ return trailing;
1501
+ }
1446
1502
  /**
1447
1503
  * Takes a store that contains an array from where index is number of row and value is the result of executing the content block rendering function.
1448
1504
  * Then renders the content and wraps it into a div with the correct styling.
@@ -1475,6 +1531,7 @@ function $f8f375d6245ffff2$var$wrap_blocks_in_div(rendered_content_blocks, max_s
1475
1531
  content: () => {
1476
1532
  // 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
1477
1533
  // However, no need to count products to know if we should render: the <For> loops in Placeholders and render_displays will only call this function if there's actually a product here that wants to display this block
1534
+ // (or, once all products have loaded, ResultsProductCards renders the blocks placed after the last product)
1478
1535
  set_rendering_delayed_(false);
1479
1536
  return content;
1480
1537
  },
@@ -2218,6 +2275,63 @@ function $c5842bdb10e57229$export$fecbb157621501bd(_ref) {
2218
2275
  }));
2219
2276
  return outmost_element;
2220
2277
  }
2278
+
2279
+ /**
2280
+ * `HTMLElement.focus()` is a **silent no-op** on an element that is not being rendered
2281
+ * (`display: none`, `visibility: hidden`, a collapsed menu). Nothing throws, focus simply
2282
+ * stays where it was, so a caller that does not check believes it restored focus when it
2283
+ * left it on `<body>` — which puts the keyboard user back at the top of the document.
2284
+ *
2285
+ * That is reachable whenever the element which opened a modal stops being rendered while the
2286
+ * modal is open, and the common way for that to happen is the responsive-duplicate header:
2287
+ * a theme renders the same search trigger twice, once for desktop and once for mobile, and
2288
+ * hides one at the current breakpoint. Open the modal from the desktop trigger, cross the
2289
+ * breakpoint (rotate a tablet, resize a window), close the modal, and the remembered trigger
2290
+ * is still `isConnected` but no longer rendered. Verified against a live merchant storefront
2291
+ * on 4.10.19.
2292
+ *
2293
+ * So: verify that focus landed, and when it did not, look for a rendered twin of the same
2294
+ * control — the other half of the responsive pair — and use that instead.
2295
+ */ /**
2296
+ * An element can only take focus if it is actually being rendered.
2297
+ *
2298
+ * Injectable because it is the one part of this module that needs a layout engine: jsdom
2299
+ * reports no client rects for anything, so the specs pass their own predicate to exercise the
2300
+ * matching rules. The real predicate is only exercised in a browser.
2301
+ */
2302
+ const $1573c1a34371380a$export$e0652711c614c755 = element => !!element.getClientRects().length;
2303
+ /**
2304
+ * `document.activeElement` is the outermost shadow host when focus is inside a shadow tree,
2305
+ * so ask the element's own root rather than the document — matching how the rest of
2306
+ * modal_opener treats shadow-mounted modals.
2307
+ */
2308
+ const $1573c1a34371380a$var$has_focus = element => element.getRootNode().activeElement === element;
2309
+ /**
2310
+ * The accessible-name-ish identity we match twins on. Deliberately narrow: an explicit label
2311
+ * or the trimmed text. Two controls that share a tag and this string are the same control
2312
+ * rendered twice, which is exactly the responsive-duplicate case.
2313
+ */
2314
+ const $1573c1a34371380a$var$identity_of = element => (element.getAttribute("aria-label") || element.getAttribute("title") || element.textContent || "").trim().replace(/\s+/g, " ");
2315
+ function $1573c1a34371380a$export$5800d9d535a06e96(element) {
2316
+ let rendered = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : $1573c1a34371380a$export$e0652711c614c755;
2317
+ const identity = $1573c1a34371380a$var$identity_of(element);
2318
+ if (!identity) return; // nothing to match on — an icon-only button with no label
2319
+ const twins = [...element.ownerDocument.querySelectorAll(element.localName)].filter(candidate => candidate !== element && rendered(candidate) && $1573c1a34371380a$var$identity_of(candidate) === identity);
2320
+ return twins.length === 1 ? twins[0] : undefined;
2321
+ }
2322
+ function $1573c1a34371380a$export$51461d633c351649(element) {
2323
+ let rendered = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : $1573c1a34371380a$export$e0652711c614c755;
2324
+ element.focus({
2325
+ preventScroll: true
2326
+ });
2327
+ if ($1573c1a34371380a$var$has_focus(element)) return true;
2328
+ const twin = $1573c1a34371380a$export$5800d9d535a06e96(element, rendered);
2329
+ if (!twin) return false;
2330
+ twin.focus({
2331
+ preventScroll: true
2332
+ });
2333
+ return $1573c1a34371380a$var$has_focus(twin);
2334
+ }
2221
2335
  async function $4cf7d9829d60d844$export$79b1565500412d9b(search_modal, modal_fn_opts, parent) {
2222
2336
  const body = parent || document.body || (await (0, $3hooq$depictaiutilishared.observer).wait_for_element("body"));
2223
2337
  let dispose_and_remove;
@@ -2283,9 +2397,12 @@ async function $4cf7d9829d60d844$export$79b1565500412d9b(search_modal, modal_fn_
2283
2397
  });
2284
2398
  focused = requested_focus_target.getRootNode().activeElement === requested_focus_target;
2285
2399
  }
2286
- if (!focused && element_focused_before_open !== null && element_focused_before_open !== void 0 && element_focused_before_open.isConnected) element_focused_before_open.focus({
2287
- preventScroll: true
2288
- });
2400
+ if (!focused && element_focused_before_open !== null && element_focused_before_open !== void 0 && element_focused_before_open.isConnected)
2401
+ // restore_focus_to rather than a bare focus(): the remembered trigger can be
2402
+ // connected but no longer rendered (a responsive-duplicate header whose other
2403
+ // half is showing now), and focus() on an unrendered element silently does
2404
+ // nothing, leaving the keyboard user at the top of the page.
2405
+ $1573c1a34371380a$export$51461d633c351649(element_focused_before_open);
2289
2406
  } finally {
2290
2407
  // Cleared on a task instead of synchronously in case a browser delivers the focus event async
2291
2408
  setTimeout(() => restoring_focus = false, 0);
@@ -8044,20 +8161,28 @@ function $73014ff36186a4dd$var$_classPrivateMethodGet(receiver, privateSet, fn)
8044
8161
  }
8045
8162
  var $73014ff36186a4dd$var$_throwing_on_navigation = /*#__PURE__*/new WeakSet();
8046
8163
  var $73014ff36186a4dd$var$_get_navigation_happened_promise = /*#__PURE__*/new WeakSet();
8164
+ var $73014ff36186a4dd$var$_watch_for_navigation_to_same_href = /*#__PURE__*/new WeakSet();
8047
8165
  class $73014ff36186a4dd$export$7e1297a3a19f10d8 {
8048
8166
  /**
8049
8167
  * Function that will be called when we want to navigate, or a string saying it's not an SPA. You can change this OTG
8050
8168
  */ /**
8051
8169
  * 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
8052
8170
  */ /**
8053
- * Vue has async router that needs to be awaited (it navigates after a microtask)
8054
- * This standardises waiting for all kinds of routers
8055
- */
8171
+ * Called when a go_to_ didn't change location.href, for example when following a link to the page one is already on. href_change_ipns stays silent then, so whoever waits for a href change to react to a navigation has to listen here too
8172
+ */ /**
8173
+ * Vue has async router that needs to be awaited (it navigates after a microtask)
8174
+ * This standardises waiting for all kinds of routers
8175
+ */ /**
8176
+ * Calls navigation_to_same_href_listeners_ if the navigation we're about to request ends on the href we're already on
8177
+ * @returns function to stop watching, call it when the navigation failed
8178
+ */
8056
8179
  constructor(on_navigation, listing_query_state_key) {
8180
+ $73014ff36186a4dd$var$_classPrivateMethodInitSpec(this, $73014ff36186a4dd$var$_watch_for_navigation_to_same_href);
8057
8181
  $73014ff36186a4dd$var$_classPrivateMethodInitSpec(this, $73014ff36186a4dd$var$_get_navigation_happened_promise);
8058
8182
  $73014ff36186a4dd$var$_classPrivateMethodInitSpec(this, $73014ff36186a4dd$var$_throwing_on_navigation);
8059
8183
  $parcel$interopDefault($3hooq$babelruntimehelpersdefineProperty)(this, "on_navigation_", void 0);
8060
8184
  $parcel$interopDefault($3hooq$babelruntimehelpersdefineProperty)(this, "listing_query_state_key", void 0);
8185
+ $parcel$interopDefault($3hooq$babelruntimehelpersdefineProperty)(this, "navigation_to_same_href_listeners_", new Set());
8061
8186
  $parcel$interopDefault($3hooq$babelruntimehelpersdefineProperty)(this, "navigate_", {
8062
8187
  /**
8063
8188
  * Call this if you *just* want to replace the state object in history.state
@@ -8099,6 +8224,7 @@ class $73014ff36186a4dd$export$7e1297a3a19f10d8 {
8099
8224
  }
8100
8225
  event_ === null || event_ === void 0 || event_.preventDefault();
8101
8226
  const promise = $73014ff36186a4dd$var$_classPrivateMethodGet(this, $73014ff36186a4dd$var$_get_navigation_happened_promise, $73014ff36186a4dd$var$_get_navigation_happened_promise2).call(this, true);
8227
+ const stop_watching_for_same_href = $73014ff36186a4dd$var$_classPrivateMethodGet(this, $73014ff36186a4dd$var$_watch_for_navigation_to_same_href, $73014ff36186a4dd$var$_watch_for_navigation_to_same_href2).call(this, new_url_);
8102
8228
  if (force_spa_navigation_ && wants_hard_navigation) {
8103
8229
  // Don't allow hard navigation if we're forcing SPA navigation, which we do for things where PageReplacer can be used for performance
8104
8230
  const new_state = history.state;
@@ -8112,7 +8238,7 @@ class $73014ff36186a4dd$export$7e1297a3a19f10d8 {
8112
8238
  is_replace: is_replace_,
8113
8239
  new_url: new_url_ instanceof URL ? new_url_ : new URL(new_url_, location.href),
8114
8240
  scroll: scroll
8115
- });
8241
+ }, stop_watching_for_same_href);
8116
8242
  await promise;
8117
8243
  })
8118
8244
  });
@@ -8120,15 +8246,16 @@ class $73014ff36186a4dd$export$7e1297a3a19f10d8 {
8120
8246
  this.on_navigation_ = on_navigation;
8121
8247
  }
8122
8248
  }
8123
- function $73014ff36186a4dd$var$_throwing_on_navigation2() {
8249
+ function $73014ff36186a4dd$var$_throwing_on_navigation2(options, on_throw_) {
8124
8250
  const {
8125
8251
  on_navigation_: on_navigation_
8126
8252
  } = this;
8127
8253
  if (typeof on_navigation_ !== "function") throw new Error("on_navigation_ is not a function");
8128
8254
  // make sure that we don't accidentally catchify if the SDK consumer has fucked up
8129
8255
  try {
8130
- return on_navigation_(...arguments);
8256
+ return on_navigation_(options);
8131
8257
  } catch (e) {
8258
+ on_throw_ === null || on_throw_ === void 0 || on_throw_();
8132
8259
  queueMicrotask(() => {
8133
8260
  throw e;
8134
8261
  });
@@ -8145,6 +8272,24 @@ function $73014ff36186a4dd$var$_get_navigation_happened_promise2(is_replace) {
8145
8272
  (0, $3hooq$depictaiutilishared.instant_exec_on_suspect_history_change).add(handler);
8146
8273
  });
8147
8274
  }
8275
+ function $73014ff36186a4dd$var$_watch_for_navigation_to_same_href2(target_url) {
8276
+ const href_before = location.href;
8277
+ const stop_watching = () => {
8278
+ (0, $3hooq$depictaiutilishared.instant_exec_on_suspect_history_change).delete(on_history_change);
8279
+ clearTimeout(timeout);
8280
+ };
8281
+ const notify_if_href_unchanged = $3hooq$depictaiutilishared.catchify(() => {
8282
+ stop_watching();
8283
+ if (location.href !== href_before) return;
8284
+ this.navigation_to_same_href_listeners_.forEach(listener => $3hooq$depictaiutilishared.catchify(listener)());
8285
+ });
8286
+ // The router has acted once it touches history, if the href is still the same then it took us to the page we're on
8287
+ const on_history_change = () => notify_if_href_unchanged();
8288
+ // A router asked to go to the exact href we're on might not touch history at all, so don't wait longer than 500ms for it. For any other target we can't tell a slow navigation from one that goes nowhere, so only stop listening after a while
8289
+ const timeout = target_url.href === href_before ? setTimeout(notify_if_href_unchanged, 500) : setTimeout(stop_watching, 10000);
8290
+ (0, $3hooq$depictaiutilishared.instant_exec_on_suspect_history_change).add(on_history_change);
8291
+ return stop_watching;
8292
+ }
8148
8293
  var $2c920813c92d6987$var$_tmpl$ = ["<button", ' class="show-more major" type="button">', "</button>"],
8149
8294
  $2c920813c92d6987$var$_tmpl$2 = ["<h2", ' class="recs-title">', "</h2>"],
8150
8295
  $2c920813c92d6987$var$_tmpl$3 = ["<div", ' class="recommendation-grid"><!--$-->', "<!--/--><!--$-->", "<!--/--></div>"];
@@ -9517,11 +9662,17 @@ var $820f2920cc576f7e$var$_tmpl$ = ["<svg", ' xmlns="http://www.w3.org/2000/svg"
9517
9662
  function $820f2920cc576f7e$export$8d8893ffd8aca39a() {
9518
9663
  return $3hooq$solidjsweb.ssr($820f2920cc576f7e$var$_tmpl$, $3hooq$solidjsweb.ssrHydrationKey());
9519
9664
  }
9520
- function $4b71b4fabdee5753$export$93d9bfd0c9c1a5b8(close_modal, search_query_url_param_name_) {
9665
+ function $4b71b4fabdee5753$export$93d9bfd0c9c1a5b8(close_modal, search_query_url_param_name_, router_) {
9521
9666
  const [exit_iterable, exitable_iterable] = $3hooq$depictaiutilishared.make_asyncIterable_exiter((0, $3hooq$depictaiutilishared.href_change_ipns));
9667
+ const {
9668
+ navigation_to_same_href_listeners_: navigation_to_same_href_listeners_
9669
+ } = router_;
9522
9670
  let set_initial_values = false;
9523
9671
  let old_pathname;
9524
9672
  let old_param_value;
9673
+ // A card linking to the page one is already on doesn't change the href, close the modal anyway so the click does something
9674
+ navigation_to_same_href_listeners_.add(close_modal);
9675
+ $3hooq$solidjs.onCleanup(() => navigation_to_same_href_listeners_.delete(close_modal));
9525
9676
  $3hooq$solidjs.onCleanup($3hooq$depictaiutilishared.catchify(exit_iterable));
9526
9677
  $3hooq$depictaiutilishared.catchify(async () => {
9527
9678
  for await (const href of exitable_iterable) {
@@ -9671,7 +9822,7 @@ function $9035b24c2dbd3f36$var$RawClassicSearchModal(_ref) {
9671
9822
  }
9672
9823
  })));
9673
9824
  if (disable_scrolling_) $8c2e68c6d458169b$export$fe334901e8bebd57();
9674
- $4b71b4fabdee5753$export$93d9bfd0c9c1a5b8(close_modal_, search_query_url_param_name_);
9825
+ $4b71b4fabdee5753$export$93d9bfd0c9c1a5b8(close_modal_, search_query_url_param_name_, router_);
9675
9826
  window.addEventListener("keydown", close_on_escape_handler);
9676
9827
  $3hooq$solidjs.onCleanup($3hooq$depictaiutilishared.catchify(() => window.removeEventListener("keydown", close_on_escape_handler)));
9677
9828
  if (closing_animation_) register_closing_animation_(closing_animation_);
@@ -10404,7 +10555,7 @@ function $43600b30502feeda$var$RawSearchModalV2(_ref) {
10404
10555
  return (((_get_modal_search_res5 = get_modal_search_results_()) === null || _get_modal_search_res5 === void 0 ? void 0 : _get_modal_search_res5.loading) === false && !suggestions_response_.loading || !!prev) && totalNumberResults() === 0 && previous_searches_matching_query().length === 0;
10405
10556
  });
10406
10557
  if (disable_scrolling_) $8c2e68c6d458169b$export$fe334901e8bebd57();
10407
- $4b71b4fabdee5753$export$93d9bfd0c9c1a5b8(close_modal_, search_query_url_param_name_);
10558
+ $4b71b4fabdee5753$export$93d9bfd0c9c1a5b8(close_modal_, search_query_url_param_name_, router_);
10408
10559
  addEventListener("keydown", close_on_escape_handler);
10409
10560
  $3hooq$solidjs.onCleanup(() => removeEventListener("keydown", close_on_escape_handler));
10410
10561
  $3hooq$solidjs.createEffect($3hooq$solidjs.on(get_search_field_value_, () => {
@@ -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.10.20";
14
+ export const version = "4.10.22";
15
15
  /**
16
16
  * Use `javascript_media_query` but return a reactive accessor instead of taking a callback function
17
17
  */
@@ -425,10 +425,8 @@ export function remap_blocks_to_index<T = () => JSX.Element | Promise<JSX.Elemen
425
425
  })[];
426
426
  n_cols_currently_showing_: number | null;
427
427
  }): {
428
- content_blocks_by_index_: (Awaited<T> | T[])[];
429
- readonly displaced_products_?: undefined;
430
- } | {
431
428
  readonly content_blocks_by_index_: (Awaited<T> | T[])[];
429
+ readonly rows_by_index_: number[][];
432
430
  readonly displaced_products_: (number | (true | undefined)[])[];
433
431
  };
434
432
  /** @jsxImportSource solid-js */
@@ -485,6 +483,10 @@ export class PseudoRouter {
485
483
  * 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
486
484
  */
487
485
  listing_query_state_key: string | undefined;
486
+ /**
487
+ * Called when a go_to_ didn't change location.href, for example when following a link to the page one is already on. href_change_ipns stays silent then, so whoever waits for a href change to react to a navigation has to listen here too
488
+ */
489
+ navigation_to_same_href_listeners_: Set<VoidFunction>;
488
490
  navigate_: {
489
491
  /**
490
492
  * Call this if you *just* want to replace the state object in history.state