@dxos/plugin-debug 0.8.3 → 0.8.4-main.1068cf700f
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/lib/browser/DebugGraph-6VMEOKEV.mjs +15 -0
- package/dist/lib/browser/DebugGraph-6VMEOKEV.mjs.map +7 -0
- package/dist/lib/browser/DevtoolsOverviewContainer-2C6XMJ3L.mjs +19 -0
- package/dist/lib/browser/DevtoolsOverviewContainer-2C6XMJ3L.mjs.map +7 -0
- package/dist/lib/browser/SpaceGenerator-W3LJORYT.mjs +1152 -0
- package/dist/lib/browser/SpaceGenerator-W3LJORYT.mjs.map +7 -0
- package/dist/lib/browser/app-graph-builder-DEBTVBQG.mjs +599 -0
- package/dist/lib/browser/app-graph-builder-DEBTVBQG.mjs.map +7 -0
- package/dist/lib/browser/{chunk-KS3YBEL7.mjs → chunk-4UFQXPP7.mjs} +13 -3
- package/dist/lib/browser/chunk-4UFQXPP7.mjs.map +7 -0
- package/dist/lib/browser/chunk-A5H5GRV6.mjs +20 -0
- package/dist/lib/browser/chunk-A5H5GRV6.mjs.map +7 -0
- package/dist/lib/browser/index.mjs +42 -46
- package/dist/lib/browser/index.mjs.map +4 -4
- package/dist/lib/browser/meta.json +1 -1
- package/dist/lib/browser/react-context-I3USIAF6.mjs +17 -0
- package/dist/lib/browser/react-context-I3USIAF6.mjs.map +7 -0
- package/dist/lib/browser/react-surface-FMVC5GPV.mjs +758 -0
- package/dist/lib/browser/react-surface-FMVC5GPV.mjs.map +7 -0
- package/dist/lib/browser/settings-SLTQJJNF.mjs +32 -0
- package/dist/lib/browser/settings-SLTQJJNF.mjs.map +7 -0
- package/dist/types/src/DebugPlugin.d.ts +2 -1
- package/dist/types/src/DebugPlugin.d.ts.map +1 -1
- package/dist/types/src/capabilities/app-graph-builder/app-graph-builder.d.ts +6 -0
- package/dist/types/src/capabilities/app-graph-builder/app-graph-builder.d.ts.map +1 -0
- package/dist/types/src/capabilities/app-graph-builder/index.d.ts +3 -0
- package/dist/types/src/capabilities/app-graph-builder/index.d.ts.map +1 -0
- package/dist/types/src/capabilities/index.d.ts +4 -8
- package/dist/types/src/capabilities/index.d.ts.map +1 -1
- package/dist/types/src/capabilities/react-context/index.d.ts +7 -0
- package/dist/types/src/capabilities/react-context/index.d.ts.map +1 -0
- package/dist/types/src/capabilities/react-context/react-context.d.ts +10 -0
- package/dist/types/src/capabilities/react-context/react-context.d.ts.map +1 -0
- package/dist/types/src/capabilities/react-surface/index.d.ts +3 -0
- package/dist/types/src/capabilities/react-surface/index.d.ts.map +1 -0
- package/dist/types/src/capabilities/react-surface/react-surface.d.ts +5 -0
- package/dist/types/src/capabilities/react-surface/react-surface.d.ts.map +1 -0
- package/dist/types/src/capabilities/settings/index.d.ts +3 -0
- package/dist/types/src/capabilities/settings/index.d.ts.map +1 -0
- package/dist/types/src/capabilities/settings/settings.d.ts +6 -0
- package/dist/types/src/capabilities/settings/settings.d.ts.map +1 -0
- package/dist/types/src/components/DebugGraph.d.ts +9 -0
- package/dist/types/src/components/DebugGraph.d.ts.map +1 -0
- package/dist/types/src/components/DebugObjectPanel.d.ts +1 -1
- package/dist/types/src/components/DebugObjectPanel.d.ts.map +1 -1
- package/dist/types/src/components/DebugSettings.d.ts +4 -2
- package/dist/types/src/components/DebugSettings.d.ts.map +1 -1
- package/dist/types/src/components/SpaceGenerator/ObjectGenerator.d.ts +6 -4
- package/dist/types/src/components/SpaceGenerator/ObjectGenerator.d.ts.map +1 -1
- package/dist/types/src/components/SpaceGenerator/SpaceGenerator.d.ts +1 -1
- package/dist/types/src/components/SpaceGenerator/SpaceGenerator.d.ts.map +1 -1
- package/dist/types/src/components/SpaceGenerator/SpaceGenerator.stories.d.ts +13 -4
- package/dist/types/src/components/SpaceGenerator/SpaceGenerator.stories.d.ts.map +1 -1
- package/dist/types/src/components/SpaceGenerator/draw-util.d.ts.map +1 -1
- package/dist/types/src/components/SpaceGenerator/presets.d.ts +5 -8
- package/dist/types/src/components/SpaceGenerator/presets.d.ts.map +1 -1
- package/dist/types/src/components/Wireframe.d.ts +2 -2
- package/dist/types/src/components/Wireframe.d.ts.map +1 -1
- package/dist/types/src/components/index.d.ts +4 -3
- package/dist/types/src/components/index.d.ts.map +1 -1
- package/dist/types/src/meta.d.ts +2 -3
- package/dist/types/src/meta.d.ts.map +1 -1
- package/dist/types/src/translations.d.ts +62 -60
- package/dist/types/src/translations.d.ts.map +1 -1
- package/dist/types/src/types.d.ts +6 -1
- package/dist/types/src/types.d.ts.map +1 -1
- package/dist/types/tsconfig.tsbuildinfo +1 -1
- package/package.json +79 -71
- package/src/DebugPlugin.tsx +19 -34
- package/src/capabilities/app-graph-builder/app-graph-builder.ts +421 -0
- package/src/capabilities/app-graph-builder/index.ts +7 -0
- package/src/capabilities/index.ts +4 -6
- package/src/capabilities/react-context/index.ts +7 -0
- package/src/capabilities/react-context/react-context.tsx +20 -0
- package/src/capabilities/react-surface/index.ts +7 -0
- package/src/capabilities/react-surface/react-surface.tsx +411 -0
- package/src/capabilities/settings/index.ts +7 -0
- package/src/capabilities/settings/settings.ts +31 -0
- package/src/components/DebugGraph.tsx +15 -0
- package/src/components/DebugObjectPanel.tsx +6 -9
- package/src/components/DebugSettings.tsx +109 -75
- package/src/components/DebugStatus.tsx +2 -2
- package/src/components/DevtoolsOverviewContainer.tsx +2 -2
- package/src/components/SpaceGenerator/ObjectGenerator.tsx +40 -41
- package/src/components/SpaceGenerator/SchemaTable.tsx +2 -2
- package/src/components/SpaceGenerator/SpaceGenerator.stories.tsx +17 -15
- package/src/components/SpaceGenerator/SpaceGenerator.tsx +41 -94
- package/src/components/SpaceGenerator/draw-util.ts +5 -5
- package/src/components/SpaceGenerator/presets.ts +537 -259
- package/src/components/Wireframe.tsx +6 -6
- package/src/components/index.ts +4 -1
- package/src/meta.ts +8 -7
- package/src/translations.ts +9 -5
- package/src/types.ts +9 -1
- package/dist/lib/browser/DebugApp-WSEJPCKY.mjs +0 -225
- package/dist/lib/browser/DebugApp-WSEJPCKY.mjs.map +0 -7
- package/dist/lib/browser/DevtoolsOverviewContainer-IIIWO77Q.mjs +0 -25
- package/dist/lib/browser/DevtoolsOverviewContainer-IIIWO77Q.mjs.map +0 -7
- package/dist/lib/browser/SpaceGenerator-VB6IB2LL.mjs +0 -1238
- package/dist/lib/browser/SpaceGenerator-VB6IB2LL.mjs.map +0 -7
- package/dist/lib/browser/app-graph-builder-6HHJMKVU.mjs +0 -597
- package/dist/lib/browser/app-graph-builder-6HHJMKVU.mjs.map +0 -7
- package/dist/lib/browser/chunk-47JOZTT2.mjs +0 -18
- package/dist/lib/browser/chunk-47JOZTT2.mjs.map +0 -7
- package/dist/lib/browser/chunk-KS3YBEL7.mjs.map +0 -7
- package/dist/lib/browser/react-context-ZQRD2WG2.mjs +0 -16
- package/dist/lib/browser/react-context-ZQRD2WG2.mjs.map +0 -7
- package/dist/lib/browser/react-surface-UI6OK73H.mjs +0 -768
- package/dist/lib/browser/react-surface-UI6OK73H.mjs.map +0 -7
- package/dist/lib/browser/settings-SXQWSIM4.mjs +0 -22
- package/dist/lib/browser/settings-SXQWSIM4.mjs.map +0 -7
- package/dist/types/src/capabilities/app-graph-builder.d.ts +0 -4
- package/dist/types/src/capabilities/app-graph-builder.d.ts.map +0 -1
- package/dist/types/src/capabilities/react-context.d.ts +0 -8
- package/dist/types/src/capabilities/react-context.d.ts.map +0 -1
- package/dist/types/src/capabilities/react-surface.d.ts +0 -4
- package/dist/types/src/capabilities/react-surface.d.ts.map +0 -1
- package/dist/types/src/capabilities/settings.d.ts +0 -4
- package/dist/types/src/capabilities/settings.d.ts.map +0 -1
- package/dist/types/src/components/DebugApp/DebugApp.d.ts +0 -6
- package/dist/types/src/components/DebugApp/DebugApp.d.ts.map +0 -1
- package/dist/types/src/components/DebugApp/Tree.d.ts +0 -18
- package/dist/types/src/components/DebugApp/Tree.d.ts.map +0 -1
- package/dist/types/src/components/DebugApp/index.d.ts +0 -3
- package/dist/types/src/components/DebugApp/index.d.ts.map +0 -1
- package/src/capabilities/app-graph-builder.ts +0 -457
- package/src/capabilities/react-context.tsx +0 -16
- package/src/capabilities/react-surface.tsx +0 -397
- package/src/capabilities/settings.ts +0 -19
- package/src/components/DebugApp/DebugApp.tsx +0 -77
- package/src/components/DebugApp/Tree.tsx +0 -103
- package/src/components/DebugApp/index.ts +0 -7
|
@@ -1,457 +0,0 @@
|
|
|
1
|
-
//
|
|
2
|
-
// Copyright 2025 DXOS.org
|
|
3
|
-
//
|
|
4
|
-
|
|
5
|
-
import { Rx } from '@effect-rx/rx-react';
|
|
6
|
-
import { Option, pipe } from 'effect';
|
|
7
|
-
|
|
8
|
-
import { contributes, Capabilities, type PluginContext } from '@dxos/app-framework';
|
|
9
|
-
import { Obj } from '@dxos/echo';
|
|
10
|
-
import { ATTENDABLE_PATH_SEPARATOR, DECK_COMPANION_TYPE, PLANK_COMPANION_TYPE } from '@dxos/plugin-deck/types';
|
|
11
|
-
import { createExtension, ROOT_ID, rxFromSignal } from '@dxos/plugin-graph';
|
|
12
|
-
import { getActiveSpace, SPACE_PLUGIN } from '@dxos/plugin-space';
|
|
13
|
-
|
|
14
|
-
import { DEBUG_PLUGIN } from '../meta';
|
|
15
|
-
import { Devtools } from '../types';
|
|
16
|
-
|
|
17
|
-
const DEVTOOLS_TYPE = 'dxos.org/plugin/debug/devtools';
|
|
18
|
-
|
|
19
|
-
export default (context: PluginContext) =>
|
|
20
|
-
contributes(Capabilities.AppGraphBuilder, [
|
|
21
|
-
// Devtools node.
|
|
22
|
-
createExtension({
|
|
23
|
-
id: 'dxos.org/plugin/debug/devtools',
|
|
24
|
-
connector: (node) =>
|
|
25
|
-
Rx.make((get) =>
|
|
26
|
-
pipe(
|
|
27
|
-
get(node),
|
|
28
|
-
Option.flatMap((node) =>
|
|
29
|
-
node.id === ROOT_ID || node.type === `${SPACE_PLUGIN}/settings` ? Option.some(node) : Option.none(),
|
|
30
|
-
),
|
|
31
|
-
Option.map((node) => {
|
|
32
|
-
const space = get(rxFromSignal(() => getActiveSpace(context)));
|
|
33
|
-
|
|
34
|
-
return [
|
|
35
|
-
{
|
|
36
|
-
id: `${Devtools.id}-${node.id}`,
|
|
37
|
-
data: null,
|
|
38
|
-
type: DEVTOOLS_TYPE,
|
|
39
|
-
properties: {
|
|
40
|
-
label: ['devtools label', { ns: DEBUG_PLUGIN }],
|
|
41
|
-
icon: 'ph--hammer--regular',
|
|
42
|
-
disposition: 'pin-end',
|
|
43
|
-
position: 'fallback',
|
|
44
|
-
},
|
|
45
|
-
nodes: [
|
|
46
|
-
...(space && node.type === `${SPACE_PLUGIN}/settings`
|
|
47
|
-
? [
|
|
48
|
-
{
|
|
49
|
-
id: `debug-${node.id}`,
|
|
50
|
-
type: 'dxos.org/plugin/debug/space',
|
|
51
|
-
data: { space, type: 'dxos.org/plugin/debug/space' },
|
|
52
|
-
properties: {
|
|
53
|
-
label: ['debug label', { ns: DEBUG_PLUGIN }],
|
|
54
|
-
icon: 'ph--bug--regular',
|
|
55
|
-
},
|
|
56
|
-
},
|
|
57
|
-
]
|
|
58
|
-
: []),
|
|
59
|
-
{
|
|
60
|
-
id: `${Devtools.Client.id}-${node.id}`,
|
|
61
|
-
data: null,
|
|
62
|
-
type: DEVTOOLS_TYPE,
|
|
63
|
-
properties: {
|
|
64
|
-
label: ['client label', { ns: DEBUG_PLUGIN }],
|
|
65
|
-
icon: 'ph--users--regular',
|
|
66
|
-
},
|
|
67
|
-
nodes: [
|
|
68
|
-
{
|
|
69
|
-
id: `${Devtools.Client.Config}-${node.id}`,
|
|
70
|
-
data: Devtools.Client.Config,
|
|
71
|
-
type: DEVTOOLS_TYPE,
|
|
72
|
-
properties: {
|
|
73
|
-
label: ['config label', { ns: DEBUG_PLUGIN }],
|
|
74
|
-
icon: 'ph--gear--regular',
|
|
75
|
-
},
|
|
76
|
-
},
|
|
77
|
-
{
|
|
78
|
-
id: `${Devtools.Client.Storage}-${node.id}`,
|
|
79
|
-
data: Devtools.Client.Storage,
|
|
80
|
-
type: DEVTOOLS_TYPE,
|
|
81
|
-
properties: {
|
|
82
|
-
label: ['storage label', { ns: DEBUG_PLUGIN }],
|
|
83
|
-
icon: 'ph--hard-drives--regular',
|
|
84
|
-
},
|
|
85
|
-
},
|
|
86
|
-
{
|
|
87
|
-
id: `${Devtools.Client.Logs}-${node.id}`,
|
|
88
|
-
data: Devtools.Client.Logs,
|
|
89
|
-
type: DEVTOOLS_TYPE,
|
|
90
|
-
properties: {
|
|
91
|
-
label: ['logs label', { ns: DEBUG_PLUGIN }],
|
|
92
|
-
icon: 'ph--file-text--regular',
|
|
93
|
-
},
|
|
94
|
-
},
|
|
95
|
-
{
|
|
96
|
-
id: `${Devtools.Client.Diagnostics}-${node.id}`,
|
|
97
|
-
data: Devtools.Client.Diagnostics,
|
|
98
|
-
type: DEVTOOLS_TYPE,
|
|
99
|
-
properties: {
|
|
100
|
-
label: ['diagnostics label', { ns: DEBUG_PLUGIN }],
|
|
101
|
-
icon: 'ph--chart-line--regular',
|
|
102
|
-
},
|
|
103
|
-
},
|
|
104
|
-
{
|
|
105
|
-
id: `${Devtools.Client.Tracing}-${node.id}`,
|
|
106
|
-
data: Devtools.Client.Tracing,
|
|
107
|
-
type: DEVTOOLS_TYPE,
|
|
108
|
-
properties: {
|
|
109
|
-
label: ['tracing label', { ns: DEBUG_PLUGIN }],
|
|
110
|
-
icon: 'ph--fire--regular',
|
|
111
|
-
},
|
|
112
|
-
},
|
|
113
|
-
],
|
|
114
|
-
},
|
|
115
|
-
{
|
|
116
|
-
id: `${Devtools.Halo.id}-${node.id}`,
|
|
117
|
-
data: null,
|
|
118
|
-
type: DEVTOOLS_TYPE,
|
|
119
|
-
properties: {
|
|
120
|
-
label: ['halo label', { ns: DEBUG_PLUGIN }],
|
|
121
|
-
icon: 'ph--identification-badge--regular',
|
|
122
|
-
},
|
|
123
|
-
nodes: [
|
|
124
|
-
{
|
|
125
|
-
id: `${Devtools.Halo.Identity}-${node.id}`,
|
|
126
|
-
data: Devtools.Halo.Identity,
|
|
127
|
-
type: DEVTOOLS_TYPE,
|
|
128
|
-
properties: {
|
|
129
|
-
label: ['identity label', { ns: DEBUG_PLUGIN }],
|
|
130
|
-
icon: 'ph--identification-badge--regular',
|
|
131
|
-
},
|
|
132
|
-
},
|
|
133
|
-
{
|
|
134
|
-
id: `${Devtools.Halo.Devices}-${node.id}`,
|
|
135
|
-
data: Devtools.Halo.Devices,
|
|
136
|
-
type: DEVTOOLS_TYPE,
|
|
137
|
-
properties: {
|
|
138
|
-
label: ['devices label', { ns: DEBUG_PLUGIN }],
|
|
139
|
-
icon: 'ph--devices--regular',
|
|
140
|
-
},
|
|
141
|
-
},
|
|
142
|
-
{
|
|
143
|
-
id: `${Devtools.Halo.Keyring}-${node.id}`,
|
|
144
|
-
data: Devtools.Halo.Keyring,
|
|
145
|
-
type: DEVTOOLS_TYPE,
|
|
146
|
-
properties: {
|
|
147
|
-
label: ['keyring label', { ns: DEBUG_PLUGIN }],
|
|
148
|
-
icon: 'ph--key--regular',
|
|
149
|
-
},
|
|
150
|
-
},
|
|
151
|
-
{
|
|
152
|
-
id: `${Devtools.Halo.Credentials}-${node.id}`,
|
|
153
|
-
data: Devtools.Halo.Credentials,
|
|
154
|
-
type: DEVTOOLS_TYPE,
|
|
155
|
-
properties: {
|
|
156
|
-
label: ['credentials label', { ns: DEBUG_PLUGIN }],
|
|
157
|
-
icon: 'ph--credit-card--regular',
|
|
158
|
-
},
|
|
159
|
-
},
|
|
160
|
-
],
|
|
161
|
-
},
|
|
162
|
-
{
|
|
163
|
-
id: `${Devtools.Echo.id}-${node.id}`,
|
|
164
|
-
data: null,
|
|
165
|
-
type: DEVTOOLS_TYPE,
|
|
166
|
-
properties: {
|
|
167
|
-
label: ['echo label', { ns: DEBUG_PLUGIN }],
|
|
168
|
-
icon: 'ph--database--regular',
|
|
169
|
-
},
|
|
170
|
-
nodes: [
|
|
171
|
-
{
|
|
172
|
-
id: `${Devtools.Echo.Spaces}-${node.id}`,
|
|
173
|
-
data: Devtools.Echo.Spaces,
|
|
174
|
-
type: DEVTOOLS_TYPE,
|
|
175
|
-
properties: {
|
|
176
|
-
label: ['spaces label', { ns: DEBUG_PLUGIN }],
|
|
177
|
-
icon: 'ph--graph--regular',
|
|
178
|
-
},
|
|
179
|
-
},
|
|
180
|
-
{
|
|
181
|
-
id: `${Devtools.Echo.Space}-${node.id}`,
|
|
182
|
-
data: Devtools.Echo.Space,
|
|
183
|
-
type: DEVTOOLS_TYPE,
|
|
184
|
-
properties: {
|
|
185
|
-
label: ['space label', { ns: DEBUG_PLUGIN }],
|
|
186
|
-
icon: 'ph--planet--regular',
|
|
187
|
-
},
|
|
188
|
-
},
|
|
189
|
-
{
|
|
190
|
-
id: `${Devtools.Echo.Feeds}-${node.id}`,
|
|
191
|
-
data: Devtools.Echo.Feeds,
|
|
192
|
-
type: DEVTOOLS_TYPE,
|
|
193
|
-
properties: {
|
|
194
|
-
label: ['feeds label', { ns: DEBUG_PLUGIN }],
|
|
195
|
-
icon: 'ph--list-bullets--regular',
|
|
196
|
-
},
|
|
197
|
-
},
|
|
198
|
-
{
|
|
199
|
-
id: `${Devtools.Echo.Objects}-${node.id}`,
|
|
200
|
-
data: Devtools.Echo.Objects,
|
|
201
|
-
type: DEVTOOLS_TYPE,
|
|
202
|
-
properties: {
|
|
203
|
-
label: ['objects label', { ns: DEBUG_PLUGIN }],
|
|
204
|
-
icon: 'ph--cube--regular',
|
|
205
|
-
},
|
|
206
|
-
},
|
|
207
|
-
{
|
|
208
|
-
id: `${Devtools.Echo.Schema}-${node.id}`,
|
|
209
|
-
data: Devtools.Echo.Schema,
|
|
210
|
-
type: DEVTOOLS_TYPE,
|
|
211
|
-
properties: {
|
|
212
|
-
label: ['schema label', { ns: DEBUG_PLUGIN }],
|
|
213
|
-
icon: 'ph--database--regular',
|
|
214
|
-
},
|
|
215
|
-
},
|
|
216
|
-
{
|
|
217
|
-
id: `${Devtools.Echo.Automerge}-${node.id}`,
|
|
218
|
-
data: Devtools.Echo.Automerge,
|
|
219
|
-
type: DEVTOOLS_TYPE,
|
|
220
|
-
properties: {
|
|
221
|
-
label: ['automerge label', { ns: DEBUG_PLUGIN }],
|
|
222
|
-
icon: 'ph--gear-six--regular',
|
|
223
|
-
},
|
|
224
|
-
},
|
|
225
|
-
{
|
|
226
|
-
id: `${Devtools.Echo.Queues}-${node.id}`,
|
|
227
|
-
data: Devtools.Echo.Queues,
|
|
228
|
-
type: DEVTOOLS_TYPE,
|
|
229
|
-
properties: {
|
|
230
|
-
label: ['queues label', { ns: DEBUG_PLUGIN }],
|
|
231
|
-
icon: 'ph--queue--regular',
|
|
232
|
-
},
|
|
233
|
-
},
|
|
234
|
-
{
|
|
235
|
-
id: `${Devtools.Echo.Members}-${node.id}`,
|
|
236
|
-
data: Devtools.Echo.Members,
|
|
237
|
-
type: DEVTOOLS_TYPE,
|
|
238
|
-
properties: {
|
|
239
|
-
label: ['members label', { ns: DEBUG_PLUGIN }],
|
|
240
|
-
icon: 'ph--users--regular',
|
|
241
|
-
},
|
|
242
|
-
},
|
|
243
|
-
{
|
|
244
|
-
id: `${Devtools.Echo.Metadata}-${node.id}`,
|
|
245
|
-
data: Devtools.Echo.Metadata,
|
|
246
|
-
type: DEVTOOLS_TYPE,
|
|
247
|
-
properties: {
|
|
248
|
-
label: ['metadata label', { ns: DEBUG_PLUGIN }],
|
|
249
|
-
icon: 'ph--hard-drive--regular',
|
|
250
|
-
},
|
|
251
|
-
},
|
|
252
|
-
],
|
|
253
|
-
},
|
|
254
|
-
{
|
|
255
|
-
id: `${Devtools.Mesh.id}-${node.id}`,
|
|
256
|
-
data: null,
|
|
257
|
-
type: DEVTOOLS_TYPE,
|
|
258
|
-
properties: {
|
|
259
|
-
label: ['mesh label', { ns: DEBUG_PLUGIN }],
|
|
260
|
-
icon: 'ph--graph--regular',
|
|
261
|
-
},
|
|
262
|
-
nodes: [
|
|
263
|
-
{
|
|
264
|
-
id: `${Devtools.Mesh.Signal}-${node.id}`,
|
|
265
|
-
data: Devtools.Mesh.Signal,
|
|
266
|
-
type: DEVTOOLS_TYPE,
|
|
267
|
-
properties: {
|
|
268
|
-
label: ['signal label', { ns: DEBUG_PLUGIN }],
|
|
269
|
-
icon: 'ph--wifi-high--regular',
|
|
270
|
-
},
|
|
271
|
-
},
|
|
272
|
-
{
|
|
273
|
-
id: `${Devtools.Mesh.Swarm}-${node.id}`,
|
|
274
|
-
data: Devtools.Mesh.Swarm,
|
|
275
|
-
type: DEVTOOLS_TYPE,
|
|
276
|
-
properties: {
|
|
277
|
-
label: ['swarm label', { ns: DEBUG_PLUGIN }],
|
|
278
|
-
icon: 'ph--users-three--regular',
|
|
279
|
-
},
|
|
280
|
-
},
|
|
281
|
-
{
|
|
282
|
-
id: `${Devtools.Mesh.Network}-${node.id}`,
|
|
283
|
-
data: Devtools.Mesh.Network,
|
|
284
|
-
type: DEVTOOLS_TYPE,
|
|
285
|
-
properties: {
|
|
286
|
-
label: ['network label', { ns: DEBUG_PLUGIN }],
|
|
287
|
-
icon: 'ph--polygon--regular',
|
|
288
|
-
},
|
|
289
|
-
},
|
|
290
|
-
],
|
|
291
|
-
},
|
|
292
|
-
// TODO(wittjosiah): Remove?
|
|
293
|
-
// {
|
|
294
|
-
// id: `${prefix}-${Devtools.Agent.id}`,
|
|
295
|
-
// data: null,
|
|
296
|
-
// type: DEVTOOLS_TYPE,
|
|
297
|
-
// properties: {
|
|
298
|
-
// label: ['agent label', { ns: DEBUG_PLUGIN }],
|
|
299
|
-
// icon: 'ph--robot--regular',
|
|
300
|
-
// },
|
|
301
|
-
// nodes: [
|
|
302
|
-
// {
|
|
303
|
-
// id: `${prefix}-${Devtools.Agent.Dashboard}`,
|
|
304
|
-
// data: Devtools.Agent.Dashboard,
|
|
305
|
-
// type: DEVTOOLS_TYPE,
|
|
306
|
-
// properties: {
|
|
307
|
-
// label: ['dashboard label', { ns: DEBUG_PLUGIN }],
|
|
308
|
-
// icon: 'ph--computer-tower--regular',
|
|
309
|
-
// },
|
|
310
|
-
// },
|
|
311
|
-
// ],
|
|
312
|
-
// },
|
|
313
|
-
{
|
|
314
|
-
id: `${Devtools.Edge.id}-${node.id}`,
|
|
315
|
-
data: null,
|
|
316
|
-
type: DEVTOOLS_TYPE,
|
|
317
|
-
properties: {
|
|
318
|
-
label: ['edge label', { ns: DEBUG_PLUGIN }],
|
|
319
|
-
icon: 'ph--cloud--regular',
|
|
320
|
-
},
|
|
321
|
-
nodes: [
|
|
322
|
-
{
|
|
323
|
-
id: `${Devtools.Edge.Dashboard}-${node.id}`,
|
|
324
|
-
data: Devtools.Edge.Dashboard,
|
|
325
|
-
type: DEVTOOLS_TYPE,
|
|
326
|
-
properties: {
|
|
327
|
-
label: ['dashboard label', { ns: DEBUG_PLUGIN }],
|
|
328
|
-
icon: 'ph--computer-tower--regular',
|
|
329
|
-
},
|
|
330
|
-
},
|
|
331
|
-
{
|
|
332
|
-
id: `${Devtools.Edge.Workflows}-${node.id}`,
|
|
333
|
-
data: Devtools.Edge.Workflows,
|
|
334
|
-
type: DEVTOOLS_TYPE,
|
|
335
|
-
properties: {
|
|
336
|
-
label: ['workflows label', { ns: DEBUG_PLUGIN }],
|
|
337
|
-
icon: 'ph--function--regular',
|
|
338
|
-
},
|
|
339
|
-
},
|
|
340
|
-
{
|
|
341
|
-
id: `${Devtools.Edge.Traces}-${node.id}`,
|
|
342
|
-
data: Devtools.Edge.Traces,
|
|
343
|
-
type: DEVTOOLS_TYPE,
|
|
344
|
-
properties: {
|
|
345
|
-
label: ['traces label', { ns: DEBUG_PLUGIN }],
|
|
346
|
-
icon: 'ph--line-segments--regular',
|
|
347
|
-
},
|
|
348
|
-
},
|
|
349
|
-
{
|
|
350
|
-
id: `${Devtools.Edge.Testing}-${node.id}`,
|
|
351
|
-
data: Devtools.Edge.Testing,
|
|
352
|
-
type: DEVTOOLS_TYPE,
|
|
353
|
-
properties: {
|
|
354
|
-
label: ['testing label', { ns: DEBUG_PLUGIN }],
|
|
355
|
-
icon: 'ph--flask--regular',
|
|
356
|
-
},
|
|
357
|
-
},
|
|
358
|
-
],
|
|
359
|
-
},
|
|
360
|
-
],
|
|
361
|
-
},
|
|
362
|
-
];
|
|
363
|
-
}),
|
|
364
|
-
Option.getOrElse(() => []),
|
|
365
|
-
),
|
|
366
|
-
),
|
|
367
|
-
}),
|
|
368
|
-
|
|
369
|
-
// Debug node.
|
|
370
|
-
createExtension({
|
|
371
|
-
id: 'dxos.org/plugin/debug/debug',
|
|
372
|
-
connector: (node) =>
|
|
373
|
-
Rx.make((get) =>
|
|
374
|
-
pipe(
|
|
375
|
-
get(node),
|
|
376
|
-
Option.flatMap((node) => (node.id === ROOT_ID ? Option.some(node) : Option.none())),
|
|
377
|
-
Option.flatMap(() => {
|
|
378
|
-
const [graph] = get(context.capabilities(Capabilities.AppGraph));
|
|
379
|
-
return graph ? Option.some(graph) : Option.none();
|
|
380
|
-
}),
|
|
381
|
-
Option.flatMap((graph) => {
|
|
382
|
-
// TODO(wittjosiah): Plank is currently blank. Remove?
|
|
383
|
-
// const settings = context
|
|
384
|
-
// .requestCapabilities(Capabilities.SettingsStore)[0]
|
|
385
|
-
// ?.getStore<DebugSettingsProps>(DEBUG_PLUGIN)?.value;
|
|
386
|
-
// return !!settings?.debug && node.id === 'root';
|
|
387
|
-
return Option.none();
|
|
388
|
-
}),
|
|
389
|
-
Option.map((graph) => [
|
|
390
|
-
{
|
|
391
|
-
id: 'dxos.org/plugin/debug/debug',
|
|
392
|
-
type: 'dxos.org/plugin/debug/debug',
|
|
393
|
-
data: { graph },
|
|
394
|
-
properties: {
|
|
395
|
-
label: ['debug label', { ns: DEBUG_PLUGIN }],
|
|
396
|
-
disposition: 'navigation',
|
|
397
|
-
icon: 'ph--bug--regular',
|
|
398
|
-
},
|
|
399
|
-
},
|
|
400
|
-
]),
|
|
401
|
-
Option.getOrElse(() => []),
|
|
402
|
-
),
|
|
403
|
-
),
|
|
404
|
-
}),
|
|
405
|
-
|
|
406
|
-
// Debug object companion.
|
|
407
|
-
createExtension({
|
|
408
|
-
id: `${DEBUG_PLUGIN}/debug-object`,
|
|
409
|
-
connector: (node) =>
|
|
410
|
-
Rx.make((get) =>
|
|
411
|
-
pipe(
|
|
412
|
-
get(node),
|
|
413
|
-
Option.flatMap((node) => (Obj.isObject(node.data) ? Option.some(node) : Option.none())),
|
|
414
|
-
Option.map((node) => [
|
|
415
|
-
{
|
|
416
|
-
id: [node.id, 'debug'].join(ATTENDABLE_PATH_SEPARATOR),
|
|
417
|
-
type: PLANK_COMPANION_TYPE,
|
|
418
|
-
data: 'debug',
|
|
419
|
-
properties: {
|
|
420
|
-
label: ['debug label', { ns: DEBUG_PLUGIN }],
|
|
421
|
-
icon: 'ph--bug--regular',
|
|
422
|
-
disposition: 'hidden',
|
|
423
|
-
position: 'fallback',
|
|
424
|
-
},
|
|
425
|
-
},
|
|
426
|
-
]),
|
|
427
|
-
Option.getOrElse(() => []),
|
|
428
|
-
),
|
|
429
|
-
),
|
|
430
|
-
}),
|
|
431
|
-
|
|
432
|
-
// Devtools deck companion.
|
|
433
|
-
createExtension({
|
|
434
|
-
id: `${DEBUG_PLUGIN}/devtools-overview`,
|
|
435
|
-
connector: (node) =>
|
|
436
|
-
Rx.make((get) =>
|
|
437
|
-
pipe(
|
|
438
|
-
get(node),
|
|
439
|
-
Option.flatMap((node) => (node.id === ROOT_ID ? Option.some(node) : Option.none())),
|
|
440
|
-
Option.map((node) => [
|
|
441
|
-
{
|
|
442
|
-
id: [node.id, 'devtools'].join(ATTENDABLE_PATH_SEPARATOR),
|
|
443
|
-
type: DECK_COMPANION_TYPE,
|
|
444
|
-
data: null,
|
|
445
|
-
properties: {
|
|
446
|
-
label: ['devtools overview label', { ns: DEBUG_PLUGIN }],
|
|
447
|
-
icon: 'ph--equalizer--regular',
|
|
448
|
-
disposition: 'hidden',
|
|
449
|
-
position: 'fallback',
|
|
450
|
-
},
|
|
451
|
-
},
|
|
452
|
-
]),
|
|
453
|
-
Option.getOrElse(() => []),
|
|
454
|
-
),
|
|
455
|
-
),
|
|
456
|
-
}),
|
|
457
|
-
]);
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
//
|
|
2
|
-
// Copyright 2025 DXOS.org
|
|
3
|
-
//
|
|
4
|
-
|
|
5
|
-
import React from 'react';
|
|
6
|
-
|
|
7
|
-
import { Capabilities, contributes } from '@dxos/app-framework';
|
|
8
|
-
import { DevtoolsContextProvider } from '@dxos/devtools';
|
|
9
|
-
|
|
10
|
-
import { DEBUG_PLUGIN } from '../meta';
|
|
11
|
-
|
|
12
|
-
export default () =>
|
|
13
|
-
contributes(Capabilities.ReactContext, {
|
|
14
|
-
id: DEBUG_PLUGIN,
|
|
15
|
-
context: ({ children }) => <DevtoolsContextProvider>{children}</DevtoolsContextProvider>,
|
|
16
|
-
});
|