@zenfg/inspector 0.1.0-beta.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 (123) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +74 -0
  3. package/dist/FrameGraphInspector.d.ts +153 -0
  4. package/dist/FrameGraphInspector.d.ts.map +1 -0
  5. package/dist/FrameGraphInspector.js +580 -0
  6. package/dist/FrameGraphInspector.js.map +1 -0
  7. package/dist/debugCaptureModel.d.ts +166 -0
  8. package/dist/debugCaptureModel.d.ts.map +1 -0
  9. package/dist/debugCaptureModel.js +364 -0
  10. package/dist/debugCaptureModel.js.map +1 -0
  11. package/dist/index.d.ts +17 -0
  12. package/dist/index.d.ts.map +1 -0
  13. package/dist/index.js +15 -0
  14. package/dist/index.js.map +1 -0
  15. package/dist/panelAliasAnalysis.d.ts +20 -0
  16. package/dist/panelAliasAnalysis.d.ts.map +1 -0
  17. package/dist/panelAliasAnalysis.js +113 -0
  18. package/dist/panelAliasAnalysis.js.map +1 -0
  19. package/dist/panelCytoscapeGraphRenderer.d.ts +71 -0
  20. package/dist/panelCytoscapeGraphRenderer.d.ts.map +1 -0
  21. package/dist/panelCytoscapeGraphRenderer.js +559 -0
  22. package/dist/panelCytoscapeGraphRenderer.js.map +1 -0
  23. package/dist/panelDiagnosticsView.d.ts +22 -0
  24. package/dist/panelDiagnosticsView.d.ts.map +1 -0
  25. package/dist/panelDiagnosticsView.js +123 -0
  26. package/dist/panelDiagnosticsView.js.map +1 -0
  27. package/dist/panelDomHelpers.d.ts +26 -0
  28. package/dist/panelDomHelpers.d.ts.map +1 -0
  29. package/dist/panelDomHelpers.js +129 -0
  30. package/dist/panelDomHelpers.js.map +1 -0
  31. package/dist/panelGraphLayout.d.ts +28 -0
  32. package/dist/panelGraphLayout.d.ts.map +1 -0
  33. package/dist/panelGraphLayout.js +223 -0
  34. package/dist/panelGraphLayout.js.map +1 -0
  35. package/dist/panelGraphRenderer.d.ts +20 -0
  36. package/dist/panelGraphRenderer.d.ts.map +1 -0
  37. package/dist/panelGraphRenderer.js +2 -0
  38. package/dist/panelGraphRenderer.js.map +1 -0
  39. package/dist/panelGraphScene.d.ts +98 -0
  40. package/dist/panelGraphScene.d.ts.map +1 -0
  41. package/dist/panelGraphScene.js +559 -0
  42. package/dist/panelGraphScene.js.map +1 -0
  43. package/dist/panelGraphView.d.ts +9 -0
  44. package/dist/panelGraphView.d.ts.map +1 -0
  45. package/dist/panelGraphView.js +88 -0
  46. package/dist/panelGraphView.js.map +1 -0
  47. package/dist/panelGraphVisuals.d.ts +38 -0
  48. package/dist/panelGraphVisuals.d.ts.map +1 -0
  49. package/dist/panelGraphVisuals.js +330 -0
  50. package/dist/panelGraphVisuals.js.map +1 -0
  51. package/dist/panelIcons.d.ts +4 -0
  52. package/dist/panelIcons.d.ts.map +1 -0
  53. package/dist/panelIcons.js +43 -0
  54. package/dist/panelIcons.js.map +1 -0
  55. package/dist/panelInspectorView.d.ts +33 -0
  56. package/dist/panelInspectorView.d.ts.map +1 -0
  57. package/dist/panelInspectorView.js +357 -0
  58. package/dist/panelInspectorView.js.map +1 -0
  59. package/dist/panelMemoryView.d.ts +21 -0
  60. package/dist/panelMemoryView.d.ts.map +1 -0
  61. package/dist/panelMemoryView.js +134 -0
  62. package/dist/panelMemoryView.js.map +1 -0
  63. package/dist/panelPassesView.d.ts +31 -0
  64. package/dist/panelPassesView.d.ts.map +1 -0
  65. package/dist/panelPassesView.js +183 -0
  66. package/dist/panelPassesView.js.map +1 -0
  67. package/dist/panelResourcesView.d.ts +19 -0
  68. package/dist/panelResourcesView.d.ts.map +1 -0
  69. package/dist/panelResourcesView.js +89 -0
  70. package/dist/panelResourcesView.js.map +1 -0
  71. package/dist/panelSelection.d.ts +5 -0
  72. package/dist/panelSelection.d.ts.map +1 -0
  73. package/dist/panelSelection.js +88 -0
  74. package/dist/panelSelection.js.map +1 -0
  75. package/dist/panelTypes.d.ts +40 -0
  76. package/dist/panelTypes.d.ts.map +1 -0
  77. package/dist/panelTypes.js +2 -0
  78. package/dist/panelTypes.js.map +1 -0
  79. package/dist/panelVisualTheme.d.ts +76 -0
  80. package/dist/panelVisualTheme.d.ts.map +1 -0
  81. package/dist/panelVisualTheme.js +39 -0
  82. package/dist/panelVisualTheme.js.map +1 -0
  83. package/dist/panelWorkbenchHelpers.d.ts +34 -0
  84. package/dist/panelWorkbenchHelpers.d.ts.map +1 -0
  85. package/dist/panelWorkbenchHelpers.js +162 -0
  86. package/dist/panelWorkbenchHelpers.js.map +1 -0
  87. package/dist/panelWorkbenchView.d.ts +77 -0
  88. package/dist/panelWorkbenchView.d.ts.map +1 -0
  89. package/dist/panelWorkbenchView.js +409 -0
  90. package/dist/panelWorkbenchView.js.map +1 -0
  91. package/dist/query.d.ts +11 -0
  92. package/dist/query.d.ts.map +1 -0
  93. package/dist/query.js +21 -0
  94. package/dist/query.js.map +1 -0
  95. package/dist/styles.d.ts +8 -0
  96. package/dist/styles.d.ts.map +1 -0
  97. package/dist/styles.js +1073 -0
  98. package/dist/styles.js.map +1 -0
  99. package/package.json +29 -0
  100. package/src/FrameGraphInspector.ts +632 -0
  101. package/src/debugCaptureModel.ts +583 -0
  102. package/src/index.ts +21 -0
  103. package/src/panelAliasAnalysis.ts +164 -0
  104. package/src/panelCytoscapeGraphRenderer.ts +617 -0
  105. package/src/panelDiagnosticsView.ts +160 -0
  106. package/src/panelDomHelpers.ts +151 -0
  107. package/src/panelGraphLayout.ts +281 -0
  108. package/src/panelGraphRenderer.ts +21 -0
  109. package/src/panelGraphScene.ts +787 -0
  110. package/src/panelGraphView.ts +108 -0
  111. package/src/panelGraphVisuals.ts +364 -0
  112. package/src/panelIcons.ts +56 -0
  113. package/src/panelInspectorView.ts +377 -0
  114. package/src/panelMemoryView.ts +154 -0
  115. package/src/panelPassesView.ts +222 -0
  116. package/src/panelResourcesView.ts +115 -0
  117. package/src/panelSelection.ts +99 -0
  118. package/src/panelTypes.ts +28 -0
  119. package/src/panelVisualTheme.ts +39 -0
  120. package/src/panelWorkbenchHelpers.ts +216 -0
  121. package/src/panelWorkbenchView.ts +465 -0
  122. package/src/query.ts +22 -0
  123. package/src/styles.ts +1076 -0
package/src/styles.ts ADDED
@@ -0,0 +1,1076 @@
1
+ import { FRAME_GRAPH_DEBUG_VISUAL_THEME, GRAPH_VISUAL_THEME } from './panelVisualTheme.ts';
2
+
3
+ const STYLE_ELEMENT_ID = 'zenfg-inspector-panel-styles';
4
+ const theme = FRAME_GRAPH_DEBUG_VISUAL_THEME;
5
+
6
+ const FRAME_GRAPH_DEBUG_PANEL_CSS = `
7
+ /* Tokens and workbench root */
8
+ .zenfg-inspector {
9
+ --fgd-canvas: ${theme.canvas};
10
+ --fgd-panel: var(--zenfg-inspector-background, ${theme.panel});
11
+ --fgd-surface: var(--zenfg-inspector-surface, ${theme.surface});
12
+ --fgd-surface-raised: var(--zenfg-inspector-surface-raised, ${theme.surfaceRaised});
13
+ --fgd-surface-hover: var(--zenfg-inspector-surface-hover, ${theme.surfaceHover});
14
+ --fgd-border: var(--zenfg-inspector-border, ${theme.border});
15
+ --fgd-border-subtle: var(--zenfg-inspector-border-subtle, rgba(180, 190, 202, 0.11));
16
+ --fgd-border-strong: var(--zenfg-inspector-border-strong, rgba(180, 190, 202, 0.28));
17
+ --fgd-text: var(--zenfg-inspector-text, ${theme.text});
18
+ --fgd-text-secondary: var(--zenfg-inspector-text-secondary, ${theme.textSecondary});
19
+ --fgd-muted: var(--zenfg-inspector-muted, ${theme.muted});
20
+ --fgd-accent: var(--zenfg-inspector-accent, ${theme.accent});
21
+ --fgd-accent-soft: var(--zenfg-inspector-accent-soft, rgba(56, 189, 248, 0.12));
22
+ --fgd-accent-hover: var(--zenfg-inspector-accent-hover, rgba(56, 189, 248, 0.18));
23
+ --fgd-success: var(--zenfg-inspector-success, ${theme.success});
24
+ --fgd-warning: var(--zenfg-inspector-warning, ${theme.warning});
25
+ --fgd-danger: var(--zenfg-inspector-danger, ${theme.danger});
26
+ --fgd-font-ui: var(--zenfg-inspector-font-ui, ${theme.fontUi});
27
+ --fgd-font-mono: var(--zenfg-inspector-font-mono, ${theme.fontMono});
28
+ position: relative;
29
+ display: block;
30
+ width: 100%;
31
+ height: 100%;
32
+ min-width: 0;
33
+ min-height: 0;
34
+ overflow: hidden;
35
+ color: var(--fgd-text);
36
+ background: var(--fgd-canvas);
37
+ font-family: var(--fgd-font-ui);
38
+ font-size: 12px;
39
+ line-height: 1.45;
40
+ color-scheme: dark;
41
+ container-name: zenfg-inspector;
42
+ container-type: inline-size;
43
+ }
44
+
45
+ .zenfg-inspector,
46
+ .zenfg-inspector * { box-sizing: border-box; }
47
+
48
+ .zenfg-inspector-body {
49
+ width: 100%;
50
+ height: 100%;
51
+ min-height: 0;
52
+ padding: 10px;
53
+ overflow: hidden;
54
+ border: 0;
55
+ border-radius: 0;
56
+ background: var(--zenfg-inspector-background, var(--fgd-panel));
57
+ }
58
+
59
+ .zenfg-inspector-content {
60
+ min-width: 0;
61
+ min-height: 0;
62
+ height: 100%;
63
+ overflow: hidden;
64
+ }
65
+
66
+ .zenfg-inspector-drop-overlay {
67
+ position: absolute;
68
+ z-index: 40;
69
+ inset: 10px;
70
+ display: grid;
71
+ place-content: center;
72
+ gap: 6px;
73
+ border: 2px dashed var(--fgd-accent);
74
+ border-radius: var(--zenfg-inspector-radius-md, 6px);
75
+ color: #bae6fd;
76
+ background: color-mix(in srgb, var(--fgd-canvas) 90%, transparent);
77
+ font: 600 13px/1.4 var(--fgd-font-ui);
78
+ text-align: center;
79
+ pointer-events: none;
80
+ }
81
+ .zenfg-inspector-drop-overlay[hidden] { display: none; }
82
+ .zenfg-inspector-drop-overlay > span { color: var(--fgd-muted); font-size: 11px; }
83
+
84
+ .zenfg-inspector-capture-summary[hidden],
85
+ .zenfg-inspector-command-status[hidden],
86
+ .zenfg-inspector-capture-action[hidden],
87
+ .zenfg-inspector-workbench-empty[hidden],
88
+ .zenfg-inspector-open-inspector[hidden],
89
+ .zenfg-inspector-inspector.unavailable,
90
+ .zenfg-inspector-view[hidden],
91
+ .zenfg-inspector-graph-status[hidden] { display: none !important; }
92
+
93
+ .zenfg-inspector-muted {
94
+ margin: 0;
95
+ color: var(--fgd-muted);
96
+ font: 11px/1.5 var(--fgd-font-ui);
97
+ }
98
+
99
+ .zenfg-inspector-control-icon {
100
+ display: block;
101
+ flex: 0 0 auto;
102
+ width: 14px;
103
+ height: 14px;
104
+ }
105
+
106
+ .zenfg-inspector-table-scroller,
107
+ .zenfg-inspector-memory-scroller,
108
+ .zenfg-inspector-diagnostics-scroller,
109
+ .zenfg-inspector-inspector-content,
110
+ .zenfg-inspector-workbench-tabs,
111
+ .zenfg-inspector-graph-legend {
112
+ scrollbar-width: thin;
113
+ scrollbar-color: rgba(180, 190, 202, 0.25) transparent;
114
+ }
115
+
116
+ /* Workbench and summary */
117
+ .zenfg-inspector-workbench {
118
+ display: grid;
119
+ grid-template-rows: auto minmax(0, 1fr);
120
+ gap: 8px;
121
+ height: 100%;
122
+ min-width: 0;
123
+ min-height: 0;
124
+ font-family: var(--fgd-font-ui);
125
+ }
126
+
127
+ .zenfg-inspector-capture-summary {
128
+ display: grid;
129
+ grid-template-columns: repeat(auto-fit, minmax(min(230px, 100%), 1fr));
130
+ align-content: start;
131
+ gap: 8px;
132
+ min-width: 0;
133
+ background: transparent;
134
+ }
135
+
136
+ .zenfg-inspector-capture-summary > section {
137
+ min-width: 0;
138
+ padding: 12px;
139
+ border: 1px solid var(--fgd-border-subtle);
140
+ border-radius: 6px;
141
+ background: var(--fgd-surface);
142
+ }
143
+
144
+ .zenfg-inspector-capture-summary h2 {
145
+ margin: 0 0 5px;
146
+ color: var(--fgd-text-secondary);
147
+ font-size: 10px;
148
+ font-weight: 700;
149
+ letter-spacing: 0.075em;
150
+ line-height: 1.2;
151
+ text-transform: uppercase;
152
+ }
153
+
154
+ .zenfg-inspector-capture-summary section > div {
155
+ display: grid;
156
+ grid-template-columns: auto minmax(0, 1fr);
157
+ gap: 8px;
158
+ min-width: 0;
159
+ font-size: 11px;
160
+ line-height: 1.5;
161
+ }
162
+
163
+ .zenfg-inspector-capture-summary span { color: var(--fgd-muted); white-space: nowrap; }
164
+ .zenfg-inspector-capture-summary strong {
165
+ min-width: 0;
166
+ overflow: hidden;
167
+ color: var(--fgd-text);
168
+ font: 600 11px/1.5 var(--fgd-font-mono);
169
+ text-align: right;
170
+ text-overflow: ellipsis;
171
+ white-space: nowrap;
172
+ }
173
+
174
+ /* Command bar, tabs, and controls */
175
+ .zenfg-inspector-workbench-command-bar {
176
+ position: relative;
177
+ display: grid;
178
+ grid-template-columns: auto minmax(0, 1fr) auto;
179
+ align-items: center;
180
+ min-width: 0;
181
+ border-bottom: 1px solid var(--fgd-border-subtle);
182
+ }
183
+ .zenfg-inspector-workbench-command-bar.branding-hidden {
184
+ grid-template-columns: minmax(0, 1fr) auto;
185
+ }
186
+
187
+ .zenfg-inspector-brand {
188
+ position: relative;
189
+ display: flex;
190
+ align-items: center;
191
+ min-width: 0;
192
+ min-height: 32px;
193
+ padding: 0 12px 0 4px;
194
+ overflow: hidden;
195
+ color: var(--fgd-text);
196
+ font: 700 12px/1 var(--fgd-font-ui);
197
+ letter-spacing: 0.015em;
198
+ text-overflow: ellipsis;
199
+ white-space: nowrap;
200
+ }
201
+ .zenfg-inspector-brand::after {
202
+ position: absolute;
203
+ top: 50%;
204
+ right: 0;
205
+ width: 1px;
206
+ height: 16px;
207
+ background: var(--fgd-border);
208
+ content: '';
209
+ transform: translateY(-50%);
210
+ }
211
+
212
+ .zenfg-inspector-workbench-tabs,
213
+ .zenfg-inspector-subtabs,
214
+ .zenfg-inspector-inspector-tabs {
215
+ display: flex;
216
+ align-items: end;
217
+ min-width: 0;
218
+ border-bottom: 1px solid var(--fgd-border-subtle);
219
+ }
220
+
221
+ .zenfg-inspector-workbench-tabs {
222
+ overflow-x: auto;
223
+ border-bottom: 0;
224
+ }
225
+
226
+ .zenfg-inspector-workbench-tabs > button,
227
+ .zenfg-inspector-subtabs > button,
228
+ .zenfg-inspector-inspector-tabs > button {
229
+ min-height: 32px;
230
+ padding: 6px 10px;
231
+ border: 0;
232
+ border-bottom: 2px solid transparent;
233
+ color: var(--fgd-muted);
234
+ background: transparent;
235
+ font: 600 12px/1 var(--fgd-font-ui);
236
+ white-space: nowrap;
237
+ cursor: pointer;
238
+ transition: color 120ms ease, background-color 120ms ease, border-color 120ms ease;
239
+ }
240
+
241
+ .zenfg-inspector-workbench-tabs > button:hover:not(:disabled),
242
+ .zenfg-inspector-subtabs > button:hover:not(:disabled),
243
+ .zenfg-inspector-inspector-tabs > button:hover:not(:disabled) {
244
+ color: var(--fgd-text-secondary);
245
+ background: rgba(180, 190, 202, 0.055);
246
+ }
247
+
248
+ .zenfg-inspector-workbench-tabs > button.active,
249
+ .zenfg-inspector-subtabs > button.active,
250
+ .zenfg-inspector-inspector-tabs > button.active {
251
+ border-bottom-color: var(--fgd-accent);
252
+ color: var(--fgd-text);
253
+ background: linear-gradient(to top, var(--fgd-accent-soft), transparent 55%);
254
+ }
255
+
256
+ .zenfg-inspector-workbench-tabs > button:disabled,
257
+ .zenfg-inspector-subtabs > button:disabled,
258
+ .zenfg-inspector-inspector-tabs > button:disabled { cursor: default; opacity: 0.42; }
259
+
260
+ .zenfg-inspector-workbench-actions {
261
+ display: flex;
262
+ align-items: center;
263
+ gap: 6px;
264
+ padding-left: 8px;
265
+ overflow-x: auto;
266
+ scrollbar-width: thin;
267
+ }
268
+
269
+ .zenfg-inspector-export-menu {
270
+ position: absolute;
271
+ z-index: 30;
272
+ top: calc(100% + 4px);
273
+ right: 0;
274
+ display: grid;
275
+ min-width: 142px;
276
+ padding: 4px;
277
+ border: 1px solid var(--fgd-border-strong);
278
+ border-radius: 6px;
279
+ background: var(--fgd-surface-raised);
280
+ box-shadow: 0 10px 24px rgba(0, 0, 0, 0.34);
281
+ }
282
+ .zenfg-inspector-export-menu[hidden] { display: none; }
283
+ .zenfg-inspector-export-menu > button {
284
+ padding: 7px 9px;
285
+ border: 0;
286
+ border-radius: 4px;
287
+ color: var(--fgd-text-secondary);
288
+ background: transparent;
289
+ font: 600 11px/1.2 var(--fgd-font-ui);
290
+ text-align: left;
291
+ cursor: pointer;
292
+ }
293
+ .zenfg-inspector-export-menu > button:hover:not(:disabled) {
294
+ color: var(--fgd-text);
295
+ background: var(--fgd-surface-hover);
296
+ }
297
+ .zenfg-inspector-export-menu > button:disabled { cursor: default; opacity: 0.46; }
298
+
299
+ .zenfg-inspector-workbench-actions > button,
300
+ .zenfg-inspector-graph-toolbar button,
301
+ .zenfg-inspector-group-toggle,
302
+ .zenfg-inspector-inspector-close {
303
+ display: inline-flex;
304
+ align-items: center;
305
+ justify-content: center;
306
+ gap: 6px;
307
+ height: 28px;
308
+ min-height: 28px;
309
+ padding: 0 9px;
310
+ border: 1px solid var(--fgd-border);
311
+ border-radius: 5px;
312
+ color: var(--fgd-text-secondary);
313
+ background: var(--fgd-surface);
314
+ font: 600 11px/1 var(--fgd-font-ui);
315
+ white-space: nowrap;
316
+ cursor: pointer;
317
+ transition: color 120ms ease, background-color 120ms ease, border-color 120ms ease;
318
+ }
319
+
320
+ .zenfg-inspector-workbench-actions > button:hover:not(:disabled),
321
+ .zenfg-inspector-graph-toolbar button:hover:not(:disabled),
322
+ .zenfg-inspector-group-toggle:hover:not(:disabled),
323
+ .zenfg-inspector-inspector-close:hover:not(:disabled) {
324
+ border-color: var(--fgd-border-strong);
325
+ color: var(--fgd-text);
326
+ background: var(--fgd-surface-hover);
327
+ }
328
+
329
+ .zenfg-inspector-workbench-actions > button[data-tone='accent'] {
330
+ border-color: rgba(56, 189, 248, 0.5);
331
+ color: #bae6fd;
332
+ background: var(--fgd-accent-soft);
333
+ }
334
+ .zenfg-inspector-workbench-actions > button[data-tone='accent']:hover:not(:disabled) {
335
+ border-color: var(--fgd-accent);
336
+ background: var(--fgd-accent-hover);
337
+ }
338
+ .zenfg-inspector-workbench-actions > button[data-tone='pending'] {
339
+ border-color: rgba(56, 189, 248, 0.42);
340
+ color: var(--fgd-text-secondary);
341
+ background: var(--fgd-accent-soft);
342
+ }
343
+ .zenfg-inspector-workbench-actions > button[data-tone='success'] {
344
+ border-color: rgba(52, 211, 153, 0.46);
345
+ color: var(--fgd-success);
346
+ background: rgba(52, 211, 153, 0.1);
347
+ }
348
+ .zenfg-inspector-workbench-actions > button:disabled { cursor: default; opacity: 0.46; }
349
+ .zenfg-inspector-workbench-actions > button[aria-busy='true']:disabled { opacity: 0.72; }
350
+
351
+ .zenfg-inspector-command-status {
352
+ max-width: 220px;
353
+ overflow: hidden;
354
+ color: var(--fgd-muted);
355
+ font: 11px/1.35 var(--fgd-font-ui);
356
+ text-overflow: ellipsis;
357
+ white-space: nowrap;
358
+ }
359
+ .zenfg-inspector-command-status[data-tone='error'] { color: var(--fgd-danger); }
360
+
361
+ .zenfg-inspector-control-icon[data-icon='spinner'],
362
+ button[aria-busy='true'] > .zenfg-inspector-control-icon {
363
+ animation: zenfg-inspector-spin 800ms linear infinite;
364
+ }
365
+ @keyframes zenfg-inspector-spin { to { transform: rotate(360deg); } }
366
+
367
+ .zenfg-inspector-workbench-tabs > button:focus-visible,
368
+ .zenfg-inspector-subtabs > button:focus-visible,
369
+ .zenfg-inspector-inspector-tabs > button:focus-visible,
370
+ .zenfg-inspector-workbench-actions > button:focus-visible,
371
+ .zenfg-inspector-graph-toolbar button:focus-visible,
372
+ .zenfg-inspector-group-toggle:focus-visible,
373
+ .zenfg-inspector-inspector-close:focus-visible,
374
+ .zenfg-inspector-relation-button:focus-visible,
375
+ .zenfg-inspector-view-toolbar input:focus-visible,
376
+ .zenfg-inspector-view-toolbar select:focus-visible {
377
+ outline: 2px solid var(--fgd-accent);
378
+ outline-offset: 1px;
379
+ }
380
+
381
+ /* Workspace and empty states */
382
+ .zenfg-inspector-overview-view {
383
+ padding: 12px;
384
+ overflow: auto;
385
+ background: var(--fgd-canvas);
386
+ }
387
+
388
+ .zenfg-inspector-workspace {
389
+ position: relative;
390
+ display: grid;
391
+ grid-template-columns: minmax(0, 1fr);
392
+ gap: 8px;
393
+ min-width: 0;
394
+ min-height: 0;
395
+ overflow: hidden;
396
+ }
397
+ .zenfg-inspector-workspace.inspector-open {
398
+ grid-template-columns: minmax(0, 1fr) minmax(360px, 28vw);
399
+ }
400
+
401
+ .zenfg-inspector-main {
402
+ display: grid;
403
+ grid-template: minmax(0, 1fr) / minmax(0, 1fr);
404
+ min-width: 0;
405
+ min-height: 0;
406
+ overflow: hidden;
407
+ }
408
+
409
+ .zenfg-inspector-workbench-empty {
410
+ grid-area: 1 / 1;
411
+ display: flex;
412
+ flex-direction: column;
413
+ align-items: center;
414
+ justify-content: center;
415
+ gap: 8px;
416
+ min-width: 0;
417
+ min-height: 0;
418
+ padding: 24px;
419
+ color: var(--fgd-muted);
420
+ font: 12px/1.5 var(--fgd-font-ui);
421
+ text-align: center;
422
+ }
423
+ .zenfg-inspector-workbench-empty > .zenfg-inspector-control-icon {
424
+ width: 22px;
425
+ height: 22px;
426
+ color: var(--fgd-text-secondary);
427
+ }
428
+ .zenfg-inspector-workbench-empty[data-state='error'] > .zenfg-inspector-control-icon { color: var(--fgd-danger); }
429
+ .zenfg-inspector-workbench-empty[data-state='capturing'] > .zenfg-inspector-control-icon { color: var(--fgd-accent); }
430
+ .zenfg-inspector-empty-message { max-width: 520px; }
431
+ .zenfg-inspector-empty-detail { color: color-mix(in srgb, var(--fgd-muted) 78%, transparent); font-size: 11px; }
432
+
433
+ .zenfg-inspector-view {
434
+ grid-area: 1 / 1;
435
+ min-width: 0;
436
+ min-height: 0;
437
+ overflow: hidden;
438
+ border: 1px solid var(--fgd-border-subtle);
439
+ border-radius: 6px;
440
+ background: var(--fgd-canvas);
441
+ }
442
+
443
+ .zenfg-inspector-view-toolbar {
444
+ display: flex;
445
+ flex: 0 0 auto;
446
+ flex-wrap: wrap;
447
+ align-items: center;
448
+ gap: 6px;
449
+ padding: 6px 8px;
450
+ border-bottom: 1px solid var(--fgd-border-subtle);
451
+ background: var(--fgd-surface);
452
+ }
453
+
454
+ .zenfg-inspector-view-toolbar input,
455
+ .zenfg-inspector-view-toolbar select {
456
+ min-width: 0;
457
+ height: 28px;
458
+ padding: 4px 8px;
459
+ border: 1px solid var(--fgd-border);
460
+ border-radius: 5px;
461
+ color: var(--fgd-text);
462
+ background: var(--fgd-panel);
463
+ font: 11px/1 var(--fgd-font-ui);
464
+ }
465
+ .zenfg-inspector-view-toolbar input { flex: 1 1 210px; }
466
+ .zenfg-inspector-view-toolbar input::placeholder { color: var(--fgd-muted); opacity: 0.86; }
467
+ .zenfg-inspector-view-toolbar select { flex: 0 1 auto; color-scheme: dark; }
468
+
469
+ .zenfg-inspector-passes-view,
470
+ .zenfg-inspector-resources-view { display: flex; flex-direction: column; }
471
+ .zenfg-inspector-subtabs,
472
+ .zenfg-inspector-inspector-tabs {
473
+ flex: 0 0 auto;
474
+ padding: 0 4px;
475
+ background: var(--fgd-panel);
476
+ }
477
+ .zenfg-inspector-subview { flex: 1 1 auto; min-height: 0; overflow: hidden; }
478
+
479
+ /* Tables and relations */
480
+ .zenfg-inspector-table-scroller {
481
+ width: 100%;
482
+ height: 100%;
483
+ min-height: 0;
484
+ overflow: auto;
485
+ }
486
+ .zenfg-inspector-workbench-table {
487
+ width: 100%;
488
+ min-width: 720px;
489
+ border-collapse: collapse;
490
+ font: 11px/1.45 var(--fgd-font-mono);
491
+ }
492
+ .zenfg-inspector-workbench-table th,
493
+ .zenfg-inspector-workbench-table td {
494
+ height: 30px;
495
+ max-width: 360px;
496
+ padding: 6px 10px;
497
+ border-bottom: 1px solid var(--fgd-border-subtle);
498
+ overflow: hidden;
499
+ text-align: left;
500
+ text-overflow: ellipsis;
501
+ white-space: nowrap;
502
+ }
503
+ .zenfg-inspector-workbench-table th {
504
+ position: sticky;
505
+ z-index: 2;
506
+ top: 0;
507
+ color: var(--fgd-muted);
508
+ background: var(--fgd-panel);
509
+ font: 650 10px/1.3 var(--fgd-font-ui);
510
+ letter-spacing: 0.025em;
511
+ }
512
+ .zenfg-inspector-workbench-table [data-column='numeric'] {
513
+ font-variant-numeric: tabular-nums;
514
+ text-align: right;
515
+ }
516
+ .zenfg-inspector-workbench-table [data-column='code'] { font-family: var(--fgd-font-mono); }
517
+ .zenfg-inspector-workbench-table tbody tr:hover td { background: rgba(180, 190, 202, 0.045); }
518
+
519
+ .zenfg-inspector-workbench-table tr.selected td,
520
+ .zenfg-inspector-diagnostic-list .selected,
521
+ .zenfg-inspector-memory-allocation.selected,
522
+ .zenfg-inspector-memory-resource.selected { background: var(--fgd-accent-soft); }
523
+ .zenfg-inspector-workbench-table tr.selected td:first-child { box-shadow: inset 2px 0 var(--fgd-accent); }
524
+
525
+ .zenfg-inspector-workbench-table td small {
526
+ display: block;
527
+ margin-top: 2px;
528
+ overflow: hidden;
529
+ color: var(--fgd-muted);
530
+ font: 10px/1.4 var(--fgd-font-ui);
531
+ text-overflow: ellipsis;
532
+ }
533
+
534
+ .zenfg-inspector-kind-label {
535
+ --fgd-kind-color: var(--fgd-muted);
536
+ display: inline-flex;
537
+ align-items: center;
538
+ gap: 6px;
539
+ max-width: 100%;
540
+ overflow: hidden;
541
+ color: var(--fgd-text-secondary);
542
+ text-overflow: ellipsis;
543
+ white-space: nowrap;
544
+ }
545
+ .zenfg-inspector-kind-label::before {
546
+ width: 6px;
547
+ height: 6px;
548
+ flex: 0 0 auto;
549
+ border: 1px solid color-mix(in srgb, var(--fgd-kind-color) 78%, white);
550
+ border-radius: 50%;
551
+ background: color-mix(in srgb, var(--fgd-kind-color) 72%, transparent);
552
+ content: '';
553
+ }
554
+ .zenfg-inspector-kind-label[data-kind='render'] { --fgd-kind-color: ${GRAPH_VISUAL_THEME.render.stroke}; }
555
+ .zenfg-inspector-kind-label[data-kind='compute'] { --fgd-kind-color: ${GRAPH_VISUAL_THEME.compute.stroke}; }
556
+ .zenfg-inspector-kind-label[data-kind='copy'] { --fgd-kind-color: ${GRAPH_VISUAL_THEME.copy.stroke}; }
557
+ .zenfg-inspector-kind-label[data-kind='clear-buffer'] { --fgd-kind-color: ${GRAPH_VISUAL_THEME.clear.stroke}; }
558
+ .zenfg-inspector-kind-label[data-kind='command'] { --fgd-kind-color: ${GRAPH_VISUAL_THEME.command.stroke}; }
559
+ .zenfg-inspector-kind-label[data-kind='external-submission'] { --fgd-kind-color: ${GRAPH_VISUAL_THEME.external.stroke}; }
560
+ .zenfg-inspector-kind-label[data-kind='opaque'] { --fgd-kind-color: ${GRAPH_VISUAL_THEME.external.stroke}; }
561
+ .zenfg-inspector-kind-label[data-kind='texture'] { --fgd-kind-color: ${GRAPH_VISUAL_THEME.texture.stroke}; }
562
+ .zenfg-inspector-kind-label[data-kind='buffer'] { --fgd-kind-color: ${GRAPH_VISUAL_THEME.buffer.stroke}; }
563
+ .zenfg-inspector-kind-label[data-kind='frame-graph'] { --fgd-kind-color: var(--fgd-accent); }
564
+ .zenfg-inspector-kind-label[data-kind='timed'] { --fgd-kind-color: var(--fgd-success); }
565
+ .zenfg-inspector-kind-label[data-kind='not-timed'] { --fgd-kind-color: var(--fgd-muted); }
566
+
567
+ .zenfg-inspector-relation-button {
568
+ max-width: 100%;
569
+ padding: 0;
570
+ border: 0;
571
+ color: #a5def6;
572
+ background: transparent;
573
+ font: inherit;
574
+ text-align: left;
575
+ text-overflow: ellipsis;
576
+ white-space: nowrap;
577
+ cursor: pointer;
578
+ }
579
+ .zenfg-inspector-relation-button:hover {
580
+ color: #d5f3ff;
581
+ text-decoration: underline;
582
+ text-underline-offset: 2px;
583
+ }
584
+ .zenfg-inspector-group-toggle { width: 28px; padding: 0; color: var(--fgd-text-secondary); }
585
+ .zenfg-inspector-empty-row {
586
+ height: 60px !important;
587
+ color: var(--fgd-muted);
588
+ font-family: var(--fgd-font-ui);
589
+ text-align: center !important;
590
+ }
591
+
592
+ /* Graph */
593
+ .zenfg-inspector-graph-view { display: flex; flex-direction: column; }
594
+ .zenfg-inspector-graph-toolbar {
595
+ display: grid;
596
+ grid-template-columns: auto minmax(0, 1fr) auto;
597
+ align-items: center;
598
+ gap: 10px;
599
+ min-width: 0;
600
+ min-height: 38px;
601
+ padding: 5px 6px;
602
+ border-bottom: 1px solid var(--fgd-border-subtle);
603
+ background: var(--fgd-surface);
604
+ }
605
+ .zenfg-inspector-graph-mode-controls,
606
+ .zenfg-inspector-graph-action-controls { display: flex; align-items: center; min-width: 0; }
607
+ .zenfg-inspector-graph-action-controls { gap: 4px; }
608
+ .zenfg-inspector-graph-toolbar .zenfg-inspector-mode-button {
609
+ margin-right: -1px;
610
+ border-radius: 0;
611
+ }
612
+ .zenfg-inspector-graph-toolbar .zenfg-inspector-mode-button:first-child { border-radius: 5px 0 0 5px; }
613
+ .zenfg-inspector-graph-toolbar .zenfg-inspector-mode-button:last-child {
614
+ margin-right: 0;
615
+ border-radius: 0 5px 5px 0;
616
+ }
617
+ .zenfg-inspector-graph-toolbar button.active,
618
+ .zenfg-inspector-graph-toolbar button[aria-pressed='true'] {
619
+ z-index: 1;
620
+ border-color: rgba(56, 189, 248, 0.6);
621
+ color: var(--fgd-accent);
622
+ background: var(--fgd-accent-soft);
623
+ }
624
+ .zenfg-inspector-graph-toolbar button:disabled { cursor: default; opacity: 0.42; }
625
+ .zenfg-inspector-graph-toolbar .zenfg-inspector-icon-button { width: 28px; padding: 0; }
626
+
627
+ .zenfg-inspector-graph-legend {
628
+ display: flex;
629
+ align-items: center;
630
+ gap: 10px;
631
+ min-width: 0;
632
+ padding: 2px 0;
633
+ overflow-x: auto;
634
+ color: var(--fgd-muted);
635
+ font: 10px/1 var(--fgd-font-ui);
636
+ white-space: nowrap;
637
+ }
638
+ .zenfg-inspector-legend-item { display: inline-flex; align-items: center; gap: 4px; flex: 0 0 auto; }
639
+ .zenfg-inspector-legend-swatch {
640
+ position: relative;
641
+ display: inline-block;
642
+ width: 10px;
643
+ height: 8px;
644
+ border: 1px solid var(--zenfg-inspector-legend-color);
645
+ border-radius: 2px;
646
+ background: color-mix(in srgb, var(--zenfg-inspector-legend-color) 20%, var(--fgd-canvas));
647
+ }
648
+ .zenfg-inspector-legend-swatch[data-shape='ellipse'] { border-radius: 50%; }
649
+ .zenfg-inspector-legend-swatch[data-shape='group'] { border-style: double; background: transparent; }
650
+ .zenfg-inspector-legend-swatch[data-shape='line'] {
651
+ width: 16px;
652
+ height: 0;
653
+ border: 0;
654
+ border-top: 1px solid var(--zenfg-inspector-legend-color);
655
+ border-radius: 0;
656
+ background: transparent;
657
+ }
658
+ .zenfg-inspector-legend-swatch[data-shape='line'][data-line-style='dotted'] { border-top-style: dotted; }
659
+ .zenfg-inspector-legend-swatch[data-shape='line'][data-line-style='dashed'] { border-top-style: dashed; }
660
+ .zenfg-inspector-legend-swatch:not([data-shape='line'])[data-line-style='dashed'] { border-style: dashed; }
661
+ .zenfg-inspector-legend-swatch[data-shape='line']::after {
662
+ position: absolute;
663
+ top: -2px;
664
+ right: -1px;
665
+ width: 5px;
666
+ height: 4px;
667
+ background: var(--zenfg-inspector-legend-color);
668
+ clip-path: polygon(0 0, 100% 50%, 0 100%);
669
+ content: '';
670
+ }
671
+ .zenfg-inspector-legend-swatch[data-shape='line'][data-hollow-arrow='true']::after {
672
+ top: -3px;
673
+ width: 4px;
674
+ height: 4px;
675
+ border-top: 1px solid var(--zenfg-inspector-legend-color);
676
+ border-right: 1px solid var(--zenfg-inspector-legend-color);
677
+ background: transparent;
678
+ clip-path: none;
679
+ transform: rotate(45deg);
680
+ }
681
+
682
+ .zenfg-inspector-graph-view .zenfg-inspector-graph {
683
+ flex: 1 1 auto;
684
+ width: 100%;
685
+ height: auto;
686
+ min-height: 0;
687
+ border: 0;
688
+ }
689
+ .zenfg-inspector-graph {
690
+ position: relative;
691
+ width: 100%;
692
+ height: 260px;
693
+ min-height: 220px;
694
+ overflow: hidden;
695
+ border: 1px solid var(--fgd-border-subtle);
696
+ background: var(--fgd-canvas);
697
+ color: var(--fgd-muted);
698
+ font-size: 11px;
699
+ }
700
+ .zenfg-inspector-graph-canvas {
701
+ width: 100%;
702
+ height: 100%;
703
+ min-width: 0;
704
+ min-height: 0;
705
+ outline: none;
706
+ }
707
+ .zenfg-inspector-graph-status {
708
+ position: absolute;
709
+ inset: 0;
710
+ z-index: 2;
711
+ display: flex;
712
+ align-items: center;
713
+ justify-content: center;
714
+ gap: 8px;
715
+ padding: 16px;
716
+ color: var(--fgd-muted);
717
+ background: rgba(11, 15, 20, 0.82);
718
+ font: 12px/1.45 var(--fgd-font-ui);
719
+ text-align: center;
720
+ pointer-events: none;
721
+ }
722
+ .zenfg-inspector-graph-status[data-state='layout'] { background: rgba(11, 15, 20, 0.5); }
723
+ .zenfg-inspector-graph-status[data-state='error'] {
724
+ color: var(--fgd-text);
725
+ background: rgba(11, 15, 20, 0.94);
726
+ }
727
+ .zenfg-inspector-graph-status > span { max-width: min(560px, 80%); }
728
+ .zenfg-inspector-graph-status button {
729
+ height: 28px;
730
+ padding: 0 9px;
731
+ border: 1px solid rgba(56, 189, 248, 0.55);
732
+ border-radius: 5px;
733
+ color: var(--fgd-accent);
734
+ background: var(--fgd-accent-soft);
735
+ font: 600 11px/1 var(--fgd-font-ui);
736
+ cursor: pointer;
737
+ pointer-events: auto;
738
+ }
739
+ .zenfg-inspector-graph-tooltip {
740
+ position: absolute;
741
+ z-index: 3;
742
+ max-width: min(380px, calc(100% - 16px));
743
+ padding: 8px 10px;
744
+ border: 1px solid var(--fgd-border-strong);
745
+ border-radius: 6px;
746
+ color: var(--fgd-text);
747
+ background: var(--fgd-surface-raised);
748
+ box-shadow: 0 8px 24px rgba(0, 0, 0, 0.42);
749
+ font: 11px/1.5 var(--fgd-font-mono);
750
+ white-space: pre-wrap;
751
+ pointer-events: none;
752
+ }
753
+
754
+ /* Inspector */
755
+ .zenfg-inspector-inspector {
756
+ display: flex;
757
+ flex-direction: column;
758
+ min-width: 0;
759
+ min-height: 0;
760
+ overflow: hidden;
761
+ border: 1px solid var(--fgd-border);
762
+ border-radius: 6px;
763
+ background: var(--fgd-surface-raised);
764
+ box-shadow: -8px 0 28px rgba(0, 0, 0, 0.2);
765
+ }
766
+ .zenfg-inspector-inspector[hidden] { display: none; }
767
+ .zenfg-inspector-inspector > header {
768
+ display: flex;
769
+ flex: 0 0 auto;
770
+ align-items: center;
771
+ justify-content: space-between;
772
+ min-height: 36px;
773
+ padding: 0 8px 0 10px;
774
+ border-bottom: 1px solid var(--fgd-border-subtle);
775
+ background: var(--fgd-surface);
776
+ }
777
+ .zenfg-inspector-inspector > header strong {
778
+ min-width: 0;
779
+ overflow: hidden;
780
+ font: 600 11px/1.3 var(--fgd-font-mono);
781
+ text-overflow: ellipsis;
782
+ white-space: nowrap;
783
+ }
784
+ .zenfg-inspector-inspector-close {
785
+ width: 28px;
786
+ padding: 0;
787
+ border-color: transparent;
788
+ background: transparent;
789
+ }
790
+ .zenfg-inspector-inspector-content {
791
+ flex: 1 1 auto;
792
+ min-height: 0;
793
+ padding: 10px;
794
+ overflow: auto;
795
+ }
796
+ .zenfg-inspector-inspector-summary {
797
+ display: grid;
798
+ grid-template-columns: minmax(96px, auto) minmax(0, 1fr);
799
+ gap: 3px 12px;
800
+ margin: 0;
801
+ font-size: 11px;
802
+ line-height: 1.6;
803
+ }
804
+ .zenfg-inspector-inspector-summary dt { color: var(--fgd-muted); font-family: var(--fgd-font-ui); }
805
+ .zenfg-inspector-inspector-summary dd {
806
+ min-width: 0;
807
+ margin: 0;
808
+ color: var(--fgd-text);
809
+ font-family: var(--fgd-font-mono);
810
+ overflow-wrap: anywhere;
811
+ }
812
+ .zenfg-inspector-inspector-relations { display: grid; gap: 8px; }
813
+ .zenfg-inspector-inspector-relations section {
814
+ display: grid;
815
+ gap: 6px;
816
+ padding: 8px;
817
+ border: 1px solid var(--fgd-border-subtle);
818
+ border-radius: 5px;
819
+ background: var(--fgd-surface);
820
+ }
821
+ .zenfg-inspector-inspector-relations h3 {
822
+ margin: 0 0 2px;
823
+ color: var(--fgd-muted);
824
+ font: 700 10px/1.3 var(--fgd-font-ui);
825
+ letter-spacing: 0.055em;
826
+ text-transform: uppercase;
827
+ }
828
+ .zenfg-inspector-inspector-relations .zenfg-inspector-relation-button {
829
+ font: 11px/1.5 var(--fgd-font-mono);
830
+ overflow-wrap: anywhere;
831
+ white-space: normal;
832
+ }
833
+ .zenfg-inspector-inspector .zenfg-inspector-raw-detail {
834
+ min-width: 100%;
835
+ margin: 0;
836
+ overflow: auto;
837
+ color: var(--fgd-text-secondary);
838
+ font: 11px/1.55 var(--fgd-font-mono);
839
+ white-space: pre;
840
+ }
841
+
842
+ /* Memory */
843
+ .zenfg-inspector-memory-view {
844
+ display: grid;
845
+ grid-template-rows: auto minmax(0, 1fr);
846
+ }
847
+ .zenfg-inspector-memory-summary {
848
+ display: grid;
849
+ grid-template-columns: repeat(4, minmax(0, 1fr));
850
+ gap: 6px;
851
+ padding: 6px;
852
+ border-bottom: 1px solid var(--fgd-border-subtle);
853
+ background: var(--fgd-panel);
854
+ }
855
+ .zenfg-inspector-memory-summary > div {
856
+ display: grid;
857
+ gap: 3px;
858
+ min-width: 0;
859
+ padding: 6px 8px;
860
+ border: 1px solid var(--fgd-border-subtle);
861
+ border-radius: 5px;
862
+ background: var(--fgd-surface);
863
+ }
864
+ .zenfg-inspector-memory-summary span { color: var(--fgd-muted); font: 10px/1.3 var(--fgd-font-ui); }
865
+ .zenfg-inspector-memory-summary strong {
866
+ overflow: hidden;
867
+ font: 600 11px/1.35 var(--fgd-font-mono);
868
+ text-overflow: ellipsis;
869
+ white-space: nowrap;
870
+ }
871
+ .zenfg-inspector-memory-scroller { min-height: 0; overflow: auto; }
872
+ .zenfg-inspector-memory-timeline {
873
+ display: grid;
874
+ min-width: 760px;
875
+ padding: 8px;
876
+ font: 11px/1.4 var(--fgd-font-mono);
877
+ }
878
+ .zenfg-inspector-memory-axis,
879
+ .zenfg-inspector-memory-resource {
880
+ display: grid;
881
+ grid-template-columns: minmax(150px, 0.9fr) 72px minmax(320px, 2.4fr) 82px;
882
+ gap: 10px;
883
+ align-items: center;
884
+ min-height: 30px;
885
+ }
886
+ .zenfg-inspector-memory-axis {
887
+ position: sticky;
888
+ z-index: 2;
889
+ top: 0;
890
+ padding: 0 8px 6px;
891
+ color: var(--fgd-muted);
892
+ background: var(--fgd-canvas);
893
+ font: 10px/1.3 var(--fgd-font-ui);
894
+ }
895
+ .zenfg-inspector-memory-axis-track,
896
+ .zenfg-inspector-memory-track { position: relative; height: 16px; }
897
+ .zenfg-inspector-memory-axis-track { border-bottom: 1px solid var(--fgd-border-strong); }
898
+ .zenfg-inspector-memory-axis-track > span {
899
+ position: absolute;
900
+ bottom: -1px;
901
+ padding-bottom: 5px;
902
+ border-left: 1px solid var(--fgd-border-strong);
903
+ font: 10px/1 var(--fgd-font-mono);
904
+ transform: translateX(-1px);
905
+ }
906
+ .zenfg-inspector-memory-allocation {
907
+ display: flex;
908
+ align-items: center;
909
+ justify-content: space-between;
910
+ gap: 12px;
911
+ margin-top: 6px;
912
+ padding: 7px 8px;
913
+ border-top: 1px solid var(--fgd-border-subtle);
914
+ border-bottom: 1px solid var(--fgd-border-subtle);
915
+ background: var(--fgd-surface);
916
+ }
917
+ .zenfg-inspector-memory-allocation > span { color: var(--fgd-muted); font: 10px/1.35 var(--fgd-font-mono); }
918
+ .zenfg-inspector-memory-allocation.muted { color: var(--fgd-muted); font-family: var(--fgd-font-ui); }
919
+ .zenfg-inspector-memory-resource { padding: 0 8px; border-bottom: 1px solid var(--fgd-border-subtle); }
920
+ .zenfg-inspector-memory-resource.selected,
921
+ .zenfg-inspector-memory-allocation.selected { box-shadow: inset 2px 0 var(--fgd-accent); }
922
+ .zenfg-inspector-memory-bar {
923
+ position: absolute;
924
+ top: 4px;
925
+ height: 8px;
926
+ min-width: 2px;
927
+ border-radius: 4px;
928
+ background: color-mix(in srgb, ${GRAPH_VISUAL_THEME.texture.stroke} 76%, transparent);
929
+ box-shadow: 0 0 0 1px color-mix(in srgb, ${GRAPH_VISUAL_THEME.texture.stroke} 36%, transparent);
930
+ }
931
+ .zenfg-inspector-memory-bar.buffer {
932
+ background: color-mix(in srgb, ${GRAPH_VISUAL_THEME.buffer.stroke} 72%, transparent);
933
+ box-shadow: 0 0 0 1px color-mix(in srgb, ${GRAPH_VISUAL_THEME.buffer.stroke} 34%, transparent);
934
+ }
935
+ .zenfg-inspector-memory-bar.empty { display: none; }
936
+
937
+ /* Diagnostics */
938
+ .zenfg-inspector-diagnostics-scroller { width: 100%; height: 100%; overflow: auto; }
939
+ .zenfg-inspector-diagnostics-grid {
940
+ display: grid;
941
+ grid-template-columns: repeat(2, minmax(0, 1fr));
942
+ gap: 8px;
943
+ padding: 8px;
944
+ }
945
+ .zenfg-inspector-diagnostic-card {
946
+ display: flex;
947
+ flex-direction: column;
948
+ min-width: 0;
949
+ min-height: 164px;
950
+ overflow: hidden;
951
+ border: 1px solid var(--fgd-border-subtle);
952
+ border-radius: 6px;
953
+ background: var(--fgd-surface);
954
+ }
955
+ .zenfg-inspector-diagnostic-card > h2 {
956
+ margin: 0;
957
+ padding: 9px 10px 3px;
958
+ color: var(--fgd-text-secondary);
959
+ font: 650 12px/1.35 var(--fgd-font-ui);
960
+ }
961
+ .zenfg-inspector-diagnostic-card > p {
962
+ margin: 0;
963
+ padding: 0 10px 8px;
964
+ color: var(--fgd-muted);
965
+ font: 11px/1.5 var(--fgd-font-ui);
966
+ }
967
+ .zenfg-inspector-diagnostic-card .zenfg-inspector-table-scroller { flex: 1 1 auto; max-height: 280px; }
968
+ .zenfg-inspector-diagnostic-card .zenfg-inspector-workbench-table { min-width: 100%; table-layout: fixed; }
969
+ .zenfg-inspector-diagnostic-card .zenfg-inspector-workbench-table td {
970
+ overflow-wrap: anywhere;
971
+ white-space: normal;
972
+ }
973
+ .zenfg-inspector-diagnostic-list { display: grid; gap: 2px; padding: 6px; overflow: auto; }
974
+ .zenfg-inspector-diagnostic-list .zenfg-inspector-relation-button {
975
+ padding: 6px 8px;
976
+ border-radius: 4px;
977
+ color: var(--fgd-text-secondary);
978
+ font: 11px/1.45 var(--fgd-font-mono);
979
+ }
980
+ .zenfg-inspector-diagnostic-list .zenfg-inspector-relation-button:hover {
981
+ background: rgba(180, 190, 202, 0.05);
982
+ text-decoration: none;
983
+ }
984
+ .zenfg-inspector-diagnostic-list .selected { box-shadow: inset 2px 0 var(--fgd-accent); }
985
+
986
+ /* Responsive */
987
+ @container zenfg-inspector (max-width: 960px) {
988
+ .zenfg-inspector-workspace.inspector-open { grid-template-columns: minmax(0, 1fr); }
989
+ .zenfg-inspector-workspace.inspector-open::after {
990
+ position: absolute;
991
+ z-index: 10;
992
+ inset: 0;
993
+ background: rgba(3, 7, 12, 0.38);
994
+ content: '';
995
+ pointer-events: none;
996
+ }
997
+ .zenfg-inspector-inspector {
998
+ position: absolute;
999
+ z-index: 20;
1000
+ top: 0;
1001
+ right: 0;
1002
+ bottom: 0;
1003
+ width: min(380px, calc(100% - 24px));
1004
+ box-shadow: -18px 0 42px rgba(0, 0, 0, 0.42);
1005
+ }
1006
+ .zenfg-inspector-graph-toolbar {
1007
+ grid-template-columns: minmax(0, 1fr) auto;
1008
+ gap: 6px 8px;
1009
+ }
1010
+ .zenfg-inspector-graph-legend {
1011
+ grid-column: 1 / -1;
1012
+ grid-row: 2;
1013
+ padding-top: 6px;
1014
+ border-top: 1px solid var(--fgd-border-subtle);
1015
+ }
1016
+ .zenfg-inspector-graph-action-controls { justify-self: end; }
1017
+ }
1018
+
1019
+ @container zenfg-inspector (max-width: 840px) {
1020
+ .zenfg-inspector-workbench-command-bar {
1021
+ grid-template-columns: minmax(0, 1fr) auto;
1022
+ }
1023
+ .zenfg-inspector-brand { grid-column: 1; grid-row: 1; min-height: 36px; display: flex; align-items: center; }
1024
+ .zenfg-inspector-brand::after { display: none; }
1025
+ .zenfg-inspector-workbench-actions { grid-column: 2; grid-row: 1; }
1026
+ .zenfg-inspector-workbench-tabs { grid-column: 1 / -1; grid-row: 2; }
1027
+ .zenfg-inspector-workbench-command-bar.branding-hidden .zenfg-inspector-workbench-tabs {
1028
+ grid-column: 1;
1029
+ grid-row: 1;
1030
+ }
1031
+ .zenfg-inspector-diagnostics-grid { grid-template-columns: minmax(0, 1fr); }
1032
+ }
1033
+
1034
+ @container zenfg-inspector (max-width: 720px) {
1035
+ .zenfg-inspector-body { padding: 8px; }
1036
+ .zenfg-inspector-overview-view { padding: 8px; }
1037
+ .zenfg-inspector-capture-summary > section { padding: 10px; }
1038
+ .zenfg-inspector-workbench-actions { padding-left: 6px; }
1039
+ .zenfg-inspector-command-status { max-width: 104px; }
1040
+ .zenfg-inspector-workbench-tabs > button { flex: 0 0 auto; padding-inline: 8px; }
1041
+ .zenfg-inspector-memory-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
1042
+ .zenfg-inspector-view-toolbar input { flex-basis: 100%; }
1043
+ .zenfg-inspector-graph-toolbar { display: flex; flex-wrap: wrap; }
1044
+ .zenfg-inspector-graph-legend { order: 3; flex-basis: 100%; }
1045
+ .zenfg-inspector-graph-action-controls { margin-left: auto; }
1046
+ .zenfg-inspector-graph-view .zenfg-inspector-graph { height: auto; }
1047
+ }
1048
+
1049
+ @media (prefers-reduced-motion: reduce) {
1050
+ .zenfg-inspector *,
1051
+ .zenfg-inspector *::before,
1052
+ .zenfg-inspector *::after {
1053
+ scroll-behavior: auto !important;
1054
+ transition-duration: 0.01ms !important;
1055
+ animation-duration: 0.01ms !important;
1056
+ animation-iteration-count: 1 !important;
1057
+ }
1058
+ }
1059
+ `;
1060
+
1061
+ /**
1062
+ * Installs the inspector's shared stylesheet in the current document once.
1063
+ *
1064
+ * @remarks This is safe to call repeatedly and is a no-op during server-side
1065
+ * rendering. `FrameGraphInspector` calls it automatically.
1066
+ */
1067
+ export function ensureFrameGraphInspectorStyles(): void {
1068
+ if (typeof document === 'undefined' || document.getElementById(STYLE_ELEMENT_ID)) {
1069
+ return;
1070
+ }
1071
+
1072
+ const style = document.createElement('style');
1073
+ style.id = STYLE_ELEMENT_ID;
1074
+ style.textContent = FRAME_GRAPH_DEBUG_PANEL_CSS;
1075
+ document.head.appendChild(style);
1076
+ }