@depict-ai/utilishared 1.0.34 → 1.0.36

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/latest/index.cjs CHANGED
@@ -272,7 +272,7 @@ $parcel$export(module.exports, "hex_to_rgb", () => $d73746ee466f09ca$export$ca30
272
272
  $parcel$export(module.exports, "version", () => $815f67c61b4c0a42$export$83d89fbfd8236492);
273
273
  $parcel$export(module.exports, "add_to_version_info", () => $e4a18bf12ad092d9$export$2cefb7e61fcbae00);
274
274
  $parcel$export(module.exports, "edit_current_page_meta_tags", () => $8838e3e61b748a8b$export$ef73ea4f975745ba);
275
- const $815f67c61b4c0a42$export$83d89fbfd8236492 = "1.0.34";
275
+ const $815f67c61b4c0a42$export$83d89fbfd8236492 = "1.0.36";
276
276
  const $7b5e577a60b81e60$export$55fe61489d2c7417 = /*@__PURE__*/(() => process.env.STRIP_DEBUG === "true" ? false : process.env.DEBUG === "true" || process.env.NODE_ENV === "development" || process.env.BUILD_TARGET !== "node" && (globalThis?.document?.currentScript?.dataset?.debug === "true" || globalThis?.localStorage?.getItem?.("debug") === "true"))();
277
277
  const $e6c6e7929ea385ae$var$browser_prefix_styling = "color: #fff;";
278
278
  let $e6c6e7929ea385ae$var$browser_prefix = "[Depict]";
@@ -293,7 +293,7 @@ function $e6c6e7929ea385ae$export$997143d41f6a0c9b(...args) {
293
293
  }
294
294
  const $e4a18bf12ad092d9$export$60d1d0e3cfc8b9ed = {};
295
295
  function $e4a18bf12ad092d9$export$2cefb7e61fcbae00(package_name, version) {
296
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("@depict-ai/" + package_name + " version", version);
296
+ $e6c6e7929ea385ae$export$de56f1198d121036("@depict-ai/" + package_name + " version", version);
297
297
  $e4a18bf12ad092d9$export$60d1d0e3cfc8b9ed[package_name] = version;
298
298
  }
299
299
  function $e4a18bf12ad092d9$export$fe609f0216e4ebef(url) {
@@ -452,8 +452,8 @@ const $9a42a570de51ea3d$var$compat_layer_to_info = /*@__PURE__*/new WeakMap();
452
452
  function $9a42a570de51ea3d$export$e806c6c1615a59ae(async_iterator_should_return_state_on_first_call = true, state_obj = new (0, $5a591e8156b1128c$export$e2c811ae0eb35313)()) {
453
453
  // @ts-ignore
454
454
  $9a42a570de51ea3d$var$on_async_iterator_next_called({}); // work around https://github.com/swc-project/swc/issues/5530
455
- const ai = (0, $5a591e8156b1128c$export$3e42f5078e3abfc0)(state_obj);
456
- const [exit, exitable] = (0, $bbe52965151ee7f0$export$927664b47117acb0)({
455
+ const ai = $5a591e8156b1128c$export$3e42f5078e3abfc0(state_obj);
456
+ const [exit, exitable] = $bbe52965151ee7f0$export$927664b47117acb0({
457
457
  ...ai
458
458
  });
459
459
  const obj = Object.assign(exitable, {
@@ -490,7 +490,7 @@ function $9a42a570de51ea3d$export$e806c6c1615a59ae(async_iterator_should_return_
490
490
  yield* $9a42a570de51ea3d$var$on_async_iterator_next_called(exitable_for_async_generator, unblock_state_obj, fn => stock_return_function = fn);
491
491
  };
492
492
  const iterator = async_generator();
493
- const [exit_async_generator, exitable_for_async_generator] = (0, $bbe52965151ee7f0$export$927664b47117acb0)(orig_iterator);
493
+ const [exit_async_generator, exitable_for_async_generator] = $bbe52965151ee7f0$export$927664b47117acb0(orig_iterator);
494
494
  // we can't use a normal async generator since it can't be "quit" from the outside (by calling .return on the AsyncIterator) while being awaited apparently
495
495
  // therefore we make the async iterable that it's (soon) passing control onto exitable by calling .return() (even if a .next() promise is being currently awaited)
496
496
  iterator.return = () => {
@@ -507,11 +507,11 @@ function $9a42a570de51ea3d$export$e806c6c1615a59ae(async_iterator_should_return_
507
507
  };
508
508
  }
509
509
  const callable_obj_with_everything = Object.assign(ai, obj);
510
- (0, $3c19296ad7b20394$export$8df876135bad6d96)(callable_obj_with_everything, "state", {
510
+ $3c19296ad7b20394$export$8df876135bad6d96(callable_obj_with_everything, "state", {
511
511
  get: () => state_obj.last_processed_value_,
512
512
  enumerable: true
513
513
  });
514
- (0, $3c19296ad7b20394$export$8df876135bad6d96)(callable_obj_with_everything, "latest_call_value", {
514
+ $3c19296ad7b20394$export$8df876135bad6d96(callable_obj_with_everything, "latest_call_value", {
515
515
  get: () => state_obj.queue_[state_obj.queue_.length - 1] ?? callable_obj_with_everything.state,
516
516
  enumerable: true
517
517
  });
@@ -557,7 +557,7 @@ function $9a42a570de51ea3d$export$10c3e52ef388b81b(ipns) {
557
557
  return $9a42a570de51ea3d$export$e806c6c1615a59ae(true, internal_state_obj);
558
558
  }
559
559
  function $548fd58b14b25a52$export$8048b892d651b310(exception, error_for_stack) {
560
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)(exception);
560
+ $e6c6e7929ea385ae$export$de56f1198d121036(exception);
561
561
  if (0, $7b5e577a60b81e60$export$55fe61489d2c7417) /* eslint-disable no-console */console.trace();
562
562
  if (process.env.BUILD_TARGET !== "node") {
563
563
  const {
@@ -580,7 +580,7 @@ async function $e6d67ef355abb2dc$export$2fc1a072736ae2f6(obj, property, ...sub_o
580
580
  }
581
581
  async function $e6d67ef355abb2dc$var$wait_for_variable_in_object(variable, obj) {
582
582
  const start = new Date().getTime();
583
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("waiting for definition of variable", variable, "in", obj);
583
+ $e6c6e7929ea385ae$export$de56f1198d121036("waiting for definition of variable", variable, "in", obj);
584
584
  let var_behind_the_scenes;
585
585
  let resolve_variable_definition;
586
586
  let was_defined = false;
@@ -608,9 +608,9 @@ async function $e6d67ef355abb2dc$var$wait_for_variable_in_object(variable, obj)
608
608
  get: get,
609
609
  set: set
610
610
  });
611
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("everything's set up, waiting for promise by setter to resolve");
611
+ $e6c6e7929ea385ae$export$de56f1198d121036("everything's set up, waiting for promise by setter to resolve");
612
612
  const result = await definition_of_var;
613
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Promise resolved, ", result, " is here. We waited", new Date().getTime() - start, "ms");
613
+ $e6c6e7929ea385ae$export$de56f1198d121036("Promise resolved, ", result, " is here. We waited", new Date().getTime() - start, "ms");
614
614
  return result;
615
615
  }
616
616
  function $e6d67ef355abb2dc$export$d5062f468a0454f3(obj, prop) {
@@ -618,7 +618,7 @@ function $e6d67ef355abb2dc$export$d5062f468a0454f3(obj, prop) {
618
618
  if (obj != null) return Object.hasOwnProperty.call(obj, prop) ? Object.getOwnPropertyDescriptor(obj, prop) : $e6d67ef355abb2dc$export$d5062f468a0454f3(Object.getPrototypeOf(obj), prop);
619
619
  }
620
620
  function $e6d67ef355abb2dc$export$79f910a98828378d(obj, variable, async_iterator_should_return_state_on_first_call) {
621
- const definition_ipns = (0, $9a42a570de51ea3d$export$e806c6c1615a59ae)(async_iterator_should_return_state_on_first_call);
621
+ const definition_ipns = $9a42a570de51ea3d$export$e806c6c1615a59ae(async_iterator_should_return_state_on_first_call);
622
622
  let var_behind_the_scenes = obj[variable];
623
623
  definition_ipns(var_behind_the_scenes); // resolve with initial value
624
624
  const previous_descriptor = $e6d67ef355abb2dc$export$d5062f468a0454f3(obj, variable);
@@ -749,7 +749,7 @@ async function $0cf2ab65d8901485$var$load_sentry(TENANT, more_options = {}, extr
749
749
  BrowserClient: BrowserClient,
750
750
  Hub: Hub,
751
751
  defaultIntegrations: defaultIntegrations
752
- } = await (0, $e6d67ef355abb2dc$export$2fc1a072736ae2f6)(window, global_var_name);
752
+ } = await $e6d67ef355abb2dc$export$2fc1a072736ae2f6(window, global_var_name);
753
753
  delete window[global_var_name];
754
754
  if (process.env.SENTRY_SAMPLE_RATE) {
755
755
  const sample_rate = parseFloat(process.env.SENTRY_SAMPLE_RATE);
@@ -771,7 +771,7 @@ async function $0cf2ab65d8901485$var$load_sentry(TENANT, more_options = {}, extr
771
771
  // https://github.com/getsentry/sentry-javascript/issues/2541
772
772
  return hub;
773
773
  }
774
- const $61a34358bf0d3d8b$export$af2e17a20c2ea3c5 = !(process.env.SENTRY === "true" || process.env.DEPICT_ERROR_REPORTING === "true" || process.env.NEXT_PUBLIC_DEPICT_ERROR_REPORTING === "true") && (process.env.SENTRY === "false" || process.env.DEPICT_ERROR_REPORTING === "false" || process.env.NEXT_PUBLIC_DEPICT_ERROR_REPORTING === "false" || (0, $7b5e577a60b81e60$export$55fe61489d2c7417)) ? /*@__PURE__*/$61a34358bf0d3d8b$var$fakesentry() : /*@__PURE__*/(0, $0cf2ab65d8901485$export$2e2bcd8739ae039)(process.env.TENANT || "unknown", undefined, (0, $e6c6e7929ea385ae$export$de56f1198d121036));
774
+ const $61a34358bf0d3d8b$export$af2e17a20c2ea3c5 = !(process.env.SENTRY === "true" || process.env.DEPICT_ERROR_REPORTING === "true" || process.env.NEXT_PUBLIC_DEPICT_ERROR_REPORTING === "true") && (process.env.SENTRY === "false" || process.env.DEPICT_ERROR_REPORTING === "false" || process.env.NEXT_PUBLIC_DEPICT_ERROR_REPORTING === "false" || (0, $7b5e577a60b81e60$export$55fe61489d2c7417)) ? /*@__PURE__*/$61a34358bf0d3d8b$var$fakesentry() : /*@__PURE__*/$0cf2ab65d8901485$export$2e2bcd8739ae039(process.env.TENANT || "unknown", undefined, (0, $e6c6e7929ea385ae$export$de56f1198d121036));
775
775
  function $61a34358bf0d3d8b$var$fakesentry() {
776
776
  // // source: https://docs.sentry.io/platforms/javascript/troubleshooting/#dealing-with-ad-blockers
777
777
  // const handler = {
@@ -838,13 +838,13 @@ function $3f34dc07544c5857$export$bb0a9c36cf454ea0(min, max) {
838
838
  function $41f528c04cc8a8da$export$535946eb77c946dd(the_function) {
839
839
  let busy = false;
840
840
  let current_promise;
841
- return (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(async (...args) => {
841
+ return $268cbd9e4ade92db$export$b3bbfd758f11cfa9(async (...args) => {
842
842
  // Double awaits to make sure that if busy is true, it must also be true two ticks later.
843
843
  // This is a fix for when a promise that finalizes immediately is passed.
844
844
  // For context: https://javascript.info/microtask-queue
845
845
  if (!busy || !(await await busy, busy)) {
846
846
  busy = true;
847
- const to_finally = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(the_function)(...args);
847
+ const to_finally = $268cbd9e4ade92db$export$b3bbfd758f11cfa9(the_function)(...args);
848
848
  current_promise = to_finally.finally(() => busy = false);
849
849
  }
850
850
  return current_promise;
@@ -854,13 +854,13 @@ function $41f528c04cc8a8da$export$f241be8e610f5c77(the_function) {
854
854
  let busy = false;
855
855
  let queued;
856
856
  let current_promise;
857
- const wrapped_fn = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(async (...args) => {
857
+ const wrapped_fn = $268cbd9e4ade92db$export$b3bbfd758f11cfa9(async (...args) => {
858
858
  // Double awaits to make sure that if busy is true, it must also be true two ticks later.
859
859
  // This is a fix for when a promise that finalizes immediately is passed.
860
860
  // For context: https://javascript.info/microtask-queue
861
861
  if (!busy || !(await await busy, busy)) {
862
862
  busy = true;
863
- const to_finally = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(the_function)(...args);
863
+ const to_finally = $268cbd9e4ade92db$export$b3bbfd758f11cfa9(the_function)(...args);
864
864
  current_promise = to_finally.finally(() => {
865
865
  busy = false;
866
866
  if (queued) {
@@ -879,7 +879,7 @@ class $04a37742898e4bd5$export$32ccf3a614c84258 {
879
879
  #internal_resolve;
880
880
  #previous_promise = Promise.resolve();
881
881
  promise = new Promise(r => this.#internal_resolve = r);
882
- #work_queue_max_once = (0, $41f528c04cc8a8da$export$535946eb77c946dd)(this.#work_queue.bind(this));
882
+ #work_queue_max_once = $41f528c04cc8a8da$export$535946eb77c946dd(this.#work_queue.bind(this));
883
883
  resolve = value => {
884
884
  this.#values_to_resolve_with.push(value);
885
885
  this.#work_queue_max_once();
@@ -907,7 +907,7 @@ class $d10801050840d92b$export$1b28bc5c68cc4d77 extends EventTarget {
907
907
  #max_fails = 10;
908
908
  #max_backoff_ms = $d10801050840d92b$var$ONE_MINUTE;
909
909
  get #initial_reconnect_delay() {
910
- return (0, $3f34dc07544c5857$export$bb0a9c36cf454ea0)(1, 1000);
910
+ return $3f34dc07544c5857$export$bb0a9c36cf454ea0(1, 1000);
911
911
  }
912
912
  #connect() {
913
913
  this.current_socket = typeof window === "object" || typeof WebSocket === "function" ? new WebSocket(...this.#ws_constructor_options) : {
@@ -916,7 +916,7 @@ class $d10801050840d92b$export$1b28bc5c68cc4d77 extends EventTarget {
916
916
  send: () => {}
917
917
  };
918
918
  this.#possible_events.forEach(name => {
919
- this.current_socket.addEventListener(name, (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(original_event => {
919
+ this.current_socket.addEventListener(name, $268cbd9e4ade92db$export$b3bbfd758f11cfa9(original_event => {
920
920
  let fixed_event;
921
921
  if (!(original_event instanceof Event)) {
922
922
  // Node - the WS class uses a predecessor of EventTarget and doesn't fire actual events, which we need for dispatchEvent since we're an EventTarget
@@ -959,7 +959,7 @@ class $d10801050840d92b$export$1b28bc5c68cc4d77 extends EventTarget {
959
959
  this.addEventListener(ev, e => {
960
960
  // e can be MessageEvent | CloseEvent | ErrorEvent I think
961
961
  const on_fn = this.#ons[ev];
962
- if (typeof on_fn === "function") (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(on_fn).call(ev, e);
962
+ if (typeof on_fn === "function") $268cbd9e4ade92db$export$b3bbfd758f11cfa9(on_fn).call(ev, e);
963
963
  });
964
964
  }
965
965
  }
@@ -975,10 +975,10 @@ class $d10801050840d92b$export$1b28bc5c68cc4d77 extends EventTarget {
975
975
  // 4100 means server thinks this is a scraper bot that's ignoring robots.txt
976
976
  // @ts-ignore
977
977
  if (error?.code === 4100) {
978
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Websocket connection rejected by server, won't reconnect", error);
978
+ $e6c6e7929ea385ae$export$de56f1198d121036("Websocket connection rejected by server, won't reconnect", error);
979
979
  return;
980
980
  }
981
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Somehow the websocket died", error, "message:",
981
+ $e6c6e7929ea385ae$export$de56f1198d121036("Somehow the websocket died", error, "message:",
982
982
  // @ts-ignore
983
983
  error?.message, "code:",
984
984
  // @ts-ignore
@@ -987,15 +987,15 @@ class $d10801050840d92b$export$1b28bc5c68cc4d77 extends EventTarget {
987
987
  error?.reason, "reconnecting in", this.#try_again_in_ms);
988
988
  await new Promise(r => {
989
989
  // "race" the timeout and getting an https://developer.mozilla.org/en-US/docs/Web/API/Window/online_event by the browser
990
- const handler = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(ev => {
990
+ const handler = $268cbd9e4ade92db$export$b3bbfd758f11cfa9(ev => {
991
991
  r();
992
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Retrying due to 'online' event", ev);
992
+ $e6c6e7929ea385ae$export$de56f1198d121036("Retrying due to 'online' event", ev);
993
993
  clearTimeout(timeout);
994
994
  });
995
995
  window.addEventListener("online", handler, {
996
996
  once: true
997
997
  });
998
- const timeout = setTimeout((0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(() => {
998
+ const timeout = setTimeout($268cbd9e4ade92db$export$b3bbfd758f11cfa9(() => {
999
999
  this.#try_again_in_ms *= 1.5 + Math.random();
1000
1000
  if (this.#try_again_in_ms > this.#max_backoff_ms) this.#try_again_in_ms = this.#max_backoff_ms * (1 + Math.random() / 10);
1001
1001
  r();
@@ -1024,9 +1024,9 @@ class $d10801050840d92b$export$1b28bc5c68cc4d77 extends EventTarget {
1024
1024
  if (max_backoff_ms) this.#max_backoff_ms = max_backoff_ms;
1025
1025
  this.#setup_dot_on_event_support();
1026
1026
  this.#connect();
1027
- this.#ensure_connection().catch(e => (0, $268cbd9e4ade92db$export$f18d5b0af29128b7)(e, "error"));
1028
- this.addEventListener("open", (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(() => {
1029
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Connection opened");
1027
+ this.#ensure_connection().catch(e => $268cbd9e4ade92db$export$f18d5b0af29128b7(e, "error"));
1028
+ this.addEventListener("open", $268cbd9e4ade92db$export$b3bbfd758f11cfa9(() => {
1029
+ $e6c6e7929ea385ae$export$de56f1198d121036("Connection opened");
1030
1030
  this.#try_again_in_ms = this.#initial_reconnect_delay; // reset exponential backoff
1031
1031
  }));
1032
1032
  }
@@ -1047,14 +1047,14 @@ class $d10801050840d92b$export$1d9c6fddbff3441f extends $d10801050840d92b$export
1047
1047
  });
1048
1048
  this.send(msg);
1049
1049
  }
1050
- #start_reconnection_if_offline_process = (0, $41f528c04cc8a8da$export$535946eb77c946dd)(async () => {
1051
- await new Promise(r => setTimeout(r, this.#reconnect_if_dead_for_ms + (0, $3f34dc07544c5857$export$bb0a9c36cf454ea0)(-2, 10)));
1050
+ #start_reconnection_if_offline_process = $41f528c04cc8a8da$export$535946eb77c946dd(async () => {
1051
+ await new Promise(r => setTimeout(r, this.#reconnect_if_dead_for_ms + $3f34dc07544c5857$export$bb0a9c36cf454ea0(-2, 10)));
1052
1052
  // so if we are trying to send something and there's no activity ("error" which could mean the server is down or message or reconnection) we can safely assume that the internet connection is down. In that case we skip the exponential backoff since we want to know when we're connected again ASAP and just retry every like 20s
1053
1053
  if (this.#messages_queued === 0) return;
1054
1054
  const now = +new Date();
1055
1055
  if (now - this.#connection_last_active > this.#reconnect_if_dead_for_ms) {
1056
1056
  const reason = `No activity in ${this.#reconnect_if_dead_for_ms} ms`;
1057
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)(reason, "reconnecting ws");
1057
+ $e6c6e7929ea385ae$export$de56f1198d121036(reason, "reconnecting ws");
1058
1058
  this.restart_ws(reason);
1059
1059
  }
1060
1060
  });
@@ -1074,7 +1074,7 @@ class $d10801050840d92b$export$1d9c6fddbff3441f extends $d10801050840d92b$export
1074
1074
  // wait the correct delay
1075
1075
  const resend_due_to_lost_message_timeout = setTimeout(
1076
1076
  // this might actually never be needed and be from when Daniel didn't understand WebSockets as well
1077
- (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(() => {
1077
+ $268cbd9e4ade92db$export$b3bbfd758f11cfa9(() => {
1078
1078
  r(true);
1079
1079
  this.removeEventListener("open", handler);
1080
1080
  }), delay_to_next_send);
@@ -1092,7 +1092,7 @@ class $d10801050840d92b$export$1d9c6fddbff3441f extends $d10801050840d92b$export
1092
1092
  this.increase_fails();
1093
1093
  }
1094
1094
  this.#messages_queued--;
1095
- })().catch(e => (0, $268cbd9e4ade92db$export$f18d5b0af29128b7)(e, "error"));
1095
+ })().catch(e => $268cbd9e4ade92db$export$f18d5b0af29128b7(e, "error"));
1096
1096
  return () => quit = true;
1097
1097
  }
1098
1098
  async ensure_sent(payload) {
@@ -1107,8 +1107,8 @@ class $d10801050840d92b$export$1d9c6fddbff3441f extends $d10801050840d92b$export
1107
1107
  reply = JSON.parse(data);
1108
1108
  } catch (e) {
1109
1109
  const msg = "Got malformed message (ignoring, might cause memory leak)";
1110
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)(msg, data, e);
1111
- (0, $268cbd9e4ade92db$export$f18d5b0af29128b7)([e, msg], "error", {
1110
+ $e6c6e7929ea385ae$export$de56f1198d121036(msg, data, e);
1111
+ $268cbd9e4ade92db$export$f18d5b0af29128b7([e, msg], "error", {
1112
1112
  data: data
1113
1113
  });
1114
1114
  continue;
@@ -1120,9 +1120,9 @@ class $d10801050840d92b$export$1d9c6fddbff3441f extends $d10801050840d92b$export
1120
1120
  if (status == "ack") {
1121
1121
  stop_sending();
1122
1122
  continue;
1123
- } else if (status == "not-ok") (0, $e6c6e7929ea385ae$export$c2363754d4758444)("Got reply not-ok reply from server for event!", payload, reply);else if (status == "ok") {
1124
- if (process.env.BUILD_TARGET !== "node") (0, $e6c6e7929ea385ae$export$de56f1198d121036)(`Successfully sent ${payload?.event?.type} (WS)`, payload, reply);
1125
- } else (0, $e6c6e7929ea385ae$export$c2363754d4758444)("Strange reply from WSS server to", payload, ":", reply);
1123
+ } else if (status == "not-ok") $e6c6e7929ea385ae$export$c2363754d4758444("Got reply not-ok reply from server for event!", payload, reply);else if (status == "ok") {
1124
+ if (process.env.BUILD_TARGET !== "node") $e6c6e7929ea385ae$export$de56f1198d121036(`Successfully sent ${payload?.event?.type} (WS)`, payload, reply);
1125
+ } else $e6c6e7929ea385ae$export$c2363754d4758444("Strange reply from WSS server to", payload, ":", reply);
1126
1126
  stop_sending();
1127
1127
  return [reply, data];
1128
1128
  }
@@ -1132,8 +1132,8 @@ class $d10801050840d92b$export$1d9c6fddbff3441f extends $d10801050840d92b$export
1132
1132
  super(...params);
1133
1133
  const option_retry_ms = params[2]?.initial_retry_ms;
1134
1134
  if (option_retry_ms) this.#initial_retry_ms = option_retry_ms;
1135
- this.addEventListener("message", (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(this.#msg_ipns.resolve));
1136
- ["open", "error", "message"].forEach(event => this.addEventListener(event, (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(() => this.#connection_last_active = +new Date())));
1135
+ this.addEventListener("message", $268cbd9e4ade92db$export$b3bbfd758f11cfa9(this.#msg_ipns.resolve));
1136
+ ["open", "error", "message"].forEach(event => this.addEventListener(event, $268cbd9e4ade92db$export$b3bbfd758f11cfa9(() => this.#connection_last_active = +new Date())));
1137
1137
  }
1138
1138
  }
1139
1139
 
@@ -1158,17 +1158,17 @@ const $0c84f8e99aac5765$export$72036d950e1fae95 = /*@__PURE__*/$0c84f8e99aac5765
1158
1158
  const $0c84f8e99aac5765$export$aa26019042811d4f = /*@__PURE__*/$0c84f8e99aac5765$var$c(async bodies => {
1159
1159
  if (process.env.DEPICT === "false") return;
1160
1160
  for (let i = 0; i < bodies.length; i++) {
1161
- const id = (0, $650b64c1b384c895$export$656831b7e9c341c3)();
1161
+ const id = $650b64c1b384c895$export$656831b7e9c341c3();
1162
1162
  $0c84f8e99aac5765$var$ws_instance?.ensure_sent({
1163
1163
  id: id,
1164
1164
  event: bodies[i]
1165
- }).catch(e => (0, $268cbd9e4ade92db$export$f18d5b0af29128b7)(e, "error"));
1165
+ }).catch(e => $268cbd9e4ade92db$export$f18d5b0af29128b7(e, "error"));
1166
1166
  }
1167
1167
  });
1168
1168
  const $0c84f8e99aac5765$export$608478473a3304a0 = /*@__PURE__*/$0c84f8e99aac5765$var$c((payload, use_ws = true) => {
1169
1169
  if (process.env.DEPICT === "false") return;
1170
1170
  if (use_ws && typeof WebSocket == "function" && typeof $0c84f8e99aac5765$var$ws_instance?.ensure_sent == "function") {
1171
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Sending to depict (ws)", payload);
1171
+ $e6c6e7929ea385ae$export$de56f1198d121036("Sending to depict (ws)", payload);
1172
1172
  return $0c84f8e99aac5765$export$aa26019042811d4f(payload);
1173
1173
  }
1174
1174
  const url = (0, $4c6861fbcd3a0611$export$362abebb4b313340) + "/create-events";
@@ -1177,19 +1177,19 @@ const $0c84f8e99aac5765$export$608478473a3304a0 = /*@__PURE__*/$0c84f8e99aac5765
1177
1177
  const $0c84f8e99aac5765$export$cc3b6ddf805f6156 = /*@__PURE__*/$0c84f8e99aac5765$var$c((url, payload) => {
1178
1178
  const payload_json = JSON.stringify(payload);
1179
1179
  let success = false;
1180
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)(`Attempting to send (beacon)`, payload);
1180
+ $e6c6e7929ea385ae$export$de56f1198d121036(`Attempting to send (beacon)`, payload);
1181
1181
  try {
1182
1182
  success = navigator.sendBeacon(url, new Blob([payload_json], {
1183
1183
  type: "application/json"
1184
1184
  }));
1185
1185
  } catch (first_error) {
1186
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Beacon has failed", first_error, "falling back to sending with wrong mime type which might work");
1186
+ $e6c6e7929ea385ae$export$de56f1198d121036("Beacon has failed", first_error, "falling back to sending with wrong mime type which might work");
1187
1187
  try {
1188
1188
  success = navigator.sendBeacon(url, new Blob([payload_json], {
1189
1189
  type: "application/x-www-form-urlencoded"
1190
1190
  }));
1191
1191
  } catch (e) {
1192
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Beacon fallback has failed", e, "trying fetch");
1192
+ $e6c6e7929ea385ae$export$de56f1198d121036("Beacon fallback has failed", e, "trying fetch");
1193
1193
  fetch(url, {
1194
1194
  "headers": {
1195
1195
  "content-type": "application/json"
@@ -1198,7 +1198,7 @@ const $0c84f8e99aac5765$export$cc3b6ddf805f6156 = /*@__PURE__*/$0c84f8e99aac5765
1198
1198
  "method": "POST",
1199
1199
  "mode": "cors",
1200
1200
  "credentials": "include"
1201
- }).then(response => response.text()).then(text => (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Beacon fallback fallback transmission result", text)).catch(fetch_error => {
1201
+ }).then(response => response.text()).then(text => $e6c6e7929ea385ae$export$de56f1198d121036("Beacon fallback fallback transmission result", text)).catch(fetch_error => {
1202
1202
  (0, $61a34358bf0d3d8b$export$af2e17a20c2ea3c5).withScope(function (scope) {
1203
1203
  scope.setExtra("stack", new Error().stack);
1204
1204
  scope.setExtra("url", url);
@@ -1227,9 +1227,9 @@ let $e0a87646d12cb987$export$6399bdb2291895e0 = () => {
1227
1227
  let localstorage_error;
1228
1228
  let cookie_error;
1229
1229
  try {
1230
- id = localStorage._dep_id ||= (0, $650b64c1b384c895$export$656831b7e9c341c3)();
1230
+ id = localStorage._dep_id ||= $650b64c1b384c895$export$656831b7e9c341c3();
1231
1231
  } catch (e) {
1232
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Can't use localStorage", e);
1232
+ $e6c6e7929ea385ae$export$de56f1198d121036("Can't use localStorage", e);
1233
1233
  localstorage_error = e;
1234
1234
  }
1235
1235
  if (!id) {
@@ -1242,11 +1242,11 @@ let $e0a87646d12cb987$export$6399bdb2291895e0 = () => {
1242
1242
  }, {})._dep_id;
1243
1243
  id = get_cookie_id();
1244
1244
  if (!id) {
1245
- document.cookie = `_dep_id=${(0, $650b64c1b384c895$export$656831b7e9c341c3)()}; expires=Fri, 31 Dec 9999 23:59:59 GMT`;
1245
+ document.cookie = `_dep_id=${$650b64c1b384c895$export$656831b7e9c341c3()}; expires=Fri, 31 Dec 9999 23:59:59 GMT`;
1246
1246
  id = get_cookie_id();
1247
1247
  }
1248
1248
  } catch (e) {
1249
- (0, $268cbd9e4ade92db$export$f18d5b0af29128b7)(e, "warning");
1249
+ $268cbd9e4ade92db$export$f18d5b0af29128b7(e, "warning");
1250
1250
  cookie_error = e;
1251
1251
  }
1252
1252
  (0, $61a34358bf0d3d8b$export$af2e17a20c2ea3c5).withScope(function (scope) {
@@ -1257,14 +1257,14 @@ let $e0a87646d12cb987$export$6399bdb2291895e0 = () => {
1257
1257
  this.captureMessage(`${id ? "localStorage" : "cookie and localStorage"} failed to hold a value!`);
1258
1258
  });
1259
1259
  }
1260
- if (!id) id = (0, $650b64c1b384c895$export$656831b7e9c341c3)();
1260
+ if (!id) id = $650b64c1b384c895$export$656831b7e9c341c3();
1261
1261
  return id;
1262
1262
  };
1263
1263
  let $e0a87646d12cb987$export$adc61a405a4cabed = $e0a87646d12cb987$export$6399bdb2291895e0;
1264
1264
  let $e0a87646d12cb987$export$61e7e1f11e96692f = () => undefined;
1265
- const $e0a87646d12cb987$export$336e7ad40bae0652 = /*@__PURE__*/(0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(newfn => $e0a87646d12cb987$export$6399bdb2291895e0 = newfn);
1266
- const $e0a87646d12cb987$export$8a96793bf9f87d90 = /*@__PURE__*/(0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(newfn => $e0a87646d12cb987$export$adc61a405a4cabed = newfn);
1267
- const $e0a87646d12cb987$export$93ae15b1ae509334 = /*@__PURE__*/(0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(newfn => $e0a87646d12cb987$export$61e7e1f11e96692f = newfn);
1265
+ const $e0a87646d12cb987$export$336e7ad40bae0652 = /*@__PURE__*/$268cbd9e4ade92db$export$b3bbfd758f11cfa9(newfn => $e0a87646d12cb987$export$6399bdb2291895e0 = newfn);
1266
+ const $e0a87646d12cb987$export$8a96793bf9f87d90 = /*@__PURE__*/$268cbd9e4ade92db$export$b3bbfd758f11cfa9(newfn => $e0a87646d12cb987$export$adc61a405a4cabed = newfn);
1267
+ const $e0a87646d12cb987$export$93ae15b1ae509334 = /*@__PURE__*/$268cbd9e4ade92db$export$b3bbfd758f11cfa9(newfn => $e0a87646d12cb987$export$61e7e1f11e96692f = newfn);
1268
1268
  const $e0a87646d12cb987$export$8c6f26a5b6921b95 = /*@__PURE__*/() => {
1269
1269
  return {
1270
1270
  session_id: $e0a87646d12cb987$export$61e7e1f11e96692f(),
@@ -1275,7 +1275,7 @@ const $e0a87646d12cb987$export$8c6f26a5b6921b95 = /*@__PURE__*/() => {
1275
1275
  document_referrer: document?.referrer
1276
1276
  };
1277
1277
  };
1278
- const $e0a87646d12cb987$export$82badda1f9923310 = /*@__PURE__*/(0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)((vars, use_ws) => {
1278
+ const $e0a87646d12cb987$export$82badda1f9923310 = /*@__PURE__*/$268cbd9e4ade92db$export$b3bbfd758f11cfa9((vars, use_ws) => {
1279
1279
  if (process.env.DEPICT === "false") return;
1280
1280
  const payload = [{
1281
1281
  ...$e0a87646d12cb987$export$8c6f26a5b6921b95(),
@@ -1285,9 +1285,9 @@ const $e0a87646d12cb987$export$82badda1f9923310 = /*@__PURE__*/(0, $268cbd9e4ade
1285
1285
  entity_price: vars?.sale_price,
1286
1286
  ...vars
1287
1287
  }];
1288
- return (0, $0c84f8e99aac5765$export$28cacbd9b4306ffc)(payload, use_ws);
1288
+ return $0c84f8e99aac5765$export$28cacbd9b4306ffc(payload, use_ws);
1289
1289
  });
1290
- const $e0a87646d12cb987$export$15f8a0cd5a8c0ebb = /*@__PURE__*/(0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(vars => {
1290
+ const $e0a87646d12cb987$export$15f8a0cd5a8c0ebb = /*@__PURE__*/$268cbd9e4ade92db$export$b3bbfd758f11cfa9(vars => {
1291
1291
  if (process.env.DEPICT === "false") return;
1292
1292
  const beacon_retval = $e0a87646d12cb987$export$82badda1f9923310({
1293
1293
  ...vars,
@@ -1303,7 +1303,7 @@ const $e0a87646d12cb987$export$15f8a0cd5a8c0ebb = /*@__PURE__*/(0, $268cbd9e4ade
1303
1303
 
1304
1304
  return beacon_retval;
1305
1305
  });
1306
- const $e0a87646d12cb987$export$9028351cb994757e = /*@__PURE__*/(0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(vars => {
1306
+ const $e0a87646d12cb987$export$9028351cb994757e = /*@__PURE__*/$268cbd9e4ade92db$export$b3bbfd758f11cfa9(vars => {
1307
1307
  if (process.env.DEPICT === "false") return;
1308
1308
  return $e0a87646d12cb987$export$82badda1f9923310({
1309
1309
  ...vars,
@@ -1317,7 +1317,7 @@ function $e0a87646d12cb987$export$622991c71a1f52b3(cookie_name) {
1317
1317
  function $13a446968e3581c0$export$c50e1901e8ed0615(callback) {
1318
1318
  // https://stackoverflow.com/a/61574326
1319
1319
  const channel = new MessageChannel();
1320
- channel.port1.onmessage = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(callback);
1320
+ channel.port1.onmessage = $268cbd9e4ade92db$export$b3bbfd758f11cfa9(callback);
1321
1321
  channel.port2.postMessage("");
1322
1322
  }
1323
1323
  function $dba5a9c0f6fb4324$export$6f051469dd676a8b(tenant, market, type) {
@@ -1327,11 +1327,11 @@ function $dba5a9c0f6fb4324$export$6f051469dd676a8b(tenant, market, type) {
1327
1327
  if (!display) return;
1328
1328
  info.set_on_index_change(() => {
1329
1329
  current_displays.add(display);
1330
- (0, $z0IcO$solidjs.onCleanup)(() => current_displays.delete(display));
1330
+ $z0IcO$solidjs.onCleanup(() => current_displays.delete(display));
1331
1331
  if (!queued_sending) {
1332
1332
  queued_sending = true;
1333
- (0, $13a446968e3581c0$export$c50e1901e8ed0615)(() => {
1334
- (0, $e0a87646d12cb987$export$82badda1f9923310)({
1333
+ $13a446968e3581c0$export$c50e1901e8ed0615(() => {
1334
+ $e0a87646d12cb987$export$82badda1f9923310({
1335
1335
  tenant: tenant,
1336
1336
  market: market,
1337
1337
  recommendation_type: type,
@@ -1352,7 +1352,7 @@ function $ee1d22bd1fcdd4e1$export$6e7454c733fa1fb2(fn, ...args) {
1352
1352
  return fn.apply(this, [...args, ...unimportant_args]);
1353
1353
  };
1354
1354
  }
1355
- const $eee5951374097b61$export$8582cf3716962dc2 = /*@__PURE__*/(0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(async ({
1355
+ const $eee5951374097b61$export$8582cf3716962dc2 = /*@__PURE__*/$268cbd9e4ade92db$export$b3bbfd758f11cfa9(async ({
1356
1356
  recs: recs,
1357
1357
  min_recs: min_recs,
1358
1358
  market: market,
@@ -1369,11 +1369,11 @@ const $eee5951374097b61$export$8582cf3716962dc2 = /*@__PURE__*/(0, $268cbd9e4ade
1369
1369
  if (Array.isArray(recs)) {
1370
1370
  if (min_recs == undefined) min_recs = 10;
1371
1371
  if (recs.length < min_recs) {
1372
- (0, $e6c6e7929ea385ae$export$c2363754d4758444)("Displays provided to check_displays is too short, it contains", recs.length, "displays which is less than", min_recs);
1372
+ $e6c6e7929ea385ae$export$c2363754d4758444("Displays provided to check_displays is too short, it contains", recs.length, "displays which is less than", min_recs);
1373
1373
  return false;
1374
1374
  } else return true;
1375
- } else (0, $e6c6e7929ea385ae$export$c2363754d4758444)(new Error("neither recs nor recs.displays are an array"));
1376
- } else (0, $e6c6e7929ea385ae$export$c2363754d4758444)(new Error("Non object was passed to check_displays"));
1375
+ } else $e6c6e7929ea385ae$export$c2363754d4758444(new Error("neither recs nor recs.displays are an array"));
1376
+ } else $e6c6e7929ea385ae$export$c2363754d4758444(new Error("Non object was passed to check_displays"));
1377
1377
  });
1378
1378
  const $546052c2e3608435$var$elem_track_id_map = /*@__PURE__*/new WeakMap();
1379
1379
  function $546052c2e3608435$export$16d7c76794a38a4(element, event, track_id, func) {
@@ -1419,7 +1419,7 @@ function $7599647868f98022$var$check_if_querySelectorAll_needs_patching() {
1419
1419
  }
1420
1420
  let $55595fc7bb226f61$var$has_queued_microtask = false;
1421
1421
  const $55595fc7bb226f61$var$queued_callbacks = /*@__PURE__*/new Map();
1422
- const $55595fc7bb226f61$var$catchified_deduplicate_and_dispatch = /*@__PURE__*/(0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)($55595fc7bb226f61$var$deduplicate_and_dispatch, "error in observer event processing", "error");
1422
+ const $55595fc7bb226f61$var$catchified_deduplicate_and_dispatch = /*@__PURE__*/$268cbd9e4ade92db$export$b3bbfd758f11cfa9($55595fc7bb226f61$var$deduplicate_and_dispatch, "error in observer event processing", "error");
1423
1423
  function $55595fc7bb226f61$export$2b08e30396270f0b(callback, ev) {
1424
1424
  $55595fc7bb226f61$var$queued_callbacks.set(ev, callback);
1425
1425
  if (!$55595fc7bb226f61$var$has_queued_microtask) queueMicrotask($55595fc7bb226f61$var$catchified_deduplicate_and_dispatch);
@@ -1464,7 +1464,7 @@ function $55595fc7bb226f61$var$deduplicate_and_dispatch() {
1464
1464
  }
1465
1465
  }
1466
1466
  function $55595fc7bb226f61$var$call_callback(callback, ev) {
1467
- (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(callback, "Error in observer callback")(ev);
1467
+ $268cbd9e4ade92db$export$b3bbfd758f11cfa9(callback, "Error in observer callback")(ev);
1468
1468
  }
1469
1469
  class $e2f46d4f382caff1$export$ea60432919e69303 {
1470
1470
  constructor(opts) {
@@ -1484,7 +1484,7 @@ class $9043c64496e3375f$export$12e07a2a9f87578a {
1484
1484
  #attribute_attribution_map_object = {};
1485
1485
  #territory;
1486
1486
  #listeners = ["exists", "creation", "removed", "change"];
1487
- #weakref_finalization_registry = typeof FinalizationRegistry === "function" && new FinalizationRegistry((0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(this.#finalization_registry_callback.bind(this)));
1487
+ #weakref_finalization_registry = typeof FinalizationRegistry === "function" && new FinalizationRegistry($268cbd9e4ade92db$export$b3bbfd758f11cfa9(this.#finalization_registry_callback.bind(this)));
1488
1488
  #verbs = {
1489
1489
  // add "normal" functions for the class that can be used as i.e. observer.ifexists() here
1490
1490
  ifexists: (selector, callback) => {
@@ -1505,7 +1505,7 @@ class $9043c64496e3375f$export$12e07a2a9f87578a {
1505
1505
  return;
1506
1506
  }
1507
1507
  const our_set = this.#attribute_attribution_map_object[selector] ||= new WeakSet();
1508
- const elements = typeof document === "undefined" ? [] : (0, $7599647868f98022$export$33f937d741e49339)(this.#territory || document, selector);
1508
+ const elements = typeof document === "undefined" ? [] : $7599647868f98022$export$33f937d741e49339(this.#territory || document, selector);
1509
1509
  for (let i = 0; i < elements.length; i++) {
1510
1510
  const element = elements[i];
1511
1511
  our_set.add(element);
@@ -1526,7 +1526,7 @@ class $9043c64496e3375f$export$12e07a2a9f87578a {
1526
1526
  wait_for_listener: (listener, selector, timeout) => {
1527
1527
  this.#check_observer_args(listener, () => {}, false);
1528
1528
  // console.log("waiting for listener", listener, "selector", selector, "timeout", timeout);
1529
- return new Promise((0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(r => {
1529
+ return new Promise($268cbd9e4ade92db$export$b3bbfd758f11cfa9(r => {
1530
1530
  const stop_observing = this.#self_proxied["on" + listener](selector, ({
1531
1531
  element: element,
1532
1532
  disconnector: disconnector
@@ -1689,7 +1689,7 @@ class $9043c64496e3375f$export$12e07a2a9f87578a {
1689
1689
  if ((addedNodes.length || removedNodes.length) && node.hasChildNodes() &&
1690
1690
  // @ts-ignore
1691
1691
  node.querySelectorAll /* don't act on i.e. textnodes. Doing the check this way is actually faster than both `in` and instanceof */) {
1692
- const matching_children = (0, $7599647868f98022$export$33f937d741e49339)(node, selector);
1692
+ const matching_children = $7599647868f98022$export$33f937d741e49339(node, selector);
1693
1693
  for (let m = 0; m < matching_children.length; m++) {
1694
1694
  // always use for loops because this can't be slow and forEach takes ages
1695
1695
  if (event == "exists") our_set.add(matching_children[m]);
@@ -1755,7 +1755,7 @@ class $9043c64496e3375f$export$12e07a2a9f87578a {
1755
1755
  const matching_nodes = [];
1756
1756
  // @ts-ignore
1757
1757
  if (node?.matches?.(selector)) matching_nodes.push(node);
1758
- matching_nodes.push(...((0, $7599647868f98022$export$33f937d741e49339)(node, selector) || []));
1758
+ matching_nodes.push(...($7599647868f98022$export$33f937d741e49339(node, selector) || []));
1759
1759
  for (let v = 0; v < matching_nodes.length; v++) this.#call_callbacks(callbacks, callback => ({
1760
1760
  element_: matching_nodes[v],
1761
1761
  selector_: selector,
@@ -1799,14 +1799,14 @@ class $9043c64496e3375f$export$12e07a2a9f87578a {
1799
1799
  for (let i = 0; i < execute_after_run.length; i++) try {
1800
1800
  execute_after_run[i]();
1801
1801
  } catch (e) {
1802
- (0, $268cbd9e4ade92db$export$f18d5b0af29128b7)([e, "error in observer running queued function"], "error");
1802
+ $268cbd9e4ade92db$export$f18d5b0af29128b7([e, "error in observer running queued function"], "error");
1803
1803
  }
1804
1804
  // Let the garbage collector empty the old array by creating a new one
1805
1805
  this.#execute_after_callback_ran = [];
1806
1806
  this.#observer_callback_running = false;
1807
1807
  }
1808
1808
  } catch (e) {
1809
- (0, $268cbd9e4ade92db$export$f18d5b0af29128b7)([e, "error in observer"], "error");
1809
+ $268cbd9e4ade92db$export$f18d5b0af29128b7([e, "error in observer"], "error");
1810
1810
  }
1811
1811
  };
1812
1812
  #check_observer_args(selector, callback, allow_nodes) {
@@ -1821,7 +1821,7 @@ class $9043c64496e3375f$export$12e07a2a9f87578a {
1821
1821
  // We are probably running on the server where we can't do anything anyway so we might just return
1822
1822
  return;
1823
1823
  if (!listener || !selector || !callback) {
1824
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("listener, selector or callback is falsey", {
1824
+ $e6c6e7929ea385ae$export$de56f1198d121036("listener, selector or callback is falsey", {
1825
1825
  listener: listener,
1826
1826
  selector: selector,
1827
1827
  callback: callback
@@ -1910,7 +1910,7 @@ class $9043c64496e3375f$export$12e07a2a9f87578a {
1910
1910
  }
1911
1911
  }
1912
1912
  #call_callbacks(callbacks, make_ev_data) {
1913
- for (const callback of callbacks) (0, $55595fc7bb226f61$export$2b08e30396270f0b)(callback, new (0, $e2f46d4f382caff1$export$ea60432919e69303)(make_ev_data(callback)));
1913
+ for (const callback of callbacks) $55595fc7bb226f61$export$2b08e30396270f0b(callback, new (0, $e2f46d4f382caff1$export$ea60432919e69303)(make_ev_data(callback)));
1914
1914
  }
1915
1915
  #get(target, verb) {
1916
1916
  // @ts-ignore
@@ -1934,7 +1934,7 @@ function $2a1cbc63a04d4a2d$var$make_default_observer() {
1934
1934
  try {
1935
1935
  return new (0, $9043c64496e3375f$export$12e07a2a9f87578a)();
1936
1936
  } catch (error) {
1937
- (0, $268cbd9e4ade92db$export$f18d5b0af29128b7)([error, "error starting ElementObserver"], "error");
1937
+ $268cbd9e4ade92db$export$f18d5b0af29128b7([error, "error starting ElementObserver"], "error");
1938
1938
  }
1939
1939
  }
1940
1940
  function $bf7f12fe044e41b2$export$925772df9b4d16e5(url, param, value) {
@@ -1960,22 +1960,22 @@ function $bf7f12fe044e41b2$export$d3e2a0560cbf4787(html) {
1960
1960
  }
1961
1961
  function $bf7f12fe044e41b2$export$d4bd03f19260ef1c(url, also_onchange = false, override_dev_url = "demo.depict.ai", stfu = true, also_in_all_shadow_roots = false) {
1962
1962
  if (process.env.DEBUG === "true" && location.href.includes(override_dev_url)) {
1963
- const relativ_callback = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(event => {
1963
+ const relativ_callback = $268cbd9e4ade92db$export$b3bbfd758f11cfa9(event => {
1964
1964
  const anchor = event.element;
1965
1965
  if (typeof url === "string") {
1966
1966
  if (anchor.href.includes(url)) {
1967
- if (!stfu) (0, $e6c6e7929ea385ae$export$de56f1198d121036)("RUNNING RELATIVIFY on", event);
1967
+ if (!stfu) $e6c6e7929ea385ae$export$de56f1198d121036("RUNNING RELATIVIFY on", event);
1968
1968
  anchor.href = anchor.href.replaceAll(url, "/");
1969
1969
  }
1970
1970
  } else if (url.test(anchor.href)) {
1971
- if (!stfu) (0, $e6c6e7929ea385ae$export$de56f1198d121036)("RUNNING RELATIVIFY on", event);
1971
+ if (!stfu) $e6c6e7929ea385ae$export$de56f1198d121036("RUNNING RELATIVIFY on", event);
1972
1972
  anchor.href = anchor.href.replace(url, "/");
1973
1973
  }
1974
1974
  });
1975
1975
  const link_sel = "a[href]";
1976
1976
  (0, $2a1cbc63a04d4a2d$export$b6ae1bc530f4c149).onexists(link_sel, relativ_callback);
1977
1977
  if (also_onchange) (0, $2a1cbc63a04d4a2d$export$b6ae1bc530f4c149).onchange(link_sel, relativ_callback);
1978
- if (also_in_all_shadow_roots && typeof ShadowRoot == "function") (0, $2a1cbc63a04d4a2d$export$b6ae1bc530f4c149).onexists("*", (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(({
1978
+ if (also_in_all_shadow_roots && typeof ShadowRoot == "function") (0, $2a1cbc63a04d4a2d$export$b6ae1bc530f4c149).onexists("*", $268cbd9e4ade92db$export$b3bbfd758f11cfa9(({
1979
1979
  element: element
1980
1980
  }) => {
1981
1981
  if (element?.shadowRoot instanceof ShadowRoot) {
@@ -1990,7 +1990,7 @@ function $bf7f12fe044e41b2$export$d4bd03f19260ef1c(url, also_onchange = false, o
1990
1990
  function $bf7f12fe044e41b2$export$5e63aea0cac01fa0(elements, selector) {
1991
1991
  const matches = [];
1992
1992
  for (const element of elements) {
1993
- if ("querySelectorAll" in element) matches.push(...(0, $7599647868f98022$export$33f937d741e49339)(element, selector));
1993
+ if ("querySelectorAll" in element) matches.push(...$7599647868f98022$export$33f937d741e49339(element, selector));
1994
1994
  if ("matches" in element && element.matches?.(selector)) matches.push(element);
1995
1995
  }
1996
1996
  return matches;
@@ -2000,18 +2000,21 @@ function $bf7f12fe044e41b2$export$cfef5d5c9ac09253(price, places_after_comma = 2
2000
2000
  if (!price && price !== 0) return "";
2001
2001
  if (typeof price === "string") {
2002
2002
  if (!isNaN(price)) {
2003
- (0, $268cbd9e4ade92db$export$f18d5b0af29128b7)(new Error("standard_price_format did not expect price as a string"), "warning", {
2003
+ $268cbd9e4ade92db$export$f18d5b0af29128b7(new Error("standard_price_format did not expect price as a string"), "warning", {
2004
2004
  price: price
2005
2005
  });
2006
2006
  price = parseFloat(price);
2007
2007
  } else {
2008
- (0, $268cbd9e4ade92db$export$f18d5b0af29128b7)(new Error("standard_price_format cannot handle price string"), "error", {
2008
+ $268cbd9e4ade92db$export$f18d5b0af29128b7(new Error("standard_price_format cannot handle price string"), "error", {
2009
2009
  price: price
2010
2010
  });
2011
2011
  return "";
2012
2012
  }
2013
2013
  }
2014
2014
  if (places_after_comma == "auto") places_after_comma = price % 1 ? 2 : 0;
2015
+ // Generalized rounding for any value of places_after_comma.
2016
+ const multiplier = Math.pow(10, places_after_comma);
2017
+ price = Math.round(price * multiplier) / multiplier;
2015
2018
  const fixed = places_after_comma < 0 ? price.toString().split(".") : price.toFixed(places_after_comma).split("."),
2016
2019
  [...chars] = fixed[0],
2017
2020
  reversed = chars.reverse();
@@ -2041,14 +2044,14 @@ function $2fafbbbf345dcde0$export$947a20746936143d(promises) {
2041
2044
  async function $44909e19109bf973$export$836f70a28c317905(product_id) {
2042
2045
  if (typeof BroadcastChannel != "function") return;
2043
2046
  const bc = new BroadcastChannel("right_click_attribution");
2044
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Broadcasting", product_id, "to", bc);
2047
+ $e6c6e7929ea385ae$export$de56f1198d121036("Broadcasting", product_id, "to", bc);
2045
2048
  bc.postMessage(product_id);
2046
2049
  bc.close();
2047
2050
  }
2048
2051
  function $44909e19109bf973$export$58c56fe2313fdbe3(elements, display, info, get_event_listener_remover) {
2049
2052
  if (typeof BroadcastChannel != "function") return elements;
2050
2053
  const disconnectors = [];
2051
- const handler = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(e => $44909e19109bf973$export$8f66c4c7fb96eda2(e, ("variant_index" in display ? display.variant_displays[display.variant_index] : display).product_id));
2054
+ const handler = $268cbd9e4ade92db$export$b3bbfd758f11cfa9(e => $44909e19109bf973$export$8f66c4c7fb96eda2(e, ("variant_index" in display ? display.variant_displays[display.variant_index] : display).product_id));
2052
2055
  const auxclick_handler = e => e.button === 1 && handler(e);
2053
2056
  for (let i = 0; i < elements?.length; i++) {
2054
2057
  const element = elements[i];
@@ -2063,15 +2066,15 @@ function $44909e19109bf973$export$58c56fe2313fdbe3(elements, display, info, get_
2063
2066
  return elements;
2064
2067
  }
2065
2068
  async function $44909e19109bf973$export$8f66c4c7fb96eda2(e, product_id) {
2066
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Contextmenu was invoked", e);
2069
+ $e6c6e7929ea385ae$export$de56f1198d121036("Contextmenu was invoked", e);
2067
2070
  const element = e.currentTarget || e.target;
2068
2071
  const bc = new BroadcastChannel("right_click_attribution");
2069
- const got_wanted_event = await (0, $2fafbbbf345dcde0$export$947a20746936143d)([new Promise(resolve => {
2070
- bc.addEventListener("message", (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(msg => {
2072
+ const got_wanted_event = await $2fafbbbf345dcde0$export$947a20746936143d([new Promise(resolve => {
2073
+ bc.addEventListener("message", $268cbd9e4ade92db$export$b3bbfd758f11cfa9(msg => {
2071
2074
  const {
2072
2075
  data: data
2073
2076
  } = msg;
2074
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Recieved broadcast channel event", data, msg);
2077
+ $e6c6e7929ea385ae$export$de56f1198d121036("Recieved broadcast channel event", data, msg);
2075
2078
  if (data == product_id) resolve(true);
2076
2079
  }));
2077
2080
  }), new Promise(r => setTimeout(r, 60000, false))]);
@@ -2082,12 +2085,12 @@ async function $44909e19109bf973$export$8f66c4c7fb96eda2(e, product_id) {
2082
2085
  cancelable: true,
2083
2086
  metaKey: true
2084
2087
  });
2085
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Someone broadcasted our product_id! Simulating a click event on the element that was contextmenu'd", element, click);
2088
+ $e6c6e7929ea385ae$export$de56f1198d121036("Someone broadcasted our product_id! Simulating a click event on the element that was contextmenu'd", element, click);
2086
2089
  element.addEventListener("click", e => (e.preventDefault(), false), {
2087
2090
  once: true
2088
2091
  });
2089
2092
  element.dispatchEvent(click);
2090
- } else (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Our product_id did not get broadcasted, closing channel");
2093
+ } else $e6c6e7929ea385ae$export$de56f1198d121036("Our product_id did not get broadcasted, closing channel");
2091
2094
  bc.close();
2092
2095
  }
2093
2096
 
@@ -2122,7 +2125,7 @@ const $72ed530554068e4f$var$unwatch_element = element => {
2122
2125
  };
2123
2126
  const $72ed530554068e4f$export$4c51576248bcdf31 = (element, callback) => {
2124
2127
  if ($72ed530554068e4f$var$watched_elements.has(element)) {
2125
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Not watching", element, "as it's already being watched");
2128
+ $e6c6e7929ea385ae$export$de56f1198d121036("Not watching", element, "as it's already being watched");
2126
2129
  return () => {};
2127
2130
  }
2128
2131
  $72ed530554068e4f$var$intersection_observer?.observe(element);
@@ -2177,7 +2180,7 @@ const $72ed530554068e4f$var$intersection_observer_callback = entries => {
2177
2180
  clearTimeout(callback_timeout_);
2178
2181
  if (time_elapsed <= (0, $dd025eb6f77f8f8b$export$ca8321ea61dc2544)) $72ed530554068e4f$var$current_intersections.delete(target);else {
2179
2182
  // we intersected long enough
2180
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("intersection_observer: setTimeout lagged", time_elapsed, (0, $dd025eb6f77f8f8b$export$ca8321ea61dc2544), "ms", target);
2183
+ $e6c6e7929ea385ae$export$de56f1198d121036("intersection_observer: setTimeout lagged", time_elapsed, (0, $dd025eb6f77f8f8b$export$ca8321ea61dc2544), "ms", target);
2181
2184
  callback(target);
2182
2185
  }
2183
2186
  }
@@ -2187,33 +2190,33 @@ const $72ed530554068e4f$var$intersection_observer_callback = entries => {
2187
2190
  * Global IntersectionObserver used for all impression tracking.
2188
2191
  * It's faster to use one observer for all elements than to create a new one for each element.
2189
2192
  */
2190
- const $72ed530554068e4f$var$intersection_observer = typeof window === "object" ? /*@__PURE__*/new IntersectionObserver( /*@__PURE__*/(0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)($72ed530554068e4f$var$intersection_observer_callback), {
2191
- threshold: /*@__PURE__*/(0, $0da0cad4f39e8f32$export$f8ea2e7b15b5d129)(8)
2193
+ const $72ed530554068e4f$var$intersection_observer = typeof window === "object" ? /*@__PURE__*/new IntersectionObserver( /*@__PURE__*/$268cbd9e4ade92db$export$b3bbfd758f11cfa9($72ed530554068e4f$var$intersection_observer_callback), {
2194
+ threshold: /*@__PURE__*/$0da0cad4f39e8f32$export$f8ea2e7b15b5d129(8)
2192
2195
  }) : undefined;
2193
2196
  const $11ff7b46c1fb674c$export$d0efd8ed14f5c33 = (items, display, info) => {
2194
2197
  if (!items?.length) return items;
2195
2198
  const node_array = Array.isArray(items) ? items : [...items]; // if it's a NodeList convert it to an array
2196
2199
  const first_watchable_el = node_array.find(el => el instanceof Element);
2197
2200
  if (!first_watchable_el) {
2198
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Impression tracking: Can't observe", items, display);
2201
+ $e6c6e7929ea385ae$export$de56f1198d121036("Impression tracking: Can't observe", items, display);
2199
2202
  return items;
2200
2203
  }
2201
2204
  if (!info.t) {
2202
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Impression tracking: No tenant instance, can't track", items, display);
2205
+ $e6c6e7929ea385ae$export$de56f1198d121036("Impression tracking: No tenant instance, can't track", items, display);
2203
2206
  return items;
2204
2207
  }
2205
2208
  (0, $2a1cbc63a04d4a2d$export$b6ae1bc530f4c149).onexists(first_watchable_el, ({
2206
2209
  element: element
2207
2210
  }) => {
2208
- (0, $72ed530554068e4f$export$4c51576248bcdf31)(element, () => {
2211
+ $72ed530554068e4f$export$4c51576248bcdf31(element, () => {
2209
2212
  const {
2210
2213
  recommendation_id: recommendation_id,
2211
2214
  search_result_id: search_result_id,
2212
2215
  product_listing_result_id: product_listing_result_id,
2213
2216
  suggestions_result_id: suggestions_result_id
2214
2217
  } = display;
2215
- (0, $dd025eb6f77f8f8b$export$4205dc6835bc0d9f)({
2216
- ...(0, $e0a87646d12cb987$export$8c6f26a5b6921b95)(),
2218
+ $dd025eb6f77f8f8b$export$4205dc6835bc0d9f({
2219
+ ...$e0a87646d12cb987$export$8c6f26a5b6921b95(),
2217
2220
  recommendation_type: info.rendering_options.type,
2218
2221
  entity_price: display.sale_price,
2219
2222
  market: info.t.market,
@@ -2235,9 +2238,9 @@ const $8e19f8200d357fe7$export$37125ccc5dd98050 = ({
2235
2238
  }) => {
2236
2239
  const disconnectors = [];
2237
2240
  const impression_track = () => {
2238
- const disconnector = (0, $72ed530554068e4f$export$4c51576248bcdf31)(element, () => {
2239
- (0, $dd025eb6f77f8f8b$export$4205dc6835bc0d9f)({
2240
- ...(0, $e0a87646d12cb987$export$8c6f26a5b6921b95)(),
2241
+ const disconnector = $72ed530554068e4f$export$4c51576248bcdf31(element, () => {
2242
+ $dd025eb6f77f8f8b$export$4205dc6835bc0d9f({
2243
+ ...$e0a87646d12cb987$export$8c6f26a5b6921b95(),
2241
2244
  ...data
2242
2245
  });
2243
2246
  });
@@ -2251,7 +2254,7 @@ const $dd025eb6f77f8f8b$export$c543ee4cdb0d0964 = (start, end) => $dd025eb6f77f8
2251
2254
  const $dd025eb6f77f8f8b$export$ca8321ea61dc2544 = 500;
2252
2255
  const $dd025eb6f77f8f8b$export$4205dc6835bc0d9f = data => {
2253
2256
  data.type = "element_visible"; // Set the type to element_visible as this is optional to pass here.
2254
- (0, $0c84f8e99aac5765$export$28cacbd9b4306ffc)([data], true);
2257
+ $0c84f8e99aac5765$export$28cacbd9b4306ffc([data], true);
2255
2258
  };
2256
2259
  function $c8263a2185830bf1$export$82a685f2da2fb027(a_element, product_id, recommendation_id, additional_listener) {
2257
2260
  if (!a_element ||
@@ -2282,9 +2285,9 @@ function $c8263a2185830bf1$export$82a685f2da2fb027(a_element, product_id, recomm
2282
2285
  async function $c8263a2185830bf1$export$2c34560c3749dc63(button, get_product_id, tracking_fn, unmatching_tracking, event) {
2283
2286
  // @ts-ignore
2284
2287
  if (!button || button.depict_tracked) return;
2285
- button.addEventListener(event ? event : "click", (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(async e => {
2288
+ button.addEventListener(event ? event : "click", $268cbd9e4ade92db$export$b3bbfd758f11cfa9(async e => {
2286
2289
  if (!e.isTrusted) {
2287
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("ignoring event", e, "because it's not user generated");
2290
+ $e6c6e7929ea385ae$export$de56f1198d121036("ignoring event", e, "because it's not user generated");
2288
2291
  return;
2289
2292
  }
2290
2293
  const product_id = await get_product_id(undefined, e);
@@ -2300,8 +2303,8 @@ async function $c8263a2185830bf1$export$2c34560c3749dc63(button, get_product_id,
2300
2303
  // @ts-ignore
2301
2304
  button.depict_tracked = true;
2302
2305
  }
2303
- const $69f7524c8bdd85b4$export$20e9533e68ee72e7 = /*@__PURE__*/(0, $9a42a570de51ea3d$export$e806c6c1615a59ae)(false);
2304
- const $69f7524c8bdd85b4$export$a9d39e43ae273d26 = /*@__PURE__*/(0, $9a42a570de51ea3d$export$e806c6c1615a59ae)();
2306
+ const $69f7524c8bdd85b4$export$20e9533e68ee72e7 = /*@__PURE__*/$9a42a570de51ea3d$export$e806c6c1615a59ae(false);
2307
+ const $69f7524c8bdd85b4$export$a9d39e43ae273d26 = /*@__PURE__*/$9a42a570de51ea3d$export$e806c6c1615a59ae();
2305
2308
  const $69f7524c8bdd85b4$export$7500cdfd37aafd43 = /*@__PURE__*/new Set();
2306
2309
  let $69f7524c8bdd85b4$var$old_url;
2307
2310
  const $69f7524c8bdd85b4$var$maybe_navigation = (what_happened, args) => {
@@ -2318,9 +2321,9 @@ const $69f7524c8bdd85b4$var$maybe_navigation = (what_happened, args) => {
2318
2321
  };
2319
2322
  $69f7524c8bdd85b4$export$baccefee4a395d8f((args, what_happened) => $69f7524c8bdd85b4$var$maybe_navigation(what_happened, args));
2320
2323
  $69f7524c8bdd85b4$var$maybe_navigation();
2321
- globalThis?.window?.addEventListener("popstate", (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(e => $69f7524c8bdd85b4$var$maybe_navigation("popstate", e)));
2324
+ globalThis?.window?.addEventListener("popstate", $268cbd9e4ade92db$export$b3bbfd758f11cfa9(e => $69f7524c8bdd85b4$var$maybe_navigation("popstate", e)));
2322
2325
  async function $69f7524c8bdd85b4$export$1cd22bab0d2c3b0b(callback) {
2323
- const catchified_callback = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(callback);
2326
+ const catchified_callback = $268cbd9e4ade92db$export$b3bbfd758f11cfa9(callback);
2324
2327
  for await (const href of $69f7524c8bdd85b4$export$20e9533e68ee72e7) {
2325
2328
  catchified_callback(href);
2326
2329
  break;
@@ -2341,7 +2344,7 @@ async function $69f7524c8bdd85b4$export$baccefee4a395d8f(after_navigation, repla
2341
2344
  try {
2342
2345
  after_navigation(arguments_list, the_thing);
2343
2346
  } catch (e) {
2344
- (0, $548fd58b14b25a52$export$8048b892d651b310)(e);
2347
+ $548fd58b14b25a52$export$8048b892d651b310(e);
2345
2348
  }
2346
2349
  return nav_result;
2347
2350
  }
@@ -2364,21 +2367,21 @@ async function $72ee205b59322497$export$eee4c4d924348b05(data) {
2364
2367
  } = location;
2365
2368
  if ($72ee205b59322497$var$last_page_pageview_sent_for !== href) {
2366
2369
  $72ee205b59322497$var$last_page_pageview_sent_for = href;
2367
- (0, $e0a87646d12cb987$export$82badda1f9923310)({
2370
+ $e0a87646d12cb987$export$82badda1f9923310({
2368
2371
  ...data,
2369
2372
  type: "page_view"
2370
2373
  });
2371
- if (data.product_id) await (0, $44909e19109bf973$export$836f70a28c317905)(data.product_id); // this takes care of right click click attribution - broadcasts the URL of the current page
2374
+ if (data.product_id) await $44909e19109bf973$export$836f70a28c317905(data.product_id); // this takes care of right click click attribution - broadcasts the URL of the current page
2372
2375
  }
2373
2376
  } catch (error) {
2374
- (0, $268cbd9e4ade92db$export$f18d5b0af29128b7)([error, "Sending page view failed"], "warning");
2377
+ $268cbd9e4ade92db$export$f18d5b0af29128b7([error, "Sending page view failed"], "warning");
2375
2378
  }
2376
2379
  }
2377
2380
  let $72ee205b59322497$var$sending_on_navigation = false;
2378
2381
  async function $72ee205b59322497$export$f7cb1bd47199ec38(data) {
2379
2382
  if (!$72ee205b59322497$var$sending_on_navigation) {
2380
2383
  $72ee205b59322497$var$sending_on_navigation = true;
2381
- (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(async () => {
2384
+ $268cbd9e4ade92db$export$b3bbfd758f11cfa9(async () => {
2382
2385
  for await (const _href of (0, $69f7524c8bdd85b4$export$a9d39e43ae273d26)) $72ee205b59322497$export$eee4c4d924348b05({
2383
2386
  tenant: data.tenant,
2384
2387
  market: data.market,
@@ -2431,7 +2434,7 @@ $parcel$export($28e42b0009d694b2$exports, "cookiebot_get_cookie_ipns", () => $28
2431
2434
  $parcel$export($28e42b0009d694b2$exports, "init_cookiebot_tracking", () => $28e42b0009d694b2$export$abec7fd9f0b9cc22);
2432
2435
  const $28e42b0009d694b2$var$required_consent_level = process.env.DEPICT_TRACKING_CONSENT_LEVEL;
2433
2436
  function $28e42b0009d694b2$var$consent_from_cookie() {
2434
- const cookie = (0, $e0a87646d12cb987$export$622991c71a1f52b3)("CookieConsent");
2437
+ const cookie = $e0a87646d12cb987$export$622991c71a1f52b3("CookieConsent");
2435
2438
  if (!cookie) return;
2436
2439
  const consent_json = cookie.replace(/%2C/g, ",").replace(/%27/g, "'").replace(/'/g, '"').replace(/([{[,])\s*([\w]+?):/g, '$1"$2":');
2437
2440
  try {
@@ -2439,7 +2442,7 @@ function $28e42b0009d694b2$var$consent_from_cookie() {
2439
2442
  } catch ({
2440
2443
  message: message
2441
2444
  }) {
2442
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Error parsing cookie json", consent_json, message);
2445
+ $e6c6e7929ea385ae$export$de56f1198d121036("Error parsing cookie json", consent_json, message);
2443
2446
  return;
2444
2447
  }
2445
2448
  }
@@ -2453,10 +2456,10 @@ async function $28e42b0009d694b2$export$56c2e8be65fb14ae() {
2453
2456
  }
2454
2457
  function $28e42b0009d694b2$export$8827362e5e938d26() {
2455
2458
  if ($28e42b0009d694b2$var$cookie_ipns) return $28e42b0009d694b2$var$cookie_ipns;
2456
- $28e42b0009d694b2$var$cookie_ipns = (0, $9a42a570de51ea3d$export$e806c6c1615a59ae)();
2459
+ $28e42b0009d694b2$var$cookie_ipns = $9a42a570de51ea3d$export$e806c6c1615a59ae();
2457
2460
  const existing_consent = $28e42b0009d694b2$var$consent_from_cookie();
2458
2461
  if (existing_consent) $28e42b0009d694b2$var$cookie_ipns(existing_consent);
2459
- const consent_maybe_changed = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(() => {
2462
+ const consent_maybe_changed = $268cbd9e4ade92db$export$b3bbfd758f11cfa9(() => {
2460
2463
  const {
2461
2464
  consent: {
2462
2465
  marketing: marketing,
@@ -2472,25 +2475,25 @@ function $28e42b0009d694b2$export$8827362e5e938d26() {
2472
2475
  statistics: statistics
2473
2476
  };
2474
2477
  if (!Object.keys(new_consent_obj).every(k => $28e42b0009d694b2$var$cookie_ipns.latest_call_value?.[k] === new_consent_obj[k])) {
2475
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Consent changed", new_consent_obj);
2478
+ $e6c6e7929ea385ae$export$de56f1198d121036("Consent changed", new_consent_obj);
2476
2479
  $28e42b0009d694b2$var$cookie_ipns(new_consent_obj);
2477
2480
  }
2478
2481
  }, "extracting consent failed");
2479
- (0, $e6d67ef355abb2dc$export$2fc1a072736ae2f6)(window, "Cookiebot", "consent").then(consent_maybe_changed);
2482
+ $e6d67ef355abb2dc$export$2fc1a072736ae2f6(window, "Cookiebot", "consent").then(consent_maybe_changed);
2480
2483
  ["CookiebotOnAccept", "CookiebotOnDecline"].forEach(e => window.addEventListener(e, consent_maybe_changed, false));
2481
2484
  return $28e42b0009d694b2$var$cookie_ipns;
2482
2485
  }
2483
- const $28e42b0009d694b2$export$abec7fd9f0b9cc22 = /*@__PURE__*/(0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(async (anon_id = "anonymous") => {
2484
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Initializing Cookiebot tracking");
2485
- if (!$28e42b0009d694b2$var$required_consent_level) return (0, $e6c6e7929ea385ae$export$de56f1198d121036)("No consent level set for Depict tracking. Ignoring consent and tracking everything.");
2486
+ const $28e42b0009d694b2$export$abec7fd9f0b9cc22 = /*@__PURE__*/$268cbd9e4ade92db$export$b3bbfd758f11cfa9(async (anon_id = "anonymous") => {
2487
+ $e6c6e7929ea385ae$export$de56f1198d121036("Initializing Cookiebot tracking");
2488
+ if (!$28e42b0009d694b2$var$required_consent_level) return $e6c6e7929ea385ae$export$de56f1198d121036("No consent level set for Depict tracking. Ignoring consent and tracking everything.");
2486
2489
  const original_get_depict_id = (0, $e0a87646d12cb987$export$6399bdb2291895e0);
2487
2490
  const original_get_user_id = (0, $e0a87646d12cb987$export$adc61a405a4cabed);
2488
- (0, $e0a87646d12cb987$export$336e7ad40bae0652)(() => $28e42b0009d694b2$var$has_consent ? original_get_depict_id() : anon_id);
2489
- (0, $e0a87646d12cb987$export$8a96793bf9f87d90)(() => $28e42b0009d694b2$var$has_consent ? original_get_user_id() : anon_id);
2491
+ $e0a87646d12cb987$export$336e7ad40bae0652(() => $28e42b0009d694b2$var$has_consent ? original_get_depict_id() : anon_id);
2492
+ $e0a87646d12cb987$export$8a96793bf9f87d90(() => $28e42b0009d694b2$var$has_consent ? original_get_user_id() : anon_id);
2490
2493
  for await (const consent_obj of $28e42b0009d694b2$export$8827362e5e938d26()) {
2491
2494
  // Changing this will change the return value of function given to set_depict_id_fn above
2492
2495
  $28e42b0009d694b2$var$has_consent = consent_obj[$28e42b0009d694b2$var$required_consent_level];
2493
- if (!$28e42b0009d694b2$var$has_consent) (0, $e6c6e7929ea385ae$export$de56f1198d121036)(`dsid/user_id will be set to, "${anon_id}", until Cookiebot has consent for "${$28e42b0009d694b2$var$required_consent_level}"`);else (0, $e6c6e7929ea385ae$export$de56f1198d121036)(`Cookiebot obtained consent for "${$28e42b0009d694b2$var$required_consent_level}", will use true dsid/user_id`);
2496
+ if (!$28e42b0009d694b2$var$has_consent) $e6c6e7929ea385ae$export$de56f1198d121036(`dsid/user_id will be set to, "${anon_id}", until Cookiebot has consent for "${$28e42b0009d694b2$var$required_consent_level}"`);else $e6c6e7929ea385ae$export$de56f1198d121036(`Cookiebot obtained consent for "${$28e42b0009d694b2$var$required_consent_level}", will use true dsid/user_id`);
2494
2497
  }
2495
2498
  });
2496
2499
  const $2026711c6c2d6204$var$required_consent_level = process.env.DEPICT_TRACKING_CONSENT_LEVEL;
@@ -2509,7 +2512,7 @@ const $2026711c6c2d6204$var$required_consent_level = process.env.DEPICT_TRACKING
2509
2512
  const $2026711c6c2d6204$var$KEY_ORDER = ["necessary", "statistics", "preferences", "marketing"];
2510
2513
  const $2026711c6c2d6204$var$OPTANON_TO_COOKIEBOT = Object.fromEntries((process.env.OPTANON_KEYS || "").split(",").filter(k => k).map((k, i) => [k, $2026711c6c2d6204$var$KEY_ORDER[i]]));
2511
2514
  function $2026711c6c2d6204$var$consent_from_cookie() {
2512
- const cookie = (0, $e0a87646d12cb987$export$622991c71a1f52b3)("OptanonConsent");
2515
+ const cookie = $e0a87646d12cb987$export$622991c71a1f52b3("OptanonConsent");
2513
2516
  if (!cookie) return;
2514
2517
  const groups = new URLSearchParams(cookie).get("groups") || "";
2515
2518
  const matches = groups.matchAll(/(\w+):(\d)/g);
@@ -2518,7 +2521,7 @@ function $2026711c6c2d6204$var$consent_from_cookie() {
2518
2521
  return consent;
2519
2522
  }
2520
2523
  let $2026711c6c2d6204$var$cookie_ipns;
2521
- let $2026711c6c2d6204$var$has_consent = $2026711c6c2d6204$var$required_consent_level ? /*@__PURE__*/$2026711c6c2d6204$var$consent_from_cookie()?.[$2026711c6c2d6204$var$required_consent_level] || false : true;
2524
+ let $2026711c6c2d6204$var$has_consent = /*@__PURE__*/(() => $2026711c6c2d6204$var$required_consent_level ? $2026711c6c2d6204$var$consent_from_cookie()?.[$2026711c6c2d6204$var$required_consent_level] || false : true)();
2522
2525
  const $2026711c6c2d6204$export$1dd9ce50e201eff1 = () => $2026711c6c2d6204$var$has_consent;
2523
2526
  async function $2026711c6c2d6204$export$7a6d436e0782c6ed() {
2524
2527
  for await (const consent_obj of $2026711c6c2d6204$export$7e4427e80d5fc619()) return consent_obj[process.env.DEPICT_TRACKING_CONSENT_LEVEL];
@@ -2527,12 +2530,12 @@ async function $2026711c6c2d6204$export$7a6d436e0782c6ed() {
2527
2530
  }
2528
2531
  function $2026711c6c2d6204$export$7e4427e80d5fc619() {
2529
2532
  if ($2026711c6c2d6204$var$cookie_ipns) return $2026711c6c2d6204$var$cookie_ipns;
2530
- $2026711c6c2d6204$var$cookie_ipns = (0, $9a42a570de51ea3d$export$e806c6c1615a59ae)();
2533
+ $2026711c6c2d6204$var$cookie_ipns = $9a42a570de51ea3d$export$e806c6c1615a59ae();
2531
2534
  const existing_consent = $2026711c6c2d6204$var$consent_from_cookie();
2532
2535
  if (existing_consent?.necessary)
2533
2536
  // If "necessary" isn't set, user hasn't actually given/withold consent yet.
2534
2537
  $2026711c6c2d6204$var$cookie_ipns(existing_consent);
2535
- window.addEventListener("consent.onetrust", (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(evt => {
2538
+ window.addEventListener("consent.onetrust", $268cbd9e4ade92db$export$b3bbfd758f11cfa9(evt => {
2536
2539
  const c = evt;
2537
2540
  // Cast because TS doesn't know about the forEach coming up
2538
2541
  const consent_obj = {};
@@ -2546,34 +2549,34 @@ function $2026711c6c2d6204$export$7e4427e80d5fc619() {
2546
2549
  }));
2547
2550
  return $2026711c6c2d6204$var$cookie_ipns;
2548
2551
  }
2549
- const $2026711c6c2d6204$export$f0f6c846d96fdbec = /*@__PURE__*/(0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(async (anon_id = "anonymous") => {
2550
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Initializing OptAnon tracking");
2551
- if (!$2026711c6c2d6204$var$required_consent_level) return (0, $e6c6e7929ea385ae$export$de56f1198d121036)("No consent level set for Depict tracking. Ignoring consent and tracking everything.");
2552
+ const $2026711c6c2d6204$export$f0f6c846d96fdbec = /*@__PURE__*/$268cbd9e4ade92db$export$b3bbfd758f11cfa9(async (anon_id = "anonymous") => {
2553
+ $e6c6e7929ea385ae$export$de56f1198d121036("Initializing OptAnon tracking");
2554
+ if (!$2026711c6c2d6204$var$required_consent_level) return $e6c6e7929ea385ae$export$de56f1198d121036("No consent level set for Depict tracking. Ignoring consent and tracking everything.");
2552
2555
  const original_get_depict_id = (0, $e0a87646d12cb987$export$6399bdb2291895e0);
2553
2556
  const original_get_user_id = (0, $e0a87646d12cb987$export$adc61a405a4cabed);
2554
- (0, $e0a87646d12cb987$export$336e7ad40bae0652)(() => $2026711c6c2d6204$var$has_consent ? original_get_depict_id() : anon_id);
2555
- (0, $e0a87646d12cb987$export$8a96793bf9f87d90)(() => $2026711c6c2d6204$var$has_consent ? original_get_user_id() : anon_id);
2557
+ $e0a87646d12cb987$export$336e7ad40bae0652(() => $2026711c6c2d6204$var$has_consent ? original_get_depict_id() : anon_id);
2558
+ $e0a87646d12cb987$export$8a96793bf9f87d90(() => $2026711c6c2d6204$var$has_consent ? original_get_user_id() : anon_id);
2556
2559
  for await (const consent_obj of $2026711c6c2d6204$export$7e4427e80d5fc619()) {
2557
2560
  // Changing this will change the return value of function given to set_depict_id_fn above
2558
2561
  $2026711c6c2d6204$var$has_consent = consent_obj[$2026711c6c2d6204$var$required_consent_level];
2559
- if (!$2026711c6c2d6204$var$has_consent) (0, $e6c6e7929ea385ae$export$de56f1198d121036)(`dsid/user_id will be set to, "${anon_id}", until Optanon has consent for "${$2026711c6c2d6204$var$required_consent_level}"`);else (0, $e6c6e7929ea385ae$export$de56f1198d121036)(`Optanon obtained consent for "${$2026711c6c2d6204$var$required_consent_level}", will use true dsid/user_id`);
2562
+ if (!$2026711c6c2d6204$var$has_consent) $e6c6e7929ea385ae$export$de56f1198d121036(`dsid/user_id will be set to, "${anon_id}", until Optanon has consent for "${$2026711c6c2d6204$var$required_consent_level}"`);else $e6c6e7929ea385ae$export$de56f1198d121036(`Optanon obtained consent for "${$2026711c6c2d6204$var$required_consent_level}", will use true dsid/user_id`);
2560
2563
  }
2561
2564
  });
2562
2565
  const $d3d8549954e0318e$var$g = typeof globalThis == "object" && globalThis || window;
2563
- const $d3d8549954e0318e$export$f3354ec2ce95ebd9 = /*@__PURE__*/(0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(async (GA_ID, strict) => {
2566
+ const $d3d8549954e0318e$export$f3354ec2ce95ebd9 = /*@__PURE__*/$268cbd9e4ade92db$export$b3bbfd758f11cfa9(async (GA_ID, strict) => {
2564
2567
  if (process.env.GTAG === "false") return;
2565
2568
  if (!GA_ID) {
2566
- (0, $e6c6e7929ea385ae$export$c2363754d4758444)("Couldn't load gtag, GA_ID not specified", GA_ID);
2569
+ $e6c6e7929ea385ae$export$c2363754d4758444("Couldn't load gtag, GA_ID not specified", GA_ID);
2567
2570
  return;
2568
2571
  }
2569
2572
  const required_consent_level = process.env.GTAG_LOADING_CONSENT_LEVEL;
2570
2573
  if (required_consent_level !== undefined) {
2571
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)(`GTag loading waiting for consent level ${required_consent_level}`);
2572
- const ipns = process.env.CONSENT_FRAMEWORK == "optanon" ? (0, $2026711c6c2d6204$export$7e4427e80d5fc619)() : (0, $28e42b0009d694b2$export$8827362e5e938d26)();
2574
+ $e6c6e7929ea385ae$export$de56f1198d121036(`GTag loading waiting for consent level ${required_consent_level}`);
2575
+ const ipns = process.env.CONSENT_FRAMEWORK == "optanon" ? $2026711c6c2d6204$export$7e4427e80d5fc619() : $28e42b0009d694b2$export$8827362e5e938d26();
2573
2576
  for await (const consent_status of ipns) {
2574
2577
  const status_for_level = consent_status[required_consent_level];
2575
2578
  if (status_for_level) {
2576
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("got consent for", required_consent_level, "loading gtag");
2579
+ $e6c6e7929ea385ae$export$de56f1198d121036("got consent for", required_consent_level, "loading gtag");
2577
2580
  break;
2578
2581
  }
2579
2582
  }
@@ -2583,13 +2586,13 @@ const $d3d8549954e0318e$export$f3354ec2ce95ebd9 = /*@__PURE__*/(0, $268cbd9e4ade
2583
2586
  const page_hasnt_loaded = $d3d8549954e0318e$var$g?.performance?.getEntriesByType?.("navigation")?.every?.(e => e?.loadEventEnd) === false;
2584
2587
  // Source: comment on https://stackoverflow.com/a/53525488
2585
2588
  // don't use readyState, source: personal experience and comment on https://stackoverflow.com/a/28093606
2586
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Loading gtag after " + (page_hasnt_loaded ? "pageload and " : "") + "3s" + (strict ? "" : ", but setting up queues already"));
2589
+ $e6c6e7929ea385ae$export$de56f1198d121036("Loading gtag after " + (page_hasnt_loaded ? "pageload and " : "") + "3s" + (strict ? "" : ", but setting up queues already"));
2587
2590
  if (!strict) $d3d8549954e0318e$export$d031e55ccd4c52dc(GA_ID);
2588
2591
  if (page_hasnt_loaded) {
2589
2592
  const load_event = await new Promise(r => window.addEventListener("load", r, {
2590
2593
  once: true
2591
2594
  }));
2592
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("page has loaded", load_event);
2595
+ $e6c6e7929ea385ae$export$de56f1198d121036("page has loaded", load_event);
2593
2596
  }
2594
2597
  await new Promise(r => setTimeout(r, 3000));
2595
2598
  const script = document.createElement("script"),
@@ -2597,9 +2600,9 @@ const $d3d8549954e0318e$export$f3354ec2ce95ebd9 = /*@__PURE__*/(0, $268cbd9e4ade
2597
2600
  script.async = true;
2598
2601
  script.src = "https://www.googletagmanager.com/gtag/js?id=" + GA_ID;
2599
2602
  head.appendChild(script);
2600
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Loading gtag now", script);
2603
+ $e6c6e7929ea385ae$export$de56f1198d121036("Loading gtag now", script);
2601
2604
  });
2602
- const $d3d8549954e0318e$export$d031e55ccd4c52dc = /*@__PURE__*/(0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(GA_ID => {
2605
+ const $d3d8549954e0318e$export$d031e55ccd4c52dc = /*@__PURE__*/$268cbd9e4ade92db$export$b3bbfd758f11cfa9(GA_ID => {
2603
2606
  if (process.env.GTAG === "false") return;
2604
2607
  $d3d8549954e0318e$var$g.dataLayer ||= [];
2605
2608
  function gtag() {
@@ -2610,9 +2613,9 @@ const $d3d8549954e0318e$export$d031e55ccd4c52dc = /*@__PURE__*/(0, $268cbd9e4ade
2610
2613
  $d3d8549954e0318e$var$g.gtag("config", GA_ID, {
2611
2614
  "send_page_view": false
2612
2615
  });
2613
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("configuring gtag with", GA_ID);
2616
+ $e6c6e7929ea385ae$export$de56f1198d121036("configuring gtag with", GA_ID);
2614
2617
  });
2615
- const $d3d8549954e0318e$export$7babcd5d4056b2ca = /*@__PURE__*/(0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(async (raw_displays, get_product_id, more) => {
2618
+ const $d3d8549954e0318e$export$7babcd5d4056b2ca = /*@__PURE__*/$268cbd9e4ade92db$export$b3bbfd758f11cfa9(async (raw_displays, get_product_id, more) => {
2616
2619
  const displays = raw_displays; // gtag tracking is "obsolete" and we don't expect any customers using something else than LegacyDisplay to use it
2617
2620
  if (process.env.GTAG === "false") return;
2618
2621
  if (process.env.GTAG_VIEW === "false") return;
@@ -2634,12 +2637,12 @@ const $d3d8549954e0318e$export$7babcd5d4056b2ca = /*@__PURE__*/(0, $268cbd9e4ade
2634
2637
  const gtag_args = ["event", "view_item_list", {
2635
2638
  "items": gtag_items.slice(i, i + max_products_per_request)
2636
2639
  }];
2637
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Sending product view to gtag", gtag_args);
2640
+ $e6c6e7929ea385ae$export$de56f1198d121036("Sending product view to gtag", gtag_args);
2638
2641
  $d3d8549954e0318e$var$g.gtag(...gtag_args);
2639
2642
  }
2640
- } else (0, $e6c6e7929ea385ae$export$c2363754d4758444)("not sending gtag tracking as there is no gtag");
2643
+ } else $e6c6e7929ea385ae$export$c2363754d4758444("not sending gtag tracking as there is no gtag");
2641
2644
  });
2642
- const $d3d8549954e0318e$export$f522672c9379e339 = /*@__PURE__*/(0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(async (product_id, index, more) => {
2645
+ const $d3d8549954e0318e$export$f522672c9379e339 = /*@__PURE__*/$268cbd9e4ade92db$export$b3bbfd758f11cfa9(async (product_id, index, more) => {
2643
2646
  if (process.env.GTAG === "false") return;
2644
2647
  if (process.env.GTAG_EVENT_CONSENT_LEVEL !== undefined && !(await $d3d8549954e0318e$var$can_send_gtag_events(product_id, index, more))) return;
2645
2648
  if (typeof $d3d8549954e0318e$var$g.gtag == "function") {
@@ -2652,17 +2655,17 @@ const $d3d8549954e0318e$export$f522672c9379e339 = /*@__PURE__*/(0, $268cbd9e4ade
2652
2655
  ...more
2653
2656
  }]
2654
2657
  }];
2655
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("calling gtag with arguments", gtag_args);
2658
+ $e6c6e7929ea385ae$export$de56f1198d121036("calling gtag with arguments", gtag_args);
2656
2659
  return $d3d8549954e0318e$var$g.gtag(...gtag_args);
2657
- } else (0, $e6c6e7929ea385ae$export$c2363754d4758444)("not sending gtag tracking as there is no gtag");
2660
+ } else $e6c6e7929ea385ae$export$c2363754d4758444("not sending gtag tracking as there is no gtag");
2658
2661
  });
2659
- const $d3d8549954e0318e$export$f75172d2e289cd02 = /*@__PURE__*/(0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(action => {
2662
+ const $d3d8549954e0318e$export$f75172d2e289cd02 = /*@__PURE__*/$268cbd9e4ade92db$export$b3bbfd758f11cfa9(action => {
2660
2663
  if (process.env.GA === "false") return;
2661
2664
  if (typeof $d3d8549954e0318e$var$g.ga != "function") {
2662
- (0, $e6c6e7929ea385ae$export$c2363754d4758444)("Not sending to ga as there is no ga");
2665
+ $e6c6e7929ea385ae$export$c2363754d4758444("Not sending to ga as there is no ga");
2663
2666
  return;
2664
2667
  }
2665
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("sending", action, "to GA");
2668
+ $e6c6e7929ea385ae$export$de56f1198d121036("sending", action, "to GA");
2666
2669
  return $d3d8549954e0318e$var$g.ga("depict.send", {
2667
2670
  hitType: "event",
2668
2671
  eventCategory: "Depict",
@@ -2671,35 +2674,35 @@ const $d3d8549954e0318e$export$f75172d2e289cd02 = /*@__PURE__*/(0, $268cbd9e4ade
2671
2674
  nonInteraction: 1
2672
2675
  });
2673
2676
  });
2674
- const $d3d8549954e0318e$export$ac7296527cb52311 = /*@__PURE__*/(0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(GAID => {
2677
+ const $d3d8549954e0318e$export$ac7296527cb52311 = /*@__PURE__*/$268cbd9e4ade92db$export$b3bbfd758f11cfa9(GAID => {
2675
2678
  if (process.env.GA === "false") return;
2676
2679
  if (!GAID) {
2677
- (0, $e6c6e7929ea385ae$export$c2363754d4758444)(new Error("No GAID specified"));
2680
+ $e6c6e7929ea385ae$export$c2363754d4758444(new Error("No GAID specified"));
2678
2681
  return;
2679
2682
  }
2680
2683
  if (typeof $d3d8549954e0318e$var$g.ga != "function") {
2681
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Creating GA queue");
2682
- (0, $c18ce8dadd041cdd$export$674d8cd8b6868154)();
2684
+ $e6c6e7929ea385ae$export$de56f1198d121036("Creating GA queue");
2685
+ $c18ce8dadd041cdd$export$674d8cd8b6868154();
2683
2686
  }
2684
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Creating ga with GA-ID", GAID);
2687
+ $e6c6e7929ea385ae$export$de56f1198d121036("Creating ga with GA-ID", GAID);
2685
2688
  $d3d8549954e0318e$var$g.ga("create", GAID, "auto", "depict");
2686
2689
  $d3d8549954e0318e$export$f3354ec2ce95ebd9(GAID, false);
2687
2690
  });
2688
- const $d3d8549954e0318e$export$127751e82111fcf = /*@__PURE__*/(0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(() => $d3d8549954e0318e$export$f75172d2e289cd02("rec_bar_click"));
2689
- const $d3d8549954e0318e$export$bf205937e5e012cb = /*@__PURE__*/(0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(() => $d3d8549954e0318e$export$f75172d2e289cd02("add_to_cart_after_rec_bar_click"));
2691
+ const $d3d8549954e0318e$export$127751e82111fcf = /*@__PURE__*/$268cbd9e4ade92db$export$b3bbfd758f11cfa9(() => $d3d8549954e0318e$export$f75172d2e289cd02("rec_bar_click"));
2692
+ const $d3d8549954e0318e$export$bf205937e5e012cb = /*@__PURE__*/$268cbd9e4ade92db$export$b3bbfd758f11cfa9(() => $d3d8549954e0318e$export$f75172d2e289cd02("add_to_cart_after_rec_bar_click"));
2690
2693
  async function $d3d8549954e0318e$var$can_send_gtag_events(...stuff_to_log) {
2691
2694
  const required_consent_level = process.env.GTAG_LOADING_CONSENT_LEVEL;
2692
2695
  if (required_consent_level !== undefined) return true; // just in case
2693
- const ipns = process.env.CONSENT_FRAMEWORK == "optanon" ? (0, $2026711c6c2d6204$export$7e4427e80d5fc619)() : (0, $28e42b0009d694b2$export$8827362e5e938d26)();
2696
+ const ipns = process.env.CONSENT_FRAMEWORK == "optanon" ? $2026711c6c2d6204$export$7e4427e80d5fc619() : $28e42b0009d694b2$export$8827362e5e938d26();
2694
2697
  for await (const consent_obj of ipns) {
2695
2698
  const can_send = consent_obj[required_consent_level];
2696
- if (!can_send) (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Got no consent for", required_consent_level, "not sending gtag event for", ...stuff_to_log);
2699
+ if (!can_send) $e6c6e7929ea385ae$export$de56f1198d121036("Got no consent for", required_consent_level, "not sending gtag event for", ...stuff_to_log);
2697
2700
  return can_send;
2698
2701
  }
2699
2702
  }
2700
2703
  let $e4bebbfa0f0b1454$var$existing_style_tag;
2701
2704
  let $e4bebbfa0f0b1454$var$reactions_in_last_s = 0;
2702
- const $e4bebbfa0f0b1454$export$59ba1eb2c083f0cd = /*@__PURE__*/(0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(async css => {
2705
+ const $e4bebbfa0f0b1454$export$59ba1eb2c083f0cd = /*@__PURE__*/$268cbd9e4ade92db$export$b3bbfd758f11cfa9(async css => {
2703
2706
  const style_tag = await ($e4bebbfa0f0b1454$var$existing_style_tag ||= (0, $2a1cbc63a04d4a2d$export$b6ae1bc530f4c149).wait_for_element("head").then(head => {
2704
2707
  const tag = document.createElement("style");
2705
2708
  (0, $2a1cbc63a04d4a2d$export$b6ae1bc530f4c149).onremoved(
@@ -2709,16 +2712,16 @@ const $e4bebbfa0f0b1454$export$59ba1eb2c083f0cd = /*@__PURE__*/(0, $268cbd9e4ade
2709
2712
  // just make sure to not freak out if it's already been added again
2710
2713
  return;
2711
2714
  if ($e4bebbfa0f0b1454$var$reactions_in_last_s >= 10) {
2712
- (0, $268cbd9e4ade92db$export$f18d5b0af29128b7)(new Error("Someone removed our styling but insists on it (10 removals in previous second). Giving up \uD83D\uDE2B"), "error");
2715
+ $268cbd9e4ade92db$export$f18d5b0af29128b7(new Error("Someone removed our styling but insists on it (10 removals in previous second). Giving up \uD83D\uDE2B"), "error");
2713
2716
  return;
2714
2717
  }
2715
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Someone removed our styling \uD83D\uDE24, reinserting", eoe);
2718
+ $e6c6e7929ea385ae$export$de56f1198d121036("Someone removed our styling \uD83D\uDE24, reinserting", eoe);
2716
2719
  $e4bebbfa0f0b1454$var$reactions_in_last_s++;
2717
2720
  setTimeout(() => $e4bebbfa0f0b1454$var$reactions_in_last_s--, 1000);
2718
2721
  document.head.append(tag); // we're sure that head exists now since we inserted it there previously
2719
2722
  });
2720
2723
 
2721
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("inserting", tag, "into", head);
2724
+ $e6c6e7929ea385ae$export$de56f1198d121036("inserting", tag, "into", head);
2722
2725
  return head.appendChild(tag);
2723
2726
  }));
2724
2727
  style_tag.append(css);
@@ -2726,10 +2729,10 @@ const $e4bebbfa0f0b1454$export$59ba1eb2c083f0cd = /*@__PURE__*/(0, $268cbd9e4ade
2726
2729
  const $e4bebbfa0f0b1454$export$a96c18473f2af463 = (tenant, selector, validator) => {
2727
2730
  return (0, $2a1cbc63a04d4a2d$export$b6ae1bc530f4c149).onexists(selector, ({
2728
2731
  element: element
2729
- }) => (0, $c8263a2185830bf1$export$2c34560c3749dc63)(element, tenant.get_product_id, (p_id, r_id, was_unmatching, event) => {
2732
+ }) => $c8263a2185830bf1$export$2c34560c3749dc63(element, tenant.get_product_id, (p_id, r_id, was_unmatching, event) => {
2730
2733
  if (typeof validator === "function" && !validator(event)) return;
2731
- if (!was_unmatching) (0, $d3d8549954e0318e$export$bf205937e5e012cb)();
2732
- (0, $e0a87646d12cb987$export$9028351cb994757e)({
2734
+ if (!was_unmatching) $d3d8549954e0318e$export$bf205937e5e012cb();
2735
+ $e0a87646d12cb987$export$9028351cb994757e({
2733
2736
  ...tenant,
2734
2737
  product_id: p_id,
2735
2738
  ...(was_unmatching ? {
@@ -2744,11 +2747,11 @@ const $e4bebbfa0f0b1454$export$a4f97b27a0592e6c = url => (url ? new URL(url, win
2744
2747
  const $e4bebbfa0f0b1454$export$692b606677218a16 = callback => {
2745
2748
  if (document.depictwashere) {
2746
2749
  if (process.env.BUILD_TARGET === "dev") {
2747
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("HMR tried to rerun us, reloading page");
2750
+ $e6c6e7929ea385ae$export$de56f1198d121036("HMR tried to rerun us, reloading page");
2748
2751
  /* eslint-disable no-self-assign */
2749
2752
  location.href = location.href;
2750
2753
  }
2751
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Script has already ran", document.currentScript, "is exiting");
2754
+ $e6c6e7929ea385ae$export$de56f1198d121036("Script has already ran", document.currentScript, "is exiting");
2752
2755
  return;
2753
2756
  }
2754
2757
  if (process.env.BUILD_TARGET === "dev") /* eslint-disable no-console */console.clear = new Proxy(console.clear, {
@@ -2770,26 +2773,26 @@ function $e4bebbfa0f0b1454$export$328e81c44cddf3c0(callback, get_market, support
2770
2773
  let localstorage_override;
2771
2774
  const query_param_override = new URLSearchParams(location.search).get("depict-override-market");
2772
2775
  if (query_param_override !== null) {
2773
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)(`Found ?depict-override-market=${query_param_override}. Using that as the market`);
2776
+ $e6c6e7929ea385ae$export$de56f1198d121036(`Found ?depict-override-market=${query_param_override}. Using that as the market`);
2774
2777
  get_market = () => query_param_override;
2775
2778
  localStorage.setItem("depict-override-market", query_param_override);
2776
2779
  } else if ((localstorage_override = localStorage.getItem("depict-override-market")) !== null) {
2777
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)(`Found depict-override-market="${localstorage_override}" in localStorage. Using that as the market`);
2780
+ $e6c6e7929ea385ae$export$de56f1198d121036(`Found depict-override-market="${localstorage_override}" in localStorage. Using that as the market`);
2778
2781
  get_market = () => localstorage_override;
2779
2782
  }
2780
2783
  }
2781
2784
  const market = await get_market();
2782
2785
  if (supported_markets.includes(market)) {
2783
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)(`Initializing with market: ${market}`);
2786
+ $e6c6e7929ea385ae$export$de56f1198d121036(`Initializing with market: ${market}`);
2784
2787
  return callback(market).catch((0, $548fd58b14b25a52$export$8048b892d651b310));
2785
2788
  } else if (unsupported_markets.includes(market)) {
2786
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)(`Unsupported market: ${market}. Exiting...`);
2789
+ $e6c6e7929ea385ae$export$de56f1198d121036(`Unsupported market: ${market}. Exiting...`);
2787
2790
  return;
2788
2791
  } else if (process.env.DEBUG === "true" && location.host.endsWith(".demo.depict.ai") && preferred_demo_market) {
2789
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)(`On demosite with default market override. Setting market to ${preferred_demo_market}`);
2792
+ $e6c6e7929ea385ae$export$de56f1198d121036(`On demosite with default market override. Setting market to ${preferred_demo_market}`);
2790
2793
  return callback(preferred_demo_market).catch((0, $548fd58b14b25a52$export$8048b892d651b310));
2791
2794
  } else {
2792
- (0, $548fd58b14b25a52$export$8048b892d651b310)(new Error(`Unknown market: "${market}". Exiting...`));
2795
+ $548fd58b14b25a52$export$8048b892d651b310(new Error(`Unknown market: "${market}". Exiting...`));
2793
2796
  return;
2794
2797
  }
2795
2798
  });
@@ -2809,9 +2812,9 @@ class $16f3a26cfac77a4c$export$8d42ce4827f43582 {
2809
2812
  this.TYPE = options.TYPE || "normal";
2810
2813
  this.catchify = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9);
2811
2814
  this.err = (0, $548fd58b14b25a52$export$8048b892d651b310);
2812
- if (this.GA_ID) (0, $d3d8549954e0318e$export$ac7296527cb52311)(this.GA_ID);
2815
+ if (this.GA_ID) $d3d8549954e0318e$export$ac7296527cb52311(this.GA_ID);
2813
2816
  // https://gitlab.com/depict-ai/depict.ai/-/merge_requests/2318#note_927887712
2814
- this.get_product_id = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)((...args) => {
2817
+ this.get_product_id = $268cbd9e4ade92db$export$b3bbfd758f11cfa9((...args) => {
2815
2818
  const id = options.get_product_id(...args);
2816
2819
  if (id instanceof Promise) return id.then(id => id || "");
2817
2820
  return id || "";
@@ -2823,9 +2826,9 @@ class $16f3a26cfac77a4c$export$8d42ce4827f43582 {
2823
2826
  this.type = this.TYPE;
2824
2827
  this.catchify = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9);
2825
2828
  this.err = (0, $548fd58b14b25a52$export$8048b892d651b310);
2826
- if (localStorage.getItem("highlight-depict") === "true") (0, $e4bebbfa0f0b1454$export$59ba1eb2c083f0cd)(".depict { background: #f00a !important; }");
2829
+ if (localStorage.getItem("highlight-depict") === "true") $e4bebbfa0f0b1454$export$59ba1eb2c083f0cd(".depict { background: #f00a !important; }");
2827
2830
  if (options.pageview_tracking ?? true) (async () => {
2828
- (0, $72ee205b59322497$export$f7cb1bd47199ec38)({
2831
+ $72ee205b59322497$export$f7cb1bd47199ec38({
2829
2832
  market: this.market,
2830
2833
  tenant: this.tenant,
2831
2834
  get_product_id: this.get_product_id
@@ -2840,7 +2843,7 @@ const $fbb09973782881cb$var$default_get_rec_id = elem => elem?.dataset?.depict_r
2840
2843
  const $fbb09973782881cb$var$default_get_prod_id = elem => elem?.dataset?.depict_product_id || elem?.dataset?.productId;
2841
2844
  const $fbb09973782881cb$var$default_get_ga_prod_id = elem => elem?.dataset?.ga_ids;
2842
2845
  const $fbb09973782881cb$var$get_index_in_children_of_el = el => [...(el?.parentElement?.children || [])].indexOf(el);
2843
- const $fbb09973782881cb$export$29a6094e0bd8bc5f = /*@__PURE__*/(0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(async (options, gtag_options) => {
2846
+ const $fbb09973782881cb$export$29a6094e0bd8bc5f = /*@__PURE__*/$268cbd9e4ade92db$export$b3bbfd758f11cfa9(async (options, gtag_options) => {
2844
2847
  const {
2845
2848
  product_selector: product_selector,
2846
2849
  a2c_selector: a2c_selector,
@@ -2872,14 +2875,14 @@ const $fbb09973782881cb$export$29a6094e0bd8bc5f = /*@__PURE__*/(0, $268cbd9e4ade
2872
2875
  const gtag_view_product_ids = {};
2873
2876
  // Page view
2874
2877
  if (t instanceof (0, $16f3a26cfac77a4c$export$8d42ce4827f43582)) (async () => {
2875
- (0, $72ee205b59322497$export$eee4c4d924348b05)({
2878
+ $72ee205b59322497$export$eee4c4d924348b05({
2876
2879
  tenant: t.tenant,
2877
2880
  market: t.market,
2878
2881
  product_id: await t.get_product_id()
2879
2882
  });
2880
2883
  })();
2881
2884
  // Product card
2882
- const add_tracking_to_product_card = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(async ({
2885
+ const add_tracking_to_product_card = $268cbd9e4ade92db$export$b3bbfd758f11cfa9(async ({
2883
2886
  element: elem
2884
2887
  }) => {
2885
2888
  const index = $fbb09973782881cb$var$get_index_in_children_of_el(elem);
@@ -2889,7 +2892,7 @@ const $fbb09973782881cb$export$29a6094e0bd8bc5f = /*@__PURE__*/(0, $268cbd9e4ade
2889
2892
  // Impression tracking
2890
2893
  if (impression_tracking && !impression_tracked_els.has(elem)) {
2891
2894
  impression_tracked_els.add(elem);
2892
- (0, $8e19f8200d357fe7$export$37125ccc5dd98050)({
2895
+ $8e19f8200d357fe7$export$37125ccc5dd98050({
2893
2896
  element: elem,
2894
2897
  data: {
2895
2898
  recommendation_id: data.recommendation_id,
@@ -2921,12 +2924,12 @@ const $fbb09973782881cb$export$29a6094e0bd8bc5f = /*@__PURE__*/(0, $268cbd9e4ade
2921
2924
  index: index
2922
2925
  })));
2923
2926
  } catch (e) {
2924
- (0, $e6c6e7929ea385ae$export$c2363754d4758444)("Something went wrong on a product with multiple ga_ids", e);
2927
+ $e6c6e7929ea385ae$export$c2363754d4758444("Something went wrong on a product with multiple ga_ids", e);
2925
2928
  }
2926
2929
  }
2927
2930
  if (typeof BroadcastChannel == "function") {
2928
2931
  // right click and mouse wheel click tracking
2929
- const handler = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(e => (0, $44909e19109bf973$export$8f66c4c7fb96eda2)(e, data.product_id));
2932
+ const handler = $268cbd9e4ade92db$export$b3bbfd758f11cfa9(e => $44909e19109bf973$export$8f66c4c7fb96eda2(e, data.product_id));
2930
2933
  elem.addEventListener("contextmenu", handler);
2931
2934
  elem.addEventListener("auxclick", e => e.button === 1 && handler(e)); // actual wheel click - some mouses / OS:es also dispatch auxclick on rightclick
2932
2935
  }
@@ -2934,14 +2937,14 @@ const $fbb09973782881cb$export$29a6094e0bd8bc5f = /*@__PURE__*/(0, $268cbd9e4ade
2934
2937
  click_tracking: {
2935
2938
  if (click_tracked_els.has(elem)) break click_tracking;
2936
2939
  click_tracked_els.add(elem);
2937
- elem.addEventListener("click", (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(() => {
2940
+ elem.addEventListener("click", $268cbd9e4ade92db$export$b3bbfd758f11cfa9(() => {
2938
2941
  const product_id = data.product_id || "DNT";
2939
2942
  const recommendation_id = data.recommendation_id || "not_depict";
2940
2943
  localStorage.setItem(`depict_attribution_${product_id}`, recommendation_id);
2941
2944
  const index = $fbb09973782881cb$var$get_index_in_children_of_el(elem);
2942
2945
  const click_location = prefix + (index + 1);
2943
- (0, $d3d8549954e0318e$export$127751e82111fcf)();
2944
- (0, $e0a87646d12cb987$export$15f8a0cd5a8c0ebb)({
2946
+ $d3d8549954e0318e$export$127751e82111fcf();
2947
+ $e0a87646d12cb987$export$15f8a0cd5a8c0ebb({
2945
2948
  ...(options.t || {}),
2946
2949
  ...options,
2947
2950
  ...data,
@@ -2955,15 +2958,15 @@ const $fbb09973782881cb$export$29a6094e0bd8bc5f = /*@__PURE__*/(0, $268cbd9e4ade
2955
2958
  list_name: gtag_list_name,
2956
2959
  ...gtag_options
2957
2960
  };
2958
- (0, $d3d8549954e0318e$export$f522672c9379e339)(data.product_id, index, gtag_options_with_click_location);
2961
+ $d3d8549954e0318e$export$f522672c9379e339(data.product_id, index, gtag_options_with_click_location);
2959
2962
  try {
2960
2963
  const to_iterate = [];
2961
2964
  if (data.ga_product_id) to_iterate.push(...(data.ga_product_id.toString?.().split(",") ?? []));
2962
2965
  to_iterate.push(...(data.ga_product_ids || []));
2963
- to_iterate.forEach(id => (0, $d3d8549954e0318e$export$f522672c9379e339)(id, index, gtag_options_with_click_location));
2966
+ to_iterate.forEach(id => $d3d8549954e0318e$export$f522672c9379e339(id, index, gtag_options_with_click_location));
2964
2967
  } catch (e) {
2965
- (0, $e6c6e7929ea385ae$export$c2363754d4758444)("Something went wrong when sending gtag click tracking on a product with multiple ga_ids");
2966
- (0, $268cbd9e4ade92db$export$f18d5b0af29128b7)(e, "error");
2968
+ $e6c6e7929ea385ae$export$c2363754d4758444("Something went wrong when sending gtag click tracking on a product with multiple ga_ids");
2969
+ $268cbd9e4ade92db$export$f18d5b0af29128b7(e, "error");
2967
2970
  }
2968
2971
  }
2969
2972
  }), {
@@ -2993,8 +2996,8 @@ const $fbb09973782881cb$export$29a6094e0bd8bc5f = /*@__PURE__*/(0, $268cbd9e4ade
2993
2996
  });
2994
2997
  element.dispatchEvent(click);
2995
2998
  }
2996
- (0, $d3d8549954e0318e$export$bf205937e5e012cb)();
2997
- (0, $e0a87646d12cb987$export$9028351cb994757e)({
2999
+ $d3d8549954e0318e$export$bf205937e5e012cb();
3000
+ $e0a87646d12cb987$export$9028351cb994757e({
2998
3001
  ...(options.t || {}),
2999
3002
  ...options,
3000
3003
  ...data
@@ -3007,11 +3010,11 @@ const $fbb09973782881cb$export$29a6094e0bd8bc5f = /*@__PURE__*/(0, $268cbd9e4ade
3007
3010
  if (options.shade) $fbb09973782881cb$export$6ebd242c09192cec(elem);
3008
3011
  if (options.attempt_gtag_view_tracking && Object.keys(gtag_view_product_ids)?.length)
3009
3012
  // setTimeout to batch the requests / put it all into one gtag view event
3010
- setTimeout((0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(() => {
3013
+ setTimeout($268cbd9e4ade92db$export$b3bbfd758f11cfa9(() => {
3011
3014
  for (const key in gtag_view_product_ids) {
3012
3015
  const product_ids = gtag_view_product_ids[key];
3013
3016
  if (product_ids?.length) {
3014
- (0, $d3d8549954e0318e$export$7babcd5d4056b2ca)(product_ids, () => "", {
3017
+ $d3d8549954e0318e$export$7babcd5d4056b2ca(product_ids, () => "", {
3015
3018
  list_name: key,
3016
3019
  ...gtag_options
3017
3020
  });
@@ -3022,14 +3025,14 @@ const $fbb09973782881cb$export$29a6094e0bd8bc5f = /*@__PURE__*/(0, $268cbd9e4ade
3022
3025
  });
3023
3026
  if (typeof product_selector == "string") (0, $2a1cbc63a04d4a2d$export$b6ae1bc530f4c149).onexists(product_selector, add_tracking_to_product_card);else if (product_elements && typeof product_elements?.[Symbol.iterator] == "function") for (const element of product_elements) add_tracking_to_product_card({
3024
3027
  element: element
3025
- });else (0, $e6c6e7929ea385ae$export$c2363754d4758444)(new Error("AIO can't find elements, try adding a selector or els")); // don't throw so that a2c tracking keeps working
3028
+ });else $e6c6e7929ea385ae$export$c2363754d4758444(new Error("AIO can't find elements, try adding a selector or els")); // don't throw so that a2c tracking keeps working
3026
3029
  // Page A2C button tracking
3027
3030
  const a2c_handler = ({
3028
3031
  element: element
3029
3032
  }) => {
3030
- (0, $c8263a2185830bf1$export$2c34560c3749dc63)(element, get_product_id, (product_id, recommendation_id, was_unmatching) => {
3031
- if (!was_unmatching) (0, $d3d8549954e0318e$export$bf205937e5e012cb)();
3032
- (0, $e0a87646d12cb987$export$9028351cb994757e)({
3033
+ $c8263a2185830bf1$export$2c34560c3749dc63(element, get_product_id, (product_id, recommendation_id, was_unmatching) => {
3034
+ if (!was_unmatching) $d3d8549954e0318e$export$bf205937e5e012cb();
3035
+ $e0a87646d12cb987$export$9028351cb994757e({
3033
3036
  ...(options.t || {}),
3034
3037
  ...options,
3035
3038
  product_id: product_id,
@@ -3044,7 +3047,7 @@ const $fbb09973782881cb$export$29a6094e0bd8bc5f = /*@__PURE__*/(0, $268cbd9e4ade
3044
3047
  };
3045
3048
  if (typeof a2c_selector == "string") (0, $2a1cbc63a04d4a2d$export$b6ae1bc530f4c149).onexists(a2c_selector, a2c_handler);else if (a2c_elements && typeof a2c_elements?.[Symbol.iterator] == "function") for (const element of a2c_elements) a2c_handler({
3046
3049
  element: element
3047
- });else (0, $e6c6e7929ea385ae$export$c2363754d4758444)(new Error("Can't find a2c button, try adding a selector or els"));
3050
+ });else $e6c6e7929ea385ae$export$c2363754d4758444(new Error("Can't find a2c button, try adding a selector or els"));
3048
3051
  return {
3049
3052
  add_a2c_element: element => a2c_handler({
3050
3053
  element: element
@@ -3054,7 +3057,7 @@ const $fbb09973782881cb$export$29a6094e0bd8bc5f = /*@__PURE__*/(0, $268cbd9e4ade
3054
3057
  })
3055
3058
  };
3056
3059
  });
3057
- const $fbb09973782881cb$export$6ebd242c09192cec = /*@__PURE__*/(0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(element => {
3060
+ const $fbb09973782881cb$export$6ebd242c09192cec = /*@__PURE__*/$268cbd9e4ade92db$export$b3bbfd758f11cfa9(element => {
3058
3061
  element.style.boxShadow = "rgba(255,0,0,0.5) 10px 10px 30px 40px";
3059
3062
  element.style.background = "rgba(255,0,0,0.5)";
3060
3063
  element.style.color = "white";
@@ -3099,18 +3102,18 @@ async function $d2fc3fb450961938$export$bcd70d5ed1cf6313(url, options, max_retri
3099
3102
  const response = await fetch(url, options);
3100
3103
  if (!response || !response.ok || response.status !== 200) {
3101
3104
  if (response.status === 422) {
3102
- (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)($d2fc3fb450961938$var$send_sentry_422)(response, options?.body || {}, stack);
3105
+ $268cbd9e4ade92db$export$b3bbfd758f11cfa9($d2fc3fb450961938$var$send_sentry_422)(response, options?.body || {}, stack);
3103
3106
  has_succeeded = true;
3104
3107
  } else if (response.status === 404) has_succeeded = true;
3105
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Response not ok", response);
3108
+ $e6c6e7929ea385ae$export$de56f1198d121036("Response not ok", response);
3106
3109
  } else has_succeeded = true;
3107
3110
  result = response;
3108
3111
  } catch (error) {
3109
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Error while fetching: ", error, url, options);
3112
+ $e6c6e7929ea385ae$export$de56f1198d121036("Error while fetching: ", error, url, options);
3110
3113
  // Don't retry CORS
3111
3114
  if (error.message.includes("CORS") && error.name.includes("CORS")) has_succeeded = true;
3112
3115
  } finally {
3113
- if (!has_succeeded) await (0, $55769f63ea4d8da4$export$5c069c93d2b7493f)(try_again_in_ms);
3116
+ if (!has_succeeded) await $55769f63ea4d8da4$export$5c069c93d2b7493f(try_again_in_ms);
3114
3117
  try_again_in_ms = calculate_retry(try_again_in_ms);
3115
3118
  max_retries -= 1;
3116
3119
  }
@@ -3119,12 +3122,12 @@ async function $d2fc3fb450961938$export$bcd70d5ed1cf6313(url, options, max_retri
3119
3122
  async function $d2fc3fb450961938$var$send_sentry_422(response, body, stack) {
3120
3123
  const msg = `Validation error: got 422 from API`;
3121
3124
  const text = await response.clone().text();
3122
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)(msg, "body", body, "response", response, "text", text, "stack", stack);
3125
+ $e6c6e7929ea385ae$export$de56f1198d121036(msg, "body", body, "response", response, "text", text, "stack", stack);
3123
3126
  (0, $61a34358bf0d3d8b$export$af2e17a20c2ea3c5).withScope(function (scope) {
3124
3127
  scope.setExtra("stack", stack);
3125
3128
  scope.setExtra("request_body", body);
3126
3129
  scope.setExtra("response", response);
3127
- scope.setExtra("serialized_response", (0, $45e05ec4fd7f1ee7$export$39d526a1194b6499)(response));
3130
+ scope.setExtra("serialized_response", $45e05ec4fd7f1ee7$export$39d526a1194b6499(response));
3128
3131
  scope.setExtra("response_text", text);
3129
3132
  scope.setLevel("error");
3130
3133
  this.captureException(new Error(msg));
@@ -3135,8 +3138,8 @@ async function $94edfb6d9c42a288$export$1bc0df10745d5412(t, options, headers, ge
3135
3138
  return res?.displays || [];
3136
3139
  }
3137
3140
  async function $94edfb6d9c42a288$export$d40679eb4cf32f09(t, options, headers, get_url = $94edfb6d9c42a288$var$default_get_fetch_url) {
3138
- const dsid = (0, $e0a87646d12cb987$export$6399bdb2291895e0)();
3139
- const session_id = options.session_id || (0, $e0a87646d12cb987$export$61e7e1f11e96692f)();
3141
+ const dsid = $e0a87646d12cb987$export$6399bdb2291895e0();
3142
+ const session_id = options.session_id || $e0a87646d12cb987$export$61e7e1f11e96692f();
3140
3143
  const user_id = options.user_id || dsid;
3141
3144
  const body = {
3142
3145
  tenant: t.tenant,
@@ -3148,17 +3151,17 @@ async function $94edfb6d9c42a288$export$d40679eb4cf32f09(t, options, headers, ge
3148
3151
  ...options
3149
3152
  };
3150
3153
  const endpoint = $94edfb6d9c42a288$var$get_fetch_endpoint_from_options(options);
3151
- return await (0, $d2fc3fb450961938$export$bcd70d5ed1cf6313)(get_url(endpoint), {
3154
+ return await $d2fc3fb450961938$export$bcd70d5ed1cf6313(get_url(endpoint), {
3152
3155
  body: JSON.stringify(body),
3153
3156
  ...(headers ? {
3154
3157
  headers: headers
3155
3158
  } : {}),
3156
3159
  method: "POST"
3157
3160
  }) // @ts-ignore
3158
- .then(r => r.json()).catch(e => (0, $e6c6e7929ea385ae$export$de56f1198d121036)("fetch_retry threw", e));
3161
+ .then(r => r.json()).catch(e => $e6c6e7929ea385ae$export$de56f1198d121036("fetch_retry threw", e));
3159
3162
  }
3160
3163
  function $94edfb6d9c42a288$var$default_get_fetch_url(type) {
3161
- return (0, $e4a18bf12ad092d9$export$fe609f0216e4ebef)(`${(0, $4c6861fbcd3a0611$export$362abebb4b313340)}/v2/recommend/products/${type}`);
3164
+ return $e4a18bf12ad092d9$export$fe609f0216e4ebef(`${(0, $4c6861fbcd3a0611$export$362abebb4b313340)}/v2/recommend/products/${type}`);
3162
3165
  }
3163
3166
  function $94edfb6d9c42a288$var$get_fetch_endpoint_from_options(options) {
3164
3167
  if (options["category_id"] !== undefined) return "category";else if (options["product_id"] !== undefined) return "product";else if (options["product_ids"] !== undefined) return "products";
@@ -3172,7 +3175,7 @@ async function $558ccd2de887e6d9$export$a9fc160c5ed83bd7(t, rendering_options) {
3172
3175
  } = rendering_options;
3173
3176
  const displays = await $558ccd2de887e6d9$var$make_sure_we_have_displays(t, rendering_options);
3174
3177
  if (!displays?.length) {
3175
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("RR: Got no displays for type " + type + ", can't recover.", t, rendering_options);
3178
+ $e6c6e7929ea385ae$export$de56f1198d121036("RR: Got no displays for type " + type + ", can't recover.", t, rendering_options);
3176
3179
  return {};
3177
3180
  }
3178
3181
  // return if too few displays
@@ -3183,19 +3186,19 @@ async function $558ccd2de887e6d9$export$a9fc160c5ed83bd7(t, rendering_options) {
3183
3186
  if (!good_displays) return {};
3184
3187
  const processed_displays = await $558ccd2de887e6d9$export$c22e610107c5a15a(t, rendering_options, displays);
3185
3188
  if (!processed_displays.length) {
3186
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("RR: No displays left after preprocessing");
3189
+ $e6c6e7929ea385ae$export$de56f1198d121036("RR: No displays left after preprocessing");
3187
3190
  return {};
3188
3191
  }
3189
3192
  const {
3190
3193
  template: template,
3191
3194
  post_processors = []
3192
3195
  } = rendering_options;
3193
- const caught_post_processing_functions = post_processors.map(post_pro => (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(post_pro));
3196
+ const caught_post_processing_functions = post_processors.map(post_pro => $268cbd9e4ade92db$export$b3bbfd758f11cfa9(post_pro));
3194
3197
  let a;
3195
- const caught_html2elems = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)((0, $bf7f12fe044e41b2$export$44951404cb8d0583));
3198
+ const caught_html2elems = $268cbd9e4ade92db$export$b3bbfd758f11cfa9((0, $bf7f12fe044e41b2$export$44951404cb8d0583));
3196
3199
  let output_elements;
3197
3200
  if (typeof template === "function") {
3198
- const caught_template = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(template);
3201
+ const caught_template = $268cbd9e4ade92db$export$b3bbfd758f11cfa9(template);
3199
3202
  output_elements = (await Promise.allSettled(processed_displays.map(async (display, index) => {
3200
3203
  const event_listeners = [];
3201
3204
  let keep = true;
@@ -3216,7 +3219,7 @@ async function $558ccd2de887e6d9$export$a9fc160c5ed83bd7(t, rendering_options) {
3216
3219
  return Array.from(post_processed_elements);
3217
3220
  }))).flat();
3218
3221
  if (!output_elements.length) {
3219
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("RR: No displays left after postprocessing/rendering");
3222
+ $e6c6e7929ea385ae$export$de56f1198d121036("RR: No displays left after postprocessing/rendering");
3220
3223
  return {};
3221
3224
  }
3222
3225
  return {
@@ -3278,7 +3281,7 @@ async function $558ccd2de887e6d9$export$c22e610107c5a15a(t, rendering_options, d
3278
3281
  max_items: max_items,
3279
3282
  pre_processors = []
3280
3283
  } = rendering_options;
3281
- const caught_pre_processors = pre_processors.map(pre_pro => (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(pre_pro));
3284
+ const caught_pre_processors = pre_processors.map(pre_pro => $268cbd9e4ade92db$export$b3bbfd758f11cfa9(pre_pro));
3282
3285
  const processed_displays = [];
3283
3286
  for (let i = 0; i < displays.length; i++) {
3284
3287
  // classic for loop is both fast and can be stopped with break
@@ -3313,7 +3316,7 @@ class $558ccd2de887e6d9$export$da854280fb61cd32 {
3313
3316
  async function $558ccd2de887e6d9$var$check_displays(displays, min_items_to_run) {
3314
3317
  // don't run if too few recs
3315
3318
  if (min_items_to_run && displays.length < min_items_to_run) {
3316
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("RR: Got too few displays, exiting");
3319
+ $e6c6e7929ea385ae$export$de56f1198d121036("RR: Got too few displays, exiting");
3317
3320
  return false;
3318
3321
  }
3319
3322
  return true;
@@ -3330,7 +3333,7 @@ async function $558ccd2de887e6d9$var$make_sure_we_have_displays(t, rendering_opt
3330
3333
  ...(rendering_options.extra_api_options || {})
3331
3334
  };
3332
3335
  for (const key of ["product_ids", "category_id", "product_id"]) if (key in rendering_options) get_displays_options[key] = rendering_options[key];
3333
- return await (0, $94edfb6d9c42a288$export$1bc0df10745d5412)(t, get_displays_options, rendering_options.headers || {}).catch(t.err);
3336
+ return await $94edfb6d9c42a288$export$1bc0df10745d5412(t, get_displays_options, rendering_options.headers || {}).catch(t.err);
3334
3337
  }
3335
3338
  async function $e5479d0db39d328b$export$c83d8da642b5104a(t, options, GWVM_opts) {
3336
3339
  const {
@@ -3350,8 +3353,8 @@ async function $e5479d0db39d328b$export$c83d8da642b5104a(t, options, GWVM_opts)
3350
3353
  only_full_rows = false,
3351
3354
  should_preload = true
3352
3355
  } = GWVM_opts;
3353
- const outer_els = typeof container_template === "string" ? [...(0, $bf7f12fe044e41b2$export$44951404cb8d0583)(container_template)] : container_template;
3354
- const [root] = (0, $bf7f12fe044e41b2$export$5e63aea0cac01fa0)(outer_els, container_selector);
3356
+ const outer_els = typeof container_template === "string" ? [...$bf7f12fe044e41b2$export$44951404cb8d0583(container_template)] : container_template;
3357
+ const [root] = $bf7f12fe044e41b2$export$5e63aea0cac01fa0(outer_els, container_selector);
3355
3358
  const cut_off_promise_obj = /*@__PURE__*/new (0, $04a37742898e4bd5$export$32ccf3a614c84258)();
3356
3359
  const i_observer = new IntersectionObserver(catchify($e5479d0db39d328b$var$observer_callback));
3357
3360
  let cut_off_point = 0;
@@ -3391,8 +3394,8 @@ async function $e5479d0db39d328b$export$c83d8da642b5104a(t, options, GWVM_opts)
3391
3394
  return rendering_results;
3392
3395
  }
3393
3396
  root.append(...rendered_elements);
3394
- const load_more_cont = (0, $bf7f12fe044e41b2$export$d3e2a0560cbf4787)(`<div class="load-more-container"></div>`);
3395
- const button_element = button instanceof Element ? button : (0, $bf7f12fe044e41b2$export$d3e2a0560cbf4787)(`<button class="load_more">${button || "Visa mer"}</button>`);
3397
+ const load_more_cont = $bf7f12fe044e41b2$export$d3e2a0560cbf4787(`<div class="load-more-container"></div>`);
3398
+ const button_element = button instanceof Element ? button : $bf7f12fe044e41b2$export$d3e2a0560cbf4787(`<button class="load_more">${button || "Visa mer"}</button>`);
3396
3399
  button_element.addEventListener("click", load_more);
3397
3400
  load_more_cont.append(button_element);
3398
3401
  root.after(load_more_cont);
@@ -3413,7 +3416,7 @@ async function $e5479d0db39d328b$export$c83d8da642b5104a(t, options, GWVM_opts)
3413
3416
  load_more_observer.observe(load_more_cont);
3414
3417
  }
3415
3418
  if (title) {
3416
- const [title_el] = (0, $bf7f12fe044e41b2$export$5e63aea0cac01fa0)(outer_els, title_selector || "h1.title");
3419
+ const [title_el] = $bf7f12fe044e41b2$export$5e63aea0cac01fa0(outer_els, title_selector || "h1.title");
3417
3420
  if (title_el) {
3418
3421
  if (title instanceof Element) title_el.replaceWith(title);else title_el.innerText = title;
3419
3422
  } else if (is_debug) {
@@ -3453,7 +3456,7 @@ info, cut_off_point, i_observer, cut_off_promise_obj, load_more) {
3453
3456
  const extras = info.extras ||= {};
3454
3457
  extras.load_more ||= load_more;
3455
3458
  extras.load_more_ipo ||= cut_off_promise_obj;
3456
- (0, $bf7f12fe044e41b2$export$5e63aea0cac01fa0)(elements_arr, "img:not(.filler):not(.ngl):not(.nolazy)").forEach(image => {
3459
+ $bf7f12fe044e41b2$export$5e63aea0cac01fa0(elements_arr, "img:not(.filler):not(.ngl):not(.nolazy)").forEach(image => {
3457
3460
  // "img" also selects "image" in IE11 which can be an SVG element which doesn't have a src property, therefore optional chaining
3458
3461
  if ((image?.src?.length || image?.dataset?.src) && image?.src?.substr?.(0, 6) != "data:") {
3459
3462
  if (is_initially_hidden && !image?.dataset.src) {
@@ -3514,7 +3517,7 @@ async function $d1ef5fbddf08305d$export$41de2959a8dd405d(t, options, GWVM_opts,
3514
3517
  } = rec;
3515
3518
  if (!parentElement) {
3516
3519
  // first rec was removed
3517
- [rec] = (0, $bf7f12fe044e41b2$export$5e63aea0cac01fa0)(result?.elements || [], rec_selector);
3520
+ [rec] = $bf7f12fe044e41b2$export$5e63aea0cac01fa0(result?.elements || [], rec_selector);
3518
3521
  parentElement = rec?.parentElement;
3519
3522
  if (!parentElement) throw new Error("Could not find element matching " + rec_selector + "to calculate width");
3520
3523
  }
@@ -3550,7 +3553,7 @@ async function $d1ef5fbddf08305d$export$41de2959a8dd405d(t, options, GWVM_opts,
3550
3553
  }
3551
3554
  };
3552
3555
  // @ts-ignore
3553
- result = await (0, $e5479d0db39d328b$export$c83d8da642b5104a)(t, options, modified_GWVM_opts);
3556
+ result = await $e5479d0db39d328b$export$c83d8da642b5104a(t, options, modified_GWVM_opts);
3554
3557
  if (!result?.elements)
3555
3558
  // no chance in finding any elements, API didn't return recs
3556
3559
  return result;
@@ -3612,28 +3615,28 @@ async function $55dae85e9309db86$export$c0a4d29bc45a38c6(t, options, GWVM_opts,
3612
3615
  $55dae85e9309db86$var$observe_first_el_after_dominsertion(all_rendered_elements, elements, info.extras.load_more);
3613
3616
  return elements;
3614
3617
  }];
3615
- return await (0, $d1ef5fbddf08305d$export$41de2959a8dd405d)(t, options, options_for_auto_gwvm, {
3618
+ return await $d1ef5fbddf08305d$export$41de2959a8dd405d(t, options, options_for_auto_gwvm, {
3616
3619
  rec_selector: rec_selector
3617
3620
  });
3618
3621
  }
3619
3622
  function $55dae85e9309db86$var$observe_first_el_after_dominsertion(all_rendered_elements, elements, load_more) {
3620
3623
  const element = $55dae85e9309db86$var$find_html_element(elements);
3621
3624
  if (!element) {
3622
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Infinite scroll won't work, couldn't find element to observe", elements);
3625
+ $e6c6e7929ea385ae$export$de56f1198d121036("Infinite scroll won't work, couldn't find element to observe", elements);
3623
3626
  return;
3624
3627
  }
3625
- (0, $2a1cbc63a04d4a2d$export$b6ae1bc530f4c149).wait_for_element(element).then((0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(() => {
3628
+ (0, $2a1cbc63a04d4a2d$export$b6ae1bc530f4c149).wait_for_element(element).then($268cbd9e4ade92db$export$b3bbfd758f11cfa9(() => {
3626
3629
  $55dae85e9309db86$var$find_last_el_and_observe(all_rendered_elements, load_more);
3627
3630
  }));
3628
3631
  }
3629
3632
  function $55dae85e9309db86$var$find_last_el_and_observe(all_rendered_elements, load_more) {
3630
3633
  const last_visible_el = $55dae85e9309db86$var$find_last_visible(all_rendered_elements);
3631
3634
  if (!last_visible_el) return;
3632
- const i_o = new IntersectionObserver((0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(records => {
3635
+ const i_o = new IntersectionObserver($268cbd9e4ade92db$export$b3bbfd758f11cfa9(records => {
3633
3636
  for (const record of records) if (record.isIntersecting) {
3634
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("loading more because of", record);
3637
+ $e6c6e7929ea385ae$export$de56f1198d121036("loading more because of", record);
3635
3638
  load_more();
3636
- setTimeout((0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)($55dae85e9309db86$var$find_last_el_and_observe), 0, all_rendered_elements, load_more);
3639
+ setTimeout($268cbd9e4ade92db$export$b3bbfd758f11cfa9($55dae85e9309db86$var$find_last_el_and_observe), 0, all_rendered_elements, load_more);
3637
3640
  i_o.disconnect();
3638
3641
  }
3639
3642
  }));
@@ -3651,26 +3654,26 @@ function $55dae85e9309db86$var$find_last_visible(bunch_of_elements) {
3651
3654
  for (let i = 0; i < considered_elements.length; i++) {
3652
3655
  const respected_element = considered_elements[i];
3653
3656
  if (!respected_element) {
3654
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Infinite scroll error: couldn't find last visible element", bunch_of_elements);
3657
+ $e6c6e7929ea385ae$export$de56f1198d121036("Infinite scroll error: couldn't find last visible element", bunch_of_elements);
3655
3658
  return;
3656
3659
  }
3657
3660
  if (respected_element.offsetParent === null) {
3658
3661
  if (!i) {
3659
3662
  // if index is 0 and we are not visible don't return the element at index -1 from the array - shit will hit the fan. Return the first one and everything should work out fine
3660
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Inf scroll: No elements visible, ", considered_elements, "will attach to first el", respected_element);
3663
+ $e6c6e7929ea385ae$export$de56f1198d121036("Inf scroll: No elements visible, ", considered_elements, "will attach to first el", respected_element);
3661
3664
  return considered_elements[i];
3662
3665
  }
3663
3666
  return considered_elements[i - 1];
3664
3667
  }
3665
3668
  }
3666
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Seems like all elements are loaded");
3669
+ $e6c6e7929ea385ae$export$de56f1198d121036("Seems like all elements are loaded");
3667
3670
  }
3668
3671
  async function $8686e45614d71607$export$9eae832ae57fbf(t, css, extra_html) {
3669
3672
  const head = await (0, $2a1cbc63a04d4a2d$export$b6ae1bc530f4c149).wait_for_element("head"),
3670
3673
  {
3671
3674
  dlog: dlog
3672
3675
  } = t,
3673
- elems = (0, $bf7f12fe044e41b2$export$44951404cb8d0583)(`<style type="text/css">${css}</style>` + (extra_html ? extra_html : ""));
3676
+ elems = $bf7f12fe044e41b2$export$44951404cb8d0583(`<style type="text/css">${css}</style>` + (extra_html ? extra_html : ""));
3674
3677
  dlog("inserting", ...elems, "into", head);
3675
3678
  head.append(...elems);
3676
3679
  }
@@ -3704,7 +3707,7 @@ async function $807b852d8decb547$var$placeholder_worker(placeholder_elements, fi
3704
3707
  }
3705
3708
  } else {
3706
3709
  await sanit_el_if_needed();
3707
- placeholder_elements[0].addEventListener("placeholder_switch", (0, $41f528c04cc8a8da$export$535946eb77c946dd)(async e => {
3710
+ placeholder_elements[0].addEventListener("placeholder_switch", $41f528c04cc8a8da$export$535946eb77c946dd(async e => {
3708
3711
  const new_state = e.detail.state;
3709
3712
  if (state != new_state) {
3710
3713
  await sanit_el_if_needed();
@@ -3724,7 +3727,7 @@ async function $807b852d8decb547$var$decide_direction_and_switch(placeholder_ele
3724
3727
  if (switch_to_final) $807b852d8decb547$var$switch_elements(placeholder_elements, final_elements);else $807b852d8decb547$var$switch_elements(final_elements, placeholder_elements);
3725
3728
  }
3726
3729
  function $807b852d8decb547$var$switch_elements(from, to) {
3727
- if (!from.length || !to.length) (0, $e6c6e7929ea385ae$export$c2363754d4758444)("Cannot switch elements as from or to is empty", from, to);
3730
+ if (!from.length || !to.length) $e6c6e7929ea385ae$export$c2363754d4758444("Cannot switch elements as from or to is empty", from, to);
3728
3731
  from[0].replaceWith(...to);
3729
3732
  for (let i = 1; i < from.length; i++) from[i].remove();
3730
3733
  }
@@ -3744,14 +3747,14 @@ class $1da560af170fb839$export$3be7054c61590ee3 {
3744
3747
  }
3745
3748
  }
3746
3749
  },
3747
- load: (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(async image => {
3750
+ load: $268cbd9e4ade92db$export$b3bbfd758f11cfa9(async image => {
3748
3751
  for (const element of [...$1da560af170fb839$export$e4741190ccada479(image, "source"), image]) {
3749
3752
  if ("loaded" in element) {
3750
- if (class_this.#verbose) (0, $e6c6e7929ea385ae$export$de56f1198d121036)(element, "is already loading, not loading again");
3753
+ if (class_this.#verbose) $e6c6e7929ea385ae$export$de56f1198d121036(element, "is already loading, not loading again");
3751
3754
  continue;
3752
3755
  }
3753
3756
  if (document?.body?.contains?.(image) === false) {
3754
- if (class_this.#verbose) (0, $e6c6e7929ea385ae$export$de56f1198d121036)(element, "has been removed from the DOM, can't load");
3757
+ if (class_this.#verbose) $e6c6e7929ea385ae$export$de56f1198d121036(element, "has been removed from the DOM, can't load");
3755
3758
  const {
3756
3759
  elements: elements
3757
3760
  } = class_this.lazyfinder;
@@ -3762,13 +3765,13 @@ class $1da560af170fb839$export$3be7054c61590ee3 {
3762
3765
  const has_src = element.dataset?.src?.length;
3763
3766
  const has_srcset = element.dataset?.srcset?.length;
3764
3767
  if (has_src || has_srcset) {
3765
- if (class_this.#verbose) (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Loading", element);
3768
+ if (class_this.#verbose) $e6c6e7929ea385ae$export$de56f1198d121036("Loading", element);
3766
3769
  element.loaded = false;
3767
3770
  // here it's of importance that we give the browser the srcset first, otherwise it (safari) might start loading the fallback src at first
3768
3771
  if (has_srcset) {
3769
3772
  // in Safari for some reason sometimes the .sizes attribute isn't set yet, like in https://www.notion.so/depictai/Pictures-in-recommendations-are-not-displayed-88e30e0f98de421e94b9eb273aea21dc. In that case, wait up to one event loop execution for it
3770
3773
  if (!element.sizes) await new Promise(resolve => {
3771
- const mo = new MutationObserver((0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(_records => {
3774
+ const mo = new MutationObserver($268cbd9e4ade92db$export$b3bbfd758f11cfa9(_records => {
3772
3775
  if (element.sizes) {
3773
3776
  resolve();
3774
3777
  mo.disconnect();
@@ -3778,7 +3781,7 @@ class $1da560af170fb839$export$3be7054c61590ee3 {
3778
3781
  attributes: true,
3779
3782
  attributeFilter: ["sizes"]
3780
3783
  });
3781
- setTimeout((0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(() => {
3784
+ setTimeout($268cbd9e4ade92db$export$b3bbfd758f11cfa9(() => {
3782
3785
  resolve(); // in case ResizeObserver doesn't set .sizes or something
3783
3786
  mo.disconnect();
3784
3787
  }));
@@ -3794,7 +3797,7 @@ class $1da560af170fb839$export$3be7054c61590ee3 {
3794
3797
  } else {
3795
3798
  if (element.src?.startsWith?.("data:")) continue;
3796
3799
  // This happens quite often for reasons unknown. One day we will figure out why, or replace this lazyloader with a new one/native.
3797
- if (class_this.#verbose) (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Cannot load", element, "as it doesn't have a data-src or data-srcset attribute");
3800
+ if (class_this.#verbose) $e6c6e7929ea385ae$export$de56f1198d121036("Cannot load", element, "as it doesn't have a data-src or data-srcset attribute");
3798
3801
  }
3799
3802
  }
3800
3803
  }),
@@ -3812,10 +3815,10 @@ class $1da560af170fb839$export$3be7054c61590ee3 {
3812
3815
  })();
3813
3816
  #initiate_new_image(image) {
3814
3817
  if (image.loaded === true || image.loaded === false) {
3815
- if (this.#verbose) (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Not lazyloading", image, "because it was loaded before or is loading");
3818
+ if (this.#verbose) $e6c6e7929ea385ae$export$de56f1198d121036("Not lazyloading", image, "because it was loaded before or is loading");
3816
3819
  return;
3817
3820
  }
3818
- (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(this.lazyfinder.unload)(image);
3821
+ $268cbd9e4ade92db$export$b3bbfd758f11cfa9(this.lazyfinder.unload)(image);
3819
3822
  this.#add_load_event_listener(image);
3820
3823
  this.intersection_observer?.observe?.(image); // observe if observer already exists, otherwise it won't and start_observer will do it
3821
3824
  }
@@ -3825,11 +3828,11 @@ class $1da560af170fb839$export$3be7054c61590ee3 {
3825
3828
  // it allows us to just add elements to the observed container and have them added to the elements array if they or their children match the selector
3826
3829
  if (!this.container && !override_container) return;
3827
3830
  const container = override_container ?? this.container;
3828
- const mutation_observer = new MutationObserver((0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(mutations => {
3831
+ const mutation_observer = new MutationObserver($268cbd9e4ade92db$export$b3bbfd758f11cfa9(mutations => {
3829
3832
  for (let i = 0; i < mutations.length; i++) {
3830
- const matching_added_els = (0, $bf7f12fe044e41b2$export$5e63aea0cac01fa0)(mutations[i].addedNodes, this.selector);
3833
+ const matching_added_els = $bf7f12fe044e41b2$export$5e63aea0cac01fa0(mutations[i].addedNodes, this.selector);
3831
3834
  if (matching_added_els.length) {
3832
- if (this.#verbose) (0, $e6c6e7929ea385ae$export$de56f1198d121036)("New elements", matching_added_els, " matching selector", this.selector, "were aded to", container, "lazyloading…");
3835
+ if (this.#verbose) $e6c6e7929ea385ae$export$de56f1198d121036("New elements", matching_added_els, " matching selector", this.selector, "were aded to", container, "lazyloading…");
3833
3836
  this.lazyfinder.elements.push(...matching_added_els);
3834
3837
  matching_added_els.forEach(this.#initiate_new_image.bind(this));
3835
3838
  }
@@ -3853,14 +3856,14 @@ class $1da560af170fb839$export$3be7054c61590ee3 {
3853
3856
  });
3854
3857
  }
3855
3858
  #add_load_event_listener(element) {
3856
- const handler = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(e => {
3859
+ const handler = $268cbd9e4ade92db$export$b3bbfd758f11cfa9(e => {
3857
3860
  // cookiebot triggers random "load" events on all elements which make the images load before the intersection observer has started
3858
3861
  if (!element.src.length) {
3859
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("ignoring load event", e, "because image doesn't have a src");
3862
+ $e6c6e7929ea385ae$export$de56f1198d121036("ignoring load event", e, "because image doesn't have a src");
3860
3863
  return;
3861
3864
  }
3862
3865
  if (this.ignore_data_urls && element.src.startsWith("data:")) {
3863
- if (this.#verbose) (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Ignoring load event", e, "because ignore_data_urls is truthy");
3866
+ if (this.#verbose) $e6c6e7929ea385ae$export$de56f1198d121036("Ignoring load event", e, "because ignore_data_urls is truthy");
3864
3867
  return;
3865
3868
  }
3866
3869
  element.removeEventListener("load", handler);
@@ -3874,7 +3877,7 @@ class $1da560af170fb839$export$3be7054c61590ee3 {
3874
3877
  elements: elements,
3875
3878
  unload: unload
3876
3879
  } = this.lazyfinder;
3877
- const caught_unload = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(unload);
3880
+ const caught_unload = $268cbd9e4ade92db$export$b3bbfd758f11cfa9(unload);
3878
3881
  for (let i = 0; i < elements.length; i++) {
3879
3882
  caught_unload(elements[i]);
3880
3883
  this.#add_load_event_listener(elements[i]);
@@ -3883,7 +3886,7 @@ class $1da560af170fb839$export$3be7054c61590ee3 {
3883
3886
  #start_observer() {
3884
3887
  let observers_first_call = true;
3885
3888
  if (!this.intersection_observer) {
3886
- this.intersection_observer = new IntersectionObserver((0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(entries => {
3889
+ this.intersection_observer = new IntersectionObserver($268cbd9e4ade92db$export$b3bbfd758f11cfa9(entries => {
3887
3890
  let any_intersected = false;
3888
3891
  for (let i = 0; i < entries.length; i++) {
3889
3892
  const entry = entries[i];
@@ -3899,7 +3902,7 @@ class $1da560af170fb839$export$3be7054c61590ee3 {
3899
3902
  if (any_intersected) observers_first_call = false;
3900
3903
  }), {
3901
3904
  root: this.container,
3902
- threshold: (0, $0da0cad4f39e8f32$export$f8ea2e7b15b5d129)(3)
3905
+ threshold: $0da0cad4f39e8f32$export$f8ea2e7b15b5d129(3)
3903
3906
  });
3904
3907
  const {
3905
3908
  elements: elements
@@ -3915,7 +3918,7 @@ class $1da560af170fb839$export$3be7054c61590ee3 {
3915
3918
  } = this.lazyfinder;
3916
3919
  for (let i = 0; i < (elements?.length ?? 0); i++) if (elements[i].loaded === true) loaded_images.push(elements[i]);else not_loaded_or_loading.push(elements[i]);
3917
3920
  if (this.#images_on_first_page.length >= loaded_images.length) {
3918
- const caught_loading_fin = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(this.lazyfinder.load);
3921
+ const caught_loading_fin = $268cbd9e4ade92db$export$b3bbfd758f11cfa9(this.lazyfinder.load);
3919
3922
  for (let i = 0; i < not_loaded_or_loading.length; i++) caught_loading_fin(not_loaded_or_loading[i]);
3920
3923
  }
3921
3924
  }
@@ -3942,10 +3945,10 @@ class $1da560af170fb839$export$3be7054c61590ee3 {
3942
3945
  this.#unload_images_and_add_load_listeners();
3943
3946
  // check if we need to branch off to an async function and wait for the elements being in the DOM
3944
3947
  if (wait_for_dominsertion) {
3945
- const caught_start_obs = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(this.#start_observer).bind(this);
3948
+ const caught_start_obs = $268cbd9e4ade92db$export$b3bbfd758f11cfa9(this.#start_observer).bind(this);
3946
3949
  if (wait_for_dominsertion instanceof Promise) wait_for_dominsertion.then(caught_start_obs);else {
3947
3950
  const el_to_listen_on = container || lazyfinder?.elements?.[0];
3948
- if (el_to_listen_on instanceof Node) (0, $2a1cbc63a04d4a2d$export$b6ae1bc530f4c149).wait_for_element(el_to_listen_on).then(caught_start_obs);else (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Could not find element to attach event listener to", () => {}); // right click function in inspector and select "jump to definition" to get here
3951
+ if (el_to_listen_on instanceof Node) (0, $2a1cbc63a04d4a2d$export$b6ae1bc530f4c149).wait_for_element(el_to_listen_on).then(caught_start_obs);else $e6c6e7929ea385ae$export$de56f1198d121036("Could not find element to attach event listener to", () => {}); // right click function in inspector and select "jump to definition" to get here
3949
3952
  }
3950
3953
  } else this.#start_observer();
3951
3954
  }
@@ -3970,9 +3973,9 @@ function $1da560af170fb839$export$e4741190ccada479(element, selector) {
3970
3973
  }
3971
3974
  return result;
3972
3975
  }
3973
- const $90e0b983530610e7$export$eb0b9ed911409b57 = (callback, element) => ((0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(callback)(element), element);
3976
+ const $90e0b983530610e7$export$eb0b9ed911409b57 = (callback, element) => ($268cbd9e4ade92db$export$b3bbfd758f11cfa9(callback)(element), element);
3974
3977
  function $90e0b983530610e7$export$f63fcc839cb0f734(event, handler, element) {
3975
- element.addEventListener(event, (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(handler));
3978
+ element.addEventListener(event, $268cbd9e4ade92db$export$b3bbfd758f11cfa9(handler));
3976
3979
  return element;
3977
3980
  }
3978
3981
  const $90e0b983530610e7$export$22a65337c1b43b1f = /* @PURE */classes => classes.filter(c => c !== undefined).join(" ");
@@ -4004,7 +4007,7 @@ const $107a74aa4ea5902d$export$34b9dba7ce09269b = (tag, {
4004
4007
  const element = is_svg ? document.createElementNS(namespace, tag) : document.createElement(tag);
4005
4008
  for (const key in props) {
4006
4009
  const value = props[key];
4007
- if (key === "onClick") element.addEventListener("click", (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(value));else if (key.startsWith("xlink:"))
4010
+ if (key === "onClick") element.addEventListener("click", $268cbd9e4ade92db$export$b3bbfd758f11cfa9(value));else if (key.startsWith("xlink:"))
4008
4011
  // https://stackoverflow.com/a/23142447
4009
4012
  // https://developer.mozilla.org/en-US/docs/Web/SVG/Namespaces_Crash_Course
4010
4013
  element.setAttributeNS("http://www.w3.org/1999/xlink", key, value);else if (key == "xmlns" || key.startsWith("xmlns:")) element.setAttributeNS("http://www.w3.org/2000/xmlns/", key, value);else if (key.startsWith("xml:")) element.setAttributeNS("http://www.w3.org/XML/1998/namespace", key, value);else element.setAttribute(key, props[key]);
@@ -4023,19 +4026,19 @@ const $107a74aa4ea5902d$export$ffb0004e005737fa = ({
4023
4026
  };
4024
4027
  class $1683d0164abd7c1d$export$692b27c28639e5b9 {
4025
4028
  // this is just here because it's often needed together with the slider
4026
- container = (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("div", {
4029
+ container = $107a74aa4ea5902d$export$34b9dba7ce09269b("div", {
4027
4030
  class: "depict-slider depict"
4028
4031
  });
4029
4032
  #elements = {
4030
- sliding_el_: (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("div", {
4033
+ sliding_el_: $107a74aa4ea5902d$export$34b9dba7ce09269b("div", {
4031
4034
  class: "sliding"
4032
4035
  }),
4033
- left_: (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("button", {
4036
+ left_: $107a74aa4ea5902d$export$34b9dba7ce09269b("button", {
4034
4037
  "aria-label": "Scroll left",
4035
4038
  class: "left d-navbutton",
4036
4039
  type: "button"
4037
4040
  }),
4038
- right_: (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("button", {
4041
+ right_: $107a74aa4ea5902d$export$34b9dba7ce09269b("button", {
4039
4042
  "aria-label": "Scroll right",
4040
4043
  class: "right d-navbutton",
4041
4044
  type: "button"
@@ -4078,15 +4081,15 @@ class $1683d0164abd7c1d$export$692b27c28639e5b9 {
4078
4081
  const rec_idx = this.get_index_of_element(target);
4079
4082
  if (entry.intersectionRatio <= 0) {
4080
4083
  for (const key in intersecting_items) if (intersecting_items[key].target === target) delete intersecting_items[key];
4081
- } else if (rec_idx != null) intersecting_items[rec_idx] = entry;else (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Could not find index of", target, "ignoring observer record");
4084
+ } else if (rec_idx != null) intersecting_items[rec_idx] = entry;else $e6c6e7929ea385ae$export$de56f1198d121036("Could not find index of", target, "ignoring observer record");
4082
4085
  }
4083
- (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(this.#hide_buttons_if_needed).call(this);
4086
+ $268cbd9e4ade92db$export$b3bbfd758f11cfa9(this.#hide_buttons_if_needed).call(this);
4084
4087
  const mutation_plugins = this.#mutation_plugins;
4085
- for (let i = 0; i < mutation_plugins.length; i++) (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(mutation_plugins[i]).call(this, entries, intersecting_items);
4088
+ for (let i = 0; i < mutation_plugins.length; i++) $268cbd9e4ade92db$export$b3bbfd758f11cfa9(mutation_plugins[i]).call(this, entries, intersecting_items);
4086
4089
  }
4087
4090
  observer = new IntersectionObserver(this.#observer_callback.bind(this), {
4088
4091
  root: this.#elements.sliding_el_,
4089
- threshold: (0, $0da0cad4f39e8f32$export$f8ea2e7b15b5d129)(100)
4092
+ threshold: $0da0cad4f39e8f32$export$f8ea2e7b15b5d129(100)
4090
4093
  });
4091
4094
  observe = this.observer.observe.bind(this.observer);
4092
4095
  get_index_of_element(target) {
@@ -4157,7 +4160,7 @@ class $1683d0164abd7c1d$export$692b27c28639e5b9 {
4157
4160
  }
4158
4161
  #distance_to(offset, is_absolute = false) {
4159
4162
  const intersecting_items = this.intersecting_items_object; // the privateFieldGet babel polyfill isn't very fast so for extra snappyness I won't get it multiple times
4160
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("intersecting_items", intersecting_items);
4163
+ $e6c6e7929ea385ae$export$de56f1198d121036("intersecting_items", intersecting_items);
4161
4164
  // I know I could have made this.intersecting_items_object a simple array instead, but maybe someone needs the boundingrect information in it some day. Also I thought I could use it, but it isn't always up to date due to the intersection observer not triggering on every scrolling move.
4162
4165
  // Now, some months later: the triggering frequency can easily be adjusted, the problem is that the observer doesn't trigger on hidden elements, meaning when scrolling left we don't have information about the hidden element's position from the observer
4163
4166
  let target; // absolute index to focus on
@@ -4167,7 +4170,7 @@ class $1683d0164abd7c1d$export$692b27c28639e5b9 {
4167
4170
  } = this;
4168
4171
  if (currently_selected == null) {
4169
4172
  // if for whatever reason we don't find a card, don't do anything
4170
- (0, $268cbd9e4ade92db$export$f18d5b0af29128b7)(new Error("can't find card in center"), "error");
4173
+ $268cbd9e4ade92db$export$f18d5b0af29128b7(new Error("can't find card in center"), "error");
4171
4174
  return 0;
4172
4175
  }
4173
4176
  target = currently_selected + offset;
@@ -4182,32 +4185,32 @@ class $1683d0164abd7c1d$export$692b27c28639e5b9 {
4182
4185
  }
4183
4186
  target = Math.floor(target);
4184
4187
  let dist;
4185
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("trying to focus target", target);
4188
+ $e6c6e7929ea385ae$export$de56f1198d121036("trying to focus target", target);
4186
4189
  let target_element = this.element_by_index(target);
4187
4190
  if (!target_element) {
4188
4191
  if (this.correct_bs_targets) {
4189
4192
  if (isNaN(target)) {
4190
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("target is not a number", target, "can't correct");
4193
+ $e6c6e7929ea385ae$export$de56f1198d121036("target is not a number", target, "can't correct");
4191
4194
  return 0;
4192
4195
  } else if (target < 0) {
4193
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Target", target, "is < 0, correcting to 0 because correct_bs_targets is enabled");
4196
+ $e6c6e7929ea385ae$export$de56f1198d121036("Target", target, "is < 0, correcting to 0 because correct_bs_targets is enabled");
4194
4197
  target = 0;
4195
4198
  target_element = this.element_by_index(target);
4196
4199
  if (!target_element) {
4197
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("can't find element 0");
4200
+ $e6c6e7929ea385ae$export$de56f1198d121036("can't find element 0");
4198
4201
  return 0;
4199
4202
  }
4200
4203
  } else {
4201
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("target", target, "does not exist, correcting to last sliding element \uD83E\uDD2D");
4204
+ $e6c6e7929ea385ae$export$de56f1198d121036("target", target, "does not exist, correcting to last sliding element \uD83E\uDD2D");
4202
4205
  target = this.index_of_last_element;
4203
4206
  target_element = this.element_by_index(target);
4204
4207
  if (!target_element) {
4205
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("last element", target, "could not be found");
4208
+ $e6c6e7929ea385ae$export$de56f1198d121036("last element", target, "could not be found");
4206
4209
  return 0;
4207
4210
  }
4208
4211
  }
4209
4212
  } else {
4210
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("target is bs, can't find", target, "by either data-index attribute or as child of", this.#elements.sliding_el_);
4213
+ $e6c6e7929ea385ae$export$de56f1198d121036("target is bs, can't find", target, "by either data-index attribute or as child of", this.#elements.sliding_el_);
4211
4214
  return 0;
4212
4215
  }
4213
4216
  }
@@ -4233,7 +4236,7 @@ class $1683d0164abd7c1d$export$692b27c28639e5b9 {
4233
4236
  dist += biggest_card * num_cards_off_target;
4234
4237
  }
4235
4238
  } catch (e) {
4236
- (0, $548fd58b14b25a52$export$8048b892d651b310)(e);
4239
+ $548fd58b14b25a52$export$8048b892d651b310(e);
4237
4240
  }
4238
4241
  return dist;
4239
4242
  }
@@ -4280,7 +4283,7 @@ class $1683d0164abd7c1d$export$692b27c28639e5b9 {
4280
4283
  }
4281
4284
  this.#cached_visible_sizes = visible_sizes;
4282
4285
  // let's assume we can cache this for a tick since the slider scrolls smoothly so there's no point in reading it instantly again and assuming a different value
4283
- queueMicrotask((0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(() => this.#cached_visible_sizes = undefined));
4286
+ queueMicrotask($268cbd9e4ade92db$export$b3bbfd758f11cfa9(() => this.#cached_visible_sizes = undefined));
4284
4287
  return visible_sizes;
4285
4288
  }
4286
4289
  get cards_fitting_in_viewport() {
@@ -4323,8 +4326,8 @@ class $1683d0164abd7c1d$export$692b27c28639e5b9 {
4323
4326
  if (should_be_visible && ishidden) element.classList.remove("hidden");else if (!should_be_visible && !ishidden) element.classList.add("hidden");
4324
4327
  }
4325
4328
  #setup_buttons() {
4326
- const goleft = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(() => this.#scroll_to(-this.stepstoslide, false, -510));
4327
- const goright = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(() => this.#scroll_to(this.stepstoslide, false, 510));
4329
+ const goleft = $268cbd9e4ade92db$export$b3bbfd758f11cfa9(() => this.#scroll_to(-this.stepstoslide, false, -510));
4330
+ const goright = $268cbd9e4ade92db$export$b3bbfd758f11cfa9(() => this.#scroll_to(this.stepstoslide, false, 510));
4328
4331
  const {
4329
4332
  right_: right_,
4330
4333
  left_: left_
@@ -4341,7 +4344,7 @@ class $1683d0164abd7c1d$export$692b27c28639e5b9 {
4341
4344
  this.container.append(es.left_, es.right_);
4342
4345
  this.container.append(es.sliding_el_);
4343
4346
  if (autoinvalidate) {
4344
- const cache_mo = new MutationObserver((0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(records => {
4347
+ const cache_mo = new MutationObserver($268cbd9e4ade92db$export$b3bbfd758f11cfa9(records => {
4345
4348
  this.invalidate_cache();
4346
4349
  for (const extra_fn of this.on_elements_changed) extra_fn.call(this, records);
4347
4350
  }));
@@ -4368,13 +4371,13 @@ class $1683d0164abd7c1d$export$692b27c28639e5b9 {
4368
4371
  this.#index_cache.last_el_ = undefined;
4369
4372
  }
4370
4373
  #scroll_to(offset, is_absolute = false, fallback_scroll_distance = 500, harsh = false) {
4371
- const left = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(this.#distance_to).call(this, offset, is_absolute);
4374
+ const left = $268cbd9e4ade92db$export$b3bbfd758f11cfa9(this.#distance_to).call(this, offset, is_absolute);
4372
4375
  const distance_after_fallback_applied = Math.round(left ?? fallback_scroll_distance);
4373
4376
  if (getComputedStyle(this.#elements.sliding_el_).scrollSnapType !== "none" && Math.abs(distance_after_fallback_applied) < 10) {
4374
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Not scrolling because snapping is enabled and distance not over threshold", distance_after_fallback_applied);
4377
+ $e6c6e7929ea385ae$export$de56f1198d121036("Not scrolling because snapping is enabled and distance not over threshold", distance_after_fallback_applied);
4375
4378
  return;
4376
4379
  }
4377
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Trying to scroll by", left, "px", "before fallback,", distance_after_fallback_applied, "after");
4380
+ $e6c6e7929ea385ae$export$de56f1198d121036("Trying to scroll by", left, "px", "before fallback,", distance_after_fallback_applied, "after");
4378
4381
  this.#elements.sliding_el_.scrollBy({
4379
4382
  left: distance_after_fallback_applied,
4380
4383
  top: 0,
@@ -4411,13 +4414,13 @@ class $1683d0164abd7c1d$export$692b27c28639e5b9 {
4411
4414
  }
4412
4415
  if (button_contents?.right) this.#elements.right_.append(...button_contents.right);
4413
4416
  if (button_contents?.left) this.#elements.left_.append(...button_contents.left);
4414
- (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(this.#create_element_structure).call(this, autoinvalidate_cache);
4417
+ $268cbd9e4ade92db$export$b3bbfd758f11cfa9(this.#create_element_structure).call(this, autoinvalidate_cache);
4415
4418
  // @ts-ignore
4416
4419
  this.#elements.sliding_el_.slider = this; // dunno if this is dumb? So far nordicagolf/kondomvaruhuset depend on it
4417
4420
  // plugin functionality i.e. for dots
4418
4421
  const constructor_args = arguments;
4419
4422
  constructor_plugins?.forEach?.(mplugin => {
4420
- (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(mplugin).call(this, constructor_args);
4423
+ $268cbd9e4ade92db$export$b3bbfd758f11cfa9(mplugin).call(this, constructor_args);
4421
4424
  });
4422
4425
  }
4423
4426
  }
@@ -4429,7 +4432,7 @@ class $a69a5236b5814082$export$68babfc5be0de5da extends (0, $1683d0164abd7c1d$ex
4429
4432
  element: element,
4430
4433
  disconnector: disconnector
4431
4434
  }) => {
4432
- const i_o = new IntersectionObserver((0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(records => {
4435
+ const i_o = new IntersectionObserver($268cbd9e4ade92db$export$b3bbfd758f11cfa9(records => {
4433
4436
  for (const record of records) if (record.intersectionRatio > 0) {
4434
4437
  r(true);
4435
4438
  i_o.disconnect();
@@ -4439,7 +4442,7 @@ class $a69a5236b5814082$export$68babfc5be0de5da extends (0, $1683d0164abd7c1d$ex
4439
4442
  }),
4440
4443
  // Fixes https://gitlab.com/depict-ai/depict.ai/-/merge_requests/5816/diffs, don't understand why
4441
4444
  {
4442
- threshold: (0, $0da0cad4f39e8f32$export$f8ea2e7b15b5d129)(10)
4445
+ threshold: $0da0cad4f39e8f32$export$f8ea2e7b15b5d129(10)
4443
4446
  });
4444
4447
  i_o.observe(element);
4445
4448
  });
@@ -4459,7 +4462,7 @@ function $04d2f7d9126af667$export$fb9afe9f540ae069(elements, _display, info) {
4459
4462
  if (!elements?.length) return elements;
4460
4463
  if (!info.t) return elements;
4461
4464
  const elements_as_array = [...elements];
4462
- const handler = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(async () => {
4465
+ const handler = $268cbd9e4ade92db$export$b3bbfd758f11cfa9(async () => {
4463
4466
  const {
4464
4467
  rendering_options: rendering_options,
4465
4468
  t: t
@@ -4467,7 +4470,7 @@ function $04d2f7d9126af667$export$fb9afe9f540ae069(elements, _display, info) {
4467
4470
  if (!$04d2f7d9126af667$export$4b50a4de9c6bbe09.has(rendering_options) && elements_as_array.some(e => document.documentElement.contains(e)) // check, just in case
4468
4471
  ) {
4469
4472
  $04d2f7d9126af667$export$4b50a4de9c6bbe09.add(rendering_options);
4470
- (0, $e0a87646d12cb987$export$82badda1f9923310)({
4473
+ $e0a87646d12cb987$export$82badda1f9923310({
4471
4474
  ...t,
4472
4475
  product_id: await t.get_product_id(),
4473
4476
  recommendation_type: info.rendering_options.type,
@@ -4489,7 +4492,7 @@ function $04d2f7d9126af667$export$1bffac19f9f0d6fc(elements, _display, info) {
4489
4492
  // GTAG tracking is deprecated, if we're doing no-tenant recommendation rendering it's SDK anyway.
4490
4493
  return elements;
4491
4494
  const [first_element] = elements;
4492
- const handler = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(() => {
4495
+ const handler = $268cbd9e4ade92db$export$b3bbfd758f11cfa9(() => {
4493
4496
  const {
4494
4497
  rendering_options: rendering_options,
4495
4498
  displays: displays
@@ -4502,7 +4505,7 @@ function $04d2f7d9126af667$export$1bffac19f9f0d6fc(elements, _display, info) {
4502
4505
  const {
4503
4506
  type: type
4504
4507
  } = rendering_options;
4505
- (0, $d3d8549954e0318e$export$7babcd5d4056b2ca)(displays, get_product_id /* yes this might create errors if there's no page_url in the display but don't have time to fix, sorry */, {
4508
+ $d3d8549954e0318e$export$7babcd5d4056b2ca(displays, get_product_id /* yes this might create errors if there's no page_url in the display but don't have time to fix, sorry */, {
4506
4509
  list_name: "depict_" + type
4507
4510
  });
4508
4511
  }
@@ -4517,7 +4520,7 @@ function $04d2f7d9126af667$export$9e1caada6901f552(elements, _display, info) {
4517
4520
  } = info;
4518
4521
  if (!t) return elements;
4519
4522
  (async () => {
4520
- (0, $72ee205b59322497$export$eee4c4d924348b05)({
4523
+ $72ee205b59322497$export$eee4c4d924348b05({
4521
4524
  tenant: t.tenant,
4522
4525
  market: t.market,
4523
4526
  product_id: await t.get_product_id()
@@ -4532,9 +4535,9 @@ function $04d2f7d9126af667$export$8d72437623fef90c(elements, display, info) {
4532
4535
  ga_product_id: ga_product_id,
4533
4536
  product_id: product_id
4534
4537
  } = display;
4535
- if (Array.isArray(ga_product_ids)) for (let i = 0; i < ga_product_ids.length; i++) (0, $d3d8549954e0318e$export$f522672c9379e339)(ga_product_ids[i], info.index, {
4538
+ if (Array.isArray(ga_product_ids)) for (let i = 0; i < ga_product_ids.length; i++) $d3d8549954e0318e$export$f522672c9379e339(ga_product_ids[i], info.index, {
4536
4539
  list_name: "depict_" + info.rendering_options.type
4537
- });else (0, $d3d8549954e0318e$export$f522672c9379e339)(ga_product_id || product_id, info.index, {
4540
+ });else $d3d8549954e0318e$export$f522672c9379e339(ga_product_id || product_id, info.index, {
4538
4541
  list_name: "depict_" + info.rendering_options.type
4539
4542
  });
4540
4543
  };
@@ -4551,7 +4554,7 @@ function $04d2f7d9126af667$export$e9106d6e723510d2(elements, display, info) {
4551
4554
  index: index,
4552
4555
  rendering_options: rendering_options
4553
4556
  } = info;
4554
- return (0, $e0a87646d12cb987$export$15f8a0cd5a8c0ebb)({
4557
+ return $e0a87646d12cb987$export$15f8a0cd5a8c0ebb({
4555
4558
  ...t,
4556
4559
  ...rendering_options,
4557
4560
  ...display,
@@ -4576,14 +4579,14 @@ function $04d2f7d9126af667$export$32eb5dd18e963410(elements, display, info) {
4576
4579
  } = "variant_index" in display ? display.variant_displays[display.variant_index] : display;
4577
4580
  if (!elements?.length) return elements;
4578
4581
  for (const element of elements) {
4579
- const handler = (0, $c8263a2185830bf1$export$82a685f2da2fb027)(element, product_id, recommendation_id || search_result_id);
4582
+ const handler = $c8263a2185830bf1$export$82a685f2da2fb027(element, product_id, recommendation_id || search_result_id);
4580
4583
  if (handler) $04d2f7d9126af667$var$push_function($04d2f7d9126af667$export$32eb5dd18e963410, handler);
4581
4584
  }
4582
4585
  return elements;
4583
4586
  }
4584
4587
  function $04d2f7d9126af667$export$dd32cb565eae0a1f(elements, display, info) {
4585
4588
  const handler = () => {
4586
- (0, $d3d8549954e0318e$export$127751e82111fcf)();
4589
+ $d3d8549954e0318e$export$127751e82111fcf();
4587
4590
  };
4588
4591
  $04d2f7d9126af667$var$push_function($04d2f7d9126af667$export$dd32cb565eae0a1f, handler);
4589
4592
  info.register_event_listener("click", handler, {
@@ -4629,7 +4632,7 @@ async function $92bde32714bb1e07$export$50ce83ace0cdd87e(t, rendering_options) {
4629
4632
  view_tracking: view_tracking,
4630
4633
  click_tracking: click_tracking
4631
4634
  } = rendering_options;
4632
- return await (0, $558ccd2de887e6d9$export$a9fc160c5ed83bd7)(t, {
4635
+ return await $558ccd2de887e6d9$export$a9fc160c5ed83bd7(t, {
4633
4636
  ...rendering_options,
4634
4637
  headers: {
4635
4638
  ...((0, $f3f05d97149aec76$export$deca40f48c0569f8) ? {
@@ -4652,7 +4655,7 @@ async function $3cb558cec98ba1a7$export$cab8bc58c64c2013(t, rendering_options, o
4652
4655
  let {
4653
4656
  container: container
4654
4657
  } = options_for_us;
4655
- if (typeof container == "string") container = [...(0, $bf7f12fe044e41b2$export$44951404cb8d0583)(container)];
4658
+ if (typeof container == "string") container = [...$bf7f12fe044e41b2$export$44951404cb8d0583(container)];
4656
4659
  if (container && !Array.isArray(container)) container = [...container];
4657
4660
  const slider = new (0, $a69a5236b5814082$export$68babfc5be0de5da)({
4658
4661
  dist_to_hide_left: 10,
@@ -4662,17 +4665,17 @@ async function $3cb558cec98ba1a7$export$cab8bc58c64c2013(t, rendering_options, o
4662
4665
  const recs = await local_rr(t, {
4663
4666
  ...rendering_options,
4664
4667
  post_processors: [(elements, display) => {
4665
- (0, $bf7f12fe044e41b2$export$5e63aea0cac01fa0)(elements, ".rec_outer").forEach(ro => ro.classList.add("noautospacing"));
4668
+ $bf7f12fe044e41b2$export$5e63aea0cac01fa0(elements, ".rec_outer").forEach(ro => ro.classList.add("noautospacing"));
4666
4669
  return elements;
4667
4670
  }, ...(rendering_options.post_processors || [])]
4668
4671
  });
4669
4672
  if (!recs.elements) {
4670
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Pro_Slider says bye bye cuz no recs");
4673
+ $e6c6e7929ea385ae$export$de56f1198d121036("Pro_Slider says bye bye cuz no recs");
4671
4674
  return {};
4672
4675
  }
4673
4676
  slider.insert_here.append(...recs.elements);
4674
4677
  if (container) {
4675
- const [root] = (0, $bf7f12fe044e41b2$export$5e63aea0cac01fa0)(container, root_selector || ".grid");
4678
+ const [root] = $bf7f12fe044e41b2$export$5e63aea0cac01fa0(container, root_selector || ".grid");
4676
4679
  root[insertion_verb](slider.container);
4677
4680
  }
4678
4681
  return {
@@ -4703,7 +4706,7 @@ class $0b6a8303b64cced1$export$1a8782481a9af507 {
4703
4706
  type: type,
4704
4707
  market: market
4705
4708
  } = this.settings;
4706
- (0, $94edfb6d9c42a288$export$1bc0df10745d5412)(
4709
+ $94edfb6d9c42a288$export$1bc0df10745d5412(
4707
4710
  // @ts-ignore - Quick workaround, as we don't have a tenant object here
4708
4711
  {
4709
4712
  tenant: tenant,
@@ -4713,7 +4716,7 @@ class $0b6a8303b64cced1$export$1a8782481a9af507 {
4713
4716
  product_id: product_id()
4714
4717
  }).then(recs => {
4715
4718
  this.data = recs;
4716
- (0, $eee5951374097b61$export$8582cf3716962dc2)({
4719
+ $eee5951374097b61$export$8582cf3716962dc2({
4717
4720
  ...this.settings,
4718
4721
  recs: this.data,
4719
4722
  min_recs: this.settings.min_items || this.settings.max_items
@@ -4730,14 +4733,14 @@ class $0b6a8303b64cced1$export$1a8782481a9af507 {
4730
4733
  }
4731
4734
  if (!action || action instanceof Event) action = "rec_bar_click";
4732
4735
  if (action == "rec_bar_click" && typeof index != "undefined" && product_id) {
4733
- if (Array.isArray(ga_product_ids)) for (const id of ga_product_ids) (0, $d3d8549954e0318e$export$f522672c9379e339)(id, index, {
4736
+ if (Array.isArray(ga_product_ids)) for (const id of ga_product_ids) $d3d8549954e0318e$export$f522672c9379e339(id, index, {
4734
4737
  list_name: "depict_" + this.settings.type
4735
- });else (0, $d3d8549954e0318e$export$f522672c9379e339)(product_id, index, {
4738
+ });else $d3d8549954e0318e$export$f522672c9379e339(product_id, index, {
4736
4739
  list_name: "depict_" + this.settings.type
4737
4740
  });
4738
4741
  }
4739
4742
  if (this.tracker === undefined) this.tracker = ga("create", this.settings.gaid, "auto", "depict");
4740
- (0, $d3d8549954e0318e$export$f75172d2e289cd02)(action);
4743
+ $d3d8549954e0318e$export$f75172d2e289cd02(action);
4741
4744
  }
4742
4745
  trackPageView() {
4743
4746
  if ($0b6a8303b64cced1$var$pageview_sent) {
@@ -4748,12 +4751,12 @@ class $0b6a8303b64cced1$export$1a8782481a9af507 {
4748
4751
  const {
4749
4752
  product_id: product_id
4750
4753
  } = this.settings;
4751
- (0, $72ee205b59322497$export$eee4c4d924348b05)(typeof product_id === "function" ? product_id() : product_id);
4754
+ $72ee205b59322497$export$eee4c4d924348b05(typeof product_id === "function" ? product_id() : product_id);
4752
4755
  }
4753
4756
  trackClick(index) {
4754
4757
  const item = this.data[index];
4755
4758
  if (item === undefined) return;
4756
- return (0, $e0a87646d12cb987$export$15f8a0cd5a8c0ebb)({
4759
+ return $e0a87646d12cb987$export$15f8a0cd5a8c0ebb({
4757
4760
  ...this.settings,
4758
4761
  ...item,
4759
4762
  click_location: `${this.settings.type}_${index + 1}`,
@@ -4761,7 +4764,7 @@ class $0b6a8303b64cced1$export$1a8782481a9af507 {
4761
4764
  });
4762
4765
  }
4763
4766
  trackAddToCart(pId) {
4764
- return (0, $e0a87646d12cb987$export$9028351cb994757e)({
4767
+ return $e0a87646d12cb987$export$9028351cb994757e({
4765
4768
  ...this.settings,
4766
4769
  product_id: pId && !(pId instanceof Event) ? pId : this.settings.product_id()
4767
4770
  });
@@ -4842,7 +4845,7 @@ class $0b6a8303b64cced1$export$1a8782481a9af507 {
4842
4845
  (0, $2a1cbc63a04d4a2d$export$b6ae1bc530f4c149).oncreation(element, () => {
4843
4846
  if (!this.#dispatched_recs_inserted) {
4844
4847
  this.#dispatched_recs_inserted = true;
4845
- (0, $e0a87646d12cb987$export$82badda1f9923310)({
4848
+ $e0a87646d12cb987$export$82badda1f9923310({
4846
4849
  ...this.settings,
4847
4850
  product_id: product_id_at_rendering,
4848
4851
  recommendation_type: this.settings.type,
@@ -4855,8 +4858,8 @@ class $0b6a8303b64cced1$export$1a8782481a9af507 {
4855
4858
  this.trackGAEvent("rec_bar_click", rec_index, item.ga_product_id || item.product_id || this.settings.product_id(item.page_url), item.ga_product_ids);
4856
4859
  };
4857
4860
  element.addEventListener("click", listener);
4858
- (0, $c8263a2185830bf1$export$82a685f2da2fb027)(element, item.product_id, item.recommendation_id);
4859
- if (this.settings.shade) (0, $fbb09973782881cb$export$6ebd242c09192cec)(element);
4861
+ $c8263a2185830bf1$export$82a685f2da2fb027(element, item.product_id, item.recommendation_id);
4862
+ if (this.settings.shade) $fbb09973782881cb$export$6ebd242c09192cec(element);
4860
4863
  // @ts-ignore
4861
4864
  if (!element.depict_event_listeners)
4862
4865
  // @ts-ignore
@@ -4868,7 +4871,7 @@ class $0b6a8303b64cced1$export$1a8782481a9af507 {
4868
4871
  resultingElements.push(...elements);
4869
4872
  });
4870
4873
  this.data = recsArray;
4871
- if (!this.settings.DNT) (0, $d3d8549954e0318e$export$7babcd5d4056b2ca)(recsArray, this.settings.product_id, {
4874
+ if (!this.settings.DNT) $d3d8549954e0318e$export$7babcd5d4056b2ca(recsArray, this.settings.product_id, {
4872
4875
  list_name: "depict_" + this.settings.type
4873
4876
  });
4874
4877
  return resultingElements;
@@ -4924,8 +4927,8 @@ $52d3be7ce5146924$export$2e2bcd8739ae039 = async options => {
4924
4927
  };
4925
4928
 
4926
4929
  // @ts-ignore
4927
- var $1259ff510e3d4a71$exports = {};
4928
- $1259ff510e3d4a71$exports = ".depict .rec_outer.noautospacing {\n width: 6cm;\n max-width: 46vw;\n margin-left: 1%;\n margin-right: 1%;\n}\n\n.depict .rec_outer.noautospacing:nth-child(1) {\n margin-left: 0;\n}\n\n.depict .rec_outer.noautospacing:nth-last-child(1) {\n margin-right: 0;\n}\n\n.depict-slider .slider_snap {\n scroll-snap-type: x mandatory;\n}\n\n.depict-slider {\n width: 100%;\n position: relative;\n}\n\n.depict-slider .sliding::-webkit-scrollbar {\n display: none;\n}\n\n.depict-slider .sliding {\n scroll-behavior: smooth;\n -ms-overflow-style: none;\n scrollbar-width: none;\n flex-flow: row;\n margin-top: -1%;\n margin-bottom: -2%;\n padding-top: 1%;\n padding-bottom: 2%;\n display: flex;\n overflow-x: scroll;\n}\n\n.depict-slider .sliding > * {\n box-sizing: border-box;\n flex: none;\n}\n\n.depict-slider button.right {\n right: 0;\n}\n\n.depict-slider button.left, .depict-slider button.right {\n z-index: 2;\n touch-action: manipulation;\n width: 1cm;\n height: 1cm;\n cursor: pointer;\n background: #fff;\n border: none;\n padding: .5%;\n transition-duration: .2s;\n position: absolute;\n top: 50%;\n transform: translateY(-50%);\n}\n\n.depict-slider button.left.hidden, .depict-slider button.right.hidden {\n opacity: 0;\n cursor: default;\n}\n\n.depict-slider button.left {\n left: 0;\n transform: translateY(-50%)rotate(180deg);\n}\n\n.depict-slider button.left img, .depict-slider button.right img {\n width: 100%;\n height: 100%;\n}\n\n.depict-slider .rec_outer {\n margin-top: 0 !important;\n}\n\n";
4930
+ var $0bdfc1d6f84716d9$exports = {};
4931
+ $0bdfc1d6f84716d9$exports = ".depict .rec_outer.noautospacing {\n width: 6cm;\n max-width: 46vw;\n margin-left: 1%;\n margin-right: 1%;\n}\n\n.depict .rec_outer.noautospacing:nth-child(1) {\n margin-left: 0;\n}\n\n.depict .rec_outer.noautospacing:nth-last-child(1) {\n margin-right: 0;\n}\n\n.depict-slider .slider_snap {\n scroll-snap-type: x mandatory;\n}\n\n.depict-slider {\n width: 100%;\n position: relative;\n}\n\n.depict-slider .sliding::-webkit-scrollbar {\n display: none;\n}\n\n.depict-slider .sliding {\n scroll-behavior: smooth;\n -ms-overflow-style: none;\n scrollbar-width: none;\n flex-flow: row;\n margin-top: -1%;\n margin-bottom: -2%;\n padding-top: 1%;\n padding-bottom: 2%;\n display: flex;\n overflow-x: scroll;\n}\n\n.depict-slider .sliding > * {\n box-sizing: border-box;\n flex: none;\n}\n\n.depict-slider button.right {\n right: 0;\n}\n\n.depict-slider button.left, .depict-slider button.right {\n z-index: 2;\n touch-action: manipulation;\n width: 1cm;\n height: 1cm;\n cursor: pointer;\n background: #fff;\n border: none;\n padding: .5%;\n transition-duration: .2s;\n position: absolute;\n top: 50%;\n transform: translateY(-50%);\n}\n\n.depict-slider button.left.hidden, .depict-slider button.right.hidden {\n opacity: 0;\n cursor: default;\n}\n\n.depict-slider button.left {\n left: 0;\n transform: translateY(-50%)rotate(180deg);\n}\n\n.depict-slider button.left img, .depict-slider button.right img {\n width: 100%;\n height: 100%;\n}\n\n.depict-slider .rec_outer {\n margin-top: 0 !important;\n}\n\n";
4929
4932
  const $e090b20cef3f0516$var$default_image_src = "data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4NCjwhLS0gR2VuZXJhdG9yOiBBZG9iZSBJbGx1c3RyYXRvciAyMy4wLjYsIFNWRyBFeHBvcnQgUGx1Zy1JbiAuIFNWRyBWZXJzaW9uOiA2LjAwIEJ1aWxkIDApICAtLT4NCjxzdmcgdmVyc2lvbj0iMS4xIiBpZD0iTGF5ZXJfMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIiB4bWxuczp4bGluaz0iaHR0cDovL3d3dy53My5vcmcvMTk5OS94bGluayIgeD0iMHB4IiB5PSIwcHgiDQoJIHZpZXdCb3g9IjAgMCAxNiAxNiIgc3R5bGU9ImVuYWJsZS1iYWNrZ3JvdW5kOm5ldyAwIDAgMTYgMTY7IiB4bWw6c3BhY2U9InByZXNlcnZlIj4NCjxwb2x5Z29uIHBvaW50cz0iOSwyLjYgOC4zLDMuNCAxMi40LDcuNSAxLjYsNy41IDEuNiw4LjUgMTIuNCw4LjUgOC4zLDEyLjYgOSwxMy40IDE0LjQsOCAiLz4NCjwvc3ZnPg0K";
4930
4933
  class $e090b20cef3f0516$export$4d41c6499d53639c extends (0, $a69a5236b5814082$export$68babfc5be0de5da) {
4931
4934
  constructor(static_options, override_lazyfier_options) {
@@ -4941,7 +4944,7 @@ class $e090b20cef3f0516$export$4d41c6499d53639c extends (0, $a69a5236b5814082$ex
4941
4944
  super(options, {
4942
4945
  lazyfinder: {
4943
4946
  unload(image) {
4944
- (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(async () => {
4947
+ $268cbd9e4ade92db$export$b3bbfd758f11cfa9(async () => {
4945
4948
  if (!image?.dataset?.src?.length) {
4946
4949
  image.dataset.src = image.src;
4947
4950
  image.removeAttribute("src");
@@ -4956,7 +4959,7 @@ class $e090b20cef3f0516$export$4d41c6499d53639c extends (0, $a69a5236b5814082$ex
4956
4959
  function $e090b20cef3f0516$export$f1b8b9fd75ddcab1(slider) {
4957
4960
  const style_elem = document.createElement("style");
4958
4961
  style_elem.type = "text/css";
4959
- style_elem.append((0, /*@__PURE__*/$parcel$interopDefault($1259ff510e3d4a71$exports)));
4962
+ style_elem.append((0, /*@__PURE__*/$parcel$interopDefault($0bdfc1d6f84716d9$exports)));
4960
4963
  slider.container.appendChild(style_elem);
4961
4964
  }
4962
4965
  async function $7af744346f17bf99$export$cd12721587f4f16d(t, rendering_options, options_for_us, slider_options, override_lazyfier_options) {
@@ -4973,7 +4976,7 @@ async function $7af744346f17bf99$export$cd12721587f4f16d(t, rendering_options, o
4973
4976
  let {
4974
4977
  container: container
4975
4978
  } = options_for_us;
4976
- if (typeof container == "string") container = [...(0, $bf7f12fe044e41b2$export$44951404cb8d0583)(container)];
4979
+ if (typeof container == "string") container = [...$bf7f12fe044e41b2$export$44951404cb8d0583(container)];
4977
4980
  if (container && !Array.isArray(container)) container = [...container];
4978
4981
  const slider = new (0, $e090b20cef3f0516$export$4d41c6499d53639c)({
4979
4982
  dlog: dlog,
@@ -4985,7 +4988,7 @@ async function $7af744346f17bf99$export$cd12721587f4f16d(t, rendering_options, o
4985
4988
  const recs = await local_rr(t, {
4986
4989
  ...rendering_options,
4987
4990
  post_processors: [(elements, display) => {
4988
- (0, $bf7f12fe044e41b2$export$5e63aea0cac01fa0)(elements, "a.rec_outer").forEach(ro => ro.classList.add("noautospacing"));
4991
+ $bf7f12fe044e41b2$export$5e63aea0cac01fa0(elements, "a.rec_outer").forEach(ro => ro.classList.add("noautospacing"));
4989
4992
  return elements;
4990
4993
  }, ...(rendering_options.post_processors || [])]
4991
4994
  });
@@ -4995,7 +4998,7 @@ async function $7af744346f17bf99$export$cd12721587f4f16d(t, rendering_options, o
4995
4998
  }
4996
4999
  slider.insert_here.append(...recs.elements);
4997
5000
  if (container) {
4998
- const [root] = (0, $bf7f12fe044e41b2$export$5e63aea0cac01fa0)(container, root_selector || ".grid");
5001
+ const [root] = $bf7f12fe044e41b2$export$5e63aea0cac01fa0(container, root_selector || ".grid");
4999
5002
  root[insertion_verb](slider.container);
5000
5003
  }
5001
5004
  return {
@@ -5027,8 +5030,8 @@ async function $765ddca135d7ab33$export$30933c637c977eef({
5027
5030
  catchify: catchify,
5028
5031
  dlog: dlog
5029
5032
  } = t,
5030
- container = [...(0, $bf7f12fe044e41b2$export$44951404cb8d0583)(container_template)],
5031
- root = (0, $bf7f12fe044e41b2$export$5e63aea0cac01fa0)(container, ".grid")[0],
5033
+ container = [...$bf7f12fe044e41b2$export$44951404cb8d0583(container_template)],
5034
+ root = $bf7f12fe044e41b2$export$5e63aea0cac01fa0(container, ".grid")[0],
5032
5035
  internal_pre_processors = [...pre_processors],
5033
5036
  // copy arrays so we don't unintentionally modify an array of a script calling us when doing auto postprocessor for slider if insertion_promise is defined
5034
5037
  internal_post_processors = [...post_processors];
@@ -5041,7 +5044,7 @@ async function $765ddca135d7ab33$export$30933c637c977eef({
5041
5044
  root.replaceWith(slider.container);
5042
5045
  if (insertion_promise) internal_post_processors.push((t, items, d) => {
5043
5046
  for (const item of items) insertion_promise.then(() => {
5044
- (0, $8e19f8200d357fe7$export$37125ccc5dd98050)({
5047
+ $8e19f8200d357fe7$export$37125ccc5dd98050({
5045
5048
  element: item,
5046
5049
  data: {
5047
5050
  tenant: t.tenant,
@@ -5058,7 +5061,7 @@ async function $765ddca135d7ab33$export$30933c637c977eef({
5058
5061
  });
5059
5062
  }
5060
5063
  if (!slider || !insertion_promise) internal_post_processors.push((t, items, d) => {
5061
- for (const item of items) (0, $8e19f8200d357fe7$export$37125ccc5dd98050)({
5064
+ for (const item of items) $8e19f8200d357fe7$export$37125ccc5dd98050({
5062
5065
  element: item,
5063
5066
  data: {
5064
5067
  tenant: t.tenant,
@@ -5072,7 +5075,7 @@ async function $765ddca135d7ab33$export$30933c637c977eef({
5072
5075
  });
5073
5076
  return items;
5074
5077
  });
5075
- const template_tool = await (0, $52d3be7ce5146924$export$2e2bcd8739ae039)({
5078
+ const template_tool = await $52d3be7ce5146924$export$2e2bcd8739ae039({
5076
5079
  options: {
5077
5080
  ...t,
5078
5081
  ...(template_tool_options || {})
@@ -5096,7 +5099,7 @@ async function $765ddca135d7ab33$export$30933c637c977eef({
5096
5099
  if (with_loadmore) catchify($765ddca135d7ab33$var$setup_load_more)(t, root, chunk_size_for_load_more);
5097
5100
  if (infinite_scroll) catchify($765ddca135d7ab33$var$setup_infinite_scroll)(t, root);
5098
5101
  if (title) {
5099
- const [title_element] = (0, $bf7f12fe044e41b2$export$5e63aea0cac01fa0)(container, "h1.title, h2.title, h3.title, h4.title, h5.title, h6.title");
5102
+ const [title_element] = $bf7f12fe044e41b2$export$5e63aea0cac01fa0(container, "h1.title, h2.title, h3.title, h4.title, h5.title, h6.title");
5100
5103
  if (title_element) {
5101
5104
  if (typeof title == "string") title_element.innerText = title;else title_element.replaceWith(...title);
5102
5105
  }
@@ -5141,8 +5144,8 @@ function $765ddca135d7ab33$var$setup_load_more(t, root, chunk_size) {
5141
5144
  const {
5142
5145
  catchify: catchify
5143
5146
  } = t,
5144
- load_more_cont = (0, $bf7f12fe044e41b2$export$d3e2a0560cbf4787)(`<div class="load-more-container"></div>`),
5145
- load_button = load_more_cont.appendChild((0, $bf7f12fe044e41b2$export$d3e2a0560cbf4787)(`<button class="load_more">Visa mer</button>`));
5147
+ load_more_cont = $bf7f12fe044e41b2$export$d3e2a0560cbf4787(`<div class="load-more-container"></div>`),
5148
+ load_button = load_more_cont.appendChild($bf7f12fe044e41b2$export$d3e2a0560cbf4787(`<button class="load_more">Visa mer</button>`));
5146
5149
  load_button.addEventListener("click", catchify(load_more_recs_and_hide_button_if_needed));
5147
5150
  root.after(load_more_cont);
5148
5151
  load_more_recs_and_hide_button_if_needed();
@@ -5211,7 +5214,7 @@ $c413c7798924612a$export$2e2bcd8739ae039 = (dlog, error_log) => {
5211
5214
  } : {})
5212
5215
  }).then(async response => {
5213
5216
  if (!response || !response.ok || response.status !== 200) {
5214
- if (response.status === 422) (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)($c413c7798924612a$var$send_sentry_422)(response, body, stack);
5217
+ if (response.status === 422) $268cbd9e4ade92db$export$b3bbfd758f11cfa9($c413c7798924612a$var$send_sentry_422)(response, body, stack);
5215
5218
  elog("Response not ok", response);
5216
5219
  return false;
5217
5220
  } else return await response[decode_json ? "json" : "text"]().catch(e => elog("error while decoding json", e));
@@ -5226,32 +5229,32 @@ $c413c7798924612a$export$2e2bcd8739ae039 = (dlog, error_log) => {
5226
5229
  async function $c413c7798924612a$var$send_sentry_422(response, body, stack) {
5227
5230
  const msg = `Validation error: got 422 from API`;
5228
5231
  const text = await response.text();
5229
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)(msg, "body", body, "response", response, "text", text, "stack", stack);
5232
+ $e6c6e7929ea385ae$export$de56f1198d121036(msg, "body", body, "response", response, "text", text, "stack", stack);
5230
5233
  (0, $61a34358bf0d3d8b$export$af2e17a20c2ea3c5).withScope(function (scope) {
5231
5234
  scope.setExtra("stack", stack);
5232
5235
  scope.setExtra("request_body", body);
5233
5236
  scope.setExtra("response", response);
5234
- scope.setExtra("serialized_response", (0, $45e05ec4fd7f1ee7$export$39d526a1194b6499)(response));
5237
+ scope.setExtra("serialized_response", $45e05ec4fd7f1ee7$export$39d526a1194b6499(response));
5235
5238
  scope.setExtra("response_text", text);
5236
5239
  scope.setLevel("error");
5237
5240
  this.captureException(new Error(msg));
5238
5241
  });
5239
5242
  }
5240
- const $c3af1bfb402a8820$export$dc84183312f0c201 = /*@__PURE__*/(() => (0, $107a74aa4ea5902d$export$25062201e9e25d76)("svg", {
5243
+ const $c3af1bfb402a8820$export$dc84183312f0c201 = /*@__PURE__*/(() => $107a74aa4ea5902d$export$25062201e9e25d76("svg", {
5241
5244
  xmlns: "http://www.w3.org/2000/svg",
5242
5245
  viewBox: "0 0 320 512",
5243
- children: [(0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("desc", {
5246
+ children: [$107a74aa4ea5902d$export$34b9dba7ce09269b("desc", {
5244
5247
  children: "Right arrow"
5245
- }), (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("path", {
5248
+ }), $107a74aa4ea5902d$export$34b9dba7ce09269b("path", {
5246
5249
  d: "M285.476 272.971L91.132 467.314c-9.373 9.373-24.569 9.373-33.941 0l-22.667-22.667c-9.357-9.357-9.375-24.522-.04-33.901L188.505 256 34.484 101.255c-9.335-9.379-9.317-24.544.04-33.901l22.667-22.667c9.373-9.373 24.569-9.373 33.941 0L285.475 239.03c9.373 9.372 9.373 24.568.001 33.941z"
5247
5250
  })]
5248
5251
  }))();
5249
- const $c3af1bfb402a8820$export$6038895ac52bd044 = /*@__PURE__*/(() => (0, $107a74aa4ea5902d$export$25062201e9e25d76)("svg", {
5252
+ const $c3af1bfb402a8820$export$6038895ac52bd044 = /*@__PURE__*/(() => $107a74aa4ea5902d$export$25062201e9e25d76("svg", {
5250
5253
  xmlns: "http://www.w3.org/2000/svg",
5251
5254
  viewBox: "0 0 320 512",
5252
- children: [(0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("desc", {
5255
+ children: [$107a74aa4ea5902d$export$34b9dba7ce09269b("desc", {
5253
5256
  children: "Left arrow"
5254
- }), (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("path", {
5257
+ }), $107a74aa4ea5902d$export$34b9dba7ce09269b("path", {
5255
5258
  d: "M34.52 239.03L228.87 44.69c9.37-9.37 24.57-9.37 33.94 0l22.67 22.67c9.36 9.36 9.37 24.52.04 33.9L131.49 256l154.02 154.75c9.34 9.38 9.32 24.54-.04 33.9l-22.67 22.67c-9.37 9.37-24.57 9.37-33.94 0L34.52 272.97c-9.37-9.37-9.37-24.57 0-33.94z"
5256
5259
  })]
5257
5260
  }))();
@@ -5268,7 +5271,7 @@ const $febdc40c8da5c25e$export$68c017fd93791405 = ({
5268
5271
  container.append(content);
5269
5272
  const expand = () => {
5270
5273
  container.style.height = content.clientHeight + "px";
5271
- setTimeout((0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(() => {
5274
+ setTimeout($268cbd9e4ade92db$export$b3bbfd758f11cfa9(() => {
5272
5275
  container.style.overflow = "unset";
5273
5276
  container.style.height = "auto";
5274
5277
  }), duration);
@@ -5280,14 +5283,14 @@ const $febdc40c8da5c25e$export$68c017fd93791405 = ({
5280
5283
  };
5281
5284
  };
5282
5285
  function $ef237c2bba47492f$export$f8913c8a18f7ca21(iterables) {
5283
- const ourselves = (0, $9a42a570de51ea3d$export$e806c6c1615a59ae)();
5286
+ const ourselves = $9a42a570de51ea3d$export$e806c6c1615a59ae();
5284
5287
  const values = new Array(iterables.length);
5285
- Promise.all(iterables.map((0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(async (iterable, index) => {
5288
+ Promise.all(iterables.map($268cbd9e4ade92db$export$b3bbfd758f11cfa9(async (iterable, index) => {
5286
5289
  for await (const value of iterable) {
5287
5290
  values[index] = value;
5288
5291
  ourselves([...values]);
5289
5292
  }
5290
- }))).then((0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(ourselves.exit));
5293
+ }))).then($268cbd9e4ade92db$export$b3bbfd758f11cfa9(ourselves.exit));
5291
5294
  return ourselves;
5292
5295
  }
5293
5296
  const $1cc2444a0f1b992e$export$717f13d9ba00ca19 = (min, max) => `@media ${min ? `(min-width:${min})` : ``}${min && max ? ` and ` : ``}${max ? `(max-width:${max})` : ``}`;
@@ -5310,16 +5313,16 @@ async function $1cc2444a0f1b992e$export$c84671f46d6a1ca({
5310
5313
  ipns: ipns
5311
5314
  } = rows_or_empty_object;
5312
5315
  const is_static = !ipns && !button;
5313
- const our_style_el = (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("style", {
5316
+ const our_style_el = $107a74aa4ea5902d$export$34b9dba7ce09269b("style", {
5314
5317
  type: "text/css"
5315
5318
  });
5316
- const container_class = (0, $650b64c1b384c895$export$a6db784f019668ba)();
5319
+ const container_class = $650b64c1b384c895$export$a6db784f019668ba();
5317
5320
  const selector_beginning = `.depict .${container_class}>`;
5318
- const el_count_ipns = (0, $9a42a570de51ea3d$export$e806c6c1615a59ae)();
5321
+ const el_count_ipns = $9a42a570de51ea3d$export$e806c6c1615a59ae();
5319
5322
  const set_length = () => el_count_ipns(container_element.children.length);
5320
5323
  const col_styling = $1cc2444a0f1b992e$export$17c3166a7ebd4688(selector_beginning, grid_spacing, cols_at_size, layout, override_vertical_spacing);
5321
5324
  let button_class;
5322
- ipns ||= (0, $9a42a570de51ea3d$export$e806c6c1615a59ae)();
5325
+ ipns ||= $9a42a570de51ea3d$export$e806c6c1615a59ae();
5323
5326
  container_element.after(our_style_el);
5324
5327
  container_element.classList.add(container_class);
5325
5328
  if (rows === "all") {
@@ -5329,7 +5332,7 @@ async function $1cc2444a0f1b992e$export$c84671f46d6a1ca({
5329
5332
  }
5330
5333
  ipns(start_rows);
5331
5334
  set_length();
5332
- const mutation_observer = new MutationObserver((0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(set_length));
5335
+ const mutation_observer = new MutationObserver($268cbd9e4ade92db$export$b3bbfd758f11cfa9(set_length));
5333
5336
  (0, $2a1cbc63a04d4a2d$export$b6ae1bc530f4c149).oncreation(container_element, ({
5334
5337
  element: element
5335
5338
  }) => {
@@ -5348,15 +5351,15 @@ async function $1cc2444a0f1b992e$export$c84671f46d6a1ca({
5348
5351
  ipns.exit();
5349
5352
  });
5350
5353
  if (button) {
5351
- button_class = (0, $650b64c1b384c895$export$a6db784f019668ba)();
5352
- const button_container = (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("div", {
5354
+ button_class = $650b64c1b384c895$export$a6db784f019668ba();
5355
+ const button_container = $107a74aa4ea5902d$export$34b9dba7ce09269b("div", {
5353
5356
  class: "load-more-container " + button_class,
5354
- children: (0, $90e0b983530610e7$export$f63fcc839cb0f734)("click", () => ipns(ipns.state + (rows_or_empty_object.rows_per_click ?? 1)), button)
5357
+ children: $90e0b983530610e7$export$f63fcc839cb0f734("click", () => ipns(ipns.state + (rows_or_empty_object.rows_per_click ?? 1)), button)
5355
5358
  });
5356
5359
  container_element.after(button_container);
5357
5360
  }
5358
5361
  (0, $2a1cbc63a04d4a2d$export$b6ae1bc530f4c149).oncreation(container_element, async () => {
5359
- for await (const [currently_showing_rows, number_of_els] of (0, $ef237c2bba47492f$export$f8913c8a18f7ca21)([
5362
+ for await (const [currently_showing_rows, number_of_els] of $ef237c2bba47492f$export$f8913c8a18f7ca21([
5360
5363
  // start for await loop when the container element gets inserted into the DOM
5361
5364
  // the loop is broken by an observer.onremoved above calling .exit on the IPNS this depends on
5362
5365
  // @ts-ignore
@@ -5524,7 +5527,7 @@ async function $a7315720bf2a1638$export$b0a773486c1c2312(t, recommendation_rende
5524
5527
  eager_images: eager_images,
5525
5528
  ...options_for_grid
5526
5529
  }) {
5527
- const [insertion_point] = (0, $bf7f12fe044e41b2$export$5e63aea0cac01fa0)(container_elements, container_selector || ".grid");
5530
+ const [insertion_point] = $bf7f12fe044e41b2$export$5e63aea0cac01fa0(container_elements, container_selector || ".grid");
5528
5531
  const rendering_result = await (override_rec_renderer || (0, $92bde32714bb1e07$export$2e2bcd8739ae039))(t, recommendation_renderer_options);
5529
5532
  const {
5530
5533
  elements: elements
@@ -5535,7 +5538,7 @@ async function $a7315720bf2a1638$export$b0a773486c1c2312(t, recommendation_rende
5535
5538
  // when the elements are in the DOM starts IntersectionObserver on whole grid
5536
5539
  // when grid intersects starts Lazyfier
5537
5540
  // this is because Lazyfier is fucking stupid
5538
- (0, $2a1cbc63a04d4a2d$export$b6ae1bc530f4c149).wait_for_element(insertion_point).then((0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(element => {
5541
+ (0, $2a1cbc63a04d4a2d$export$b6ae1bc530f4c149).wait_for_element(insertion_point).then($268cbd9e4ade92db$export$b3bbfd758f11cfa9(element => {
5539
5542
  let start_lazy_loading;
5540
5543
  const lazy_loading_promise = new Promise(r => start_lazy_loading = r);
5541
5544
  const lf = new (0, $1da560af170fb839$export$3be7054c61590ee3)({
@@ -5544,7 +5547,7 @@ async function $a7315720bf2a1638$export$b0a773486c1c2312(t, recommendation_rende
5544
5547
  ...lazyfier_options
5545
5548
  });
5546
5549
  lf.start_observing_for_new_children_(element);
5547
- const i_o = new IntersectionObserver((0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(records => {
5550
+ const i_o = new IntersectionObserver($268cbd9e4ade92db$export$b3bbfd758f11cfa9(records => {
5548
5551
  for (const record of records) if (record.intersectionRatio > 0) {
5549
5552
  start_lazy_loading();
5550
5553
  i_o.disconnect();
@@ -5554,7 +5557,7 @@ async function $a7315720bf2a1638$export$b0a773486c1c2312(t, recommendation_rende
5554
5557
  i_o.observe(insertion_point);
5555
5558
  }));
5556
5559
  insertion_point.append(...elements);
5557
- (0, $1cc2444a0f1b992e$export$c84671f46d6a1ca)({
5560
+ $1cc2444a0f1b992e$export$c84671f46d6a1ca({
5558
5561
  ...options_for_grid,
5559
5562
  container_element: insertion_point,
5560
5563
  layout: "grid"
@@ -5566,8 +5569,8 @@ async function $a7315720bf2a1638$export$b0a773486c1c2312(t, recommendation_rende
5566
5569
  }
5567
5570
 
5568
5571
  // @ts-ignore
5569
- var $7b8e569839dd1ea3$exports = {};
5570
- $7b8e569839dd1ea3$exports = ".depict-slider {\n width: 100%;\n position: relative;\n}\n\n.depict-slider .sliding {\n scroll-behavior: smooth;\n -ms-overflow-style: none;\n scrollbar-width: none;\n flex-flow: row;\n display: flex;\n overflow-x: scroll;\n}\n\n.depict-slider .sliding::-webkit-scrollbar {\n display: none;\n}\n\n.depict-slider .sliding > * {\n box-sizing: border-box;\n flex: none;\n}\n\n";
5572
+ var $6f9658642611ab01$exports = {};
5573
+ $6f9658642611ab01$exports = ".depict-slider {\n width: 100%;\n position: relative;\n}\n\n.depict-slider .sliding {\n scroll-behavior: smooth;\n -ms-overflow-style: none;\n scrollbar-width: none;\n flex-flow: row;\n display: flex;\n overflow-x: scroll;\n}\n\n.depict-slider .sliding::-webkit-scrollbar {\n display: none;\n}\n\n.depict-slider .sliding > * {\n box-sizing: border-box;\n flex: none;\n}\n\n";
5571
5574
  let $79804e8d76404ae4$var$slider_styling_was_inserted = false;
5572
5575
  async function $79804e8d76404ae4$export$82cfdc85a4d15688(t, recommendation_renderer_options, {
5573
5576
  container_elements: container_elements,
@@ -5581,7 +5584,7 @@ async function $79804e8d76404ae4$export$82cfdc85a4d15688(t, recommendation_rende
5581
5584
  rows = "all",
5582
5585
  ...slider_options
5583
5586
  }) {
5584
- const [insertion_point] = (0, $bf7f12fe044e41b2$export$5e63aea0cac01fa0)(container_elements, container_selector || ".grid");
5587
+ const [insertion_point] = $bf7f12fe044e41b2$export$5e63aea0cac01fa0(container_elements, container_selector || ".grid");
5585
5588
  const slider = eager_images ? new (0, $1683d0164abd7c1d$export$692b27c28639e5b9)(slider_options) : new (0, $a69a5236b5814082$export$68babfc5be0de5da)(slider_options, lazyfier_options);
5586
5589
  const rendering_result = await (override_rec_renderer || (0, $92bde32714bb1e07$export$2e2bcd8739ae039))(t, recommendation_renderer_options);
5587
5590
  const {
@@ -5590,18 +5593,18 @@ async function $79804e8d76404ae4$export$82cfdc85a4d15688(t, recommendation_rende
5590
5593
  if (!elements) return rendering_result;
5591
5594
  if (!$79804e8d76404ae4$var$slider_styling_was_inserted) {
5592
5595
  $79804e8d76404ae4$var$slider_styling_was_inserted = true;
5593
- (0, $e4bebbfa0f0b1454$export$59ba1eb2c083f0cd)((0, /*@__PURE__*/$parcel$interopDefault($7b8e569839dd1ea3$exports)));
5596
+ $e4bebbfa0f0b1454$export$59ba1eb2c083f0cd((0, /*@__PURE__*/$parcel$interopDefault($6f9658642611ab01$exports)));
5594
5597
  }
5595
5598
  insertion_point.replaceWith(slider.container);
5596
5599
  slider.insert_here.append(...elements);
5597
- (0, $1cc2444a0f1b992e$export$c84671f46d6a1ca)({
5600
+ $1cc2444a0f1b992e$export$c84671f46d6a1ca({
5598
5601
  grid_spacing: grid_spacing,
5599
5602
  cols_at_size: cols_at_size,
5600
5603
  container_element: slider.insert_here,
5601
5604
  rows: rows,
5602
5605
  layout: "slider",
5603
5606
  override_vertical_spacing: override_vertical_spacing
5604
- }).catch(e => (0, $268cbd9e4ade92db$export$f18d5b0af29128b7)([e, "Grid had an error"], "warning"));
5607
+ }).catch(e => $268cbd9e4ade92db$export$f18d5b0af29128b7([e, "Grid had an error"], "warning"));
5605
5608
  return {
5606
5609
  ...rendering_result,
5607
5610
  slider: slider,
@@ -5625,11 +5628,11 @@ function $535c6ee2337e2717$export$8cbd8aa1c70f9a13(interval = 5000) {
5625
5628
  return {
5626
5629
  constructor_plugin() {
5627
5630
  const set_scroll_int = interval_scroll.bind(this);
5628
- this.container.addEventListener("click", (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(() => {
5631
+ this.container.addEventListener("click", $268cbd9e4ade92db$export$b3bbfd758f11cfa9(() => {
5629
5632
  clearInterval(timer);
5630
5633
  set_scroll_int();
5631
5634
  }));
5632
- this.container.addEventListener("mousedown", (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(() => {
5635
+ this.container.addEventListener("mousedown", $268cbd9e4ade92db$export$b3bbfd758f11cfa9(() => {
5633
5636
  clearInterval(timer);
5634
5637
  }));
5635
5638
  set_scroll_int();
@@ -5646,7 +5649,7 @@ function $a8a0385b88626561$export$80039a49055269fb() {
5646
5649
  return Object.fromEntries(["left", "right"].map(side => [side, [new_arrowimage()]]));
5647
5650
  }
5648
5651
  function $edc9fe0b09e00df6$export$af88b4929c2dc86() {
5649
- const img = (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("img", {
5652
+ const img = $107a74aa4ea5902d$export$34b9dba7ce09269b("img", {
5650
5653
  src: "data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHN0eWxlPSJkaXNwbGF5OiBpbmxpbmUtYmxvY2s7IHZlcnRpY2FsLWFsaWduOiBtaWRkbGU7IiB3aWR0aD0iMTZweCIgaGVpZ2h0PSIxNnB4IiB2aWV3Qm94PSIwIDAgOCAxNSI+PHBhdGggc3R5bGU9ImZpbGw6IHJnYigwLCAwLCAwKTsiIGQ9Ik0uNjI5LjAwMWMuMTUuMDA4LjI5My4wNzIuMzk4LjE4bDYuNzkyIDYuODlhLjYwMS42MDEgMCAwIDEgMCAuODZsLTYuNzkyIDYuODg4YS41ODYuNTg2IDAgMCAxLS44NDYgMCAuNjAxLjYwMSAwIDAgMSAwLS44Nkw2LjU1NCA3LjUuMjExIDEuMDAxYS42MDEuNjAxIDAgMCAxIDAtLjg2Yy4xMTUtLjEuMjY2LS4xNS40MTgtLjE0Ij48L3BhdGg+PC9zdmc+"
5651
5654
  });
5652
5655
  return {
@@ -5741,12 +5744,12 @@ function $158313c0231e6555$export$1d17a045bcc711b1({
5741
5744
  };
5742
5745
  }
5743
5746
  function $158313c0231e6555$export$a09282b33e69b43f(unique_name) {
5744
- return (0, $107a74aa4ea5902d$export$25062201e9e25d76)("label", {
5747
+ return $107a74aa4ea5902d$export$25062201e9e25d76("label", {
5745
5748
  class: "checkbox_container",
5746
- children: [(0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("input", {
5749
+ children: [$107a74aa4ea5902d$export$34b9dba7ce09269b("input", {
5747
5750
  type: "radio",
5748
5751
  name: `radio-${unique_name}`
5749
- }), (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("span", {
5752
+ }), $107a74aa4ea5902d$export$34b9dba7ce09269b("span", {
5750
5753
  class: "checkmark"
5751
5754
  })]
5752
5755
  });
@@ -5830,7 +5833,7 @@ function $98ef92db220106f3$export$411b0f20794697ce(t) {
5830
5833
  }
5831
5834
  function mutation_plugin(intersections, intersecting_mutations) {}
5832
5835
  function instant_post_pro(items) {
5833
- (0, $bf7f12fe044e41b2$export$5e63aea0cac01fa0)(items, "a, img, canvas").forEach(el => {
5836
+ $bf7f12fe044e41b2$export$5e63aea0cac01fa0(items, "a, img, canvas").forEach(el => {
5834
5837
  // @ts-ignore
5835
5838
  el.draggable = false;
5836
5839
  el.addEventListener("dragstart", e => {
@@ -5892,10 +5895,10 @@ function $91f7baba008bce7d$export$5723caf9a8335aa6(_t, fraction = 1, max_steps,
5892
5895
  configurable: true,
5893
5896
  enumerable: true,
5894
5897
  set(v) {
5895
- (0, $548fd58b14b25a52$export$8048b892d651b310)(new Error("Cannot set steps to slide manually when using fractional scroll"));
5898
+ $548fd58b14b25a52$export$8048b892d651b310(new Error("Cannot set steps to slide manually when using fractional scroll"));
5896
5899
  return v;
5897
5900
  },
5898
- get: (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(() => {
5901
+ get: $268cbd9e4ade92db$export$b3bbfd758f11cfa9(() => {
5899
5902
  const sliding_width = sliding.getBoundingClientRect().width;
5900
5903
  const first_rec = sliding.firstElementChild;
5901
5904
  if (!first_rec)
@@ -5907,7 +5910,7 @@ function $91f7baba008bce7d$export$5723caf9a8335aa6(_t, fraction = 1, max_steps,
5907
5910
  const stepsize_limited_up = max_steps && calculated_stepsize > max_steps ? max_steps : calculated_stepsize;
5908
5911
  const stepsize_limited_up_and_down = min_steps && stepsize_limited_up < min_steps ? min_steps : stepsize_limited_up;
5909
5912
  const stepby = stepsize_limited_up_and_down || fallback_stepsize;
5910
- if (stepby != calculated_stepsize) (0, $e6c6e7929ea385ae$export$de56f1198d121036)("going by", stepby, "because of max_steps or invalid stepsize");
5913
+ if (stepby != calculated_stepsize) $e6c6e7929ea385ae$export$de56f1198d121036("going by", stepby, "because of max_steps or invalid stepsize");
5911
5914
  return stepby;
5912
5915
  })
5913
5916
  });
@@ -5920,10 +5923,10 @@ function $91f7baba008bce7d$export$5723caf9a8335aa6(_t, fraction = 1, max_steps,
5920
5923
  }
5921
5924
  function $1942530ef27e571b$export$93223e488e7ee078(options) {
5922
5925
  function constructor_plugin(_slider_options) {
5923
- const scroll_bar = (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("div", {
5926
+ const scroll_bar = $107a74aa4ea5902d$export$34b9dba7ce09269b("div", {
5924
5927
  class: "depict_slider_scroll_bar"
5925
5928
  });
5926
- const scroll_container = (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("div", {
5929
+ const scroll_container = $107a74aa4ea5902d$export$34b9dba7ce09269b("div", {
5927
5930
  class: "depict_slider_scroll_container"
5928
5931
  });
5929
5932
  if (options.scroll_bar_classes?.length) scroll_bar.classList.add(...options.scroll_bar_classes);
@@ -5958,14 +5961,14 @@ function $6af20338fcad1911$export$b36d2489a5a16728(_t, {
5958
5961
  } = {}) {
5959
5962
  function constructor_plugin(_slider_options) {
5960
5963
  const slider_this = this;
5961
- const random_classname = "x" + (0, $650b64c1b384c895$export$656831b7e9c341c3)().replaceAll(".", "");
5964
+ const random_classname = "x" + $650b64c1b384c895$export$656831b7e9c341c3().replaceAll(".", "");
5962
5965
  slider_this.insert_here.classList.add(random_classname);
5963
5966
  const style = document.createElement("style");
5964
5967
  style.append(`.depict .${random_classname}{scroll-snap-type:x mandatory}.depict .${random_classname}>*:nth-child(${snapEvery ?? 1}n + 1){scroll-snap-align:${align || "start"}}`);
5965
5968
  slider_this.snap_style = slider_this.container.appendChild(style);
5966
5969
  $6af20338fcad1911$export$49b950309ab787ad().then(we_can => {
5967
5970
  if (!we_can) {
5968
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Disabling slider snapping due browser where it's impossible to have working buttons and css snapping");
5971
+ $e6c6e7929ea385ae$export$de56f1198d121036("Disabling slider snapping due browser where it's impossible to have working buttons and css snapping");
5969
5972
  style.remove();
5970
5973
  delete slider_this["snap_style"];
5971
5974
  }
@@ -5981,9 +5984,9 @@ function $6af20338fcad1911$export$b36d2489a5a16728(_t, {
5981
5984
  }
5982
5985
  async function $6af20338fcad1911$export$49b950309ab787ad() {
5983
5986
  if ("scrollBehavior" in document.documentElement.style) return true;
5984
- const test_div = (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("div", {
5987
+ const test_div = $107a74aa4ea5902d$export$34b9dba7ce09269b("div", {
5985
5988
  style: "position: absolute; width: 1em; overflow: scroll; scroll-snap-type: x mandatory;",
5986
- children: (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("div", {
5989
+ children: $107a74aa4ea5902d$export$34b9dba7ce09269b("div", {
5987
5990
  style: "scroll-snap-align: start; color: transparent;",
5988
5991
  children: "test"
5989
5992
  })
@@ -6018,14 +6021,14 @@ function $379066823f8eeb0b$export$dac64fd35a4805a4(options = {}) {
6018
6021
  insert_here: sliding
6019
6022
  } = this;
6020
6023
  const scroll_abs_no_negative = target => this.scroll_to_abs(target < 0 ? 0 : target); // the slider ignores everything < 0 but we want it to move to the first card
6021
- sliding.addEventListener("mousedown", (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(() => {
6024
+ sliding.addEventListener("mousedown", $268cbd9e4ade92db$export$b3bbfd758f11cfa9(() => {
6022
6025
  lock_on_element.lock_active = true;
6023
6026
  const starting_ratio_left = ratio_left.ratio;
6024
6027
  lock_on_element.left = ratio_left.element;
6025
6028
  const starting_ratio_right = ratio_right.ratio;
6026
6029
  lock_on_element.right = ratio_right.element;
6027
6030
  const scroll_left_start = sliding.scrollLeft;
6028
- const mouseup_listener = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(e => {
6031
+ const mouseup_listener = $268cbd9e4ade92db$export$b3bbfd758f11cfa9(e => {
6029
6032
  lock_on_element.lock_active = false;
6030
6033
  const delta_left = Math.abs(ratio_left.ratio - starting_ratio_left);
6031
6034
  const delta_right = Math.abs(ratio_right.ratio - starting_ratio_right);
@@ -6037,7 +6040,7 @@ function $379066823f8eeb0b$export$dac64fd35a4805a4(options = {}) {
6037
6040
  try {
6038
6041
  currently_visible = Math.floor(this.insert_here.getBoundingClientRect().width / this.insert_here.firstElementChild.getBoundingClientRect().width);
6039
6042
  } catch (e) {
6040
- (0, $268cbd9e4ade92db$export$f18d5b0af29128b7)(e, "warning");
6043
+ $268cbd9e4ade92db$export$f18d5b0af29128b7(e, "warning");
6041
6044
  }
6042
6045
  const stepsize = options.stepsize || currently_visible || 4;
6043
6046
  if (scrolled_right) scroll_abs_no_negative(+currently_left + stepsize);else scroll_abs_no_negative(+currently_left - stepsize);
@@ -6081,8 +6084,8 @@ function $379066823f8eeb0b$export$dac64fd35a4805a4(options = {}) {
6081
6084
  }
6082
6085
  }
6083
6086
  return {
6084
- constructor_plugin: (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(constructor_plugin),
6085
- mutation_plugin: (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(mutation_plugin)
6087
+ constructor_plugin: $268cbd9e4ade92db$export$b3bbfd758f11cfa9(constructor_plugin),
6088
+ mutation_plugin: $268cbd9e4ade92db$export$b3bbfd758f11cfa9(mutation_plugin)
6086
6089
  };
6087
6090
  }
6088
6091
  function $3d8df0a23b9bebac$export$53306504b987cbf7({
@@ -6104,7 +6107,7 @@ function $3d8df0a23b9bebac$export$53306504b987cbf7({
6104
6107
  let are_far_right = false;
6105
6108
  let inactive_checker_timeout;
6106
6109
  // let elgreen;
6107
- const check_if_we_inactive = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(function () {
6110
+ const check_if_we_inactive = $268cbd9e4ade92db$export$b3bbfd758f11cfa9(function () {
6108
6111
  // const { insert_here: sliding } = this;
6109
6112
  const now = window?.performance?.now?.() || +new Date();
6110
6113
  const time_since_ran = now - last_move;
@@ -6115,7 +6118,7 @@ function $3d8df0a23b9bebac$export$53306504b987cbf7({
6115
6118
  // sliding.style.background = "green";
6116
6119
  // elgreen = true;
6117
6120
  // }
6118
- (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)($3d8df0a23b9bebac$var$scroll_idle)(this, originally_rendered_elements.length, clones_per_side);
6121
+ $268cbd9e4ade92db$export$b3bbfd758f11cfa9($3d8df0a23b9bebac$var$scroll_idle)(this, originally_rendered_elements.length, clones_per_side);
6119
6122
  inactive_checker_running = false;
6120
6123
  } else {
6121
6124
  // if (elgreen !== false) {
@@ -6129,10 +6132,10 @@ function $3d8df0a23b9bebac$export$53306504b987cbf7({
6129
6132
  function constructor_plugin() {
6130
6133
  window.addEventListener("touchstart", () => touches++);
6131
6134
  window.addEventListener("touchend", () => touches--);
6132
- this.insert_here.addEventListener("scroll", (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(() => {
6135
+ this.insert_here.addEventListener("scroll", $268cbd9e4ade92db$export$b3bbfd758f11cfa9(() => {
6133
6136
  last_move = window?.performance?.now?.() || +new Date();
6134
6137
  }));
6135
- const mo = new MutationObserver((0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(records => {
6138
+ const mo = new MutationObserver($268cbd9e4ade92db$export$b3bbfd758f11cfa9(records => {
6136
6139
  for (const record of records) for (const node of record.removedNodes) {
6137
6140
  if (removed_by_us.has(node)) {
6138
6141
  removed_by_us.delete(node);
@@ -6141,7 +6144,7 @@ function $3d8df0a23b9bebac$export$53306504b987cbf7({
6141
6144
  for (const a_set of sets_of_els) {
6142
6145
  const index_in_el_set = a_set.indexOf(node);
6143
6146
  if (index_in_el_set >= 0) {
6144
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Removing", node, "from el set", a_set);
6147
+ $e6c6e7929ea385ae$export$de56f1198d121036("Removing", node, "from el set", a_set);
6145
6148
  a_set.splice(index_in_el_set, 1);
6146
6149
  }
6147
6150
  }
@@ -6170,7 +6173,7 @@ function $3d8df0a23b9bebac$export$53306504b987cbf7({
6170
6173
  // calculate how many cards including margin the slider fits
6171
6174
  const first_rect = first_element.getBoundingClientRect();
6172
6175
  if (!first_rect.width) {
6173
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)(first_rect);
6176
+ $e6c6e7929ea385ae$export$de56f1198d121036(first_rect);
6174
6177
  throw new Error("First rect doesn't have width");
6175
6178
  }
6176
6179
  const second_rect = second_element.getBoundingClientRect();
@@ -6188,7 +6191,7 @@ function $3d8df0a23b9bebac$export$53306504b987cbf7({
6188
6191
  }
6189
6192
  if (dont_wraparound) {
6190
6193
  if (surplus_in_body) {
6191
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Removing surplus of els. Total els: ", sets_of_els);
6194
+ $e6c6e7929ea385ae$export$de56f1198d121036("Removing surplus of els. Total els: ", sets_of_els);
6192
6195
  // @ts-ignore
6193
6196
  for (let i = (sets_of_els.length || 1) - 1; i--;) for (let j = 0; j < sets_of_els[i].length; j++) {
6194
6197
  const el = sets_of_els[i][j];
@@ -6204,7 +6207,7 @@ function $3d8df0a23b9bebac$export$53306504b987cbf7({
6204
6207
  return;
6205
6208
  }
6206
6209
  if (!surplus_in_body) {
6207
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Adding surplus of els");
6210
+ $e6c6e7929ea385ae$export$de56f1198d121036("Adding surplus of els");
6208
6211
  this.insert_here.append(...sets_of_els.slice(0, -1).flat());
6209
6212
  this.invalidate_cache();
6210
6213
  surplus_in_body = true;
@@ -6242,11 +6245,11 @@ function $3d8df0a23b9bebac$export$53306504b987cbf7({
6242
6245
  if (our_index >= 0) post_processors.splice(our_index, 1);else {
6243
6246
  const msg = "Couldn't find ourselves in post processors, infinite loop might ensue. Exiting. Wraparound will be broken.";
6244
6247
  (0, $61a34358bf0d3d8b$export$af2e17a20c2ea3c5).captureException(new Error(msg));
6245
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)(msg, () => {});
6248
+ $e6c6e7929ea385ae$export$de56f1198d121036(msg, () => {});
6246
6249
  return elements;
6247
6250
  }
6248
6251
  for (let i = 0; i < clones_per_side * 2; i++) {
6249
- const additional_render = await (0, $558ccd2de887e6d9$export$a9fc160c5ed83bd7)(info.t, {
6252
+ const additional_render = await $558ccd2de887e6d9$export$a9fc160c5ed83bd7(info.t, {
6250
6253
  ...rendering_options,
6251
6254
  post_processors: post_processors,
6252
6255
  pre_processors: [],
@@ -6360,7 +6363,7 @@ function $3721a5ccba25c247$export$3d04c40e7acc1a32(initial_value) {
6360
6363
  function $93c499898a1702c7$export$515c3ea4d599b05a(
6361
6364
  // inspired by code in houdinisportswear modify script
6362
6365
  query, handler, initial_call = true) {
6363
- const catchified_handler = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(handler, "Error in media query listener callback");
6366
+ const catchified_handler = $268cbd9e4ade92db$export$b3bbfd758f11cfa9(handler, "Error in media query listener callback");
6364
6367
  if (typeof window !== "object") {
6365
6368
  // on server call the handler in case nothing is rendered if it isn't called, then do nothing
6366
6369
  catchified_handler({
@@ -6388,9 +6391,9 @@ async function $bf76a92ec2055e1a$export$417ef0ab13d8b984({
6388
6391
  let resolve_success_promise;
6389
6392
  const success_promise = new Promise(r => resolve_success_promise = r);
6390
6393
  const cache = new Map();
6391
- const [template_els, _get, set_els] = (0, $3721a5ccba25c247$export$3d04c40e7acc1a32)();
6392
- const catchified_switch_to_surface = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)($bf76a92ec2055e1a$var$switch_to_surface);
6393
- (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(async () => {
6394
+ const [template_els, _get, set_els] = $3721a5ccba25c247$export$3d04c40e7acc1a32();
6395
+ const catchified_switch_to_surface = $268cbd9e4ade92db$export$b3bbfd758f11cfa9($bf76a92ec2055e1a$var$switch_to_surface);
6396
+ $268cbd9e4ade92db$export$b3bbfd758f11cfa9(async () => {
6394
6397
  for await (const surface of current_surface_) {
6395
6398
  const rendering_function = surface_rendering_functions_[surface];
6396
6399
  catchified_switch_to_surface(surface, rendering_function, current_surface_, cache, set_els, resolve_success_promise);
@@ -6408,9 +6411,9 @@ async function $bf76a92ec2055e1a$var$switch_to_surface(surface_index, rendering_
6408
6411
  const {
6409
6412
  cache_until_: cache_until_,
6410
6413
  surface_: surface_
6411
- } = await rendering_function().catch(e => ((0, $268cbd9e4ade92db$export$f18d5b0af29128b7)([e, "error in rendering"], "warning"), {}));
6414
+ } = await rendering_function().catch(e => ($268cbd9e4ade92db$export$f18d5b0af29128b7([e, "error in rendering"], "warning"), {}));
6412
6415
  if (!surface_ || !surface_?.elements?.length) {
6413
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Got no/empty surface, not switching");
6416
+ $e6c6e7929ea385ae$export$de56f1198d121036("Got no/empty surface, not switching");
6414
6417
  // also tell insert_surface that we didn't get recs so it can revert, dunno if we want this
6415
6418
  resolve_success_promise(false);
6416
6419
  return;
@@ -6418,17 +6421,17 @@ async function $bf76a92ec2055e1a$var$switch_to_surface(surface_index, rendering_
6418
6421
  rendered_surface = surface_;
6419
6422
  if (cache_until_ instanceof Promise) {
6420
6423
  cache.set(surface_index, surface_);
6421
- cache_until_.then((0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(() => cache.delete(surface_index)));
6424
+ cache_until_.then($268cbd9e4ade92db$export$b3bbfd758f11cfa9(() => cache.delete(surface_index)));
6422
6425
  }
6423
6426
  }
6424
6427
  if (current_surface_ipns.state !== surface_index) {
6425
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Surface switched to", current_surface_ipns.state, "while rendering surface", surface_index, "discarding results");
6428
+ $e6c6e7929ea385ae$export$de56f1198d121036("Surface switched to", current_surface_ipns.state, "while rendering surface", surface_index, "discarding results");
6426
6429
  return;
6427
6430
  }
6428
6431
  set_els(rendered_surface.elements);
6429
6432
  if (rendered_surface.should_stay_inserted instanceof Promise)
6430
6433
  // if there is promise that says if surface succeeded or not, use that
6431
- rendered_surface.should_stay_inserted.then((0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(success => {
6434
+ rendered_surface.should_stay_inserted.then($268cbd9e4ade92db$export$b3bbfd758f11cfa9(success => {
6432
6435
  resolve_success_promise(success);
6433
6436
  }));else
6434
6437
  // otherwise let's just assume it suceeded since there are elements
@@ -6436,12 +6439,12 @@ async function $bf76a92ec2055e1a$var$switch_to_surface(surface_index, rendering_
6436
6439
  }
6437
6440
  function $bf76a92ec2055e1a$export$419f84efad7d9fe(surface_per_size, cleanup_promise) {
6438
6441
  let microtask_queued = false;
6439
- const ipns = (0, $9a42a570de51ea3d$export$e806c6c1615a59ae)();
6442
+ const ipns = $9a42a570de51ea3d$export$e806c6c1615a59ae();
6440
6443
  const target_indexes = new Set();
6441
- const dedupe_overlapping_queries = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(() => {
6444
+ const dedupe_overlapping_queries = $268cbd9e4ade92db$export$b3bbfd758f11cfa9(() => {
6442
6445
  microtask_queued = false;
6443
6446
  const first_value = target_indexes[Symbol.iterator]().next().value;
6444
- if (first_value === ipns.latest_call_value) (0, $e6c6e7929ea385ae$export$de56f1198d121036)("surface", first_value, "is already selected");else ipns(first_value);
6447
+ if (first_value === ipns.latest_call_value) $e6c6e7929ea385ae$export$de56f1198d121036("surface", first_value, "is already selected");else ipns(first_value);
6445
6448
  if (target_indexes.size > 1) {
6446
6449
  const error_string = "Multiple matching media queries detected, used first one: " + JSON.stringify(surface_per_size.filter(([index]) => target_indexes.has(index)));
6447
6450
  target_indexes.clear();
@@ -6450,10 +6453,10 @@ function $bf76a92ec2055e1a$export$419f84efad7d9fe(surface_per_size, cleanup_prom
6450
6453
  target_indexes.clear();
6451
6454
  });
6452
6455
  surface_per_size.forEach(([surface_index, min, max]) => {
6453
- const media_query = (0, $1cc2444a0f1b992e$export$717f13d9ba00ca19)(min, max).split("@media ").pop();
6456
+ const media_query = $1cc2444a0f1b992e$export$717f13d9ba00ca19(min, max).split("@media ").pop();
6454
6457
  const {
6455
6458
  remove: remove
6456
- } = (0, $93c499898a1702c7$export$515c3ea4d599b05a)(media_query, ({
6459
+ } = $93c499898a1702c7$export$515c3ea4d599b05a(media_query, ({
6457
6460
  matches: matches
6458
6461
  }) => {
6459
6462
  if (!matches) return;
@@ -6463,21 +6466,21 @@ function $bf76a92ec2055e1a$export$419f84efad7d9fe(surface_per_size, cleanup_prom
6463
6466
  microtask_queued = true;
6464
6467
  }
6465
6468
  });
6466
- if (cleanup_promise instanceof Promise) cleanup_promise.then(remove);else (0, $69f7524c8bdd85b4$export$1cd22bab0d2c3b0b)(remove);
6469
+ if (cleanup_promise instanceof Promise) cleanup_promise.then(remove);else $69f7524c8bdd85b4$export$1cd22bab0d2c3b0b(remove);
6467
6470
  });
6468
6471
  return ipns;
6469
6472
  }
6470
6473
  function $bf76a92ec2055e1a$export$be95cb0e8cfd099e() {
6471
- return new Promise(r => (0, $69f7524c8bdd85b4$export$1cd22bab0d2c3b0b)(r));
6474
+ return new Promise(r => $69f7524c8bdd85b4$export$1cd22bab0d2c3b0b(r));
6472
6475
  }
6473
6476
  function $0c9d834f187cc4ff$export$3ebd86018b39d9d2(t, selector, filter) {
6474
6477
  (0, $2a1cbc63a04d4a2d$export$b6ae1bc530f4c149).onexists(selector, eoe => {
6475
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Order confirmation element showed up!", eoe);
6478
+ $e6c6e7929ea385ae$export$de56f1198d121036("Order confirmation element showed up!", eoe);
6476
6479
  const {
6477
6480
  element: element
6478
6481
  } = eoe;
6479
6482
  const the_id = element.innerText;
6480
- $0c9d834f187cc4ff$export$1ac466d53a6636ac(t, the_id, (0, $e0a87646d12cb987$export$6399bdb2291895e0)(), filter);
6483
+ $0c9d834f187cc4ff$export$1ac466d53a6636ac(t, the_id, $e0a87646d12cb987$export$6399bdb2291895e0(), filter);
6481
6484
  });
6482
6485
  }
6483
6486
  function $0c9d834f187cc4ff$export$b11248fa13a8a86c(tenant, id_extractor) {
@@ -6495,7 +6498,7 @@ function $0c9d834f187cc4ff$export$b11248fa13a8a86c(tenant, id_extractor) {
6495
6498
  try {
6496
6499
  maybe_send_entries(args_list);
6497
6500
  } catch (e) {
6498
- (0, $268cbd9e4ade92db$export$f18d5b0af29128b7)([e, "Extracting and sending transaction IDs from dataLayer failed"], "warning");
6501
+ $268cbd9e4ade92db$export$f18d5b0af29128b7([e, "Extracting and sending transaction IDs from dataLayer failed"], "warning");
6499
6502
  }
6500
6503
  return target.apply(this_arg, args_list);
6501
6504
  }
@@ -6507,15 +6510,15 @@ function $0c9d834f187cc4ff$export$ff8673d5dea82bd4(tenant, id_extractor) {
6507
6510
  const order_id = id_extractor(new URL(href));
6508
6511
  if (order_id && typeof order_id === "string") $0c9d834f187cc4ff$export$1ac466d53a6636ac(tenant, order_id);
6509
6512
  }
6510
- })().catch(e => (0, $268cbd9e4ade92db$export$f18d5b0af29128b7)([e, "Extracting and sending transaction IDs from URL failed"], "warning"));
6513
+ })().catch(e => $268cbd9e4ade92db$export$f18d5b0af29128b7([e, "Extracting and sending transaction IDs from URL failed"], "warning"));
6511
6514
  }
6512
- function $0c9d834f187cc4ff$export$1ac466d53a6636ac(t, input_id, dsid = (0, $e0a87646d12cb987$export$6399bdb2291895e0)(), filter) {
6515
+ function $0c9d834f187cc4ff$export$1ac466d53a6636ac(t, input_id, dsid = $e0a87646d12cb987$export$6399bdb2291895e0(), filter) {
6513
6516
  const transaction_id = typeof filter == "function" ? filter(input_id) : input_id;
6514
6517
  if (!transaction_id) {
6515
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Not sending", transaction_id, "because it didn't pass filter");
6518
+ $e6c6e7929ea385ae$export$de56f1198d121036("Not sending", transaction_id, "because it didn't pass filter");
6516
6519
  return;
6517
6520
  }
6518
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Sending this order id:", transaction_id, "(before filtering it was", input_id, ")");
6521
+ $e6c6e7929ea385ae$export$de56f1198d121036("Sending this order id:", transaction_id, "(before filtering it was", input_id, ")");
6519
6522
  const payload = {
6520
6523
  "tenant": t.tenant,
6521
6524
  "market": t.market,
@@ -6525,36 +6528,36 @@ function $0c9d834f187cc4ff$export$1ac466d53a6636ac(t, input_id, dsid = (0, $e0a8
6525
6528
  dsid: dsid
6526
6529
  }]
6527
6530
  };
6528
- (0, $0c84f8e99aac5765$export$cc3b6ddf805f6156)((0, $4c6861fbcd3a0611$export$362abebb4b313340) + "/v2/track", payload);
6531
+ $0c84f8e99aac5765$export$cc3b6ddf805f6156((0, $4c6861fbcd3a0611$export$362abebb4b313340) + "/v2/track", payload);
6529
6532
  }
6530
6533
  function $5a44db2d2c8361b9$export$1ff14fec60ed5697(t, filter) {
6531
6534
  try {
6532
- (0, $c18ce8dadd041cdd$export$674d8cd8b6868154)();
6533
- ga((0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(async function (tracker) {
6535
+ $c18ce8dadd041cdd$export$674d8cd8b6868154();
6536
+ ga($268cbd9e4ade92db$export$b3bbfd758f11cfa9(async function (tracker) {
6534
6537
  let get_all_function = window?.ga?.getAll; // https://sentry.io/organizations/depictai-0o/issues/3621911835/?project=5476183&referrer=slack
6535
- if (typeof get_all_function !== "function") get_all_function = await (0, $e6d67ef355abb2dc$export$2fc1a072736ae2f6)(window, "ga", "getAll");
6538
+ if (typeof get_all_function !== "function") get_all_function = await $e6d67ef355abb2dc$export$2fc1a072736ae2f6(window, "ga", "getAll");
6536
6539
  const all_trackers = get_all_function.call(ga);
6537
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("we have trackers", all_trackers);
6540
+ $e6c6e7929ea385ae$export$de56f1198d121036("we have trackers", all_trackers);
6538
6541
  // @ts-ignore
6539
6542
  const {
6540
6543
  P: P
6541
6544
  } = ga;
6542
- (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(modify_trackers_of_iterable)(all_trackers);
6545
+ $268cbd9e4ade92db$export$b3bbfd758f11cfa9(modify_trackers_of_iterable)(all_trackers);
6543
6546
  if (typeof P?.push === "function")
6544
6547
  // this check is just so we don't fail if this doesn't exist for some reason, but it always should
6545
6548
  P.push = new Proxy(P.push, {
6546
6549
  apply(target, this_arg, args_list) {
6547
6550
  const retval = target.apply(this_arg, args_list);
6548
- (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(modify_trackers_of_iterable)(args_list);
6551
+ $268cbd9e4ade92db$export$b3bbfd758f11cfa9(modify_trackers_of_iterable)(args_list);
6549
6552
  return retval;
6550
6553
  }
6551
6554
  });
6552
6555
  function modify_trackers_of_iterable(array) {
6553
- for (const tracker of array) (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)($5a44db2d2c8361b9$var$make_tracker_send_to_depict)(tracker, t, filter);
6556
+ for (const tracker of array) $268cbd9e4ade92db$export$b3bbfd758f11cfa9($5a44db2d2c8361b9$var$make_tracker_send_to_depict)(tracker, t, filter);
6554
6557
  }
6555
6558
  }));
6556
6559
  } catch (error) {
6557
- (0, $268cbd9e4ade92db$export$f18d5b0af29128b7)(error, "error");
6560
+ $268cbd9e4ade92db$export$f18d5b0af29128b7(error, "error");
6558
6561
  }
6559
6562
  }
6560
6563
  function $5a44db2d2c8361b9$var$make_tracker_send_to_depict(ga_tracker, t, filter) {
@@ -6566,22 +6569,22 @@ function $5a44db2d2c8361b9$var$make_tracker_send_to_depict(ga_tracker, t, filter
6566
6569
  originalSendHitTask(model);
6567
6570
  // console.log('Sent original hit, now sending to depict');
6568
6571
  try {
6569
- const dsid = (0, $e0a87646d12cb987$export$6399bdb2291895e0)();
6572
+ const dsid = $e0a87646d12cb987$export$6399bdb2291895e0();
6570
6573
  const payload = model.get("hitPayload");
6571
6574
  const sp = new URLSearchParams(payload);
6572
6575
  const id = sp.get("ti");
6573
6576
  if (id) {
6574
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Got interesting analytics request", payload, id);
6575
- (0, $0c9d834f187cc4ff$export$1ac466d53a6636ac)(t, id, dsid, filter);
6577
+ $e6c6e7929ea385ae$export$de56f1198d121036("Got interesting analytics request", payload, id);
6578
+ $0c9d834f187cc4ff$export$1ac466d53a6636ac(t, id, dsid, filter);
6576
6579
  }
6577
6580
  } catch (e) {
6578
- (0, $268cbd9e4ade92db$export$f18d5b0af29128b7)(e, "error");
6581
+ $268cbd9e4ade92db$export$f18d5b0af29128b7(e, "error");
6579
6582
  }
6580
6583
  });
6581
6584
  }
6582
6585
  async function $8594d423459ba80c$export$d63b08f4f29ddba5(t, unavailability_type) {
6583
6586
  const product_id = await t.get_product_id();
6584
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)(`Notifying Depict that product id: ${product_id} is ${unavailability_type}`);
6587
+ $e6c6e7929ea385ae$export$de56f1198d121036(`Notifying Depict that product id: ${product_id} is ${unavailability_type}`);
6585
6588
  const payload = {
6586
6589
  "tenant": t.tenant,
6587
6590
  "market": t.market,
@@ -6589,11 +6592,11 @@ async function $8594d423459ba80c$export$d63b08f4f29ddba5(t, unavailability_type)
6589
6592
  event_type: "product_unavailable",
6590
6593
  product_id: product_id,
6591
6594
  unavailability_type: unavailability_type,
6592
- user_id: (0, $e0a87646d12cb987$export$adc61a405a4cabed)(),
6593
- dsid: (0, $e0a87646d12cb987$export$6399bdb2291895e0)()
6595
+ user_id: $e0a87646d12cb987$export$adc61a405a4cabed(),
6596
+ dsid: $e0a87646d12cb987$export$6399bdb2291895e0()
6594
6597
  }]
6595
6598
  };
6596
- (0, $0c84f8e99aac5765$export$cc3b6ddf805f6156)((0, $4c6861fbcd3a0611$export$362abebb4b313340) + "/v2/track", payload);
6599
+ $0c84f8e99aac5765$export$cc3b6ddf805f6156((0, $4c6861fbcd3a0611$export$362abebb4b313340) + "/v2/track", payload);
6597
6600
  }
6598
6601
 
6599
6602
  /**
@@ -6653,11 +6656,11 @@ const $194791b6959e932d$export$6b75200e58bc97d0 = (arr1, arr2, compareFunc) => {
6653
6656
  const $194791b6959e932d$export$9426572bd5645bc1 = (arr1, arr2) => $194791b6959e932d$export$6b75200e58bc97d0(arr1, arr2 || [], (i1, i2) => i1.product_id === i2.product_id);
6654
6657
  function $1e9d51e365c02476$export$82539d9817116aff(e, url) {
6655
6658
  if (e.button) {
6656
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Not single page navigating because button is not 0", e);
6659
+ $e6c6e7929ea385ae$export$de56f1198d121036("Not single page navigating because button is not 0", e);
6657
6660
  return;
6658
6661
  }
6659
6662
  if (e.metaKey || e.ctrlKey) {
6660
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Someone command-clicked a link, not single page navigating");
6663
+ $e6c6e7929ea385ae$export$de56f1198d121036("Someone command-clicked a link, not single page navigating");
6661
6664
  return;
6662
6665
  }
6663
6666
  // single page navigate
@@ -6718,7 +6721,7 @@ class $7ccebf01cfe4f824$export$f8da66bc4f1d059e extends Response {
6718
6721
  }
6719
6722
  }
6720
6723
  function $23d6393391c08860$export$ab0f802c05dd969b(on_request) {
6721
- (0, $7ccebf01cfe4f824$export$85be83e1935d93c2)(async (target, this_arg, argument_list) => {
6724
+ $7ccebf01cfe4f824$export$85be83e1935d93c2(async (target, this_arg, argument_list) => {
6722
6725
  const response_promise = target.apply(this_arg, argument_list);
6723
6726
  try {
6724
6727
  const input = argument_list[0];
@@ -6754,7 +6757,7 @@ function $23d6393391c08860$export$ab0f802c05dd969b(on_request) {
6754
6757
  break;
6755
6758
  }
6756
6759
  } catch (e) {
6757
- (0, $268cbd9e4ade92db$export$f18d5b0af29128b7)([e, "error in shopify interception logic"], "warning");
6760
+ $268cbd9e4ade92db$export$f18d5b0af29128b7([e, "error in shopify interception logic"], "warning");
6758
6761
  }
6759
6762
  return await response_promise;
6760
6763
  }, true);
@@ -6786,8 +6789,8 @@ async function $23d6393391c08860$export$337197b94b3bd680() {
6786
6789
  const json = await response.json();
6787
6790
  if (Array.isArray(json.items)) return json.items;else if (typeof json.status === "number") return json;else throw new Error(`Shopify ${url} did not respond as expected`);
6788
6791
  }
6789
- const $23d6393391c08860$export$783ef16647773b3d = /*@__PURE__*/(0, $41f528c04cc8a8da$export$535946eb77c946dd)( /*@__PURE__*/(0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(async () => {
6790
- const meta = await (0, $e6d67ef355abb2dc$export$2fc1a072736ae2f6)(window, "ShopifyAnalytics", "meta");
6792
+ const $23d6393391c08860$export$783ef16647773b3d = /*@__PURE__*/$41f528c04cc8a8da$export$535946eb77c946dd( /*@__PURE__*/$268cbd9e4ade92db$export$b3bbfd758f11cfa9(async () => {
6793
+ const meta = await $e6d67ef355abb2dc$export$2fc1a072736ae2f6(window, "ShopifyAnalytics", "meta");
6791
6794
  return meta?.product;
6792
6795
  }));
6793
6796
  async function $40f3ad8d5c440ce9$export$b404e20f3c4a490e({
@@ -6801,7 +6804,7 @@ async function $40f3ad8d5c440ce9$export$b404e20f3c4a490e({
6801
6804
  Sentry: Sentry
6802
6805
  } = t,
6803
6806
  start = new Date().getTime(),
6804
- optimize = await (0, $e6d67ef355abb2dc$export$2fc1a072736ae2f6)(window, "google_optimize"),
6807
+ optimize = await $e6d67ef355abb2dc$export$2fc1a072736ae2f6(window, "google_optimize"),
6805
6808
  end = new Date().getTime();
6806
6809
  dlog("Waited for google_optimize for", end - start, "ms");
6807
6810
  // if (!optimize.get) {
@@ -6827,19 +6830,19 @@ async function $40f3ad8d5c440ce9$export$b404e20f3c4a490e({
6827
6830
  }
6828
6831
  function $b6542de877d46468$export$2c2f50b30b7b2576(el, attribute_name, async_iterable, quit_after_navigation = true) {
6829
6832
  (async () => {
6830
- const [exit, exitable_iterable] = (0, $bbe52965151ee7f0$export$927664b47117acb0)(async_iterable);
6831
- if (quit_after_navigation) (0, $69f7524c8bdd85b4$export$1cd22bab0d2c3b0b)(exit);
6833
+ const [exit, exitable_iterable] = $bbe52965151ee7f0$export$927664b47117acb0(async_iterable);
6834
+ if (quit_after_navigation) $69f7524c8bdd85b4$export$1cd22bab0d2c3b0b(exit);
6832
6835
  for await (const new_value of exitable_iterable) el.setAttribute(attribute_name, new_value);
6833
- })().catch(e => (0, $268cbd9e4ade92db$export$f18d5b0af29128b7)([e, "Failed to set attribute"], "error"));
6836
+ })().catch(e => $268cbd9e4ade92db$export$f18d5b0af29128b7([e, "Failed to set attribute"], "error"));
6834
6837
  return el;
6835
6838
  }
6836
6839
  function $374ca311b64f260b$export$7c081fdbc65b6a2a(async_iterable, quit_after_navigation = true) {
6837
- const [template_els, _get, set] = (0, $3721a5ccba25c247$export$3d04c40e7acc1a32)();
6840
+ const [template_els, _get, set] = $3721a5ccba25c247$export$3d04c40e7acc1a32();
6838
6841
  (async () => {
6839
- const [exit, exitable_iterable] = (0, $bbe52965151ee7f0$export$927664b47117acb0)(async_iterable);
6840
- if (quit_after_navigation) (0, $69f7524c8bdd85b4$export$1cd22bab0d2c3b0b)(exit);
6842
+ const [exit, exitable_iterable] = $bbe52965151ee7f0$export$927664b47117acb0(async_iterable);
6843
+ if (quit_after_navigation) $69f7524c8bdd85b4$export$1cd22bab0d2c3b0b(exit);
6841
6844
  for await (const els of exitable_iterable) set(els);
6842
- })().catch(e => (0, $268cbd9e4ade92db$export$f18d5b0af29128b7)([e, "Failed to convert AsyncIterable to elements"], "error"));
6845
+ })().catch(e => $268cbd9e4ade92db$export$f18d5b0af29128b7([e, "Failed to convert AsyncIterable to elements"], "error"));
6843
6846
  return template_els;
6844
6847
  }
6845
6848
  let $c693a2d89c78efe6$var$context_counter = 0; // last context that was created (unless 0), to make sure we don't have two of the same
@@ -6895,23 +6898,23 @@ function $c693a2d89c78efe6$export$f811d2ce0aa6019b({
6895
6898
  disconnect_reinsertion_observers?.(); // Not sure if necessary? But if we re-insert in the same container and don't disconnect preserve_elements observers before it might lead to two observers acting on one element
6896
6899
  disconnect_reinsertion_observers = $c693a2d89c78efe6$var$actual_insertion(element, verb, surfaces, try_forever, href, context, remove_after_navigation, preserve_elements);
6897
6900
  });
6898
- if (!try_forever) (0, $69f7524c8bdd85b4$export$1cd22bab0d2c3b0b)(disconnect_observer);
6901
+ if (!try_forever) $69f7524c8bdd85b4$export$1cd22bab0d2c3b0b(disconnect_observer);
6899
6902
  } else {
6900
6903
  if (!context && verb !== "replaceChildren") throw new Error("insert_surface, provided an element, may not be called without a context." + (process.env.DEBUG === "true" ? " Please wrap the function calling it into prevent_infinite_loop(). If you have already done that, make sure that there's no `await` before the calling of insert_surface" : ""));
6901
- (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)($c693a2d89c78efe6$var$actual_insertion)(target, verb, surfaces, try_forever, href, context, remove_after_navigation, preserve_elements);
6904
+ $268cbd9e4ade92db$export$b3bbfd758f11cfa9($c693a2d89c78efe6$var$actual_insertion)(target, verb, surfaces, try_forever, href, context, remove_after_navigation, preserve_elements);
6902
6905
  }
6903
6906
  return surfaces.map(({
6904
6907
  promise_: promise_
6905
6908
  }) => promise_);
6906
6909
  }
6907
- const $c693a2d89c78efe6$export$e3f70ef7e3d00501 = /*@__PURE__*/(0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(async (target, should_stay_inserted) => {
6910
+ const $c693a2d89c78efe6$export$e3f70ef7e3d00501 = /*@__PURE__*/$268cbd9e4ade92db$export$b3bbfd758f11cfa9(async (target, should_stay_inserted) => {
6908
6911
  const per_el_fn = (el, disconnect_observer) => {
6909
6912
  const comment_node = document.createComment("Old recs were here // Depict");
6910
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Replacing", el, "with", comment_node);
6913
+ $e6c6e7929ea385ae$export$de56f1198d121036("Replacing", el, "with", comment_node);
6911
6914
  el.replaceWith(comment_node);
6912
6915
  should_stay_inserted.then(keep => {
6913
6916
  if (!keep) {
6914
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Reverting", comment_node, "to", el);
6917
+ $e6c6e7929ea385ae$export$de56f1198d121036("Reverting", comment_node, "to", el);
6915
6918
  comment_node.replaceWith(el);
6916
6919
  disconnect_observer?.();
6917
6920
  }
@@ -6922,7 +6925,7 @@ const $c693a2d89c78efe6$export$e3f70ef7e3d00501 = /*@__PURE__*/(0, $268cbd9e4ade
6922
6925
  element: element,
6923
6926
  disconnector: disconnector
6924
6927
  }) => per_el_fn(element, disconnector));
6925
- (0, $69f7524c8bdd85b4$export$1cd22bab0d2c3b0b)(disconnect_observer);
6928
+ $69f7524c8bdd85b4$export$1cd22bab0d2c3b0b(disconnect_observer);
6926
6929
  } else {
6927
6930
  let did_already_fail = false;
6928
6931
  should_stay_inserted.then(should_stay_inserted => {
@@ -6930,7 +6933,7 @@ const $c693a2d89c78efe6$export$e3f70ef7e3d00501 = /*@__PURE__*/(0, $268cbd9e4ade
6930
6933
  });
6931
6934
  await 0;
6932
6935
  if (did_already_fail) {
6933
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Not removing", target, should_stay_inserted, "is already resolved to false");
6936
+ $e6c6e7929ea385ae$export$de56f1198d121036("Not removing", target, should_stay_inserted, "is already resolved to false");
6934
6937
  return;
6935
6938
  }
6936
6939
  if (Array.isArray(target)) for (let i = 0; i < target.length; i++) per_el_fn(target[i]);else per_el_fn(target);
@@ -6945,7 +6948,7 @@ function $c693a2d89c78efe6$var$actual_insertion(target, verb, surfaces, try_fore
6945
6948
  const disconnect_all_observers = () => disconnectors.forEach(disconnector => disconnector());
6946
6949
  const check_if_revert_whole = () => {
6947
6950
  if (failed_surfaces !== surfaces.length) return; // we didn't fail
6948
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)(`All surfaces`, surfaces, `failed. ${was_replaced ? "Reverting to old els" : "removing els"}`);
6951
+ $e6c6e7929ea385ae$export$de56f1198d121036(`All surfaces`, surfaces, `failed. ${was_replaced ? "Reverting to old els" : "removing els"}`);
6949
6952
  $c693a2d89c78efe6$var$failed_contexts.add(context);
6950
6953
  disconnect_all_observers();
6951
6954
  const flat_tnodes = template_nodes.flat();
@@ -6958,29 +6961,29 @@ function $c693a2d89c78efe6$var$actual_insertion(target, verb, surfaces, try_fore
6958
6961
  surface_: surface_,
6959
6962
  resolve_promise_: resolve_promise_
6960
6963
  }) => {
6961
- const [template_els, _get, set] = (0, $3721a5ccba25c247$export$3d04c40e7acc1a32)();
6964
+ const [template_els, _get, set] = $3721a5ccba25c247$export$3d04c40e7acc1a32();
6962
6965
  (async () => {
6963
6966
  let surface;
6964
6967
  try {
6965
6968
  surface = await surface_;
6966
6969
  } catch (e) {
6967
- (0, $268cbd9e4ade92db$export$f18d5b0af29128b7)([e, "A surface promise rejected" + (process.env.DEBUG === "true" ? " please catch this earlier" : "")], "warning");
6970
+ $268cbd9e4ade92db$export$f18d5b0af29128b7([e, "A surface promise rejected" + (process.env.DEBUG === "true" ? " please catch this earlier" : "")], "warning");
6968
6971
  }
6969
6972
  if (!try_forever && location.href !== starting_href)
6970
6973
  // navigated away
6971
6974
  return;
6972
6975
  // @ts-ignore
6973
6976
  if (surface?.elements) {
6974
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("insert_surface:", target, "." + verb, surface);
6977
+ $e6c6e7929ea385ae$export$de56f1198d121036("insert_surface:", target, "." + verb, surface);
6975
6978
  set(surface.elements);
6976
- if (surface.should_stay_inserted instanceof Promise) surface.should_stay_inserted.then((0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(keep => {
6979
+ if (surface.should_stay_inserted instanceof Promise) surface.should_stay_inserted.then($268cbd9e4ade92db$export$b3bbfd758f11cfa9(keep => {
6977
6980
  if (keep)
6978
6981
  // @ts-ignore
6979
6982
  resolve_promise_({
6980
6983
  surface: surface,
6981
6984
  succeeded: true
6982
6985
  });else {
6983
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Removing surface", surface, "because it failed");
6986
+ $e6c6e7929ea385ae$export$de56f1198d121036("Removing surface", surface, "because it failed");
6984
6987
  set("");
6985
6988
  // @ts-ignore
6986
6989
  resolve_promise_({
@@ -7003,7 +7006,7 @@ function $c693a2d89c78efe6$var$actual_insertion(target, verb, surfaces, try_fore
7003
7006
  failed_surfaces++;
7004
7007
  check_if_revert_whole();
7005
7008
  }
7006
- })().catch(e => (0, $268cbd9e4ade92db$export$f18d5b0af29128b7)([e, "insert_surface failed due to technical errors"], "error"));
7009
+ })().catch(e => $268cbd9e4ade92db$export$f18d5b0af29128b7([e, "insert_surface failed due to technical errors"], "error"));
7007
7010
  return template_els;
7008
7011
  });
7009
7012
  target[verb](...template_nodes.flat());
@@ -7012,10 +7015,10 @@ function $c693a2d89c78efe6$var$actual_insertion(target, verb, surfaces, try_fore
7012
7015
  const already_observing_nodes = new WeakSet();
7013
7016
  $c693a2d89c78efe6$var$deal_w_removal_of_node_array(node_array, disconnectors.push.bind(disconnectors), already_observing_nodes);
7014
7017
  }
7015
- if (remove_after_navigation) (0, $69f7524c8bdd85b4$export$1cd22bab0d2c3b0b)(() => {
7018
+ if (remove_after_navigation) $69f7524c8bdd85b4$export$1cd22bab0d2c3b0b(() => {
7016
7019
  disconnect_all_observers();
7017
7020
  template_nodes.flat().forEach(tn => tn.remove());
7018
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Removed", template_nodes, "due to navigation");
7021
+ $e6c6e7929ea385ae$export$de56f1198d121036("Removed", template_nodes, "due to navigation");
7019
7022
  });
7020
7023
  return disconnect_all_observers;
7021
7024
  }
@@ -7039,7 +7042,7 @@ function $c693a2d89c78efe6$var$deal_w_removal_of_node_array(node_array, push_dis
7039
7042
  target: target
7040
7043
  } = mutation_record;
7041
7044
  if (previous_parent !== target) {
7042
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)(element, "was removed", eoe, "but because a parent got removed we're keeping it that way");
7045
+ $e6c6e7929ea385ae$export$de56f1198d121036(element, "was removed", eoe, "but because a parent got removed we're keeping it that way");
7043
7046
  return;
7044
7047
  }
7045
7048
  if (node_array.every(node => target.contains(node))) {
@@ -7047,18 +7050,18 @@ function $c693a2d89c78efe6$var$deal_w_removal_of_node_array(node_array, push_dis
7047
7050
  // node_array is a reference to an updating array
7048
7051
  // it has always updated once this callback is ran, so we can just check if the new value are currently in the DOM
7049
7052
  // here we don't check the order but I don't think it's going to be an issue?
7050
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Ignoring removal of", element, eoe, "because it seems to come from reactive_template change");
7053
+ $e6c6e7929ea385ae$export$de56f1198d121036("Ignoring removal of", element, eoe, "because it seems to come from reactive_template change");
7051
7054
  // protect future nodes
7052
7055
  $c693a2d89c78efe6$var$deal_w_removal_of_node_array(node_array, push_disconnector, already_observing_nodes);
7053
7056
  } else if (!target.contains(element)) {
7054
7057
  // it's possible that the element already was re-inserted at the same time (this callback is executed a tick late), we obv. don't want to attempt to reinsert then
7055
7058
  if (removals_in_last_s > 10) {
7056
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("More than 10 reinsertions in last second, ignoring");
7059
+ $e6c6e7929ea385ae$export$de56f1198d121036("More than 10 reinsertions in last second, ignoring");
7057
7060
  return;
7058
7061
  }
7059
7062
  removals_in_last_s++;
7060
7063
  setTimeout(() => removals_in_last_s--, 1000);
7061
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)(element, "was removed from DOM,", eoe, "reinserting");
7064
+ $e6c6e7929ea385ae$export$de56f1198d121036(element, "was removed from DOM,", eoe, "reinserting");
7062
7065
  const {
7063
7066
  documentElement: documentElement
7064
7067
  } = document;
@@ -7071,7 +7074,7 @@ function $c693a2d89c78efe6$var$deal_w_removal_of_node_array(node_array, push_dis
7071
7074
  push_disconnector(disconnect_observer);
7072
7075
  }
7073
7076
  }
7074
- const $fac9c96b6bbe43cd$export$3b75288f46cadd96 = () => new Array((0, $3f34dc07544c5857$export$bb0a9c36cf454ea0)(3, 8)).fill("⬜").join("");
7077
+ const $fac9c96b6bbe43cd$export$3b75288f46cadd96 = () => new Array($3f34dc07544c5857$export$bb0a9c36cf454ea0(3, 8)).fill("⬜").join("");
7075
7078
  const $fac9c96b6bbe43cd$var$make_sel = (image_url, attribute) => `[${attribute}=${JSON.stringify(image_url)}]`;
7076
7079
  const $fac9c96b6bbe43cd$export$a4eccf92efefa04d = (image_width, image_height, color = "#f6f7f8") => `data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='${image_width}' height='${image_height}' xmlns:v='https://vecta.io/nano'%3e%3cpath d='M0 0h${image_width}.016v${image_height}.01H0' fill='${encodeURIComponent(color)}'/%3e%3c/svg%3e`;
7077
7080
  async function $fac9c96b6bbe43cd$export$2dd69958012e3e49({
@@ -7108,9 +7111,9 @@ async function $fac9c96b6bbe43cd$export$2dd69958012e3e49({
7108
7111
  for (const elem of elems) {
7109
7112
  if (elem instanceof HTMLElement) elem.style.cursor = "default";
7110
7113
  elem?.classList?.add?.("placeholder");
7111
- elem.addEventListener("click", e => ((0, $e6c6e7929ea385ae$export$de56f1198d121036)("Supressing placeholder click", e), e.preventDefault(), e.stopPropagation(), false), true);
7114
+ elem.addEventListener("click", e => ($e6c6e7929ea385ae$export$de56f1198d121036("Supressing placeholder click", e), e.preventDefault(), e.stopPropagation(), false), true);
7112
7115
  }
7113
- for (const img of (0, $bf7f12fe044e41b2$export$5e63aea0cac01fa0)(elems, ["src", "srcset", "data-src", "data-srcset"].map(attribute => $fac9c96b6bbe43cd$var$make_sel(image_url, attribute)).join(", "))) img.classList.add("nolazy"); // this gets ignored by all lazyloaders
7116
+ for (const img of $bf7f12fe044e41b2$export$5e63aea0cac01fa0(elems, ["src", "srcset", "data-src", "data-srcset"].map(attribute => $fac9c96b6bbe43cd$var$make_sel(image_url, attribute)).join(", "))) img.classList.add("nolazy"); // this gets ignored by all lazyloaders
7114
7117
  return elems;
7115
7118
  }]
7116
7119
  };
@@ -7119,9 +7122,9 @@ async function $fac9c96b6bbe43cd$export$2dd69958012e3e49({
7119
7122
  let set_should_stay_inserted;
7120
7123
  const should_stay_inserted = new Promise(r => set_should_stay_inserted = r);
7121
7124
  if (placeholder_rendering?.elements) {
7122
- const [template_els, _get_state, set_state] = (0, $3721a5ccba25c247$export$3d04c40e7acc1a32)(placeholder_rendering.elements);
7125
+ const [template_els, _get_state, set_state] = $3721a5ccba25c247$export$3d04c40e7acc1a32(placeholder_rendering.elements);
7123
7126
  actual_rendering.then(async rendering_result => {
7124
- if (typeof post_rendering == "function") await (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(post_rendering)(rendering_result);
7127
+ if (typeof post_rendering == "function") await $268cbd9e4ade92db$export$b3bbfd758f11cfa9(post_rendering)(rendering_result);
7125
7128
  const {
7126
7129
  elements: elements
7127
7130
  } = rendering_result || {};
@@ -7141,7 +7144,7 @@ async function $fac9c96b6bbe43cd$export$2dd69958012e3e49({
7141
7144
  should_stay_inserted: should_stay_inserted
7142
7145
  };
7143
7146
  } else {
7144
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Placeholder rendering went wrong, this is bad! Ditching placeholders");
7147
+ $e6c6e7929ea385ae$export$de56f1198d121036("Placeholder rendering went wrong, this is bad! Ditching placeholders");
7145
7148
  return (await actual_rendering) || {};
7146
7149
  }
7147
7150
  };
@@ -7155,7 +7158,7 @@ function $d91a08ea384e6cd4$export$8ec5c86406f333ff() {
7155
7158
  try {
7156
7159
  return target.apply(this_arg, arguments_list);
7157
7160
  } catch (e) {
7158
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Swallowing error of removal of node that we have removed or created", e, el);
7161
+ $e6c6e7929ea385ae$export$de56f1198d121036("Swallowing error of removal of node that we have removed or created", e, el);
7159
7162
  }
7160
7163
  return el;
7161
7164
  }
@@ -7191,7 +7194,7 @@ function $6d0c26cd36f5eeff$export$38e89c688f9d553a() {
7191
7194
  const w = window;
7192
7195
  let da_promise = w[$6d0c26cd36f5eeff$var$promise_as_string];
7193
7196
  let iframe_promise;
7194
- if ((typeof da_promise.allSettled !== "function" || typeof da_promise?.prototype?.finally !== "function") && !(0, $bd274a272f8400ec$export$4fbbab6c30e664d5)(da_promise) && (iframe_promise = $6d0c26cd36f5eeff$export$e647444ed9403635())) da_promise = iframe_promise;
7197
+ if ((typeof da_promise.allSettled !== "function" || typeof da_promise?.prototype?.finally !== "function") && !$bd274a272f8400ec$export$4fbbab6c30e664d5(da_promise) && (iframe_promise = $6d0c26cd36f5eeff$export$e647444ed9403635())) da_promise = iframe_promise;
7195
7198
  if (da_promise) {
7196
7199
  if (Object.getOwnPropertyDescriptor(w, $6d0c26cd36f5eeff$var$promise_as_string)?.configurable !== false) Object.defineProperty(w, $6d0c26cd36f5eeff$var$promise_as_string, {
7197
7200
  configurable: false,
@@ -7202,10 +7205,10 @@ function $6d0c26cd36f5eeff$export$38e89c688f9d553a() {
7202
7205
  set(value) {
7203
7206
  return value;
7204
7207
  }
7205
- });else (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Unable to redefine " + $6d0c26cd36f5eeff$var$promise_as_string + ", it's already nonconfigurable");
7208
+ });else $e6c6e7929ea385ae$export$de56f1198d121036("Unable to redefine " + $6d0c26cd36f5eeff$var$promise_as_string + ", it's already nonconfigurable");
7206
7209
  }
7207
7210
  } catch (e) {
7208
- (0, $548fd58b14b25a52$export$8048b892d651b310)(e);
7211
+ $548fd58b14b25a52$export$8048b892d651b310(e);
7209
7212
  }
7210
7213
  }
7211
7214
  function $6d0c26cd36f5eeff$export$e647444ed9403635() {
@@ -7215,7 +7218,7 @@ function $6d0c26cd36f5eeff$export$e647444ed9403635() {
7215
7218
  return iframe?.contentWindow?.[$6d0c26cd36f5eeff$var$promise_as_string];
7216
7219
  }
7217
7220
  function $61201159f98f0375$export$33d1643df63073a8(fetch_handler) {
7218
- fetch_handler = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(fetch_handler);
7221
+ fetch_handler = $268cbd9e4ade92db$export$b3bbfd758f11cfa9(fetch_handler);
7219
7222
  const {
7220
7223
  prototype: prototype
7221
7224
  } = XMLHttpRequest;
@@ -7224,17 +7227,17 @@ function $61201159f98f0375$export$33d1643df63073a8(fetch_handler) {
7224
7227
  if (Array.isArray(arg_array)) {
7225
7228
  const request = this_arg;
7226
7229
  const [method, url] = arg_array;
7227
- (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(fetch_handler)(request, method, url, arg_array);
7230
+ $268cbd9e4ade92db$export$b3bbfd758f11cfa9(fetch_handler)(request, method, url, arg_array);
7228
7231
  }
7229
7232
  return target.apply(this_arg, arg_array);
7230
7233
  }
7231
7234
  });
7232
7235
  }
7233
7236
  function $61201159f98f0375$export$f314addd5f976083(handler) {
7234
- $61201159f98f0375$export$33d1643df63073a8((req, method, url) => req.addEventListener("load", (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(event => handler(req, method, url, event))));
7237
+ $61201159f98f0375$export$33d1643df63073a8((req, method, url) => req.addEventListener("load", $268cbd9e4ade92db$export$b3bbfd758f11cfa9(event => handler(req, method, url, event))));
7235
7238
  }
7236
7239
  async function $61201159f98f0375$export$c74578d2cd47a84a(send_callback) {
7237
- const catchified_callback = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(send_callback);
7240
+ const catchified_callback = $268cbd9e4ade92db$export$b3bbfd758f11cfa9(send_callback);
7238
7241
  const requests = new WeakMap();
7239
7242
  $61201159f98f0375$export$33d1643df63073a8((request, _method, _url, arg_array) => {
7240
7243
  requests.set(request, arg_array);
@@ -7247,14 +7250,14 @@ async function $61201159f98f0375$export$c74578d2cd47a84a(send_callback) {
7247
7250
  try {
7248
7251
  if (requests.has(this_request)) catchified_callback(this_request, requests.get(this_request), arg_list);
7249
7252
  } catch (e) {
7250
- (0, $548fd58b14b25a52$export$8048b892d651b310)(e);
7253
+ $548fd58b14b25a52$export$8048b892d651b310(e);
7251
7254
  }
7252
7255
  return target.apply(this_request, arg_list);
7253
7256
  }
7254
7257
  });
7255
7258
  }
7256
7259
  async function $61201159f98f0375$export$8e16c51fd2b6507(read_callback) {
7257
- const catchified_read_callback = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(read_callback);
7260
+ const catchified_read_callback = $268cbd9e4ade92db$export$b3bbfd758f11cfa9(read_callback);
7258
7261
  const open_send_arg_map = new WeakMap();
7259
7262
  const {
7260
7263
  prototype: prototype
@@ -7275,7 +7278,7 @@ async function $61201159f98f0375$export$8e16c51fd2b6507(read_callback) {
7275
7278
  return catchified_read_callback(this_arg, open_args, send_args, default_value, n) || default_value;
7276
7279
  } catch (e) {
7277
7280
  // in case the weakmaps fail for some reason
7278
- (0, $548fd58b14b25a52$export$8048b892d651b310)(e);
7281
+ $548fd58b14b25a52$export$8048b892d651b310(e);
7279
7282
  return default_value;
7280
7283
  }
7281
7284
  }
@@ -7292,11 +7295,11 @@ async function $2780129735dc272e$export$83ec13b10b391f13(orig_url = process.env.
7292
7295
  const orig_url_with_trailing_slash = o_u_u_o.protocol + "//" + o_u_u_o.host + "/";
7293
7296
  if (orig_url) {
7294
7297
  // change links
7295
- (0, $bf7f12fe044e41b2$export$d4bd03f19260ef1c)(orig_url_with_trailing_slash, false, location.hostname);
7298
+ $bf7f12fe044e41b2$export$d4bd03f19260ef1c(orig_url_with_trailing_slash, false, location.hostname);
7296
7299
  $2780129735dc272e$export$2a1cc61cffa1f36f(orig_url_with_trailing_slash);
7297
7300
  $2780129735dc272e$export$2a38b176ce969e2c(orig_url_with_trailing_slash);
7298
7301
  $2780129735dc272e$export$f14a775632a826c4(orig_url_with_trailing_slash);
7299
- } else (0, $e6c6e7929ea385ae$export$de56f1198d121036)(new Error("No ORIG_URL env var was set, demo fixes not gonna work."));
7302
+ } else $e6c6e7929ea385ae$export$de56f1198d121036(new Error("No ORIG_URL env var was set, demo fixes not gonna work."));
7300
7303
  }
7301
7304
  function $2780129735dc272e$export$f14a775632a826c4(orig_url_with_trailing_slash) {
7302
7305
  // rewrite history.pushState and history.replaceState so that it works if someone calls it with absolute URLs
@@ -7313,21 +7316,21 @@ function $2780129735dc272e$export$f14a775632a826c4(orig_url_with_trailing_slash)
7313
7316
  }
7314
7317
  function $2780129735dc272e$export$2a1cc61cffa1f36f(orig_url_with_trailing_slash) {
7315
7318
  // rewrite fetch requests just in case, maybe we should also rewrite responses
7316
- (0, $7ccebf01cfe4f824$export$85be83e1935d93c2)(async (target, this_arg, arg_list) => {
7319
+ $7ccebf01cfe4f824$export$85be83e1935d93c2(async (target, this_arg, arg_list) => {
7317
7320
  try {
7318
7321
  const [url] = arg_list;
7319
7322
  if (typeof url == "string") arg_list[0] = url.replaceAll(orig_url_with_trailing_slash, "/");else if (url instanceof Request) {
7320
7323
  if (url.url.includes(orig_url_with_trailing_slash)) arg_list[0] = new Request(url.url.replaceAll(orig_url_with_trailing_slash, "/"), url);
7321
7324
  }
7322
7325
  } catch (e) {
7323
- (0, $548fd58b14b25a52$export$8048b892d651b310)(e);
7326
+ $548fd58b14b25a52$export$8048b892d651b310(e);
7324
7327
  }
7325
7328
  return target.apply(this_arg, arg_list);
7326
7329
  });
7327
7330
  }
7328
7331
  function $2780129735dc272e$export$2a38b176ce969e2c(orig_url_with_trailing_slash) {
7329
7332
  // rewrite xhr requests just in case
7330
- (0, $61201159f98f0375$export$33d1643df63073a8)((request, method, url, arg_array) => {
7333
+ $61201159f98f0375$export$33d1643df63073a8((request, method, url, arg_array) => {
7331
7334
  if (url instanceof URL) url.href = url.href.replaceAll(orig_url_with_trailing_slash, "/");else if (typeof url == "string") arg_array[1] = url.replaceAll(orig_url_with_trailing_slash, "");
7332
7335
  });
7333
7336
  }
@@ -7403,11 +7406,11 @@ function $02a3425594231893$export$a422d714c8cb1a5d(allowed_markets, url, tenant
7403
7406
  return "se";
7404
7407
  }
7405
7408
  function $05802e6cb0fdbdcd$export$3427ec8268623f1(listener) {
7406
- if (!(0, $1da560af170fb839$export$b87d7e0da8b5cbe3)()) {
7407
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Not hooking localStorage as it would freeze it due to lacking Proxy support");
7409
+ if (!$1da560af170fb839$export$b87d7e0da8b5cbe3()) {
7410
+ $e6c6e7929ea385ae$export$de56f1198d121036("Not hooking localStorage as it would freeze it due to lacking Proxy support");
7408
7411
  return;
7409
7412
  }
7410
- const caught_listener = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(listener);
7413
+ const caught_listener = $268cbd9e4ade92db$export$b3bbfd758f11cfa9(listener);
7411
7414
  let changed_instance;
7412
7415
  const update_changed_instance = () => changed_instance = Storage.prototype.setItem !== localStorage.setItem;
7413
7416
  update_changed_instance();
@@ -7475,7 +7478,7 @@ function $05802e6cb0fdbdcd$export$3427ec8268623f1(listener) {
7475
7478
  changed_this_args.add(fn_with_changed_this_arg);
7476
7479
  }
7477
7480
  } catch (e) {
7478
- if (key !== "length") (0, $e6c6e7929ea385ae$export$de56f1198d121036)(e);
7481
+ if (key !== "length") $e6c6e7929ea385ae$export$de56f1198d121036(e);
7479
7482
  }
7480
7483
  }
7481
7484
 
@@ -7489,16 +7492,16 @@ function $9ed7c4b0fbf9ccd8$export$cd1adfb8059b5fcd(promise, ms) {
7489
7492
  }
7490
7493
  const $5185cc9bd668b8f9$var$get_voyado_id = () => {
7491
7494
  const va = /\b_vaI=([^;]+)/.exec(document.cookie)?.[1];
7492
- return va || (0, $e0a87646d12cb987$export$6399bdb2291895e0)();
7495
+ return va || $e0a87646d12cb987$export$6399bdb2291895e0();
7493
7496
  };
7494
- const $5185cc9bd668b8f9$export$a739d9a07da7f9ce = /*@__PURE__*/(0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(() => {
7495
- (0, $e0a87646d12cb987$export$336e7ad40bae0652)($5185cc9bd668b8f9$var$get_voyado_id);
7497
+ const $5185cc9bd668b8f9$export$a739d9a07da7f9ce = /*@__PURE__*/$268cbd9e4ade92db$export$b3bbfd758f11cfa9(() => {
7498
+ $e0a87646d12cb987$export$336e7ad40bae0652($5185cc9bd668b8f9$var$get_voyado_id);
7496
7499
  });
7497
7500
  function $dba3e72fb3e5c53d$export$4a3043e508dd72f0({
7498
7501
  children: children,
7499
7502
  ...attributes
7500
7503
  }) {
7501
- const button = (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("button", {
7504
+ const button = $107a74aa4ea5902d$export$34b9dba7ce09269b("button", {
7502
7505
  ...attributes,
7503
7506
  type: "button",
7504
7507
  children: children
@@ -7515,30 +7518,30 @@ async function $a7550e9f97f84465$export$8a0e4d6f6abf7e90({
7515
7518
  let close_;
7516
7519
  const open_promise = new Promise(r => close_ = r);
7517
7520
  const body = await (0, $2a1cbc63a04d4a2d$export$b6ae1bc530f4c149).wait_for_element("body");
7518
- const backdrop = (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("div", {
7521
+ const backdrop = $107a74aa4ea5902d$export$34b9dba7ce09269b("div", {
7519
7522
  class: "slidein-backdrop",
7520
7523
  onClick: close_
7521
7524
  });
7522
- const [exit_title_iterator, exitable_title_iterator] = (0, $bbe52965151ee7f0$export$927664b47117acb0)(title_);
7525
+ const [exit_title_iterator, exitable_title_iterator] = $bbe52965151ee7f0$export$927664b47117acb0(title_);
7523
7526
  const closing_handlers = [exit_title_iterator];
7524
- const slidein = (0, $107a74aa4ea5902d$export$25062201e9e25d76)("div", {
7527
+ const slidein = $107a74aa4ea5902d$export$25062201e9e25d76("div", {
7525
7528
  class: "slidein",
7526
- children: [(0, $107a74aa4ea5902d$export$25062201e9e25d76)("div", {
7529
+ children: [$107a74aa4ea5902d$export$25062201e9e25d76("div", {
7527
7530
  class: "header",
7528
- children: [(0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("span", {
7531
+ children: [$107a74aa4ea5902d$export$34b9dba7ce09269b("span", {
7529
7532
  class: "title",
7530
- children: (0, $374ca311b64f260b$export$7c081fdbc65b6a2a)(exitable_title_iterator, false)
7531
- }), (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("button", {
7533
+ children: $374ca311b64f260b$export$7c081fdbc65b6a2a(exitable_title_iterator, false)
7534
+ }), $107a74aa4ea5902d$export$34b9dba7ce09269b("button", {
7532
7535
  class: "close",
7533
7536
  onClick: close_,
7534
7537
  children: CloseIcon()
7535
7538
  })]
7536
- }), (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("div", {
7539
+ }), $107a74aa4ea5902d$export$34b9dba7ce09269b("div", {
7537
7540
  class: "body",
7538
7541
  children: children
7539
7542
  })]
7540
7543
  });
7541
- const elements_in_container = (0, $107a74aa4ea5902d$export$25062201e9e25d76)("div", {
7544
+ const elements_in_container = $107a74aa4ea5902d$export$25062201e9e25d76("div", {
7542
7545
  class: "depict",
7543
7546
  children: [backdrop, slidein]
7544
7547
  });
@@ -7556,7 +7559,7 @@ async function $a7550e9f97f84465$export$8a0e4d6f6abf7e90({
7556
7559
  easing: "ease-in",
7557
7560
  duration: 220
7558
7561
  });
7559
- const handler = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(({
7562
+ const handler = $268cbd9e4ade92db$export$b3bbfd758f11cfa9(({
7560
7563
  key: key
7561
7564
  }) => {
7562
7565
  if (key === "Escape")
@@ -7564,7 +7567,7 @@ async function $a7550e9f97f84465$export$8a0e4d6f6abf7e90({
7564
7567
  close_();
7565
7568
  });
7566
7569
  window.addEventListener("keydown", handler);
7567
- open_promise.then((0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(() => {
7570
+ open_promise.then($268cbd9e4ade92db$export$b3bbfd758f11cfa9(() => {
7568
7571
  window.removeEventListener("keydown", handler);
7569
7572
  backdrop.animate({
7570
7573
  opacity: [1, 0]
@@ -7579,7 +7582,7 @@ async function $a7550e9f97f84465$export$8a0e4d6f6abf7e90({
7579
7582
  }, {
7580
7583
  easing: "ease-out",
7581
7584
  duration: 220
7582
- }).addEventListener("finish", (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(() => {
7585
+ }).addEventListener("finish", $268cbd9e4ade92db$export$b3bbfd758f11cfa9(() => {
7583
7586
  elements_in_container.remove();
7584
7587
  closing_handlers.forEach(handler => handler());
7585
7588
  }));
@@ -7595,35 +7598,35 @@ async function $bd0fccdac6624b01$export$c068ad5361be7646({
7595
7598
  out_of_stock_text_: out_of_stock_text_,
7596
7599
  CloseIcon: CloseIcon
7597
7600
  }) {
7598
- const [exit_oos_iterator, exitable_oos_iterator] = (0, $bbe52965151ee7f0$export$927664b47117acb0)(out_of_stock_text_);
7601
+ const [exit_oos_iterator, exitable_oos_iterator] = $bbe52965151ee7f0$export$927664b47117acb0(out_of_stock_text_);
7599
7602
  // eslint-disable-line no-async-promise-executor
7600
- return new Promise((0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(async size_selected => {
7603
+ return new Promise($268cbd9e4ade92db$export$b3bbfd758f11cfa9(async size_selected => {
7601
7604
  const {
7602
7605
  close_: close_,
7603
7606
  on_close_: on_close_
7604
- } = await (0, $a7550e9f97f84465$export$8a0e4d6f6abf7e90)({
7607
+ } = await $a7550e9f97f84465$export$8a0e4d6f6abf7e90({
7605
7608
  CloseIcon: CloseIcon,
7606
7609
  title_: title_,
7607
- children: [(0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("div", {
7610
+ children: [$107a74aa4ea5902d$export$34b9dba7ce09269b("div", {
7608
7611
  class: "option-list",
7609
7612
  children: items_.map(({
7610
7613
  size_name_: size_name_,
7611
7614
  is_available_: is_available_,
7612
7615
  id_: id_
7613
7616
  }) => {
7614
- const button = (0, $107a74aa4ea5902d$export$25062201e9e25d76)("button", {
7617
+ const button = $107a74aa4ea5902d$export$25062201e9e25d76("button", {
7615
7618
  type: "button",
7616
7619
  class: "option" + (is_available_ ? " available" : ""),
7617
7620
  onClick: () => {
7618
7621
  size_selected(id_);
7619
7622
  close_();
7620
7623
  },
7621
- children: [(0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("span", {
7624
+ children: [$107a74aa4ea5902d$export$34b9dba7ce09269b("span", {
7622
7625
  class: "size",
7623
7626
  children: size_name_
7624
- }), !is_available_ && (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("span", {
7627
+ }), !is_available_ && $107a74aa4ea5902d$export$34b9dba7ce09269b("span", {
7625
7628
  class: "sold-out",
7626
- children: (0, $374ca311b64f260b$export$7c081fdbc65b6a2a)(exitable_oos_iterator)
7629
+ children: $374ca311b64f260b$export$7c081fdbc65b6a2a(exitable_oos_iterator)
7627
7630
  })]
7628
7631
  });
7629
7632
  if (!is_available_) button.disabled = true;
@@ -7635,8 +7638,8 @@ async function $bd0fccdac6624b01$export$c068ad5361be7646({
7635
7638
  on_close_(exit_oos_iterator);
7636
7639
  }));
7637
7640
  }
7638
- var $286ce77d5f6728db$exports = {};
7639
- $286ce77d5f6728db$exports = ".depict-placeholder {\n will-change: mask, -webkit-mask;\n mask-position-x: 125%;\n mask-position-y: center;\n background: #ddd;\n animation: 1.5s linear infinite depict-placeholder;\n display: inline-block;\n position: relative;\n overflow: hidden;\n -webkit-mask: linear-gradient(-60deg, #000 30%, #0005, #000 70%) 125% / 300% 100%;\n -webkit-mask-image: ;\n mask-image: ;\n -webkit-mask-size: ;\n mask-size: ;\n}\n\n@keyframes depict-placeholder {\n 0% {\n mask-position-x: 125%;\n -webkit-mask-position-x: 125%;\n }\n\n 10% {\n mask-position-x: 125%;\n -webkit-mask-position-x: 125%;\n }\n\n 90% {\n mask-position-x: -25%;\n -webkit-mask-position-x: -25%;\n }\n\n 100% {\n mask-position-x: -25%;\n -webkit-mask-position-x: -25%;\n }\n}\n\n";
7641
+ var $05427557ffc98539$exports = {};
7642
+ $05427557ffc98539$exports = ".depict-placeholder {\n will-change: mask, -webkit-mask;\n mask-position-x: 125%;\n mask-position-y: center;\n background: #ddd;\n animation: 1.5s linear infinite depict-placeholder;\n display: inline-block;\n position: relative;\n overflow: hidden;\n -webkit-mask: linear-gradient(-60deg, #000 30%, #0005, #000 70%) 125% / 300% 100%;\n -webkit-mask-image: ;\n mask-image: ;\n -webkit-mask-size: ;\n mask-size: ;\n}\n\n@keyframes depict-placeholder {\n 0% {\n mask-position-x: 125%;\n -webkit-mask-position-x: 125%;\n }\n\n 10% {\n mask-position-x: 125%;\n -webkit-mask-position-x: 125%;\n }\n\n 90% {\n mask-position-x: -25%;\n -webkit-mask-position-x: -25%;\n }\n\n 100% {\n mask-position-x: -25%;\n -webkit-mask-position-x: -25%;\n }\n}\n\n";
7640
7643
  let $e587cb3b31b82f43$var$inserted = false;
7641
7644
  const $e587cb3b31b82f43$export$84712d0562a614b8 = ({
7642
7645
  width: width,
@@ -7647,12 +7650,12 @@ const $e587cb3b31b82f43$export$84712d0562a614b8 = ({
7647
7650
  }) => {
7648
7651
  if (!$e587cb3b31b82f43$var$inserted) {
7649
7652
  // Insert styling on first import
7650
- (0, $e4bebbfa0f0b1454$export$59ba1eb2c083f0cd)((0, /*@__PURE__*/$parcel$interopDefault($286ce77d5f6728db$exports)));
7653
+ $e4bebbfa0f0b1454$export$59ba1eb2c083f0cd((0, /*@__PURE__*/$parcel$interopDefault($05427557ffc98539$exports)));
7651
7654
  $e587cb3b31b82f43$var$inserted = true;
7652
7655
  }
7653
7656
  return (
7654
7657
  // @ts-ignore
7655
- (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("div", {
7658
+ $107a74aa4ea5902d$export$34b9dba7ce09269b("div", {
7656
7659
  class: `depict-placeholder${extra_classes ? " " + extra_classes : ""}`,
7657
7660
  style: style ? style : `width:${width};height:${height};`,
7658
7661
  ...attributes
@@ -7663,33 +7666,33 @@ const $e587cb3b31b82f43$export$d613f5b6d0a331a8 = ({
7663
7666
  aspect_ratio: aspect_ratio,
7664
7667
  ...attributes
7665
7668
  }) => {
7666
- return (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)($e587cb3b31b82f43$export$84712d0562a614b8, {
7669
+ return $107a74aa4ea5902d$export$34b9dba7ce09269b($e587cb3b31b82f43$export$84712d0562a614b8, {
7667
7670
  style: `position:relative;width:100%;padding-bottom:${1 / aspect_ratio * 100}%`,
7668
7671
  ...attributes
7669
7672
  });
7670
7673
  };
7671
- const $b9c0746e4d18273a$export$97f31f44c68c1d5 = (title, surface_classes = []) => (0, $90e0b983530610e7$export$eb0b9ed911409b57)(e => e.classList.add(...surface_classes), (0, $107a74aa4ea5902d$export$25062201e9e25d76)("div", {
7674
+ const $b9c0746e4d18273a$export$97f31f44c68c1d5 = (title, surface_classes = []) => $90e0b983530610e7$export$eb0b9ed911409b57(e => e.classList.add(...surface_classes), $107a74aa4ea5902d$export$25062201e9e25d76("div", {
7672
7675
  class: "depict recommendation_container",
7673
- children: [title && typeof title === "string" ? (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("h4", {
7676
+ children: [title && typeof title === "string" ? $107a74aa4ea5902d$export$34b9dba7ce09269b("h4", {
7674
7677
  class: "recs_header",
7675
7678
  children: title
7676
- }) : title, (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("div", {
7679
+ }) : title, $107a74aa4ea5902d$export$34b9dba7ce09269b("div", {
7677
7680
  class: "grid"
7678
7681
  })]
7679
7682
  }));
7680
- const $69accc27bcbd6972$export$32a55d57d151bc5a = () => (0, $107a74aa4ea5902d$export$25062201e9e25d76)("svg", {
7683
+ const $69accc27bcbd6972$export$32a55d57d151bc5a = () => $107a74aa4ea5902d$export$25062201e9e25d76("svg", {
7681
7684
  viewBox: "0 0 320 512",
7682
- children: [(0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("desc", {
7685
+ children: [$107a74aa4ea5902d$export$34b9dba7ce09269b("desc", {
7683
7686
  children: "Right arrow"
7684
- }), (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("path", {
7687
+ }), $107a74aa4ea5902d$export$34b9dba7ce09269b("path", {
7685
7688
  d: "M285.476 272.971L91.132 467.314c-9.373 9.373-24.569 9.373-33.941 0l-22.667-22.667c-9.357-9.357-9.375-24.522-.04-33.901L188.505 256 34.484 101.255c-9.335-9.379-9.317-24.544.04-33.901l22.667-22.667c9.373-9.373 24.569-9.373 33.941 0L285.475 239.03c9.373 9.372 9.373 24.568.001 33.941z"
7686
7689
  })]
7687
7690
  });
7688
- const $69accc27bcbd6972$export$ddd70fdae1b350e6 = () => (0, $107a74aa4ea5902d$export$25062201e9e25d76)("svg", {
7691
+ const $69accc27bcbd6972$export$ddd70fdae1b350e6 = () => $107a74aa4ea5902d$export$25062201e9e25d76("svg", {
7689
7692
  viewBox: "0 0 320 512",
7690
- children: [(0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("desc", {
7693
+ children: [$107a74aa4ea5902d$export$34b9dba7ce09269b("desc", {
7691
7694
  children: "Left arrow"
7692
- }), (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("path", {
7695
+ }), $107a74aa4ea5902d$export$34b9dba7ce09269b("path", {
7693
7696
  d: "M34.52 239.03L228.87 44.69c9.37-9.37 24.57-9.37 33.94 0l22.67 22.67c9.36 9.36 9.37 24.52.04 33.9L131.49 256l154.02 154.75c9.34 9.38 9.32 24.54-.04 33.9l-22.67 22.67c-9.37 9.37-24.57 9.37-33.94 0L34.52 272.97c-9.37-9.37-9.37-24.57 0-33.94z"
7694
7697
  })]
7695
7698
  });
@@ -7703,21 +7706,21 @@ function $af92e61c7dfccf01$var$ColorCircle({
7703
7706
  onClick: onClick,
7704
7707
  onHoverUpdate: onHoverUpdate
7705
7708
  }) {
7706
- const button = (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("button", {
7709
+ const button = $107a74aa4ea5902d$export$34b9dba7ce09269b("button", {
7707
7710
  class: "color-circle-container",
7708
7711
  onClick: e => onClick(e.currentTarget, color),
7709
7712
  title: color.label || "",
7710
- children: (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("div", {
7713
+ children: $107a74aa4ea5902d$export$34b9dba7ce09269b("div", {
7711
7714
  class: "outer-circle",
7712
7715
  style: `border-color: ${color.value};`,
7713
- children: (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("div", {
7716
+ children: $107a74aa4ea5902d$export$34b9dba7ce09269b("div", {
7714
7717
  class: "inner-circle",
7715
7718
  style: `background-color: ${color.value};`
7716
7719
  })
7717
7720
  })
7718
7721
  });
7719
- button.addEventListener("mouseenter", (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(() => onHoverUpdate(button, color, true)));
7720
- button.addEventListener("mouseleave", (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(() => onHoverUpdate(button, color, false)));
7722
+ button.addEventListener("mouseenter", $268cbd9e4ade92db$export$b3bbfd758f11cfa9(() => onHoverUpdate(button, color, true)));
7723
+ button.addEventListener("mouseleave", $268cbd9e4ade92db$export$b3bbfd758f11cfa9(() => onHoverUpdate(button, color, false)));
7721
7724
  return button;
7722
7725
  }
7723
7726
  function $af92e61c7dfccf01$export$590326cc34f49e2d({
@@ -7770,7 +7773,7 @@ function $af92e61c7dfccf01$export$590326cc34f49e2d({
7770
7773
  if (selectOnHover) handleSelectOnHover(hovered, color, hovering);
7771
7774
  };
7772
7775
  // Create the color circles
7773
- const circles = colors.map(color => (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)($af92e61c7dfccf01$var$ColorCircle, {
7776
+ const circles = colors.map(color => $107a74aa4ea5902d$export$34b9dba7ce09269b($af92e61c7dfccf01$var$ColorCircle, {
7774
7777
  color: color,
7775
7778
  onClick: handleClick,
7776
7779
  onHoverUpdate: handleHoverUpdate
@@ -7781,7 +7784,7 @@ function $af92e61c7dfccf01$export$590326cc34f49e2d({
7781
7784
  const initial_index = initialColor == undefined ? -1 : colors.findIndex(c => typeof initialColor === "string" ? c.value === initialColor : c.value === initialColor.value && c.label === initialColor.label);
7782
7785
  if (initial_index > -1) setActiveIndex(initial_index);
7783
7786
  if (onlyCircles) return circles;
7784
- return (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("div", {
7787
+ return $107a74aa4ea5902d$export$34b9dba7ce09269b("div", {
7785
7788
  class: "color-picker",
7786
7789
  role: "form",
7787
7790
  "aria-label": "Color picker",
@@ -7813,17 +7816,17 @@ const $b25f388f0fe2f1b3$export$237455ad7e59d4e5 = ({
7813
7816
  children: children
7814
7817
  }) => {
7815
7818
  if (Array.isArray(children) && children.length === 1) children = children[0];
7816
- innerRef = (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("div", {
7819
+ innerRef = $107a74aa4ea5902d$export$34b9dba7ce09269b("div", {
7817
7820
  children: children
7818
7821
  });
7819
- outerRef = (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("div", {
7822
+ outerRef = $107a74aa4ea5902d$export$34b9dba7ce09269b("div", {
7820
7823
  style: `overflow:hidden;height:0px;visibility:hidden`,
7821
7824
  "aria-hidden": "true",
7822
7825
  children: innerRef
7823
7826
  });
7824
7827
  return outerRef;
7825
7828
  };
7826
- const expand = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(async (expanding_delay = delay, time_to_expand = duration) => {
7829
+ const expand = $268cbd9e4ade92db$export$b3bbfd758f11cfa9(async (expanding_delay = delay, time_to_expand = duration) => {
7827
7830
  const start = get_current_height_possibly_during_transition(); // need to read this before cancelling the old animation
7828
7831
  outerRef.style.visibility = "";
7829
7832
  outerRef.removeAttribute("aria-hidden");
@@ -7836,14 +7839,14 @@ const $b25f388f0fe2f1b3$export$237455ad7e59d4e5 = ({
7836
7839
  easing: "ease-in"
7837
7840
  });
7838
7841
  current_animation = animation;
7839
- animation.addEventListener("finish", (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(() => {
7842
+ animation.addEventListener("finish", $268cbd9e4ade92db$export$b3bbfd758f11cfa9(() => {
7840
7843
  current_animation = undefined;
7841
7844
  outerRef.style.overflow = "";
7842
7845
  outerRef.style.height = "auto";
7843
7846
  }));
7844
7847
  return animation;
7845
7848
  });
7846
- const collapse = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(async (collapsing_delay = delay, time_to_collapse = duration) => {
7849
+ const collapse = $268cbd9e4ade92db$export$b3bbfd758f11cfa9(async (collapsing_delay = delay, time_to_collapse = duration) => {
7847
7850
  const start = get_current_height_possibly_during_transition();
7848
7851
  current_animation?.cancel?.();
7849
7852
  outerRef.style.overflow = "hidden";
@@ -7856,7 +7859,7 @@ const $b25f388f0fe2f1b3$export$237455ad7e59d4e5 = ({
7856
7859
  easing: "ease-out"
7857
7860
  });
7858
7861
  current_animation = animation;
7859
- animation.addEventListener("finish", (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(() => {
7862
+ animation.addEventListener("finish", $268cbd9e4ade92db$export$b3bbfd758f11cfa9(() => {
7860
7863
  current_animation = undefined;
7861
7864
  outerRef.style.height = "0";
7862
7865
  outerRef.style.visibility = "hidden";
@@ -7869,13 +7872,13 @@ const $b25f388f0fe2f1b3$export$237455ad7e59d4e5 = ({
7869
7872
  collapse: collapse
7870
7873
  };
7871
7874
  };
7872
- var $bdb3d8c0ba0e9ccc$exports = {};
7873
- $bdb3d8c0ba0e9ccc$exports = ".depict-img-cont {\n width: 100%;\n height: 100%;\n position: absolute;\n}\n\n.depict-img-filler {\n width: 100%;\n height: auto;\n display: inline-block;\n}\n\n.depict-img-comp {\n width: auto;\n height: auto;\n max-width: 100%;\n max-height: 100%;\n position: absolute;\n top: 50%;\n left: 50%;\n transform: translate(-50%, -50%);\n}\n\n.depict-img-mod {\n width: 100%;\n height: 100%;\n object-fit: contain;\n position: absolute;\n inset: 0;\n}\n\n";
7875
+ var $278195e5c6164616$exports = {};
7876
+ $278195e5c6164616$exports = ".depict-img-cont {\n width: 100%;\n height: 100%;\n position: absolute;\n}\n\n.depict-img-filler {\n width: 100%;\n height: auto;\n display: inline-block;\n}\n\n.depict-img-comp {\n width: auto;\n height: auto;\n max-width: 100%;\n max-height: 100%;\n position: absolute;\n top: 50%;\n left: 50%;\n transform: translate(-50%, -50%);\n}\n\n.depict-img-mod {\n width: 100%;\n height: 100%;\n object-fit: contain;\n position: absolute;\n inset: 0;\n}\n\n";
7874
7877
  const $ff973b2032639b5f$export$3d13beba9b52c947 = "https://img.depict.ai/ResizeImage" + (process.env.TENANT ? "/" + process.env.TENANT : "");
7875
7878
  const $ff973b2032639b5f$export$a98fc8a2c818d3d8 = /*@__PURE__*/(() => typeof navigator === "undefined" ? false : /^((?!chrome|android).)*safari/i.test(navigator.userAgent))(); // https://stackoverflow.com/a/23522755
7876
- function $ff973b2032639b5f$export$f39a7d0667e924a(what_to_watch, sizes_communicator = (0, $9a42a570de51ea3d$export$e806c6c1615a59ae)(), resolution_factor = 1) {
7879
+ function $ff973b2032639b5f$export$f39a7d0667e924a(what_to_watch, sizes_communicator = $9a42a570de51ea3d$export$e806c6c1615a59ae(), resolution_factor = 1) {
7877
7880
  let currently_live = false;
7878
- const ro = new ResizeObserver((0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(records => {
7881
+ const ro = new ResizeObserver($268cbd9e4ade92db$export$b3bbfd758f11cfa9(records => {
7879
7882
  for (let j = 0; j < records.length; j++) {
7880
7883
  const {
7881
7884
  width: width
@@ -7946,9 +7949,9 @@ function $ff973b2032639b5f$export$a62825542f1bfcf5({
7946
7949
  const raw_src = image_options?.src || image_options?.["data-src"]; // get wanted src
7947
7950
  const src = new URL(raw_src, location.origin).href;
7948
7951
  if (!src) {
7949
- (0, $e6c6e7929ea385ae$export$de56f1198d121036)(image_options, () => {}); // noop function is to allow to get here quickly by "jump to function definition"
7950
- (0, $548fd58b14b25a52$export$8048b892d651b310)(new Error("no image src provided: " + src));
7951
- return (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("img", {
7952
+ $e6c6e7929ea385ae$export$de56f1198d121036(image_options, () => {}); // noop function is to allow to get here quickly by "jump to function definition"
7953
+ $548fd58b14b25a52$export$8048b892d651b310(new Error("no image src provided: " + src));
7954
+ return $107a74aa4ea5902d$export$34b9dba7ce09269b("img", {
7952
7955
  ...image_options
7953
7956
  }); // we don't want everything to fail if someone misused this component
7954
7957
  }
@@ -7961,7 +7964,7 @@ function $ff973b2032639b5f$export$a62825542f1bfcf5({
7961
7964
  const srcset = $ff973b2032639b5f$var$make_srcset(src, format, resolutions);
7962
7965
  sources.push(
7963
7966
  // 0px important because chrome will load the biggest size otherwise until sizes attribute is set to the correct value
7964
- (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("source", {
7967
+ $107a74aa4ea5902d$export$34b9dba7ce09269b("source", {
7965
7968
  sizes: "0px",
7966
7969
  type: `image/${format}`,
7967
7970
  ...(set_dataset ? {
@@ -7976,7 +7979,7 @@ function $ff973b2032639b5f$export$a62825542f1bfcf5({
7976
7979
  }; // Prevents the image from instantly loading the original source
7977
7980
  delete opts_without_src["src"];
7978
7981
  delete opts_without_src["srcset"];
7979
- const the_image = (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("img", {
7982
+ const the_image = $107a74aa4ea5902d$export$34b9dba7ce09269b("img", {
7980
7983
  ...opts_without_src
7981
7984
  }); // create image
7982
7985
  sources.push(the_image); // chrome seems to be the dumbest piece of cake that has ever existed and just load the first source?????
@@ -7985,7 +7988,7 @@ function $ff973b2032639b5f$export$a62825542f1bfcf5({
7985
7988
  // start a sizes_setter for every source (including fallback image)
7986
7989
  for (let i = 0; i < sources.length; i++) sizes_setter_(sources[i]).catch((0, $548fd58b14b25a52$export$8048b892d651b310));
7987
7990
  // embed all sources into a <picture> so that the browser understands they're "together"
7988
- const picture = (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("picture", {
7991
+ const picture = $107a74aa4ea5902d$export$34b9dba7ce09269b("picture", {
7989
7992
  children: sources
7990
7993
  });
7991
7994
  // Create src and srcset for fallback image and set it.
@@ -8026,13 +8029,13 @@ const $a312bccd722ac9e4$export$788756b42446dc2d = ({
8026
8029
  }) => {
8027
8030
  if (!$a312bccd722ac9e4$var$inserted) {
8028
8031
  // Insert styling on first import
8029
- (0, $e4bebbfa0f0b1454$export$59ba1eb2c083f0cd)((0, /*@__PURE__*/$parcel$interopDefault($bdb3d8c0ba0e9ccc$exports)));
8032
+ $e4bebbfa0f0b1454$export$59ba1eb2c083f0cd((0, /*@__PURE__*/$parcel$interopDefault($278195e5c6164616$exports)));
8030
8033
  $a312bccd722ac9e4$var$inserted = true;
8031
8034
  }
8032
8035
  const img = process.env.BUILD_TARGET === "modern" || process.env.BUILD_TARGET === "dev" ? $a312bccd722ac9e4$var$Image(options) : $a312bccd722ac9e4$var$CompatibleImage(options);
8033
8036
  if (init_with_placeholder)
8034
8037
  // 10000 is a magic value, that is just supposed to be bigger than the size of the actual image.
8035
- img.querySelectorAll("img").forEach(i => i.src = (0, $fac9c96b6bbe43cd$export$a4eccf92efefa04d)(10000 * options.aspect_ratio, 10000));
8038
+ img.querySelectorAll("img").forEach(i => i.src = $fac9c96b6bbe43cd$export$a4eccf92efefa04d(10000 * options.aspect_ratio, 10000));
8036
8039
  return img;
8037
8040
  };
8038
8041
  function $a312bccd722ac9e4$var$Image({
@@ -8044,20 +8047,20 @@ function $a312bccd722ac9e4$var$Image({
8044
8047
  init_with_placeholder: _,
8045
8048
  ...image_options
8046
8049
  }) {
8047
- const div = (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("div", {
8050
+ const div = $107a74aa4ea5902d$export$34b9dba7ce09269b("div", {
8048
8051
  style: `position:relative;width:100%;padding-bottom:${1 / aspect_ratio * 100}%`
8049
8052
  });
8050
8053
  const sourceset_component = $a312bccd722ac9e4$var$srcset_comp_from_map_or_new(rendering_options, srcset_opts, div);
8051
8054
  const IMG_tag = image_options.src?.startsWith("data:") || !sourceset_component ? "img" : sourceset_component;
8052
8055
  div.append(
8053
8056
  // @ts-ignore
8054
- (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)(IMG_tag, {
8057
+ $107a74aa4ea5902d$export$34b9dba7ce09269b(IMG_tag, {
8055
8058
  alt: alt,
8056
8059
  ...(remove_on_error ? {
8057
8060
  onerror: "this.remove()"
8058
8061
  } : {}),
8059
8062
  ...image_options,
8060
- class: (0, $90e0b983530610e7$export$22a65337c1b43b1f)(["depict-img-mod ", image_options.class, $a312bccd722ac9e4$var$add_nolazy_to_placeholder(rendering_options?.type)])
8063
+ class: $90e0b983530610e7$export$22a65337c1b43b1f(["depict-img-mod ", image_options.class, $a312bccd722ac9e4$var$add_nolazy_to_placeholder(rendering_options?.type)])
8061
8064
  }));
8062
8065
  return div;
8063
8066
  }
@@ -8069,24 +8072,24 @@ function $a312bccd722ac9e4$var$CompatibleImage({
8069
8072
  srcset_opts: srcset_opts,
8070
8073
  ...image_options
8071
8074
  }) {
8072
- const canvas = (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("canvas", {
8075
+ const canvas = $107a74aa4ea5902d$export$34b9dba7ce09269b("canvas", {
8073
8076
  class: "depict-img-filler",
8074
8077
  width: 3000 * aspect_ratio,
8075
8078
  height: 3000
8076
8079
  });
8077
8080
  const sourceset_component = $a312bccd722ac9e4$var$srcset_comp_from_map_or_new(rendering_options, srcset_opts, canvas);
8078
8081
  const IMG_tag = image_options.src?.startsWith("data:") || !sourceset_component ? "img" : sourceset_component;
8079
- return (0, $107a74aa4ea5902d$export$25062201e9e25d76)("div", {
8082
+ return $107a74aa4ea5902d$export$25062201e9e25d76("div", {
8080
8083
  style: "position:relative",
8081
- children: [(0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("div", {
8084
+ children: [$107a74aa4ea5902d$export$34b9dba7ce09269b("div", {
8082
8085
  class: "depict-img-cont",
8083
- children: (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)(IMG_tag, {
8086
+ children: $107a74aa4ea5902d$export$34b9dba7ce09269b(IMG_tag, {
8084
8087
  alt: alt,
8085
8088
  ...(remove_on_error ? {
8086
8089
  onerror: "this.remove()"
8087
8090
  } : {}),
8088
8091
  ...image_options,
8089
- class: (0, $90e0b983530610e7$export$22a65337c1b43b1f)(["depict-img-comp", image_options.class, $a312bccd722ac9e4$var$add_nolazy_to_placeholder(rendering_options?.type)])
8092
+ class: $90e0b983530610e7$export$22a65337c1b43b1f(["depict-img-comp", image_options.class, $a312bccd722ac9e4$var$add_nolazy_to_placeholder(rendering_options?.type)])
8090
8093
  })
8091
8094
  }), canvas]
8092
8095
  });
@@ -8100,14 +8103,14 @@ function $a312bccd722ac9e4$var$srcset_comp_from_map_or_new(rendering_options, sr
8100
8103
  ...srcset_opts
8101
8104
  };
8102
8105
  cloned_opts.what_to_watch = canvas;
8103
- sourceset_component = (0, $ff973b2032639b5f$export$a62825542f1bfcf5)(cloned_opts);
8106
+ sourceset_component = $ff973b2032639b5f$export$a62825542f1bfcf5(cloned_opts);
8104
8107
  $a312bccd722ac9e4$var$rendering_options_to_sourceset_component.set(rendering_options, new WeakRef(sourceset_component));
8105
8108
  }
8106
8109
  }
8107
8110
  return sourceset_component;
8108
8111
  }
8109
- var $a5803966f4ce1570$exports = {};
8110
- $a5803966f4ce1570$exports = ".depict .images-container {\n position: relative;\n}\n\n.depict .second-image-container {\n width: 100%;\n opacity: 0;\n position: absolute;\n top: 0;\n}\n\n.depict .hovering .main-image-container {\n opacity: 0;\n}\n\n.depict .hovering .second-image-container {\n opacity: 1;\n}\n\n";
8112
+ var $63f2002626a07875$exports = {};
8113
+ $63f2002626a07875$exports = ".depict .images-container {\n position: relative;\n}\n\n.depict .second-image-container {\n width: 100%;\n opacity: 0;\n position: absolute;\n top: 0;\n}\n\n.depict .hovering .main-image-container {\n opacity: 0;\n}\n\n.depict .hovering .second-image-container {\n opacity: 1;\n}\n\n";
8111
8114
 
8112
8115
  // Saving bytez
8113
8116
  // Maybe? @Daniel
@@ -8137,7 +8140,7 @@ function $a656daa2fa8c279a$var$register_element_for_touch_hover(el, navigation_m
8137
8140
  }
8138
8141
  function $a656daa2fa8c279a$var$start_checking_for_touch_hover() {
8139
8142
  const currently_hovering = new Map();
8140
- const handle_touch_start = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(evt => {
8143
+ const handle_touch_start = $268cbd9e4ade92db$export$b3bbfd758f11cfa9(evt => {
8141
8144
  const touch = evt?.changedTouches?.[0];
8142
8145
  if (!touch) return; // Eytys dispatches fake touch events without changedTouches
8143
8146
  const id = touch.identifier;
@@ -8160,7 +8163,7 @@ function $a656daa2fa8c279a$var$start_checking_for_touch_hover() {
8160
8163
  }
8161
8164
  });
8162
8165
  let last_collision_check = +new Date();
8163
- const handle_touch_move = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(evt => {
8166
+ const handle_touch_move = $268cbd9e4ade92db$export$b3bbfd758f11cfa9(evt => {
8164
8167
  const first_touch = evt?.changedTouches?.[0];
8165
8168
  if (!first_touch) return;
8166
8169
  const {
@@ -8176,7 +8179,7 @@ function $a656daa2fa8c279a$var$start_checking_for_touch_hover() {
8176
8179
  if (get_hover_element_from_coords(clientX, clientY) !== our_touch_data.element_) clear_hover(identifier, our_touch_data, clientX, clientY);
8177
8180
  }
8178
8181
  });
8179
- const handle_touch_cancel = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(evt => {
8182
+ const handle_touch_cancel = $268cbd9e4ade92db$export$b3bbfd758f11cfa9(evt => {
8180
8183
  const touch = evt?.changedTouches?.[0];
8181
8184
  if (!touch) return;
8182
8185
  const id = touch.identifier;
@@ -8188,7 +8191,7 @@ function $a656daa2fa8c279a$var$start_checking_for_touch_hover() {
8188
8191
  const hover_element = elements[$a656daa2fa8c279a$var$HOVER_IMAGE_DEPTH - 1];
8189
8192
  return hover_element && $a656daa2fa8c279a$var$touch_hover_elements.has(hover_element) ? hover_element : null;
8190
8193
  };
8191
- const clear_hover = (0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)((id, info_about_touch, now_x, now_y) => {
8194
+ const clear_hover = $268cbd9e4ade92db$export$b3bbfd758f11cfa9((id, info_about_touch, now_x, now_y) => {
8192
8195
  const {
8193
8196
  element_: element_,
8194
8197
  start_y_: start_y_,
@@ -8235,25 +8238,25 @@ const $a656daa2fa8c279a$export$2369f6fc1c911576 = ({
8235
8238
  ...options
8236
8239
  }) => {
8237
8240
  if (!$a656daa2fa8c279a$var$styling_inserted) {
8238
- (0, $e4bebbfa0f0b1454$export$59ba1eb2c083f0cd)((0, /*@__PURE__*/$parcel$interopDefault($a5803966f4ce1570$exports)));
8241
+ $e4bebbfa0f0b1454$export$59ba1eb2c083f0cd((0, /*@__PURE__*/$parcel$interopDefault($63f2002626a07875$exports)));
8239
8242
  $a656daa2fa8c279a$var$styling_inserted = true;
8240
8243
  }
8241
- const main_image = (0, $a312bccd722ac9e4$export$788756b42446dc2d)({
8244
+ const main_image = $a312bccd722ac9e4$export$788756b42446dc2d({
8242
8245
  ...options
8243
8246
  });
8244
- const second_image = (0, $a312bccd722ac9e4$export$788756b42446dc2d)({
8247
+ const second_image = $a312bccd722ac9e4$export$788756b42446dc2d({
8245
8248
  ...options,
8246
8249
  [second_srcset_opts?.set_dataset === false ? "src" : "data-src"]: second_src || "",
8247
8250
  [second_srcset_opts?.set_dataset === false ? "srcset" : "data-srcset"]: second_srcset || "",
8248
8251
  srcset_opts: second_srcset_opts || {}
8249
8252
  });
8250
8253
  const no_second_img = !second_src && !second_srcset && !second_srcset_opts;
8251
- const images_container = (0, $107a74aa4ea5902d$export$25062201e9e25d76)("div", {
8254
+ const images_container = $107a74aa4ea5902d$export$25062201e9e25d76("div", {
8252
8255
  class: "images-container",
8253
- children: [!no_second_img && (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("div", {
8256
+ children: [!no_second_img && $107a74aa4ea5902d$export$34b9dba7ce09269b("div", {
8254
8257
  class: "second-image-container",
8255
8258
  children: second_image
8256
- }), (0, $107a74aa4ea5902d$export$34b9dba7ce09269b)("div", {
8259
+ }), $107a74aa4ea5902d$export$34b9dba7ce09269b("div", {
8257
8260
  class: "main-image-container",
8258
8261
  children: main_image
8259
8262
  })]
@@ -8396,11 +8399,11 @@ let $8838e3e61b748a8b$var$running_writers = 0;
8396
8399
  function $8838e3e61b748a8b$export$ef73ea4f975745ba(meta_data) {
8397
8400
  if ($8838e3e61b748a8b$var$running_writers >= 1) return;
8398
8401
  $8838e3e61b748a8b$var$running_writers++;
8399
- (0, $z0IcO$solidjs.onCleanup)(() => $8838e3e61b748a8b$var$running_writers--);
8402
+ $z0IcO$solidjs.onCleanup(() => $8838e3e61b748a8b$var$running_writers--);
8400
8403
  const disconnectors = [];
8401
- (0, $z0IcO$solidjs.createEffect)((0, $268cbd9e4ade92db$export$b3bbfd758f11cfa9)(() => {
8404
+ $z0IcO$solidjs.createEffect($268cbd9e4ade92db$export$b3bbfd758f11cfa9(() => {
8402
8405
  if (!meta_data()) return;
8403
- (0, $z0IcO$solidjs.onCleanup)(() => {
8406
+ $z0IcO$solidjs.onCleanup(() => {
8404
8407
  disconnectors.forEach(d => d());
8405
8408
  });
8406
8409
  for (const [type, content] of Object.entries(meta_data())) for (const opts of $8838e3e61b748a8b$var$tags[type]) {
@@ -8411,7 +8414,7 @@ function $8838e3e61b748a8b$export$ef73ea4f975745ba(meta_data) {
8411
8414
  * It's preferred not to kill any conflicting meta tags because frameworks might go apeshit.
8412
8415
  * Things seem to work when only changing the meta values though */
8413
8416
  const sync_elements_to_head = () => {
8414
- if (retries++ > $8838e3e61b748a8b$var$MAX_SYNC_RETRIES) return (0, $e6c6e7929ea385ae$export$de56f1198d121036)("Failed to sync meta tag to head. Hit max retries.", opts.selector, content);
8417
+ if (retries++ > $8838e3e61b748a8b$var$MAX_SYNC_RETRIES) return $e6c6e7929ea385ae$export$de56f1198d121036("Failed to sync meta tag to head. Hit max retries.", opts.selector, content);
8415
8418
  const existing_elements = document.head.querySelectorAll(opts.selector);
8416
8419
  const elements = existing_elements.length ? existing_elements : [opts.create()];
8417
8420
  elements.forEach(el => {
@@ -8434,5 +8437,5 @@ function $8838e3e61b748a8b$export$ef73ea4f975745ba(meta_data) {
8434
8437
  }
8435
8438
  }, "Meta tag writing crashed"));
8436
8439
  }
8437
- (0, $e4a18bf12ad092d9$export$2cefb7e61fcbae00)("utilishared", (0, $815f67c61b4c0a42$export$83d89fbfd8236492));
8440
+ $e4a18bf12ad092d9$export$2cefb7e61fcbae00("utilishared", (0, $815f67c61b4c0a42$export$83d89fbfd8236492));
8438
8441
  $parcel$exportWildcard(module.exports, $28e42b0009d694b2$exports);