@tanstack/react-query-devtools 4.39.0 → 4.39.1

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.
Files changed (78) hide show
  1. package/build/lib/Explorer.esm.js +264 -0
  2. package/build/lib/Explorer.esm.js.map +1 -0
  3. package/build/lib/Explorer.js +302 -0
  4. package/build/lib/Explorer.js.map +1 -0
  5. package/build/lib/Explorer.mjs +264 -0
  6. package/build/lib/Explorer.mjs.map +1 -0
  7. package/build/lib/Logo.esm.js +32 -0
  8. package/build/lib/Logo.esm.js.map +1 -0
  9. package/build/lib/Logo.js +56 -0
  10. package/build/lib/Logo.js.map +1 -0
  11. package/build/lib/Logo.mjs +32 -0
  12. package/build/lib/Logo.mjs.map +1 -0
  13. package/build/lib/_virtual/_rollupPluginBabelHelpers.esm.js +19 -0
  14. package/build/lib/_virtual/_rollupPluginBabelHelpers.esm.js.map +1 -0
  15. package/build/lib/_virtual/_rollupPluginBabelHelpers.js +23 -0
  16. package/build/lib/_virtual/_rollupPluginBabelHelpers.js.map +1 -0
  17. package/build/lib/_virtual/_rollupPluginBabelHelpers.mjs +19 -0
  18. package/build/lib/_virtual/_rollupPluginBabelHelpers.mjs.map +1 -0
  19. package/build/lib/devtools.esm.js +925 -0
  20. package/build/lib/devtools.esm.js.map +1 -0
  21. package/build/lib/devtools.js +949 -0
  22. package/build/lib/devtools.js.map +1 -0
  23. package/build/lib/devtools.mjs +925 -0
  24. package/build/lib/devtools.mjs.map +1 -0
  25. package/build/lib/index.esm.js +12 -0
  26. package/build/lib/index.esm.js.map +1 -0
  27. package/build/lib/index.js +17 -0
  28. package/build/lib/index.js.map +1 -0
  29. package/build/lib/index.mjs +12 -0
  30. package/build/lib/index.mjs.map +1 -0
  31. package/build/lib/index.prod.d.ts +4 -0
  32. package/build/lib/index.prod.esm.js +1604 -0
  33. package/build/lib/index.prod.esm.js.map +1 -0
  34. package/build/lib/index.prod.js +1631 -0
  35. package/build/lib/index.prod.js.map +1 -0
  36. package/build/lib/index.prod.mjs +1604 -0
  37. package/build/lib/index.prod.mjs.map +1 -0
  38. package/build/lib/screenreader.esm.js +17 -0
  39. package/build/lib/screenreader.esm.js.map +1 -0
  40. package/build/lib/screenreader.js +41 -0
  41. package/build/lib/screenreader.js.map +1 -0
  42. package/build/lib/screenreader.mjs +17 -0
  43. package/build/lib/screenreader.mjs.map +1 -0
  44. package/build/lib/styledComponents.esm.js +94 -0
  45. package/build/lib/styledComponents.esm.js.map +1 -0
  46. package/build/lib/styledComponents.js +105 -0
  47. package/build/lib/styledComponents.js.map +1 -0
  48. package/build/lib/styledComponents.mjs +94 -0
  49. package/build/lib/styledComponents.mjs.map +1 -0
  50. package/build/lib/theme.esm.js +33 -0
  51. package/build/lib/theme.esm.js.map +1 -0
  52. package/build/lib/theme.js +59 -0
  53. package/build/lib/theme.js.map +1 -0
  54. package/build/lib/theme.mjs +33 -0
  55. package/build/lib/theme.mjs.map +1 -0
  56. package/build/lib/useLocalStorage.esm.js +47 -0
  57. package/build/lib/useLocalStorage.esm.js.map +1 -0
  58. package/build/lib/useLocalStorage.js +71 -0
  59. package/build/lib/useLocalStorage.js.map +1 -0
  60. package/build/lib/useLocalStorage.mjs +47 -0
  61. package/build/lib/useLocalStorage.mjs.map +1 -0
  62. package/build/lib/useMediaQuery.esm.js +36 -0
  63. package/build/lib/useMediaQuery.esm.js.map +1 -0
  64. package/build/lib/useMediaQuery.js +60 -0
  65. package/build/lib/useMediaQuery.js.map +1 -0
  66. package/build/lib/useMediaQuery.mjs +36 -0
  67. package/build/lib/useMediaQuery.mjs.map +1 -0
  68. package/build/lib/utils.esm.js +186 -0
  69. package/build/lib/utils.esm.js.map +1 -0
  70. package/build/lib/utils.js +226 -0
  71. package/build/lib/utils.js.map +1 -0
  72. package/build/lib/utils.mjs +186 -0
  73. package/build/lib/utils.mjs.map +1 -0
  74. package/build/umd/index.development.js +3531 -0
  75. package/build/umd/index.development.js.map +1 -0
  76. package/build/umd/index.production.js +2 -0
  77. package/build/umd/index.production.js.map +1 -0
  78. package/package.json +3 -3
@@ -0,0 +1,949 @@
1
+ 'use client';
2
+ 'use strict';
3
+
4
+ Object.defineProperty(exports, '__esModule', { value: true });
5
+
6
+ var _rollupPluginBabelHelpers = require('./_virtual/_rollupPluginBabelHelpers.js');
7
+ var React = require('react');
8
+ var reactQuery = require('@tanstack/react-query');
9
+ var matchSorterUtils = require('@tanstack/match-sorter-utils');
10
+ var useLocalStorage = require('./useLocalStorage.js');
11
+ var utils = require('./utils.js');
12
+ var styledComponents = require('./styledComponents.js');
13
+ var screenreader = require('./screenreader.js');
14
+ var theme = require('./theme.js');
15
+ var Explorer = require('./Explorer.js');
16
+ var Logo = require('./Logo.js');
17
+ var index_js = require('use-sync-external-store/shim/index.js');
18
+
19
+ function _interopNamespace(e) {
20
+ if (e && e.__esModule) return e;
21
+ var n = Object.create(null);
22
+ if (e) {
23
+ Object.keys(e).forEach(function (k) {
24
+ if (k !== 'default') {
25
+ var d = Object.getOwnPropertyDescriptor(e, k);
26
+ Object.defineProperty(n, k, d.get ? d : {
27
+ enumerable: true,
28
+ get: function () { return e[k]; }
29
+ });
30
+ }
31
+ });
32
+ }
33
+ n["default"] = e;
34
+ return Object.freeze(n);
35
+ }
36
+
37
+ var React__namespace = /*#__PURE__*/_interopNamespace(React);
38
+
39
+ function ReactQueryDevtools({
40
+ initialIsOpen,
41
+ panelProps = {},
42
+ closeButtonProps = {},
43
+ toggleButtonProps = {},
44
+ position = 'bottom-left',
45
+ containerElement: Container = 'aside',
46
+ context,
47
+ styleNonce,
48
+ panelPosition: initialPanelPosition = 'bottom',
49
+ errorTypes = []
50
+ }) {
51
+ const rootRef = React__namespace.useRef(null);
52
+ const panelRef = React__namespace.useRef(null);
53
+ const [isOpen, setIsOpen] = useLocalStorage["default"]('reactQueryDevtoolsOpen', initialIsOpen);
54
+ const [devtoolsHeight, setDevtoolsHeight] = useLocalStorage["default"]('reactQueryDevtoolsHeight', utils.defaultPanelSize);
55
+ const [devtoolsWidth, setDevtoolsWidth] = useLocalStorage["default"]('reactQueryDevtoolsWidth', utils.defaultPanelSize);
56
+ const [panelPosition = 'bottom', setPanelPosition] = useLocalStorage["default"]('reactQueryDevtoolsPanelPosition', initialPanelPosition);
57
+ const [isResolvedOpen, setIsResolvedOpen] = React__namespace.useState(false);
58
+ const [isResizing, setIsResizing] = React__namespace.useState(false);
59
+ const isMounted = utils.useIsMounted();
60
+
61
+ const handleDragStart = (panelElement, startEvent) => {
62
+ if (!panelElement) return;
63
+ if (startEvent.button !== 0) return; // Only allow left click for drag
64
+
65
+ const isVertical = utils.isVerticalSide(panelPosition);
66
+ setIsResizing(true);
67
+ const {
68
+ height,
69
+ width
70
+ } = panelElement.getBoundingClientRect();
71
+ const startX = startEvent.clientX;
72
+ const startY = startEvent.clientY;
73
+ let newSize = 0;
74
+
75
+ const run = moveEvent => {
76
+ // prevent mouse selecting stuff with mouse drag
77
+ moveEvent.preventDefault(); // calculate the correct size based on mouse position and current panel position
78
+ // hint: it is different formula for the opposite sides
79
+
80
+ if (isVertical) {
81
+ newSize = width + (panelPosition === 'right' ? startX - moveEvent.clientX : moveEvent.clientX - startX);
82
+ setDevtoolsWidth(newSize);
83
+ } else {
84
+ newSize = height + (panelPosition === 'bottom' ? startY - moveEvent.clientY : moveEvent.clientY - startY);
85
+ setDevtoolsHeight(newSize);
86
+ }
87
+
88
+ if (newSize < utils.minPanelSize) {
89
+ setIsOpen(false);
90
+ } else {
91
+ setIsOpen(true);
92
+ }
93
+ };
94
+
95
+ const unsub = () => {
96
+ if (isResizing) {
97
+ setIsResizing(false);
98
+ }
99
+
100
+ document.removeEventListener('mousemove', run, false);
101
+ document.removeEventListener('mouseUp', unsub, false);
102
+ };
103
+
104
+ document.addEventListener('mousemove', run, false);
105
+ document.addEventListener('mouseup', unsub, false);
106
+ };
107
+
108
+ React__namespace.useEffect(() => {
109
+ setIsResolvedOpen(isOpen != null ? isOpen : false);
110
+ }, [isOpen, isResolvedOpen, setIsResolvedOpen]); // Toggle panel visibility before/after transition (depending on direction).
111
+ // Prevents focusing in a closed panel.
112
+
113
+ React__namespace.useEffect(() => {
114
+ const ref = panelRef.current;
115
+
116
+ if (ref) {
117
+ const handlePanelTransitionStart = () => {
118
+ if (isResolvedOpen) {
119
+ ref.style.visibility = 'visible';
120
+ }
121
+ };
122
+
123
+ const handlePanelTransitionEnd = () => {
124
+ if (!isResolvedOpen) {
125
+ ref.style.visibility = 'hidden';
126
+ }
127
+ };
128
+
129
+ ref.addEventListener('transitionstart', handlePanelTransitionStart);
130
+ ref.addEventListener('transitionend', handlePanelTransitionEnd);
131
+ return () => {
132
+ ref.removeEventListener('transitionstart', handlePanelTransitionStart);
133
+ ref.removeEventListener('transitionend', handlePanelTransitionEnd);
134
+ };
135
+ }
136
+
137
+ return;
138
+ }, [isResolvedOpen]);
139
+ React__namespace.useEffect(() => {
140
+ var _rootRef$current;
141
+
142
+ if (isResolvedOpen && (_rootRef$current = rootRef.current) != null && _rootRef$current.parentElement) {
143
+ const {
144
+ parentElement
145
+ } = rootRef.current;
146
+ const styleProp = utils.getSidedProp('padding', panelPosition);
147
+ const isVertical = utils.isVerticalSide(panelPosition);
148
+
149
+ const previousPaddings = (({
150
+ padding,
151
+ paddingTop,
152
+ paddingBottom,
153
+ paddingLeft,
154
+ paddingRight
155
+ }) => ({
156
+ padding,
157
+ paddingTop,
158
+ paddingBottom,
159
+ paddingLeft,
160
+ paddingRight
161
+ }))(parentElement.style);
162
+
163
+ const run = () => {
164
+ // reset the padding
165
+ parentElement.style.padding = '0px';
166
+ parentElement.style.paddingTop = '0px';
167
+ parentElement.style.paddingBottom = '0px';
168
+ parentElement.style.paddingLeft = '0px';
169
+ parentElement.style.paddingRight = '0px'; // set the new padding based on the new panel position
170
+
171
+ parentElement.style[styleProp] = (isVertical ? devtoolsWidth : devtoolsHeight) + "px";
172
+ };
173
+
174
+ run();
175
+
176
+ if (typeof window !== 'undefined') {
177
+ window.addEventListener('resize', run);
178
+ return () => {
179
+ window.removeEventListener('resize', run);
180
+ Object.entries(previousPaddings).forEach(([property, previousValue]) => {
181
+ parentElement.style[property] = previousValue;
182
+ });
183
+ };
184
+ }
185
+ }
186
+
187
+ return;
188
+ }, [isResolvedOpen, panelPosition, devtoolsHeight, devtoolsWidth]);
189
+ const {
190
+ style: panelStyle = {},
191
+ ...otherPanelProps
192
+ } = panelProps;
193
+ const {
194
+ style: toggleButtonStyle = {},
195
+ onClick: onToggleClick,
196
+ ...otherToggleButtonProps
197
+ } = toggleButtonProps; // get computed style based on panel position
198
+
199
+ const style = utils.getSidePanelStyle({
200
+ position: panelPosition,
201
+ devtoolsTheme: theme.defaultTheme,
202
+ isOpen: isResolvedOpen,
203
+ height: devtoolsHeight,
204
+ width: devtoolsWidth,
205
+ isResizing,
206
+ panelStyle
207
+ }); // Do not render on the server
208
+
209
+ if (!isMounted()) return null;
210
+ return /*#__PURE__*/React__namespace.createElement(Container, {
211
+ ref: rootRef,
212
+ className: "ReactQueryDevtools",
213
+ "aria-label": "React Query Devtools"
214
+ }, /*#__PURE__*/React__namespace.createElement(theme.ThemeProvider, {
215
+ theme: theme.defaultTheme
216
+ }, /*#__PURE__*/React__namespace.createElement(ReactQueryDevtoolsPanel, _rollupPluginBabelHelpers["extends"]({
217
+ ref: panelRef,
218
+ context: context,
219
+ styleNonce: styleNonce,
220
+ position: panelPosition,
221
+ onPositionChange: setPanelPosition,
222
+ showCloseButton: true,
223
+ closeButtonProps: closeButtonProps
224
+ }, otherPanelProps, {
225
+ style: style,
226
+ isOpen: isResolvedOpen,
227
+ setIsOpen: setIsOpen,
228
+ onDragStart: e => handleDragStart(panelRef.current, e),
229
+ errorTypes: errorTypes
230
+ }))), !isResolvedOpen ? /*#__PURE__*/React__namespace.createElement("button", _rollupPluginBabelHelpers["extends"]({
231
+ type: "button"
232
+ }, otherToggleButtonProps, {
233
+ "aria-label": "Open React Query Devtools",
234
+ "aria-controls": "ReactQueryDevtoolsPanel",
235
+ "aria-haspopup": "true",
236
+ "aria-expanded": "false",
237
+ onClick: e => {
238
+ setIsOpen(true);
239
+ onToggleClick == null ? void 0 : onToggleClick(e);
240
+ },
241
+ style: {
242
+ background: 'none',
243
+ border: 0,
244
+ padding: 0,
245
+ position: 'fixed',
246
+ zIndex: 99999,
247
+ display: 'inline-flex',
248
+ fontSize: '1.5em',
249
+ margin: '.5em',
250
+ cursor: 'pointer',
251
+ width: 'fit-content',
252
+ ...(position === 'top-right' ? {
253
+ top: '0',
254
+ right: '0'
255
+ } : position === 'top-left' ? {
256
+ top: '0',
257
+ left: '0'
258
+ } : position === 'bottom-right' ? {
259
+ bottom: '0',
260
+ right: '0'
261
+ } : {
262
+ bottom: '0',
263
+ left: '0'
264
+ }),
265
+ ...toggleButtonStyle
266
+ }
267
+ }), /*#__PURE__*/React__namespace.createElement(Logo["default"], {
268
+ "aria-hidden": true
269
+ }), /*#__PURE__*/React__namespace.createElement(screenreader["default"], {
270
+ text: "Open React Query Devtools"
271
+ })) : null);
272
+ }
273
+
274
+ const useSubscribeToQueryCache = (queryCache, getSnapshot, skip = false) => {
275
+ return index_js.useSyncExternalStore(React__namespace.useCallback(onStoreChange => {
276
+ if (!skip) return queryCache.subscribe(reactQuery.notifyManager.batchCalls(onStoreChange));
277
+ return () => {
278
+ return;
279
+ };
280
+ }, [queryCache, skip]), getSnapshot, getSnapshot);
281
+ };
282
+
283
+ const ReactQueryDevtoolsPanel = /*#__PURE__*/React__namespace.forwardRef(function ReactQueryDevtoolsPanel(props, ref) {
284
+ const {
285
+ isOpen = true,
286
+ styleNonce,
287
+ setIsOpen,
288
+ context,
289
+ onDragStart,
290
+ onPositionChange,
291
+ showCloseButton,
292
+ position,
293
+ closeButtonProps = {},
294
+ errorTypes = [],
295
+ ...panelProps
296
+ } = props;
297
+ const {
298
+ onClick: onCloseClick,
299
+ ...otherCloseButtonProps
300
+ } = closeButtonProps;
301
+ const queryClient = reactQuery.useQueryClient({
302
+ context
303
+ });
304
+ const queryCache = queryClient.getQueryCache();
305
+ const [sort, setSort] = useLocalStorage["default"]('reactQueryDevtoolsSortFn', Object.keys(utils.sortFns)[0]);
306
+ const [filter, setFilter] = useLocalStorage["default"]('reactQueryDevtoolsFilter', '');
307
+ const [baseSort, setBaseSort] = useLocalStorage["default"]('reactQueryDevtoolsBaseSort', 1);
308
+ const sortFn = React__namespace.useMemo(() => utils.sortFns[sort], [sort]);
309
+ const queriesCount = useSubscribeToQueryCache(queryCache, () => queryCache.getAll().length, !isOpen);
310
+ const [activeQueryHash, setActiveQueryHash] = useLocalStorage["default"]('reactQueryDevtoolsActiveQueryHash', '');
311
+ const queries = React__namespace.useMemo(() => {
312
+ const unsortedQueries = queryCache.getAll();
313
+
314
+ if (queriesCount === 0) {
315
+ return [];
316
+ }
317
+
318
+ const filtered = filter ? unsortedQueries.filter(item => matchSorterUtils.rankItem(item.queryHash, filter).passed) : [...unsortedQueries];
319
+ const sorted = sortFn ? filtered.sort((a, b) => sortFn(a, b) * baseSort) : filtered;
320
+ return sorted;
321
+ }, [baseSort, sortFn, filter, queriesCount, queryCache]);
322
+ const [isMockOffline, setMockOffline] = React__namespace.useState(false);
323
+ return /*#__PURE__*/React__namespace.createElement(theme.ThemeProvider, {
324
+ theme: theme.defaultTheme
325
+ }, /*#__PURE__*/React__namespace.createElement(styledComponents.Panel, _rollupPluginBabelHelpers["extends"]({
326
+ ref: ref,
327
+ className: "ReactQueryDevtoolsPanel",
328
+ "aria-label": "React Query Devtools Panel",
329
+ id: "ReactQueryDevtoolsPanel"
330
+ }, panelProps, {
331
+ style: {
332
+ height: utils.defaultPanelSize,
333
+ position: 'relative',
334
+ ...panelProps.style
335
+ }
336
+ }), /*#__PURE__*/React__namespace.createElement("style", {
337
+ nonce: styleNonce,
338
+ dangerouslySetInnerHTML: {
339
+ __html: "\n .ReactQueryDevtoolsPanel * {\n scrollbar-color: " + theme.defaultTheme.backgroundAlt + " " + theme.defaultTheme.gray + ";\n }\n\n .ReactQueryDevtoolsPanel *::-webkit-scrollbar, .ReactQueryDevtoolsPanel scrollbar {\n width: 1em;\n height: 1em;\n }\n\n .ReactQueryDevtoolsPanel *::-webkit-scrollbar-track, .ReactQueryDevtoolsPanel scrollbar-track {\n background: " + theme.defaultTheme.backgroundAlt + ";\n }\n\n .ReactQueryDevtoolsPanel *::-webkit-scrollbar-thumb, .ReactQueryDevtoolsPanel scrollbar-thumb {\n background: " + theme.defaultTheme.gray + ";\n border-radius: .5em;\n border: 3px solid " + theme.defaultTheme.backgroundAlt + ";\n }\n "
340
+ }
341
+ }), /*#__PURE__*/React__namespace.createElement("div", {
342
+ style: utils.getResizeHandleStyle(position),
343
+ onMouseDown: onDragStart
344
+ }), isOpen && /*#__PURE__*/React__namespace.createElement("div", {
345
+ style: {
346
+ flex: '1 1 500px',
347
+ minHeight: '40%',
348
+ maxHeight: '100%',
349
+ overflow: 'auto',
350
+ borderRight: "1px solid " + theme.defaultTheme.grayAlt,
351
+ display: 'flex',
352
+ flexDirection: 'column'
353
+ }
354
+ }, /*#__PURE__*/React__namespace.createElement("div", {
355
+ style: {
356
+ padding: '.5em',
357
+ background: theme.defaultTheme.backgroundAlt,
358
+ display: 'flex',
359
+ justifyContent: 'space-between',
360
+ alignItems: 'center'
361
+ }
362
+ }, /*#__PURE__*/React__namespace.createElement("button", {
363
+ type: "button",
364
+ "aria-label": "Close React Query Devtools",
365
+ "aria-controls": "ReactQueryDevtoolsPanel",
366
+ "aria-haspopup": "true",
367
+ "aria-expanded": "true",
368
+ onClick: () => setIsOpen(false),
369
+ style: {
370
+ display: 'inline-flex',
371
+ background: 'none',
372
+ border: 0,
373
+ padding: 0,
374
+ marginRight: '.5em',
375
+ cursor: 'pointer'
376
+ }
377
+ }, /*#__PURE__*/React__namespace.createElement(Logo["default"], {
378
+ "aria-hidden": true
379
+ }), /*#__PURE__*/React__namespace.createElement(screenreader["default"], {
380
+ text: "Close React Query Devtools"
381
+ })), /*#__PURE__*/React__namespace.createElement("div", {
382
+ style: {
383
+ display: 'flex',
384
+ flexDirection: 'column'
385
+ }
386
+ }, /*#__PURE__*/React__namespace.createElement("div", {
387
+ style: {
388
+ display: 'flex',
389
+ justifyContent: 'space-between',
390
+ alignItems: 'center',
391
+ marginBottom: '.5em'
392
+ }
393
+ }, /*#__PURE__*/React__namespace.createElement(QueryStatusCount, {
394
+ queryCache: queryCache
395
+ }), position && onPositionChange ? /*#__PURE__*/React__namespace.createElement(styledComponents.Select, {
396
+ "aria-label": "Panel position",
397
+ value: position,
398
+ style: {
399
+ marginInlineStart: '.5em'
400
+ },
401
+ onChange: e => onPositionChange(e.target.value)
402
+ }, /*#__PURE__*/React__namespace.createElement("option", {
403
+ value: "left"
404
+ }, "Left"), /*#__PURE__*/React__namespace.createElement("option", {
405
+ value: "right"
406
+ }, "Right"), /*#__PURE__*/React__namespace.createElement("option", {
407
+ value: "top"
408
+ }, "Top"), /*#__PURE__*/React__namespace.createElement("option", {
409
+ value: "bottom"
410
+ }, "Bottom")) : null), /*#__PURE__*/React__namespace.createElement("div", {
411
+ style: {
412
+ display: 'flex',
413
+ alignItems: 'center',
414
+ flexWrap: 'wrap',
415
+ gap: '0.5em'
416
+ }
417
+ }, /*#__PURE__*/React__namespace.createElement(styledComponents.Input, {
418
+ placeholder: "Filter",
419
+ "aria-label": "Filter by queryhash",
420
+ value: filter != null ? filter : '',
421
+ onChange: e => setFilter(e.target.value),
422
+ onKeyDown: e => {
423
+ if (e.key === 'Escape') setFilter('');
424
+ },
425
+ style: {
426
+ flex: '1',
427
+ width: '100%'
428
+ }
429
+ }), /*#__PURE__*/React__namespace.createElement(styledComponents.Select, {
430
+ "aria-label": "Sort queries",
431
+ value: sort,
432
+ onChange: e => setSort(e.target.value),
433
+ style: {
434
+ flex: '1',
435
+ minWidth: 75,
436
+ marginRight: '.5em'
437
+ }
438
+ }, Object.keys(utils.sortFns).map(key => /*#__PURE__*/React__namespace.createElement("option", {
439
+ key: key,
440
+ value: key
441
+ }, "Sort by ", key))), /*#__PURE__*/React__namespace.createElement(styledComponents.Button, {
442
+ type: "button",
443
+ onClick: () => setBaseSort(old => old * -1),
444
+ style: {
445
+ padding: '.3em .4em',
446
+ marginRight: '.5em'
447
+ }
448
+ }, baseSort === 1 ? '⬆ Asc' : '⬇ Desc'), /*#__PURE__*/React__namespace.createElement(styledComponents.Button, {
449
+ title: "Clear cache",
450
+ "aria-label": "Clear cache",
451
+ type: "button",
452
+ onClick: () => queryCache.clear(),
453
+ style: {
454
+ padding: '.3em .4em',
455
+ marginRight: '.5em'
456
+ }
457
+ }, "Clear"), /*#__PURE__*/React__namespace.createElement(styledComponents.Button, {
458
+ type: "button",
459
+ onClick: () => {
460
+ if (isMockOffline) {
461
+ reactQuery.onlineManager.setOnline(undefined);
462
+ setMockOffline(false);
463
+ window.dispatchEvent(new Event('online'));
464
+ } else {
465
+ reactQuery.onlineManager.setOnline(false);
466
+ setMockOffline(true);
467
+ }
468
+ },
469
+ "aria-label": isMockOffline ? 'Restore offline mock' : 'Mock offline behavior',
470
+ title: isMockOffline ? 'Restore offline mock' : 'Mock offline behavior',
471
+ style: {
472
+ padding: '0',
473
+ height: '2em'
474
+ }
475
+ }, /*#__PURE__*/React__namespace.createElement("svg", {
476
+ xmlns: "http://www.w3.org/2000/svg",
477
+ width: "2em",
478
+ height: "2em",
479
+ viewBox: "0 0 24 24",
480
+ stroke: isMockOffline ? theme.defaultTheme.danger : 'currentColor',
481
+ fill: "none"
482
+ }, isMockOffline ? /*#__PURE__*/React__namespace.createElement(React__namespace.Fragment, null, /*#__PURE__*/React__namespace.createElement("path", {
483
+ stroke: "none",
484
+ d: "M0 0h24v24H0z",
485
+ fill: "none"
486
+ }), /*#__PURE__*/React__namespace.createElement("line", {
487
+ x1: "12",
488
+ y1: "18",
489
+ x2: "12.01",
490
+ y2: "18"
491
+ }), /*#__PURE__*/React__namespace.createElement("path", {
492
+ d: "M9.172 15.172a4 4 0 0 1 5.656 0"
493
+ }), /*#__PURE__*/React__namespace.createElement("path", {
494
+ d: "M6.343 12.343a7.963 7.963 0 0 1 3.864 -2.14m4.163 .155a7.965 7.965 0 0 1 3.287 2"
495
+ }), /*#__PURE__*/React__namespace.createElement("path", {
496
+ d: "M3.515 9.515a12 12 0 0 1 3.544 -2.455m3.101 -.92a12 12 0 0 1 10.325 3.374"
497
+ }), /*#__PURE__*/React__namespace.createElement("line", {
498
+ x1: "3",
499
+ y1: "3",
500
+ x2: "21",
501
+ y2: "21"
502
+ })) : /*#__PURE__*/React__namespace.createElement(React__namespace.Fragment, null, /*#__PURE__*/React__namespace.createElement("path", {
503
+ stroke: "none",
504
+ d: "M0 0h24v24H0z",
505
+ fill: "none"
506
+ }), /*#__PURE__*/React__namespace.createElement("line", {
507
+ x1: "12",
508
+ y1: "18",
509
+ x2: "12.01",
510
+ y2: "18"
511
+ }), /*#__PURE__*/React__namespace.createElement("path", {
512
+ d: "M9.172 15.172a4 4 0 0 1 5.656 0"
513
+ }), /*#__PURE__*/React__namespace.createElement("path", {
514
+ d: "M6.343 12.343a8 8 0 0 1 11.314 0"
515
+ }), /*#__PURE__*/React__namespace.createElement("path", {
516
+ d: "M3.515 9.515c4.686 -4.687 12.284 -4.687 17 0"
517
+ }))), /*#__PURE__*/React__namespace.createElement(screenreader["default"], {
518
+ text: isMockOffline ? 'Restore offline mock' : 'Mock offline behavior'
519
+ }))))), /*#__PURE__*/React__namespace.createElement("div", {
520
+ style: {
521
+ overflowY: 'auto',
522
+ flex: '1'
523
+ }
524
+ }, queries.map(query => {
525
+ return /*#__PURE__*/React__namespace.createElement(QueryRow, {
526
+ queryKey: query.queryKey,
527
+ activeQueryHash: activeQueryHash,
528
+ setActiveQueryHash: setActiveQueryHash,
529
+ key: query.queryHash,
530
+ queryCache: queryCache
531
+ });
532
+ }))), activeQueryHash && isOpen ? /*#__PURE__*/React__namespace.createElement(ActiveQuery, {
533
+ activeQueryHash: activeQueryHash,
534
+ queryCache: queryCache,
535
+ queryClient: queryClient,
536
+ errorTypes: errorTypes
537
+ }) : null, showCloseButton ? /*#__PURE__*/React__namespace.createElement(styledComponents.Button, _rollupPluginBabelHelpers["extends"]({
538
+ type: "button",
539
+ "aria-controls": "ReactQueryDevtoolsPanel",
540
+ "aria-haspopup": "true",
541
+ "aria-expanded": "true"
542
+ }, otherCloseButtonProps, {
543
+ style: {
544
+ position: 'absolute',
545
+ zIndex: 99999,
546
+ margin: '.5em',
547
+ bottom: 0,
548
+ left: 0,
549
+ ...otherCloseButtonProps.style
550
+ },
551
+ onClick: e => {
552
+ setIsOpen(false);
553
+ onCloseClick == null ? void 0 : onCloseClick(e);
554
+ }
555
+ }), "Close") : null));
556
+ });
557
+
558
+ const ActiveQuery = ({
559
+ queryCache,
560
+ activeQueryHash,
561
+ queryClient,
562
+ errorTypes
563
+ }) => {
564
+ var _useSubscribeToQueryC, _useSubscribeToQueryC2;
565
+
566
+ const activeQuery = useSubscribeToQueryCache(queryCache, () => queryCache.getAll().find(query => query.queryHash === activeQueryHash));
567
+ const activeQueryState = useSubscribeToQueryCache(queryCache, () => {
568
+ var _queryCache$getAll$fi;
569
+
570
+ return (_queryCache$getAll$fi = queryCache.getAll().find(query => query.queryHash === activeQueryHash)) == null ? void 0 : _queryCache$getAll$fi.state;
571
+ });
572
+ const isStale = (_useSubscribeToQueryC = useSubscribeToQueryCache(queryCache, () => {
573
+ var _queryCache$getAll$fi2;
574
+
575
+ return (_queryCache$getAll$fi2 = queryCache.getAll().find(query => query.queryHash === activeQueryHash)) == null ? void 0 : _queryCache$getAll$fi2.isStale();
576
+ })) != null ? _useSubscribeToQueryC : false;
577
+ const observerCount = (_useSubscribeToQueryC2 = useSubscribeToQueryCache(queryCache, () => {
578
+ var _queryCache$getAll$fi3;
579
+
580
+ return (_queryCache$getAll$fi3 = queryCache.getAll().find(query => query.queryHash === activeQueryHash)) == null ? void 0 : _queryCache$getAll$fi3.getObserversCount();
581
+ })) != null ? _useSubscribeToQueryC2 : 0;
582
+
583
+ const handleRefetch = () => {
584
+ const promise = activeQuery == null ? void 0 : activeQuery.fetch();
585
+ promise == null ? void 0 : promise.catch(noop);
586
+ };
587
+
588
+ const currentErrorTypeName = React.useMemo(() => {
589
+ if (activeQuery && activeQueryState != null && activeQueryState.error) {
590
+ const errorType = errorTypes.find(type => {
591
+ var _activeQueryState$err;
592
+
593
+ return type.initializer(activeQuery).toString() === ((_activeQueryState$err = activeQueryState.error) == null ? void 0 : _activeQueryState$err.toString());
594
+ });
595
+ return errorType == null ? void 0 : errorType.name;
596
+ }
597
+
598
+ return undefined;
599
+ }, [activeQuery, activeQueryState == null ? void 0 : activeQueryState.error, errorTypes]);
600
+
601
+ if (!activeQuery || !activeQueryState) {
602
+ return null;
603
+ }
604
+
605
+ const triggerError = errorType => {
606
+ var _errorType$initialize;
607
+
608
+ const error = (_errorType$initialize = errorType == null ? void 0 : errorType.initializer(activeQuery)) != null ? _errorType$initialize : new Error('Unknown error from devtools');
609
+ const __previousQueryOptions = activeQuery.options;
610
+ activeQuery.setState({
611
+ status: 'error',
612
+ error,
613
+ fetchMeta: { ...activeQuery.state.fetchMeta,
614
+ __previousQueryOptions
615
+ }
616
+ });
617
+ };
618
+
619
+ const restoreQueryAfterLoadingOrError = () => {
620
+ activeQuery.fetch(activeQuery.state.fetchMeta.__previousQueryOptions, {
621
+ // Make sure this fetch will cancel the previous one
622
+ cancelRefetch: true
623
+ });
624
+ };
625
+
626
+ return /*#__PURE__*/React__namespace.createElement(styledComponents.ActiveQueryPanel, null, /*#__PURE__*/React__namespace.createElement("div", {
627
+ style: {
628
+ padding: '.5em',
629
+ background: theme.defaultTheme.backgroundAlt,
630
+ position: 'sticky',
631
+ top: 0,
632
+ zIndex: 1
633
+ }
634
+ }, "Query Details"), /*#__PURE__*/React__namespace.createElement("div", {
635
+ style: {
636
+ padding: '.5em'
637
+ }
638
+ }, /*#__PURE__*/React__namespace.createElement("div", {
639
+ style: {
640
+ marginBottom: '.5em',
641
+ display: 'flex',
642
+ alignItems: 'flex-start',
643
+ justifyContent: 'space-between'
644
+ }
645
+ }, /*#__PURE__*/React__namespace.createElement(styledComponents.Code, {
646
+ style: {
647
+ lineHeight: '1.8em'
648
+ }
649
+ }, /*#__PURE__*/React__namespace.createElement("pre", {
650
+ style: {
651
+ margin: 0,
652
+ padding: 0,
653
+ overflow: 'auto'
654
+ }
655
+ }, utils.displayValue(activeQuery.queryKey, true))), /*#__PURE__*/React__namespace.createElement("span", {
656
+ style: {
657
+ padding: '0.3em .6em',
658
+ borderRadius: '0.4em',
659
+ fontWeight: 'bold',
660
+ textShadow: '0 2px 10px black',
661
+ background: utils.getQueryStatusColor({
662
+ queryState: activeQueryState,
663
+ isStale: isStale,
664
+ observerCount: observerCount,
665
+ theme: theme.defaultTheme
666
+ }),
667
+ flexShrink: 0
668
+ }
669
+ }, utils.getQueryStatusLabel(activeQuery))), /*#__PURE__*/React__namespace.createElement("div", {
670
+ style: {
671
+ marginBottom: '.5em',
672
+ display: 'flex',
673
+ alignItems: 'center',
674
+ justifyContent: 'space-between'
675
+ }
676
+ }, "Observers: ", /*#__PURE__*/React__namespace.createElement(styledComponents.Code, null, observerCount)), /*#__PURE__*/React__namespace.createElement("div", {
677
+ style: {
678
+ display: 'flex',
679
+ alignItems: 'center',
680
+ justifyContent: 'space-between'
681
+ }
682
+ }, "Last Updated:", ' ', /*#__PURE__*/React__namespace.createElement(styledComponents.Code, null, new Date(activeQueryState.dataUpdatedAt).toLocaleTimeString()))), /*#__PURE__*/React__namespace.createElement("div", {
683
+ style: {
684
+ background: theme.defaultTheme.backgroundAlt,
685
+ padding: '.5em',
686
+ position: 'sticky',
687
+ top: 0,
688
+ zIndex: 1
689
+ }
690
+ }, "Actions"), /*#__PURE__*/React__namespace.createElement("div", {
691
+ style: {
692
+ padding: '0.5em',
693
+ display: 'flex',
694
+ flexWrap: 'wrap',
695
+ gap: '0.5em',
696
+ alignItems: 'flex-end'
697
+ }
698
+ }, /*#__PURE__*/React__namespace.createElement(styledComponents.Button, {
699
+ type: "button",
700
+ onClick: handleRefetch,
701
+ disabled: activeQueryState.fetchStatus === 'fetching',
702
+ style: {
703
+ background: theme.defaultTheme.active
704
+ }
705
+ }, "Refetch"), ' ', /*#__PURE__*/React__namespace.createElement(styledComponents.Button, {
706
+ type: "button",
707
+ onClick: () => queryClient.invalidateQueries(activeQuery),
708
+ style: {
709
+ background: theme.defaultTheme.warning,
710
+ color: theme.defaultTheme.inputTextColor
711
+ }
712
+ }, "Invalidate"), ' ', /*#__PURE__*/React__namespace.createElement(styledComponents.Button, {
713
+ type: "button",
714
+ onClick: () => queryClient.resetQueries(activeQuery),
715
+ style: {
716
+ background: theme.defaultTheme.gray
717
+ }
718
+ }, "Reset"), ' ', /*#__PURE__*/React__namespace.createElement(styledComponents.Button, {
719
+ type: "button",
720
+ onClick: () => queryClient.removeQueries(activeQuery),
721
+ style: {
722
+ background: theme.defaultTheme.danger
723
+ }
724
+ }, "Remove"), ' ', /*#__PURE__*/React__namespace.createElement(styledComponents.Button, {
725
+ type: "button",
726
+ onClick: () => {
727
+ var _activeQuery$state$fe;
728
+
729
+ // Return early if the query is already restoring
730
+ if (activeQuery.state.fetchStatus === 'fetching' && typeof ((_activeQuery$state$fe = activeQuery.state.fetchMeta) == null ? void 0 : _activeQuery$state$fe.__previousQueryOptions) === 'undefined') {
731
+ return;
732
+ }
733
+
734
+ if (activeQuery.state.data === undefined) {
735
+ restoreQueryAfterLoadingOrError();
736
+ } else {
737
+ const __previousQueryOptions = activeQuery.options; // Trigger a fetch in order to trigger suspense as well.
738
+
739
+ activeQuery.fetch({ ...__previousQueryOptions,
740
+ queryFn: () => {
741
+ return new Promise(() => {// Never resolve
742
+ });
743
+ },
744
+ cacheTime: -1
745
+ });
746
+ activeQuery.setState({
747
+ data: undefined,
748
+ status: 'loading',
749
+ fetchMeta: { ...activeQuery.state.fetchMeta,
750
+ __previousQueryOptions
751
+ }
752
+ });
753
+ }
754
+ },
755
+ style: {
756
+ background: theme.defaultTheme.paused
757
+ }
758
+ }, activeQuery.state.status === 'loading' ? 'Restore' : 'Trigger', ' ', "loading"), ' ', errorTypes.length === 0 || activeQuery.state.status === 'error' ? /*#__PURE__*/React__namespace.createElement(styledComponents.Button, {
759
+ type: "button",
760
+ onClick: () => {
761
+ if (!activeQuery.state.error) {
762
+ triggerError();
763
+ } else {
764
+ queryClient.resetQueries(activeQuery);
765
+ }
766
+ },
767
+ style: {
768
+ background: theme.defaultTheme.danger
769
+ }
770
+ }, activeQuery.state.status === 'error' ? 'Restore' : 'Trigger', " error") : /*#__PURE__*/React__namespace.createElement("label", null, "Trigger error:", /*#__PURE__*/React__namespace.createElement(styledComponents.Select, {
771
+ value: currentErrorTypeName != null ? currentErrorTypeName : '',
772
+ style: {
773
+ marginInlineStart: '.5em'
774
+ },
775
+ onChange: e => {
776
+ const errorType = errorTypes.find(t => t.name === e.target.value);
777
+ triggerError(errorType);
778
+ }
779
+ }, /*#__PURE__*/React__namespace.createElement("option", {
780
+ key: "",
781
+ value: ""
782
+ }), errorTypes.map(errorType => /*#__PURE__*/React__namespace.createElement("option", {
783
+ key: errorType.name,
784
+ value: errorType.name
785
+ }, errorType.name))))), /*#__PURE__*/React__namespace.createElement("div", {
786
+ style: {
787
+ background: theme.defaultTheme.backgroundAlt,
788
+ padding: '.5em',
789
+ position: 'sticky',
790
+ top: 0,
791
+ zIndex: 1
792
+ }
793
+ }, "Data Explorer"), /*#__PURE__*/React__namespace.createElement("div", {
794
+ style: {
795
+ padding: '.5em'
796
+ }
797
+ }, /*#__PURE__*/React__namespace.createElement(Explorer["default"], {
798
+ label: "Data",
799
+ value: activeQueryState.data,
800
+ defaultExpanded: {},
801
+ copyable: true
802
+ })), /*#__PURE__*/React__namespace.createElement("div", {
803
+ style: {
804
+ background: theme.defaultTheme.backgroundAlt,
805
+ padding: '.5em',
806
+ position: 'sticky',
807
+ top: 0,
808
+ zIndex: 1
809
+ }
810
+ }, "Query Explorer"), /*#__PURE__*/React__namespace.createElement("div", {
811
+ style: {
812
+ padding: '.5em'
813
+ }
814
+ }, /*#__PURE__*/React__namespace.createElement(Explorer["default"], {
815
+ label: "Query",
816
+ value: activeQuery,
817
+ defaultExpanded: {
818
+ queryKey: true
819
+ }
820
+ })));
821
+ };
822
+
823
+ const QueryStatusCount = ({
824
+ queryCache
825
+ }) => {
826
+ const hasFresh = useSubscribeToQueryCache(queryCache, () => queryCache.getAll().filter(q => utils.getQueryStatusLabel(q) === 'fresh').length);
827
+ const hasFetching = useSubscribeToQueryCache(queryCache, () => queryCache.getAll().filter(q => utils.getQueryStatusLabel(q) === 'fetching').length);
828
+ const hasPaused = useSubscribeToQueryCache(queryCache, () => queryCache.getAll().filter(q => utils.getQueryStatusLabel(q) === 'paused').length);
829
+ const hasStale = useSubscribeToQueryCache(queryCache, () => queryCache.getAll().filter(q => utils.getQueryStatusLabel(q) === 'stale').length);
830
+ const hasInactive = useSubscribeToQueryCache(queryCache, () => queryCache.getAll().filter(q => utils.getQueryStatusLabel(q) === 'inactive').length);
831
+ return /*#__PURE__*/React__namespace.createElement(styledComponents.QueryKeys, null, /*#__PURE__*/React__namespace.createElement(styledComponents.QueryKey, {
832
+ style: {
833
+ background: theme.defaultTheme.success,
834
+ opacity: hasFresh ? 1 : 0.3
835
+ }
836
+ }, "fresh ", /*#__PURE__*/React__namespace.createElement(styledComponents.Code, null, "(", hasFresh, ")")), ' ', /*#__PURE__*/React__namespace.createElement(styledComponents.QueryKey, {
837
+ style: {
838
+ background: theme.defaultTheme.active,
839
+ opacity: hasFetching ? 1 : 0.3
840
+ }
841
+ }, "fetching ", /*#__PURE__*/React__namespace.createElement(styledComponents.Code, null, "(", hasFetching, ")")), ' ', /*#__PURE__*/React__namespace.createElement(styledComponents.QueryKey, {
842
+ style: {
843
+ background: theme.defaultTheme.paused,
844
+ opacity: hasPaused ? 1 : 0.3
845
+ }
846
+ }, "paused ", /*#__PURE__*/React__namespace.createElement(styledComponents.Code, null, "(", hasPaused, ")")), ' ', /*#__PURE__*/React__namespace.createElement(styledComponents.QueryKey, {
847
+ style: {
848
+ background: theme.defaultTheme.warning,
849
+ color: 'black',
850
+ textShadow: '0',
851
+ opacity: hasStale ? 1 : 0.3
852
+ }
853
+ }, "stale ", /*#__PURE__*/React__namespace.createElement(styledComponents.Code, null, "(", hasStale, ")")), ' ', /*#__PURE__*/React__namespace.createElement(styledComponents.QueryKey, {
854
+ style: {
855
+ background: theme.defaultTheme.gray,
856
+ opacity: hasInactive ? 1 : 0.3
857
+ }
858
+ }, "inactive ", /*#__PURE__*/React__namespace.createElement(styledComponents.Code, null, "(", hasInactive, ")")));
859
+ };
860
+
861
+ const QueryRow = /*#__PURE__*/React__namespace.memo(({
862
+ queryKey,
863
+ setActiveQueryHash,
864
+ activeQueryHash,
865
+ queryCache
866
+ }) => {
867
+ var _useSubscribeToQueryC3, _useSubscribeToQueryC4, _useSubscribeToQueryC5, _useSubscribeToQueryC6;
868
+
869
+ const queryHash = (_useSubscribeToQueryC3 = useSubscribeToQueryCache(queryCache, () => {
870
+ var _queryCache$find;
871
+
872
+ return (_queryCache$find = queryCache.find(queryKey)) == null ? void 0 : _queryCache$find.queryHash;
873
+ })) != null ? _useSubscribeToQueryC3 : '';
874
+ const queryState = useSubscribeToQueryCache(queryCache, () => {
875
+ var _queryCache$find2;
876
+
877
+ return (_queryCache$find2 = queryCache.find(queryKey)) == null ? void 0 : _queryCache$find2.state;
878
+ });
879
+ const isStale = (_useSubscribeToQueryC4 = useSubscribeToQueryCache(queryCache, () => {
880
+ var _queryCache$find3;
881
+
882
+ return (_queryCache$find3 = queryCache.find(queryKey)) == null ? void 0 : _queryCache$find3.isStale();
883
+ })) != null ? _useSubscribeToQueryC4 : false;
884
+ const isDisabled = (_useSubscribeToQueryC5 = useSubscribeToQueryCache(queryCache, () => {
885
+ var _queryCache$find4;
886
+
887
+ return (_queryCache$find4 = queryCache.find(queryKey)) == null ? void 0 : _queryCache$find4.isDisabled();
888
+ })) != null ? _useSubscribeToQueryC5 : false;
889
+ const observerCount = (_useSubscribeToQueryC6 = useSubscribeToQueryCache(queryCache, () => {
890
+ var _queryCache$find5;
891
+
892
+ return (_queryCache$find5 = queryCache.find(queryKey)) == null ? void 0 : _queryCache$find5.getObserversCount();
893
+ })) != null ? _useSubscribeToQueryC6 : 0;
894
+
895
+ if (!queryState) {
896
+ return null;
897
+ }
898
+
899
+ return /*#__PURE__*/React__namespace.createElement("div", {
900
+ role: "button",
901
+ "aria-label": "Open query details for " + queryHash,
902
+ onClick: () => setActiveQueryHash(activeQueryHash === queryHash ? '' : queryHash),
903
+ style: {
904
+ display: 'flex',
905
+ borderBottom: "solid 1px " + theme.defaultTheme.grayAlt,
906
+ cursor: 'pointer',
907
+ background: queryHash === activeQueryHash ? 'rgba(255,255,255,.1)' : undefined
908
+ }
909
+ }, /*#__PURE__*/React__namespace.createElement("div", {
910
+ style: {
911
+ flex: '0 0 auto',
912
+ width: '2em',
913
+ height: '2em',
914
+ background: utils.getQueryStatusColor({
915
+ queryState,
916
+ isStale,
917
+ observerCount,
918
+ theme: theme.defaultTheme
919
+ }),
920
+ display: 'flex',
921
+ alignItems: 'center',
922
+ justifyContent: 'center',
923
+ fontWeight: 'bold',
924
+ textShadow: isStale ? '0' : '0 0 10px black',
925
+ color: isStale ? 'black' : 'white'
926
+ }
927
+ }, observerCount), isDisabled ? /*#__PURE__*/React__namespace.createElement("div", {
928
+ style: {
929
+ flex: '0 0 auto',
930
+ height: '2em',
931
+ background: theme.defaultTheme.gray,
932
+ display: 'flex',
933
+ alignItems: 'center',
934
+ fontWeight: 'bold',
935
+ padding: '0 0.5em'
936
+ }
937
+ }, "disabled") : null, /*#__PURE__*/React__namespace.createElement(styledComponents.Code, {
938
+ style: {
939
+ padding: '.5em'
940
+ }
941
+ }, "" + queryHash));
942
+ });
943
+ QueryRow.displayName = 'QueryRow'; // eslint-disable-next-line @typescript-eslint/no-empty-function
944
+
945
+ function noop() {}
946
+
947
+ exports.ReactQueryDevtools = ReactQueryDevtools;
948
+ exports.ReactQueryDevtoolsPanel = ReactQueryDevtoolsPanel;
949
+ //# sourceMappingURL=devtools.js.map