@depict-ai/ui 4.3.12 → 4.3.14

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 CHANGED
@@ -100,7 +100,7 @@ $parcel$export(module.exports, "BreadCrumbs", () => $335c02c1241a9ca8$export$5b7
100
100
  $parcel$export(module.exports, "QuickLinks", () => $335c02c1241a9ca8$export$de035477d6fef996);
101
101
  $parcel$export(module.exports, "CategoryPage", () => $c10e33c4681f8c9b$export$e2bf8ce7779e827e);
102
102
  /*! Depict.ai search and product listing SDK */
103
- const $aa1938dec50d6c12$export$83d89fbfd8236492 = "4.3.12";
103
+ const $aa1938dec50d6c12$export$83d89fbfd8236492 = "4.3.14";
104
104
  const $5401a6698b0c0658$var$transform_elements = sorted_cols_at_size => {
105
105
  const cols_at_size = [];
106
106
  for (let i = 0; i < sorted_cols_at_size.length; i++) {
@@ -1420,9 +1420,9 @@ function $d66c35b5a6d6d926$export$b73ed90f0ee50dc3(_ref) {
1420
1420
  is_replace_: false,
1421
1421
  event_: event_
1422
1422
  });
1423
- if (event_.defaultPrevented)
1424
- // We single-page-navigated in this tab, close the look
1425
- setUserWantsExpanded(false);
1423
+ if (!event_.defaultPrevented)
1424
+ // If the user opened in a new tab, prevent the event from propagating to the parent which would close the look
1425
+ event_.stopImmediatePropagation();
1426
1426
  }
1427
1427
  });
1428
1428
  }
@@ -1783,9 +1783,7 @@ function $47e3c3102c78121b$export$44809a8a3e867e30(_ref) {
1783
1783
  let {
1784
1784
  target: target
1785
1785
  } = _ref2;
1786
- // Don't toggle when clicking on the links
1787
- if (target.matches("a") || target.closest("a")) return;
1788
- setUserWantsExpanded(prev => !prev);
1786
+ return setUserWantsExpanded(prev => !prev);
1789
1787
  }), true);
1790
1788
  _el$.classList.toggle("placeholder", !!!display_);
1791
1789
  $52FdA$solidjsweb.runHydrationEvents();
@@ -9388,19 +9386,21 @@ function $a162c9a08dc208c2$export$b288c38ae3fddb56(_ref) {
9388
9386
  // can't or shouldn't be merged due to not being selected, just take remote one
9389
9387
  new_local_filter_state.push(remote_filter);else {
9390
9388
  const data_objs_in_remote = Object.fromEntries(remote_meta.values.map((value, index) => {
9391
- var _remote_meta$counts, _remote_meta$names;
9389
+ var _remote_meta$counts, _remote_meta$names, _swatches;
9392
9390
  return [JSON.stringify(value), {
9393
9391
  value_: value,
9394
9392
  count_: (_remote_meta$counts = remote_meta.counts) === null || _remote_meta$counts === void 0 ? void 0 : _remote_meta$counts[index],
9395
- name_: (_remote_meta$names = remote_meta.names) === null || _remote_meta$names === void 0 ? void 0 : _remote_meta$names[index]
9393
+ name_: (_remote_meta$names = remote_meta.names) === null || _remote_meta$names === void 0 ? void 0 : _remote_meta$names[index],
9394
+ swatches_: (_swatches = remote_meta.swatches) === null || _swatches === void 0 ? void 0 : _swatches[index]
9396
9395
  }];
9397
9396
  }));
9398
9397
  const data_objs_in_local = Object.fromEntries(local_meta.values.map((value, index) => {
9399
- var _local_meta$names;
9398
+ var _local_meta$names, _swatches2;
9400
9399
  return [JSON.stringify(value), {
9401
9400
  value_: value,
9402
9401
  count_: 0,
9403
- name_: (_local_meta$names = local_meta.names) === null || _local_meta$names === void 0 ? void 0 : _local_meta$names[index]
9402
+ name_: (_local_meta$names = local_meta.names) === null || _local_meta$names === void 0 ? void 0 : _local_meta$names[index],
9403
+ swatches_: (_swatches2 = local_meta.swatches) === null || _swatches2 === void 0 ? void 0 : _swatches2[index]
9404
9404
  }];
9405
9405
  }));
9406
9406
  const new_data = [...Object.keys(data_objs_in_local).filter(key => {
@@ -9445,6 +9445,14 @@ function $a162c9a08dc208c2$export$b288c38ae3fddb56(_ref) {
9445
9445
  count_: count_
9446
9446
  } = _ref4;
9447
9447
  return count_;
9448
+ }),
9449
+ ...("swatches" in remote_filter && {
9450
+ swatches: new_data.map(_ref5 => {
9451
+ let {
9452
+ swatches_: swatches_
9453
+ } = _ref5;
9454
+ return swatches_;
9455
+ })
9448
9456
  })
9449
9457
  }
9450
9458
  };
@@ -9494,6 +9502,10 @@ function $a162c9a08dc208c2$var$modify_only_local_filter(local_filter_object, sel
9494
9502
  }
9495
9503
  new_meta.values = values.filter((_, index) => !indexes_to_remove.has(index));
9496
9504
  if (new_meta.names) new_meta.names = new_meta.names.filter((_, index) => !indexes_to_remove.has(index));
9505
+ if ("swatches" in new_meta) {
9506
+ var _new_meta$swatches;
9507
+ new_meta.swatches = (_new_meta$swatches = new_meta.swatches) === null || _new_meta$swatches === void 0 ? void 0 : _new_meta$swatches.filter((_, index) => !indexes_to_remove.has(index));
9508
+ }
9497
9509
  if (new_meta.counts)
9498
9510
  // remove counts that are too much, they're all zero anyway if they exist
9499
9511
  new_meta.counts.length -= indexes_to_remove.size;
package/ES10/index.d.ts CHANGED
@@ -10,7 +10,7 @@ import { ProductListingRequestV3 } from "@depict-ai/types/api/ProductListingRequ
10
10
  import { GetListingRequest } from "@depict-ai/types/api/GetListingRequest";
11
11
  import { BaseSearchRequestV3 } from "@depict-ai/types/api/BaseSearchRequestV3";
12
12
  import { SearchFilter as _SearchFilter3 } from "@depict-ai/types/api/SearchRequestV2";
13
- export const version = "4.3.12";
13
+ export const version = "4.3.14";
14
14
  declare const LISTING_ID = "listingId";
15
15
  declare const EXTERNAL_ID = "externalId";
16
16
  type ScrollRestorationData = {
@@ -1399,7 +1399,7 @@ type OpenModalParams<OriginalDisplay extends Display, OutputDisplay extends Mode
1399
1399
  * Open the modal with support for alignment.
1400
1400
  * @returns {void}
1401
1401
  */
1402
- export const open_modal_with_alignment: <OriginalDisplay extends Display, OutputDisplay extends ModernDisplay>(openModalParams: OpenModalParams<OriginalDisplay, OutputDisplay>) => void;
1402
+ export const open_modal_with_alignment: <OriginalDisplay extends Display, OutputDisplay extends unknown>(openModalParams: OpenModalParams<OriginalDisplay, OutputDisplay>) => void;
1403
1403
  export function open_search_with_shift_slash(open_search: VoidFunction): () => void;
1404
1404
  export interface PageReplacer {
1405
1405
  readonly render_: () => Node_Array;
@@ -1477,5 +1477,5 @@ export function CategoryPage<OriginalDisplay extends Display, OutputDisplay exte
1477
1477
  content_blocks_by_row?: ContentBlocksByRow;
1478
1478
  layout?: PossibleLayout;
1479
1479
  filterModalParent_?: HTMLElement | ShadowRoot;
1480
- }): import("@depict-ai/utilishared/latest").Node_Array;
1480
+ }): import("@depict-ai/utilishared").Node_Array;
1481
1481
  export type { SearchFilter } from "@depict-ai/types/api/SearchRequestV3";
package/ES10/index.js CHANGED
@@ -10,7 +10,7 @@ import { createStore as $8tj43$createStore, reconcile as $8tj43$reconcile } from
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.3.12";
13
+ const $8db9a15135765c11$export$83d89fbfd8236492 = "4.3.14";
14
14
  const $a9c7ba6087881ac2$var$transform_elements = sorted_cols_at_size => {
15
15
  const cols_at_size = [];
16
16
  for (let i = 0; i < sorted_cols_at_size.length; i++) {
@@ -1330,9 +1330,9 @@ function $0c5b1686f971e5e7$export$b73ed90f0ee50dc3(_ref) {
1330
1330
  is_replace_: false,
1331
1331
  event_: event_
1332
1332
  });
1333
- if (event_.defaultPrevented)
1334
- // We single-page-navigated in this tab, close the look
1335
- setUserWantsExpanded(false);
1333
+ if (!event_.defaultPrevented)
1334
+ // If the user opened in a new tab, prevent the event from propagating to the parent which would close the look
1335
+ event_.stopImmediatePropagation();
1336
1336
  }
1337
1337
  });
1338
1338
  }
@@ -1693,9 +1693,7 @@ function $697d8713dc82b9ab$export$44809a8a3e867e30(_ref) {
1693
1693
  let {
1694
1694
  target: target
1695
1695
  } = _ref2;
1696
- // Don't toggle when clicking on the links
1697
- if (target.matches("a") || target.closest("a")) return;
1698
- setUserWantsExpanded(prev => !prev);
1696
+ return setUserWantsExpanded(prev => !prev);
1699
1697
  }), true);
1700
1698
  _el$.classList.toggle("placeholder", !!!display_);
1701
1699
  $8tj43$runHydrationEvents();
@@ -9298,19 +9296,21 @@ function $44aa24b1bb793549$export$b288c38ae3fddb56(_ref) {
9298
9296
  // can't or shouldn't be merged due to not being selected, just take remote one
9299
9297
  new_local_filter_state.push(remote_filter);else {
9300
9298
  const data_objs_in_remote = Object.fromEntries(remote_meta.values.map((value, index) => {
9301
- var _remote_meta$counts, _remote_meta$names;
9299
+ var _remote_meta$counts, _remote_meta$names, _swatches;
9302
9300
  return [JSON.stringify(value), {
9303
9301
  value_: value,
9304
9302
  count_: (_remote_meta$counts = remote_meta.counts) === null || _remote_meta$counts === void 0 ? void 0 : _remote_meta$counts[index],
9305
- name_: (_remote_meta$names = remote_meta.names) === null || _remote_meta$names === void 0 ? void 0 : _remote_meta$names[index]
9303
+ name_: (_remote_meta$names = remote_meta.names) === null || _remote_meta$names === void 0 ? void 0 : _remote_meta$names[index],
9304
+ swatches_: (_swatches = remote_meta.swatches) === null || _swatches === void 0 ? void 0 : _swatches[index]
9306
9305
  }];
9307
9306
  }));
9308
9307
  const data_objs_in_local = Object.fromEntries(local_meta.values.map((value, index) => {
9309
- var _local_meta$names;
9308
+ var _local_meta$names, _swatches2;
9310
9309
  return [JSON.stringify(value), {
9311
9310
  value_: value,
9312
9311
  count_: 0,
9313
- name_: (_local_meta$names = local_meta.names) === null || _local_meta$names === void 0 ? void 0 : _local_meta$names[index]
9312
+ name_: (_local_meta$names = local_meta.names) === null || _local_meta$names === void 0 ? void 0 : _local_meta$names[index],
9313
+ swatches_: (_swatches2 = local_meta.swatches) === null || _swatches2 === void 0 ? void 0 : _swatches2[index]
9314
9314
  }];
9315
9315
  }));
9316
9316
  const new_data = [...Object.keys(data_objs_in_local).filter(key => {
@@ -9355,6 +9355,14 @@ function $44aa24b1bb793549$export$b288c38ae3fddb56(_ref) {
9355
9355
  count_: count_
9356
9356
  } = _ref4;
9357
9357
  return count_;
9358
+ }),
9359
+ ...("swatches" in remote_filter && {
9360
+ swatches: new_data.map(_ref5 => {
9361
+ let {
9362
+ swatches_: swatches_
9363
+ } = _ref5;
9364
+ return swatches_;
9365
+ })
9358
9366
  })
9359
9367
  }
9360
9368
  };
@@ -9404,6 +9412,10 @@ function $44aa24b1bb793549$var$modify_only_local_filter(local_filter_object, sel
9404
9412
  }
9405
9413
  new_meta.values = values.filter((_, index) => !indexes_to_remove.has(index));
9406
9414
  if (new_meta.names) new_meta.names = new_meta.names.filter((_, index) => !indexes_to_remove.has(index));
9415
+ if ("swatches" in new_meta) {
9416
+ var _new_meta$swatches;
9417
+ new_meta.swatches = (_new_meta$swatches = new_meta.swatches) === null || _new_meta$swatches === void 0 ? void 0 : _new_meta$swatches.filter((_, index) => !indexes_to_remove.has(index));
9418
+ }
9407
9419
  if (new_meta.counts)
9408
9420
  // remove counts that are too much, they're all zero anyway if they exist
9409
9421
  new_meta.counts.length -= indexes_to_remove.size;
package/latest/index.cjs CHANGED
@@ -94,7 +94,7 @@ $parcel$export(module.exports, "BreadCrumbs", () => $1f4925833f07df29$export$5b7
94
94
  $parcel$export(module.exports, "QuickLinks", () => $1f4925833f07df29$export$de035477d6fef996);
95
95
  $parcel$export(module.exports, "CategoryPage", () => $14f289047713d67a$export$e2bf8ce7779e827e);
96
96
  /*! Depict.ai search and product listing SDK */
97
- const $b757f75811f3261f$export$83d89fbfd8236492 = "4.3.12";
97
+ const $b757f75811f3261f$export$83d89fbfd8236492 = "4.3.14";
98
98
  const $4e04be41243c3d80$var$transform_elements = sorted_cols_at_size => {
99
99
  const cols_at_size = [];
100
100
  for (let i = 0; i < sorted_cols_at_size.length; i++) {
@@ -1339,9 +1339,9 @@ function $1ae437d7d388a66e$export$b73ed90f0ee50dc3({
1339
1339
  is_replace_: false,
1340
1340
  event_: event_
1341
1341
  });
1342
- if (event_.defaultPrevented)
1343
- // We single-page-navigated in this tab, close the look
1344
- setUserWantsExpanded(false);
1342
+ if (!event_.defaultPrevented)
1343
+ // If the user opened in a new tab, prevent the event from propagating to the parent which would close the look
1344
+ event_.stopImmediatePropagation();
1345
1345
  }
1346
1346
  });
1347
1347
  }
@@ -1694,11 +1694,7 @@ function $ad882bbe664dbd53$export$44809a8a3e867e30({
1694
1694
  var _el$ = $gVhhF$solidjsweb.getNextElement($ad882bbe664dbd53$var$_tmpl$);
1695
1695
  $gVhhF$solidjsweb.addEventListener(_el$, "click", $gVhhF$depictaiutilishared.catchify(({
1696
1696
  target: target
1697
- }) => {
1698
- // Don't toggle when clicking on the links
1699
- if (target.matches("a") || target.closest("a")) return;
1700
- setUserWantsExpanded(prev => !prev);
1701
- }), true);
1697
+ }) => setUserWantsExpanded(prev => !prev)), true);
1702
1698
  _el$.classList.toggle("placeholder", !!!display_);
1703
1699
  $gVhhF$solidjsweb.runHydrationEvents();
1704
1700
  return _el$;
@@ -8921,12 +8917,14 @@ function $70482f04605572e2$export$b288c38ae3fddb56({
8921
8917
  const data_objs_in_remote = Object.fromEntries(remote_meta.values.map((value, index) => [JSON.stringify(value), {
8922
8918
  value_: value,
8923
8919
  count_: remote_meta.counts?.[index],
8924
- name_: remote_meta.names?.[index]
8920
+ name_: remote_meta.names?.[index],
8921
+ swatches_: remote_meta.swatches?.[index]
8925
8922
  }]));
8926
8923
  const data_objs_in_local = Object.fromEntries(local_meta.values.map((value, index) => [JSON.stringify(value), {
8927
8924
  value_: value,
8928
8925
  count_: 0,
8929
- name_: local_meta.names?.[index]
8926
+ name_: local_meta.names?.[index],
8927
+ swatches_: local_meta.swatches?.[index]
8930
8928
  }]));
8931
8929
  const new_data = [...Object.keys(data_objs_in_local).filter(key => {
8932
8930
  // put data entries that are selected and don't exist in new remote state first
@@ -8961,7 +8959,12 @@ function $70482f04605572e2$export$b288c38ae3fddb56({
8961
8959
  }) => name_),
8962
8960
  counts: new_data.map(({
8963
8961
  count_: count_
8964
- }) => count_)
8962
+ }) => count_),
8963
+ ...("swatches" in remote_filter && {
8964
+ swatches: new_data.map(({
8965
+ swatches_: swatches_
8966
+ }) => swatches_)
8967
+ })
8965
8968
  }
8966
8969
  };
8967
8970
  new_local_filter_state.push(result);
@@ -9010,6 +9013,7 @@ function $70482f04605572e2$var$modify_only_local_filter(local_filter_object, sel
9010
9013
  }
9011
9014
  new_meta.values = values.filter((_, index) => !indexes_to_remove.has(index));
9012
9015
  if (new_meta.names) new_meta.names = new_meta.names.filter((_, index) => !indexes_to_remove.has(index));
9016
+ if ("swatches" in new_meta) new_meta.swatches = new_meta.swatches?.filter((_, index) => !indexes_to_remove.has(index));
9013
9017
  if (new_meta.counts)
9014
9018
  // remove counts that are too much, they're all zero anyway if they exist
9015
9019
  new_meta.counts.length -= indexes_to_remove.size;
package/latest/index.d.ts CHANGED
@@ -10,7 +10,7 @@ import { ProductListingRequestV3 } from "@depict-ai/types/api/ProductListingRequ
10
10
  import { GetListingRequest } from "@depict-ai/types/api/GetListingRequest";
11
11
  import { BaseSearchRequestV3 } from "@depict-ai/types/api/BaseSearchRequestV3";
12
12
  import { SearchFilter as _SearchFilter3 } from "@depict-ai/types/api/SearchRequestV2";
13
- export const version = "4.3.12";
13
+ export const version = "4.3.14";
14
14
  declare const LISTING_ID = "listingId";
15
15
  declare const EXTERNAL_ID = "externalId";
16
16
  type ScrollRestorationData = {
@@ -1399,7 +1399,7 @@ type OpenModalParams<OriginalDisplay extends Display, OutputDisplay extends Mode
1399
1399
  * Open the modal with support for alignment.
1400
1400
  * @returns {void}
1401
1401
  */
1402
- export const open_modal_with_alignment: <OriginalDisplay extends Display, OutputDisplay extends ModernDisplay>(openModalParams: OpenModalParams<OriginalDisplay, OutputDisplay>) => void;
1402
+ export const open_modal_with_alignment: <OriginalDisplay extends Display, OutputDisplay extends unknown>(openModalParams: OpenModalParams<OriginalDisplay, OutputDisplay>) => void;
1403
1403
  export function open_search_with_shift_slash(open_search: VoidFunction): () => void;
1404
1404
  export interface PageReplacer {
1405
1405
  readonly render_: () => Node_Array;
@@ -1477,5 +1477,5 @@ export function CategoryPage<OriginalDisplay extends Display, OutputDisplay exte
1477
1477
  content_blocks_by_row?: ContentBlocksByRow;
1478
1478
  layout?: PossibleLayout;
1479
1479
  filterModalParent_?: HTMLElement | ShadowRoot;
1480
- }): import("@depict-ai/utilishared/latest").Node_Array;
1480
+ }): import("@depict-ai/utilishared").Node_Array;
1481
1481
  export type { SearchFilter } from "@depict-ai/types/api/SearchRequestV3";
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.3.12";
10
+ const $ec291e0010116877$export$83d89fbfd8236492 = "4.3.14";
11
11
  const $b5cccc8ee7d24677$var$transform_elements = sorted_cols_at_size => {
12
12
  const cols_at_size = [];
13
13
  for (let i = 0; i < sorted_cols_at_size.length; i++) {
@@ -1252,9 +1252,9 @@ function $5a6c386e1bde5665$export$b73ed90f0ee50dc3({
1252
1252
  is_replace_: false,
1253
1253
  event_: event_
1254
1254
  });
1255
- if (event_.defaultPrevented)
1256
- // We single-page-navigated in this tab, close the look
1257
- setUserWantsExpanded(false);
1255
+ if (!event_.defaultPrevented)
1256
+ // If the user opened in a new tab, prevent the event from propagating to the parent which would close the look
1257
+ event_.stopImmediatePropagation();
1258
1258
  }
1259
1259
  });
1260
1260
  }
@@ -1607,11 +1607,7 @@ function $28ee4f7db3cc44b8$export$44809a8a3e867e30({
1607
1607
  var _el$ = $9HbP8$getNextElement($28ee4f7db3cc44b8$var$_tmpl$);
1608
1608
  $9HbP8$addEventListener(_el$, "click", $9HbP8$catchify(({
1609
1609
  target: target
1610
- }) => {
1611
- // Don't toggle when clicking on the links
1612
- if (target.matches("a") || target.closest("a")) return;
1613
- setUserWantsExpanded(prev => !prev);
1614
- }), true);
1610
+ }) => setUserWantsExpanded(prev => !prev)), true);
1615
1611
  _el$.classList.toggle("placeholder", !!!display_);
1616
1612
  $9HbP8$runHydrationEvents();
1617
1613
  return _el$;
@@ -8834,12 +8830,14 @@ function $5efb5894079b220e$export$b288c38ae3fddb56({
8834
8830
  const data_objs_in_remote = Object.fromEntries(remote_meta.values.map((value, index) => [JSON.stringify(value), {
8835
8831
  value_: value,
8836
8832
  count_: remote_meta.counts?.[index],
8837
- name_: remote_meta.names?.[index]
8833
+ name_: remote_meta.names?.[index],
8834
+ swatches_: remote_meta.swatches?.[index]
8838
8835
  }]));
8839
8836
  const data_objs_in_local = Object.fromEntries(local_meta.values.map((value, index) => [JSON.stringify(value), {
8840
8837
  value_: value,
8841
8838
  count_: 0,
8842
- name_: local_meta.names?.[index]
8839
+ name_: local_meta.names?.[index],
8840
+ swatches_: local_meta.swatches?.[index]
8843
8841
  }]));
8844
8842
  const new_data = [...Object.keys(data_objs_in_local).filter(key => {
8845
8843
  // put data entries that are selected and don't exist in new remote state first
@@ -8874,7 +8872,12 @@ function $5efb5894079b220e$export$b288c38ae3fddb56({
8874
8872
  }) => name_),
8875
8873
  counts: new_data.map(({
8876
8874
  count_: count_
8877
- }) => count_)
8875
+ }) => count_),
8876
+ ...("swatches" in remote_filter && {
8877
+ swatches: new_data.map(({
8878
+ swatches_: swatches_
8879
+ }) => swatches_)
8880
+ })
8878
8881
  }
8879
8882
  };
8880
8883
  new_local_filter_state.push(result);
@@ -8923,6 +8926,7 @@ function $5efb5894079b220e$var$modify_only_local_filter(local_filter_object, sel
8923
8926
  }
8924
8927
  new_meta.values = values.filter((_, index) => !indexes_to_remove.has(index));
8925
8928
  if (new_meta.names) new_meta.names = new_meta.names.filter((_, index) => !indexes_to_remove.has(index));
8929
+ if ("swatches" in new_meta) new_meta.swatches = new_meta.swatches?.filter((_, index) => !indexes_to_remove.has(index));
8926
8930
  if (new_meta.counts)
8927
8931
  // remove counts that are too much, they're all zero anyway if they exist
8928
8932
  new_meta.counts.length -= indexes_to_remove.size;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@depict-ai/ui",
3
- "version": "4.3.12",
3
+ "version": "4.3.14",
4
4
  "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.",
5
5
  "packageManager": "yarn@3.2.2",
6
6
  "sass": "styles.scss",
@@ -100,7 +100,7 @@ $parcel$export(module.exports, "BreadCrumbs", () => $335c02c1241a9ca8$export$5b7
100
100
  $parcel$export(module.exports, "QuickLinks", () => $335c02c1241a9ca8$export$de035477d6fef996);
101
101
  $parcel$export(module.exports, "CategoryPage", () => $c10e33c4681f8c9b$export$e2bf8ce7779e827e);
102
102
  /*! Depict.ai search and product listing SDK */
103
- const $aa1938dec50d6c12$export$83d89fbfd8236492 = "4.3.12";
103
+ const $aa1938dec50d6c12$export$83d89fbfd8236492 = "4.3.14";
104
104
  const $5401a6698b0c0658$var$transform_elements = sorted_cols_at_size => {
105
105
  const cols_at_size = [];
106
106
  for (let i = 0; i < sorted_cols_at_size.length; i++) {
@@ -7420,19 +7420,21 @@ function $a162c9a08dc208c2$export$b288c38ae3fddb56(_ref) {
7420
7420
  // can't or shouldn't be merged due to not being selected, just take remote one
7421
7421
  new_local_filter_state.push(remote_filter);else {
7422
7422
  const data_objs_in_remote = Object.fromEntries(remote_meta.values.map((value, index) => {
7423
- var _remote_meta$counts, _remote_meta$names;
7423
+ var _remote_meta$counts, _remote_meta$names, _swatches;
7424
7424
  return [JSON.stringify(value), {
7425
7425
  value_: value,
7426
7426
  count_: (_remote_meta$counts = remote_meta.counts) === null || _remote_meta$counts === void 0 ? void 0 : _remote_meta$counts[index],
7427
- name_: (_remote_meta$names = remote_meta.names) === null || _remote_meta$names === void 0 ? void 0 : _remote_meta$names[index]
7427
+ name_: (_remote_meta$names = remote_meta.names) === null || _remote_meta$names === void 0 ? void 0 : _remote_meta$names[index],
7428
+ swatches_: (_swatches = remote_meta.swatches) === null || _swatches === void 0 ? void 0 : _swatches[index]
7428
7429
  }];
7429
7430
  }));
7430
7431
  const data_objs_in_local = Object.fromEntries(local_meta.values.map((value, index) => {
7431
- var _local_meta$names;
7432
+ var _local_meta$names, _swatches2;
7432
7433
  return [JSON.stringify(value), {
7433
7434
  value_: value,
7434
7435
  count_: 0,
7435
- name_: (_local_meta$names = local_meta.names) === null || _local_meta$names === void 0 ? void 0 : _local_meta$names[index]
7436
+ name_: (_local_meta$names = local_meta.names) === null || _local_meta$names === void 0 ? void 0 : _local_meta$names[index],
7437
+ swatches_: (_swatches2 = local_meta.swatches) === null || _swatches2 === void 0 ? void 0 : _swatches2[index]
7436
7438
  }];
7437
7439
  }));
7438
7440
  const new_data = [...Object.keys(data_objs_in_local).filter(key => {
@@ -7477,6 +7479,14 @@ function $a162c9a08dc208c2$export$b288c38ae3fddb56(_ref) {
7477
7479
  count_: count_
7478
7480
  } = _ref4;
7479
7481
  return count_;
7482
+ }),
7483
+ ...("swatches" in remote_filter && {
7484
+ swatches: new_data.map(_ref5 => {
7485
+ let {
7486
+ swatches_: swatches_
7487
+ } = _ref5;
7488
+ return swatches_;
7489
+ })
7480
7490
  })
7481
7491
  }
7482
7492
  };
@@ -7526,6 +7536,10 @@ function $a162c9a08dc208c2$var$modify_only_local_filter(local_filter_object, sel
7526
7536
  }
7527
7537
  new_meta.values = values.filter((_, index) => !indexes_to_remove.has(index));
7528
7538
  if (new_meta.names) new_meta.names = new_meta.names.filter((_, index) => !indexes_to_remove.has(index));
7539
+ if ("swatches" in new_meta) {
7540
+ var _new_meta$swatches;
7541
+ new_meta.swatches = (_new_meta$swatches = new_meta.swatches) === null || _new_meta$swatches === void 0 ? void 0 : _new_meta$swatches.filter((_, index) => !indexes_to_remove.has(index));
7542
+ }
7529
7543
  if (new_meta.counts)
7530
7544
  // remove counts that are too much, they're all zero anyway if they exist
7531
7545
  new_meta.counts.length -= indexes_to_remove.size;
@@ -10,7 +10,7 @@ import { ProductListingRequestV3 } from "@depict-ai/types/api/ProductListingRequ
10
10
  import { GetListingRequest } from "@depict-ai/types/api/GetListingRequest";
11
11
  import { BaseSearchRequestV3 } from "@depict-ai/types/api/BaseSearchRequestV3";
12
12
  import { SearchFilter as _SearchFilter3 } from "@depict-ai/types/api/SearchRequestV2";
13
- export const version = "4.3.12";
13
+ export const version = "4.3.14";
14
14
  declare const LISTING_ID = "listingId";
15
15
  declare const EXTERNAL_ID = "externalId";
16
16
  type ScrollRestorationData = {
@@ -1399,7 +1399,7 @@ type OpenModalParams<OriginalDisplay extends Display, OutputDisplay extends Mode
1399
1399
  * Open the modal with support for alignment.
1400
1400
  * @returns {void}
1401
1401
  */
1402
- export const open_modal_with_alignment: <OriginalDisplay extends Display, OutputDisplay extends ModernDisplay>(openModalParams: OpenModalParams<OriginalDisplay, OutputDisplay>) => void;
1402
+ export const open_modal_with_alignment: <OriginalDisplay extends Display, OutputDisplay extends unknown>(openModalParams: OpenModalParams<OriginalDisplay, OutputDisplay>) => void;
1403
1403
  export function open_search_with_shift_slash(open_search: VoidFunction): () => void;
1404
1404
  export interface PageReplacer {
1405
1405
  readonly render_: () => Node_Array;
@@ -1477,5 +1477,5 @@ export function CategoryPage<OriginalDisplay extends Display, OutputDisplay exte
1477
1477
  content_blocks_by_row?: ContentBlocksByRow;
1478
1478
  layout?: PossibleLayout;
1479
1479
  filterModalParent_?: HTMLElement | ShadowRoot;
1480
- }): import("@depict-ai/utilishared/latest").Node_Array;
1480
+ }): import("@depict-ai/utilishared").Node_Array;
1481
1481
  export type { SearchFilter } from "@depict-ai/types/api/SearchRequestV3";
@@ -10,7 +10,7 @@ import { createStore as $b8hua$createStore, reconcile as $b8hua$reconcile } from
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.3.12";
13
+ const $8db9a15135765c11$export$83d89fbfd8236492 = "4.3.14";
14
14
  const $a9c7ba6087881ac2$var$transform_elements = sorted_cols_at_size => {
15
15
  const cols_at_size = [];
16
16
  for (let i = 0; i < sorted_cols_at_size.length; i++) {
@@ -7330,19 +7330,21 @@ function $44aa24b1bb793549$export$b288c38ae3fddb56(_ref) {
7330
7330
  // can't or shouldn't be merged due to not being selected, just take remote one
7331
7331
  new_local_filter_state.push(remote_filter);else {
7332
7332
  const data_objs_in_remote = Object.fromEntries(remote_meta.values.map((value, index) => {
7333
- var _remote_meta$counts, _remote_meta$names;
7333
+ var _remote_meta$counts, _remote_meta$names, _swatches;
7334
7334
  return [JSON.stringify(value), {
7335
7335
  value_: value,
7336
7336
  count_: (_remote_meta$counts = remote_meta.counts) === null || _remote_meta$counts === void 0 ? void 0 : _remote_meta$counts[index],
7337
- name_: (_remote_meta$names = remote_meta.names) === null || _remote_meta$names === void 0 ? void 0 : _remote_meta$names[index]
7337
+ name_: (_remote_meta$names = remote_meta.names) === null || _remote_meta$names === void 0 ? void 0 : _remote_meta$names[index],
7338
+ swatches_: (_swatches = remote_meta.swatches) === null || _swatches === void 0 ? void 0 : _swatches[index]
7338
7339
  }];
7339
7340
  }));
7340
7341
  const data_objs_in_local = Object.fromEntries(local_meta.values.map((value, index) => {
7341
- var _local_meta$names;
7342
+ var _local_meta$names, _swatches2;
7342
7343
  return [JSON.stringify(value), {
7343
7344
  value_: value,
7344
7345
  count_: 0,
7345
- name_: (_local_meta$names = local_meta.names) === null || _local_meta$names === void 0 ? void 0 : _local_meta$names[index]
7346
+ name_: (_local_meta$names = local_meta.names) === null || _local_meta$names === void 0 ? void 0 : _local_meta$names[index],
7347
+ swatches_: (_swatches2 = local_meta.swatches) === null || _swatches2 === void 0 ? void 0 : _swatches2[index]
7346
7348
  }];
7347
7349
  }));
7348
7350
  const new_data = [...Object.keys(data_objs_in_local).filter(key => {
@@ -7387,6 +7389,14 @@ function $44aa24b1bb793549$export$b288c38ae3fddb56(_ref) {
7387
7389
  count_: count_
7388
7390
  } = _ref4;
7389
7391
  return count_;
7392
+ }),
7393
+ ...("swatches" in remote_filter && {
7394
+ swatches: new_data.map(_ref5 => {
7395
+ let {
7396
+ swatches_: swatches_
7397
+ } = _ref5;
7398
+ return swatches_;
7399
+ })
7390
7400
  })
7391
7401
  }
7392
7402
  };
@@ -7436,6 +7446,10 @@ function $44aa24b1bb793549$var$modify_only_local_filter(local_filter_object, sel
7436
7446
  }
7437
7447
  new_meta.values = values.filter((_, index) => !indexes_to_remove.has(index));
7438
7448
  if (new_meta.names) new_meta.names = new_meta.names.filter((_, index) => !indexes_to_remove.has(index));
7449
+ if ("swatches" in new_meta) {
7450
+ var _new_meta$swatches;
7451
+ new_meta.swatches = (_new_meta$swatches = new_meta.swatches) === null || _new_meta$swatches === void 0 ? void 0 : _new_meta$swatches.filter((_, index) => !indexes_to_remove.has(index));
7452
+ }
7439
7453
  if (new_meta.counts)
7440
7454
  // remove counts that are too much, they're all zero anyway if they exist
7441
7455
  new_meta.counts.length -= indexes_to_remove.size;
@@ -94,7 +94,7 @@ $parcel$export(module.exports, "BreadCrumbs", () => $1f4925833f07df29$export$5b7
94
94
  $parcel$export(module.exports, "QuickLinks", () => $1f4925833f07df29$export$de035477d6fef996);
95
95
  $parcel$export(module.exports, "CategoryPage", () => $14f289047713d67a$export$e2bf8ce7779e827e);
96
96
  /*! Depict.ai search and product listing SDK */
97
- const $b757f75811f3261f$export$83d89fbfd8236492 = "4.3.12";
97
+ const $b757f75811f3261f$export$83d89fbfd8236492 = "4.3.14";
98
98
  const $4e04be41243c3d80$var$transform_elements = sorted_cols_at_size => {
99
99
  const cols_at_size = [];
100
100
  for (let i = 0; i < sorted_cols_at_size.length; i++) {
@@ -7010,12 +7010,14 @@ function $70482f04605572e2$export$b288c38ae3fddb56({
7010
7010
  const data_objs_in_remote = Object.fromEntries(remote_meta.values.map((value, index) => [JSON.stringify(value), {
7011
7011
  value_: value,
7012
7012
  count_: remote_meta.counts?.[index],
7013
- name_: remote_meta.names?.[index]
7013
+ name_: remote_meta.names?.[index],
7014
+ swatches_: remote_meta.swatches?.[index]
7014
7015
  }]));
7015
7016
  const data_objs_in_local = Object.fromEntries(local_meta.values.map((value, index) => [JSON.stringify(value), {
7016
7017
  value_: value,
7017
7018
  count_: 0,
7018
- name_: local_meta.names?.[index]
7019
+ name_: local_meta.names?.[index],
7020
+ swatches_: local_meta.swatches?.[index]
7019
7021
  }]));
7020
7022
  const new_data = [...Object.keys(data_objs_in_local).filter(key => {
7021
7023
  // put data entries that are selected and don't exist in new remote state first
@@ -7050,7 +7052,12 @@ function $70482f04605572e2$export$b288c38ae3fddb56({
7050
7052
  }) => name_),
7051
7053
  counts: new_data.map(({
7052
7054
  count_: count_
7053
- }) => count_)
7055
+ }) => count_),
7056
+ ...("swatches" in remote_filter && {
7057
+ swatches: new_data.map(({
7058
+ swatches_: swatches_
7059
+ }) => swatches_)
7060
+ })
7054
7061
  }
7055
7062
  };
7056
7063
  new_local_filter_state.push(result);
@@ -7099,6 +7106,7 @@ function $70482f04605572e2$var$modify_only_local_filter(local_filter_object, sel
7099
7106
  }
7100
7107
  new_meta.values = values.filter((_, index) => !indexes_to_remove.has(index));
7101
7108
  if (new_meta.names) new_meta.names = new_meta.names.filter((_, index) => !indexes_to_remove.has(index));
7109
+ if ("swatches" in new_meta) new_meta.swatches = new_meta.swatches?.filter((_, index) => !indexes_to_remove.has(index));
7102
7110
  if (new_meta.counts)
7103
7111
  // remove counts that are too much, they're all zero anyway if they exist
7104
7112
  new_meta.counts.length -= indexes_to_remove.size;
@@ -10,7 +10,7 @@ import { ProductListingRequestV3 } from "@depict-ai/types/api/ProductListingRequ
10
10
  import { GetListingRequest } from "@depict-ai/types/api/GetListingRequest";
11
11
  import { BaseSearchRequestV3 } from "@depict-ai/types/api/BaseSearchRequestV3";
12
12
  import { SearchFilter as _SearchFilter3 } from "@depict-ai/types/api/SearchRequestV2";
13
- export const version = "4.3.12";
13
+ export const version = "4.3.14";
14
14
  declare const LISTING_ID = "listingId";
15
15
  declare const EXTERNAL_ID = "externalId";
16
16
  type ScrollRestorationData = {
@@ -1399,7 +1399,7 @@ type OpenModalParams<OriginalDisplay extends Display, OutputDisplay extends Mode
1399
1399
  * Open the modal with support for alignment.
1400
1400
  * @returns {void}
1401
1401
  */
1402
- export const open_modal_with_alignment: <OriginalDisplay extends Display, OutputDisplay extends ModernDisplay>(openModalParams: OpenModalParams<OriginalDisplay, OutputDisplay>) => void;
1402
+ export const open_modal_with_alignment: <OriginalDisplay extends Display, OutputDisplay extends unknown>(openModalParams: OpenModalParams<OriginalDisplay, OutputDisplay>) => void;
1403
1403
  export function open_search_with_shift_slash(open_search: VoidFunction): () => void;
1404
1404
  export interface PageReplacer {
1405
1405
  readonly render_: () => Node_Array;
@@ -1477,5 +1477,5 @@ export function CategoryPage<OriginalDisplay extends Display, OutputDisplay exte
1477
1477
  content_blocks_by_row?: ContentBlocksByRow;
1478
1478
  layout?: PossibleLayout;
1479
1479
  filterModalParent_?: HTMLElement | ShadowRoot;
1480
- }): import("@depict-ai/utilishared/latest").Node_Array;
1480
+ }): import("@depict-ai/utilishared").Node_Array;
1481
1481
  export type { SearchFilter } from "@depict-ai/types/api/SearchRequestV3";
@@ -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.3.12";
10
+ const $ec291e0010116877$export$83d89fbfd8236492 = "4.3.14";
11
11
  const $b5cccc8ee7d24677$var$transform_elements = sorted_cols_at_size => {
12
12
  const cols_at_size = [];
13
13
  for (let i = 0; i < sorted_cols_at_size.length; i++) {
@@ -6923,12 +6923,14 @@ function $5efb5894079b220e$export$b288c38ae3fddb56({
6923
6923
  const data_objs_in_remote = Object.fromEntries(remote_meta.values.map((value, index) => [JSON.stringify(value), {
6924
6924
  value_: value,
6925
6925
  count_: remote_meta.counts?.[index],
6926
- name_: remote_meta.names?.[index]
6926
+ name_: remote_meta.names?.[index],
6927
+ swatches_: remote_meta.swatches?.[index]
6927
6928
  }]));
6928
6929
  const data_objs_in_local = Object.fromEntries(local_meta.values.map((value, index) => [JSON.stringify(value), {
6929
6930
  value_: value,
6930
6931
  count_: 0,
6931
- name_: local_meta.names?.[index]
6932
+ name_: local_meta.names?.[index],
6933
+ swatches_: local_meta.swatches?.[index]
6932
6934
  }]));
6933
6935
  const new_data = [...Object.keys(data_objs_in_local).filter(key => {
6934
6936
  // put data entries that are selected and don't exist in new remote state first
@@ -6963,7 +6965,12 @@ function $5efb5894079b220e$export$b288c38ae3fddb56({
6963
6965
  }) => name_),
6964
6966
  counts: new_data.map(({
6965
6967
  count_: count_
6966
- }) => count_)
6968
+ }) => count_),
6969
+ ...("swatches" in remote_filter && {
6970
+ swatches: new_data.map(({
6971
+ swatches_: swatches_
6972
+ }) => swatches_)
6973
+ })
6967
6974
  }
6968
6975
  };
6969
6976
  new_local_filter_state.push(result);
@@ -7012,6 +7019,7 @@ function $5efb5894079b220e$var$modify_only_local_filter(local_filter_object, sel
7012
7019
  }
7013
7020
  new_meta.values = values.filter((_, index) => !indexes_to_remove.has(index));
7014
7021
  if (new_meta.names) new_meta.names = new_meta.names.filter((_, index) => !indexes_to_remove.has(index));
7022
+ if ("swatches" in new_meta) new_meta.swatches = new_meta.swatches?.filter((_, index) => !indexes_to_remove.has(index));
7015
7023
  if (new_meta.counts)
7016
7024
  // remove counts that are too much, they're all zero anyway if they exist
7017
7025
  new_meta.counts.length -= indexes_to_remove.size;