@tanstack/query-devtools 5.1.0 → 5.4.2
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/build/Devtools/{QHGCTHEZ.jsx → 7FRXYIEA.jsx} +119 -90
- package/build/Devtools/{BWLPXLBN.js → HESZYUBG.js} +141 -107
- package/build/Devtools/{QHLLQ2XL.jsx → KWB27UDF.jsx} +119 -90
- package/build/Devtools/{CRASJTHY.js → MVUALMJ4.js} +141 -107
- package/build/dev.cjs +140 -106
- package/build/dev.js +1 -1
- package/build/dev.jsx +1 -1
- package/build/index.cjs +140 -106
- package/build/index.js +1 -1
- package/build/index.jsx +1 -1
- package/package.json +1 -1
- package/src/Devtools.tsx +50 -14
- package/src/Explorer.tsx +5 -5
- package/src/theme.ts +71 -71
|
@@ -8737,35 +8737,35 @@ var tokens = {
|
|
|
8737
8737
|
},
|
|
8738
8738
|
font: {
|
|
8739
8739
|
size: {
|
|
8740
|
-
"2xs": "0.
|
|
8741
|
-
xs: "0.
|
|
8742
|
-
sm: "0.
|
|
8743
|
-
md: "
|
|
8744
|
-
lg: "1.
|
|
8745
|
-
xl: "1.
|
|
8746
|
-
"2xl": "1.
|
|
8747
|
-
"3xl": "1.
|
|
8748
|
-
"4xl": "2.
|
|
8749
|
-
"5xl": "
|
|
8750
|
-
"6xl": "3.
|
|
8751
|
-
"7xl": "4.
|
|
8752
|
-
"8xl": "
|
|
8753
|
-
"9xl": "
|
|
8740
|
+
"2xs": "calc(var(--tsqd-font-size) * 0.625)",
|
|
8741
|
+
xs: "calc(var(--tsqd-font-size) * 0.75)",
|
|
8742
|
+
sm: "calc(var(--tsqd-font-size) * 0.875)",
|
|
8743
|
+
md: "var(--tsqd-font-size)",
|
|
8744
|
+
lg: "calc(var(--tsqd-font-size) * 1.125)",
|
|
8745
|
+
xl: "calc(var(--tsqd-font-size) * 1.25)",
|
|
8746
|
+
"2xl": "calc(var(--tsqd-font-size) * 1.5)",
|
|
8747
|
+
"3xl": "calc(var(--tsqd-font-size) * 1.875)",
|
|
8748
|
+
"4xl": "calc(var(--tsqd-font-size) * 2.25)",
|
|
8749
|
+
"5xl": "calc(var(--tsqd-font-size) * 3)",
|
|
8750
|
+
"6xl": "calc(var(--tsqd-font-size) * 3.75)",
|
|
8751
|
+
"7xl": "calc(var(--tsqd-font-size) * 4.5)",
|
|
8752
|
+
"8xl": "calc(var(--tsqd-font-size) * 6)",
|
|
8753
|
+
"9xl": "calc(var(--tsqd-font-size) * 8)"
|
|
8754
8754
|
},
|
|
8755
8755
|
lineHeight: {
|
|
8756
|
-
xs: "
|
|
8757
|
-
sm: "1.
|
|
8758
|
-
md: "1.
|
|
8759
|
-
lg: "1.
|
|
8760
|
-
xl: "
|
|
8761
|
-
"2xl": "
|
|
8762
|
-
"3xl": "2.
|
|
8763
|
-
"4xl": "2.
|
|
8764
|
-
"5xl": "
|
|
8765
|
-
"6xl": "
|
|
8766
|
-
"7xl": "
|
|
8767
|
-
"8xl": "
|
|
8768
|
-
"9xl": "
|
|
8756
|
+
xs: "calc(var(--tsqd-font-size) * 1)",
|
|
8757
|
+
sm: "calc(var(--tsqd-font-size) * 1.25)",
|
|
8758
|
+
md: "calc(var(--tsqd-font-size) * 1.5)",
|
|
8759
|
+
lg: "calc(var(--tsqd-font-size) * 1.75)",
|
|
8760
|
+
xl: "calc(var(--tsqd-font-size) * 2)",
|
|
8761
|
+
"2xl": "calc(var(--tsqd-font-size) * 2.25)",
|
|
8762
|
+
"3xl": "calc(var(--tsqd-font-size) * 2.5)",
|
|
8763
|
+
"4xl": "calc(var(--tsqd-font-size) * 2.75)",
|
|
8764
|
+
"5xl": "calc(var(--tsqd-font-size) * 3)",
|
|
8765
|
+
"6xl": "calc(var(--tsqd-font-size) * 3.25)",
|
|
8766
|
+
"7xl": "calc(var(--tsqd-font-size) * 3.5)",
|
|
8767
|
+
"8xl": "calc(var(--tsqd-font-size) * 3.75)",
|
|
8768
|
+
"9xl": "calc(var(--tsqd-font-size) * 4)"
|
|
8769
8769
|
},
|
|
8770
8770
|
weight: {
|
|
8771
8771
|
thin: "100",
|
|
@@ -8790,55 +8790,55 @@ var tokens = {
|
|
|
8790
8790
|
border: {
|
|
8791
8791
|
radius: {
|
|
8792
8792
|
none: "0px",
|
|
8793
|
-
xs: "0.
|
|
8794
|
-
sm: "0.
|
|
8795
|
-
md: "0.
|
|
8796
|
-
lg: "0.
|
|
8797
|
-
xl: "0.
|
|
8798
|
-
"2xl": "
|
|
8799
|
-
"3xl": "1.
|
|
8793
|
+
xs: "calc(var(--tsqd-font-size) * 0.125)",
|
|
8794
|
+
sm: "calc(var(--tsqd-font-size) * 0.25)",
|
|
8795
|
+
md: "calc(var(--tsqd-font-size) * 0.375)",
|
|
8796
|
+
lg: "calc(var(--tsqd-font-size) * 0.5)",
|
|
8797
|
+
xl: "calc(var(--tsqd-font-size) * 0.75)",
|
|
8798
|
+
"2xl": "calc(var(--tsqd-font-size) * 1)",
|
|
8799
|
+
"3xl": "calc(var(--tsqd-font-size) * 1.5)",
|
|
8800
8800
|
full: "9999px"
|
|
8801
8801
|
}
|
|
8802
8802
|
},
|
|
8803
8803
|
size: {
|
|
8804
8804
|
0: "0px",
|
|
8805
|
-
0.25: "0.
|
|
8806
|
-
0.5: "0.
|
|
8807
|
-
1: "0.
|
|
8808
|
-
1.5: "0.
|
|
8809
|
-
2: "0.
|
|
8810
|
-
2.5: "0.
|
|
8811
|
-
3: "0.
|
|
8812
|
-
3.5: "0.
|
|
8813
|
-
4: "
|
|
8814
|
-
4.5: "1.
|
|
8815
|
-
5: "1.
|
|
8816
|
-
5.5: "1.
|
|
8817
|
-
6: "1.
|
|
8818
|
-
6.5: "1.
|
|
8819
|
-
7: "1.
|
|
8820
|
-
8: "
|
|
8821
|
-
9: "2.
|
|
8822
|
-
10: "2.
|
|
8823
|
-
11: "2.
|
|
8824
|
-
12: "
|
|
8825
|
-
14: "3.
|
|
8826
|
-
16: "
|
|
8827
|
-
20: "
|
|
8828
|
-
24: "
|
|
8829
|
-
28: "
|
|
8830
|
-
32: "
|
|
8831
|
-
36: "
|
|
8832
|
-
40: "
|
|
8833
|
-
44: "
|
|
8834
|
-
48: "
|
|
8835
|
-
52: "
|
|
8836
|
-
56: "
|
|
8837
|
-
60: "
|
|
8838
|
-
64: "
|
|
8839
|
-
72: "
|
|
8840
|
-
80: "
|
|
8841
|
-
96: "
|
|
8805
|
+
0.25: "calc(var(--tsqd-font-size) * 0.0625)",
|
|
8806
|
+
0.5: "calc(var(--tsqd-font-size) * 0.125)",
|
|
8807
|
+
1: "calc(var(--tsqd-font-size) * 0.25)",
|
|
8808
|
+
1.5: "calc(var(--tsqd-font-size) * 0.375)",
|
|
8809
|
+
2: "calc(var(--tsqd-font-size) * 0.5)",
|
|
8810
|
+
2.5: "calc(var(--tsqd-font-size) * 0.625)",
|
|
8811
|
+
3: "calc(var(--tsqd-font-size) * 0.75)",
|
|
8812
|
+
3.5: "calc(var(--tsqd-font-size) * 0.875)",
|
|
8813
|
+
4: "calc(var(--tsqd-font-size) * 1)",
|
|
8814
|
+
4.5: "calc(var(--tsqd-font-size) * 1.125)",
|
|
8815
|
+
5: "calc(var(--tsqd-font-size) * 1.25)",
|
|
8816
|
+
5.5: "calc(var(--tsqd-font-size) * 1.375)",
|
|
8817
|
+
6: "calc(var(--tsqd-font-size) * 1.5)",
|
|
8818
|
+
6.5: "calc(var(--tsqd-font-size) * 1.625)",
|
|
8819
|
+
7: "calc(var(--tsqd-font-size) * 1.75)",
|
|
8820
|
+
8: "calc(var(--tsqd-font-size) * 2)",
|
|
8821
|
+
9: "calc(var(--tsqd-font-size) * 2.25)",
|
|
8822
|
+
10: "calc(var(--tsqd-font-size) * 2.5)",
|
|
8823
|
+
11: "calc(var(--tsqd-font-size) * 2.75)",
|
|
8824
|
+
12: "calc(var(--tsqd-font-size) * 3)",
|
|
8825
|
+
14: "calc(var(--tsqd-font-size) * 3.5)",
|
|
8826
|
+
16: "calc(var(--tsqd-font-size) * 4)",
|
|
8827
|
+
20: "calc(var(--tsqd-font-size) * 5)",
|
|
8828
|
+
24: "calc(var(--tsqd-font-size) * 6)",
|
|
8829
|
+
28: "calc(var(--tsqd-font-size) * 7)",
|
|
8830
|
+
32: "calc(var(--tsqd-font-size) * 8)",
|
|
8831
|
+
36: "calc(var(--tsqd-font-size) * 9)",
|
|
8832
|
+
40: "calc(var(--tsqd-font-size) * 10)",
|
|
8833
|
+
44: "calc(var(--tsqd-font-size) * 11)",
|
|
8834
|
+
48: "calc(var(--tsqd-font-size) * 12)",
|
|
8835
|
+
52: "calc(var(--tsqd-font-size) * 13)",
|
|
8836
|
+
56: "calc(var(--tsqd-font-size) * 14)",
|
|
8837
|
+
60: "calc(var(--tsqd-font-size) * 15)",
|
|
8838
|
+
64: "calc(var(--tsqd-font-size) * 16)",
|
|
8839
|
+
72: "calc(var(--tsqd-font-size) * 18)",
|
|
8840
|
+
80: "calc(var(--tsqd-font-size) * 20)",
|
|
8841
|
+
96: "calc(var(--tsqd-font-size) * 24)"
|
|
8842
8842
|
},
|
|
8843
8843
|
shadow: Shadow,
|
|
8844
8844
|
zIndices: {
|
|
@@ -11505,8 +11505,8 @@ var stylesFactory = (theme) => {
|
|
|
11505
11505
|
expanderButtonContainer: u`
|
|
11506
11506
|
display: flex;
|
|
11507
11507
|
align-items: center;
|
|
11508
|
-
line-height:
|
|
11509
|
-
min-height:
|
|
11508
|
+
line-height: ${size2[4]};
|
|
11509
|
+
min-height: ${size2[4]};
|
|
11510
11510
|
gap: ${size2[2]};
|
|
11511
11511
|
`,
|
|
11512
11512
|
expanderButton: u`
|
|
@@ -11514,7 +11514,7 @@ var stylesFactory = (theme) => {
|
|
|
11514
11514
|
color: inherit;
|
|
11515
11515
|
font: inherit;
|
|
11516
11516
|
outline: inherit;
|
|
11517
|
-
height:
|
|
11517
|
+
height: ${size2[5]};
|
|
11518
11518
|
background: transparent;
|
|
11519
11519
|
border: none;
|
|
11520
11520
|
padding: 0;
|
|
@@ -11556,8 +11556,8 @@ var stylesFactory = (theme) => {
|
|
|
11556
11556
|
display: inline-flex;
|
|
11557
11557
|
gap: ${size2[2]};
|
|
11558
11558
|
width: 100%;
|
|
11559
|
-
margin
|
|
11560
|
-
line-height:
|
|
11559
|
+
margin: ${size2[0.25]} 0px;
|
|
11560
|
+
line-height: ${size2[4.5]};
|
|
11561
11561
|
align-items: center;
|
|
11562
11562
|
`,
|
|
11563
11563
|
editableInput: u`
|
|
@@ -11657,8 +11657,9 @@ var Devtools = (props) => {
|
|
|
11657
11657
|
const position = createMemo(() => {
|
|
11658
11658
|
return props.localStore.position || useQueryDevtoolsContext().position || POSITION;
|
|
11659
11659
|
});
|
|
11660
|
+
let transitionsContainerRef;
|
|
11660
11661
|
createEffect(() => {
|
|
11661
|
-
const root =
|
|
11662
|
+
const root = transitionsContainerRef.parentElement;
|
|
11662
11663
|
const height = props.localStore.height || DEFAULT_HEIGHT;
|
|
11663
11664
|
const width = props.localStore.width || DEFAULT_WIDTH;
|
|
11664
11665
|
const panelPosition = position();
|
|
@@ -11671,6 +11672,18 @@ var Devtools = (props) => {
|
|
|
11671
11672
|
`${panelPosition === "left" ? "-" : ""}${width}px`
|
|
11672
11673
|
);
|
|
11673
11674
|
});
|
|
11675
|
+
onMount(() => {
|
|
11676
|
+
const onFocus = () => {
|
|
11677
|
+
const root = transitionsContainerRef.parentElement;
|
|
11678
|
+
const fontSize = getComputedStyle(root).fontSize;
|
|
11679
|
+
root.style.setProperty("--tsqd-font-size", fontSize);
|
|
11680
|
+
};
|
|
11681
|
+
onFocus();
|
|
11682
|
+
window.addEventListener("focus", onFocus);
|
|
11683
|
+
onCleanup(() => {
|
|
11684
|
+
window.removeEventListener("focus", onFocus);
|
|
11685
|
+
});
|
|
11686
|
+
});
|
|
11674
11687
|
return <div
|
|
11675
11688
|
class={clsx(
|
|
11676
11689
|
u`
|
|
@@ -11696,6 +11709,7 @@ var Devtools = (props) => {
|
|
|
11696
11709
|
`,
|
|
11697
11710
|
"tsqd-transitions-container"
|
|
11698
11711
|
)}
|
|
11712
|
+
ref={transitionsContainerRef}
|
|
11699
11713
|
>
|
|
11700
11714
|
<TransitionGroup name="tsqd-panel-transition"><Show when={isOpen()}><DevtoolsPanel
|
|
11701
11715
|
localStore={props.localStore}
|
|
@@ -11862,6 +11876,7 @@ var DevtoolsPanel = (props) => {
|
|
|
11862
11876
|
var ContentView = (props) => {
|
|
11863
11877
|
setupQueryCacheSubscription();
|
|
11864
11878
|
setupMutationCacheSubscription();
|
|
11879
|
+
let containerRef;
|
|
11865
11880
|
const theme = useTheme();
|
|
11866
11881
|
const styles = createMemo(() => {
|
|
11867
11882
|
return theme() === "dark" ? darkStyles2 : lightStyles2;
|
|
@@ -11939,6 +11954,11 @@ var ContentView = (props) => {
|
|
|
11939
11954
|
const setDevtoolsPosition = (pos) => {
|
|
11940
11955
|
props.setLocalStore("position", pos);
|
|
11941
11956
|
};
|
|
11957
|
+
const setComputedVariables = (el) => {
|
|
11958
|
+
const computedStyle = getComputedStyle(containerRef);
|
|
11959
|
+
const variable = computedStyle.getPropertyValue("--tsqd-font-size");
|
|
11960
|
+
el.style.setProperty("--tsqd-font-size", variable);
|
|
11961
|
+
};
|
|
11942
11962
|
return <>
|
|
11943
11963
|
<div
|
|
11944
11964
|
class={clsx(
|
|
@@ -11949,6 +11969,7 @@ var ContentView = (props) => {
|
|
|
11949
11969
|
`,
|
|
11950
11970
|
"tsqd-queries-container"
|
|
11951
11971
|
)}
|
|
11972
|
+
ref={containerRef}
|
|
11952
11973
|
>
|
|
11953
11974
|
<div class={clsx(styles().row, "tsqd-header")}>
|
|
11954
11975
|
<div class={styles().logoAndToggleContainer}>
|
|
@@ -12119,7 +12140,9 @@ var ContentView = (props) => {
|
|
|
12119
12140
|
"tsqd-action-settings"
|
|
12120
12141
|
)}
|
|
12121
12142
|
><Settings /></index$d.Trigger>
|
|
12122
|
-
<index$d.Portal
|
|
12143
|
+
<index$d.Portal
|
|
12144
|
+
ref={(el) => setComputedVariables(el)}
|
|
12145
|
+
><index$d.Content
|
|
12123
12146
|
class={clsx(styles().settingsMenu, "tsqd-settings-menu")}
|
|
12124
12147
|
>
|
|
12125
12148
|
<div
|
|
@@ -12139,7 +12162,9 @@ var ContentView = (props) => {
|
|
|
12139
12162
|
<span>Position</span>
|
|
12140
12163
|
<ChevronDown />
|
|
12141
12164
|
</index$d.SubTrigger>
|
|
12142
|
-
<index$d.Portal
|
|
12165
|
+
<index$d.Portal
|
|
12166
|
+
ref={(el) => setComputedVariables(el)}
|
|
12167
|
+
><index$d.SubContent
|
|
12143
12168
|
class={clsx(
|
|
12144
12169
|
styles().settingsMenu,
|
|
12145
12170
|
"tsqd-settings-submenu"
|
|
@@ -12214,7 +12239,9 @@ var ContentView = (props) => {
|
|
|
12214
12239
|
<span>Theme</span>
|
|
12215
12240
|
<ChevronDown />
|
|
12216
12241
|
</index$d.SubTrigger>
|
|
12217
|
-
<index$d.Portal
|
|
12242
|
+
<index$d.Portal
|
|
12243
|
+
ref={(el) => setComputedVariables(el)}
|
|
12244
|
+
><index$d.SubContent
|
|
12218
12245
|
class={clsx(
|
|
12219
12246
|
styles().settingsMenu,
|
|
12220
12247
|
"tsqd-settings-submenu"
|
|
@@ -12904,7 +12931,7 @@ var QueryDetails = () => {
|
|
|
12904
12931
|
<div class={clsx(styles().detailsHeader, "tsqd-query-details-header")}>Data Explorer</div>
|
|
12905
12932
|
<div
|
|
12906
12933
|
style={{
|
|
12907
|
-
padding:
|
|
12934
|
+
padding: tokens.size[2]
|
|
12908
12935
|
}}
|
|
12909
12936
|
class="tsqd-query-details-explorer-container tsqd-query-details-data-explorer"
|
|
12910
12937
|
><Explorer
|
|
@@ -12917,7 +12944,7 @@ var QueryDetails = () => {
|
|
|
12917
12944
|
<div class={clsx(styles().detailsHeader, "tsqd-query-details-header")}>Query Explorer</div>
|
|
12918
12945
|
<div
|
|
12919
12946
|
style={{
|
|
12920
|
-
padding:
|
|
12947
|
+
padding: tokens.size[2]
|
|
12921
12948
|
}}
|
|
12922
12949
|
class="tsqd-query-details-explorer-container tsqd-query-details-query-explorer"
|
|
12923
12950
|
><Explorer
|
|
@@ -13008,7 +13035,7 @@ var MutationDetails = () => {
|
|
|
13008
13035
|
<div class={clsx(styles().detailsHeader, "tsqd-query-details-header")}>Variables Details</div>
|
|
13009
13036
|
<div
|
|
13010
13037
|
style={{
|
|
13011
|
-
padding:
|
|
13038
|
+
padding: tokens.size[2]
|
|
13012
13039
|
}}
|
|
13013
13040
|
class="tsqd-query-details-explorer-container tsqd-query-details-query-explorer"
|
|
13014
13041
|
><Explorer
|
|
@@ -13019,7 +13046,7 @@ var MutationDetails = () => {
|
|
|
13019
13046
|
<div class={clsx(styles().detailsHeader, "tsqd-query-details-header")}>Context Details</div>
|
|
13020
13047
|
<div
|
|
13021
13048
|
style={{
|
|
13022
|
-
padding:
|
|
13049
|
+
padding: tokens.size[2]
|
|
13023
13050
|
}}
|
|
13024
13051
|
class="tsqd-query-details-explorer-container tsqd-query-details-query-explorer"
|
|
13025
13052
|
><Explorer
|
|
@@ -13030,7 +13057,7 @@ var MutationDetails = () => {
|
|
|
13030
13057
|
<div class={clsx(styles().detailsHeader, "tsqd-query-details-header")}>Data Explorer</div>
|
|
13031
13058
|
<div
|
|
13032
13059
|
style={{
|
|
13033
|
-
padding:
|
|
13060
|
+
padding: tokens.size[2]
|
|
13034
13061
|
}}
|
|
13035
13062
|
class="tsqd-query-details-explorer-container tsqd-query-details-query-explorer"
|
|
13036
13063
|
><Explorer
|
|
@@ -13041,7 +13068,7 @@ var MutationDetails = () => {
|
|
|
13041
13068
|
<div class={clsx(styles().detailsHeader, "tsqd-query-details-header")}>Mutations Explorer</div>
|
|
13042
13069
|
<div
|
|
13043
13070
|
style={{
|
|
13044
|
-
padding:
|
|
13071
|
+
padding: tokens.size[2]
|
|
13045
13072
|
}}
|
|
13046
13073
|
class="tsqd-query-details-explorer-container tsqd-query-details-query-explorer"
|
|
13047
13074
|
><Explorer
|
|
@@ -13214,7 +13241,7 @@ var stylesFactory2 = (theme) => {
|
|
|
13214
13241
|
right: 0;
|
|
13215
13242
|
left: 0;
|
|
13216
13243
|
max-height: 90%;
|
|
13217
|
-
min-height:
|
|
13244
|
+
min-height: ${size2[14]};
|
|
13218
13245
|
border-bottom: ${t2(colors.gray[400], colors.darkGray[300])} 1px solid;
|
|
13219
13246
|
`,
|
|
13220
13247
|
"panel-position-bottom": u`
|
|
@@ -13222,7 +13249,7 @@ var stylesFactory2 = (theme) => {
|
|
|
13222
13249
|
right: 0;
|
|
13223
13250
|
left: 0;
|
|
13224
13251
|
max-height: 90%;
|
|
13225
|
-
min-height:
|
|
13252
|
+
min-height: ${size2[14]};
|
|
13226
13253
|
border-top: ${t2(colors.gray[400], colors.darkGray[300])} 1px solid;
|
|
13227
13254
|
`,
|
|
13228
13255
|
"panel-position-right": u`
|
|
@@ -13554,6 +13581,8 @@ var stylesFactory2 = (theme) => {
|
|
|
13554
13581
|
outline: 2px solid ${colors.blue[800]};
|
|
13555
13582
|
}
|
|
13556
13583
|
& svg {
|
|
13584
|
+
width: ${tokens.size[3]};
|
|
13585
|
+
height: ${tokens.size[3]};
|
|
13557
13586
|
color: ${t2(colors.gray[500], colors.gray[400])};
|
|
13558
13587
|
}
|
|
13559
13588
|
}
|
|
@@ -13639,8 +13668,8 @@ var stylesFactory2 = (theme) => {
|
|
|
13639
13668
|
border-radius: ${tokens.border.radius.sm};
|
|
13640
13669
|
background-color: ${t2(colors.gray[100], colors.darkGray[400])};
|
|
13641
13670
|
border: 1px solid ${t2(colors.gray[300], colors.darkGray[200])};
|
|
13642
|
-
width:
|
|
13643
|
-
height:
|
|
13671
|
+
width: ${tokens.size[6.5]};
|
|
13672
|
+
height: ${tokens.size[6.5]};
|
|
13644
13673
|
justify-content: center;
|
|
13645
13674
|
display: flex;
|
|
13646
13675
|
align-items: center;
|