@dxos/plugin-devtools 0.10.0 → 0.11.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 (99) hide show
  1. package/README.md +3 -3
  2. package/dist/lib/DevtoolsPlugin.mjs +39 -0
  3. package/dist/lib/DevtoolsPlugin.mjs.map +1 -0
  4. package/dist/lib/DevtoolsPlugin.node.mjs +10 -0
  5. package/dist/lib/DevtoolsPlugin.node.mjs.map +1 -0
  6. package/dist/lib/DevtoolsPlugin.workerd.mjs +8 -0
  7. package/dist/lib/DevtoolsPlugin.workerd.mjs.map +1 -0
  8. package/dist/lib/capabilities.mjs +9 -0
  9. package/dist/lib/capabilities.mjs.map +1 -0
  10. package/dist/lib/chunk-DebugGraph.mjs +20 -0
  11. package/dist/lib/chunk-DebugGraph.mjs.map +1 -0
  12. package/dist/lib/chunk-DevtoolsOverviewContainer.mjs +40 -0
  13. package/dist/lib/chunk-DevtoolsOverviewContainer.mjs.map +1 -0
  14. package/dist/lib/chunk-GithubPanel.mjs +158 -0
  15. package/dist/lib/chunk-GithubPanel.mjs.map +1 -0
  16. package/dist/lib/chunk-RegistryPanel.mjs +124 -0
  17. package/dist/lib/chunk-RegistryPanel.mjs.map +1 -0
  18. package/dist/lib/chunk-app-graph-builder.mjs +371 -0
  19. package/dist/lib/chunk-app-graph-builder.mjs.map +1 -0
  20. package/dist/lib/{neutral/chunk-QCL4JV4T.mjs → chunk-meta.mjs} +16 -25
  21. package/dist/lib/chunk-meta.mjs.map +1 -0
  22. package/dist/lib/chunk-react-context.mjs +16 -0
  23. package/dist/lib/chunk-react-context.mjs.map +1 -0
  24. package/dist/lib/chunk-react-surface.mjs +252 -0
  25. package/dist/lib/chunk-react-surface.mjs.map +1 -0
  26. package/dist/lib/chunk-types.mjs +92 -0
  27. package/dist/lib/chunk-types.mjs.map +1 -0
  28. package/dist/lib/containers.mjs +10 -0
  29. package/dist/lib/containers.mjs.map +1 -0
  30. package/dist/lib/index.mjs +3 -0
  31. package/dist/lib/meta.mjs +2 -0
  32. package/dist/lib/plugin.mjs +8 -0
  33. package/dist/lib/plugin.mjs.map +1 -0
  34. package/dist/lib/translations.mjs +55 -0
  35. package/dist/lib/translations.mjs.map +1 -0
  36. package/dist/lib/types.mjs +2 -0
  37. package/dist/types/src/capabilities/DevtoolsSurfaces.d.ts +18 -0
  38. package/dist/types/src/capabilities/DevtoolsSurfaces.d.ts.map +1 -0
  39. package/dist/types/src/capabilities/app-graph-builder.d.ts +1 -1
  40. package/dist/types/src/capabilities/react-context.d.ts +1 -1
  41. package/dist/types/src/capabilities/react-surface.d.ts +1 -1
  42. package/dist/types/src/capabilities/react-surface.d.ts.map +1 -1
  43. package/dist/types/src/containers/DebugGraph/DebugGraph.d.ts.map +1 -1
  44. package/dist/types/src/containers/GithubPanel/GithubComponent.stories.d.ts +1 -1
  45. package/dist/types/src/translations.d.ts +1 -1
  46. package/dist/types/src/translations.d.ts.map +1 -1
  47. package/dist/types/tsconfig.tsbuildinfo +1 -1
  48. package/package.json +77 -79
  49. package/src/DevtoolsPlugin.tsx +1 -1
  50. package/src/capabilities/DevtoolsSurfaces.tsx +100 -0
  51. package/src/capabilities/app-graph-builder.ts +3 -3
  52. package/src/capabilities/react-surface.ts +236 -0
  53. package/src/containers/DebugGraph/DebugGraph.tsx +12 -1
  54. package/src/containers/GithubPanel/GithubComponent.stories.tsx +1 -1
  55. package/src/containers/GithubPanel/GithubComponent.tsx +1 -1
  56. package/src/containers/GithubPanel/GithubPanel.tsx +1 -1
  57. package/src/containers/RegistryPanel/RegistryPanel.tsx +15 -14
  58. package/src/translations.ts +1 -1
  59. package/dist/lib/neutral/DebugGraph-F7AMZXKW.mjs +0 -16
  60. package/dist/lib/neutral/DebugGraph-F7AMZXKW.mjs.map +0 -7
  61. package/dist/lib/neutral/DevtoolsOverviewContainer-DCNZFKK5.mjs +0 -51
  62. package/dist/lib/neutral/DevtoolsOverviewContainer-DCNZFKK5.mjs.map +0 -7
  63. package/dist/lib/neutral/DevtoolsPlugin.mjs +0 -55
  64. package/dist/lib/neutral/DevtoolsPlugin.mjs.map +0 -7
  65. package/dist/lib/neutral/DevtoolsPlugin.node.mjs +0 -16
  66. package/dist/lib/neutral/DevtoolsPlugin.node.mjs.map +0 -7
  67. package/dist/lib/neutral/DevtoolsPlugin.workerd.mjs +0 -12
  68. package/dist/lib/neutral/DevtoolsPlugin.workerd.mjs.map +0 -7
  69. package/dist/lib/neutral/GithubPanel-DWFZXZUK.mjs +0 -178
  70. package/dist/lib/neutral/GithubPanel-DWFZXZUK.mjs.map +0 -7
  71. package/dist/lib/neutral/RegistryPanel-CVETZUZV.mjs +0 -162
  72. package/dist/lib/neutral/RegistryPanel-CVETZUZV.mjs.map +0 -7
  73. package/dist/lib/neutral/app-graph-builder-KHZ65O2Q.mjs +0 -560
  74. package/dist/lib/neutral/app-graph-builder-KHZ65O2Q.mjs.map +0 -7
  75. package/dist/lib/neutral/capabilities/index.mjs +0 -13
  76. package/dist/lib/neutral/capabilities/index.mjs.map +0 -7
  77. package/dist/lib/neutral/chunk-J5LGTIGS.mjs +0 -10
  78. package/dist/lib/neutral/chunk-J5LGTIGS.mjs.map +0 -7
  79. package/dist/lib/neutral/chunk-PJNVAE7D.mjs +0 -81
  80. package/dist/lib/neutral/chunk-PJNVAE7D.mjs.map +0 -7
  81. package/dist/lib/neutral/chunk-QCL4JV4T.mjs.map +0 -7
  82. package/dist/lib/neutral/containers/index.mjs +0 -15
  83. package/dist/lib/neutral/containers/index.mjs.map +0 -7
  84. package/dist/lib/neutral/index.mjs +0 -12
  85. package/dist/lib/neutral/index.mjs.map +0 -7
  86. package/dist/lib/neutral/meta.json +0 -1
  87. package/dist/lib/neutral/meta.mjs +0 -8
  88. package/dist/lib/neutral/meta.mjs.map +0 -7
  89. package/dist/lib/neutral/plugin.mjs +0 -12
  90. package/dist/lib/neutral/plugin.mjs.map +0 -7
  91. package/dist/lib/neutral/react-context-UJURDOO6.mjs +0 -17
  92. package/dist/lib/neutral/react-context-UJURDOO6.mjs.map +0 -7
  93. package/dist/lib/neutral/react-surface-XILLHGRR.mjs +0 -332
  94. package/dist/lib/neutral/react-surface-XILLHGRR.mjs.map +0 -7
  95. package/dist/lib/neutral/translations.mjs +0 -65
  96. package/dist/lib/neutral/translations.mjs.map +0 -7
  97. package/dist/lib/neutral/types/index.mjs +0 -8
  98. package/dist/lib/neutral/types/index.mjs.map +0 -7
  99. package/src/capabilities/react-surface.tsx +0 -331
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dxos/plugin-devtools",
3
- "version": "0.10.0",
3
+ "version": "0.11.1",
4
4
  "description": "DXOS developer inspector plugin.",
5
5
  "homepage": "https://dxos.org",
6
6
  "bugs": "https://github.com/dxos/dxos/issues",
@@ -16,17 +16,17 @@
16
16
  "#capabilities": {
17
17
  "source": "./src/capabilities/index.ts",
18
18
  "types": "./dist/types/src/capabilities/index.d.ts",
19
- "default": "./dist/lib/neutral/capabilities/index.mjs"
19
+ "default": "./dist/lib/capabilities.mjs"
20
20
  },
21
21
  "#containers": {
22
22
  "source": "./src/containers/index.ts",
23
23
  "types": "./dist/types/src/containers/index.d.ts",
24
- "default": "./dist/lib/neutral/containers/index.mjs"
24
+ "default": "./dist/lib/containers.mjs"
25
25
  },
26
26
  "#meta": {
27
27
  "source": "./src/meta.ts",
28
28
  "types": "./dist/types/src/meta.d.ts",
29
- "default": "./dist/lib/neutral/meta.mjs"
29
+ "default": "./dist/lib/meta.mjs"
30
30
  },
31
31
  "#plugin": {
32
32
  "source": {
@@ -35,37 +35,37 @@
35
35
  "default": "./src/DevtoolsPlugin.tsx"
36
36
  },
37
37
  "types": "./dist/types/src/DevtoolsPlugin.d.ts",
38
- "workerd": "./dist/lib/neutral/DevtoolsPlugin.workerd.mjs",
39
- "node": "./dist/lib/neutral/DevtoolsPlugin.node.mjs",
40
- "default": "./dist/lib/neutral/DevtoolsPlugin.mjs"
38
+ "workerd": "./dist/lib/DevtoolsPlugin.workerd.mjs",
39
+ "node": "./dist/lib/DevtoolsPlugin.node.mjs",
40
+ "default": "./dist/lib/DevtoolsPlugin.mjs"
41
41
  },
42
42
  "#translations": {
43
43
  "source": "./src/translations.ts",
44
44
  "types": "./dist/types/src/translations.d.ts",
45
- "default": "./dist/lib/neutral/translations.mjs"
45
+ "default": "./dist/lib/translations.mjs"
46
46
  },
47
47
  "#types": {
48
48
  "source": "./src/types/index.ts",
49
49
  "types": "./dist/types/src/types/index.d.ts",
50
- "default": "./dist/lib/neutral/types/index.mjs"
50
+ "default": "./dist/lib/types.mjs"
51
51
  }
52
52
  },
53
53
  "exports": {
54
54
  ".": {
55
55
  "source": "./src/index.ts",
56
56
  "types": "./dist/types/src/index.d.ts",
57
- "default": "./dist/lib/neutral/index.mjs"
57
+ "import": "./dist/lib/index.mjs"
58
58
  },
59
59
  "./assets/PLUGIN.mdl": "./PLUGIN.mdl",
60
60
  "./plugin": {
61
61
  "source": "./src/plugin.ts",
62
62
  "types": "./dist/types/src/plugin.d.ts",
63
- "default": "./dist/lib/neutral/plugin.mjs"
63
+ "import": "./dist/lib/plugin.mjs"
64
64
  },
65
65
  "./translations": {
66
66
  "source": "./src/translations.ts",
67
67
  "types": "./dist/types/src/translations.d.ts",
68
- "default": "./dist/lib/neutral/translations.mjs"
68
+ "import": "./dist/lib/translations.mjs"
69
69
  }
70
70
  },
71
71
  "types": "dist/types/src/index.d.ts",
@@ -76,78 +76,76 @@
76
76
  "PLUGIN.mdl"
77
77
  ],
78
78
  "dependencies": {
79
- "@antv/graphlib": "catalog:",
80
- "@antv/layout": "catalog:",
81
- "@dxos/app-framework": "workspace:*",
82
- "@dxos/app-toolkit": "workspace:*",
83
- "@dxos/assistant-toolkit": "workspace:*",
84
- "@dxos/async": "workspace:*",
85
- "@dxos/client-services": "workspace:*",
86
- "@dxos/compute": "workspace:*",
87
- "@dxos/compute-hyperformula": "workspace:*",
88
- "@dxos/conductor": "workspace:*",
89
- "@dxos/config": "workspace:*",
90
- "@dxos/devtools": "workspace:*",
91
- "@dxos/echo": "workspace:*",
92
- "@dxos/echo-host": "workspace:*",
93
- "@dxos/effect": "workspace:*",
94
- "@dxos/invariant": "workspace:*",
95
- "@dxos/keys": "workspace:*",
96
- "@dxos/log": "workspace:*",
97
- "@dxos/log-store-idb": "workspace:*",
98
- "@dxos/operation": "workspace:*",
99
- "@dxos/plugin-client": "workspace:*",
100
- "@dxos/plugin-graph": "workspace:*",
101
- "@dxos/plugin-inbox": "workspace:*",
102
- "@dxos/plugin-markdown": "workspace:*",
103
- "@dxos/plugin-script": "workspace:*",
104
- "@dxos/plugin-sheet": "workspace:*",
105
- "@dxos/plugin-sketch": "workspace:*",
106
- "@dxos/plugin-space": "workspace:*",
107
- "@dxos/plugin-status-bar": "workspace:*",
108
- "@dxos/protocols": "workspace:*",
109
- "@dxos/random": "workspace:*",
110
- "@dxos/react-client": "workspace:*",
111
- "@dxos/react-ui-attention": "workspace:*",
112
- "@dxos/react-ui-canvas-compute": "workspace:*",
113
- "@dxos/react-ui-canvas-editor": "workspace:*",
114
- "@dxos/react-ui-form": "workspace:*",
115
- "@dxos/react-ui-introspect": "workspace:*",
116
- "@dxos/react-ui-syntax-highlighter": "workspace:*",
117
- "@dxos/react-ui-table": "workspace:*",
118
- "@dxos/schema": "workspace:*",
119
- "@dxos/tracing": "workspace:*",
120
- "@dxos/types": "workspace:*",
121
- "@dxos/util": "workspace:*",
122
- "@effect-atom/atom-react": "catalog:",
123
- "@tldraw/tldraw": "catalog:",
124
- "react-resize-detector": "catalog:"
79
+ "@antv/graphlib": "^2.0.4",
80
+ "@antv/layout": "^1.2.13",
81
+ "@tldraw/tldraw": "^3.0.0",
82
+ "react-resize-detector": "^11.0.1",
83
+ "@dxos/app-framework": "0.11.1",
84
+ "@dxos/app-toolkit": "0.11.1",
85
+ "@dxos/assistant-toolkit": "0.11.1",
86
+ "@dxos/client-services": "0.11.1",
87
+ "@dxos/compute": "0.11.1",
88
+ "@dxos/async": "0.11.1",
89
+ "@dxos/compute-hyperformula": "0.11.1",
90
+ "@dxos/conductor": "0.11.1",
91
+ "@dxos/config": "0.11.1",
92
+ "@dxos/devtools": "0.11.1",
93
+ "@dxos/echo": "0.11.1",
94
+ "@dxos/echo-host": "0.11.1",
95
+ "@dxos/effect": "0.11.1",
96
+ "@dxos/invariant": "0.11.1",
97
+ "@dxos/keys": "0.11.1",
98
+ "@dxos/log": "0.11.1",
99
+ "@dxos/log-store-idb": "0.11.1",
100
+ "@dxos/operation": "0.11.1",
101
+ "@dxos/plugin-client": "0.11.1",
102
+ "@dxos/plugin-graph": "0.11.1",
103
+ "@dxos/plugin-inbox": "0.11.1",
104
+ "@dxos/plugin-markdown": "0.11.1",
105
+ "@dxos/plugin-script": "0.11.1",
106
+ "@dxos/plugin-sheet": "0.11.1",
107
+ "@dxos/plugin-space": "0.11.1",
108
+ "@dxos/plugin-status-bar": "0.11.1",
109
+ "@dxos/protocols": "0.11.1",
110
+ "@dxos/random": "0.11.1",
111
+ "@dxos/react-client": "0.11.1",
112
+ "@dxos/react-ui-attention": "0.11.1",
113
+ "@dxos/react-ui-canvas-compute": "0.11.1",
114
+ "@dxos/react-ui-canvas-editor": "0.11.1",
115
+ "@dxos/react-ui-form": "0.11.1",
116
+ "@dxos/react-ui-introspect": "0.11.1",
117
+ "@dxos/react-ui-syntax-highlighter": "0.11.1",
118
+ "@dxos/react-ui-table": "0.11.1",
119
+ "@dxos/schema": "0.11.1",
120
+ "@dxos/tracing": "0.11.1",
121
+ "@dxos/types": "0.11.1",
122
+ "@dxos/util": "0.11.1"
125
123
  },
126
124
  "devDependencies": {
127
- "@dxos/plugin-testing": "workspace:*",
128
- "@dxos/react-ui": "workspace:*",
129
- "@dxos/storybook-utils": "workspace:*",
130
- "@dxos/ui-theme": "workspace:*",
131
- "@effect-atom/atom-react": "catalog:",
132
- "@effect/platform": "catalog:",
133
- "@types/react": "catalog:",
134
- "@types/react-dom": "catalog:",
135
- "effect": "catalog:",
136
- "react": "catalog:",
137
- "react-dom": "catalog:",
138
- "vite": "catalog:"
125
+ "@effect-atom/atom-react": "^0.5.0",
126
+ "@effect/platform": "0.96.2",
127
+ "@types/react": "~19.2.17",
128
+ "@types/react-dom": "~19.2.3",
129
+ "effect": "3.21.4",
130
+ "react": "~19.2.7",
131
+ "react-dom": "~19.2.7",
132
+ "vite": "^8.1.4",
133
+ "@dxos/plugin-testing": "0.11.1",
134
+ "@dxos/react-ui": "0.11.1",
135
+ "@dxos/storybook-utils": "0.11.1",
136
+ "@dxos/ui-theme": "0.11.1"
139
137
  },
140
138
  "peerDependencies": {
141
- "@dxos/random": "workspace:*",
142
- "@dxos/react-ui": "workspace:*",
143
- "@dxos/ui-theme": "workspace:*",
144
- "@effect-atom/atom-react": "catalog:",
145
- "@effect/platform": "catalog:",
146
- "effect": "catalog:",
147
- "react": "catalog:",
148
- "react-dom": "catalog:"
139
+ "@effect-atom/atom-react": "^0.5.0",
140
+ "@effect/platform": "0.96.2",
141
+ "effect": "3.21.4",
142
+ "react": "~19.2.7",
143
+ "react-dom": "~19.2.7",
144
+ "@dxos/random": "0.11.1",
145
+ "@dxos/react-ui": "0.11.1",
146
+ "@dxos/ui-theme": "0.11.1"
149
147
  },
150
148
  "publishConfig": {
151
149
  "access": "public"
152
150
  }
153
- }
151
+ }
@@ -40,7 +40,7 @@ const setupDevtools = () => {
40
40
 
41
41
  // Used to test how composer handles breaking protocol changes.
42
42
  (globalThis as any).composer.changeStorageVersionInMetadata = async (version: number) => {
43
- const { changeStorageVersionInMetadata } = await import('@dxos/echo-host/testing');
43
+ const { changeStorageVersionInMetadata } = await import('@dxos/client-services/testing');
44
44
  const { createStorageObjects } = await import('@dxos/client-services');
45
45
  const client: Client = (window as any).dxos.client;
46
46
  const config = client.config;
@@ -0,0 +1,100 @@
1
+ //
2
+ // Copyright 2025 DXOS.org
3
+ //
4
+
5
+ // Surface components that cannot be expressed as a `props` mapper, because they call hooks.
6
+
7
+ import React, { type ComponentType, useCallback } from 'react';
8
+
9
+ import { useOperationInvoker } from '@dxos/app-framework/ui';
10
+ import { GraphPath, LayoutOperation } from '@dxos/app-toolkit';
11
+ import { useActiveSpace } from '@dxos/app-toolkit/ui';
12
+ import { InvocationTraceContainer, SpaceInfoPanel, SpaceListPanel, TestingPanel } from '@dxos/devtools';
13
+ import { Feed } from '@dxos/echo';
14
+ import { log } from '@dxos/log';
15
+ import { ScriptOperation } from '@dxos/plugin-script';
16
+ import { SpaceOperation } from '@dxos/plugin-space';
17
+ import { type Space } from '@dxos/react-client/echo';
18
+
19
+ import { Devtools } from '#types';
20
+
21
+ export type ActiveSpacePanelProps = {
22
+ /** Stable module-level panel component; the surface passes it through its `props` mapper. */
23
+ Panel: ComponentType<{ space: Space }>;
24
+ };
25
+
26
+ /**
27
+ * Most devtools panels take the active space and render nothing without one. A mapper cannot read
28
+ * the active space (it is a hook) nor decline to render, so they share this wrapper.
29
+ */
30
+ export const ActiveSpacePanel = ({ Panel }: ActiveSpacePanelProps) => {
31
+ const space = useActiveSpace();
32
+
33
+ return space ? <Panel space={space} /> : null;
34
+ };
35
+
36
+ export const SpaceListSurface = () => {
37
+ const { invokePromise } = useOperationInvoker();
38
+ const handleSelect = useCallback(
39
+ () => invokePromise(LayoutOperation.Open, { subject: [Devtools.Echo.Space] }),
40
+ [invokePromise],
41
+ );
42
+
43
+ return <SpaceListPanel onSelect={handleSelect} />;
44
+ };
45
+
46
+ export const SpaceInfoSurface = () => {
47
+ const space = useActiveSpace();
48
+ const { invokePromise } = useOperationInvoker();
49
+ const handleSelect = useCallback(
50
+ () => invokePromise(LayoutOperation.Open, { subject: [Devtools.Echo.Feeds] }),
51
+ [invokePromise],
52
+ );
53
+ if (!space) {
54
+ return null;
55
+ }
56
+
57
+ return <SpaceInfoPanel space={space} onSelectFeed={handleSelect} onSelectPipeline={handleSelect} />;
58
+ };
59
+
60
+ export const EdgeTracesSurface = () => {
61
+ const space = useActiveSpace();
62
+ if (!space) {
63
+ return null;
64
+ }
65
+
66
+ const feed = space.properties.invocationTraceFeed?.target;
67
+ const feedDXN = feed ? Feed.getFeedUri(feed) : undefined;
68
+
69
+ return <InvocationTraceContainer db={space.db} feedDXN={feedDXN} detailAxis='block' />;
70
+ };
71
+
72
+ export const EdgeTestingSurface = () => {
73
+ const { invokePromise } = useOperationInvoker();
74
+ const onSpaceCreate = useCallback(
75
+ async (space: Space) => {
76
+ await space.waitUntilReady();
77
+ await invokePromise(SpaceOperation.Migrate, { space });
78
+ await space.db.flush();
79
+ },
80
+ [invokePromise],
81
+ );
82
+ const onScriptPluginOpen = useCallback(
83
+ async (space: Space) => {
84
+ await space.waitUntilReady();
85
+ const createResult = await invokePromise(ScriptOperation.CreateScript, { db: space.db });
86
+ if (createResult.data?.object) {
87
+ await invokePromise(SpaceOperation.AddObject, { target: space.db, object: createResult.data.object });
88
+ }
89
+ log.info('script created', { result: createResult });
90
+ if (createResult.data?.object) {
91
+ await invokePromise(LayoutOperation.Open, {
92
+ subject: [GraphPath.getObjectPathFromObject(createResult.data.object)],
93
+ });
94
+ }
95
+ },
96
+ [invokePromise],
97
+ );
98
+
99
+ return <TestingPanel onSpaceCreate={onSpaceCreate} onScriptPluginOpen={onScriptPluginOpen} />;
100
+ };
@@ -5,7 +5,7 @@
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
10
  import { type Space } from '@dxos/react-client/echo';
11
11
  import { Position } from '@dxos/util';
@@ -37,7 +37,7 @@ export default Capability.makeModule(
37
37
 
38
38
  GraphBuilder.createExtension({
39
39
  id: 'devtools',
40
- match: NodeMatcher.whenAny(NodeMatcher.whenRoot, AppNodeMatcher.whenNavTreeGroup(Paths.GroupTypes.system)),
40
+ match: NodeMatcher.whenAny(NodeMatcher.whenRoot, AppNodeMatcher.whenNavTreeGroup(GraphPath.GroupTypes.system)),
41
41
  connector: (_nodeOrSpace: Node.Node | Space, get) =>
42
42
  Effect.gen(function* () {
43
43
  const [graph] = get(yield* Capability.atom(AppCapabilities.AppGraph));
@@ -112,7 +112,7 @@ export default Capability.makeModule(
112
112
  data: Devtools.Client.Logs,
113
113
  type: Devtools.id,
114
114
  properties: {
115
- label: ['logs.label', { ns: meta.profile.key }],
115
+ label: ['logging.label', { ns: meta.profile.key }],
116
116
  icon: 'ph--file-text--regular',
117
117
  },
118
118
  }),
@@ -0,0 +1,236 @@
1
+ //
2
+ // Copyright 2025 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 { AppSurface } from '@dxos/app-toolkit/ui';
10
+ import { EDGE_SERVICE_DEFAULTS, EdgeServiceName } from '@dxos/config';
11
+ import {
12
+ AutomergePanel,
13
+ ConfigPanel,
14
+ CredentialsPanel,
15
+ DeviceListPanel,
16
+ DiagnosticsPanel,
17
+ EdgeDashboardPanel,
18
+ FeedsPanel,
19
+ IdentityPanel,
20
+ KeyringPanel,
21
+ LoggingPanel,
22
+ MembersPanel,
23
+ MetadataPanel,
24
+ NetworkPanel,
25
+ ObjectsPanel,
26
+ QueuesPanel,
27
+ SchemaPanel,
28
+ SignalPanel,
29
+ SqlitePanel,
30
+ StoragePanel,
31
+ SwarmPanel,
32
+ WorkflowPanel,
33
+ } from '@dxos/devtools';
34
+ import { type Graph } from '@dxos/plugin-graph';
35
+ import { ToolsExplorer } from '@dxos/react-ui-introspect';
36
+
37
+ import { DebugGraph, DevtoolsOverviewContainer, RegistryPanel } from '#containers';
38
+ import { Devtools } from '#types';
39
+
40
+ import {
41
+ ActiveSpacePanel,
42
+ EdgeTestingSurface,
43
+ EdgeTracesSurface,
44
+ SpaceInfoSurface,
45
+ SpaceListSurface,
46
+ } from './DevtoolsSurfaces';
47
+
48
+ const MCP_SERVER_URL = EDGE_SERVICE_DEFAULTS[EdgeServiceName.Introspect];
49
+
50
+ type GraphDebug = {
51
+ graph: Graph.Graph;
52
+ root: string;
53
+ };
54
+
55
+ const isGraphDebug = (data: unknown): data is GraphDebug => {
56
+ if (typeof data !== 'object' || data === null || !('graph' in data) || !('root' in data)) {
57
+ return false;
58
+ }
59
+
60
+ const { graph, root } = data;
61
+ return (
62
+ typeof graph === 'object' &&
63
+ graph !== null &&
64
+ 'json' in graph &&
65
+ typeof graph.json === 'function' &&
66
+ typeof root === 'string'
67
+ );
68
+ };
69
+
70
+ export default Capability.makeModule(
71
+ Effect.fnUntraced(function* () {
72
+ return Capability.contributes(Capabilities.ReactSurface, [
73
+ Surface.create({
74
+ id: 'appGraph',
75
+ filter: AppSurface.subject(AppSurface.Article, isGraphDebug),
76
+ component: DebugGraph,
77
+ props: ({ data: { subject } }) => ({ graph: subject.graph, root: subject.root }),
78
+ }),
79
+ Surface.create({
80
+ id: 'toolsExplorer',
81
+ filter: AppSurface.literal(AppSurface.Article, Devtools.ToolsExplorer),
82
+ component: ToolsExplorer,
83
+ props: () => ({ serverUrl: MCP_SERVER_URL }),
84
+ }),
85
+ Surface.create({
86
+ id: 'registry',
87
+ filter: AppSurface.literal(AppSurface.Article, Devtools.Echo.Registry),
88
+ component: RegistryPanel,
89
+ }),
90
+ Surface.create({
91
+ id: 'devtoolsOverview',
92
+ filter: Surface.makeFilter(AppSurface.deckCompanion('devtoolsOverview')),
93
+ component: DevtoolsOverviewContainer,
94
+ }),
95
+
96
+ //
97
+ // Devtools
98
+ //
99
+
100
+ Surface.create({
101
+ id: 'client.config',
102
+ filter: AppSurface.literal(AppSurface.Article, Devtools.Client.Config),
103
+ component: ConfigPanel,
104
+ props: () => ({ vaultSelector: false }),
105
+ }),
106
+ Surface.create({
107
+ id: 'client.storage',
108
+ filter: AppSurface.literal(AppSurface.Article, Devtools.Client.Storage),
109
+ component: StoragePanel,
110
+ }),
111
+ Surface.create({
112
+ id: 'client.sqlite',
113
+ filter: AppSurface.literal(AppSurface.Article, Devtools.Client.Sqlite),
114
+ component: SqlitePanel,
115
+ }),
116
+ Surface.create({
117
+ id: 'client.logs',
118
+ filter: AppSurface.literal(AppSurface.Article, Devtools.Client.Logs),
119
+ component: LoggingPanel,
120
+ }),
121
+ Surface.create({
122
+ id: 'client.diagnostics',
123
+ filter: AppSurface.literal(AppSurface.Article, Devtools.Client.Diagnostics),
124
+ component: DiagnosticsPanel,
125
+ }),
126
+ Surface.create({
127
+ id: 'halo.identity',
128
+ filter: AppSurface.literal(AppSurface.Article, Devtools.Halo.Identity),
129
+ component: IdentityPanel,
130
+ }),
131
+ Surface.create({
132
+ id: 'halo.devices',
133
+ filter: AppSurface.literal(AppSurface.Article, Devtools.Halo.Devices),
134
+ component: DeviceListPanel,
135
+ }),
136
+ Surface.create({
137
+ id: 'halo.keyring',
138
+ filter: AppSurface.literal(AppSurface.Article, Devtools.Halo.Keyring),
139
+ component: KeyringPanel,
140
+ }),
141
+ Surface.create({
142
+ id: 'halo.credentials',
143
+ filter: AppSurface.literal(AppSurface.Article, Devtools.Halo.Credentials),
144
+ component: ActiveSpacePanel,
145
+ props: () => ({ Panel: CredentialsPanel }),
146
+ }),
147
+ Surface.create({
148
+ id: 'echo.spaces',
149
+ filter: AppSurface.literal(AppSurface.Article, Devtools.Echo.Spaces),
150
+ component: SpaceListSurface,
151
+ }),
152
+ Surface.create({
153
+ id: 'echo.space',
154
+ filter: AppSurface.literal(AppSurface.Article, Devtools.Echo.Space),
155
+ component: SpaceInfoSurface,
156
+ }),
157
+ Surface.create({
158
+ id: 'echo.feeds',
159
+ filter: AppSurface.literal(AppSurface.Article, Devtools.Echo.Feeds),
160
+ component: ActiveSpacePanel,
161
+ props: () => ({ Panel: FeedsPanel }),
162
+ }),
163
+ Surface.create({
164
+ id: 'echo.objects',
165
+ filter: AppSurface.literal(AppSurface.Article, Devtools.Echo.Objects),
166
+ component: ActiveSpacePanel,
167
+ props: () => ({ Panel: ObjectsPanel }),
168
+ }),
169
+ Surface.create({
170
+ id: 'echo.schema',
171
+ filter: AppSurface.literal(AppSurface.Article, Devtools.Echo.Schema),
172
+ component: ActiveSpacePanel,
173
+ props: () => ({ Panel: SchemaPanel }),
174
+ }),
175
+ Surface.create({
176
+ id: 'echo.automerge',
177
+ filter: AppSurface.literal(AppSurface.Article, Devtools.Echo.Automerge),
178
+ component: ActiveSpacePanel,
179
+ props: () => ({ Panel: AutomergePanel }),
180
+ }),
181
+ Surface.create({
182
+ id: 'echo.queues',
183
+ filter: AppSurface.literal(AppSurface.Article, Devtools.Echo.Queues),
184
+ component: QueuesPanel,
185
+ }),
186
+ Surface.create({
187
+ id: 'echo.members',
188
+ filter: AppSurface.literal(AppSurface.Article, Devtools.Echo.Members),
189
+ component: ActiveSpacePanel,
190
+ props: () => ({ Panel: MembersPanel }),
191
+ }),
192
+ Surface.create({
193
+ id: 'echo.metadata',
194
+ filter: AppSurface.literal(AppSurface.Article, Devtools.Echo.Metadata),
195
+ component: MetadataPanel,
196
+ }),
197
+ Surface.create({
198
+ id: 'mesh.signal',
199
+ filter: AppSurface.literal(AppSurface.Article, Devtools.Mesh.Signal),
200
+ component: SignalPanel,
201
+ }),
202
+ Surface.create({
203
+ id: 'mesh.swarm',
204
+ filter: AppSurface.literal(AppSurface.Article, Devtools.Mesh.Swarm),
205
+ component: SwarmPanel,
206
+ }),
207
+ Surface.create({
208
+ id: 'mesh.network',
209
+ filter: AppSurface.literal(AppSurface.Article, Devtools.Mesh.Network),
210
+ component: ActiveSpacePanel,
211
+ props: () => ({ Panel: NetworkPanel }),
212
+ }),
213
+ Surface.create({
214
+ id: 'edge.dashboard',
215
+ filter: AppSurface.literal(AppSurface.Article, Devtools.Edge.Dashboard),
216
+ component: EdgeDashboardPanel,
217
+ }),
218
+ Surface.create({
219
+ id: 'edge.workflows',
220
+ filter: AppSurface.literal(AppSurface.Article, Devtools.Edge.Workflows),
221
+ component: ActiveSpacePanel,
222
+ props: () => ({ Panel: WorkflowPanel }),
223
+ }),
224
+ Surface.create({
225
+ id: 'edge.traces',
226
+ filter: AppSurface.literal(AppSurface.Article, Devtools.Edge.Traces),
227
+ component: EdgeTracesSurface,
228
+ }),
229
+ Surface.create({
230
+ id: 'edge.testing',
231
+ filter: AppSurface.literal(AppSurface.Article, Devtools.Edge.Testing),
232
+ component: EdgeTestingSurface,
233
+ }),
234
+ ]);
235
+ }),
236
+ );
@@ -6,11 +6,22 @@ import React from 'react';
6
6
 
7
7
  import { Tree } from '@dxos/devtools';
8
8
  import { Graph } from '@dxos/plugin-graph';
9
+ import { Panel, ScrollArea } from '@dxos/react-ui';
9
10
 
10
11
  export type DebugGraphProps = { graph: Graph.Graph; root: string };
11
12
 
12
13
  export const DebugGraph = ({ graph, root }: DebugGraphProps) => {
13
- return <Tree data={Graph.toJSON(graph, root)} />;
14
+ return (
15
+ <Panel.Root>
16
+ <Panel.Content asChild>
17
+ <ScrollArea.Root orientation='all'>
18
+ <ScrollArea.Viewport>
19
+ <Tree data={Graph.toJSON(graph, root)} />
20
+ </ScrollArea.Viewport>
21
+ </ScrollArea.Root>
22
+ </Panel.Content>
23
+ </Panel.Root>
24
+ );
14
25
  };
15
26
 
16
27
  DebugGraph.displayName = 'DebugGraph';
@@ -13,7 +13,7 @@ import { GithubComponent } from './GithubComponent';
13
13
 
14
14
  const DefaultStory = () => (
15
15
  <GithubComponent.Root>
16
- <div className='grid grid-rows-[auto_minmax(0,1fr)_auto] overflow-hidden h-full is-full'>
16
+ <div className='grid grid-rows-[auto_minmax(0,1fr)_auto] overflow-hidden h-full w-full'>
17
17
  <GithubComponent.Header />
18
18
  <GithubComponent.Content />
19
19
  <GithubComponent.StatusBar />
@@ -93,7 +93,7 @@ const Header = () => {
93
93
  const { t } = useTranslation(meta.profile.key);
94
94
  const { repo, pulls, unavailable } = useComponentContext();
95
95
  return (
96
- <header className='flex items-center justify-between gap-1 px-4 py-3 bg-modal-surface border-b border-subdued-separator'>
96
+ <header className='flex items-center justify-between gap-1 px-4 py-3 dx-modal-surface border-b border-subdued-separator'>
97
97
  <a
98
98
  href={`https://github.com/${repo}`}
99
99
  target='_blank'
@@ -8,7 +8,7 @@ import { GithubComponent } from './GithubComponent';
8
8
 
9
9
  export const GithubPanel = () => (
10
10
  <GithubComponent.Root>
11
- <div className='h-full grid grid-rows-[auto_minmax(0,1fr)_auto] overflow-hidden h-full is-full'>
11
+ <div className='h-full grid grid-rows-[auto_minmax(0,1fr)_auto] overflow-hidden h-full w-full'>
12
12
  <GithubComponent.Header />
13
13
  <GithubComponent.Content />
14
14
  <GithubComponent.StatusBar />