@tanstack/router-devtools-core 1.132.51 → 1.133.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.
- package/dist/{BaseTanStackRouterDevtoolsPanel-CaAQWNvS.js → BaseTanStackRouterDevtoolsPanel-Cbvcs84k.js} +263 -148
- package/dist/BaseTanStackRouterDevtoolsPanel-Cbvcs84k.js.map +1 -0
- package/dist/{BaseTanStackRouterDevtoolsPanel-CbH9Ihs_.cjs → BaseTanStackRouterDevtoolsPanel-CiObEXSM.cjs} +262 -147
- package/dist/BaseTanStackRouterDevtoolsPanel-CiObEXSM.cjs.map +1 -0
- package/dist/{FloatingTanStackRouterDevtools-0xtXUOcx.cjs → FloatingTanStackRouterDevtools-BMhRQRk5.cjs} +3 -3
- package/dist/{FloatingTanStackRouterDevtools-0xtXUOcx.cjs.map → FloatingTanStackRouterDevtools-BMhRQRk5.cjs.map} +1 -1
- package/dist/{FloatingTanStackRouterDevtools-DdHNTjWg.js → FloatingTanStackRouterDevtools-KvPiI7YB.js} +3 -3
- package/dist/{FloatingTanStackRouterDevtools-DdHNTjWg.js.map → FloatingTanStackRouterDevtools-KvPiI7YB.js.map} +1 -1
- package/dist/cjs/TanStackRouterDevtoolsCore.d.cts +4 -5
- package/dist/cjs/TanStackRouterDevtoolsPanelCore.d.cts +2 -3
- package/dist/cjs/index.cjs +1 -1
- package/dist/cjs/useStyles.d.cts +2 -0
- package/dist/esm/TanStackRouterDevtoolsCore.d.ts +4 -5
- package/dist/esm/TanStackRouterDevtoolsPanelCore.d.ts +2 -3
- package/dist/esm/index.js +1 -1
- package/dist/esm/useStyles.d.ts +2 -0
- package/dist/{index-BiZF0hsR.js → index-Bz4rofgr.js} +3 -3
- package/dist/index-Bz4rofgr.js.map +1 -0
- package/dist/{index-CHaaetqh.cjs → index-sVJ8jjbP.cjs} +3 -3
- package/dist/index-sVJ8jjbP.cjs.map +1 -0
- package/package.json +1 -1
- package/src/BaseTanStackRouterDevtoolsPanel.tsx +169 -57
- package/src/TanStackRouterDevtoolsCore.tsx +4 -6
- package/src/TanStackRouterDevtoolsPanelCore.tsx +2 -4
- package/src/useStyles.tsx +10 -0
- package/dist/BaseTanStackRouterDevtoolsPanel-CaAQWNvS.js.map +0 -1
- package/dist/BaseTanStackRouterDevtoolsPanel-CbH9Ihs_.cjs.map +0 -1
- package/dist/index-BiZF0hsR.js.map +0 -1
- package/dist/index-CHaaetqh.cjs.map +0 -1
|
@@ -2,8 +2,8 @@ import { template, insert, memo, createComponent, effect, className, setAttribut
|
|
|
2
2
|
import { clsx } from "clsx";
|
|
3
3
|
import invariant from "tiny-invariant";
|
|
4
4
|
import { rootRouteId, trimPath, interpolatePath } from "@tanstack/router-core";
|
|
5
|
-
import { createSignal, createEffect, createRenderEffect, useContext, createMemo, Show, onCleanup } from "solid-js";
|
|
6
|
-
import { S as ShadowDomTargetContext, u as useDevtoolsOnClose } from "./index-
|
|
5
|
+
import { createSignal, createEffect, createRenderEffect, useContext, createMemo, untrack, Switch, Match, For, Show, onCleanup } from "solid-js";
|
|
6
|
+
import { S as ShadowDomTargetContext, u as useDevtoolsOnClose } from "./index-Bz4rofgr.js";
|
|
7
7
|
import * as goober from "goober";
|
|
8
8
|
const isServer = typeof window === "undefined";
|
|
9
9
|
function getStatusColor(match) {
|
|
@@ -645,6 +645,16 @@ const stylesFactory$1 = (shadowDOMTarget) => {
|
|
|
645
645
|
overflow-y: auto;
|
|
646
646
|
max-height: 50%;
|
|
647
647
|
`,
|
|
648
|
+
historyContainer: css`
|
|
649
|
+
display: flex;
|
|
650
|
+
flex: 1 1 auto;
|
|
651
|
+
overflow-y: auto;
|
|
652
|
+
max-height: 50%;
|
|
653
|
+
`,
|
|
654
|
+
historyOverflowContainer: css`
|
|
655
|
+
padding: ${size[1]} ${size[2]};
|
|
656
|
+
font-size: ${tokens.font.size.xs};
|
|
657
|
+
`,
|
|
648
658
|
maskedBadgeContainer: css`
|
|
649
659
|
flex: 1;
|
|
650
660
|
justify-content: flex-end;
|
|
@@ -1215,7 +1225,8 @@ function NavigateButton({
|
|
|
1215
1225
|
})();
|
|
1216
1226
|
}
|
|
1217
1227
|
delegateEvents(["click"]);
|
|
1218
|
-
var _tmpl$ = /* @__PURE__ */ template(`<button><div>TANSTACK</div><div>TanStack Router v1`), _tmpl$2 = /* @__PURE__ */ template(`<div><div>`), _tmpl$3 = /* @__PURE__ */ template(`<code> `), _tmpl$4 = /* @__PURE__ */ template(`<code>`), _tmpl$5 = /* @__PURE__ */ template(`<div><div role=button><div>`), _tmpl$6 = /* @__PURE__ */ template(`<div>`), _tmpl$7 = /* @__PURE__ */ template(`<div><button><svg xmlns=http://www.w3.org/2000/svg width=10 height=6 fill=none viewBox="0 0 10 6"><path stroke=currentColor stroke-linecap=round stroke-linejoin=round stroke-width=1.667 d="M1 1l4 4 4-4"></path></svg></button><div><div></div><div><div></div></div></div><div><div><div><span>Pathname</span></div><div><code></code></div><div><div><button type=button>Routes</button><button type=button>Matches</button></div><div><div>age / staleTime / gcTime</div></div></div><div>`), _tmpl$
|
|
1228
|
+
var _tmpl$ = /* @__PURE__ */ template(`<button><div>TANSTACK</div><div>TanStack Router v1`), _tmpl$2 = /* @__PURE__ */ template(`<div><div>`), _tmpl$3 = /* @__PURE__ */ template(`<code> `), _tmpl$4 = /* @__PURE__ */ template(`<code>`), _tmpl$5 = /* @__PURE__ */ template(`<div><div role=button><div>`), _tmpl$6 = /* @__PURE__ */ template(`<div>`), _tmpl$7 = /* @__PURE__ */ template(`<div><ul>`), _tmpl$8 = /* @__PURE__ */ template(`<div><button><svg xmlns=http://www.w3.org/2000/svg width=10 height=6 fill=none viewBox="0 0 10 6"><path stroke=currentColor stroke-linecap=round stroke-linejoin=round stroke-width=1.667 d="M1 1l4 4 4-4"></path></svg></button><div><div></div><div><div></div></div></div><div><div><div><span>Pathname</span></div><div><code></code></div><div><div><button type=button>Routes</button><button type=button>Matches</button><button type=button>History</button></div><div><div>age / staleTime / gcTime</div></div></div><div>`), _tmpl$9 = /* @__PURE__ */ template(`<div><span>masked`), _tmpl$0 = /* @__PURE__ */ template(`<div role=button><div>`), _tmpl$1 = /* @__PURE__ */ template(`<li><div>`), _tmpl$10 = /* @__PURE__ */ template(`<li>This panel displays the most recent 15 navigations.`), _tmpl$11 = /* @__PURE__ */ template(`<div><div><div>Cached Matches</div><div>age / staleTime / gcTime</div></div><div>`), _tmpl$12 = /* @__PURE__ */ template(`<div><div>Match Details</div><div><div><div><div></div></div><div><div>ID:</div><div><code></code></div></div><div><div>State:</div><div></div></div><div><div>Last Updated:</div><div></div></div></div></div><div>Explorer</div><div>`), _tmpl$13 = /* @__PURE__ */ template(`<div>Loader Data`), _tmpl$14 = /* @__PURE__ */ template(`<div><div><span>Search Params</span></div><div>`), _tmpl$15 = /* @__PURE__ */ template(`<span style=margin-left:0.5rem;>`), _tmpl$16 = /* @__PURE__ */ template(`<button type=button style=cursor:pointer; aria-label="Copy value to clipboard">`);
|
|
1229
|
+
const HISTORY_LIMIT = 15;
|
|
1219
1230
|
function Logo(props) {
|
|
1220
1231
|
const {
|
|
1221
1232
|
className: className$1,
|
|
@@ -1396,8 +1407,30 @@ const BaseTanStackRouterDevtoolsPanel = function BaseTanStackRouterDevtoolsPanel
|
|
|
1396
1407
|
...otherPanelProps
|
|
1397
1408
|
} = panelProps;
|
|
1398
1409
|
invariant(router, "No router was found for the TanStack Router Devtools. Please place the devtools in the <RouterProvider> component tree or pass the router instance to the devtools manually.");
|
|
1399
|
-
const [
|
|
1410
|
+
const [currentTab, setCurrentTab] = useLocalStorage("tanstackRouterDevtoolsActiveTab", "routes");
|
|
1400
1411
|
const [activeId, setActiveId] = useLocalStorage("tanstackRouterDevtoolsActiveRouteId", "");
|
|
1412
|
+
const [history, setHistory] = createSignal([]);
|
|
1413
|
+
const [hasHistoryOverflowed, setHasHistoryOverflowed] = createSignal(false);
|
|
1414
|
+
createEffect(() => {
|
|
1415
|
+
const matches = routerState().matches;
|
|
1416
|
+
const currentMatch = matches[matches.length - 1];
|
|
1417
|
+
if (!currentMatch) {
|
|
1418
|
+
return;
|
|
1419
|
+
}
|
|
1420
|
+
const historyUntracked = untrack(() => history());
|
|
1421
|
+
const lastMatch = historyUntracked[0];
|
|
1422
|
+
const sameLocation = lastMatch && lastMatch.pathname === currentMatch.pathname && JSON.stringify(lastMatch.search ?? {}) === JSON.stringify(currentMatch.search ?? {});
|
|
1423
|
+
if (!lastMatch || !sameLocation) {
|
|
1424
|
+
if (historyUntracked.length >= HISTORY_LIMIT) {
|
|
1425
|
+
setHasHistoryOverflowed(true);
|
|
1426
|
+
}
|
|
1427
|
+
setHistory((prev) => {
|
|
1428
|
+
const newHistory = [currentMatch, ...prev];
|
|
1429
|
+
newHistory.splice(HISTORY_LIMIT);
|
|
1430
|
+
return newHistory;
|
|
1431
|
+
});
|
|
1432
|
+
}
|
|
1433
|
+
});
|
|
1401
1434
|
const activeMatch = createMemo(() => {
|
|
1402
1435
|
const matches = [...routerState().pendingMatches ?? [], ...routerState().matches, ...routerState().cachedMatches];
|
|
1403
1436
|
return matches.find((d) => d.routeId === activeId() || d.id === activeId());
|
|
@@ -1414,9 +1447,9 @@ const BaseTanStackRouterDevtoolsPanel = function BaseTanStackRouterDevtoolsPanel
|
|
|
1414
1447
|
const activeMatchValue = createMemo(() => activeMatch());
|
|
1415
1448
|
const locationSearchValue = createMemo(() => routerState().location.search);
|
|
1416
1449
|
return (() => {
|
|
1417
|
-
var _el$11 = _tmpl$
|
|
1450
|
+
var _el$11 = _tmpl$8(), _el$12 = _el$11.firstChild, _el$13 = _el$12.firstChild, _el$14 = _el$12.nextSibling, _el$15 = _el$14.firstChild, _el$16 = _el$15.nextSibling, _el$17 = _el$16.firstChild, _el$18 = _el$14.nextSibling, _el$19 = _el$18.firstChild, _el$20 = _el$19.firstChild;
|
|
1418
1451
|
_el$20.firstChild;
|
|
1419
|
-
var _el$22 = _el$20.nextSibling, _el$23 = _el$22.firstChild, _el$24 = _el$22.nextSibling, _el$25 = _el$24.firstChild, _el$26 = _el$25.firstChild, _el$27 = _el$26.nextSibling, _el$28 = _el$
|
|
1452
|
+
var _el$22 = _el$20.nextSibling, _el$23 = _el$22.firstChild, _el$24 = _el$22.nextSibling, _el$25 = _el$24.firstChild, _el$26 = _el$25.firstChild, _el$27 = _el$26.nextSibling, _el$28 = _el$27.nextSibling, _el$29 = _el$25.nextSibling, _el$30 = _el$24.nextSibling;
|
|
1420
1453
|
spread(_el$11, mergeProps({
|
|
1421
1454
|
get ["class"]() {
|
|
1422
1455
|
return clsx(styles().devtoolsPanel, "TanStackRouterDevtoolsPanel", className$1 ? className$1() : "");
|
|
@@ -1426,10 +1459,10 @@ const BaseTanStackRouterDevtoolsPanel = function BaseTanStackRouterDevtoolsPanel
|
|
|
1426
1459
|
}
|
|
1427
1460
|
}, otherPanelProps), false, true);
|
|
1428
1461
|
insert(_el$11, handleDragStart ? (() => {
|
|
1429
|
-
var _el$
|
|
1430
|
-
addEventListener(_el$
|
|
1431
|
-
effect(() => className(_el$
|
|
1432
|
-
return _el$
|
|
1462
|
+
var _el$34 = _tmpl$6();
|
|
1463
|
+
addEventListener(_el$34, "mousedown", handleDragStart, true);
|
|
1464
|
+
effect(() => className(_el$34, styles().dragHandle));
|
|
1465
|
+
return _el$34;
|
|
1433
1466
|
})() : null, _el$12);
|
|
1434
1467
|
_el$12.$$click = (e) => {
|
|
1435
1468
|
if (setIsOpen) {
|
|
@@ -1461,106 +1494,184 @@ const BaseTanStackRouterDevtoolsPanel = function BaseTanStackRouterDevtoolsPanel
|
|
|
1461
1494
|
insert(_el$20, (() => {
|
|
1462
1495
|
var _c$2 = memo(() => !!routerState().location.maskedLocation);
|
|
1463
1496
|
return () => _c$2() ? (() => {
|
|
1464
|
-
var _el$
|
|
1497
|
+
var _el$35 = _tmpl$9(), _el$36 = _el$35.firstChild;
|
|
1465
1498
|
effect((_p$) => {
|
|
1466
|
-
var _v$
|
|
1467
|
-
_v$
|
|
1468
|
-
_v$
|
|
1499
|
+
var _v$24 = styles().maskedBadgeContainer, _v$25 = styles().maskedBadge;
|
|
1500
|
+
_v$24 !== _p$.e && className(_el$35, _p$.e = _v$24);
|
|
1501
|
+
_v$25 !== _p$.t && className(_el$36, _p$.t = _v$25);
|
|
1469
1502
|
return _p$;
|
|
1470
1503
|
}, {
|
|
1471
1504
|
e: void 0,
|
|
1472
1505
|
t: void 0
|
|
1473
1506
|
});
|
|
1474
|
-
return _el$
|
|
1507
|
+
return _el$35;
|
|
1475
1508
|
})() : null;
|
|
1476
1509
|
})(), null);
|
|
1477
1510
|
insert(_el$23, () => routerState().location.pathname);
|
|
1478
1511
|
insert(_el$22, (() => {
|
|
1479
1512
|
var _c$3 = memo(() => !!routerState().location.maskedLocation);
|
|
1480
1513
|
return () => _c$3() ? (() => {
|
|
1481
|
-
var _el$
|
|
1482
|
-
insert(_el$
|
|
1483
|
-
effect(() => className(_el$
|
|
1484
|
-
return _el$
|
|
1514
|
+
var _el$37 = _tmpl$4();
|
|
1515
|
+
insert(_el$37, () => routerState().location.maskedLocation?.pathname);
|
|
1516
|
+
effect(() => className(_el$37, styles().maskedLocation));
|
|
1517
|
+
return _el$37;
|
|
1485
1518
|
})() : null;
|
|
1486
1519
|
})(), null);
|
|
1487
1520
|
_el$26.$$click = () => {
|
|
1488
|
-
|
|
1521
|
+
setCurrentTab("routes");
|
|
1489
1522
|
};
|
|
1490
1523
|
_el$27.$$click = () => {
|
|
1491
|
-
|
|
1524
|
+
setCurrentTab("matches");
|
|
1492
1525
|
};
|
|
1493
|
-
|
|
1494
|
-
|
|
1495
|
-
|
|
1496
|
-
|
|
1497
|
-
|
|
1498
|
-
|
|
1499
|
-
|
|
1500
|
-
|
|
1501
|
-
|
|
1502
|
-
|
|
1503
|
-
|
|
1504
|
-
|
|
1505
|
-
|
|
1506
|
-
|
|
1507
|
-
|
|
1508
|
-
|
|
1509
|
-
|
|
1510
|
-
|
|
1511
|
-
|
|
1512
|
-
|
|
1513
|
-
|
|
1514
|
-
|
|
1515
|
-
|
|
1516
|
-
|
|
1517
|
-
|
|
1526
|
+
_el$28.$$click = () => {
|
|
1527
|
+
setCurrentTab("history");
|
|
1528
|
+
};
|
|
1529
|
+
insert(_el$30, createComponent(Switch, {
|
|
1530
|
+
get children() {
|
|
1531
|
+
return [createComponent(Match, {
|
|
1532
|
+
get when() {
|
|
1533
|
+
return currentTab() === "routes";
|
|
1534
|
+
},
|
|
1535
|
+
get children() {
|
|
1536
|
+
return createComponent(RouteComp, {
|
|
1537
|
+
routerState,
|
|
1538
|
+
router,
|
|
1539
|
+
get route() {
|
|
1540
|
+
return router().routeTree;
|
|
1541
|
+
},
|
|
1542
|
+
isRoot: true,
|
|
1543
|
+
activeId,
|
|
1544
|
+
setActiveId
|
|
1545
|
+
});
|
|
1546
|
+
}
|
|
1547
|
+
}), createComponent(Match, {
|
|
1548
|
+
get when() {
|
|
1549
|
+
return currentTab() === "matches";
|
|
1550
|
+
},
|
|
1551
|
+
get children() {
|
|
1552
|
+
var _el$31 = _tmpl$6();
|
|
1553
|
+
insert(_el$31, () => (routerState().pendingMatches?.length ? routerState().pendingMatches : routerState().matches)?.map((match, _i) => {
|
|
1554
|
+
return (() => {
|
|
1555
|
+
var _el$38 = _tmpl$0(), _el$39 = _el$38.firstChild;
|
|
1556
|
+
_el$38.$$click = () => setActiveId(activeId() === match.id ? "" : match.id);
|
|
1557
|
+
insert(_el$38, createComponent(NavigateLink, {
|
|
1558
|
+
get left() {
|
|
1559
|
+
return createComponent(NavigateButton, {
|
|
1560
|
+
get to() {
|
|
1561
|
+
return match.pathname;
|
|
1562
|
+
},
|
|
1563
|
+
get params() {
|
|
1564
|
+
return match.params;
|
|
1565
|
+
},
|
|
1566
|
+
get search() {
|
|
1567
|
+
return match.search;
|
|
1568
|
+
},
|
|
1569
|
+
router
|
|
1570
|
+
});
|
|
1518
1571
|
},
|
|
1519
|
-
get
|
|
1520
|
-
return
|
|
1572
|
+
get right() {
|
|
1573
|
+
return createComponent(AgeTicker, {
|
|
1574
|
+
match,
|
|
1575
|
+
router
|
|
1576
|
+
});
|
|
1521
1577
|
},
|
|
1522
|
-
|
|
1578
|
+
get children() {
|
|
1579
|
+
var _el$40 = _tmpl$4();
|
|
1580
|
+
insert(_el$40, () => `${match.routeId === rootRouteId ? rootRouteId : match.pathname}`);
|
|
1581
|
+
effect(() => className(_el$40, styles().matchID));
|
|
1582
|
+
return _el$40;
|
|
1583
|
+
}
|
|
1584
|
+
}), null);
|
|
1585
|
+
effect((_p$) => {
|
|
1586
|
+
var _v$26 = `Open match details for ${match.id}`, _v$27 = clsx(styles().matchRow(match === activeMatch())), _v$28 = clsx(styles().matchIndicator(getStatusColor(match)));
|
|
1587
|
+
_v$26 !== _p$.e && setAttribute(_el$38, "aria-label", _p$.e = _v$26);
|
|
1588
|
+
_v$27 !== _p$.t && className(_el$38, _p$.t = _v$27);
|
|
1589
|
+
_v$28 !== _p$.a && className(_el$39, _p$.a = _v$28);
|
|
1590
|
+
return _p$;
|
|
1591
|
+
}, {
|
|
1592
|
+
e: void 0,
|
|
1593
|
+
t: void 0,
|
|
1594
|
+
a: void 0
|
|
1523
1595
|
});
|
|
1596
|
+
return _el$38;
|
|
1597
|
+
})();
|
|
1598
|
+
}));
|
|
1599
|
+
return _el$31;
|
|
1600
|
+
}
|
|
1601
|
+
}), createComponent(Match, {
|
|
1602
|
+
get when() {
|
|
1603
|
+
return currentTab() === "history";
|
|
1604
|
+
},
|
|
1605
|
+
get children() {
|
|
1606
|
+
var _el$32 = _tmpl$7(), _el$33 = _el$32.firstChild;
|
|
1607
|
+
insert(_el$33, createComponent(For, {
|
|
1608
|
+
get each() {
|
|
1609
|
+
return history();
|
|
1524
1610
|
},
|
|
1525
|
-
|
|
1526
|
-
|
|
1527
|
-
|
|
1528
|
-
|
|
1611
|
+
children: (match, index) => (() => {
|
|
1612
|
+
var _el$41 = _tmpl$1(), _el$42 = _el$41.firstChild;
|
|
1613
|
+
insert(_el$41, createComponent(NavigateLink, {
|
|
1614
|
+
get left() {
|
|
1615
|
+
return createComponent(NavigateButton, {
|
|
1616
|
+
get to() {
|
|
1617
|
+
return match.pathname;
|
|
1618
|
+
},
|
|
1619
|
+
get params() {
|
|
1620
|
+
return match.params;
|
|
1621
|
+
},
|
|
1622
|
+
get search() {
|
|
1623
|
+
return match.search;
|
|
1624
|
+
},
|
|
1625
|
+
router
|
|
1626
|
+
});
|
|
1627
|
+
},
|
|
1628
|
+
get right() {
|
|
1629
|
+
return createComponent(AgeTicker, {
|
|
1630
|
+
match,
|
|
1631
|
+
router
|
|
1632
|
+
});
|
|
1633
|
+
},
|
|
1634
|
+
get children() {
|
|
1635
|
+
var _el$43 = _tmpl$4();
|
|
1636
|
+
insert(_el$43, () => `${match.routeId === rootRouteId ? rootRouteId : match.pathname}`);
|
|
1637
|
+
effect(() => className(_el$43, styles().matchID));
|
|
1638
|
+
return _el$43;
|
|
1639
|
+
}
|
|
1640
|
+
}), null);
|
|
1641
|
+
effect((_p$) => {
|
|
1642
|
+
var _v$29 = clsx(styles().matchRow(match === activeMatch())), _v$30 = clsx(styles().matchIndicator(index() === 0 ? "green" : "gray"));
|
|
1643
|
+
_v$29 !== _p$.e && className(_el$41, _p$.e = _v$29);
|
|
1644
|
+
_v$30 !== _p$.t && className(_el$42, _p$.t = _v$30);
|
|
1645
|
+
return _p$;
|
|
1646
|
+
}, {
|
|
1647
|
+
e: void 0,
|
|
1648
|
+
t: void 0
|
|
1529
1649
|
});
|
|
1530
|
-
|
|
1531
|
-
|
|
1532
|
-
var _el$37 = _tmpl$4();
|
|
1533
|
-
insert(_el$37, () => `${match.routeId === rootRouteId ? rootRouteId : match.pathname}`);
|
|
1534
|
-
effect(() => className(_el$37, styles().matchID));
|
|
1535
|
-
return _el$37;
|
|
1536
|
-
}
|
|
1650
|
+
return _el$41;
|
|
1651
|
+
})()
|
|
1537
1652
|
}), null);
|
|
1538
|
-
|
|
1539
|
-
var
|
|
1540
|
-
|
|
1541
|
-
|
|
1542
|
-
|
|
1543
|
-
|
|
1544
|
-
|
|
1545
|
-
|
|
1546
|
-
|
|
1547
|
-
|
|
1548
|
-
|
|
1549
|
-
|
|
1550
|
-
|
|
1551
|
-
}));
|
|
1552
|
-
return _el$34;
|
|
1553
|
-
})();
|
|
1554
|
-
})());
|
|
1653
|
+
insert(_el$33, (() => {
|
|
1654
|
+
var _c$4 = memo(() => !!hasHistoryOverflowed());
|
|
1655
|
+
return () => _c$4() ? (() => {
|
|
1656
|
+
var _el$44 = _tmpl$10();
|
|
1657
|
+
effect(() => className(_el$44, styles().historyOverflowContainer));
|
|
1658
|
+
return _el$44;
|
|
1659
|
+
})() : null;
|
|
1660
|
+
})(), null);
|
|
1661
|
+
return _el$32;
|
|
1662
|
+
}
|
|
1663
|
+
})];
|
|
1664
|
+
}
|
|
1665
|
+
}));
|
|
1555
1666
|
insert(_el$18, (() => {
|
|
1556
1667
|
var _c$5 = memo(() => !!routerState().cachedMatches.length);
|
|
1557
1668
|
return () => _c$5() ? (() => {
|
|
1558
|
-
var _el$
|
|
1559
|
-
insert(_el$
|
|
1669
|
+
var _el$45 = _tmpl$11(), _el$46 = _el$45.firstChild, _el$47 = _el$46.firstChild, _el$48 = _el$47.nextSibling, _el$49 = _el$46.nextSibling;
|
|
1670
|
+
insert(_el$49, () => routerState().cachedMatches.map((match) => {
|
|
1560
1671
|
return (() => {
|
|
1561
|
-
var _el$
|
|
1562
|
-
_el$
|
|
1563
|
-
insert(_el$
|
|
1672
|
+
var _el$50 = _tmpl$0(), _el$51 = _el$50.firstChild;
|
|
1673
|
+
_el$50.$$click = () => setActiveId(activeId() === match.id ? "" : match.id);
|
|
1674
|
+
insert(_el$50, createComponent(NavigateLink, {
|
|
1564
1675
|
get left() {
|
|
1565
1676
|
return createComponent(NavigateButton, {
|
|
1566
1677
|
get to() {
|
|
@@ -1582,93 +1693,93 @@ const BaseTanStackRouterDevtoolsPanel = function BaseTanStackRouterDevtoolsPanel
|
|
|
1582
1693
|
});
|
|
1583
1694
|
},
|
|
1584
1695
|
get children() {
|
|
1585
|
-
var _el$
|
|
1586
|
-
insert(_el$
|
|
1587
|
-
effect(() => className(_el$
|
|
1588
|
-
return _el$
|
|
1696
|
+
var _el$52 = _tmpl$4();
|
|
1697
|
+
insert(_el$52, () => `${match.id}`);
|
|
1698
|
+
effect(() => className(_el$52, styles().matchID));
|
|
1699
|
+
return _el$52;
|
|
1589
1700
|
}
|
|
1590
1701
|
}), null);
|
|
1591
1702
|
effect((_p$) => {
|
|
1592
|
-
var _v$
|
|
1593
|
-
_v$
|
|
1594
|
-
_v$
|
|
1595
|
-
_v$
|
|
1703
|
+
var _v$34 = `Open match details for ${match.id}`, _v$35 = clsx(styles().matchRow(match === activeMatch())), _v$36 = clsx(styles().matchIndicator(getStatusColor(match)));
|
|
1704
|
+
_v$34 !== _p$.e && setAttribute(_el$50, "aria-label", _p$.e = _v$34);
|
|
1705
|
+
_v$35 !== _p$.t && className(_el$50, _p$.t = _v$35);
|
|
1706
|
+
_v$36 !== _p$.a && className(_el$51, _p$.a = _v$36);
|
|
1596
1707
|
return _p$;
|
|
1597
1708
|
}, {
|
|
1598
1709
|
e: void 0,
|
|
1599
1710
|
t: void 0,
|
|
1600
1711
|
a: void 0
|
|
1601
1712
|
});
|
|
1602
|
-
return _el$
|
|
1713
|
+
return _el$50;
|
|
1603
1714
|
})();
|
|
1604
1715
|
}));
|
|
1605
1716
|
effect((_p$) => {
|
|
1606
|
-
var _v$
|
|
1607
|
-
_v$
|
|
1608
|
-
_v$
|
|
1609
|
-
_v$
|
|
1717
|
+
var _v$31 = styles().cachedMatchesContainer, _v$32 = styles().detailsHeader, _v$33 = styles().detailsHeaderInfo;
|
|
1718
|
+
_v$31 !== _p$.e && className(_el$45, _p$.e = _v$31);
|
|
1719
|
+
_v$32 !== _p$.t && className(_el$46, _p$.t = _v$32);
|
|
1720
|
+
_v$33 !== _p$.a && className(_el$48, _p$.a = _v$33);
|
|
1610
1721
|
return _p$;
|
|
1611
1722
|
}, {
|
|
1612
1723
|
e: void 0,
|
|
1613
1724
|
t: void 0,
|
|
1614
1725
|
a: void 0
|
|
1615
1726
|
});
|
|
1616
|
-
return _el$
|
|
1727
|
+
return _el$45;
|
|
1617
1728
|
})() : null;
|
|
1618
1729
|
})(), null);
|
|
1619
1730
|
insert(_el$11, (() => {
|
|
1620
1731
|
var _c$6 = memo(() => !!(activeMatch() && activeMatch()?.status));
|
|
1621
1732
|
return () => _c$6() ? (() => {
|
|
1622
|
-
var _el$
|
|
1623
|
-
insert(_el$
|
|
1733
|
+
var _el$53 = _tmpl$12(), _el$54 = _el$53.firstChild, _el$55 = _el$54.nextSibling, _el$56 = _el$55.firstChild, _el$57 = _el$56.firstChild, _el$58 = _el$57.firstChild, _el$59 = _el$57.nextSibling, _el$60 = _el$59.firstChild, _el$61 = _el$60.nextSibling, _el$62 = _el$61.firstChild, _el$63 = _el$59.nextSibling, _el$64 = _el$63.firstChild, _el$65 = _el$64.nextSibling, _el$66 = _el$63.nextSibling, _el$67 = _el$66.firstChild, _el$68 = _el$67.nextSibling, _el$69 = _el$55.nextSibling, _el$70 = _el$69.nextSibling;
|
|
1734
|
+
insert(_el$58, (() => {
|
|
1624
1735
|
var _c$8 = memo(() => !!(activeMatch()?.status === "success" && activeMatch()?.isFetching));
|
|
1625
1736
|
return () => _c$8() ? "fetching" : activeMatch()?.status;
|
|
1626
1737
|
})());
|
|
1627
|
-
insert(_el$
|
|
1628
|
-
insert(_el$
|
|
1738
|
+
insert(_el$62, () => activeMatch()?.id);
|
|
1739
|
+
insert(_el$65, (() => {
|
|
1629
1740
|
var _c$9 = memo(() => !!routerState().pendingMatches?.find((d) => d.id === activeMatch()?.id));
|
|
1630
1741
|
return () => _c$9() ? "Pending" : routerState().matches.find((d) => d.id === activeMatch()?.id) ? "Active" : "Cached";
|
|
1631
1742
|
})());
|
|
1632
|
-
insert(_el$
|
|
1743
|
+
insert(_el$68, (() => {
|
|
1633
1744
|
var _c$0 = memo(() => !!activeMatch()?.updatedAt);
|
|
1634
1745
|
return () => _c$0() ? new Date(activeMatch()?.updatedAt).toLocaleTimeString() : "N/A";
|
|
1635
1746
|
})());
|
|
1636
|
-
insert(_el$
|
|
1747
|
+
insert(_el$53, (() => {
|
|
1637
1748
|
var _c$1 = memo(() => !!activeMatchLoaderData());
|
|
1638
1749
|
return () => _c$1() ? [(() => {
|
|
1639
|
-
var _el$
|
|
1640
|
-
effect(() => className(_el$
|
|
1641
|
-
return _el$
|
|
1750
|
+
var _el$71 = _tmpl$13();
|
|
1751
|
+
effect(() => className(_el$71, styles().detailsHeader));
|
|
1752
|
+
return _el$71;
|
|
1642
1753
|
})(), (() => {
|
|
1643
|
-
var _el$
|
|
1644
|
-
insert(_el$
|
|
1754
|
+
var _el$72 = _tmpl$6();
|
|
1755
|
+
insert(_el$72, createComponent(Explorer, {
|
|
1645
1756
|
label: "loaderData",
|
|
1646
1757
|
value: activeMatchLoaderData,
|
|
1647
1758
|
defaultExpanded: {}
|
|
1648
1759
|
}));
|
|
1649
|
-
effect(() => className(_el$
|
|
1650
|
-
return _el$
|
|
1760
|
+
effect(() => className(_el$72, styles().detailsContent));
|
|
1761
|
+
return _el$72;
|
|
1651
1762
|
})()] : null;
|
|
1652
|
-
})(), _el$
|
|
1653
|
-
insert(_el$
|
|
1763
|
+
})(), _el$69);
|
|
1764
|
+
insert(_el$70, createComponent(Explorer, {
|
|
1654
1765
|
label: "Match",
|
|
1655
1766
|
value: activeMatchValue,
|
|
1656
1767
|
defaultExpanded: {}
|
|
1657
1768
|
}));
|
|
1658
1769
|
effect((_p$) => {
|
|
1659
|
-
var _v$
|
|
1660
|
-
_v$
|
|
1661
|
-
_v$
|
|
1662
|
-
_v$
|
|
1663
|
-
_v$
|
|
1664
|
-
_v$
|
|
1665
|
-
_v$
|
|
1666
|
-
_v$
|
|
1667
|
-
_v$
|
|
1668
|
-
_v$
|
|
1669
|
-
_v$
|
|
1670
|
-
_v$
|
|
1671
|
-
_v$
|
|
1770
|
+
var _v$37 = styles().thirdContainer, _v$38 = styles().detailsHeader, _v$39 = styles().matchDetails, _v$40 = styles().matchStatus(activeMatch()?.status, activeMatch()?.isFetching), _v$41 = styles().matchDetailsInfoLabel, _v$42 = styles().matchDetailsInfo, _v$43 = styles().matchDetailsInfoLabel, _v$44 = styles().matchDetailsInfo, _v$45 = styles().matchDetailsInfoLabel, _v$46 = styles().matchDetailsInfo, _v$47 = styles().detailsHeader, _v$48 = styles().detailsContent;
|
|
1771
|
+
_v$37 !== _p$.e && className(_el$53, _p$.e = _v$37);
|
|
1772
|
+
_v$38 !== _p$.t && className(_el$54, _p$.t = _v$38);
|
|
1773
|
+
_v$39 !== _p$.a && className(_el$56, _p$.a = _v$39);
|
|
1774
|
+
_v$40 !== _p$.o && className(_el$57, _p$.o = _v$40);
|
|
1775
|
+
_v$41 !== _p$.i && className(_el$59, _p$.i = _v$41);
|
|
1776
|
+
_v$42 !== _p$.n && className(_el$61, _p$.n = _v$42);
|
|
1777
|
+
_v$43 !== _p$.s && className(_el$63, _p$.s = _v$43);
|
|
1778
|
+
_v$44 !== _p$.h && className(_el$65, _p$.h = _v$44);
|
|
1779
|
+
_v$45 !== _p$.r && className(_el$66, _p$.r = _v$45);
|
|
1780
|
+
_v$46 !== _p$.d && className(_el$68, _p$.d = _v$46);
|
|
1781
|
+
_v$47 !== _p$.l && className(_el$69, _p$.l = _v$47);
|
|
1782
|
+
_v$48 !== _p$.u && className(_el$70, _p$.u = _v$48);
|
|
1672
1783
|
return _p$;
|
|
1673
1784
|
}, {
|
|
1674
1785
|
e: void 0,
|
|
@@ -1684,26 +1795,26 @@ const BaseTanStackRouterDevtoolsPanel = function BaseTanStackRouterDevtoolsPanel
|
|
|
1684
1795
|
l: void 0,
|
|
1685
1796
|
u: void 0
|
|
1686
1797
|
});
|
|
1687
|
-
return _el$
|
|
1798
|
+
return _el$53;
|
|
1688
1799
|
})() : null;
|
|
1689
1800
|
})(), null);
|
|
1690
1801
|
insert(_el$11, (() => {
|
|
1691
1802
|
var _c$7 = memo(() => !!hasSearch());
|
|
1692
1803
|
return () => _c$7() ? (() => {
|
|
1693
|
-
var _el$
|
|
1694
|
-
_el$
|
|
1695
|
-
var _el$
|
|
1696
|
-
insert(_el$
|
|
1697
|
-
var _el$
|
|
1698
|
-
insert(_el$
|
|
1804
|
+
var _el$73 = _tmpl$14(), _el$74 = _el$73.firstChild;
|
|
1805
|
+
_el$74.firstChild;
|
|
1806
|
+
var _el$76 = _el$74.nextSibling;
|
|
1807
|
+
insert(_el$74, typeof navigator !== "undefined" ? (() => {
|
|
1808
|
+
var _el$77 = _tmpl$15();
|
|
1809
|
+
insert(_el$77, createComponent(CopyButton, {
|
|
1699
1810
|
getValue: () => {
|
|
1700
1811
|
const search = routerState().location.search;
|
|
1701
1812
|
return JSON.stringify(search);
|
|
1702
1813
|
}
|
|
1703
1814
|
}));
|
|
1704
|
-
return _el$
|
|
1815
|
+
return _el$77;
|
|
1705
1816
|
})() : null, null);
|
|
1706
|
-
insert(_el$
|
|
1817
|
+
insert(_el$76, createComponent(Explorer, {
|
|
1707
1818
|
value: locationSearchValue,
|
|
1708
1819
|
get defaultExpanded() {
|
|
1709
1820
|
return Object.keys(routerState().location.search).reduce((obj, next) => {
|
|
@@ -1713,21 +1824,21 @@ const BaseTanStackRouterDevtoolsPanel = function BaseTanStackRouterDevtoolsPanel
|
|
|
1713
1824
|
}
|
|
1714
1825
|
}));
|
|
1715
1826
|
effect((_p$) => {
|
|
1716
|
-
var _v$
|
|
1717
|
-
_v$
|
|
1718
|
-
_v$
|
|
1719
|
-
_v$
|
|
1827
|
+
var _v$49 = styles().fourthContainer, _v$50 = styles().detailsHeader, _v$51 = styles().detailsContent;
|
|
1828
|
+
_v$49 !== _p$.e && className(_el$73, _p$.e = _v$49);
|
|
1829
|
+
_v$50 !== _p$.t && className(_el$74, _p$.t = _v$50);
|
|
1830
|
+
_v$51 !== _p$.a && className(_el$76, _p$.a = _v$51);
|
|
1720
1831
|
return _p$;
|
|
1721
1832
|
}, {
|
|
1722
1833
|
e: void 0,
|
|
1723
1834
|
t: void 0,
|
|
1724
1835
|
a: void 0
|
|
1725
1836
|
});
|
|
1726
|
-
return _el$
|
|
1837
|
+
return _el$73;
|
|
1727
1838
|
})() : null;
|
|
1728
1839
|
})(), null);
|
|
1729
1840
|
effect((_p$) => {
|
|
1730
|
-
var _v$6 = styles().panelCloseBtn, _v$7 = styles().panelCloseBtnIcon, _v$8 = styles().firstContainer, _v$9 = styles().row, _v$0 = styles().routerExplorerContainer, _v$1 = styles().routerExplorer, _v$10 = styles().secondContainer, _v$11 = styles().matchesContainer, _v$12 = styles().detailsHeader, _v$13 = styles().detailsContent, _v$14 = styles().detailsHeader, _v$15 = styles().routeMatchesToggle, _v$16 =
|
|
1841
|
+
var _v$6 = styles().panelCloseBtn, _v$7 = styles().panelCloseBtnIcon, _v$8 = styles().firstContainer, _v$9 = styles().row, _v$0 = styles().routerExplorerContainer, _v$1 = styles().routerExplorer, _v$10 = styles().secondContainer, _v$11 = styles().matchesContainer, _v$12 = styles().detailsHeader, _v$13 = styles().detailsContent, _v$14 = styles().detailsHeader, _v$15 = styles().routeMatchesToggle, _v$16 = currentTab() === "routes", _v$17 = clsx(styles().routeMatchesToggleBtn(currentTab() === "routes", true)), _v$18 = currentTab() === "matches", _v$19 = clsx(styles().routeMatchesToggleBtn(currentTab() === "matches", true)), _v$20 = currentTab() === "history", _v$21 = clsx(styles().routeMatchesToggleBtn(currentTab() === "history", false)), _v$22 = styles().detailsHeaderInfo, _v$23 = clsx(styles().routesContainer);
|
|
1731
1842
|
_v$6 !== _p$.e && className(_el$12, _p$.e = _v$6);
|
|
1732
1843
|
_v$7 !== _p$.t && setAttribute(_el$13, "class", _p$.t = _v$7);
|
|
1733
1844
|
_v$8 !== _p$.a && className(_el$14, _p$.a = _v$8);
|
|
@@ -1744,8 +1855,10 @@ const BaseTanStackRouterDevtoolsPanel = function BaseTanStackRouterDevtoolsPanel
|
|
|
1744
1855
|
_v$17 !== _p$.w && className(_el$26, _p$.w = _v$17);
|
|
1745
1856
|
_v$18 !== _p$.m && (_el$27.disabled = _p$.m = _v$18);
|
|
1746
1857
|
_v$19 !== _p$.f && className(_el$27, _p$.f = _v$19);
|
|
1747
|
-
_v$20 !== _p$.y &&
|
|
1748
|
-
_v$21 !== _p$.g && className(_el$
|
|
1858
|
+
_v$20 !== _p$.y && (_el$28.disabled = _p$.y = _v$20);
|
|
1859
|
+
_v$21 !== _p$.g && className(_el$28, _p$.g = _v$21);
|
|
1860
|
+
_v$22 !== _p$.p && className(_el$29, _p$.p = _v$22);
|
|
1861
|
+
_v$23 !== _p$.b && className(_el$30, _p$.b = _v$23);
|
|
1749
1862
|
return _p$;
|
|
1750
1863
|
}, {
|
|
1751
1864
|
e: void 0,
|
|
@@ -1765,7 +1878,9 @@ const BaseTanStackRouterDevtoolsPanel = function BaseTanStackRouterDevtoolsPanel
|
|
|
1765
1878
|
m: void 0,
|
|
1766
1879
|
f: void 0,
|
|
1767
1880
|
y: void 0,
|
|
1768
|
-
g: void 0
|
|
1881
|
+
g: void 0,
|
|
1882
|
+
p: void 0,
|
|
1883
|
+
b: void 0
|
|
1769
1884
|
});
|
|
1770
1885
|
return _el$11;
|
|
1771
1886
|
})();
|
|
@@ -1794,11 +1909,11 @@ function CopyButton({
|
|
|
1794
1909
|
if (timeoutId) clearTimeout(timeoutId);
|
|
1795
1910
|
});
|
|
1796
1911
|
return (() => {
|
|
1797
|
-
var _el$
|
|
1798
|
-
_el$
|
|
1799
|
-
insert(_el$
|
|
1800
|
-
effect(() => setAttribute(_el$
|
|
1801
|
-
return _el$
|
|
1912
|
+
var _el$78 = _tmpl$16();
|
|
1913
|
+
_el$78.$$click = handleCopy;
|
|
1914
|
+
insert(_el$78, () => copied() ? "✅" : "📋");
|
|
1915
|
+
effect(() => setAttribute(_el$78, "title", copied() ? "Copied!" : "Copy"));
|
|
1916
|
+
return _el$78;
|
|
1802
1917
|
})();
|
|
1803
1918
|
}
|
|
1804
1919
|
delegateEvents(["click", "mousedown"]);
|
|
@@ -1814,4 +1929,4 @@ export {
|
|
|
1814
1929
|
BaseTanStackRouterDevtoolsPanel$1 as c,
|
|
1815
1930
|
useLocalStorage as u
|
|
1816
1931
|
};
|
|
1817
|
-
//# sourceMappingURL=BaseTanStackRouterDevtoolsPanel-
|
|
1932
|
+
//# sourceMappingURL=BaseTanStackRouterDevtoolsPanel-Cbvcs84k.js.map
|