@depict-ai/ui 4.10.24 → 4.10.26
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/ES10/index.cjs +70 -16
- package/ES10/index.d.ts +1 -1
- package/ES10/index.js +70 -16
- package/latest/index.cjs +62 -14
- package/latest/index.d.ts +1 -1
- package/latest/index.js +62 -14
- package/package.json +4 -4
- package/server/ES10/index.cjs +57 -9
- package/server/ES10/index.d.ts +1 -1
- package/server/ES10/index.js +57 -9
- package/server/latest/index.cjs +49 -7
- package/server/latest/index.d.ts +1 -1
- package/server/latest/index.js +49 -7
package/ES10/index.cjs
CHANGED
|
@@ -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.
|
|
118
|
+
const $aa1938dec50d6c12$export$83d89fbfd8236492 = "4.10.26";
|
|
119
119
|
function $3e17e871e9d0911d$export$d9f36cf74e24d595(media_query) {
|
|
120
120
|
const signal = $52FdA$solidjs.createSignal(false);
|
|
121
121
|
$52FdA$solidjs.onCleanup($52FdA$depictaiutilishared.javascript_media_query(media_query, _ref => {
|
|
@@ -1482,7 +1482,13 @@ function $830518481649feb1$export$e2f22da34aaf310a(props, container_element) {
|
|
|
1482
1482
|
const base_styling = $52FdA$solidjs.createMemo(() => {
|
|
1483
1483
|
return "".concat(container_selector, "{display:grid;}");
|
|
1484
1484
|
});
|
|
1485
|
-
const get_styling = $52FdA$solidjs.createMemo(() => base_styling() + col_styling())
|
|
1485
|
+
const get_styling = $52FdA$solidjs.createMemo(() => base_styling() + col_styling() + (props.content_block_row_styles || []).map(_ref => {
|
|
1486
|
+
let {
|
|
1487
|
+
row: row,
|
|
1488
|
+
template: template
|
|
1489
|
+
} = _ref;
|
|
1490
|
+
return "".concat(container_selector, ':has(>.content-block-wrapper.spans-multiple-rows[data-content-block-row="').concat(row, '"]){grid-template-rows:').concat(template, ";}");
|
|
1491
|
+
}).join(""));
|
|
1486
1492
|
const style_element = (() => {
|
|
1487
1493
|
var _el$2 = $52FdA$solidjsweb.getNextElement($830518481649feb1$var$_tmpl$2);
|
|
1488
1494
|
$52FdA$solidjsweb.insert(_el$2, get_styling);
|
|
@@ -1491,14 +1497,14 @@ function $830518481649feb1$export$e2f22da34aaf310a(props, container_element) {
|
|
|
1491
1497
|
if (insert_after_container) container_element.after(style_element);
|
|
1492
1498
|
return [container_element, style_element];
|
|
1493
1499
|
}
|
|
1494
|
-
function $830518481649feb1$var$generate_media_queried_declarations(
|
|
1500
|
+
function $830518481649feb1$var$generate_media_queried_declarations(_ref2) {
|
|
1495
1501
|
let {
|
|
1496
1502
|
container_selector_: container_selector_,
|
|
1497
1503
|
default_grid_spacing_text: default_grid_spacing_text,
|
|
1498
1504
|
cols_at_size_: cols_at_size_,
|
|
1499
1505
|
override_vertical_spacing_: override_vertical_spacing_,
|
|
1500
1506
|
top_row_shortened_by_: top_row_shortened_by_
|
|
1501
|
-
} =
|
|
1507
|
+
} = _ref2;
|
|
1502
1508
|
return cols_at_size_.map(options => {
|
|
1503
1509
|
const [n_cols, min, max, grid_spacing_for_size] = options;
|
|
1504
1510
|
const main_spacing_to_use = grid_spacing_for_size || default_grid_spacing_text;
|
|
@@ -1671,6 +1677,7 @@ function $f8f375d6245ffff2$export$791ef57e62e21c3f(_ref) {
|
|
|
1671
1677
|
}));
|
|
1672
1678
|
const content_blocks_by_index_ = $52FdA$solidjs.createMemo(() => remapped_().content_blocks_by_index_);
|
|
1673
1679
|
return Object.assign(content_blocks_by_index_, {
|
|
1680
|
+
row_styles_: $52FdA$solidjs.createMemo(() => $f8f375d6245ffff2$export$c4e1acd6a7f84fcf(get_wrapped_blocks_(), n_cols_currently_showing_())),
|
|
1674
1681
|
trailing_: product_count => $f8f375d6245ffff2$export$b94605e5b3ce01c({
|
|
1675
1682
|
...remapped_(),
|
|
1676
1683
|
n_cols_currently_showing_: n_cols_currently_showing_(),
|
|
@@ -1678,6 +1685,27 @@ function $f8f375d6245ffff2$export$791ef57e62e21c3f(_ref) {
|
|
|
1678
1685
|
})
|
|
1679
1686
|
});
|
|
1680
1687
|
}
|
|
1688
|
+
function $f8f375d6245ffff2$export$c4e1acd6a7f84fcf(blocks, n_cols) {
|
|
1689
|
+
const styles = [];
|
|
1690
|
+
if (!n_cols) return styles;
|
|
1691
|
+
let last_row = 0;
|
|
1692
|
+
blocks.forEach((block, row) => {
|
|
1693
|
+
if (!block || block.span_rows <= 1 || block.span_columns >= n_cols) return;
|
|
1694
|
+
last_row = Math.max(last_row, row + block.span_rows);
|
|
1695
|
+
// Give product rows equal heights. Full-width cards keep their own height.
|
|
1696
|
+
const tracks = Array.from({
|
|
1697
|
+
length: last_row
|
|
1698
|
+
}, (_, index) => {
|
|
1699
|
+
var _blocks$index;
|
|
1700
|
+
return ((_blocks$index = blocks[index]) === null || _blocks$index === void 0 ? void 0 : _blocks$index.span_columns) === n_cols ? "auto" : "1fr";
|
|
1701
|
+
});
|
|
1702
|
+
styles.push({
|
|
1703
|
+
row: row,
|
|
1704
|
+
template: tracks.join(" ")
|
|
1705
|
+
});
|
|
1706
|
+
});
|
|
1707
|
+
return styles;
|
|
1708
|
+
}
|
|
1681
1709
|
function $f8f375d6245ffff2$export$92aa5d691d588f3f(_ref2) {
|
|
1682
1710
|
let {
|
|
1683
1711
|
wrapped_blocks_: wrapped_blocks_,
|
|
@@ -1804,11 +1832,12 @@ function $f8f375d6245ffff2$export$911278b0390ae36e(block, max_span_columns) {
|
|
|
1804
1832
|
return {
|
|
1805
1833
|
span_columns: span_columns,
|
|
1806
1834
|
span_rows: spans_whole_row ? 1 : block.span_rows,
|
|
1807
|
-
spans_whole_row: spans_whole_row
|
|
1835
|
+
spans_whole_row: spans_whole_row,
|
|
1836
|
+
spans_multiple_rows: !spans_whole_row && block.span_rows > 1
|
|
1808
1837
|
};
|
|
1809
1838
|
}
|
|
1810
1839
|
function $f8f375d6245ffff2$var$wrap_blocks_in_div(rendered_content_blocks, max_span_columns) {
|
|
1811
|
-
const get_wrapped_blocks = $52FdA$solidjs.mapArray(() => rendered_content_blocks, block => {
|
|
1840
|
+
const get_wrapped_blocks = $52FdA$solidjs.mapArray(() => rendered_content_blocks, (block, row) => {
|
|
1812
1841
|
if (!block) return;
|
|
1813
1842
|
const final_spans = $52FdA$solidjs.createMemo(() => $f8f375d6245ffff2$export$911278b0390ae36e(block, max_span_columns()));
|
|
1814
1843
|
const final_span_columns = $52FdA$solidjs.createMemo(() => final_spans().span_columns);
|
|
@@ -1826,22 +1855,28 @@ function $f8f375d6245ffff2$var$wrap_blocks_in_div(rendered_content_blocks, max_s
|
|
|
1826
1855
|
}
|
|
1827
1856
|
}));
|
|
1828
1857
|
$52FdA$solidjsweb.effect(_p$ => {
|
|
1829
|
-
var _v$ =
|
|
1830
|
-
_v$2 =
|
|
1858
|
+
var _v$ = row(),
|
|
1859
|
+
_v$2 = !!final_spans().spans_whole_row,
|
|
1860
|
+
_v$3 = !!final_spans().spans_multiple_rows,
|
|
1861
|
+
_v$4 = {
|
|
1831
1862
|
[(0, $830518481649feb1$export$c500183c31c2b22e)]: final_span_columns()
|
|
1832
1863
|
},
|
|
1833
|
-
_v$
|
|
1834
|
-
_v$
|
|
1835
|
-
_v$ !== _p$.e &&
|
|
1836
|
-
_p$.t
|
|
1837
|
-
_v$3 !== _p$.a &&
|
|
1838
|
-
|
|
1864
|
+
_v$5 = "span ".concat(final_span_columns()),
|
|
1865
|
+
_v$6 = "span ".concat(final_span_rows());
|
|
1866
|
+
_v$ !== _p$.e && $52FdA$solidjsweb.setAttribute(_el$, "data-content-block-row", _p$.e = _v$);
|
|
1867
|
+
_v$2 !== _p$.t && _el$.classList.toggle("spans-whole-row", _p$.t = _v$2);
|
|
1868
|
+
_v$3 !== _p$.a && _el$.classList.toggle("spans-multiple-rows", _p$.a = _v$3);
|
|
1869
|
+
_p$.o = $52FdA$solidjsweb.style(_el$, _v$4, _p$.o);
|
|
1870
|
+
_v$5 !== _p$.i && ((_p$.i = _v$5) != null ? _el$.style.setProperty("grid-column", _v$5) : _el$.style.removeProperty("grid-column"));
|
|
1871
|
+
_v$6 !== _p$.n && ((_p$.n = _v$6) != null ? _el$.style.setProperty("grid-row", _v$6) : _el$.style.removeProperty("grid-row"));
|
|
1839
1872
|
return _p$;
|
|
1840
1873
|
}, {
|
|
1841
1874
|
e: undefined,
|
|
1842
1875
|
t: undefined,
|
|
1843
1876
|
a: undefined,
|
|
1844
|
-
o: undefined
|
|
1877
|
+
o: undefined,
|
|
1878
|
+
i: undefined,
|
|
1879
|
+
n: undefined
|
|
1845
1880
|
});
|
|
1846
1881
|
return _el$;
|
|
1847
1882
|
}
|
|
@@ -2107,6 +2142,10 @@ function $484eec37514a982e$export$3925f87b1545cfc6(_ref) {
|
|
|
2107
2142
|
cols_at_size_: modified_cols_at_size,
|
|
2108
2143
|
set_top_row_shortened_by_: set_top_row_shortened_by_
|
|
2109
2144
|
}));
|
|
2145
|
+
const content_block_row_styles = $52FdA$solidjs.createMemo(() => {
|
|
2146
|
+
const blocks = content_blocks_();
|
|
2147
|
+
return "row_styles_" in blocks ? blocks.row_styles_() : [];
|
|
2148
|
+
});
|
|
2110
2149
|
const rendered_placeholders = $52FdA$solidjs.createMemo(() => {
|
|
2111
2150
|
if (get_should_have_placeholders_rendered()) return $e3915574cfd3466c$export$f33414a4df0afd3f({
|
|
2112
2151
|
content_blocks_: content_blocks_,
|
|
@@ -2206,6 +2245,9 @@ function $484eec37514a982e$export$3925f87b1545cfc6(_ref) {
|
|
|
2206
2245
|
class: "cards css-grid"
|
|
2207
2246
|
},
|
|
2208
2247
|
top_row_shortened_by_: top_row_shortened_by_,
|
|
2248
|
+
get content_block_row_styles() {
|
|
2249
|
+
return content_block_row_styles();
|
|
2250
|
+
},
|
|
2209
2251
|
children: listing_contents
|
|
2210
2252
|
});
|
|
2211
2253
|
},
|
|
@@ -7966,7 +8008,7 @@ function $e4e98e5080f4386e$export$2972b890694ced75(callback, _ref) {
|
|
|
7966
8008
|
};
|
|
7967
8009
|
const idleHandle = requestIdleCallback(deadline => {
|
|
7968
8010
|
cancel();
|
|
7969
|
-
return callback(deadline);
|
|
8011
|
+
return callback(typeof (deadline === null || deadline === void 0 ? void 0 : deadline.timeRemaining) === "function" ? deadline : $e4e98e5080f4386e$var$makeDeadline());
|
|
7970
8012
|
}, {
|
|
7971
8013
|
timeout: timeout
|
|
7972
8014
|
});
|
|
@@ -7983,6 +8025,18 @@ function $e4e98e5080f4386e$export$2972b890694ced75(callback, _ref) {
|
|
|
7983
8025
|
}, timeout + 1000);
|
|
7984
8026
|
return cancel;
|
|
7985
8027
|
}
|
|
8028
|
+
/**
|
|
8029
|
+
* Stand-in for a missing IdleDeadline: 50ms, the most a real one gives, counting down from when the callback was called
|
|
8030
|
+
*/
|
|
8031
|
+
function $e4e98e5080f4386e$var$makeDeadline() {
|
|
8032
|
+
const start = performance.now();
|
|
8033
|
+
return {
|
|
8034
|
+
didTimeout: false,
|
|
8035
|
+
timeRemaining() {
|
|
8036
|
+
return Math.max(0, 50 - (performance.now() - start));
|
|
8037
|
+
}
|
|
8038
|
+
};
|
|
8039
|
+
}
|
|
7986
8040
|
function $4692443b324db9ee$export$566cd7e46bad5c2d(callback) {
|
|
7987
8041
|
var _globalThis$performan, _globalThis$performan2, _globalThis$performan3, _globalThis$performan4;
|
|
7988
8042
|
const page_hasnt_loaded =
|
package/ES10/index.d.ts
CHANGED
|
@@ -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.
|
|
14
|
+
export const version = "4.10.26";
|
|
15
15
|
/**
|
|
16
16
|
* Use `javascript_media_query` but return a reactive accessor instead of taking a callback function
|
|
17
17
|
*/
|
package/ES10/index.js
CHANGED
|
@@ -10,7 +10,7 @@ import $8tj43$babelruntimehelpersclassPrivateFieldGet from "@babel/runtime/helpe
|
|
|
10
10
|
/*! Depict.ai search and product listing SDK */
|
|
11
11
|
import { register_es_version } from "../multi_import_deduplicator.mjs";
|
|
12
12
|
register_es_version("ui", "ES10");
|
|
13
|
-
const $8db9a15135765c11$export$83d89fbfd8236492 = "4.10.
|
|
13
|
+
const $8db9a15135765c11$export$83d89fbfd8236492 = "4.10.26";
|
|
14
14
|
function $00a5b94f0c11efbb$export$d9f36cf74e24d595(media_query) {
|
|
15
15
|
const signal = $8tj43$createSignal(false);
|
|
16
16
|
$8tj43$onCleanup($8tj43$javascript_media_query(media_query, _ref => {
|
|
@@ -1377,7 +1377,13 @@ function $64d94dcaa058dc7b$export$e2f22da34aaf310a(props, container_element) {
|
|
|
1377
1377
|
const base_styling = $8tj43$createMemo(() => {
|
|
1378
1378
|
return "".concat(container_selector, "{display:grid;}");
|
|
1379
1379
|
});
|
|
1380
|
-
const get_styling = $8tj43$createMemo(() => base_styling() + col_styling())
|
|
1380
|
+
const get_styling = $8tj43$createMemo(() => base_styling() + col_styling() + (props.content_block_row_styles || []).map(_ref => {
|
|
1381
|
+
let {
|
|
1382
|
+
row: row,
|
|
1383
|
+
template: template
|
|
1384
|
+
} = _ref;
|
|
1385
|
+
return "".concat(container_selector, ':has(>.content-block-wrapper.spans-multiple-rows[data-content-block-row="').concat(row, '"]){grid-template-rows:').concat(template, ";}");
|
|
1386
|
+
}).join(""));
|
|
1381
1387
|
const style_element = (() => {
|
|
1382
1388
|
var _el$2 = $8tj43$getNextElement($64d94dcaa058dc7b$var$_tmpl$2);
|
|
1383
1389
|
$8tj43$insert(_el$2, get_styling);
|
|
@@ -1386,14 +1392,14 @@ function $64d94dcaa058dc7b$export$e2f22da34aaf310a(props, container_element) {
|
|
|
1386
1392
|
if (insert_after_container) container_element.after(style_element);
|
|
1387
1393
|
return [container_element, style_element];
|
|
1388
1394
|
}
|
|
1389
|
-
function $64d94dcaa058dc7b$var$generate_media_queried_declarations(
|
|
1395
|
+
function $64d94dcaa058dc7b$var$generate_media_queried_declarations(_ref2) {
|
|
1390
1396
|
let {
|
|
1391
1397
|
container_selector_: container_selector_,
|
|
1392
1398
|
default_grid_spacing_text: default_grid_spacing_text,
|
|
1393
1399
|
cols_at_size_: cols_at_size_,
|
|
1394
1400
|
override_vertical_spacing_: override_vertical_spacing_,
|
|
1395
1401
|
top_row_shortened_by_: top_row_shortened_by_
|
|
1396
|
-
} =
|
|
1402
|
+
} = _ref2;
|
|
1397
1403
|
return cols_at_size_.map(options => {
|
|
1398
1404
|
const [n_cols, min, max, grid_spacing_for_size] = options;
|
|
1399
1405
|
const main_spacing_to_use = grid_spacing_for_size || default_grid_spacing_text;
|
|
@@ -1566,6 +1572,7 @@ function $ff7feae4dddd6073$export$791ef57e62e21c3f(_ref) {
|
|
|
1566
1572
|
}));
|
|
1567
1573
|
const content_blocks_by_index_ = $8tj43$createMemo(() => remapped_().content_blocks_by_index_);
|
|
1568
1574
|
return Object.assign(content_blocks_by_index_, {
|
|
1575
|
+
row_styles_: $8tj43$createMemo(() => $ff7feae4dddd6073$export$c4e1acd6a7f84fcf(get_wrapped_blocks_(), n_cols_currently_showing_())),
|
|
1569
1576
|
trailing_: product_count => $ff7feae4dddd6073$export$b94605e5b3ce01c({
|
|
1570
1577
|
...remapped_(),
|
|
1571
1578
|
n_cols_currently_showing_: n_cols_currently_showing_(),
|
|
@@ -1573,6 +1580,27 @@ function $ff7feae4dddd6073$export$791ef57e62e21c3f(_ref) {
|
|
|
1573
1580
|
})
|
|
1574
1581
|
});
|
|
1575
1582
|
}
|
|
1583
|
+
function $ff7feae4dddd6073$export$c4e1acd6a7f84fcf(blocks, n_cols) {
|
|
1584
|
+
const styles = [];
|
|
1585
|
+
if (!n_cols) return styles;
|
|
1586
|
+
let last_row = 0;
|
|
1587
|
+
blocks.forEach((block, row) => {
|
|
1588
|
+
if (!block || block.span_rows <= 1 || block.span_columns >= n_cols) return;
|
|
1589
|
+
last_row = Math.max(last_row, row + block.span_rows);
|
|
1590
|
+
// Give product rows equal heights. Full-width cards keep their own height.
|
|
1591
|
+
const tracks = Array.from({
|
|
1592
|
+
length: last_row
|
|
1593
|
+
}, (_, index) => {
|
|
1594
|
+
var _blocks$index;
|
|
1595
|
+
return ((_blocks$index = blocks[index]) === null || _blocks$index === void 0 ? void 0 : _blocks$index.span_columns) === n_cols ? "auto" : "1fr";
|
|
1596
|
+
});
|
|
1597
|
+
styles.push({
|
|
1598
|
+
row: row,
|
|
1599
|
+
template: tracks.join(" ")
|
|
1600
|
+
});
|
|
1601
|
+
});
|
|
1602
|
+
return styles;
|
|
1603
|
+
}
|
|
1576
1604
|
function $ff7feae4dddd6073$export$92aa5d691d588f3f(_ref2) {
|
|
1577
1605
|
let {
|
|
1578
1606
|
wrapped_blocks_: wrapped_blocks_,
|
|
@@ -1699,11 +1727,12 @@ function $ff7feae4dddd6073$export$911278b0390ae36e(block, max_span_columns) {
|
|
|
1699
1727
|
return {
|
|
1700
1728
|
span_columns: span_columns,
|
|
1701
1729
|
span_rows: spans_whole_row ? 1 : block.span_rows,
|
|
1702
|
-
spans_whole_row: spans_whole_row
|
|
1730
|
+
spans_whole_row: spans_whole_row,
|
|
1731
|
+
spans_multiple_rows: !spans_whole_row && block.span_rows > 1
|
|
1703
1732
|
};
|
|
1704
1733
|
}
|
|
1705
1734
|
function $ff7feae4dddd6073$var$wrap_blocks_in_div(rendered_content_blocks, max_span_columns) {
|
|
1706
|
-
const get_wrapped_blocks = $8tj43$mapArray(() => rendered_content_blocks, block => {
|
|
1735
|
+
const get_wrapped_blocks = $8tj43$mapArray(() => rendered_content_blocks, (block, row) => {
|
|
1707
1736
|
if (!block) return;
|
|
1708
1737
|
const final_spans = $8tj43$createMemo(() => $ff7feae4dddd6073$export$911278b0390ae36e(block, max_span_columns()));
|
|
1709
1738
|
const final_span_columns = $8tj43$createMemo(() => final_spans().span_columns);
|
|
@@ -1721,22 +1750,28 @@ function $ff7feae4dddd6073$var$wrap_blocks_in_div(rendered_content_blocks, max_s
|
|
|
1721
1750
|
}
|
|
1722
1751
|
}));
|
|
1723
1752
|
$8tj43$effect(_p$ => {
|
|
1724
|
-
var _v$ =
|
|
1725
|
-
_v$2 =
|
|
1753
|
+
var _v$ = row(),
|
|
1754
|
+
_v$2 = !!final_spans().spans_whole_row,
|
|
1755
|
+
_v$3 = !!final_spans().spans_multiple_rows,
|
|
1756
|
+
_v$4 = {
|
|
1726
1757
|
[(0, $64d94dcaa058dc7b$export$c500183c31c2b22e)]: final_span_columns()
|
|
1727
1758
|
},
|
|
1728
|
-
_v$
|
|
1729
|
-
_v$
|
|
1730
|
-
_v$ !== _p$.e && _el
|
|
1731
|
-
_p$.t
|
|
1732
|
-
_v$3 !== _p$.a &&
|
|
1733
|
-
|
|
1759
|
+
_v$5 = "span ".concat(final_span_columns()),
|
|
1760
|
+
_v$6 = "span ".concat(final_span_rows());
|
|
1761
|
+
_v$ !== _p$.e && $8tj43$setAttribute(_el$, "data-content-block-row", _p$.e = _v$);
|
|
1762
|
+
_v$2 !== _p$.t && _el$.classList.toggle("spans-whole-row", _p$.t = _v$2);
|
|
1763
|
+
_v$3 !== _p$.a && _el$.classList.toggle("spans-multiple-rows", _p$.a = _v$3);
|
|
1764
|
+
_p$.o = $8tj43$style(_el$, _v$4, _p$.o);
|
|
1765
|
+
_v$5 !== _p$.i && ((_p$.i = _v$5) != null ? _el$.style.setProperty("grid-column", _v$5) : _el$.style.removeProperty("grid-column"));
|
|
1766
|
+
_v$6 !== _p$.n && ((_p$.n = _v$6) != null ? _el$.style.setProperty("grid-row", _v$6) : _el$.style.removeProperty("grid-row"));
|
|
1734
1767
|
return _p$;
|
|
1735
1768
|
}, {
|
|
1736
1769
|
e: undefined,
|
|
1737
1770
|
t: undefined,
|
|
1738
1771
|
a: undefined,
|
|
1739
|
-
o: undefined
|
|
1772
|
+
o: undefined,
|
|
1773
|
+
i: undefined,
|
|
1774
|
+
n: undefined
|
|
1740
1775
|
});
|
|
1741
1776
|
return _el$;
|
|
1742
1777
|
}
|
|
@@ -2002,6 +2037,10 @@ function $7faea0096f14b59b$export$3925f87b1545cfc6(_ref) {
|
|
|
2002
2037
|
cols_at_size_: modified_cols_at_size,
|
|
2003
2038
|
set_top_row_shortened_by_: set_top_row_shortened_by_
|
|
2004
2039
|
}));
|
|
2040
|
+
const content_block_row_styles = $8tj43$createMemo(() => {
|
|
2041
|
+
const blocks = content_blocks_();
|
|
2042
|
+
return "row_styles_" in blocks ? blocks.row_styles_() : [];
|
|
2043
|
+
});
|
|
2005
2044
|
const rendered_placeholders = $8tj43$createMemo(() => {
|
|
2006
2045
|
if (get_should_have_placeholders_rendered()) return $bdd80c7862246dc2$export$f33414a4df0afd3f({
|
|
2007
2046
|
content_blocks_: content_blocks_,
|
|
@@ -2101,6 +2140,9 @@ function $7faea0096f14b59b$export$3925f87b1545cfc6(_ref) {
|
|
|
2101
2140
|
class: "cards css-grid"
|
|
2102
2141
|
},
|
|
2103
2142
|
top_row_shortened_by_: top_row_shortened_by_,
|
|
2143
|
+
get content_block_row_styles() {
|
|
2144
|
+
return content_block_row_styles();
|
|
2145
|
+
},
|
|
2104
2146
|
children: listing_contents
|
|
2105
2147
|
});
|
|
2106
2148
|
},
|
|
@@ -7861,7 +7903,7 @@ function $6db93f70c2db1486$export$2972b890694ced75(callback, _ref) {
|
|
|
7861
7903
|
};
|
|
7862
7904
|
const idleHandle = requestIdleCallback(deadline => {
|
|
7863
7905
|
cancel();
|
|
7864
|
-
return callback(deadline);
|
|
7906
|
+
return callback(typeof (deadline === null || deadline === void 0 ? void 0 : deadline.timeRemaining) === "function" ? deadline : $6db93f70c2db1486$var$makeDeadline());
|
|
7865
7907
|
}, {
|
|
7866
7908
|
timeout: timeout
|
|
7867
7909
|
});
|
|
@@ -7878,6 +7920,18 @@ function $6db93f70c2db1486$export$2972b890694ced75(callback, _ref) {
|
|
|
7878
7920
|
}, timeout + 1000);
|
|
7879
7921
|
return cancel;
|
|
7880
7922
|
}
|
|
7923
|
+
/**
|
|
7924
|
+
* Stand-in for a missing IdleDeadline: 50ms, the most a real one gives, counting down from when the callback was called
|
|
7925
|
+
*/
|
|
7926
|
+
function $6db93f70c2db1486$var$makeDeadline() {
|
|
7927
|
+
const start = performance.now();
|
|
7928
|
+
return {
|
|
7929
|
+
didTimeout: false,
|
|
7930
|
+
timeRemaining() {
|
|
7931
|
+
return Math.max(0, 50 - (performance.now() - start));
|
|
7932
|
+
}
|
|
7933
|
+
};
|
|
7934
|
+
}
|
|
7881
7935
|
function $29b3cf99ce390e3b$export$566cd7e46bad5c2d(callback) {
|
|
7882
7936
|
var _globalThis$performan, _globalThis$performan2, _globalThis$performan3, _globalThis$performan4;
|
|
7883
7937
|
const page_hasnt_loaded =
|
package/latest/index.cjs
CHANGED
|
@@ -109,7 +109,7 @@ $parcel$export(module.exports, "BreadCrumbs", () => $1f4925833f07df29$export$5b7
|
|
|
109
109
|
$parcel$export(module.exports, "QuickLinks", () => $1f4925833f07df29$export$de035477d6fef996);
|
|
110
110
|
$parcel$export(module.exports, "CategoryPage", () => $14f289047713d67a$export$e2bf8ce7779e827e);
|
|
111
111
|
/*! Depict.ai search and product listing SDK */
|
|
112
|
-
const $b757f75811f3261f$export$83d89fbfd8236492 = "4.10.
|
|
112
|
+
const $b757f75811f3261f$export$83d89fbfd8236492 = "4.10.26";
|
|
113
113
|
function $b54e6192d0caa293$export$d9f36cf74e24d595(media_query) {
|
|
114
114
|
const signal = $gVhhF$solidjs.createSignal(false);
|
|
115
115
|
$gVhhF$solidjs.onCleanup($gVhhF$depictaiutilishared.javascript_media_query(media_query, ({
|
|
@@ -1416,7 +1416,10 @@ function $75777da1687ba3f6$export$e2f22da34aaf310a(props, container_element, ins
|
|
|
1416
1416
|
const base_styling = $gVhhF$solidjs.createMemo(() => {
|
|
1417
1417
|
return `${container_selector}{display:grid;}`;
|
|
1418
1418
|
});
|
|
1419
|
-
const get_styling = $gVhhF$solidjs.createMemo(() => base_styling() + col_styling())
|
|
1419
|
+
const get_styling = $gVhhF$solidjs.createMemo(() => base_styling() + col_styling() + (props.content_block_row_styles || []).map(({
|
|
1420
|
+
row: row,
|
|
1421
|
+
template: template
|
|
1422
|
+
}) => `${container_selector}:has(>.content-block-wrapper.spans-multiple-rows[data-content-block-row="${row}"]){grid-template-rows:${template};}`).join(""));
|
|
1420
1423
|
const style_element = (() => {
|
|
1421
1424
|
var _el$2 = $gVhhF$solidjsweb.getNextElement($75777da1687ba3f6$var$_tmpl$2);
|
|
1422
1425
|
$gVhhF$solidjsweb.insert(_el$2, get_styling);
|
|
@@ -1595,6 +1598,7 @@ function $d92f338ba8f9da9b$export$791ef57e62e21c3f({
|
|
|
1595
1598
|
}));
|
|
1596
1599
|
const content_blocks_by_index_ = $gVhhF$solidjs.createMemo(() => remapped_().content_blocks_by_index_);
|
|
1597
1600
|
return Object.assign(content_blocks_by_index_, {
|
|
1601
|
+
row_styles_: $gVhhF$solidjs.createMemo(() => $d92f338ba8f9da9b$export$c4e1acd6a7f84fcf(get_wrapped_blocks_(), n_cols_currently_showing_())),
|
|
1598
1602
|
trailing_: product_count => $d92f338ba8f9da9b$export$b94605e5b3ce01c({
|
|
1599
1603
|
...remapped_(),
|
|
1600
1604
|
n_cols_currently_showing_: n_cols_currently_showing_(),
|
|
@@ -1602,6 +1606,24 @@ function $d92f338ba8f9da9b$export$791ef57e62e21c3f({
|
|
|
1602
1606
|
})
|
|
1603
1607
|
});
|
|
1604
1608
|
}
|
|
1609
|
+
function $d92f338ba8f9da9b$export$c4e1acd6a7f84fcf(blocks, n_cols) {
|
|
1610
|
+
const styles = [];
|
|
1611
|
+
if (!n_cols) return styles;
|
|
1612
|
+
let last_row = 0;
|
|
1613
|
+
blocks.forEach((block, row) => {
|
|
1614
|
+
if (!block || block.span_rows <= 1 || block.span_columns >= n_cols) return;
|
|
1615
|
+
last_row = Math.max(last_row, row + block.span_rows);
|
|
1616
|
+
// Give product rows equal heights. Full-width cards keep their own height.
|
|
1617
|
+
const tracks = Array.from({
|
|
1618
|
+
length: last_row
|
|
1619
|
+
}, (_, index) => blocks[index]?.span_columns === n_cols ? "auto" : "1fr");
|
|
1620
|
+
styles.push({
|
|
1621
|
+
row: row,
|
|
1622
|
+
template: tracks.join(" ")
|
|
1623
|
+
});
|
|
1624
|
+
});
|
|
1625
|
+
return styles;
|
|
1626
|
+
}
|
|
1605
1627
|
function $d92f338ba8f9da9b$export$92aa5d691d588f3f({
|
|
1606
1628
|
wrapped_blocks_: wrapped_blocks_,
|
|
1607
1629
|
n_cols_currently_showing_: n_cols_currently_showing_
|
|
@@ -1721,11 +1743,12 @@ function $d92f338ba8f9da9b$export$911278b0390ae36e(block, max_span_columns) {
|
|
|
1721
1743
|
return {
|
|
1722
1744
|
span_columns: span_columns,
|
|
1723
1745
|
span_rows: spans_whole_row ? 1 : block.span_rows,
|
|
1724
|
-
spans_whole_row: spans_whole_row
|
|
1746
|
+
spans_whole_row: spans_whole_row,
|
|
1747
|
+
spans_multiple_rows: !spans_whole_row && block.span_rows > 1
|
|
1725
1748
|
};
|
|
1726
1749
|
}
|
|
1727
1750
|
function $d92f338ba8f9da9b$var$wrap_blocks_in_div(rendered_content_blocks, max_span_columns) {
|
|
1728
|
-
const get_wrapped_blocks = $gVhhF$solidjs.mapArray(() => rendered_content_blocks, block => {
|
|
1751
|
+
const get_wrapped_blocks = $gVhhF$solidjs.mapArray(() => rendered_content_blocks, (block, row) => {
|
|
1729
1752
|
if (!block) return;
|
|
1730
1753
|
const final_spans = $gVhhF$solidjs.createMemo(() => $d92f338ba8f9da9b$export$911278b0390ae36e(block, max_span_columns()));
|
|
1731
1754
|
const final_span_columns = $gVhhF$solidjs.createMemo(() => final_spans().span_columns);
|
|
@@ -1743,22 +1766,28 @@ function $d92f338ba8f9da9b$var$wrap_blocks_in_div(rendered_content_blocks, max_s
|
|
|
1743
1766
|
}
|
|
1744
1767
|
}));
|
|
1745
1768
|
$gVhhF$solidjsweb.effect(_p$ => {
|
|
1746
|
-
var _v$ =
|
|
1747
|
-
_v$2 =
|
|
1769
|
+
var _v$ = row(),
|
|
1770
|
+
_v$2 = !!final_spans().spans_whole_row,
|
|
1771
|
+
_v$3 = !!final_spans().spans_multiple_rows,
|
|
1772
|
+
_v$4 = {
|
|
1748
1773
|
[(0, $75777da1687ba3f6$export$c500183c31c2b22e)]: final_span_columns()
|
|
1749
1774
|
},
|
|
1750
|
-
_v$
|
|
1751
|
-
_v$
|
|
1752
|
-
_v$ !== _p$.e &&
|
|
1753
|
-
_p$.t
|
|
1754
|
-
_v$3 !== _p$.a &&
|
|
1755
|
-
|
|
1775
|
+
_v$5 = `span ${final_span_columns()}`,
|
|
1776
|
+
_v$6 = `span ${final_span_rows()}`;
|
|
1777
|
+
_v$ !== _p$.e && $gVhhF$solidjsweb.setAttribute(_el$, "data-content-block-row", _p$.e = _v$);
|
|
1778
|
+
_v$2 !== _p$.t && _el$.classList.toggle("spans-whole-row", _p$.t = _v$2);
|
|
1779
|
+
_v$3 !== _p$.a && _el$.classList.toggle("spans-multiple-rows", _p$.a = _v$3);
|
|
1780
|
+
_p$.o = $gVhhF$solidjsweb.style(_el$, _v$4, _p$.o);
|
|
1781
|
+
_v$5 !== _p$.i && ((_p$.i = _v$5) != null ? _el$.style.setProperty("grid-column", _v$5) : _el$.style.removeProperty("grid-column"));
|
|
1782
|
+
_v$6 !== _p$.n && ((_p$.n = _v$6) != null ? _el$.style.setProperty("grid-row", _v$6) : _el$.style.removeProperty("grid-row"));
|
|
1756
1783
|
return _p$;
|
|
1757
1784
|
}, {
|
|
1758
1785
|
e: undefined,
|
|
1759
1786
|
t: undefined,
|
|
1760
1787
|
a: undefined,
|
|
1761
|
-
o: undefined
|
|
1788
|
+
o: undefined,
|
|
1789
|
+
i: undefined,
|
|
1790
|
+
n: undefined
|
|
1762
1791
|
});
|
|
1763
1792
|
return _el$;
|
|
1764
1793
|
}
|
|
@@ -2015,6 +2044,10 @@ function $fe76fb463cc60b89$export$3925f87b1545cfc6({
|
|
|
2015
2044
|
cols_at_size_: modified_cols_at_size,
|
|
2016
2045
|
set_top_row_shortened_by_: set_top_row_shortened_by_
|
|
2017
2046
|
}));
|
|
2047
|
+
const content_block_row_styles = $gVhhF$solidjs.createMemo(() => {
|
|
2048
|
+
const blocks = content_blocks_();
|
|
2049
|
+
return "row_styles_" in blocks ? blocks.row_styles_() : [];
|
|
2050
|
+
});
|
|
2018
2051
|
const rendered_placeholders = $gVhhF$solidjs.createMemo(() => {
|
|
2019
2052
|
if (get_should_have_placeholders_rendered()) return $0caf87eaa19079da$export$f33414a4df0afd3f({
|
|
2020
2053
|
content_blocks_: content_blocks_,
|
|
@@ -2114,6 +2147,9 @@ function $fe76fb463cc60b89$export$3925f87b1545cfc6({
|
|
|
2114
2147
|
class: "cards css-grid"
|
|
2115
2148
|
},
|
|
2116
2149
|
top_row_shortened_by_: top_row_shortened_by_,
|
|
2150
|
+
get content_block_row_styles() {
|
|
2151
|
+
return content_block_row_styles();
|
|
2152
|
+
},
|
|
2117
2153
|
children: listing_contents
|
|
2118
2154
|
});
|
|
2119
2155
|
},
|
|
@@ -7543,7 +7579,7 @@ function $3ea8e0af95b5b7d2$export$2972b890694ced75(callback, {
|
|
|
7543
7579
|
};
|
|
7544
7580
|
const idleHandle = requestIdleCallback(deadline => {
|
|
7545
7581
|
cancel();
|
|
7546
|
-
return callback(deadline);
|
|
7582
|
+
return callback(typeof deadline?.timeRemaining === "function" ? deadline : $3ea8e0af95b5b7d2$var$makeDeadline());
|
|
7547
7583
|
}, {
|
|
7548
7584
|
timeout: timeout
|
|
7549
7585
|
});
|
|
@@ -7560,6 +7596,18 @@ function $3ea8e0af95b5b7d2$export$2972b890694ced75(callback, {
|
|
|
7560
7596
|
}, timeout + 1000);
|
|
7561
7597
|
return cancel;
|
|
7562
7598
|
}
|
|
7599
|
+
/**
|
|
7600
|
+
* Stand-in for a missing IdleDeadline: 50ms, the most a real one gives, counting down from when the callback was called
|
|
7601
|
+
*/
|
|
7602
|
+
function $3ea8e0af95b5b7d2$var$makeDeadline() {
|
|
7603
|
+
const start = performance.now();
|
|
7604
|
+
return {
|
|
7605
|
+
didTimeout: false,
|
|
7606
|
+
timeRemaining() {
|
|
7607
|
+
return Math.max(0, 50 - (performance.now() - start));
|
|
7608
|
+
}
|
|
7609
|
+
};
|
|
7610
|
+
}
|
|
7563
7611
|
function $7ea61486b66872b6$export$566cd7e46bad5c2d(callback) {
|
|
7564
7612
|
const page_hasnt_loaded =
|
|
7565
7613
|
// @ts-ignore
|
package/latest/index.d.ts
CHANGED
|
@@ -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.
|
|
14
|
+
export const version = "4.10.26";
|
|
15
15
|
/**
|
|
16
16
|
* Use `javascript_media_query` but return a reactive accessor instead of taking a callback function
|
|
17
17
|
*/
|
package/latest/index.js
CHANGED
|
@@ -7,7 +7,7 @@ import { createStore as $9HbP8$createStore, reconcile as $9HbP8$reconcile } from
|
|
|
7
7
|
/*! Depict.ai search and product listing SDK */
|
|
8
8
|
import { register_es_version } from "../multi_import_deduplicator.mjs";
|
|
9
9
|
register_es_version("ui", "latest");
|
|
10
|
-
const $ec291e0010116877$export$83d89fbfd8236492 = "4.10.
|
|
10
|
+
const $ec291e0010116877$export$83d89fbfd8236492 = "4.10.26";
|
|
11
11
|
function $dc9262ef6f786812$export$d9f36cf74e24d595(media_query) {
|
|
12
12
|
const signal = $9HbP8$createSignal(false);
|
|
13
13
|
$9HbP8$onCleanup($9HbP8$javascript_media_query(media_query, ({
|
|
@@ -1314,7 +1314,10 @@ function $6dee9211e57ac31a$export$e2f22da34aaf310a(props, container_element, ins
|
|
|
1314
1314
|
const base_styling = $9HbP8$createMemo(() => {
|
|
1315
1315
|
return `${container_selector}{display:grid;}`;
|
|
1316
1316
|
});
|
|
1317
|
-
const get_styling = $9HbP8$createMemo(() => base_styling() + col_styling())
|
|
1317
|
+
const get_styling = $9HbP8$createMemo(() => base_styling() + col_styling() + (props.content_block_row_styles || []).map(({
|
|
1318
|
+
row: row,
|
|
1319
|
+
template: template
|
|
1320
|
+
}) => `${container_selector}:has(>.content-block-wrapper.spans-multiple-rows[data-content-block-row="${row}"]){grid-template-rows:${template};}`).join(""));
|
|
1318
1321
|
const style_element = (() => {
|
|
1319
1322
|
var _el$2 = $9HbP8$getNextElement($6dee9211e57ac31a$var$_tmpl$2);
|
|
1320
1323
|
$9HbP8$insert(_el$2, get_styling);
|
|
@@ -1493,6 +1496,7 @@ function $e7a7eb102ddc0c79$export$791ef57e62e21c3f({
|
|
|
1493
1496
|
}));
|
|
1494
1497
|
const content_blocks_by_index_ = $9HbP8$createMemo(() => remapped_().content_blocks_by_index_);
|
|
1495
1498
|
return Object.assign(content_blocks_by_index_, {
|
|
1499
|
+
row_styles_: $9HbP8$createMemo(() => $e7a7eb102ddc0c79$export$c4e1acd6a7f84fcf(get_wrapped_blocks_(), n_cols_currently_showing_())),
|
|
1496
1500
|
trailing_: product_count => $e7a7eb102ddc0c79$export$b94605e5b3ce01c({
|
|
1497
1501
|
...remapped_(),
|
|
1498
1502
|
n_cols_currently_showing_: n_cols_currently_showing_(),
|
|
@@ -1500,6 +1504,24 @@ function $e7a7eb102ddc0c79$export$791ef57e62e21c3f({
|
|
|
1500
1504
|
})
|
|
1501
1505
|
});
|
|
1502
1506
|
}
|
|
1507
|
+
function $e7a7eb102ddc0c79$export$c4e1acd6a7f84fcf(blocks, n_cols) {
|
|
1508
|
+
const styles = [];
|
|
1509
|
+
if (!n_cols) return styles;
|
|
1510
|
+
let last_row = 0;
|
|
1511
|
+
blocks.forEach((block, row) => {
|
|
1512
|
+
if (!block || block.span_rows <= 1 || block.span_columns >= n_cols) return;
|
|
1513
|
+
last_row = Math.max(last_row, row + block.span_rows);
|
|
1514
|
+
// Give product rows equal heights. Full-width cards keep their own height.
|
|
1515
|
+
const tracks = Array.from({
|
|
1516
|
+
length: last_row
|
|
1517
|
+
}, (_, index) => blocks[index]?.span_columns === n_cols ? "auto" : "1fr");
|
|
1518
|
+
styles.push({
|
|
1519
|
+
row: row,
|
|
1520
|
+
template: tracks.join(" ")
|
|
1521
|
+
});
|
|
1522
|
+
});
|
|
1523
|
+
return styles;
|
|
1524
|
+
}
|
|
1503
1525
|
function $e7a7eb102ddc0c79$export$92aa5d691d588f3f({
|
|
1504
1526
|
wrapped_blocks_: wrapped_blocks_,
|
|
1505
1527
|
n_cols_currently_showing_: n_cols_currently_showing_
|
|
@@ -1619,11 +1641,12 @@ function $e7a7eb102ddc0c79$export$911278b0390ae36e(block, max_span_columns) {
|
|
|
1619
1641
|
return {
|
|
1620
1642
|
span_columns: span_columns,
|
|
1621
1643
|
span_rows: spans_whole_row ? 1 : block.span_rows,
|
|
1622
|
-
spans_whole_row: spans_whole_row
|
|
1644
|
+
spans_whole_row: spans_whole_row,
|
|
1645
|
+
spans_multiple_rows: !spans_whole_row && block.span_rows > 1
|
|
1623
1646
|
};
|
|
1624
1647
|
}
|
|
1625
1648
|
function $e7a7eb102ddc0c79$var$wrap_blocks_in_div(rendered_content_blocks, max_span_columns) {
|
|
1626
|
-
const get_wrapped_blocks = $9HbP8$mapArray(() => rendered_content_blocks, block => {
|
|
1649
|
+
const get_wrapped_blocks = $9HbP8$mapArray(() => rendered_content_blocks, (block, row) => {
|
|
1627
1650
|
if (!block) return;
|
|
1628
1651
|
const final_spans = $9HbP8$createMemo(() => $e7a7eb102ddc0c79$export$911278b0390ae36e(block, max_span_columns()));
|
|
1629
1652
|
const final_span_columns = $9HbP8$createMemo(() => final_spans().span_columns);
|
|
@@ -1641,22 +1664,28 @@ function $e7a7eb102ddc0c79$var$wrap_blocks_in_div(rendered_content_blocks, max_s
|
|
|
1641
1664
|
}
|
|
1642
1665
|
}));
|
|
1643
1666
|
$9HbP8$effect(_p$ => {
|
|
1644
|
-
var _v$ =
|
|
1645
|
-
_v$2 =
|
|
1667
|
+
var _v$ = row(),
|
|
1668
|
+
_v$2 = !!final_spans().spans_whole_row,
|
|
1669
|
+
_v$3 = !!final_spans().spans_multiple_rows,
|
|
1670
|
+
_v$4 = {
|
|
1646
1671
|
[(0, $6dee9211e57ac31a$export$c500183c31c2b22e)]: final_span_columns()
|
|
1647
1672
|
},
|
|
1648
|
-
_v$
|
|
1649
|
-
_v$
|
|
1650
|
-
_v$ !== _p$.e && _el
|
|
1651
|
-
_p$.t
|
|
1652
|
-
_v$3 !== _p$.a &&
|
|
1653
|
-
|
|
1673
|
+
_v$5 = `span ${final_span_columns()}`,
|
|
1674
|
+
_v$6 = `span ${final_span_rows()}`;
|
|
1675
|
+
_v$ !== _p$.e && $9HbP8$setAttribute(_el$, "data-content-block-row", _p$.e = _v$);
|
|
1676
|
+
_v$2 !== _p$.t && _el$.classList.toggle("spans-whole-row", _p$.t = _v$2);
|
|
1677
|
+
_v$3 !== _p$.a && _el$.classList.toggle("spans-multiple-rows", _p$.a = _v$3);
|
|
1678
|
+
_p$.o = $9HbP8$style(_el$, _v$4, _p$.o);
|
|
1679
|
+
_v$5 !== _p$.i && ((_p$.i = _v$5) != null ? _el$.style.setProperty("grid-column", _v$5) : _el$.style.removeProperty("grid-column"));
|
|
1680
|
+
_v$6 !== _p$.n && ((_p$.n = _v$6) != null ? _el$.style.setProperty("grid-row", _v$6) : _el$.style.removeProperty("grid-row"));
|
|
1654
1681
|
return _p$;
|
|
1655
1682
|
}, {
|
|
1656
1683
|
e: undefined,
|
|
1657
1684
|
t: undefined,
|
|
1658
1685
|
a: undefined,
|
|
1659
|
-
o: undefined
|
|
1686
|
+
o: undefined,
|
|
1687
|
+
i: undefined,
|
|
1688
|
+
n: undefined
|
|
1660
1689
|
});
|
|
1661
1690
|
return _el$;
|
|
1662
1691
|
}
|
|
@@ -1913,6 +1942,10 @@ function $2d25e42846eac370$export$3925f87b1545cfc6({
|
|
|
1913
1942
|
cols_at_size_: modified_cols_at_size,
|
|
1914
1943
|
set_top_row_shortened_by_: set_top_row_shortened_by_
|
|
1915
1944
|
}));
|
|
1945
|
+
const content_block_row_styles = $9HbP8$createMemo(() => {
|
|
1946
|
+
const blocks = content_blocks_();
|
|
1947
|
+
return "row_styles_" in blocks ? blocks.row_styles_() : [];
|
|
1948
|
+
});
|
|
1916
1949
|
const rendered_placeholders = $9HbP8$createMemo(() => {
|
|
1917
1950
|
if (get_should_have_placeholders_rendered()) return $6e41f1fde994db72$export$f33414a4df0afd3f({
|
|
1918
1951
|
content_blocks_: content_blocks_,
|
|
@@ -2012,6 +2045,9 @@ function $2d25e42846eac370$export$3925f87b1545cfc6({
|
|
|
2012
2045
|
class: "cards css-grid"
|
|
2013
2046
|
},
|
|
2014
2047
|
top_row_shortened_by_: top_row_shortened_by_,
|
|
2048
|
+
get content_block_row_styles() {
|
|
2049
|
+
return content_block_row_styles();
|
|
2050
|
+
},
|
|
2015
2051
|
children: listing_contents
|
|
2016
2052
|
});
|
|
2017
2053
|
},
|
|
@@ -7441,7 +7477,7 @@ function $4ea56971d92eb0cd$export$2972b890694ced75(callback, {
|
|
|
7441
7477
|
};
|
|
7442
7478
|
const idleHandle = requestIdleCallback(deadline => {
|
|
7443
7479
|
cancel();
|
|
7444
|
-
return callback(deadline);
|
|
7480
|
+
return callback(typeof deadline?.timeRemaining === "function" ? deadline : $4ea56971d92eb0cd$var$makeDeadline());
|
|
7445
7481
|
}, {
|
|
7446
7482
|
timeout: timeout
|
|
7447
7483
|
});
|
|
@@ -7458,6 +7494,18 @@ function $4ea56971d92eb0cd$export$2972b890694ced75(callback, {
|
|
|
7458
7494
|
}, timeout + 1000);
|
|
7459
7495
|
return cancel;
|
|
7460
7496
|
}
|
|
7497
|
+
/**
|
|
7498
|
+
* Stand-in for a missing IdleDeadline: 50ms, the most a real one gives, counting down from when the callback was called
|
|
7499
|
+
*/
|
|
7500
|
+
function $4ea56971d92eb0cd$var$makeDeadline() {
|
|
7501
|
+
const start = performance.now();
|
|
7502
|
+
return {
|
|
7503
|
+
didTimeout: false,
|
|
7504
|
+
timeRemaining() {
|
|
7505
|
+
return Math.max(0, 50 - (performance.now() - start));
|
|
7506
|
+
}
|
|
7507
|
+
};
|
|
7508
|
+
}
|
|
7461
7509
|
function $f71681eb5d5aae0a$export$566cd7e46bad5c2d(callback) {
|
|
7462
7510
|
const page_hasnt_loaded =
|
|
7463
7511
|
// @ts-ignore
|
package/package.json
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
"url": "git+https://github.com/depict-org/depict-ui.git",
|
|
6
6
|
"directory": "browser-tags-v2/packages/ui"
|
|
7
7
|
},
|
|
8
|
-
"version": "4.10.
|
|
8
|
+
"version": "4.10.26",
|
|
9
9
|
"description": "Base package containing the actual UI of Depict UI along with translations, with a not-simplified API. We recommend using @depict-ai/js-ui or @depict-ai/react-ui instead.",
|
|
10
10
|
"packageManager": "yarn@3.2.2",
|
|
11
11
|
"sass": "styles.scss",
|
|
@@ -241,9 +241,9 @@
|
|
|
241
241
|
"@babel/plugin-transform-typescript": "^7.22.9",
|
|
242
242
|
"@babel/runtime": "^7.22.6",
|
|
243
243
|
"@babel/runtime-corejs3": "^7.22.6",
|
|
244
|
-
"@depict-ai/plp-styling": "^4.6.
|
|
245
|
-
"@depict-ai/types": "^5.6.
|
|
246
|
-
"@depict-ai/utilishared": "^2.6.
|
|
244
|
+
"@depict-ai/plp-styling": "^4.6.17",
|
|
245
|
+
"@depict-ai/types": "^5.6.15",
|
|
246
|
+
"@depict-ai/utilishared": "^2.6.15",
|
|
247
247
|
"solid-js": "^1.9.10"
|
|
248
248
|
},
|
|
249
249
|
"type": "module",
|
package/server/ES10/index.cjs
CHANGED
|
@@ -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.
|
|
118
|
+
const $aa1938dec50d6c12$export$83d89fbfd8236492 = "4.10.26";
|
|
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 => {
|
|
@@ -1206,19 +1206,25 @@ function $830518481649feb1$export$e2f22da34aaf310a(props, container_element) {
|
|
|
1206
1206
|
const base_styling = $3hooq$solidjs.createMemo(() => {
|
|
1207
1207
|
return "".concat(container_selector, "{display:grid;}");
|
|
1208
1208
|
});
|
|
1209
|
-
const get_styling = $3hooq$solidjs.createMemo(() => base_styling() + col_styling())
|
|
1209
|
+
const get_styling = $3hooq$solidjs.createMemo(() => base_styling() + col_styling() + (props.content_block_row_styles || []).map(_ref => {
|
|
1210
|
+
let {
|
|
1211
|
+
row: row,
|
|
1212
|
+
template: template
|
|
1213
|
+
} = _ref;
|
|
1214
|
+
return "".concat(container_selector, ':has(>.content-block-wrapper.spans-multiple-rows[data-content-block-row="').concat(row, '"]){grid-template-rows:').concat(template, ";}");
|
|
1215
|
+
}).join(""));
|
|
1210
1216
|
const style_element = $3hooq$solidjsweb.ssr($830518481649feb1$var$_tmpl$, $3hooq$solidjsweb.ssrHydrationKey(), get_styling); // need to create this after set_styling has been called or else there will be no styling in the SSR'd output
|
|
1211
1217
|
if (insert_after_container) container_element.after(style_element);
|
|
1212
1218
|
return [container_element, style_element];
|
|
1213
1219
|
}
|
|
1214
|
-
function $830518481649feb1$var$generate_media_queried_declarations(
|
|
1220
|
+
function $830518481649feb1$var$generate_media_queried_declarations(_ref2) {
|
|
1215
1221
|
let {
|
|
1216
1222
|
container_selector_: container_selector_,
|
|
1217
1223
|
default_grid_spacing_text: default_grid_spacing_text,
|
|
1218
1224
|
cols_at_size_: cols_at_size_,
|
|
1219
1225
|
override_vertical_spacing_: override_vertical_spacing_,
|
|
1220
1226
|
top_row_shortened_by_: top_row_shortened_by_
|
|
1221
|
-
} =
|
|
1227
|
+
} = _ref2;
|
|
1222
1228
|
return cols_at_size_.map(options => {
|
|
1223
1229
|
const [n_cols, min, max, grid_spacing_for_size] = options;
|
|
1224
1230
|
const main_spacing_to_use = grid_spacing_for_size || default_grid_spacing_text;
|
|
@@ -1338,7 +1344,7 @@ function $b8a8d61b3ec5f5ac$export$3f37af283f8fb843(props) {
|
|
|
1338
1344
|
}
|
|
1339
1345
|
});
|
|
1340
1346
|
}
|
|
1341
|
-
var $f8f375d6245ffff2$var$_tmpl$ = ["<div", ' class="', '" style="', '">', "</div>"];
|
|
1347
|
+
var $f8f375d6245ffff2$var$_tmpl$ = ["<div", ' class="', '"', ' style="', '">', "</div>"];
|
|
1342
1348
|
function $f8f375d6245ffff2$export$791ef57e62e21c3f(_ref) {
|
|
1343
1349
|
let {
|
|
1344
1350
|
content_blocks_: incoming_content_blocks,
|
|
@@ -1378,6 +1384,7 @@ function $f8f375d6245ffff2$export$791ef57e62e21c3f(_ref) {
|
|
|
1378
1384
|
}));
|
|
1379
1385
|
const content_blocks_by_index_ = $3hooq$solidjs.createMemo(() => remapped_().content_blocks_by_index_);
|
|
1380
1386
|
return Object.assign(content_blocks_by_index_, {
|
|
1387
|
+
row_styles_: $3hooq$solidjs.createMemo(() => $f8f375d6245ffff2$export$c4e1acd6a7f84fcf(get_wrapped_blocks_(), n_cols_currently_showing_())),
|
|
1381
1388
|
trailing_: product_count => $f8f375d6245ffff2$export$b94605e5b3ce01c({
|
|
1382
1389
|
...remapped_(),
|
|
1383
1390
|
n_cols_currently_showing_: n_cols_currently_showing_(),
|
|
@@ -1385,6 +1392,27 @@ function $f8f375d6245ffff2$export$791ef57e62e21c3f(_ref) {
|
|
|
1385
1392
|
})
|
|
1386
1393
|
});
|
|
1387
1394
|
}
|
|
1395
|
+
function $f8f375d6245ffff2$export$c4e1acd6a7f84fcf(blocks, n_cols) {
|
|
1396
|
+
const styles = [];
|
|
1397
|
+
if (!n_cols) return styles;
|
|
1398
|
+
let last_row = 0;
|
|
1399
|
+
blocks.forEach((block, row) => {
|
|
1400
|
+
if (!block || block.span_rows <= 1 || block.span_columns >= n_cols) return;
|
|
1401
|
+
last_row = Math.max(last_row, row + block.span_rows);
|
|
1402
|
+
// Give product rows equal heights. Full-width cards keep their own height.
|
|
1403
|
+
const tracks = Array.from({
|
|
1404
|
+
length: last_row
|
|
1405
|
+
}, (_, index) => {
|
|
1406
|
+
var _blocks$index;
|
|
1407
|
+
return ((_blocks$index = blocks[index]) === null || _blocks$index === void 0 ? void 0 : _blocks$index.span_columns) === n_cols ? "auto" : "1fr";
|
|
1408
|
+
});
|
|
1409
|
+
styles.push({
|
|
1410
|
+
row: row,
|
|
1411
|
+
template: tracks.join(" ")
|
|
1412
|
+
});
|
|
1413
|
+
});
|
|
1414
|
+
return styles;
|
|
1415
|
+
}
|
|
1388
1416
|
function $f8f375d6245ffff2$export$92aa5d691d588f3f(_ref2) {
|
|
1389
1417
|
let {
|
|
1390
1418
|
wrapped_blocks_: wrapped_blocks_,
|
|
@@ -1511,11 +1539,12 @@ function $f8f375d6245ffff2$export$911278b0390ae36e(block, max_span_columns) {
|
|
|
1511
1539
|
return {
|
|
1512
1540
|
span_columns: span_columns,
|
|
1513
1541
|
span_rows: spans_whole_row ? 1 : block.span_rows,
|
|
1514
|
-
spans_whole_row: spans_whole_row
|
|
1542
|
+
spans_whole_row: spans_whole_row,
|
|
1543
|
+
spans_multiple_rows: !spans_whole_row && block.span_rows > 1
|
|
1515
1544
|
};
|
|
1516
1545
|
}
|
|
1517
1546
|
function $f8f375d6245ffff2$var$wrap_blocks_in_div(rendered_content_blocks, max_span_columns) {
|
|
1518
|
-
const get_wrapped_blocks = $3hooq$solidjs.mapArray(() => rendered_content_blocks, block => {
|
|
1547
|
+
const get_wrapped_blocks = $3hooq$solidjs.mapArray(() => rendered_content_blocks, (block, row) => {
|
|
1519
1548
|
if (!block) return;
|
|
1520
1549
|
const final_spans = $3hooq$solidjs.createMemo(() => $f8f375d6245ffff2$export$911278b0390ae36e(block, max_span_columns()));
|
|
1521
1550
|
const final_span_columns = $3hooq$solidjs.createMemo(() => final_spans().span_columns);
|
|
@@ -1526,7 +1555,7 @@ function $f8f375d6245ffff2$var$wrap_blocks_in_div(rendered_content_blocks, max_s
|
|
|
1526
1555
|
return !rendering_delayed();
|
|
1527
1556
|
},
|
|
1528
1557
|
get children() {
|
|
1529
|
-
return $3hooq$solidjsweb.ssr($f8f375d6245ffff2$var$_tmpl$, $3hooq$solidjsweb.ssrHydrationKey(), "content-block-wrapper ".concat(final_spans().spans_whole_row ? "spans-whole-row" : ""), "grid-column:" + "span ".concat($3hooq$solidjsweb.escape(final_span_columns(), true)) + (";grid-row:" + "span ".concat($3hooq$solidjsweb.escape(final_span_rows(), true))) + (";spans_columns_variable_name:" + $3hooq$solidjsweb.escape(final_span_columns(), true)), $3hooq$solidjsweb.escape($3hooq$solidjsweb.createComponent($f8f375d6245ffff2$var$RenderContent, {
|
|
1558
|
+
return $3hooq$solidjsweb.ssr($f8f375d6245ffff2$var$_tmpl$, $3hooq$solidjsweb.ssrHydrationKey(), "content-block-wrapper ".concat(final_spans().spans_whole_row ? "spans-whole-row" : "", " ").concat(final_spans().spans_multiple_rows ? "spans-multiple-rows" : ""), $3hooq$solidjsweb.ssrAttribute("data-content-block-row", $3hooq$solidjsweb.escape(row(), true), false), "grid-column:" + "span ".concat($3hooq$solidjsweb.escape(final_span_columns(), true)) + (";grid-row:" + "span ".concat($3hooq$solidjsweb.escape(final_span_rows(), true))) + (";spans_columns_variable_name:" + $3hooq$solidjsweb.escape(final_span_columns(), true)), $3hooq$solidjsweb.escape($3hooq$solidjsweb.createComponent($f8f375d6245ffff2$var$RenderContent, {
|
|
1530
1559
|
get content() {
|
|
1531
1560
|
return block.content;
|
|
1532
1561
|
}
|
|
@@ -1755,6 +1784,10 @@ function $484eec37514a982e$export$3925f87b1545cfc6(_ref) {
|
|
|
1755
1784
|
cols_at_size_: modified_cols_at_size,
|
|
1756
1785
|
set_top_row_shortened_by_: set_top_row_shortened_by_
|
|
1757
1786
|
}));
|
|
1787
|
+
const content_block_row_styles = $3hooq$solidjs.createMemo(() => {
|
|
1788
|
+
const blocks = content_blocks_();
|
|
1789
|
+
return "row_styles_" in blocks ? blocks.row_styles_() : [];
|
|
1790
|
+
});
|
|
1758
1791
|
const rendered_placeholders = $3hooq$solidjs.createMemo(() => {
|
|
1759
1792
|
if (get_should_have_placeholders_rendered()) return $e3915574cfd3466c$export$f33414a4df0afd3f({
|
|
1760
1793
|
content_blocks_: content_blocks_,
|
|
@@ -1854,6 +1887,9 @@ function $484eec37514a982e$export$3925f87b1545cfc6(_ref) {
|
|
|
1854
1887
|
class: "cards css-grid"
|
|
1855
1888
|
},
|
|
1856
1889
|
top_row_shortened_by_: top_row_shortened_by_,
|
|
1890
|
+
get content_block_row_styles() {
|
|
1891
|
+
return content_block_row_styles();
|
|
1892
|
+
},
|
|
1857
1893
|
children: listing_contents
|
|
1858
1894
|
});
|
|
1859
1895
|
},
|
|
@@ -6483,7 +6519,7 @@ function $e4e98e5080f4386e$export$2972b890694ced75(callback, _ref) {
|
|
|
6483
6519
|
};
|
|
6484
6520
|
const idleHandle = requestIdleCallback(deadline => {
|
|
6485
6521
|
cancel();
|
|
6486
|
-
return callback(deadline);
|
|
6522
|
+
return callback(typeof (deadline === null || deadline === void 0 ? void 0 : deadline.timeRemaining) === "function" ? deadline : $e4e98e5080f4386e$var$makeDeadline());
|
|
6487
6523
|
}, {
|
|
6488
6524
|
timeout: timeout
|
|
6489
6525
|
});
|
|
@@ -6500,6 +6536,18 @@ function $e4e98e5080f4386e$export$2972b890694ced75(callback, _ref) {
|
|
|
6500
6536
|
}, timeout + 1000);
|
|
6501
6537
|
return cancel;
|
|
6502
6538
|
}
|
|
6539
|
+
/**
|
|
6540
|
+
* Stand-in for a missing IdleDeadline: 50ms, the most a real one gives, counting down from when the callback was called
|
|
6541
|
+
*/
|
|
6542
|
+
function $e4e98e5080f4386e$var$makeDeadline() {
|
|
6543
|
+
const start = performance.now();
|
|
6544
|
+
return {
|
|
6545
|
+
didTimeout: false,
|
|
6546
|
+
timeRemaining() {
|
|
6547
|
+
return Math.max(0, 50 - (performance.now() - start));
|
|
6548
|
+
}
|
|
6549
|
+
};
|
|
6550
|
+
}
|
|
6503
6551
|
function $4692443b324db9ee$export$566cd7e46bad5c2d(callback) {
|
|
6504
6552
|
var _globalThis$performan, _globalThis$performan2, _globalThis$performan3, _globalThis$performan4;
|
|
6505
6553
|
const page_hasnt_loaded =
|
package/server/ES10/index.d.ts
CHANGED
|
@@ -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.
|
|
14
|
+
export const version = "4.10.26";
|
|
15
15
|
/**
|
|
16
16
|
* Use `javascript_media_query` but return a reactive accessor instead of taking a callback function
|
|
17
17
|
*/
|
package/server/ES10/index.js
CHANGED
|
@@ -10,7 +10,7 @@ import $b8hua$babelruntimehelpersclassPrivateFieldGet from "@babel/runtime/helpe
|
|
|
10
10
|
/*! Depict.ai search and product listing SDK */
|
|
11
11
|
import { register_es_version } from "../../multi_import_deduplicator.mjs";
|
|
12
12
|
register_es_version("ui", "ES10");
|
|
13
|
-
const $8db9a15135765c11$export$83d89fbfd8236492 = "4.10.
|
|
13
|
+
const $8db9a15135765c11$export$83d89fbfd8236492 = "4.10.26";
|
|
14
14
|
function $00a5b94f0c11efbb$export$d9f36cf74e24d595(media_query) {
|
|
15
15
|
const signal = $b8hua$createSignal(false);
|
|
16
16
|
$b8hua$onCleanup($b8hua$javascript_media_query(media_query, _ref => {
|
|
@@ -1101,19 +1101,25 @@ function $64d94dcaa058dc7b$export$e2f22da34aaf310a(props, container_element) {
|
|
|
1101
1101
|
const base_styling = $b8hua$createMemo(() => {
|
|
1102
1102
|
return "".concat(container_selector, "{display:grid;}");
|
|
1103
1103
|
});
|
|
1104
|
-
const get_styling = $b8hua$createMemo(() => base_styling() + col_styling())
|
|
1104
|
+
const get_styling = $b8hua$createMemo(() => base_styling() + col_styling() + (props.content_block_row_styles || []).map(_ref => {
|
|
1105
|
+
let {
|
|
1106
|
+
row: row,
|
|
1107
|
+
template: template
|
|
1108
|
+
} = _ref;
|
|
1109
|
+
return "".concat(container_selector, ':has(>.content-block-wrapper.spans-multiple-rows[data-content-block-row="').concat(row, '"]){grid-template-rows:').concat(template, ";}");
|
|
1110
|
+
}).join(""));
|
|
1105
1111
|
const style_element = $b8hua$ssr($64d94dcaa058dc7b$var$_tmpl$, $b8hua$ssrHydrationKey(), get_styling); // need to create this after set_styling has been called or else there will be no styling in the SSR'd output
|
|
1106
1112
|
if (insert_after_container) container_element.after(style_element);
|
|
1107
1113
|
return [container_element, style_element];
|
|
1108
1114
|
}
|
|
1109
|
-
function $64d94dcaa058dc7b$var$generate_media_queried_declarations(
|
|
1115
|
+
function $64d94dcaa058dc7b$var$generate_media_queried_declarations(_ref2) {
|
|
1110
1116
|
let {
|
|
1111
1117
|
container_selector_: container_selector_,
|
|
1112
1118
|
default_grid_spacing_text: default_grid_spacing_text,
|
|
1113
1119
|
cols_at_size_: cols_at_size_,
|
|
1114
1120
|
override_vertical_spacing_: override_vertical_spacing_,
|
|
1115
1121
|
top_row_shortened_by_: top_row_shortened_by_
|
|
1116
|
-
} =
|
|
1122
|
+
} = _ref2;
|
|
1117
1123
|
return cols_at_size_.map(options => {
|
|
1118
1124
|
const [n_cols, min, max, grid_spacing_for_size] = options;
|
|
1119
1125
|
const main_spacing_to_use = grid_spacing_for_size || default_grid_spacing_text;
|
|
@@ -1233,7 +1239,7 @@ function $3ab4aa97880fb88d$export$3f37af283f8fb843(props) {
|
|
|
1233
1239
|
}
|
|
1234
1240
|
});
|
|
1235
1241
|
}
|
|
1236
|
-
var $ff7feae4dddd6073$var$_tmpl$ = ["<div", ' class="', '" style="', '">', "</div>"];
|
|
1242
|
+
var $ff7feae4dddd6073$var$_tmpl$ = ["<div", ' class="', '"', ' style="', '">', "</div>"];
|
|
1237
1243
|
function $ff7feae4dddd6073$export$791ef57e62e21c3f(_ref) {
|
|
1238
1244
|
let {
|
|
1239
1245
|
content_blocks_: incoming_content_blocks,
|
|
@@ -1273,6 +1279,7 @@ function $ff7feae4dddd6073$export$791ef57e62e21c3f(_ref) {
|
|
|
1273
1279
|
}));
|
|
1274
1280
|
const content_blocks_by_index_ = $b8hua$createMemo(() => remapped_().content_blocks_by_index_);
|
|
1275
1281
|
return Object.assign(content_blocks_by_index_, {
|
|
1282
|
+
row_styles_: $b8hua$createMemo(() => $ff7feae4dddd6073$export$c4e1acd6a7f84fcf(get_wrapped_blocks_(), n_cols_currently_showing_())),
|
|
1276
1283
|
trailing_: product_count => $ff7feae4dddd6073$export$b94605e5b3ce01c({
|
|
1277
1284
|
...remapped_(),
|
|
1278
1285
|
n_cols_currently_showing_: n_cols_currently_showing_(),
|
|
@@ -1280,6 +1287,27 @@ function $ff7feae4dddd6073$export$791ef57e62e21c3f(_ref) {
|
|
|
1280
1287
|
})
|
|
1281
1288
|
});
|
|
1282
1289
|
}
|
|
1290
|
+
function $ff7feae4dddd6073$export$c4e1acd6a7f84fcf(blocks, n_cols) {
|
|
1291
|
+
const styles = [];
|
|
1292
|
+
if (!n_cols) return styles;
|
|
1293
|
+
let last_row = 0;
|
|
1294
|
+
blocks.forEach((block, row) => {
|
|
1295
|
+
if (!block || block.span_rows <= 1 || block.span_columns >= n_cols) return;
|
|
1296
|
+
last_row = Math.max(last_row, row + block.span_rows);
|
|
1297
|
+
// Give product rows equal heights. Full-width cards keep their own height.
|
|
1298
|
+
const tracks = Array.from({
|
|
1299
|
+
length: last_row
|
|
1300
|
+
}, (_, index) => {
|
|
1301
|
+
var _blocks$index;
|
|
1302
|
+
return ((_blocks$index = blocks[index]) === null || _blocks$index === void 0 ? void 0 : _blocks$index.span_columns) === n_cols ? "auto" : "1fr";
|
|
1303
|
+
});
|
|
1304
|
+
styles.push({
|
|
1305
|
+
row: row,
|
|
1306
|
+
template: tracks.join(" ")
|
|
1307
|
+
});
|
|
1308
|
+
});
|
|
1309
|
+
return styles;
|
|
1310
|
+
}
|
|
1283
1311
|
function $ff7feae4dddd6073$export$92aa5d691d588f3f(_ref2) {
|
|
1284
1312
|
let {
|
|
1285
1313
|
wrapped_blocks_: wrapped_blocks_,
|
|
@@ -1406,11 +1434,12 @@ function $ff7feae4dddd6073$export$911278b0390ae36e(block, max_span_columns) {
|
|
|
1406
1434
|
return {
|
|
1407
1435
|
span_columns: span_columns,
|
|
1408
1436
|
span_rows: spans_whole_row ? 1 : block.span_rows,
|
|
1409
|
-
spans_whole_row: spans_whole_row
|
|
1437
|
+
spans_whole_row: spans_whole_row,
|
|
1438
|
+
spans_multiple_rows: !spans_whole_row && block.span_rows > 1
|
|
1410
1439
|
};
|
|
1411
1440
|
}
|
|
1412
1441
|
function $ff7feae4dddd6073$var$wrap_blocks_in_div(rendered_content_blocks, max_span_columns) {
|
|
1413
|
-
const get_wrapped_blocks = $b8hua$mapArray(() => rendered_content_blocks, block => {
|
|
1442
|
+
const get_wrapped_blocks = $b8hua$mapArray(() => rendered_content_blocks, (block, row) => {
|
|
1414
1443
|
if (!block) return;
|
|
1415
1444
|
const final_spans = $b8hua$createMemo(() => $ff7feae4dddd6073$export$911278b0390ae36e(block, max_span_columns()));
|
|
1416
1445
|
const final_span_columns = $b8hua$createMemo(() => final_spans().span_columns);
|
|
@@ -1421,7 +1450,7 @@ function $ff7feae4dddd6073$var$wrap_blocks_in_div(rendered_content_blocks, max_s
|
|
|
1421
1450
|
return !rendering_delayed();
|
|
1422
1451
|
},
|
|
1423
1452
|
get children() {
|
|
1424
|
-
return $b8hua$ssr($ff7feae4dddd6073$var$_tmpl$, $b8hua$ssrHydrationKey(), "content-block-wrapper ".concat(final_spans().spans_whole_row ? "spans-whole-row" : ""), "grid-column:" + "span ".concat($b8hua$escape(final_span_columns(), true)) + (";grid-row:" + "span ".concat($b8hua$escape(final_span_rows(), true))) + (";spans_columns_variable_name:" + $b8hua$escape(final_span_columns(), true)), $b8hua$escape($b8hua$createComponent($ff7feae4dddd6073$var$RenderContent, {
|
|
1453
|
+
return $b8hua$ssr($ff7feae4dddd6073$var$_tmpl$, $b8hua$ssrHydrationKey(), "content-block-wrapper ".concat(final_spans().spans_whole_row ? "spans-whole-row" : "", " ").concat(final_spans().spans_multiple_rows ? "spans-multiple-rows" : ""), $b8hua$ssrAttribute("data-content-block-row", $b8hua$escape(row(), true), false), "grid-column:" + "span ".concat($b8hua$escape(final_span_columns(), true)) + (";grid-row:" + "span ".concat($b8hua$escape(final_span_rows(), true))) + (";spans_columns_variable_name:" + $b8hua$escape(final_span_columns(), true)), $b8hua$escape($b8hua$createComponent($ff7feae4dddd6073$var$RenderContent, {
|
|
1425
1454
|
get content() {
|
|
1426
1455
|
return block.content;
|
|
1427
1456
|
}
|
|
@@ -1650,6 +1679,10 @@ function $7faea0096f14b59b$export$3925f87b1545cfc6(_ref) {
|
|
|
1650
1679
|
cols_at_size_: modified_cols_at_size,
|
|
1651
1680
|
set_top_row_shortened_by_: set_top_row_shortened_by_
|
|
1652
1681
|
}));
|
|
1682
|
+
const content_block_row_styles = $b8hua$createMemo(() => {
|
|
1683
|
+
const blocks = content_blocks_();
|
|
1684
|
+
return "row_styles_" in blocks ? blocks.row_styles_() : [];
|
|
1685
|
+
});
|
|
1653
1686
|
const rendered_placeholders = $b8hua$createMemo(() => {
|
|
1654
1687
|
if (get_should_have_placeholders_rendered()) return $bdd80c7862246dc2$export$f33414a4df0afd3f({
|
|
1655
1688
|
content_blocks_: content_blocks_,
|
|
@@ -1749,6 +1782,9 @@ function $7faea0096f14b59b$export$3925f87b1545cfc6(_ref) {
|
|
|
1749
1782
|
class: "cards css-grid"
|
|
1750
1783
|
},
|
|
1751
1784
|
top_row_shortened_by_: top_row_shortened_by_,
|
|
1785
|
+
get content_block_row_styles() {
|
|
1786
|
+
return content_block_row_styles();
|
|
1787
|
+
},
|
|
1752
1788
|
children: listing_contents
|
|
1753
1789
|
});
|
|
1754
1790
|
},
|
|
@@ -6378,7 +6414,7 @@ function $6db93f70c2db1486$export$2972b890694ced75(callback, _ref) {
|
|
|
6378
6414
|
};
|
|
6379
6415
|
const idleHandle = requestIdleCallback(deadline => {
|
|
6380
6416
|
cancel();
|
|
6381
|
-
return callback(deadline);
|
|
6417
|
+
return callback(typeof (deadline === null || deadline === void 0 ? void 0 : deadline.timeRemaining) === "function" ? deadline : $6db93f70c2db1486$var$makeDeadline());
|
|
6382
6418
|
}, {
|
|
6383
6419
|
timeout: timeout
|
|
6384
6420
|
});
|
|
@@ -6395,6 +6431,18 @@ function $6db93f70c2db1486$export$2972b890694ced75(callback, _ref) {
|
|
|
6395
6431
|
}, timeout + 1000);
|
|
6396
6432
|
return cancel;
|
|
6397
6433
|
}
|
|
6434
|
+
/**
|
|
6435
|
+
* Stand-in for a missing IdleDeadline: 50ms, the most a real one gives, counting down from when the callback was called
|
|
6436
|
+
*/
|
|
6437
|
+
function $6db93f70c2db1486$var$makeDeadline() {
|
|
6438
|
+
const start = performance.now();
|
|
6439
|
+
return {
|
|
6440
|
+
didTimeout: false,
|
|
6441
|
+
timeRemaining() {
|
|
6442
|
+
return Math.max(0, 50 - (performance.now() - start));
|
|
6443
|
+
}
|
|
6444
|
+
};
|
|
6445
|
+
}
|
|
6398
6446
|
function $29b3cf99ce390e3b$export$566cd7e46bad5c2d(callback) {
|
|
6399
6447
|
var _globalThis$performan, _globalThis$performan2, _globalThis$performan3, _globalThis$performan4;
|
|
6400
6448
|
const page_hasnt_loaded =
|
package/server/latest/index.cjs
CHANGED
|
@@ -109,7 +109,7 @@ $parcel$export(module.exports, "BreadCrumbs", () => $1f4925833f07df29$export$5b7
|
|
|
109
109
|
$parcel$export(module.exports, "QuickLinks", () => $1f4925833f07df29$export$de035477d6fef996);
|
|
110
110
|
$parcel$export(module.exports, "CategoryPage", () => $14f289047713d67a$export$e2bf8ce7779e827e);
|
|
111
111
|
/*! Depict.ai search and product listing SDK */
|
|
112
|
-
const $b757f75811f3261f$export$83d89fbfd8236492 = "4.10.
|
|
112
|
+
const $b757f75811f3261f$export$83d89fbfd8236492 = "4.10.26";
|
|
113
113
|
function $b54e6192d0caa293$export$d9f36cf74e24d595(media_query) {
|
|
114
114
|
const signal = $5vyXB$solidjs.createSignal(false);
|
|
115
115
|
$5vyXB$solidjs.onCleanup($5vyXB$depictaiutilishared.javascript_media_query(media_query, ({
|
|
@@ -1153,7 +1153,10 @@ function $75777da1687ba3f6$export$e2f22da34aaf310a(props, container_element, ins
|
|
|
1153
1153
|
const base_styling = $5vyXB$solidjs.createMemo(() => {
|
|
1154
1154
|
return `${container_selector}{display:grid;}`;
|
|
1155
1155
|
});
|
|
1156
|
-
const get_styling = $5vyXB$solidjs.createMemo(() => base_styling() + col_styling())
|
|
1156
|
+
const get_styling = $5vyXB$solidjs.createMemo(() => base_styling() + col_styling() + (props.content_block_row_styles || []).map(({
|
|
1157
|
+
row: row,
|
|
1158
|
+
template: template
|
|
1159
|
+
}) => `${container_selector}:has(>.content-block-wrapper.spans-multiple-rows[data-content-block-row="${row}"]){grid-template-rows:${template};}`).join(""));
|
|
1157
1160
|
const style_element = $5vyXB$solidjsweb.ssr($75777da1687ba3f6$var$_tmpl$, $5vyXB$solidjsweb.ssrHydrationKey(), get_styling); // need to create this after set_styling has been called or else there will be no styling in the SSR'd output
|
|
1158
1161
|
if (insert_after_container) container_element.after(style_element);
|
|
1159
1162
|
return [container_element, style_element];
|
|
@@ -1276,7 +1279,7 @@ function $3bc4a89b971a3af5$export$3f37af283f8fb843(props) {
|
|
|
1276
1279
|
}
|
|
1277
1280
|
});
|
|
1278
1281
|
}
|
|
1279
|
-
var $d92f338ba8f9da9b$var$_tmpl$ = ["<div", ' class="', '" style="', '">', "</div>"];
|
|
1282
|
+
var $d92f338ba8f9da9b$var$_tmpl$ = ["<div", ' class="', '"', ' style="', '">', "</div>"];
|
|
1280
1283
|
function $d92f338ba8f9da9b$export$791ef57e62e21c3f({
|
|
1281
1284
|
content_blocks_: incoming_content_blocks,
|
|
1282
1285
|
cols_at_size_: cols_at_size_,
|
|
@@ -1315,6 +1318,7 @@ function $d92f338ba8f9da9b$export$791ef57e62e21c3f({
|
|
|
1315
1318
|
}));
|
|
1316
1319
|
const content_blocks_by_index_ = $5vyXB$solidjs.createMemo(() => remapped_().content_blocks_by_index_);
|
|
1317
1320
|
return Object.assign(content_blocks_by_index_, {
|
|
1321
|
+
row_styles_: $5vyXB$solidjs.createMemo(() => $d92f338ba8f9da9b$export$c4e1acd6a7f84fcf(get_wrapped_blocks_(), n_cols_currently_showing_())),
|
|
1318
1322
|
trailing_: product_count => $d92f338ba8f9da9b$export$b94605e5b3ce01c({
|
|
1319
1323
|
...remapped_(),
|
|
1320
1324
|
n_cols_currently_showing_: n_cols_currently_showing_(),
|
|
@@ -1322,6 +1326,24 @@ function $d92f338ba8f9da9b$export$791ef57e62e21c3f({
|
|
|
1322
1326
|
})
|
|
1323
1327
|
});
|
|
1324
1328
|
}
|
|
1329
|
+
function $d92f338ba8f9da9b$export$c4e1acd6a7f84fcf(blocks, n_cols) {
|
|
1330
|
+
const styles = [];
|
|
1331
|
+
if (!n_cols) return styles;
|
|
1332
|
+
let last_row = 0;
|
|
1333
|
+
blocks.forEach((block, row) => {
|
|
1334
|
+
if (!block || block.span_rows <= 1 || block.span_columns >= n_cols) return;
|
|
1335
|
+
last_row = Math.max(last_row, row + block.span_rows);
|
|
1336
|
+
// Give product rows equal heights. Full-width cards keep their own height.
|
|
1337
|
+
const tracks = Array.from({
|
|
1338
|
+
length: last_row
|
|
1339
|
+
}, (_, index) => blocks[index]?.span_columns === n_cols ? "auto" : "1fr");
|
|
1340
|
+
styles.push({
|
|
1341
|
+
row: row,
|
|
1342
|
+
template: tracks.join(" ")
|
|
1343
|
+
});
|
|
1344
|
+
});
|
|
1345
|
+
return styles;
|
|
1346
|
+
}
|
|
1325
1347
|
function $d92f338ba8f9da9b$export$92aa5d691d588f3f({
|
|
1326
1348
|
wrapped_blocks_: wrapped_blocks_,
|
|
1327
1349
|
n_cols_currently_showing_: n_cols_currently_showing_
|
|
@@ -1441,11 +1463,12 @@ function $d92f338ba8f9da9b$export$911278b0390ae36e(block, max_span_columns) {
|
|
|
1441
1463
|
return {
|
|
1442
1464
|
span_columns: span_columns,
|
|
1443
1465
|
span_rows: spans_whole_row ? 1 : block.span_rows,
|
|
1444
|
-
spans_whole_row: spans_whole_row
|
|
1466
|
+
spans_whole_row: spans_whole_row,
|
|
1467
|
+
spans_multiple_rows: !spans_whole_row && block.span_rows > 1
|
|
1445
1468
|
};
|
|
1446
1469
|
}
|
|
1447
1470
|
function $d92f338ba8f9da9b$var$wrap_blocks_in_div(rendered_content_blocks, max_span_columns) {
|
|
1448
|
-
const get_wrapped_blocks = $5vyXB$solidjs.mapArray(() => rendered_content_blocks, block => {
|
|
1471
|
+
const get_wrapped_blocks = $5vyXB$solidjs.mapArray(() => rendered_content_blocks, (block, row) => {
|
|
1449
1472
|
if (!block) return;
|
|
1450
1473
|
const final_spans = $5vyXB$solidjs.createMemo(() => $d92f338ba8f9da9b$export$911278b0390ae36e(block, max_span_columns()));
|
|
1451
1474
|
const final_span_columns = $5vyXB$solidjs.createMemo(() => final_spans().span_columns);
|
|
@@ -1456,7 +1479,7 @@ function $d92f338ba8f9da9b$var$wrap_blocks_in_div(rendered_content_blocks, max_s
|
|
|
1456
1479
|
return !rendering_delayed();
|
|
1457
1480
|
},
|
|
1458
1481
|
get children() {
|
|
1459
|
-
return $5vyXB$solidjsweb.ssr($d92f338ba8f9da9b$var$_tmpl$, $5vyXB$solidjsweb.ssrHydrationKey(), `content-block-wrapper ${final_spans().spans_whole_row ? "spans-whole-row" : ""}`, "grid-column:" + `span ${$5vyXB$solidjsweb.escape(final_span_columns(), true)}` + (";grid-row:" + `span ${$5vyXB$solidjsweb.escape(final_span_rows(), true)}`) + (";spans_columns_variable_name:" + $5vyXB$solidjsweb.escape(final_span_columns(), true)), $5vyXB$solidjsweb.escape($5vyXB$solidjsweb.createComponent($d92f338ba8f9da9b$var$RenderContent, {
|
|
1482
|
+
return $5vyXB$solidjsweb.ssr($d92f338ba8f9da9b$var$_tmpl$, $5vyXB$solidjsweb.ssrHydrationKey(), `content-block-wrapper ${final_spans().spans_whole_row ? "spans-whole-row" : ""} ${final_spans().spans_multiple_rows ? "spans-multiple-rows" : ""}`, $5vyXB$solidjsweb.ssrAttribute("data-content-block-row", $5vyXB$solidjsweb.escape(row(), true), false), "grid-column:" + `span ${$5vyXB$solidjsweb.escape(final_span_columns(), true)}` + (";grid-row:" + `span ${$5vyXB$solidjsweb.escape(final_span_rows(), true)}`) + (";spans_columns_variable_name:" + $5vyXB$solidjsweb.escape(final_span_columns(), true)), $5vyXB$solidjsweb.escape($5vyXB$solidjsweb.createComponent($d92f338ba8f9da9b$var$RenderContent, {
|
|
1460
1483
|
get content() {
|
|
1461
1484
|
return block.content;
|
|
1462
1485
|
}
|
|
@@ -1676,6 +1699,10 @@ function $fe76fb463cc60b89$export$3925f87b1545cfc6({
|
|
|
1676
1699
|
cols_at_size_: modified_cols_at_size,
|
|
1677
1700
|
set_top_row_shortened_by_: set_top_row_shortened_by_
|
|
1678
1701
|
}));
|
|
1702
|
+
const content_block_row_styles = $5vyXB$solidjs.createMemo(() => {
|
|
1703
|
+
const blocks = content_blocks_();
|
|
1704
|
+
return "row_styles_" in blocks ? blocks.row_styles_() : [];
|
|
1705
|
+
});
|
|
1679
1706
|
const rendered_placeholders = $5vyXB$solidjs.createMemo(() => {
|
|
1680
1707
|
if (get_should_have_placeholders_rendered()) return $0caf87eaa19079da$export$f33414a4df0afd3f({
|
|
1681
1708
|
content_blocks_: content_blocks_,
|
|
@@ -1775,6 +1802,9 @@ function $fe76fb463cc60b89$export$3925f87b1545cfc6({
|
|
|
1775
1802
|
class: "cards css-grid"
|
|
1776
1803
|
},
|
|
1777
1804
|
top_row_shortened_by_: top_row_shortened_by_,
|
|
1805
|
+
get content_block_row_styles() {
|
|
1806
|
+
return content_block_row_styles();
|
|
1807
|
+
},
|
|
1778
1808
|
children: listing_contents
|
|
1779
1809
|
});
|
|
1780
1810
|
},
|
|
@@ -6116,7 +6146,7 @@ function $3ea8e0af95b5b7d2$export$2972b890694ced75(callback, {
|
|
|
6116
6146
|
};
|
|
6117
6147
|
const idleHandle = requestIdleCallback(deadline => {
|
|
6118
6148
|
cancel();
|
|
6119
|
-
return callback(deadline);
|
|
6149
|
+
return callback(typeof deadline?.timeRemaining === "function" ? deadline : $3ea8e0af95b5b7d2$var$makeDeadline());
|
|
6120
6150
|
}, {
|
|
6121
6151
|
timeout: timeout
|
|
6122
6152
|
});
|
|
@@ -6133,6 +6163,18 @@ function $3ea8e0af95b5b7d2$export$2972b890694ced75(callback, {
|
|
|
6133
6163
|
}, timeout + 1000);
|
|
6134
6164
|
return cancel;
|
|
6135
6165
|
}
|
|
6166
|
+
/**
|
|
6167
|
+
* Stand-in for a missing IdleDeadline: 50ms, the most a real one gives, counting down from when the callback was called
|
|
6168
|
+
*/
|
|
6169
|
+
function $3ea8e0af95b5b7d2$var$makeDeadline() {
|
|
6170
|
+
const start = performance.now();
|
|
6171
|
+
return {
|
|
6172
|
+
didTimeout: false,
|
|
6173
|
+
timeRemaining() {
|
|
6174
|
+
return Math.max(0, 50 - (performance.now() - start));
|
|
6175
|
+
}
|
|
6176
|
+
};
|
|
6177
|
+
}
|
|
6136
6178
|
function $7ea61486b66872b6$export$566cd7e46bad5c2d(callback) {
|
|
6137
6179
|
const page_hasnt_loaded =
|
|
6138
6180
|
// @ts-ignore
|
package/server/latest/index.d.ts
CHANGED
|
@@ -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.
|
|
14
|
+
export const version = "4.10.26";
|
|
15
15
|
/**
|
|
16
16
|
* Use `javascript_media_query` but return a reactive accessor instead of taking a callback function
|
|
17
17
|
*/
|
package/server/latest/index.js
CHANGED
|
@@ -7,7 +7,7 @@ import { createStore as $i7OB2$createStore, reconcile as $i7OB2$reconcile } from
|
|
|
7
7
|
/*! Depict.ai search and product listing SDK */
|
|
8
8
|
import { register_es_version } from "../../multi_import_deduplicator.mjs";
|
|
9
9
|
register_es_version("ui", "latest");
|
|
10
|
-
const $ec291e0010116877$export$83d89fbfd8236492 = "4.10.
|
|
10
|
+
const $ec291e0010116877$export$83d89fbfd8236492 = "4.10.26";
|
|
11
11
|
function $dc9262ef6f786812$export$d9f36cf74e24d595(media_query) {
|
|
12
12
|
const signal = $i7OB2$createSignal(false);
|
|
13
13
|
$i7OB2$onCleanup($i7OB2$javascript_media_query(media_query, ({
|
|
@@ -1051,7 +1051,10 @@ function $6dee9211e57ac31a$export$e2f22da34aaf310a(props, container_element, ins
|
|
|
1051
1051
|
const base_styling = $i7OB2$createMemo(() => {
|
|
1052
1052
|
return `${container_selector}{display:grid;}`;
|
|
1053
1053
|
});
|
|
1054
|
-
const get_styling = $i7OB2$createMemo(() => base_styling() + col_styling())
|
|
1054
|
+
const get_styling = $i7OB2$createMemo(() => base_styling() + col_styling() + (props.content_block_row_styles || []).map(({
|
|
1055
|
+
row: row,
|
|
1056
|
+
template: template
|
|
1057
|
+
}) => `${container_selector}:has(>.content-block-wrapper.spans-multiple-rows[data-content-block-row="${row}"]){grid-template-rows:${template};}`).join(""));
|
|
1055
1058
|
const style_element = $i7OB2$ssr($6dee9211e57ac31a$var$_tmpl$, $i7OB2$ssrHydrationKey(), get_styling); // need to create this after set_styling has been called or else there will be no styling in the SSR'd output
|
|
1056
1059
|
if (insert_after_container) container_element.after(style_element);
|
|
1057
1060
|
return [container_element, style_element];
|
|
@@ -1174,7 +1177,7 @@ function $7f60f09116a3fe61$export$3f37af283f8fb843(props) {
|
|
|
1174
1177
|
}
|
|
1175
1178
|
});
|
|
1176
1179
|
}
|
|
1177
|
-
var $e7a7eb102ddc0c79$var$_tmpl$ = ["<div", ' class="', '" style="', '">', "</div>"];
|
|
1180
|
+
var $e7a7eb102ddc0c79$var$_tmpl$ = ["<div", ' class="', '"', ' style="', '">', "</div>"];
|
|
1178
1181
|
function $e7a7eb102ddc0c79$export$791ef57e62e21c3f({
|
|
1179
1182
|
content_blocks_: incoming_content_blocks,
|
|
1180
1183
|
cols_at_size_: cols_at_size_,
|
|
@@ -1213,6 +1216,7 @@ function $e7a7eb102ddc0c79$export$791ef57e62e21c3f({
|
|
|
1213
1216
|
}));
|
|
1214
1217
|
const content_blocks_by_index_ = $i7OB2$createMemo(() => remapped_().content_blocks_by_index_);
|
|
1215
1218
|
return Object.assign(content_blocks_by_index_, {
|
|
1219
|
+
row_styles_: $i7OB2$createMemo(() => $e7a7eb102ddc0c79$export$c4e1acd6a7f84fcf(get_wrapped_blocks_(), n_cols_currently_showing_())),
|
|
1216
1220
|
trailing_: product_count => $e7a7eb102ddc0c79$export$b94605e5b3ce01c({
|
|
1217
1221
|
...remapped_(),
|
|
1218
1222
|
n_cols_currently_showing_: n_cols_currently_showing_(),
|
|
@@ -1220,6 +1224,24 @@ function $e7a7eb102ddc0c79$export$791ef57e62e21c3f({
|
|
|
1220
1224
|
})
|
|
1221
1225
|
});
|
|
1222
1226
|
}
|
|
1227
|
+
function $e7a7eb102ddc0c79$export$c4e1acd6a7f84fcf(blocks, n_cols) {
|
|
1228
|
+
const styles = [];
|
|
1229
|
+
if (!n_cols) return styles;
|
|
1230
|
+
let last_row = 0;
|
|
1231
|
+
blocks.forEach((block, row) => {
|
|
1232
|
+
if (!block || block.span_rows <= 1 || block.span_columns >= n_cols) return;
|
|
1233
|
+
last_row = Math.max(last_row, row + block.span_rows);
|
|
1234
|
+
// Give product rows equal heights. Full-width cards keep their own height.
|
|
1235
|
+
const tracks = Array.from({
|
|
1236
|
+
length: last_row
|
|
1237
|
+
}, (_, index) => blocks[index]?.span_columns === n_cols ? "auto" : "1fr");
|
|
1238
|
+
styles.push({
|
|
1239
|
+
row: row,
|
|
1240
|
+
template: tracks.join(" ")
|
|
1241
|
+
});
|
|
1242
|
+
});
|
|
1243
|
+
return styles;
|
|
1244
|
+
}
|
|
1223
1245
|
function $e7a7eb102ddc0c79$export$92aa5d691d588f3f({
|
|
1224
1246
|
wrapped_blocks_: wrapped_blocks_,
|
|
1225
1247
|
n_cols_currently_showing_: n_cols_currently_showing_
|
|
@@ -1339,11 +1361,12 @@ function $e7a7eb102ddc0c79$export$911278b0390ae36e(block, max_span_columns) {
|
|
|
1339
1361
|
return {
|
|
1340
1362
|
span_columns: span_columns,
|
|
1341
1363
|
span_rows: spans_whole_row ? 1 : block.span_rows,
|
|
1342
|
-
spans_whole_row: spans_whole_row
|
|
1364
|
+
spans_whole_row: spans_whole_row,
|
|
1365
|
+
spans_multiple_rows: !spans_whole_row && block.span_rows > 1
|
|
1343
1366
|
};
|
|
1344
1367
|
}
|
|
1345
1368
|
function $e7a7eb102ddc0c79$var$wrap_blocks_in_div(rendered_content_blocks, max_span_columns) {
|
|
1346
|
-
const get_wrapped_blocks = $i7OB2$mapArray(() => rendered_content_blocks, block => {
|
|
1369
|
+
const get_wrapped_blocks = $i7OB2$mapArray(() => rendered_content_blocks, (block, row) => {
|
|
1347
1370
|
if (!block) return;
|
|
1348
1371
|
const final_spans = $i7OB2$createMemo(() => $e7a7eb102ddc0c79$export$911278b0390ae36e(block, max_span_columns()));
|
|
1349
1372
|
const final_span_columns = $i7OB2$createMemo(() => final_spans().span_columns);
|
|
@@ -1354,7 +1377,7 @@ function $e7a7eb102ddc0c79$var$wrap_blocks_in_div(rendered_content_blocks, max_s
|
|
|
1354
1377
|
return !rendering_delayed();
|
|
1355
1378
|
},
|
|
1356
1379
|
get children() {
|
|
1357
|
-
return $i7OB2$ssr($e7a7eb102ddc0c79$var$_tmpl$, $i7OB2$ssrHydrationKey(), `content-block-wrapper ${final_spans().spans_whole_row ? "spans-whole-row" : ""}`, "grid-column:" + `span ${$i7OB2$escape(final_span_columns(), true)}` + (";grid-row:" + `span ${$i7OB2$escape(final_span_rows(), true)}`) + (";spans_columns_variable_name:" + $i7OB2$escape(final_span_columns(), true)), $i7OB2$escape($i7OB2$createComponent($e7a7eb102ddc0c79$var$RenderContent, {
|
|
1380
|
+
return $i7OB2$ssr($e7a7eb102ddc0c79$var$_tmpl$, $i7OB2$ssrHydrationKey(), `content-block-wrapper ${final_spans().spans_whole_row ? "spans-whole-row" : ""} ${final_spans().spans_multiple_rows ? "spans-multiple-rows" : ""}`, $i7OB2$ssrAttribute("data-content-block-row", $i7OB2$escape(row(), true), false), "grid-column:" + `span ${$i7OB2$escape(final_span_columns(), true)}` + (";grid-row:" + `span ${$i7OB2$escape(final_span_rows(), true)}`) + (";spans_columns_variable_name:" + $i7OB2$escape(final_span_columns(), true)), $i7OB2$escape($i7OB2$createComponent($e7a7eb102ddc0c79$var$RenderContent, {
|
|
1358
1381
|
get content() {
|
|
1359
1382
|
return block.content;
|
|
1360
1383
|
}
|
|
@@ -1574,6 +1597,10 @@ function $2d25e42846eac370$export$3925f87b1545cfc6({
|
|
|
1574
1597
|
cols_at_size_: modified_cols_at_size,
|
|
1575
1598
|
set_top_row_shortened_by_: set_top_row_shortened_by_
|
|
1576
1599
|
}));
|
|
1600
|
+
const content_block_row_styles = $i7OB2$createMemo(() => {
|
|
1601
|
+
const blocks = content_blocks_();
|
|
1602
|
+
return "row_styles_" in blocks ? blocks.row_styles_() : [];
|
|
1603
|
+
});
|
|
1577
1604
|
const rendered_placeholders = $i7OB2$createMemo(() => {
|
|
1578
1605
|
if (get_should_have_placeholders_rendered()) return $6e41f1fde994db72$export$f33414a4df0afd3f({
|
|
1579
1606
|
content_blocks_: content_blocks_,
|
|
@@ -1673,6 +1700,9 @@ function $2d25e42846eac370$export$3925f87b1545cfc6({
|
|
|
1673
1700
|
class: "cards css-grid"
|
|
1674
1701
|
},
|
|
1675
1702
|
top_row_shortened_by_: top_row_shortened_by_,
|
|
1703
|
+
get content_block_row_styles() {
|
|
1704
|
+
return content_block_row_styles();
|
|
1705
|
+
},
|
|
1676
1706
|
children: listing_contents
|
|
1677
1707
|
});
|
|
1678
1708
|
},
|
|
@@ -6014,7 +6044,7 @@ function $4ea56971d92eb0cd$export$2972b890694ced75(callback, {
|
|
|
6014
6044
|
};
|
|
6015
6045
|
const idleHandle = requestIdleCallback(deadline => {
|
|
6016
6046
|
cancel();
|
|
6017
|
-
return callback(deadline);
|
|
6047
|
+
return callback(typeof deadline?.timeRemaining === "function" ? deadline : $4ea56971d92eb0cd$var$makeDeadline());
|
|
6018
6048
|
}, {
|
|
6019
6049
|
timeout: timeout
|
|
6020
6050
|
});
|
|
@@ -6031,6 +6061,18 @@ function $4ea56971d92eb0cd$export$2972b890694ced75(callback, {
|
|
|
6031
6061
|
}, timeout + 1000);
|
|
6032
6062
|
return cancel;
|
|
6033
6063
|
}
|
|
6064
|
+
/**
|
|
6065
|
+
* Stand-in for a missing IdleDeadline: 50ms, the most a real one gives, counting down from when the callback was called
|
|
6066
|
+
*/
|
|
6067
|
+
function $4ea56971d92eb0cd$var$makeDeadline() {
|
|
6068
|
+
const start = performance.now();
|
|
6069
|
+
return {
|
|
6070
|
+
didTimeout: false,
|
|
6071
|
+
timeRemaining() {
|
|
6072
|
+
return Math.max(0, 50 - (performance.now() - start));
|
|
6073
|
+
}
|
|
6074
|
+
};
|
|
6075
|
+
}
|
|
6034
6076
|
function $f71681eb5d5aae0a$export$566cd7e46bad5c2d(callback) {
|
|
6035
6077
|
const page_hasnt_loaded =
|
|
6036
6078
|
// @ts-ignore
|