@tanstack/query-devtools 5.71.2 → 5.71.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,4 +1,4 @@
1
- import { sortFns, mutationSortFns, createContext, splitProps, createMemo, createComponent, mergeProps, createUniqueId, createSignal, createEffect, onCleanup, Show, on, delegateEvents, Dynamic, useContext, template, createRenderEffect, setAttribute, Portal, untrack, isServer, onMount, createComputed, getOwner, use, insert, className, getSidedProp, getQueryStatusColor, getMutationStatusColor, getQueryStatusLabel, spread, getQueryStatusColorByLabel, displayValue, For, batch, clearDelegatedEvents, convertRemToPixels, serialize, Index, updateNestedDataByPath, $TRACK, createRoot, DEV, addEventListener, stringify, Switch, Match, deleteNestedDataByPath, useTransition } from './KMI5VYOH.js';
1
+ import { sortFns, mutationSortFns, createContext, splitProps, createMemo, createComponent, mergeProps, createUniqueId, createSignal, createEffect, onCleanup, Show, on, delegateEvents, Dynamic, useContext, template, createRenderEffect, setAttribute, Portal, untrack, isServer, onMount, createComputed, getOwner, use, insert, className, getSidedProp, getQueryStatusColor, getMutationStatusColor, getQueryStatusLabel, spread, getQueryStatusColorByLabel, displayValue, For, batch, clearDelegatedEvents, convertRemToPixels, serialize, Index, updateNestedDataByPath, $TRACK, createRoot, DEV, addEventListener, stringify, Switch, Match, deleteNestedDataByPath, useTransition } from './HR7YXZ5H.js';
2
2
 
3
3
  // ../../node_modules/.pnpm/@solid-primitives+utils@6.2.3_solid-js@1.9.5/node_modules/@solid-primitives/utils/dist/chunk/R5675YMU.js
4
4
  var isClient = !isServer;
@@ -1028,8 +1028,7 @@ var c = {};
1028
1028
  var s = (e2) => {
1029
1029
  if ("object" == typeof e2) {
1030
1030
  let t2 = "";
1031
- for (let r2 in e2)
1032
- t2 += r2 + s(e2[r2]);
1031
+ for (let r2 in e2) t2 += r2 + s(e2[r2]);
1033
1032
  return t2;
1034
1033
  }
1035
1034
  return e2;
@@ -1037,15 +1036,13 @@ var s = (e2) => {
1037
1036
  var i = (e2, t2, r2, i2, p2) => {
1038
1037
  let u2 = s(e2), d = c[u2] || (c[u2] = ((e3) => {
1039
1038
  let t3 = 0, r3 = 11;
1040
- for (; t3 < e3.length; )
1041
- r3 = 101 * r3 + e3.charCodeAt(t3++) >>> 0;
1039
+ for (; t3 < e3.length; ) r3 = 101 * r3 + e3.charCodeAt(t3++) >>> 0;
1042
1040
  return "go" + r3;
1043
1041
  })(u2));
1044
1042
  if (!c[d]) {
1045
1043
  let t3 = u2 !== e2 ? e2 : ((e3) => {
1046
1044
  let t4, r3, o2 = [{}];
1047
- for (; t4 = l.exec(e3.replace(a, "")); )
1048
- t4[4] ? o2.shift() : t4[3] ? (r3 = t4[3].replace(n, " ").trim(), o2.unshift(o2[0][r3] = o2[0][r3] || {})) : o2[0][t4[1]] = t4[2].replace(n, " ").trim();
1045
+ for (; t4 = l.exec(e3.replace(a, "")); ) t4[4] ? o2.shift() : t4[3] ? (r3 = t4[3].replace(n, " ").trim(), o2.unshift(o2[0][r3] = o2[0][r3] || {})) : o2[0][t4[1]] = t4[2].replace(n, " ").trim();
1049
1046
  return o2[0];
1050
1047
  })(e2);
1051
1048
  c[d] = o(p2 ? { ["@keyframes " + d]: t3 } : t3, r2 ? "" : "." + d);
@@ -1073,21 +1070,15 @@ u.bind({ k: 1 });
1073
1070
  // ../../node_modules/.pnpm/clsx@2.1.1/node_modules/clsx/dist/clsx.mjs
1074
1071
  function r(e2) {
1075
1072
  var t2, f, n2 = "";
1076
- if ("string" == typeof e2 || "number" == typeof e2)
1077
- n2 += e2;
1078
- else if ("object" == typeof e2)
1079
- if (Array.isArray(e2)) {
1080
- var o2 = e2.length;
1081
- for (t2 = 0; t2 < o2; t2++)
1082
- e2[t2] && (f = r(e2[t2])) && (n2 && (n2 += " "), n2 += f);
1083
- } else
1084
- for (f in e2)
1085
- e2[f] && (n2 && (n2 += " "), n2 += f);
1073
+ if ("string" == typeof e2 || "number" == typeof e2) n2 += e2;
1074
+ else if ("object" == typeof e2) if (Array.isArray(e2)) {
1075
+ var o2 = e2.length;
1076
+ for (t2 = 0; t2 < o2; t2++) e2[t2] && (f = r(e2[t2])) && (n2 && (n2 += " "), n2 += f);
1077
+ } else for (f in e2) e2[f] && (n2 && (n2 += " "), n2 += f);
1086
1078
  return n2;
1087
1079
  }
1088
1080
  function clsx() {
1089
- for (var e2, t2, f = 0, n2 = "", o2 = arguments.length; f < o2; f++)
1090
- (e2 = arguments[f]) && (t2 = r(e2)) && (n2 && (n2 += " "), n2 += t2);
1081
+ for (var e2, t2, f = 0, n2 = "", o2 = arguments.length; f < o2; f++) (e2 = arguments[f]) && (t2 = r(e2)) && (n2 && (n2 += " "), n2 += t2);
1091
1082
  return n2;
1092
1083
  }
1093
1084
  function createListTransition(source, options) {
@@ -3544,8 +3535,7 @@ var access2 = (v) => typeof v === "function" ? v() : v;
3544
3535
  var createPresence = (props) => {
3545
3536
  const refStyles = createMemo(() => {
3546
3537
  const element = access2(props.element);
3547
- if (!element)
3548
- return;
3538
+ if (!element) return;
3549
3539
  return getComputedStyle(element);
3550
3540
  });
3551
3541
  const getAnimationName = () => {
@@ -3556,8 +3546,7 @@ var createPresence = (props) => {
3556
3546
  createEffect((prevShow) => {
3557
3547
  const show = access2(props.show);
3558
3548
  untrack(() => {
3559
- if (prevShow === show)
3560
- return show;
3549
+ if (prevShow === show) return show;
3561
3550
  const prevAnimationName = animationName;
3562
3551
  const currentAnimationName = getAnimationName();
3563
3552
  if (show) {
@@ -3577,8 +3566,7 @@ var createPresence = (props) => {
3577
3566
  });
3578
3567
  createEffect(() => {
3579
3568
  const element = access2(props.element);
3580
- if (!element)
3581
- return;
3569
+ if (!element) return;
3582
3570
  const handleAnimationStart = (event) => {
3583
3571
  if (event.target === element) {
3584
3572
  animationName = getAnimationName();
@@ -3834,8 +3822,7 @@ function getSideList(side, isStart, rtl) {
3834
3822
  switch (side) {
3835
3823
  case "top":
3836
3824
  case "bottom":
3837
- if (rtl)
3838
- return isStart ? rl : lr;
3825
+ if (rtl) return isStart ? rl : lr;
3839
3826
  return isStart ? lr : rl;
3840
3827
  case "left":
3841
3828
  case "right":
@@ -4597,8 +4584,7 @@ function getContainingBlock(element) {
4597
4584
  return null;
4598
4585
  }
4599
4586
  function isWebKit() {
4600
- if (typeof CSS === "undefined" || !CSS.supports)
4601
- return false;
4587
+ if (typeof CSS === "undefined" || !CSS.supports) return false;
4602
4588
  return CSS.supports("-webkit-backdrop-filter", "none");
4603
4589
  }
4604
4590
  function isLastTraversableNode(node) {
@@ -6661,8 +6647,7 @@ var createStyle = (props) => {
6661
6647
  }
6662
6648
  onCleanup(() => {
6663
6649
  const activeStyle2 = activeStyles.get(props.key);
6664
- if (!activeStyle2)
6665
- return;
6650
+ if (!activeStyle2) return;
6666
6651
  if (activeStyle2.activeCount !== 1) {
6667
6652
  activeStyle2.activeCount--;
6668
6653
  return;
@@ -6744,8 +6729,7 @@ var createPreventScroll = (props) => {
6744
6729
  let currentTouchStartAxis = null;
6745
6730
  let currentTouchStartDelta = null;
6746
6731
  createEffect(() => {
6747
- if (!access2(defaultedProps.enabled))
6748
- return;
6732
+ if (!access2(defaultedProps.enabled)) return;
6749
6733
  setPreventScrollStack((stack) => [...stack, preventScrollId]);
6750
6734
  onCleanup(() => {
6751
6735
  setPreventScrollStack(
@@ -6796,8 +6780,7 @@ var createPreventScroll = (props) => {
6796
6780
  }
6797
6781
  });
6798
6782
  createEffect(() => {
6799
- if (!isActive(preventScrollId) || !access2(defaultedProps.enabled))
6800
- return;
6783
+ if (!isActive(preventScrollId) || !access2(defaultedProps.enabled)) return;
6801
6784
  document.addEventListener("wheel", maybePreventWheel, {
6802
6785
  passive: false
6803
6786
  });
@@ -6892,12 +6875,10 @@ var wouldScroll = (target, axis, delta, wrapper) => {
6892
6875
  return true;
6893
6876
  };
6894
6877
  var contains2 = (wrapper, target) => {
6895
- if (wrapper.contains(target))
6896
- return true;
6878
+ if (wrapper.contains(target)) return true;
6897
6879
  let currentElement = target;
6898
6880
  while (currentElement) {
6899
- if (currentElement === wrapper)
6900
- return true;
6881
+ if (currentElement === wrapper) return true;
6901
6882
  currentElement = currentElement._$host ?? currentElement.parentElement;
6902
6883
  }
6903
6884
  return false;
@@ -9662,8 +9643,7 @@ var PiPPanel = (props) => {
9662
9643
  createEffect(() => {
9663
9644
  const win = pip().pipWindow;
9664
9645
  const resizeCB = () => {
9665
- if (!win)
9666
- return;
9646
+ if (!win) return;
9667
9647
  setPanelWidth(win.innerWidth);
9668
9648
  };
9669
9649
  if (win) {
@@ -9751,8 +9731,7 @@ var DraggablePanel = (props) => {
9751
9731
  const position = createMemo(() => props.localStore.position || useQueryDevtoolsContext().position || POSITION);
9752
9732
  const handleDragStart = (event) => {
9753
9733
  const panelElement = event.currentTarget.parentElement;
9754
- if (!panelElement)
9755
- return;
9734
+ if (!panelElement) return;
9756
9735
  setIsResizing(true);
9757
9736
  const {
9758
9737
  height,
@@ -9808,8 +9787,7 @@ var DraggablePanel = (props) => {
9808
9787
  });
9809
9788
  createEffect(() => {
9810
9789
  const rootContainer = panelRef.parentElement?.parentElement?.parentElement;
9811
- if (!rootContainer)
9812
- return;
9790
+ if (!rootContainer) return;
9813
9791
  const currentPosition = props.localStore.position || POSITION;
9814
9792
  const styleProp = getSidedProp("padding", currentPosition);
9815
9793
  const isVertical = props.localStore.position === "left" || props.localStore.position === "right";
@@ -10492,15 +10470,13 @@ var MutationRow = (props) => {
10492
10470
  const isPaused = createSubscribeToMutationCacheBatcher((mutationCache) => {
10493
10471
  const mutations = mutationCache().getAll();
10494
10472
  const mutation = mutations.find((m) => m.mutationId === props.mutation.mutationId);
10495
- if (!mutation)
10496
- return false;
10473
+ if (!mutation) return false;
10497
10474
  return mutation.state.isPaused;
10498
10475
  });
10499
10476
  const status = createSubscribeToMutationCacheBatcher((mutationCache) => {
10500
10477
  const mutations = mutationCache().getAll();
10501
10478
  const mutation = mutations.find((m) => m.mutationId === props.mutation.mutationId);
10502
- if (!mutation)
10503
- return "idle";
10479
+ if (!mutation) return "idle";
10504
10480
  return mutation.state.status;
10505
10481
  });
10506
10482
  const color = createMemo(() => getMutationStatusColor({
@@ -10821,14 +10797,12 @@ var QueryDetails = () => {
10821
10797
  }, false);
10822
10798
  const statusLabel = createSubscribeToQueryCacheBatcher((queryCache) => {
10823
10799
  const query = queryCache().getAll().find((q) => q.queryHash === selectedQueryHash());
10824
- if (!query)
10825
- return "inactive";
10800
+ if (!query) return "inactive";
10826
10801
  return getQueryStatusLabel(query);
10827
10802
  });
10828
10803
  const queryStatus = createSubscribeToQueryCacheBatcher((queryCache) => {
10829
10804
  const query = queryCache().getAll().find((q) => q.queryHash === selectedQueryHash());
10830
- if (!query)
10831
- return "pending";
10805
+ if (!query) return "pending";
10832
10806
  return query.state.status;
10833
10807
  });
10834
10808
  const observerCount = createSubscribeToQueryCacheBatcher((queryCache) => queryCache().getAll().find((query) => query.queryHash === selectedQueryHash())?.getObserversCount() ?? 0);
@@ -10908,8 +10882,7 @@ var QueryDetails = () => {
10908
10882
  restoreQueryAfterLoadingOrError();
10909
10883
  } else {
10910
10884
  const activeQueryVal = activeQuery();
10911
- if (!activeQueryVal)
10912
- return;
10885
+ if (!activeQueryVal) return;
10913
10886
  const __previousQueryOptions = activeQueryVal.options;
10914
10887
  activeQueryVal.fetch({
10915
10888
  ...__previousQueryOptions,
@@ -11175,15 +11148,13 @@ var MutationDetails = () => {
11175
11148
  const isPaused = createSubscribeToMutationCacheBatcher((mutationCache) => {
11176
11149
  const mutations = mutationCache().getAll();
11177
11150
  const mutation = mutations.find((m) => m.mutationId === selectedMutationId());
11178
- if (!mutation)
11179
- return false;
11151
+ if (!mutation) return false;
11180
11152
  return mutation.state.isPaused;
11181
11153
  });
11182
11154
  const status = createSubscribeToMutationCacheBatcher((mutationCache) => {
11183
11155
  const mutations = mutationCache().getAll();
11184
11156
  const mutation = mutations.find((m) => m.mutationId === selectedMutationId());
11185
- if (!mutation)
11186
- return "idle";
11157
+ if (!mutation) return "idle";
11187
11158
  return mutation.state.status;
11188
11159
  });
11189
11160
  const color = createMemo(() => getMutationStatusColor({
@@ -11305,8 +11276,7 @@ var setupQueryCacheSubscription = () => {
11305
11276
  const unsubscribe = queryCache().subscribe((q) => {
11306
11277
  batch(() => {
11307
11278
  for (const [callback, value] of queryCacheMap.entries()) {
11308
- if (!value.shouldUpdate(q))
11309
- continue;
11279
+ if (!value.shouldUpdate(q)) continue;
11310
11280
  value.setter(callback(queryCache));
11311
11281
  }
11312
11282
  });