uidex 0.5.2 → 0.7.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +3 -3
- package/dist/cli/cli.cjs +1542 -1227
- package/dist/cli/cli.cjs.map +1 -1
- package/dist/cloud/index.cjs +385 -175
- package/dist/cloud/index.cjs.map +1 -1
- package/dist/cloud/index.d.cts +192 -4
- package/dist/cloud/index.d.ts +192 -4
- package/dist/cloud/index.js +377 -177
- package/dist/cloud/index.js.map +1 -1
- package/dist/headless/index.cjs +116 -251
- package/dist/headless/index.cjs.map +1 -1
- package/dist/headless/index.d.cts +6 -11
- package/dist/headless/index.d.ts +6 -11
- package/dist/headless/index.js +116 -253
- package/dist/headless/index.js.map +1 -1
- package/dist/index.cjs +776 -1055
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +152 -160
- package/dist/index.d.ts +152 -160
- package/dist/index.js +792 -1066
- package/dist/index.js.map +1 -1
- package/dist/react/index.cjs +801 -1019
- package/dist/react/index.cjs.map +1 -1
- package/dist/react/index.d.cts +102 -86
- package/dist/react/index.d.ts +102 -86
- package/dist/react/index.js +821 -1038
- package/dist/react/index.js.map +1 -1
- package/dist/scan/index.cjs +1550 -1220
- package/dist/scan/index.cjs.map +1 -1
- package/dist/scan/index.d.cts +210 -12
- package/dist/scan/index.d.ts +210 -12
- package/dist/scan/index.js +1547 -1219
- package/dist/scan/index.js.map +1 -1
- package/package.json +22 -21
- package/templates/claude/SKILL.md +71 -0
- package/templates/claude/references/audit.md +43 -0
- package/templates/claude/{rules.md → references/conventions.md} +25 -28
- package/templates/claude/audit.md +0 -43
- /package/templates/claude/{api.md → references/api.md} +0 -0
package/dist/index.d.cts
CHANGED
|
@@ -102,6 +102,7 @@ interface ReportRecord {
|
|
|
102
102
|
interface Registry {
|
|
103
103
|
add(entity: Entity): void;
|
|
104
104
|
get<K extends EntityKind>(kind: K, id: string): EntityByKind<K> | undefined;
|
|
105
|
+
matchPattern<K extends EntityKind>(kind: K, id: string): EntityByKind<K> | undefined;
|
|
105
106
|
list<K extends EntityKind>(kind: K): ReadonlyArray<EntityByKind<K>>;
|
|
106
107
|
query(predicate: (entity: Entity) => boolean): Entity[];
|
|
107
108
|
byScope(scope: Scope): Entity[];
|
|
@@ -109,7 +110,7 @@ interface Registry {
|
|
|
109
110
|
setReports(kind: EntityKind, id: string, reports: readonly ReportRecord[]): void;
|
|
110
111
|
getReports(kind: EntityKind, id: string): readonly ReportRecord[];
|
|
111
112
|
listReportKeys(): readonly string[];
|
|
112
|
-
|
|
113
|
+
closeReport?: (reportId: string, status?: string) => void | Promise<void>;
|
|
113
114
|
onReportsChange(cb: () => void): () => void;
|
|
114
115
|
}
|
|
115
116
|
declare function createRegistry(): Registry;
|
|
@@ -126,110 +127,6 @@ declare const KIND_STYLE: Record<EntityKind, KindStyleEntry>;
|
|
|
126
127
|
declare function prettify(id: string): string;
|
|
127
128
|
declare function displayName(entity: Entity, node?: Element | null): string;
|
|
128
129
|
|
|
129
|
-
interface UserIdentity {
|
|
130
|
-
id: string;
|
|
131
|
-
name?: string;
|
|
132
|
-
avatar?: string;
|
|
133
|
-
}
|
|
134
|
-
|
|
135
|
-
type ThemePreference = "light" | "dark" | "auto";
|
|
136
|
-
type ResolvedTheme = "light" | "dark";
|
|
137
|
-
interface ViewStackEntry {
|
|
138
|
-
id: string;
|
|
139
|
-
ref: EntityRef | null;
|
|
140
|
-
}
|
|
141
|
-
interface SessionSnapshot {
|
|
142
|
-
hover: EntityRef | null;
|
|
143
|
-
selection: EntityRef | null;
|
|
144
|
-
stack: ViewStackEntry[];
|
|
145
|
-
/** Sticky overlay highlight. Set by "Highlight Element" actions; cleared on Esc. */
|
|
146
|
-
pinnedHighlight: EntityRef | null;
|
|
147
|
-
inspectorActive: boolean;
|
|
148
|
-
theme: ThemePreference;
|
|
149
|
-
resolvedTheme: ResolvedTheme;
|
|
150
|
-
ingestActive: boolean;
|
|
151
|
-
/**
|
|
152
|
-
* Identity for the local user. Set once at session creation; gates realtime
|
|
153
|
-
* features (cursor labels, presence) and auto-populates report attribution.
|
|
154
|
-
*/
|
|
155
|
-
user: UserIdentity | null;
|
|
156
|
-
}
|
|
157
|
-
type SessionState = SessionSnapshot;
|
|
158
|
-
|
|
159
|
-
interface NavigationState {
|
|
160
|
-
stack: ViewStackEntry[];
|
|
161
|
-
}
|
|
162
|
-
interface NavigationActions {
|
|
163
|
-
push(entry: ViewStackEntry): void;
|
|
164
|
-
pop(): void;
|
|
165
|
-
replace(entry: ViewStackEntry): void;
|
|
166
|
-
clear(): void;
|
|
167
|
-
reset(stack: ViewStackEntry[]): void;
|
|
168
|
-
}
|
|
169
|
-
type NavigationStore = StoreApi<NavigationState> & {
|
|
170
|
-
nav: NavigationActions;
|
|
171
|
-
};
|
|
172
|
-
declare function createNavigationStore(): NavigationStore;
|
|
173
|
-
|
|
174
|
-
type SurfaceMode = "idle" | "inspecting" | "palette" | "viewing";
|
|
175
|
-
interface ModeSnapshot {
|
|
176
|
-
mode: SurfaceMode;
|
|
177
|
-
inspectorActive: boolean;
|
|
178
|
-
}
|
|
179
|
-
interface ModeBindings {
|
|
180
|
-
mountInspector?: () => void;
|
|
181
|
-
destroyInspector?: () => void;
|
|
182
|
-
}
|
|
183
|
-
interface ModeTransitions {
|
|
184
|
-
openPalette(): void;
|
|
185
|
-
openInspector(): void;
|
|
186
|
-
closeInspector(): void;
|
|
187
|
-
toggleInspector(): void;
|
|
188
|
-
enterViewing(initialStack: ViewStackEntry[]): void;
|
|
189
|
-
dismiss(): void;
|
|
190
|
-
popOrTransition(): void;
|
|
191
|
-
pushView(entry: ViewStackEntry): void;
|
|
192
|
-
}
|
|
193
|
-
type ModeStore = StoreApi<ModeSnapshot> & {
|
|
194
|
-
transition: ModeTransitions;
|
|
195
|
-
};
|
|
196
|
-
interface CreateModeStoreOptions {
|
|
197
|
-
nav: NavigationStore;
|
|
198
|
-
bindings?: ModeBindings;
|
|
199
|
-
}
|
|
200
|
-
declare function createModeStore(options: CreateModeStoreOptions): ModeStore;
|
|
201
|
-
|
|
202
|
-
interface HighlightContext {
|
|
203
|
-
ref: EntityRef | null;
|
|
204
|
-
element: HTMLElement | null;
|
|
205
|
-
pinnedRef: EntityRef | null;
|
|
206
|
-
color: string | null;
|
|
207
|
-
}
|
|
208
|
-
interface HighlightActions {
|
|
209
|
-
hover(ref: EntityRef, element?: HTMLElement | null, color?: string | null): void;
|
|
210
|
-
unhover(): void;
|
|
211
|
-
pin(ref?: EntityRef): void;
|
|
212
|
-
unpin(): void;
|
|
213
|
-
}
|
|
214
|
-
type SessionStore = StoreApi<SessionState> & {
|
|
215
|
-
readonly nav: NavigationStore;
|
|
216
|
-
readonly mode: ModeStore;
|
|
217
|
-
readonly highlight: HighlightActions;
|
|
218
|
-
select(ref: EntityRef | null): void;
|
|
219
|
-
setTheme(theme: ThemePreference, resolved?: ResolvedTheme): void;
|
|
220
|
-
setIngest(active: boolean): void;
|
|
221
|
-
};
|
|
222
|
-
interface CreateSessionOptions extends Partial<SessionSnapshot> {
|
|
223
|
-
detectTheme?: () => ResolvedTheme;
|
|
224
|
-
onMountInspector?: () => void;
|
|
225
|
-
onDestroyInspector?: () => void;
|
|
226
|
-
onShowOverlay?: (context: HighlightContext) => void;
|
|
227
|
-
onHideOverlay?: () => void;
|
|
228
|
-
onUpdateOverlay?: (context: HighlightContext) => void;
|
|
229
|
-
}
|
|
230
|
-
declare function resolveTheme(preference: ThemePreference, detect?: () => ResolvedTheme): ResolvedTheme;
|
|
231
|
-
declare function createSession(options?: CreateSessionOptions): SessionStore;
|
|
232
|
-
|
|
233
130
|
type ConsoleLevel = "warn" | "error";
|
|
234
131
|
interface ConsoleEntry {
|
|
235
132
|
level: ConsoleLevel;
|
|
@@ -274,7 +171,12 @@ interface NetworkCapture {
|
|
|
274
171
|
declare function createNetworkCapture(options?: NetworkCaptureOptions): NetworkCapture;
|
|
275
172
|
|
|
276
173
|
declare const nativeFetch: typeof fetch | undefined;
|
|
277
|
-
|
|
174
|
+
|
|
175
|
+
interface UserIdentity {
|
|
176
|
+
id: string;
|
|
177
|
+
name?: string;
|
|
178
|
+
avatar?: string;
|
|
179
|
+
}
|
|
278
180
|
|
|
279
181
|
type RealtimePresenceUser = {
|
|
280
182
|
userId: string;
|
|
@@ -293,6 +195,8 @@ interface RealtimeChannel {
|
|
|
293
195
|
joinRoute(route: string): void;
|
|
294
196
|
onPresence(cb: (users: RealtimePresenceUser[]) => void): () => void;
|
|
295
197
|
onPin(cb: (pin: PinRecord) => void): () => void;
|
|
198
|
+
/** Optional so pre-existing channel stubs keep satisfying the interface. */
|
|
199
|
+
onPinArchived?(cb: (reportId: string) => void): () => void;
|
|
296
200
|
}
|
|
297
201
|
interface CloudAdapter<TPayload = ReportPayload, TResult = ReportResult, TIntegrations = {
|
|
298
202
|
getConfig(): Promise<IngestConfig>;
|
|
@@ -314,8 +218,17 @@ interface CloudAdapter<TPayload = ReportPayload, TResult = ReportResult, TIntegr
|
|
|
314
218
|
route?: string;
|
|
315
219
|
entities?: string;
|
|
316
220
|
}): Promise<PinRecord[]>;
|
|
317
|
-
|
|
221
|
+
/**
|
|
222
|
+
* Pin records travel without their screenshot (kept out of `pins.list`
|
|
223
|
+
* so multi-MB frames don't stall the shared socket); the report detail
|
|
224
|
+
* view fetches it lazily through here. Optional for host-provided
|
|
225
|
+
* adapters that inline screenshots on the record instead.
|
|
226
|
+
*/
|
|
227
|
+
screenshot?(reportId: string): Promise<string | null>;
|
|
228
|
+
close(reportId: string, reason?: ArchiveReason): Promise<void>;
|
|
318
229
|
};
|
|
230
|
+
/** Closes the adapter's shared socket. Any later RPC call revives it. */
|
|
231
|
+
dispose?(): void;
|
|
319
232
|
}
|
|
320
233
|
|
|
321
234
|
interface IngestOptions {
|
|
@@ -334,12 +247,104 @@ interface Ingest {
|
|
|
334
247
|
readonly console: ConsoleCapture | null;
|
|
335
248
|
readonly network: NetworkCapture | null;
|
|
336
249
|
}
|
|
337
|
-
|
|
338
|
-
session?: SessionStore;
|
|
339
|
-
}
|
|
250
|
+
type CreateIngestOptions = IngestOptions;
|
|
340
251
|
declare function createIngest(options?: CreateIngestOptions): Ingest;
|
|
341
252
|
declare function resolveIngestOptions(explicit: IngestOptions | null | undefined, hasCloud: boolean): IngestOptions | null;
|
|
342
253
|
|
|
254
|
+
type ThemePreference = "light" | "dark" | "auto";
|
|
255
|
+
type ResolvedTheme = "light" | "dark";
|
|
256
|
+
interface ViewStackEntry {
|
|
257
|
+
id: string;
|
|
258
|
+
ref: EntityRef | null;
|
|
259
|
+
}
|
|
260
|
+
interface SessionSnapshot {
|
|
261
|
+
stack: ViewStackEntry[];
|
|
262
|
+
/** Sticky overlay highlight. Set by "Highlight Element" actions; cleared on Esc. */
|
|
263
|
+
pinnedHighlight: EntityRef | null;
|
|
264
|
+
/** Mirrored from the mode store; the surface mode the session is currently in. */
|
|
265
|
+
mode: SurfaceMode;
|
|
266
|
+
theme: ThemePreference;
|
|
267
|
+
resolvedTheme: ResolvedTheme;
|
|
268
|
+
/**
|
|
269
|
+
* Identity for the local user. Set once at session creation; gates realtime
|
|
270
|
+
* features (cursor labels, presence) and auto-populates report attribution.
|
|
271
|
+
*/
|
|
272
|
+
user: UserIdentity | null;
|
|
273
|
+
}
|
|
274
|
+
type SessionState = SessionSnapshot;
|
|
275
|
+
|
|
276
|
+
interface NavigationState {
|
|
277
|
+
stack: ViewStackEntry[];
|
|
278
|
+
}
|
|
279
|
+
interface NavigationActions {
|
|
280
|
+
push(entry: ViewStackEntry): void;
|
|
281
|
+
pop(): void;
|
|
282
|
+
clear(): void;
|
|
283
|
+
reset(stack: ViewStackEntry[]): void;
|
|
284
|
+
}
|
|
285
|
+
type NavigationStore = StoreApi<NavigationState> & {
|
|
286
|
+
nav: NavigationActions;
|
|
287
|
+
};
|
|
288
|
+
declare function createNavigationStore(): NavigationStore;
|
|
289
|
+
|
|
290
|
+
type SurfaceMode = "idle" | "inspecting" | "palette" | "viewing";
|
|
291
|
+
interface ModeSnapshot {
|
|
292
|
+
mode: SurfaceMode;
|
|
293
|
+
}
|
|
294
|
+
interface ModeBindings {
|
|
295
|
+
mountInspector?: () => void;
|
|
296
|
+
destroyInspector?: () => void;
|
|
297
|
+
}
|
|
298
|
+
interface ModeTransitions {
|
|
299
|
+
openPalette(): void;
|
|
300
|
+
openInspector(): void;
|
|
301
|
+
closeInspector(): void;
|
|
302
|
+
toggleInspector(): void;
|
|
303
|
+
enterViewing(initialStack: ViewStackEntry[]): void;
|
|
304
|
+
dismiss(): void;
|
|
305
|
+
popOrTransition(): void;
|
|
306
|
+
pushView(entry: ViewStackEntry): void;
|
|
307
|
+
}
|
|
308
|
+
type ModeStore = StoreApi<ModeSnapshot> & {
|
|
309
|
+
transition: ModeTransitions;
|
|
310
|
+
};
|
|
311
|
+
interface CreateModeStoreOptions {
|
|
312
|
+
nav: NavigationStore;
|
|
313
|
+
bindings?: ModeBindings;
|
|
314
|
+
}
|
|
315
|
+
declare function createModeStore(options: CreateModeStoreOptions): ModeStore;
|
|
316
|
+
|
|
317
|
+
interface HighlightContext {
|
|
318
|
+
ref: EntityRef | null;
|
|
319
|
+
element: HTMLElement | null;
|
|
320
|
+
pinnedRef: EntityRef | null;
|
|
321
|
+
color: string | null;
|
|
322
|
+
}
|
|
323
|
+
interface HighlightActions {
|
|
324
|
+
hover(ref: EntityRef, element?: HTMLElement | null, color?: string | null): void;
|
|
325
|
+
unhover(): void;
|
|
326
|
+
pin(ref?: EntityRef): void;
|
|
327
|
+
unpin(): void;
|
|
328
|
+
}
|
|
329
|
+
type SessionStore = StoreApi<SessionState> & {
|
|
330
|
+
readonly nav: NavigationStore;
|
|
331
|
+
readonly mode: ModeStore;
|
|
332
|
+
readonly highlight: HighlightActions;
|
|
333
|
+
setTheme(theme: ThemePreference, resolved?: ResolvedTheme): void;
|
|
334
|
+
};
|
|
335
|
+
interface CreateSessionOptions extends Partial<SessionSnapshot> {
|
|
336
|
+
detectTheme?: () => ResolvedTheme;
|
|
337
|
+
onMountInspector?: () => void;
|
|
338
|
+
onDestroyInspector?: () => void;
|
|
339
|
+
onShowOverlay?: (context: HighlightContext) => void;
|
|
340
|
+
onHideOverlay?: () => void;
|
|
341
|
+
onUpdateOverlay?: (context: HighlightContext) => void;
|
|
342
|
+
/** When true, start the session in inspector mode. */
|
|
343
|
+
inspectorActive?: boolean;
|
|
344
|
+
}
|
|
345
|
+
declare function resolveTheme(preference: ThemePreference, detect?: () => ResolvedTheme): ResolvedTheme;
|
|
346
|
+
declare function createSession(options?: CreateSessionOptions): SessionStore;
|
|
347
|
+
|
|
343
348
|
interface SurfaceHost {
|
|
344
349
|
readonly hostEl: HTMLElement;
|
|
345
350
|
readonly shadowRoot: ShadowRoot;
|
|
@@ -381,31 +386,9 @@ interface CursorTooltip {
|
|
|
381
386
|
}
|
|
382
387
|
interface CursorTooltipDeps {
|
|
383
388
|
container: Element;
|
|
384
|
-
session: SessionStore;
|
|
385
389
|
}
|
|
386
390
|
declare function createCursorTooltip(deps: CursorTooltipDeps): CursorTooltip;
|
|
387
391
|
|
|
388
|
-
interface OverlayShowOptions {
|
|
389
|
-
label?: string;
|
|
390
|
-
color?: string;
|
|
391
|
-
padding?: number;
|
|
392
|
-
borderStyle?: string;
|
|
393
|
-
borderWidth?: number;
|
|
394
|
-
fillOpacity?: number;
|
|
395
|
-
backdrop?: boolean;
|
|
396
|
-
}
|
|
397
|
-
interface Overlay {
|
|
398
|
-
show(target: Element, options?: OverlayShowOptions): void;
|
|
399
|
-
hide(): void;
|
|
400
|
-
destroy(): void;
|
|
401
|
-
onDismiss: (() => void) | null;
|
|
402
|
-
readonly isVisible: boolean;
|
|
403
|
-
}
|
|
404
|
-
interface OverlayDeps {
|
|
405
|
-
container: Element | ShadowRoot;
|
|
406
|
-
}
|
|
407
|
-
declare function createOverlay(deps: OverlayDeps): Overlay;
|
|
408
|
-
|
|
409
392
|
interface InspectorMatch {
|
|
410
393
|
element: HTMLElement;
|
|
411
394
|
ref: EntityRef;
|
|
@@ -444,39 +427,20 @@ interface Inspector {
|
|
|
444
427
|
mount(): void;
|
|
445
428
|
destroy(): void;
|
|
446
429
|
}
|
|
447
|
-
declare function defaultResolveMatch(target: Element, registry?: Registry): InspectorMatch | null;
|
|
448
430
|
declare function resolveEntityElement(ref: EntityRef): HTMLElement | null;
|
|
449
|
-
interface HighlightControllerLike {
|
|
450
|
-
show(ref: EntityRef, opts?: OverlayShowOptions): void;
|
|
451
|
-
hide(): void;
|
|
452
|
-
}
|
|
453
|
-
declare function createHighlightController(overlay: Overlay): HighlightControllerLike;
|
|
454
431
|
declare function createInspector(options: InspectorOptions): Inspector;
|
|
455
432
|
|
|
456
433
|
type PinMatchMode = "route" | "pathname" | "component";
|
|
457
|
-
interface PinFilter {
|
|
458
|
-
branch: string | null;
|
|
459
|
-
commit: string | null;
|
|
460
|
-
}
|
|
461
|
-
interface PinFilterState extends PinFilter {
|
|
462
|
-
readonly commits: readonly string[];
|
|
463
|
-
readonly commitIndex: number;
|
|
464
|
-
}
|
|
465
434
|
interface PinLayer {
|
|
466
435
|
setPins(pins: readonly PinRecord[]): void;
|
|
467
436
|
addPin(pin: PinRecord): void;
|
|
468
437
|
removePin(reportId: string): void;
|
|
469
438
|
clear(): void;
|
|
470
439
|
getPinsForElement(componentId: string): readonly PinRecord[];
|
|
471
|
-
getAllPinsForElement(componentId: string): readonly PinRecord[];
|
|
472
440
|
getAllPins(): readonly PinRecord[];
|
|
473
441
|
attachChannel(channel: RealtimeChannel): () => void;
|
|
474
442
|
attachCloud(opts: AttachCloudOpts): () => void;
|
|
475
443
|
refresh(): Promise<void>;
|
|
476
|
-
readonly filterState: PinFilterState;
|
|
477
|
-
setFilter(filter: Partial<PinFilter>): void;
|
|
478
|
-
nextCommit(): void;
|
|
479
|
-
prevCommit(): void;
|
|
480
444
|
onFilterChange(cb: () => void): () => void;
|
|
481
445
|
readonly visible: boolean;
|
|
482
446
|
setVisible(visible: boolean): void;
|
|
@@ -496,7 +460,6 @@ interface PinLayerOptions {
|
|
|
496
460
|
onOpenPinDetail?: (componentId: string, reportId: string) => void;
|
|
497
461
|
onHoverPin?: (anchor: HTMLElement | null, componentId: string | null) => void;
|
|
498
462
|
onPinsChanged?: () => void;
|
|
499
|
-
currentBranch?: string | null;
|
|
500
463
|
}
|
|
501
464
|
declare function createPinLayer(options: PinLayerOptions): PinLayer;
|
|
502
465
|
|
|
@@ -519,6 +482,27 @@ interface MenuBar {
|
|
|
519
482
|
}
|
|
520
483
|
declare function createMenuBar(options: MenuBarOptions): MenuBar;
|
|
521
484
|
|
|
485
|
+
interface OverlayShowOptions {
|
|
486
|
+
label?: string;
|
|
487
|
+
color?: string;
|
|
488
|
+
padding?: number;
|
|
489
|
+
borderStyle?: string;
|
|
490
|
+
borderWidth?: number;
|
|
491
|
+
fillOpacity?: number;
|
|
492
|
+
backdrop?: boolean;
|
|
493
|
+
}
|
|
494
|
+
interface Overlay {
|
|
495
|
+
show(target: Element, options?: OverlayShowOptions): void;
|
|
496
|
+
hide(): void;
|
|
497
|
+
destroy(): void;
|
|
498
|
+
onDismiss: (() => void) | null;
|
|
499
|
+
readonly isVisible: boolean;
|
|
500
|
+
}
|
|
501
|
+
interface OverlayDeps {
|
|
502
|
+
container: Element | ShadowRoot;
|
|
503
|
+
}
|
|
504
|
+
declare function createOverlay(deps: OverlayDeps): Overlay;
|
|
505
|
+
|
|
522
506
|
interface ThemeDetector {
|
|
523
507
|
destroy(): void;
|
|
524
508
|
/** Resolve the current theme preference against the environment. */
|
|
@@ -640,6 +624,8 @@ interface DetailSurface {
|
|
|
640
624
|
entityKind: EntityKind;
|
|
641
625
|
/** Registry lookup failed — renders the "not found" placeholder. */
|
|
642
626
|
notFound?: EntityRef;
|
|
627
|
+
/** Entity exists in the DOM but not in the registry (gen file). */
|
|
628
|
+
unregistered?: boolean;
|
|
643
629
|
/** Entity display name, rendered as the heading. */
|
|
644
630
|
title?: string;
|
|
645
631
|
subtitle?: DetailSubtitle;
|
|
@@ -716,9 +702,16 @@ type DetailSection = {
|
|
|
716
702
|
id: "routes";
|
|
717
703
|
paths: readonly string[];
|
|
718
704
|
filterable?: boolean;
|
|
719
|
-
}
|
|
705
|
+
}
|
|
706
|
+
/**
|
|
707
|
+
* `url` renders immediately; `load` fetches lazily (cloud pins travel
|
|
708
|
+
* without their screenshot) and the section stays hidden until — and
|
|
709
|
+
* unless — the promise resolves with a data URL.
|
|
710
|
+
*/
|
|
711
|
+
| {
|
|
720
712
|
id: "screenshot";
|
|
721
|
-
url
|
|
713
|
+
url?: string;
|
|
714
|
+
load?: () => Promise<string | null>;
|
|
722
715
|
} | {
|
|
723
716
|
id: "metadata";
|
|
724
717
|
entries: readonly MetadataEntry[];
|
|
@@ -917,8 +910,9 @@ interface View {
|
|
|
917
910
|
* when the declared target has been removed from the host.
|
|
918
911
|
*/
|
|
919
912
|
focusTarget?: (root: HTMLElement, ctx: ViewContext) => HTMLElement | null;
|
|
920
|
-
|
|
921
|
-
|
|
913
|
+
/** Required unless `render` is provided. */
|
|
914
|
+
surface?: (ctx: ViewContext) => ViewSurface;
|
|
915
|
+
/** Direct render for integration adapters (React, etc.). Takes precedence over `surface` when both are present. */
|
|
922
916
|
render?: (ctx: ViewContext, root: HTMLElement) => Cleanup | void;
|
|
923
917
|
parent?: (ref: EntityRef | null) => ViewStackEntry | null;
|
|
924
918
|
}
|
|
@@ -948,12 +942,11 @@ declare function formatShortcutLabel(shortcut: PaletteShortcut): string;
|
|
|
948
942
|
type EscapeHandler = () => boolean;
|
|
949
943
|
|
|
950
944
|
declare const SURFACE_HOST_CLASS = "uidex-surface-host";
|
|
951
|
-
declare const SURFACE_CONTAINER_CLASS = "uidex-container";
|
|
952
945
|
declare const Z_BASE = 2147483630;
|
|
953
946
|
declare const Z_OVERLAY = 2147483635;
|
|
954
947
|
declare const Z_PIN_LAYER = 2147483640;
|
|
955
948
|
declare const Z_CHROME = 2147483645;
|
|
956
|
-
declare const SURFACE_IGNORE_SELECTOR = ".uidex-surface-host
|
|
949
|
+
declare const SURFACE_IGNORE_SELECTOR = ".uidex-surface-host";
|
|
957
950
|
|
|
958
951
|
interface ViewStackOptions {
|
|
959
952
|
container: HTMLElement;
|
|
@@ -962,7 +955,6 @@ interface ViewStackOptions {
|
|
|
962
955
|
registry: Registry;
|
|
963
956
|
cloud?: CloudAdapter | null;
|
|
964
957
|
highlight: HighlightController;
|
|
965
|
-
globalActions?: (ctx: ViewContext) => ShellAction[];
|
|
966
958
|
shortcut?: PaletteShortcut;
|
|
967
959
|
dev?: boolean;
|
|
968
960
|
pushEscapeLayer?: ViewContext["pushEscapeLayer"];
|
|
@@ -1049,4 +1041,4 @@ interface Uidex {
|
|
|
1049
1041
|
}
|
|
1050
1042
|
declare function createUidex(options?: CreateUidexOptions): Uidex;
|
|
1051
1043
|
|
|
1052
|
-
export { type AttachCloudOpts, type Cleanup, type CloudAdapter, type ConsoleCapture, type ConsoleEntry, type ConsoleLevel, type Corner, type CreateRouterOptions, type CreateSessionOptions, type CreateSurfaceShellOptions, type CreateUidexOptions, type CursorTooltip, type CursorTooltipDeps, type DetailAction, type DetailActionIcon, type DetailActionRunContext, type DetailSection, type DetailSubtitle, type DetailSurface, ENTITY_KINDS, type Element$1 as Element, type Entity, type EntityByKind, type EntityKind, type EntityRef, type Feature, type Flow, type FormField, type FormSubmit, type FormSubmitResult, type FormSurface, type FormValue, type HighlightActions, type HighlightController, type Ingest, type IngestOptions, type Inspector, type InspectorMatch, type InspectorMatchStack, type InspectorOptions, KIND_STYLE, type KindStyleEntry, type ListItem, type ListSurface, type Location, type MenuBar, type MenuBarOptions, type MetaEntityKind, type Metadata, type ModeBindings, type ModeSnapshot, type ModeStore, type ModeTransitions, type NavigationActions, type NavigationState, type NavigationStore, type NetworkCapture, type NetworkEntry, type Overlay, type OverlayShowOptions, type Page, type PaletteShortcut, type PinLayer, type PinLayerOptions, type PinMatchMode, type Primitive, type RealtimeChannel, type RealtimeChannelState, type RealtimePresenceUser, type Region, type Registry, type ReportRecord, type ResolvedTheme, type Route, type RouteMatch, type Router,
|
|
1044
|
+
export { type AttachCloudOpts, type Cleanup, type CloudAdapter, type ConsoleCapture, type ConsoleEntry, type ConsoleLevel, type Corner, type CreateRouterOptions, type CreateSessionOptions, type CreateSurfaceShellOptions, type CreateUidexOptions, type CursorTooltip, type CursorTooltipDeps, type DetailAction, type DetailActionIcon, type DetailActionRunContext, type DetailSection, type DetailSubtitle, type DetailSurface, ENTITY_KINDS, type Element$1 as Element, type Entity, type EntityByKind, type EntityKind, type EntityRef, type Feature, type Flow, type FormField, type FormSubmit, type FormSubmitResult, type FormSurface, type FormValue, type HighlightActions, type HighlightController, type Ingest, type IngestOptions, type Inspector, type InspectorMatch, type InspectorMatchStack, type InspectorOptions, KIND_STYLE, type KindStyleEntry, type ListItem, type ListSurface, type Location, type MenuBar, type MenuBarOptions, type MetaEntityKind, type Metadata, type ModeBindings, type ModeSnapshot, type ModeStore, type ModeTransitions, type NavigationActions, type NavigationState, type NavigationStore, type NetworkCapture, type NetworkEntry, type Overlay, type OverlayShowOptions, type Page, type PaletteShortcut, type PinLayer, type PinLayerOptions, type PinMatchMode, type Primitive, type RealtimeChannel, type RealtimeChannelState, type RealtimePresenceUser, type Region, type Registry, type ReportRecord, type ResolvedTheme, type Route, type RouteMatch, type Router, SURFACE_HOST_CLASS, SURFACE_IGNORE_SELECTOR, type Scope, type SessionSnapshot, type SessionState, type SessionStore, type ShellAction, type ShellHint, type SurfaceHost, type SurfaceHostOptions, type SurfaceMode, type SurfaceShell, type ThemeDetector, type ThemeDetectorDeps, type ThemePreference, type Uidex, UnknownEntityKindError, type UserIdentity, type View, type ViewContext, type ViewPalette, type ViewPushTarget, type ViewStack, type ViewStackEntry, type ViewStackOptions, type ViewSurface, ViewValidationError, type Widget, Z_BASE, Z_CHROME, Z_OVERLAY, Z_PIN_LAYER, assertEntityKind, buildDefaultViews, componentDetailView, createCommandPaletteView, createConsoleCapture, createCursorTooltip, createIngest, createInspector, createMenuBar, createModeStore, createNavigationStore, createNetworkCapture, createOverlay, createPinLayer, createRegistry, createRouter, createSession, createSurfaceHost, createSurfaceShell, createThemeDetector, createUidex, createViewStack, displayName, entityKey, featureDetailView, flowDetailView, formatShortcutLabel, isMetaKind, nativeFetch, pageDetailView, pinSettingsView, prettify, primitiveDetailView, regionDetailView, reportView, resolveEntityElement, resolveIngestOptions, resolveTheme, widgetDetailView };
|