@tanstack/router-devtools-core 1.167.1 → 1.167.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/dist/{BaseTanStackRouterDevtoolsPanel-qCkSGZav.js → BaseTanStackRouterDevtoolsPanel-BYamTwOT.js} +263 -57
- package/dist/BaseTanStackRouterDevtoolsPanel-BYamTwOT.js.map +1 -0
- package/dist/{BaseTanStackRouterDevtoolsPanel-DSj2U3K0.cjs → BaseTanStackRouterDevtoolsPanel-CKR5l6C5.cjs} +263 -57
- package/dist/BaseTanStackRouterDevtoolsPanel-CKR5l6C5.cjs.map +1 -0
- package/dist/{FloatingTanStackRouterDevtools-Dz-7tBRe.js → FloatingTanStackRouterDevtools-5lmIMjR6.js} +2 -2
- package/dist/{FloatingTanStackRouterDevtools-Dz-7tBRe.js.map → FloatingTanStackRouterDevtools-5lmIMjR6.js.map} +1 -1
- package/dist/{FloatingTanStackRouterDevtools-BGIBDKFY.cjs → FloatingTanStackRouterDevtools-eF_9_NhU.cjs} +2 -2
- package/dist/{FloatingTanStackRouterDevtools-BGIBDKFY.cjs.map → FloatingTanStackRouterDevtools-eF_9_NhU.cjs.map} +1 -1
- package/dist/cjs/Explorer.d.cts +1 -1
- package/dist/cjs/index.cjs +2 -2
- package/dist/cjs/utils.d.cts +24 -0
- package/dist/esm/Explorer.d.ts +1 -1
- package/dist/esm/index.js +2 -2
- package/dist/esm/utils.d.ts +24 -0
- package/package.json +4 -4
- package/src/BaseTanStackRouterDevtoolsPanel.tsx +6 -6
- package/src/Explorer.tsx +155 -5
- package/src/utils.tsx +129 -1
- package/dist/BaseTanStackRouterDevtoolsPanel-DSj2U3K0.cjs.map +0 -1
- package/dist/BaseTanStackRouterDevtoolsPanel-qCkSGZav.js.map +0 -1
|
@@ -917,16 +917,90 @@ function useIsMounted() {
|
|
|
917
917
|
});
|
|
918
918
|
return isMounted;
|
|
919
919
|
}
|
|
920
|
+
var SERVER_COMPONENT_STREAM = Symbol.for("tanstack.rsc.stream");
|
|
921
|
+
var RENDERABLE_RSC = Symbol.for("tanstack.rsc.renderable");
|
|
922
|
+
var RSC_SLOT_USAGES = Symbol.for("tanstack.rsc.slotUsages");
|
|
923
|
+
function trimTrailingUndefined(arr) {
|
|
924
|
+
let end = arr.length;
|
|
925
|
+
while (end > 0 && arr[end - 1] === void 0) end--;
|
|
926
|
+
if (end === 0) return arr;
|
|
927
|
+
return end === arr.length ? arr : arr.slice(0, end);
|
|
928
|
+
}
|
|
929
|
+
/**
|
|
930
|
+
* Checks if a value is any kind of server component
|
|
931
|
+
*/
|
|
932
|
+
var isServerComponent = (value) => {
|
|
933
|
+
return (typeof value === "object" || typeof value === "function") && value !== null && SERVER_COMPONENT_STREAM in value;
|
|
934
|
+
};
|
|
935
|
+
/**
|
|
936
|
+
* Gets the type of server component.
|
|
937
|
+
* - RENDERABLE_RSC === true → renderable (from renderServerComponent)
|
|
938
|
+
* - RENDERABLE_RSC === false or not present → composite (from createCompositeComponent)
|
|
939
|
+
*/
|
|
940
|
+
var getServerComponentType = (value) => {
|
|
941
|
+
if (!isServerComponent(value)) return null;
|
|
942
|
+
const v = value;
|
|
943
|
+
if (RENDERABLE_RSC in v && v[RENDERABLE_RSC] === true) return "renderableValue";
|
|
944
|
+
return "compositeSource";
|
|
945
|
+
};
|
|
946
|
+
/**
|
|
947
|
+
* Gets the slot names from a composite server component (dev only)
|
|
948
|
+
*/
|
|
949
|
+
var getServerComponentSlots = (value) => {
|
|
950
|
+
if (!isServerComponent(value)) return [];
|
|
951
|
+
const v = value;
|
|
952
|
+
const out = [];
|
|
953
|
+
if (RSC_SLOT_USAGES in v) {
|
|
954
|
+
const usages = v[RSC_SLOT_USAGES];
|
|
955
|
+
if (Array.isArray(usages)) for (const evt of usages) {
|
|
956
|
+
const name = evt?.slot;
|
|
957
|
+
if (typeof name === "string" && !out.includes(name)) out.push(name);
|
|
958
|
+
}
|
|
959
|
+
}
|
|
960
|
+
return out;
|
|
961
|
+
};
|
|
962
|
+
var getServerComponentSlotUsages = (value) => {
|
|
963
|
+
if (!isServerComponent(value)) return [];
|
|
964
|
+
const v = value;
|
|
965
|
+
if (!(RSC_SLOT_USAGES in v)) return [];
|
|
966
|
+
const usages = v[RSC_SLOT_USAGES];
|
|
967
|
+
if (!Array.isArray(usages)) return [];
|
|
968
|
+
return usages.filter((d) => {
|
|
969
|
+
return d && typeof d === "object" && typeof d.slot === "string" && (d.args === void 0 || Array.isArray(d.args));
|
|
970
|
+
});
|
|
971
|
+
};
|
|
972
|
+
var getServerComponentSlotUsageSummary = (value) => {
|
|
973
|
+
const usages = getServerComponentSlotUsages(value);
|
|
974
|
+
const out = {};
|
|
975
|
+
for (const evt of usages) {
|
|
976
|
+
const args = trimTrailingUndefined(evt.args ?? []);
|
|
977
|
+
const prev = out[evt.slot] ?? (out[evt.slot] = {
|
|
978
|
+
count: 0,
|
|
979
|
+
invocations: []
|
|
980
|
+
});
|
|
981
|
+
prev.count++;
|
|
982
|
+
prev.invocations.push(args);
|
|
983
|
+
}
|
|
984
|
+
return out;
|
|
985
|
+
};
|
|
920
986
|
/**
|
|
921
987
|
* Displays a string regardless the type of the data
|
|
922
988
|
* @param {unknown} value Value to be stringified
|
|
923
989
|
*/
|
|
924
990
|
var displayValue = (value) => {
|
|
991
|
+
if (value === "React element") return "React element";
|
|
992
|
+
const componentType = getServerComponentType(value);
|
|
993
|
+
if (componentType === "compositeSource") {
|
|
994
|
+
const slots = getServerComponentSlots(value);
|
|
995
|
+
if (slots.length > 0) return `RSC composite source (${slots.length} ${slots.length === 1 ? "slot" : "slots"})`;
|
|
996
|
+
return "RSC composite source";
|
|
997
|
+
}
|
|
998
|
+
if (componentType === "renderableValue") return "RSC renderable value";
|
|
925
999
|
const name = Object.getOwnPropertyNames(Object(value));
|
|
926
1000
|
const newValue = typeof value === "bigint" ? `${value.toString()}n` : value;
|
|
927
1001
|
try {
|
|
928
1002
|
return JSON.stringify(newValue, name);
|
|
929
|
-
} catch
|
|
1003
|
+
} catch {
|
|
930
1004
|
return `unable to stringify`;
|
|
931
1005
|
}
|
|
932
1006
|
};
|
|
@@ -947,8 +1021,8 @@ function multiSortBy(arr, accessors = [(d) => d]) {
|
|
|
947
1021
|
}
|
|
948
1022
|
//#endregion
|
|
949
1023
|
//#region src/Explorer.tsx
|
|
950
|
-
var _tmpl$$3 = /* @__PURE__ */ template(`<span><svg xmlns=http://www.w3.org/2000/svg width=12 height=12 fill=none viewBox="0 0 24 24"><path stroke=currentColor stroke-linecap=round stroke-linejoin=round stroke-width=2 d="M9 18l6-6-6-6">`), _tmpl$2$1 = /* @__PURE__ */ template(`<div>`), _tmpl$3$1 = /* @__PURE__ */ template(`<button><span
|
|
951
|
-
var Expander = ({ expanded, style = {} }) => {
|
|
1024
|
+
var _tmpl$$3 = /* @__PURE__ */ template(`<span><svg xmlns=http://www.w3.org/2000/svg width=12 height=12 fill=none viewBox="0 0 24 24"><path stroke=currentColor stroke-linecap=round stroke-linejoin=round stroke-width=2 d="M9 18l6-6-6-6">`), _tmpl$2$1 = /* @__PURE__ */ template(`<div>`), _tmpl$3$1 = /* @__PURE__ */ template(`<button><span>:</span><span>`), _tmpl$4$1 = /* @__PURE__ */ template(`<div><span>slots</span><div>`), _tmpl$5$1 = /* @__PURE__ */ template(`<span>:`), _tmpl$6$1 = /* @__PURE__ */ template(`<span>`), _tmpl$7$1 = /* @__PURE__ */ template(`<button><span> `), _tmpl$8$1 = /* @__PURE__ */ template(`<div><div><button> [<!> ... <!>]`), _tmpl$9$1 = /* @__PURE__ */ template(`<button><span></span> 🔄 `);
|
|
1025
|
+
var Expander = ({ expanded, style: _style = {} }) => {
|
|
952
1026
|
const styles = useStyles();
|
|
953
1027
|
return (() => {
|
|
954
1028
|
var _el$ = _tmpl$$3(), _el$2 = _el$.firstChild;
|
|
@@ -986,6 +1060,11 @@ function chunkArray(array, size) {
|
|
|
986
1060
|
function isIterable(x) {
|
|
987
1061
|
return Symbol.iterator in x;
|
|
988
1062
|
}
|
|
1063
|
+
function isPlainObject(value) {
|
|
1064
|
+
if (!value || typeof value !== "object") return false;
|
|
1065
|
+
const proto = Object.getPrototypeOf(value);
|
|
1066
|
+
return proto === Object.prototype || proto === null;
|
|
1067
|
+
}
|
|
989
1068
|
function Explorer({ value, defaultExpanded, pageSize = 100, filterSubEntries, ...rest }) {
|
|
990
1069
|
const [expanded, setExpanded] = createSignal(Boolean(defaultExpanded));
|
|
991
1070
|
const toggleExpanded = () => setExpanded((old) => !old);
|
|
@@ -1000,7 +1079,16 @@ function Explorer({ value, defaultExpanded, pageSize = 100, filterSubEntries, ..
|
|
|
1000
1079
|
defaultExpanded: subDefaultExpanded
|
|
1001
1080
|
};
|
|
1002
1081
|
};
|
|
1003
|
-
if (Array.isArray(value()))
|
|
1082
|
+
if (Array.isArray(value()) && value().length === 2 && value()[0] === "React element" && isPlainObject(value()[1])) {
|
|
1083
|
+
const v = value();
|
|
1084
|
+
entries = [makeProperty({
|
|
1085
|
+
label: "0",
|
|
1086
|
+
value: v[0]
|
|
1087
|
+
}), ...Object.entries(v[1]).map(([key, val]) => makeProperty({
|
|
1088
|
+
label: key,
|
|
1089
|
+
value: val
|
|
1090
|
+
}))];
|
|
1091
|
+
} else if (Array.isArray(value())) entries = value().map((d, i) => makeProperty({
|
|
1004
1092
|
label: i.toString(),
|
|
1005
1093
|
value: d
|
|
1006
1094
|
}));
|
|
@@ -1025,94 +1113,151 @@ function Explorer({ value, defaultExpanded, pageSize = 100, filterSubEntries, ..
|
|
|
1025
1113
|
value,
|
|
1026
1114
|
filterSubEntries
|
|
1027
1115
|
}, rest, entry));
|
|
1116
|
+
const serverComponentType = createMemo(() => getServerComponentType(value()));
|
|
1117
|
+
const serverComponentSlots = createMemo(() => getServerComponentSlots(value()));
|
|
1118
|
+
const serverComponentSlotUsageSummary = createMemo(() => getServerComponentSlotUsageSummary(value()));
|
|
1119
|
+
const isCompositeWithSlots = createMemo(() => serverComponentType() === "compositeSource" && serverComponentSlots().length > 0);
|
|
1028
1120
|
return (() => {
|
|
1029
1121
|
var _el$3 = _tmpl$2$1();
|
|
1030
1122
|
insert(_el$3, (() => {
|
|
1031
|
-
var _c$ = memo(() =>
|
|
1032
|
-
return () => _c$() ? [(() => {
|
|
1033
|
-
var _el$4 = _tmpl$3$1(), _el$5 = _el$4.firstChild, _el$6 = _el$5.firstChild;
|
|
1123
|
+
var _c$ = memo(() => serverComponentType() !== null);
|
|
1124
|
+
return () => _c$() ? memo(() => !!isCompositeWithSlots())() ? [(() => {
|
|
1125
|
+
var _el$4 = _tmpl$3$1(), _el$5 = _el$4.firstChild, _el$6 = _el$5.firstChild, _el$7 = _el$5.nextSibling;
|
|
1034
1126
|
_el$4.$$click = () => toggleExpanded();
|
|
1035
1127
|
insert(_el$4, createComponent(Expander, { get expanded() {
|
|
1036
1128
|
return expanded() ?? false;
|
|
1037
1129
|
} }), _el$5);
|
|
1038
|
-
insert(_el$
|
|
1039
|
-
insert(_el$
|
|
1040
|
-
insert(_el$5, () => subEntries().length, _el$6);
|
|
1041
|
-
insert(_el$5, () => subEntries().length > 1 ? `items` : `item`, null);
|
|
1130
|
+
insert(_el$5, () => rest.label, _el$6);
|
|
1131
|
+
insert(_el$7, () => displayValue(value()));
|
|
1042
1132
|
createRenderEffect((_p$) => {
|
|
1043
|
-
var _v$3 = styles().expandButton, _v$4 = styles().
|
|
1133
|
+
var _v$3 = styles().expandButton, _v$4 = styles().compositeComponent;
|
|
1044
1134
|
_v$3 !== _p$.e && className(_el$4, _p$.e = _v$3);
|
|
1045
|
-
_v$4 !== _p$.t && className(_el$
|
|
1135
|
+
_v$4 !== _p$.t && className(_el$7, _p$.t = _v$4);
|
|
1046
1136
|
return _p$;
|
|
1047
1137
|
}, {
|
|
1048
1138
|
e: void 0,
|
|
1049
1139
|
t: void 0
|
|
1050
1140
|
});
|
|
1051
1141
|
return _el$4;
|
|
1142
|
+
})(), memo(() => memo(() => !!(expanded() ?? false))() ? (() => {
|
|
1143
|
+
var _el$8 = _tmpl$4$1(), _el$9 = _el$8.firstChild, _el$0 = _el$9.nextSibling;
|
|
1144
|
+
insert(_el$0, () => serverComponentSlots().map((name) => {
|
|
1145
|
+
const usage = serverComponentSlotUsageSummary()[name];
|
|
1146
|
+
if (!usage) return null;
|
|
1147
|
+
return createComponent(Explorer, {
|
|
1148
|
+
label: `${name}:`,
|
|
1149
|
+
value: () => usage.invocations.map((args) => args.length === 1 ? args[0] : args)
|
|
1150
|
+
});
|
|
1151
|
+
}));
|
|
1152
|
+
createRenderEffect((_p$) => {
|
|
1153
|
+
var _v$5 = styles().rscMetaRow, _v$6 = styles().rscMetaLabel, _v$7 = styles().subEntries;
|
|
1154
|
+
_v$5 !== _p$.e && className(_el$8, _p$.e = _v$5);
|
|
1155
|
+
_v$6 !== _p$.t && className(_el$9, _p$.t = _v$6);
|
|
1156
|
+
_v$7 !== _p$.a && className(_el$0, _p$.a = _v$7);
|
|
1157
|
+
return _p$;
|
|
1158
|
+
}, {
|
|
1159
|
+
e: void 0,
|
|
1160
|
+
t: void 0,
|
|
1161
|
+
a: void 0
|
|
1162
|
+
});
|
|
1163
|
+
return _el$8;
|
|
1164
|
+
})() : null)] : [
|
|
1165
|
+
(() => {
|
|
1166
|
+
var _el$1 = _tmpl$5$1(), _el$10 = _el$1.firstChild;
|
|
1167
|
+
insert(_el$1, () => rest.label, _el$10);
|
|
1168
|
+
return _el$1;
|
|
1169
|
+
})(),
|
|
1170
|
+
" ",
|
|
1171
|
+
(() => {
|
|
1172
|
+
var _el$11 = _tmpl$6$1();
|
|
1173
|
+
insert(_el$11, () => displayValue(value()));
|
|
1174
|
+
createRenderEffect(() => className(_el$11, serverComponentType() === "compositeSource" ? styles().compositeComponent : styles().renderableComponent));
|
|
1175
|
+
return _el$11;
|
|
1176
|
+
})()
|
|
1177
|
+
] : memo(() => !!subEntryPages().length)() ? [(() => {
|
|
1178
|
+
var _el$12 = _tmpl$7$1(), _el$13 = _el$12.firstChild, _el$14 = _el$13.firstChild;
|
|
1179
|
+
_el$12.$$click = () => toggleExpanded();
|
|
1180
|
+
insert(_el$12, createComponent(Expander, { get expanded() {
|
|
1181
|
+
return expanded() ?? false;
|
|
1182
|
+
} }), _el$13);
|
|
1183
|
+
insert(_el$12, () => rest.label, _el$13);
|
|
1184
|
+
insert(_el$13, () => String(type).toLowerCase() === "iterable" ? "(Iterable) " : "", _el$14);
|
|
1185
|
+
insert(_el$13, () => subEntries().length, _el$14);
|
|
1186
|
+
insert(_el$13, () => subEntries().length > 1 ? `items` : `item`, null);
|
|
1187
|
+
createRenderEffect((_p$) => {
|
|
1188
|
+
var _v$8 = styles().expandButton, _v$9 = styles().info;
|
|
1189
|
+
_v$8 !== _p$.e && className(_el$12, _p$.e = _v$8);
|
|
1190
|
+
_v$9 !== _p$.t && className(_el$13, _p$.t = _v$9);
|
|
1191
|
+
return _p$;
|
|
1192
|
+
}, {
|
|
1193
|
+
e: void 0,
|
|
1194
|
+
t: void 0
|
|
1195
|
+
});
|
|
1196
|
+
return _el$12;
|
|
1052
1197
|
})(), memo(() => memo(() => !!(expanded() ?? false))() ? memo(() => subEntryPages().length === 1)() ? (() => {
|
|
1053
|
-
var _el$
|
|
1054
|
-
insert(_el$
|
|
1055
|
-
createRenderEffect(() => className(_el$
|
|
1056
|
-
return _el$
|
|
1198
|
+
var _el$15 = _tmpl$2$1();
|
|
1199
|
+
insert(_el$15, () => subEntries().map((entry, index) => handleEntry(entry)));
|
|
1200
|
+
createRenderEffect(() => className(_el$15, styles().subEntries));
|
|
1201
|
+
return _el$15;
|
|
1057
1202
|
})() : (() => {
|
|
1058
|
-
var _el$
|
|
1059
|
-
insert(_el$
|
|
1203
|
+
var _el$16 = _tmpl$2$1();
|
|
1204
|
+
insert(_el$16, () => subEntryPages().map((entries, index) => {
|
|
1060
1205
|
return (() => {
|
|
1061
|
-
var _el$
|
|
1062
|
-
_el$
|
|
1063
|
-
_el$
|
|
1064
|
-
insert(_el$
|
|
1206
|
+
var _el$17 = _tmpl$8$1(), _el$18 = _el$17.firstChild, _el$19 = _el$18.firstChild, _el$20 = _el$19.firstChild, _el$25 = _el$20.nextSibling, _el$26 = _el$25.nextSibling.nextSibling;
|
|
1207
|
+
_el$26.nextSibling;
|
|
1208
|
+
_el$19.$$click = () => setExpandedPages((old) => old.includes(index) ? old.filter((d) => d !== index) : [...old, index]);
|
|
1209
|
+
insert(_el$19, createComponent(Expander, { get expanded() {
|
|
1065
1210
|
return expandedPages().includes(index);
|
|
1066
|
-
} }), _el$
|
|
1067
|
-
insert(_el$
|
|
1068
|
-
insert(_el$
|
|
1069
|
-
insert(_el$
|
|
1211
|
+
} }), _el$20);
|
|
1212
|
+
insert(_el$19, index * pageSize, _el$25);
|
|
1213
|
+
insert(_el$19, index * pageSize + pageSize - 1, _el$26);
|
|
1214
|
+
insert(_el$18, (() => {
|
|
1070
1215
|
var _c$2 = memo(() => !!expandedPages().includes(index));
|
|
1071
1216
|
return () => _c$2() ? (() => {
|
|
1072
|
-
var _el$
|
|
1073
|
-
insert(_el$
|
|
1074
|
-
createRenderEffect(() => className(_el$
|
|
1075
|
-
return _el$
|
|
1217
|
+
var _el$27 = _tmpl$2$1();
|
|
1218
|
+
insert(_el$27, () => entries.map((entry) => handleEntry(entry)));
|
|
1219
|
+
createRenderEffect(() => className(_el$27, styles().subEntries));
|
|
1220
|
+
return _el$27;
|
|
1076
1221
|
})() : null;
|
|
1077
1222
|
})(), null);
|
|
1078
1223
|
createRenderEffect((_p$) => {
|
|
1079
|
-
var _v$
|
|
1080
|
-
_v$
|
|
1081
|
-
_v$
|
|
1224
|
+
var _v$0 = styles().entry, _v$1 = clsx(styles().labelButton, "labelButton");
|
|
1225
|
+
_v$0 !== _p$.e && className(_el$18, _p$.e = _v$0);
|
|
1226
|
+
_v$1 !== _p$.t && className(_el$19, _p$.t = _v$1);
|
|
1082
1227
|
return _p$;
|
|
1083
1228
|
}, {
|
|
1084
1229
|
e: void 0,
|
|
1085
1230
|
t: void 0
|
|
1086
1231
|
});
|
|
1087
|
-
return _el$
|
|
1232
|
+
return _el$17;
|
|
1088
1233
|
})();
|
|
1089
1234
|
}));
|
|
1090
|
-
createRenderEffect(() => className(_el$
|
|
1091
|
-
return _el$
|
|
1235
|
+
createRenderEffect(() => className(_el$16, styles().subEntries));
|
|
1236
|
+
return _el$16;
|
|
1092
1237
|
})() : null)] : memo(() => type() === "function")() ? createComponent(Explorer, {
|
|
1093
1238
|
get label() {
|
|
1094
1239
|
return (() => {
|
|
1095
|
-
var _el$
|
|
1096
|
-
_el$
|
|
1097
|
-
insert(_el$
|
|
1098
|
-
createRenderEffect(() => className(_el$
|
|
1099
|
-
return _el$
|
|
1240
|
+
var _el$28 = _tmpl$9$1(), _el$29 = _el$28.firstChild;
|
|
1241
|
+
_el$28.$$click = refreshValueSnapshot;
|
|
1242
|
+
insert(_el$29, () => rest.label);
|
|
1243
|
+
createRenderEffect(() => className(_el$28, styles().refreshValueBtn));
|
|
1244
|
+
return _el$28;
|
|
1100
1245
|
})();
|
|
1101
1246
|
},
|
|
1102
1247
|
value: valueSnapshot,
|
|
1103
1248
|
defaultExpanded: {}
|
|
1104
1249
|
}) : [
|
|
1105
1250
|
(() => {
|
|
1106
|
-
var _el$
|
|
1107
|
-
insert(_el$
|
|
1108
|
-
return _el$
|
|
1251
|
+
var _el$30 = _tmpl$5$1(), _el$31 = _el$30.firstChild;
|
|
1252
|
+
insert(_el$30, () => rest.label, _el$31);
|
|
1253
|
+
return _el$30;
|
|
1109
1254
|
})(),
|
|
1110
1255
|
" ",
|
|
1111
1256
|
(() => {
|
|
1112
|
-
var _el$
|
|
1113
|
-
insert(_el$
|
|
1114
|
-
createRenderEffect(() => className(_el$
|
|
1115
|
-
return _el$
|
|
1257
|
+
var _el$32 = _tmpl$6$1();
|
|
1258
|
+
insert(_el$32, () => displayValue(value()));
|
|
1259
|
+
createRenderEffect(() => className(_el$32, styles().value));
|
|
1260
|
+
return _el$32;
|
|
1116
1261
|
})()
|
|
1117
1262
|
];
|
|
1118
1263
|
})());
|
|
@@ -1121,7 +1266,7 @@ function Explorer({ value, defaultExpanded, pageSize = 100, filterSubEntries, ..
|
|
|
1121
1266
|
})();
|
|
1122
1267
|
}
|
|
1123
1268
|
var stylesFactory = (shadowDOMTarget) => {
|
|
1124
|
-
const { colors, font, size,
|
|
1269
|
+
const { colors, font, size, border } = tokens;
|
|
1125
1270
|
const { fontFamily, lineHeight, size: fontSize } = font;
|
|
1126
1271
|
const css = shadowDOMTarget ? goober.css.bind({ target: shadowDOMTarget }) : goober.css;
|
|
1127
1272
|
return {
|
|
@@ -1174,6 +1319,67 @@ var stylesFactory = (shadowDOMTarget) => {
|
|
|
1174
1319
|
`,
|
|
1175
1320
|
value: css`
|
|
1176
1321
|
color: ${colors.purple[400]};
|
|
1322
|
+
`,
|
|
1323
|
+
compositeComponent: css`
|
|
1324
|
+
display: inline-flex;
|
|
1325
|
+
align-items: center;
|
|
1326
|
+
padding: 1px ${size[1]};
|
|
1327
|
+
border-radius: ${border.radius.full};
|
|
1328
|
+
border: 1px solid ${colors.darkGray[500]};
|
|
1329
|
+
background: ${colors.darkGray[700]};
|
|
1330
|
+
color: ${colors.cyan[300]};
|
|
1331
|
+
font-style: normal;
|
|
1332
|
+
font-weight: ${font.weight.medium};
|
|
1333
|
+
`,
|
|
1334
|
+
renderableComponent: css`
|
|
1335
|
+
display: inline-flex;
|
|
1336
|
+
align-items: center;
|
|
1337
|
+
padding: 1px ${size[1]};
|
|
1338
|
+
border-radius: ${border.radius.full};
|
|
1339
|
+
border: 1px solid ${colors.darkGray[500]};
|
|
1340
|
+
background: ${colors.darkGray[700]};
|
|
1341
|
+
color: ${colors.teal[300]};
|
|
1342
|
+
font-style: normal;
|
|
1343
|
+
font-weight: ${font.weight.medium};
|
|
1344
|
+
`,
|
|
1345
|
+
rscMetaRow: css`
|
|
1346
|
+
display: flex;
|
|
1347
|
+
gap: ${size[1]};
|
|
1348
|
+
align-items: flex-start;
|
|
1349
|
+
margin-left: calc(${size[3]} + ${size[1]});
|
|
1350
|
+
margin-top: ${size[.5]};
|
|
1351
|
+
flex-wrap: wrap;
|
|
1352
|
+
`,
|
|
1353
|
+
rscMetaLabel: css`
|
|
1354
|
+
color: ${colors.gray[500]};
|
|
1355
|
+
font-size: ${fontSize["2xs"]};
|
|
1356
|
+
text-transform: uppercase;
|
|
1357
|
+
letter-spacing: 0.06em;
|
|
1358
|
+
padding-top: 2px;
|
|
1359
|
+
`,
|
|
1360
|
+
rscChipRow: css`
|
|
1361
|
+
display: flex;
|
|
1362
|
+
gap: ${size[1]};
|
|
1363
|
+
flex-wrap: wrap;
|
|
1364
|
+
`,
|
|
1365
|
+
rscChip: css`
|
|
1366
|
+
display: inline-flex;
|
|
1367
|
+
align-items: center;
|
|
1368
|
+
gap: ${size[.5]};
|
|
1369
|
+
padding: 1px ${size[1]};
|
|
1370
|
+
border-radius: ${border.radius.full};
|
|
1371
|
+
border: 1px solid ${colors.darkGray[500]};
|
|
1372
|
+
background: ${colors.darkGray[800]};
|
|
1373
|
+
color: ${colors.gray[200]};
|
|
1374
|
+
font-size: ${fontSize["2xs"]};
|
|
1375
|
+
line-height: ${lineHeight.xs};
|
|
1376
|
+
`,
|
|
1377
|
+
rscChipName: css`
|
|
1378
|
+
color: ${colors.gray[100]};
|
|
1379
|
+
`,
|
|
1380
|
+
rscChipMeta: css`
|
|
1381
|
+
color: ${colors.gray[400]};
|
|
1382
|
+
font-size: ${fontSize["2xs"]};
|
|
1177
1383
|
`,
|
|
1178
1384
|
subEntries: css`
|
|
1179
1385
|
margin-left: ${size[2]};
|
|
@@ -1425,23 +1631,23 @@ var BaseTanStackRouterDevtoolsPanel = function BaseTanStackRouterDevtoolsPanel({
|
|
|
1425
1631
|
cachedMatches = _cachedMatches;
|
|
1426
1632
|
createEffect(() => {
|
|
1427
1633
|
const pendingMatchesStore = router().stores.pendingMatchesSnapshot;
|
|
1428
|
-
setPendingMatches(pendingMatchesStore.
|
|
1634
|
+
setPendingMatches(pendingMatchesStore.get());
|
|
1429
1635
|
const subscription = pendingMatchesStore.subscribe(() => {
|
|
1430
|
-
setPendingMatches(pendingMatchesStore.
|
|
1636
|
+
setPendingMatches(pendingMatchesStore.get());
|
|
1431
1637
|
});
|
|
1432
1638
|
onCleanup(() => subscription.unsubscribe());
|
|
1433
1639
|
});
|
|
1434
1640
|
createEffect(() => {
|
|
1435
1641
|
const cachedMatchesStore = router().stores.cachedMatchesSnapshot;
|
|
1436
|
-
setCachedMatches(cachedMatchesStore.
|
|
1642
|
+
setCachedMatches(cachedMatchesStore.get());
|
|
1437
1643
|
const subscription = cachedMatchesStore.subscribe(() => {
|
|
1438
|
-
setCachedMatches(cachedMatchesStore.
|
|
1644
|
+
setCachedMatches(cachedMatchesStore.get());
|
|
1439
1645
|
});
|
|
1440
1646
|
onCleanup(() => subscription.unsubscribe());
|
|
1441
1647
|
});
|
|
1442
1648
|
} else {
|
|
1443
|
-
pendingMatches = () => router().stores.pendingMatchesSnapshot.
|
|
1444
|
-
cachedMatches = () => router().stores.cachedMatchesSnapshot.
|
|
1649
|
+
pendingMatches = () => router().stores.pendingMatchesSnapshot.get();
|
|
1650
|
+
cachedMatches = () => router().stores.cachedMatchesSnapshot.get();
|
|
1445
1651
|
}
|
|
1446
1652
|
createEffect(() => {
|
|
1447
1653
|
const matches = routerState().matches;
|
|
@@ -1964,4 +2170,4 @@ delegateEvents(["click", "mousedown"]);
|
|
|
1964
2170
|
//#endregion
|
|
1965
2171
|
export { BaseTanStackRouterDevtoolsPanel, BaseTanStackRouterDevtoolsPanel as default, useLocalStorage as n, useStyles$1 as r, useIsMounted as t };
|
|
1966
2172
|
|
|
1967
|
-
//# sourceMappingURL=BaseTanStackRouterDevtoolsPanel-
|
|
2173
|
+
//# sourceMappingURL=BaseTanStackRouterDevtoolsPanel-BYamTwOT.js.map
|