@dxos/plugin-debug 0.10.0 → 0.11.0

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 (236) hide show
  1. package/PLUGIN.mdl +12 -325
  2. package/README.md +4 -14
  3. package/dist/lib/DebugPlugin.mjs +29 -0
  4. package/dist/lib/DebugPlugin.mjs.map +1 -0
  5. package/dist/lib/DebugPlugin.node.mjs +10 -0
  6. package/dist/lib/DebugPlugin.node.mjs.map +1 -0
  7. package/dist/lib/DebugPlugin.workerd.mjs +8 -0
  8. package/dist/lib/DebugPlugin.workerd.mjs.map +1 -0
  9. package/dist/lib/capabilities.mjs +11 -0
  10. package/dist/lib/capabilities.mjs.map +1 -0
  11. package/dist/lib/chunk-DebugObjectPanel.mjs +58 -0
  12. package/dist/lib/chunk-DebugObjectPanel.mjs.map +1 -0
  13. package/dist/lib/chunk-DebugSettings.mjs +237 -0
  14. package/dist/lib/chunk-DebugSettings.mjs.map +1 -0
  15. package/dist/lib/chunk-DebugSpaceObjectsPanel.mjs +39 -0
  16. package/dist/lib/chunk-DebugSpaceObjectsPanel.mjs.map +1 -0
  17. package/dist/lib/chunk-DebugStatus.mjs +117 -0
  18. package/dist/lib/chunk-DebugStatus.mjs.map +1 -0
  19. package/dist/lib/chunk-LogStatus.mjs +44 -0
  20. package/dist/lib/chunk-LogStatus.mjs.map +1 -0
  21. package/dist/lib/chunk-SpaceGenerator.mjs +208 -0
  22. package/dist/lib/chunk-SpaceGenerator.mjs.map +1 -0
  23. package/dist/lib/chunk-StatsPanel.mjs +58 -0
  24. package/dist/lib/chunk-StatsPanel.mjs.map +1 -0
  25. package/dist/lib/chunk-Wireframe.mjs +60 -0
  26. package/dist/lib/chunk-Wireframe.mjs.map +1 -0
  27. package/dist/lib/chunk-app-graph-builder.mjs +76 -0
  28. package/dist/lib/chunk-app-graph-builder.mjs.map +1 -0
  29. package/dist/lib/chunk-log-recording.mjs +17 -0
  30. package/dist/lib/chunk-log-recording.mjs.map +1 -0
  31. package/dist/lib/chunk-meta.mjs +36 -0
  32. package/dist/lib/chunk-meta.mjs.map +1 -0
  33. package/dist/lib/chunk-react-surface.mjs +193 -0
  34. package/dist/lib/chunk-react-surface.mjs.map +1 -0
  35. package/dist/lib/chunk-settings.mjs +23 -0
  36. package/dist/lib/chunk-settings.mjs.map +1 -0
  37. package/dist/lib/chunk-stats-panel.mjs +56 -0
  38. package/dist/lib/chunk-stats-panel.mjs.map +1 -0
  39. package/dist/lib/chunk-types.mjs +60 -0
  40. package/dist/lib/chunk-types.mjs.map +1 -0
  41. package/dist/lib/components.mjs +763 -0
  42. package/dist/lib/components.mjs.map +1 -0
  43. package/dist/lib/containers.mjs +14 -0
  44. package/dist/lib/containers.mjs.map +1 -0
  45. package/dist/lib/index.mjs +3 -0
  46. package/dist/lib/meta.mjs +2 -0
  47. package/dist/lib/plugin.mjs +8 -0
  48. package/dist/lib/plugin.mjs.map +1 -0
  49. package/dist/lib/translations.mjs +38 -0
  50. package/dist/lib/translations.mjs.map +1 -0
  51. package/dist/lib/types.mjs +2 -0
  52. package/dist/types/src/DebugPlugin.d.ts.map +1 -1
  53. package/dist/types/src/capabilities/DebugSurfaces.d.ts +25 -0
  54. package/dist/types/src/capabilities/DebugSurfaces.d.ts.map +1 -0
  55. package/dist/types/src/capabilities/app-graph-builder.d.ts +1 -1
  56. package/dist/types/src/capabilities/index.d.ts +4 -1
  57. package/dist/types/src/capabilities/index.d.ts.map +1 -1
  58. package/dist/types/src/capabilities/log-recording.d.ts +10 -0
  59. package/dist/types/src/capabilities/log-recording.d.ts.map +1 -0
  60. package/dist/types/src/capabilities/react-surface.d.ts +1 -1
  61. package/dist/types/src/capabilities/react-surface.d.ts.map +1 -1
  62. package/dist/types/src/capabilities/settings.d.ts +1 -1
  63. package/dist/types/src/capabilities/stats-panel.d.ts +16 -0
  64. package/dist/types/src/capabilities/stats-panel.d.ts.map +1 -0
  65. package/dist/types/src/components/SchemaTable/SchemaTable.d.ts +4 -3
  66. package/dist/types/src/components/SchemaTable/SchemaTable.d.ts.map +1 -1
  67. package/dist/types/src/components/SpaceGenerator/ObjectGenerator.d.ts.map +1 -1
  68. package/dist/types/src/containers/DebugObjectPanel/DebugObjectPanel.d.ts +4 -1
  69. package/dist/types/src/containers/DebugObjectPanel/DebugObjectPanel.d.ts.map +1 -1
  70. package/dist/types/src/containers/DebugSettings/DebugSettings.d.ts +4 -1
  71. package/dist/types/src/containers/DebugSettings/DebugSettings.d.ts.map +1 -1
  72. package/dist/types/src/containers/DebugSettings/DebugSettings.stories.d.ts +30 -58
  73. package/dist/types/src/containers/DebugSettings/DebugSettings.stories.d.ts.map +1 -1
  74. package/dist/types/src/containers/DebugSpaceObjectsPanel/DebugSpaceObjectsPanel.d.ts +4 -1
  75. package/dist/types/src/containers/DebugSpaceObjectsPanel/DebugSpaceObjectsPanel.d.ts.map +1 -1
  76. package/dist/types/src/containers/DebugStatus/DebugStatus.d.ts +4 -1
  77. package/dist/types/src/containers/DebugStatus/DebugStatus.d.ts.map +1 -1
  78. package/dist/types/src/containers/LogStatus/LogStatus.d.ts +6 -0
  79. package/dist/types/src/containers/LogStatus/LogStatus.d.ts.map +1 -0
  80. package/dist/types/src/containers/LogStatus/index.d.ts +2 -0
  81. package/dist/types/src/containers/LogStatus/index.d.ts.map +1 -0
  82. package/dist/types/src/containers/SpaceGenerator/SpaceGenerator.d.ts +1 -1
  83. package/dist/types/src/containers/SpaceGenerator/SpaceGenerator.d.ts.map +1 -1
  84. package/dist/types/src/containers/StatsPanel/StatsPanel.d.ts +6 -0
  85. package/dist/types/src/containers/StatsPanel/StatsPanel.d.ts.map +1 -0
  86. package/dist/types/src/containers/StatsPanel/index.d.ts +2 -0
  87. package/dist/types/src/containers/StatsPanel/index.d.ts.map +1 -0
  88. package/dist/types/src/containers/Wireframe/Wireframe.d.ts +4 -1
  89. package/dist/types/src/containers/Wireframe/Wireframe.d.ts.map +1 -1
  90. package/dist/types/src/containers/index.d.ts +4 -6
  91. package/dist/types/src/containers/index.d.ts.map +1 -1
  92. package/dist/types/src/translations.d.ts +26 -57
  93. package/dist/types/src/translations.d.ts.map +1 -1
  94. package/dist/types/src/types/DebugNodes.d.ts +7 -0
  95. package/dist/types/src/types/DebugNodes.d.ts.map +1 -0
  96. package/dist/types/src/types/DebugSurface.d.ts +8 -0
  97. package/dist/types/src/types/DebugSurface.d.ts.map +1 -0
  98. package/dist/types/src/types/debug.d.ts +3 -1
  99. package/dist/types/src/types/debug.d.ts.map +1 -1
  100. package/dist/types/src/types/index.d.ts +2 -2
  101. package/dist/types/src/types/index.d.ts.map +1 -1
  102. package/dist/types/tsconfig.tsbuildinfo +1 -1
  103. package/dx.config.ts +8 -13
  104. package/package.json +61 -63
  105. package/src/DebugPlugin.node.ts +1 -1
  106. package/src/DebugPlugin.tsx +10 -27
  107. package/src/DebugPlugin.workerd.ts +1 -1
  108. package/src/capabilities/DebugSurfaces.tsx +146 -0
  109. package/src/capabilities/app-graph-builder.ts +39 -373
  110. package/src/capabilities/index.ts +3 -2
  111. package/src/capabilities/log-recording.ts +20 -0
  112. package/src/capabilities/react-surface.ts +123 -0
  113. package/src/capabilities/stats-panel.ts +74 -0
  114. package/src/components/SchemaTable/SchemaTable.tsx +6 -5
  115. package/src/components/SpaceGenerator/ObjectGenerator.tsx +9 -3
  116. package/src/components/SpaceGenerator/presets.ts +2 -2
  117. package/src/components/index.ts +1 -1
  118. package/src/containers/DebugObjectPanel/DebugObjectPanel.tsx +20 -20
  119. package/src/containers/DebugSettings/DebugSettings.tsx +4 -3
  120. package/src/containers/DebugSpaceObjectsPanel/DebugSpaceObjectsPanel.tsx +4 -2
  121. package/src/containers/DebugStatus/DebugStatus.tsx +2 -0
  122. package/src/containers/LogStatus/LogStatus.tsx +51 -0
  123. package/src/containers/LogStatus/index.ts +5 -0
  124. package/src/containers/SpaceGenerator/SpaceGenerator.tsx +108 -10
  125. package/src/containers/StatsPanel/StatsPanel.tsx +74 -0
  126. package/src/containers/StatsPanel/index.ts +5 -0
  127. package/src/containers/Wireframe/Wireframe.tsx +2 -0
  128. package/src/containers/index.ts +9 -7
  129. package/src/index.ts +1 -1
  130. package/src/meta.ts +1 -1
  131. package/src/plugin.ts +1 -1
  132. package/src/translations.ts +8 -52
  133. package/src/types/DebugNodes.ts +18 -0
  134. package/src/types/DebugSurface.ts +16 -0
  135. package/src/types/debug.ts +3 -1
  136. package/src/types/index.ts +3 -3
  137. package/dist/lib/neutral/DebugGraph-G4FWS57E.mjs +0 -15
  138. package/dist/lib/neutral/DebugGraph-G4FWS57E.mjs.map +0 -7
  139. package/dist/lib/neutral/DebugObjectPanel-QSGQJ3LM.mjs +0 -61
  140. package/dist/lib/neutral/DebugObjectPanel-QSGQJ3LM.mjs.map +0 -7
  141. package/dist/lib/neutral/DebugPlugin.mjs +0 -59
  142. package/dist/lib/neutral/DebugPlugin.mjs.map +0 -7
  143. package/dist/lib/neutral/DebugPlugin.node.mjs +0 -18
  144. package/dist/lib/neutral/DebugPlugin.node.mjs.map +0 -7
  145. package/dist/lib/neutral/DebugPlugin.workerd.mjs +0 -12
  146. package/dist/lib/neutral/DebugPlugin.workerd.mjs.map +0 -7
  147. package/dist/lib/neutral/DebugSettings-Q3WUL6YQ.mjs +0 -229
  148. package/dist/lib/neutral/DebugSettings-Q3WUL6YQ.mjs.map +0 -7
  149. package/dist/lib/neutral/DebugSpaceObjectsPanel-AXFZWEIM.mjs +0 -36
  150. package/dist/lib/neutral/DebugSpaceObjectsPanel-AXFZWEIM.mjs.map +0 -7
  151. package/dist/lib/neutral/DebugStatus-H2BAHN26.mjs +0 -122
  152. package/dist/lib/neutral/DebugStatus-H2BAHN26.mjs.map +0 -7
  153. package/dist/lib/neutral/DevtoolsOverviewContainer-DWQHTK7D.mjs +0 -24
  154. package/dist/lib/neutral/DevtoolsOverviewContainer-DWQHTK7D.mjs.map +0 -7
  155. package/dist/lib/neutral/GithubPanel-4CSJRVKE.mjs +0 -177
  156. package/dist/lib/neutral/GithubPanel-4CSJRVKE.mjs.map +0 -7
  157. package/dist/lib/neutral/RegistryPanel-64GIYJHN.mjs +0 -161
  158. package/dist/lib/neutral/RegistryPanel-64GIYJHN.mjs.map +0 -7
  159. package/dist/lib/neutral/SpaceGenerator-Y35G6DRV.mjs +0 -146
  160. package/dist/lib/neutral/SpaceGenerator-Y35G6DRV.mjs.map +0 -7
  161. package/dist/lib/neutral/Wireframe-WD7S2AUU.mjs +0 -52
  162. package/dist/lib/neutral/Wireframe-WD7S2AUU.mjs.map +0 -7
  163. package/dist/lib/neutral/app-graph-builder-UKG4WVYK.mjs +0 -619
  164. package/dist/lib/neutral/app-graph-builder-UKG4WVYK.mjs.map +0 -7
  165. package/dist/lib/neutral/capabilities/index.mjs +0 -15
  166. package/dist/lib/neutral/capabilities/index.mjs.map +0 -7
  167. package/dist/lib/neutral/chunk-72QXLYMI.mjs +0 -118
  168. package/dist/lib/neutral/chunk-72QXLYMI.mjs.map +0 -7
  169. package/dist/lib/neutral/chunk-J5LGTIGS.mjs +0 -10
  170. package/dist/lib/neutral/chunk-J5LGTIGS.mjs.map +0 -7
  171. package/dist/lib/neutral/chunk-R5C4CKOF.mjs +0 -54
  172. package/dist/lib/neutral/chunk-R5C4CKOF.mjs.map +0 -7
  173. package/dist/lib/neutral/components/index.mjs +0 -961
  174. package/dist/lib/neutral/components/index.mjs.map +0 -7
  175. package/dist/lib/neutral/containers/index.mjs +0 -27
  176. package/dist/lib/neutral/containers/index.mjs.map +0 -7
  177. package/dist/lib/neutral/index.mjs +0 -20
  178. package/dist/lib/neutral/index.mjs.map +0 -7
  179. package/dist/lib/neutral/meta.json +0 -1
  180. package/dist/lib/neutral/meta.mjs +0 -8
  181. package/dist/lib/neutral/meta.mjs.map +0 -7
  182. package/dist/lib/neutral/plugin.mjs +0 -12
  183. package/dist/lib/neutral/plugin.mjs.map +0 -7
  184. package/dist/lib/neutral/react-context-UJURDOO6.mjs +0 -17
  185. package/dist/lib/neutral/react-context-UJURDOO6.mjs.map +0 -7
  186. package/dist/lib/neutral/react-surface-URESE7J4.mjs +0 -484
  187. package/dist/lib/neutral/react-surface-URESE7J4.mjs.map +0 -7
  188. package/dist/lib/neutral/settings-5I2674B6.mjs +0 -28
  189. package/dist/lib/neutral/settings-5I2674B6.mjs.map +0 -7
  190. package/dist/lib/neutral/translations.mjs +0 -91
  191. package/dist/lib/neutral/translations.mjs.map +0 -7
  192. package/dist/lib/neutral/types/index.mjs +0 -16
  193. package/dist/lib/neutral/types/index.mjs.map +0 -7
  194. package/dist/types/src/DebugPlugin.test.d.ts +0 -2
  195. package/dist/types/src/DebugPlugin.test.d.ts.map +0 -1
  196. package/dist/types/src/capabilities/react-context.d.ts +0 -5
  197. package/dist/types/src/capabilities/react-context.d.ts.map +0 -1
  198. package/dist/types/src/containers/DebugGraph/DebugGraph.d.ts +0 -8
  199. package/dist/types/src/containers/DebugGraph/DebugGraph.d.ts.map +0 -1
  200. package/dist/types/src/containers/DebugGraph/index.d.ts +0 -2
  201. package/dist/types/src/containers/DebugGraph/index.d.ts.map +0 -1
  202. package/dist/types/src/containers/DevtoolsOverviewContainer/DevtoolsOverviewContainer.d.ts +0 -3
  203. package/dist/types/src/containers/DevtoolsOverviewContainer/DevtoolsOverviewContainer.d.ts.map +0 -1
  204. package/dist/types/src/containers/DevtoolsOverviewContainer/index.d.ts +0 -2
  205. package/dist/types/src/containers/DevtoolsOverviewContainer/index.d.ts.map +0 -1
  206. package/dist/types/src/containers/GithubPanel/GithubComponent.d.ts +0 -15
  207. package/dist/types/src/containers/GithubPanel/GithubComponent.d.ts.map +0 -1
  208. package/dist/types/src/containers/GithubPanel/GithubComponent.stories.d.ts +0 -106
  209. package/dist/types/src/containers/GithubPanel/GithubComponent.stories.d.ts.map +0 -1
  210. package/dist/types/src/containers/GithubPanel/GithubPanel.d.ts +0 -3
  211. package/dist/types/src/containers/GithubPanel/GithubPanel.d.ts.map +0 -1
  212. package/dist/types/src/containers/GithubPanel/index.d.ts +0 -2
  213. package/dist/types/src/containers/GithubPanel/index.d.ts.map +0 -1
  214. package/dist/types/src/containers/RegistryPanel/RegistryPanel.d.ts +0 -3
  215. package/dist/types/src/containers/RegistryPanel/RegistryPanel.d.ts.map +0 -1
  216. package/dist/types/src/containers/RegistryPanel/index.d.ts +0 -2
  217. package/dist/types/src/containers/RegistryPanel/index.d.ts.map +0 -1
  218. package/dist/types/src/types/Devtools.d.ts +0 -57
  219. package/dist/types/src/types/Devtools.d.ts.map +0 -1
  220. package/dist/types/src/types/surface.d.ts +0 -4
  221. package/dist/types/src/types/surface.d.ts.map +0 -1
  222. package/src/DebugPlugin.test.ts +0 -29
  223. package/src/capabilities/react-context.tsx +0 -25
  224. package/src/capabilities/react-surface.tsx +0 -504
  225. package/src/containers/DebugGraph/DebugGraph.tsx +0 -14
  226. package/src/containers/DebugGraph/index.ts +0 -5
  227. package/src/containers/DevtoolsOverviewContainer/DevtoolsOverviewContainer.tsx +0 -27
  228. package/src/containers/DevtoolsOverviewContainer/index.ts +0 -5
  229. package/src/containers/GithubPanel/GithubComponent.stories.tsx +0 -38
  230. package/src/containers/GithubPanel/GithubComponent.tsx +0 -192
  231. package/src/containers/GithubPanel/GithubPanel.tsx +0 -17
  232. package/src/containers/GithubPanel/index.ts +0 -5
  233. package/src/containers/RegistryPanel/RegistryPanel.tsx +0 -150
  234. package/src/containers/RegistryPanel/index.ts +0 -5
  235. package/src/types/Devtools.ts +0 -73
  236. package/src/types/surface.ts +0 -10
@@ -1,385 +1,51 @@
1
1
  //
2
- // Copyright 2025 DXOS.org
2
+ // Copyright 2026 DXOS.org
3
3
  //
4
4
 
5
5
  import * as Effect from 'effect/Effect';
6
6
 
7
7
  import { Capability } from '@dxos/app-framework';
8
- import { AppCapabilities, AppNode, AppNodeMatcher, Paths } from '@dxos/app-toolkit';
8
+ import { AppCapabilities, AppNode, AppNodeMatcher, GraphPath } from '@dxos/app-toolkit';
9
9
  import { GraphBuilder, Node, NodeMatcher } from '@dxos/plugin-graph';
10
- import { type Space, isSpace } from '@dxos/react-client/echo';
10
+ import { type Space } from '@dxos/react-client/echo';
11
11
  import { Position } from '@dxos/util';
12
12
 
13
13
  import { meta } from '#meta';
14
- import { Devtools } from '#types';
14
+ import { DebugNodes } from '#types';
15
15
 
16
16
  export default Capability.makeModule(
17
17
  Effect.fnUntraced(function* () {
18
18
  const extensions = yield* Effect.all([
19
+ // Top-level Debug node (sibling of DevTools under SYSTEM); only present when a space is active.
19
20
  GraphBuilder.createExtension({
20
- id: 'root',
21
- match: NodeMatcher.whenRoot,
22
- actions: () =>
21
+ id: 'debug',
22
+ match: AppNodeMatcher.whenNavTreeGroup(GraphPath.GroupTypes.system),
23
+ connector: (space: Space) =>
23
24
  Effect.succeed([
24
- Node.makeAction({
25
- id: 'resetData',
26
- data: () =>
27
- Effect.sync(() => {
28
- window.location.href = '/reset.html#continue';
29
- }),
25
+ Node.make({
26
+ id: DebugNodes.nodeId(DebugNodes.id),
27
+ data: null,
28
+ type: DebugNodes.id,
30
29
  properties: {
31
- label: ['reset-data.label', { ns: meta.profile.key }],
32
- icon: 'ph--warning--regular',
30
+ label: ['debug.label', { ns: meta.profile.key }],
31
+ icon: 'ph--bug--regular',
32
+ position: Position.last,
33
33
  },
34
+ nodes: [
35
+ Node.make({
36
+ id: DebugNodes.nodeId(DebugNodes.SpaceType),
37
+ type: DebugNodes.SpaceType,
38
+ data: { space, type: DebugNodes.SpaceType },
39
+ properties: {
40
+ label: ['generate-objects.label', { ns: meta.profile.key }],
41
+ icon: 'ph--dice-five--regular',
42
+ },
43
+ }),
44
+ ],
34
45
  }),
35
46
  ]),
36
47
  }),
37
48
 
38
- GraphBuilder.createExtension({
39
- id: 'devtools',
40
- match: NodeMatcher.whenAny(NodeMatcher.whenRoot, AppNodeMatcher.whenNavTreeGroup(Paths.GroupTypes.system)),
41
- connector: (nodeOrSpace: Node.Node | Space, get) =>
42
- Effect.gen(function* () {
43
- const space: Space | undefined = isSpace(nodeOrSpace) ? nodeOrSpace : undefined;
44
- const [graph] = get(yield* Capability.atom(AppCapabilities.AppGraph));
45
-
46
- return [
47
- Node.make({
48
- id: Devtools.nodeId(Devtools.id),
49
- data: null,
50
- type: Devtools.id,
51
- properties: {
52
- label: ['devtools.label', { ns: meta.profile.key }],
53
- icon: 'ph--hammer--regular',
54
- position: Position.last,
55
- },
56
- nodes: [
57
- Node.make({
58
- id: Devtools.nodeId(Devtools.AppGraph),
59
- type: `${meta.profile.key}.app-graph`,
60
- data: { graph: graph?.graph, root: Node.RootId },
61
- properties: {
62
- label: ['debug-app-graph.label', { ns: meta.profile.key }],
63
- icon: 'ph--graph--regular',
64
- },
65
- }),
66
- Node.make({
67
- id: Devtools.nodeId(Devtools.ToolsExplorer),
68
- data: Devtools.ToolsExplorer,
69
- type: Devtools.id,
70
- properties: {
71
- label: ['debug-tools-explorer.label', { ns: meta.profile.key }],
72
- icon: 'ph--toolbox--regular',
73
- },
74
- }),
75
- ...(space
76
- ? [
77
- Node.make({
78
- id: Devtools.nodeId(Devtools.Debug),
79
- type: `${meta.profile.key}.space`,
80
- data: { space, type: `${meta.profile.key}.space` },
81
- properties: {
82
- label: ['generate-objects.label', { ns: meta.profile.key }],
83
- icon: 'ph--dice-five--regular',
84
- },
85
- }),
86
- ]
87
- : []),
88
- Node.make({
89
- id: Devtools.nodeId(Devtools.Client.id),
90
- data: null,
91
- type: Devtools.id,
92
- properties: {
93
- label: ['client.label', { ns: meta.profile.key }],
94
- icon: 'ph--users--regular',
95
- },
96
- nodes: [
97
- Node.make({
98
- id: Devtools.nodeId(Devtools.Client.Config),
99
- data: Devtools.Client.Config,
100
- type: Devtools.id,
101
- properties: {
102
- label: ['config.label', { ns: meta.profile.key }],
103
- icon: 'ph--gear--regular',
104
- },
105
- }),
106
- Node.make({
107
- id: Devtools.nodeId(Devtools.Client.Storage),
108
- data: Devtools.Client.Storage,
109
- type: Devtools.id,
110
- properties: {
111
- label: ['storage.label', { ns: meta.profile.key }],
112
- icon: 'ph--hard-drives--regular',
113
- },
114
- }),
115
- Node.make({
116
- id: Devtools.nodeId(Devtools.Client.Sqlite),
117
- data: Devtools.Client.Sqlite,
118
- type: Devtools.id,
119
- properties: {
120
- label: ['sqlite.label', { ns: meta.profile.key }],
121
- icon: 'ph--database--regular',
122
- },
123
- }),
124
- Node.make({
125
- id: Devtools.nodeId(Devtools.Client.Logs),
126
- data: Devtools.Client.Logs,
127
- type: Devtools.id,
128
- properties: {
129
- label: ['logs.label', { ns: meta.profile.key }],
130
- icon: 'ph--file-text--regular',
131
- },
132
- }),
133
- Node.make({
134
- id: Devtools.nodeId(Devtools.Client.Diagnostics),
135
- data: Devtools.Client.Diagnostics,
136
- type: Devtools.id,
137
- properties: {
138
- label: ['diagnostics.label', { ns: meta.profile.key }],
139
- icon: 'ph--chart-line--regular',
140
- },
141
- }),
142
- ],
143
- }),
144
- Node.make({
145
- id: Devtools.nodeId(Devtools.Halo.id),
146
- data: null,
147
- type: Devtools.id,
148
- properties: {
149
- label: ['halo.label', { ns: meta.profile.key }],
150
- icon: 'ph--identification-badge--regular',
151
- },
152
- nodes: [
153
- Node.make({
154
- id: Devtools.nodeId(Devtools.Halo.Identity),
155
- data: Devtools.Halo.Identity,
156
- type: Devtools.id,
157
- properties: {
158
- label: ['identity.label', { ns: meta.profile.key }],
159
- icon: 'ph--identification-badge--regular',
160
- },
161
- }),
162
- Node.make({
163
- id: Devtools.nodeId(Devtools.Halo.Devices),
164
- data: Devtools.Halo.Devices,
165
- type: Devtools.id,
166
- properties: {
167
- label: ['devices.label', { ns: meta.profile.key }],
168
- icon: 'ph--devices--regular',
169
- },
170
- }),
171
- Node.make({
172
- id: Devtools.nodeId(Devtools.Halo.Keyring),
173
- data: Devtools.Halo.Keyring,
174
- type: Devtools.id,
175
- properties: {
176
- label: ['keyring.label', { ns: meta.profile.key }],
177
- icon: 'ph--key--regular',
178
- },
179
- }),
180
- Node.make({
181
- id: Devtools.nodeId(Devtools.Halo.Credentials),
182
- data: Devtools.Halo.Credentials,
183
- type: Devtools.id,
184
- properties: {
185
- label: ['credentials.label', { ns: meta.profile.key }],
186
- icon: 'ph--credit-card--regular',
187
- },
188
- }),
189
- ],
190
- }),
191
- Node.make({
192
- id: Devtools.nodeId(Devtools.Echo.id),
193
- data: null,
194
- type: Devtools.id,
195
- properties: {
196
- label: ['echo.label', { ns: meta.profile.key }],
197
- icon: 'ph--database--regular',
198
- },
199
- nodes: [
200
- Node.make({
201
- id: Devtools.nodeId(Devtools.Echo.Spaces),
202
- data: Devtools.Echo.Spaces,
203
- type: Devtools.id,
204
- properties: {
205
- label: ['spaces.label', { ns: meta.profile.key }],
206
- icon: 'ph--graph--regular',
207
- },
208
- }),
209
- Node.make({
210
- id: Devtools.nodeId(Devtools.Echo.Space),
211
- data: Devtools.Echo.Space,
212
- type: Devtools.id,
213
- properties: {
214
- label: ['space.label', { ns: meta.profile.key }],
215
- icon: 'ph--planet--regular',
216
- },
217
- }),
218
- Node.make({
219
- id: Devtools.nodeId(Devtools.Echo.Feeds),
220
- data: Devtools.Echo.Feeds,
221
- type: Devtools.id,
222
- properties: {
223
- label: ['feeds.label', { ns: meta.profile.key }],
224
- icon: 'ph--list-bullets--regular',
225
- },
226
- }),
227
- Node.make({
228
- id: Devtools.nodeId(Devtools.Echo.Objects),
229
- data: Devtools.Echo.Objects,
230
- type: Devtools.id,
231
- properties: {
232
- label: ['objects.label', { ns: meta.profile.key }],
233
- icon: 'ph--cube--regular',
234
- },
235
- }),
236
- Node.make({
237
- id: Devtools.nodeId(Devtools.Echo.Schema),
238
- data: Devtools.Echo.Schema,
239
- type: Devtools.id,
240
- properties: {
241
- label: ['schema.label', { ns: meta.profile.key }],
242
- icon: 'ph--database--regular',
243
- },
244
- }),
245
- Node.make({
246
- id: Devtools.nodeId(Devtools.Echo.Registry),
247
- data: Devtools.Echo.Registry,
248
- type: Devtools.id,
249
- properties: {
250
- label: ['registry.label', { ns: meta.profile.key }],
251
- icon: 'ph--books--regular',
252
- },
253
- }),
254
- Node.make({
255
- id: Devtools.nodeId(Devtools.Echo.Automerge),
256
- data: Devtools.Echo.Automerge,
257
- type: Devtools.id,
258
- properties: {
259
- label: ['automerge.label', { ns: meta.profile.key }],
260
- icon: 'ph--gear-six--regular',
261
- },
262
- }),
263
- Node.make({
264
- id: Devtools.nodeId(Devtools.Echo.Queues),
265
- data: Devtools.Echo.Queues,
266
- type: Devtools.id,
267
- properties: {
268
- label: ['queues.label', { ns: meta.profile.key }],
269
- icon: 'ph--queue--regular',
270
- },
271
- }),
272
- Node.make({
273
- id: Devtools.nodeId(Devtools.Echo.Members),
274
- data: Devtools.Echo.Members,
275
- type: Devtools.id,
276
- properties: {
277
- label: ['members.label', { ns: meta.profile.key }],
278
- icon: 'ph--users--regular',
279
- },
280
- }),
281
- Node.make({
282
- id: Devtools.nodeId(Devtools.Echo.Metadata),
283
- data: Devtools.Echo.Metadata,
284
- type: Devtools.id,
285
- properties: {
286
- label: ['metadata.label', { ns: meta.profile.key }],
287
- icon: 'ph--hard-drive--regular',
288
- },
289
- }),
290
- ],
291
- }),
292
- Node.make({
293
- id: Devtools.nodeId(Devtools.Mesh.id),
294
- data: null,
295
- type: Devtools.id,
296
- properties: {
297
- label: ['mesh.label', { ns: meta.profile.key }],
298
- icon: 'ph--graph--regular',
299
- },
300
- nodes: [
301
- Node.make({
302
- id: Devtools.nodeId(Devtools.Mesh.Signal),
303
- data: Devtools.Mesh.Signal,
304
- type: Devtools.id,
305
- properties: {
306
- label: ['signal.label', { ns: meta.profile.key }],
307
- icon: 'ph--wifi-high--regular',
308
- },
309
- }),
310
- Node.make({
311
- id: Devtools.nodeId(Devtools.Mesh.Swarm),
312
- data: Devtools.Mesh.Swarm,
313
- type: Devtools.id,
314
- properties: {
315
- label: ['swarm.label', { ns: meta.profile.key }],
316
- icon: 'ph--users-three--regular',
317
- },
318
- }),
319
- Node.make({
320
- id: Devtools.nodeId(Devtools.Mesh.Network),
321
- data: Devtools.Mesh.Network,
322
- type: Devtools.id,
323
- properties: {
324
- label: ['network.label', { ns: meta.profile.key }],
325
- icon: 'ph--polygon--regular',
326
- },
327
- }),
328
- ],
329
- }),
330
- Node.make({
331
- id: Devtools.nodeId(Devtools.Edge.id),
332
- data: null,
333
- type: Devtools.id,
334
- properties: {
335
- label: ['edge.label', { ns: meta.profile.key }],
336
- icon: 'ph--cloud--regular',
337
- },
338
- nodes: [
339
- Node.make({
340
- id: Devtools.nodeId(Devtools.Edge.Dashboard),
341
- data: Devtools.Edge.Dashboard,
342
- type: Devtools.id,
343
- properties: {
344
- label: ['dashboard.label', { ns: meta.profile.key }],
345
- icon: 'ph--computer-tower--regular',
346
- },
347
- }),
348
- Node.make({
349
- id: Devtools.nodeId(Devtools.Edge.Workflows),
350
- data: Devtools.Edge.Workflows,
351
- type: Devtools.id,
352
- properties: {
353
- label: ['workflows.label', { ns: meta.profile.key }],
354
- icon: 'ph--function--regular',
355
- },
356
- }),
357
- Node.make({
358
- id: Devtools.nodeId(Devtools.Edge.Traces),
359
- data: Devtools.Edge.Traces,
360
- type: Devtools.id,
361
- properties: {
362
- label: ['traces.label', { ns: meta.profile.key }],
363
- icon: 'ph--line-segments--regular',
364
- },
365
- }),
366
- Node.make({
367
- id: Devtools.nodeId(Devtools.Edge.Testing),
368
- data: Devtools.Edge.Testing,
369
- type: Devtools.id,
370
- properties: {
371
- label: ['testing.label', { ns: meta.profile.key }],
372
- icon: 'ph--flask--regular',
373
- },
374
- }),
375
- ],
376
- }),
377
- ],
378
- }),
379
- ];
380
- }),
381
- }),
382
-
383
49
  // Debug object companion.
384
50
  GraphBuilder.createExtension({
385
51
  id: 'debugObject',
@@ -387,7 +53,7 @@ export default Capability.makeModule(
387
53
  connector: () =>
388
54
  Effect.succeed([
389
55
  AppNode.makeCompanion({
390
- id: 'debug',
56
+ variant: 'debug',
391
57
  label: ['debug.label', { ns: meta.profile.key }],
392
58
  icon: 'ph--bug--regular',
393
59
  data: 'debug',
@@ -396,33 +62,33 @@ export default Capability.makeModule(
396
62
  ]),
397
63
  }),
398
64
 
399
- // Devtools deck companion.
65
+ // Object explorer deck companion.
400
66
  GraphBuilder.createExtension({
401
- id: 'devtoolsOverview',
67
+ id: 'spaceObjects',
402
68
  match: NodeMatcher.whenRoot,
403
69
  connector: () =>
404
70
  Effect.succeed([
405
71
  AppNode.makeDeckCompanion({
406
- id: 'devtoolsOverview',
407
- label: ['devtools-overview.label', { ns: meta.profile.key }],
408
- icon: 'ph--equalizer--regular',
409
- data: 'devtools' as const,
72
+ id: 'spaceObjects',
73
+ label: ['space-objects.label', { ns: meta.profile.key }],
74
+ icon: 'ph--cube--regular',
75
+ data: 'space-objects' as const,
410
76
  position: Position.last,
411
77
  }),
412
78
  ]),
413
79
  }),
414
80
 
415
- // Object explorer.
81
+ // Log panel deck companion.
416
82
  GraphBuilder.createExtension({
417
- id: 'spaceObjects',
83
+ id: 'logs',
418
84
  match: NodeMatcher.whenRoot,
419
85
  connector: () =>
420
86
  Effect.succeed([
421
87
  AppNode.makeDeckCompanion({
422
- id: 'spaceObjects',
423
- label: ['space-objects.label', { ns: meta.profile.key }],
424
- icon: 'ph--cube--regular',
425
- data: 'space-objects' as const,
88
+ id: 'logs',
89
+ label: ['logs.label', { ns: meta.profile.key }],
90
+ icon: 'ph--list-magnifying-glass--regular',
91
+ data: 'logs' as const,
426
92
  position: Position.last,
427
93
  }),
428
94
  ]),
@@ -1,10 +1,11 @@
1
1
  //
2
- // Copyright 2025 DXOS.org
2
+ // Copyright 2026 DXOS.org
3
3
  //
4
4
 
5
5
  import { Capability } from '@dxos/app-framework';
6
6
 
7
7
  export const AppGraphBuilder = Capability.lazy('AppGraphBuilder', () => import('./app-graph-builder'));
8
- export const ReactContext = Capability.lazy('ReactContext', () => import('./react-context'));
9
8
  export const ReactSurface = Capability.lazy('ReactSurface', () => import('./react-surface'));
10
9
  export const DebugSettings = Capability.lazy('DebugSettings', () => import('./settings'));
10
+ export const StatsPanel = Capability.lazy('StatsPanel', () => import('./stats-panel'));
11
+ export const LogRecording = Capability.lazy('LogRecording', () => import('./log-recording'));
@@ -0,0 +1,20 @@
1
+ //
2
+ // Copyright 2026 DXOS.org
3
+ //
4
+
5
+ import * as Effect from 'effect/Effect';
6
+
7
+ import { Capabilities, Capability } from '@dxos/app-framework';
8
+ import { logBuffer } from '@dxos/react-ui-debug';
9
+
10
+ /**
11
+ * Start recording into the process-wide log buffer at startup, so the log companion shows what
12
+ * happened before it was opened. Recording deliberately does not follow the panel's mount: the
13
+ * entries worth reading are usually the ones from before you went looking.
14
+ */
15
+ export default Capability.makeModule(
16
+ Effect.fnUntraced(function* () {
17
+ logBuffer.start();
18
+ return Capability.contributes(Capabilities.Null, null, () => Effect.sync(() => logBuffer.stop()));
19
+ }),
20
+ );
@@ -0,0 +1,123 @@
1
+ //
2
+ // Copyright 2026 DXOS.org
3
+ //
4
+
5
+ import * as Effect from 'effect/Effect';
6
+
7
+ import { Capabilities, Capability } from '@dxos/app-framework';
8
+ import { Surface } from '@dxos/app-framework/ui';
9
+ import { AppCapabilities } from '@dxos/app-toolkit';
10
+ import { AppSurface } from '@dxos/app-toolkit/ui';
11
+ import { Obj } from '@dxos/echo';
12
+ import { type IdbLogStore } from '@dxos/log-store-idb';
13
+ import { type Space, isSpace } from '@dxos/react-client/echo';
14
+ import { Position } from '@dxos/util';
15
+
16
+ import { DebugStatus, LogStatus, StatsPanel, Wireframe } from '#containers';
17
+ import { meta } from '#meta';
18
+ import { DebugCapabilities, DebugNodes, DebugSurface } from '#types';
19
+
20
+ import {
21
+ DebugSettingsSurface,
22
+ LoggerSurface,
23
+ ObjectDebugSurface,
24
+ SpaceGeneratorSurface,
25
+ SpaceObjectsSurface,
26
+ } from './DebugSurfaces';
27
+
28
+ type SpaceDebug = {
29
+ type: string;
30
+ space: Space;
31
+ };
32
+
33
+ const isSpaceDebug = (data: unknown): data is SpaceDebug =>
34
+ typeof data === 'object' &&
35
+ data !== null &&
36
+ 'type' in data &&
37
+ data.type === DebugNodes.SpaceType &&
38
+ 'space' in data &&
39
+ isSpace(data.space);
40
+
41
+ type ReactSurfaceOptions = {
42
+ logStore?: IdbLogStore;
43
+ };
44
+
45
+ export default Capability.makeModule(
46
+ Effect.fnUntraced(function* ({ logStore }: ReactSurfaceOptions) {
47
+ const capabilities = yield* Capability.Service;
48
+ const registry = capabilities.get(Capabilities.AtomRegistry);
49
+ const settingsAtom = capabilities.get(DebugCapabilities.Settings);
50
+ const fileUploader = capabilities.getAll(AppCapabilities.FileUploader)[0];
51
+
52
+ return Capability.contributes(Capabilities.ReactSurface, [
53
+ Surface.create({
54
+ id: 'pluginSettings',
55
+ filter: AppSurface.settings(AppSurface.Article, meta.profile.key),
56
+ component: DebugSettingsSurface,
57
+ props: ({ data: { subject } }) => ({ subject, logStore, onUpload: fileUploader }),
58
+ }),
59
+ Surface.create({
60
+ id: 'space',
61
+ filter: AppSurface.subject(AppSurface.Article, isSpaceDebug),
62
+ component: SpaceGeneratorSurface,
63
+ props: ({ role, data: { subject } }) => ({ role, space: subject.space }),
64
+ }),
65
+ Surface.create({
66
+ id: 'wireframe',
67
+ // TODO(wittjosiah): Split into multiple surfaces if this filter proves too strict for non-article roles.
68
+ filter: AppSurface.oneOf(
69
+ AppSurface.subject(AppSurface.Article, (value): value is Obj.Unknown => {
70
+ const settings = registry.get(settingsAtom);
71
+ return Obj.isObject(value) && !!settings.wireframe;
72
+ }),
73
+ AppSurface.subject(AppSurface.Section, (value): value is Obj.Unknown => {
74
+ const settings = registry.get(settingsAtom);
75
+ return Obj.isObject(value) && !!settings.wireframe;
76
+ }),
77
+ ),
78
+ position: Position.first,
79
+ component: Wireframe,
80
+ props: ({ role, name, data: { subject } }) => ({
81
+ label: `${role}:${name}`,
82
+ object: subject,
83
+ classNames: 'row-span-2 overflow-hidden',
84
+ }),
85
+ }),
86
+ Surface.create({
87
+ id: 'objectDebug',
88
+ filter: AppSurface.allOf(
89
+ AppSurface.literal(AppSurface.Article, 'debug'),
90
+ AppSurface.companion(AppSurface.Article),
91
+ ),
92
+ component: ObjectDebugSurface,
93
+ props: ({ role, data: { companionTo } }) => ({ role, companionTo }),
94
+ }),
95
+ Surface.create({
96
+ id: 'spaceObjects',
97
+ filter: Surface.makeFilter(AppSurface.deckCompanion('spaceObjects')),
98
+ component: SpaceObjectsSurface,
99
+ }),
100
+ Surface.create({
101
+ id: 'debugStatus',
102
+ filter: Surface.makeFilter(AppSurface.StatusIndicator),
103
+ position: Position.first,
104
+ component: DebugStatus,
105
+ }),
106
+ Surface.create({
107
+ id: 'logs',
108
+ filter: Surface.makeFilter(AppSurface.deckCompanion('logs')),
109
+ component: LoggerSurface,
110
+ }),
111
+ Surface.create({
112
+ id: 'logStatus',
113
+ filter: Surface.makeFilter(AppSurface.StatusIndicator),
114
+ component: LogStatus,
115
+ }),
116
+ Surface.create({
117
+ id: 'statsPanel',
118
+ filter: Surface.makeFilter(DebugSurface.Stats),
119
+ component: StatsPanel,
120
+ }),
121
+ ]);
122
+ }),
123
+ );