sculpted 0.0.0 → 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (31) hide show
  1. package/LICENSE +105 -0
  2. package/README.md +233 -0
  3. package/dist/index.d.mts +129 -0
  4. package/dist/index.mjs +3 -0
  5. package/dist/patcher-BAw2kF1Q.mjs +2594 -0
  6. package/dist/protocol-BJm-xGHP.mjs +54 -0
  7. package/dist/runtime-DwE3PVhB.d.mts +64 -0
  8. package/dist/runtime.d.mts +2 -0
  9. package/dist/runtime.mjs +613 -0
  10. package/dist/sourceSyntax-DanNzS7Y.d.mts +103 -0
  11. package/dist/types-CdByW0ji.d.mts +381 -0
  12. package/dist/ui.d.mts +54 -0
  13. package/dist/ui.mjs +11125 -0
  14. package/dist/vite.d.mts +85 -0
  15. package/dist/vite.mjs +2325 -0
  16. package/examples/manual-vite-preact-pandacss/README.md +75 -0
  17. package/examples/manual-vite-preact-pandacss/index.html +12 -0
  18. package/examples/manual-vite-preact-pandacss/package.json +23 -0
  19. package/examples/manual-vite-preact-pandacss/panda.config.ts +43 -0
  20. package/examples/manual-vite-preact-pandacss/pnpm-lock.yaml +3359 -0
  21. package/examples/manual-vite-preact-pandacss/pnpm-workspace.yaml +2 -0
  22. package/examples/manual-vite-preact-pandacss/postcss.config.cjs +5 -0
  23. package/examples/manual-vite-preact-pandacss/src/TsrxManualPanel.tsrx +47 -0
  24. package/examples/manual-vite-preact-pandacss/src/index.css +8 -0
  25. package/examples/manual-vite-preact-pandacss/src/main.style.ts +33 -0
  26. package/examples/manual-vite-preact-pandacss/src/main.tsx +484 -0
  27. package/examples/manual-vite-preact-pandacss/src/tsrx.d.ts +5 -0
  28. package/examples/manual-vite-preact-pandacss/tsconfig.json +21 -0
  29. package/examples/manual-vite-preact-pandacss/vite.config.ts +20 -0
  30. package/package.json +66 -8
  31. package/readme.md +0 -1
@@ -0,0 +1,103 @@
1
+ import { V as SourceRange, z as SourceLocation } from "./types-CdByW0ji.mjs";
2
+ import ts from "typescript";
3
+
4
+ //#region src/sourceSyntax.d.ts
5
+ type ParseSourceSyntaxOptions = {
6
+ readonly filePath: string;
7
+ readonly sourceText: string;
8
+ };
9
+ type SourceAstKind = 'typescript' | 'estree';
10
+ type EstreeNode = {
11
+ readonly type: string;
12
+ readonly start?: number;
13
+ readonly end?: number;
14
+ readonly loc?: {
15
+ readonly start: {
16
+ readonly line: number;
17
+ readonly column: number;
18
+ };
19
+ readonly end: {
20
+ readonly line: number;
21
+ readonly column: number;
22
+ };
23
+ } | null;
24
+ readonly [key: string]: unknown;
25
+ };
26
+ type SourceParseResult = {
27
+ readonly kind: 'typescript';
28
+ readonly languageId: string;
29
+ readonly sourceFile: ts.SourceFile;
30
+ } | {
31
+ readonly kind: 'estree';
32
+ readonly languageId: string;
33
+ readonly program: EstreeNode;
34
+ readonly comments?: readonly EstreeNode[];
35
+ };
36
+ type SourceParserAdapter = {
37
+ readonly languageId: string;
38
+ readonly kind: SourceAstKind;
39
+ readonly isSupportedFile: (filePath: string) => boolean;
40
+ readonly parse: (options: ParseSourceSyntaxOptions) => SourceParseResult;
41
+ };
42
+ type SourceSyntaxAdapter = SourceParserAdapter;
43
+ type SourceSyntaxOption = SourceParserAdapter | readonly SourceParserAdapter[];
44
+ type PandaSourceAstAdapter<Root, Node> = {
45
+ readonly astKind: SourceAstKind;
46
+ walk(root: Root, visit: (node: Node, parent: Node | undefined) => void): void;
47
+ topLevelStatements(root: Root): readonly Node[];
48
+ isImportDeclaration(node: Node): boolean;
49
+ getImportSource(node: Node): string | undefined;
50
+ getNamedImportBindings(node: Node): readonly {
51
+ readonly imported: string;
52
+ readonly local: string;
53
+ }[];
54
+ isCallExpression(node: Node): boolean;
55
+ getCallCalleeIdentifier(node: Node): string | undefined;
56
+ getCallArguments(node: Node): readonly Node[];
57
+ isObjectExpression(node: Node): boolean;
58
+ getObjectProperties(node: Node): readonly Node[];
59
+ isPlainProperty(node: Node): boolean;
60
+ isSpreadProperty(node: Node): boolean;
61
+ getPropertyName(node: Node): string | undefined;
62
+ getPropertyValue(node: Node): Node | undefined;
63
+ getLiteralValue(node: Node): string | number | boolean | null | undefined;
64
+ isIdentifier(node: Node): boolean;
65
+ getRange(node: Node): SourceRange;
66
+ getLocation(node: Node): SourceLocation;
67
+ findObjectExpressionAtRange(root: Root, range: SourceRange): Node | undefined;
68
+ getParent(root: Root, node: Node): Node | undefined;
69
+ nodeContains(root: Node, target: Node): boolean;
70
+ getVariableDeclaratorName(node: Node): string | undefined;
71
+ getVariableDeclaratorInitializer(node: Node): Node | undefined;
72
+ isVariableDeclaratorInitializer(node: Node, child: Node): boolean;
73
+ getPropertyOwnerName(node: Node): string | undefined;
74
+ isPropertyValue(node: Node, child: Node): boolean;
75
+ isJsxBoundary(node: Node): boolean;
76
+ firstImportEnd(root: Root): number;
77
+ isPatchableLiteral(node: Node): boolean;
78
+ };
79
+ type ParsedPandaSource = {
80
+ readonly astKind: 'typescript';
81
+ readonly languageId: string;
82
+ readonly filePath: string;
83
+ readonly sourceText: string;
84
+ readonly root: ts.SourceFile;
85
+ readonly ops: PandaSourceAstAdapter<ts.SourceFile, ts.Node>;
86
+ } | {
87
+ readonly astKind: 'estree';
88
+ readonly languageId: string;
89
+ readonly filePath: string;
90
+ readonly sourceText: string;
91
+ readonly root: EstreeNode;
92
+ readonly ops: PandaSourceAstAdapter<EstreeNode, EstreeNode>;
93
+ };
94
+ declare function parseWithSourceParserAdapter(adapter: SourceSyntaxOption | undefined, options: ParseSourceSyntaxOptions): SourceParseResult;
95
+ declare function parsePandaSource(adapter: SourceSyntaxOption | undefined, options: ParseSourceSyntaxOptions): ParsedPandaSource;
96
+ declare function resolveSourceParserAdapter(filePath: string, adapter: SourceSyntaxOption | undefined): SourceParserAdapter;
97
+ declare const tsxSourceParserAdapter: SourceParserAdapter;
98
+ declare const tsxSourceSyntaxAdapter: SourceParserAdapter;
99
+ declare const tsrxSourceParserAdapter: SourceParserAdapter;
100
+ declare const typescriptPandaAstAdapter: PandaSourceAstAdapter<ts.SourceFile, ts.Node>;
101
+ declare function createEstreePandaAstAdapter(root: EstreeNode): PandaSourceAstAdapter<EstreeNode, EstreeNode>;
102
+ //#endregion
103
+ export { typescriptPandaAstAdapter as _, SourceAstKind as a, SourceSyntaxAdapter as c, parsePandaSource as d, parseWithSourceParserAdapter as f, tsxSourceSyntaxAdapter as g, tsxSourceParserAdapter as h, ParsedPandaSource as i, SourceSyntaxOption as l, tsrxSourceParserAdapter as m, PandaSourceAstAdapter as n, SourceParseResult as o, resolveSourceParserAdapter as p, ParseSourceSyntaxOptions as r, SourceParserAdapter as s, EstreeNode as t, createEstreePandaAstAdapter as u };
@@ -0,0 +1,381 @@
1
+ //#region src/shared/types.d.ts
2
+ type JsonPrimitive = string | number | boolean | null;
3
+ type JsonValue = JsonPrimitive | {
4
+ readonly [key: string]: JsonValue;
5
+ } | readonly JsonValue[];
6
+ type SourcePosition = {
7
+ readonly line: number;
8
+ readonly column: number;
9
+ };
10
+ type SourceLocation = {
11
+ readonly start: SourcePosition;
12
+ readonly end: SourcePosition;
13
+ };
14
+ type SourceRange = {
15
+ readonly start: number;
16
+ readonly end: number;
17
+ };
18
+ type Confidence = 'high' | 'medium' | 'low';
19
+ type SourceTargetKind = 'panda-css' | 'dynamic' | 'external' | 'unsupported';
20
+ type UnsupportedReason = 'ambiguous-target' | 'computed-css-only' | 'dynamic-expression' | 'external-class' | 'generated-source' | 'missing-source' | 'multiple-targets' | 'not-panda-css' | 'spread-value' | 'stale-metadata' | 'unsupported-source-shape' | 'variable-reference';
21
+ type StyleValueSource = {
22
+ readonly kind: 'literal';
23
+ readonly value: JsonValue;
24
+ readonly range?: SourceRange;
25
+ readonly loc?: SourceLocation;
26
+ } | {
27
+ readonly kind: 'unsupported';
28
+ readonly reason: UnsupportedReason;
29
+ readonly description?: string;
30
+ readonly range?: SourceRange;
31
+ readonly loc?: SourceLocation;
32
+ };
33
+ type PandaStyleObject = {
34
+ readonly [property: string]: StyleValueSource | PandaStyleObject;
35
+ };
36
+ type SourceTargetBase = {
37
+ readonly id: string;
38
+ readonly kind: SourceTargetKind;
39
+ readonly file: string;
40
+ readonly absoluteFile?: string;
41
+ readonly range?: SourceRange;
42
+ readonly loc?: SourceLocation;
43
+ readonly sourceHash?: string;
44
+ readonly name?: string;
45
+ readonly component?: string;
46
+ readonly element?: string;
47
+ readonly attribute?: string;
48
+ readonly jsxSource?: string;
49
+ readonly jsxSourceAliases?: readonly string[];
50
+ readonly markerClass?: string;
51
+ readonly confidence: Confidence;
52
+ readonly reason?: string;
53
+ };
54
+ type PandaCssSourceTarget = SourceTargetBase & {
55
+ readonly kind: 'panda-css';
56
+ readonly callee: string;
57
+ readonly styleObject: PandaStyleObject;
58
+ readonly dynamic: false;
59
+ };
60
+ type DynamicSourceTarget = SourceTargetBase & {
61
+ readonly kind: 'dynamic';
62
+ readonly dynamic: true;
63
+ readonly unsupportedReason: UnsupportedReason;
64
+ };
65
+ type ExternalSourceTarget = SourceTargetBase & {
66
+ readonly kind: 'external';
67
+ readonly unsupportedReason: UnsupportedReason;
68
+ };
69
+ type UnsupportedSourceTarget = SourceTargetBase & {
70
+ readonly kind: 'unsupported';
71
+ readonly unsupportedReason: UnsupportedReason;
72
+ };
73
+ type SourceTarget = PandaCssSourceTarget | DynamicSourceTarget | ExternalSourceTarget | UnsupportedSourceTarget;
74
+ type InspectorManifestEntry = SourceTarget & {
75
+ readonly protocolVersion: number;
76
+ };
77
+ type InspectorManifest = {
78
+ readonly version: number;
79
+ readonly projectRoot: string;
80
+ readonly generatedAt?: string;
81
+ readonly entries: readonly InspectorManifestEntry[];
82
+ };
83
+ type EditorMetadataUnavailableReason = 'panda-config-missing' | 'panda-config-unreadable' | 'unsupported-panda-config' | 'production-disabled';
84
+ type EditorMetadataSection<T> = {
85
+ readonly status: 'available';
86
+ readonly items: readonly T[];
87
+ } | {
88
+ readonly status: 'unavailable';
89
+ readonly items: readonly [];
90
+ readonly reason: EditorMetadataUnavailableReason;
91
+ readonly message: string;
92
+ };
93
+ type EditorColorTokenMetadata = {
94
+ readonly kind: 'token' | 'semantic-token';
95
+ readonly category: 'colors';
96
+ readonly path: string;
97
+ readonly label: string;
98
+ readonly value?: JsonValue;
99
+ readonly swatch?: string;
100
+ readonly cssVariable?: string;
101
+ readonly presetName?: string;
102
+ readonly conditions?: readonly {
103
+ readonly condition: string;
104
+ readonly value: JsonValue;
105
+ readonly swatch?: string;
106
+ }[];
107
+ readonly sourceTargetId?: string;
108
+ readonly sourcePath?: readonly string[];
109
+ readonly writable?: boolean;
110
+ readonly readonlyReason?: string;
111
+ };
112
+ type EditorFontTokenMetadata = {
113
+ readonly kind: 'token';
114
+ readonly category: 'fonts';
115
+ readonly path: string;
116
+ readonly label: string;
117
+ readonly value?: JsonValue;
118
+ readonly cssVariable?: string;
119
+ readonly presetName?: string;
120
+ readonly sourcePath?: readonly string[];
121
+ };
122
+ type EditorTokenSourceSection = 'tokens.colors' | 'semanticTokens.colors';
123
+ type EditorTokenSourceTarget = {
124
+ readonly id: string;
125
+ readonly kind: 'panda-config';
126
+ readonly file: string;
127
+ readonly absoluteFile?: string;
128
+ readonly range?: SourceRange;
129
+ readonly sourceHash: string;
130
+ readonly configPath: string;
131
+ readonly writableSections: readonly EditorTokenSourceSection[];
132
+ readonly confidence: Confidence;
133
+ readonly writable: boolean;
134
+ readonly readonlyReason?: string;
135
+ };
136
+ type EditorPropertyCategory = 'color' | 'spacing' | 'sizing' | 'typography' | 'layout' | 'border' | 'effects' | 'other';
137
+ type EditorPropertyMetadata = {
138
+ readonly name: string;
139
+ readonly label: string;
140
+ readonly category: EditorPropertyCategory;
141
+ readonly cssProperty?: string;
142
+ readonly aliases: readonly string[];
143
+ readonly tokenCategory?: string;
144
+ readonly defaultUnit?: string;
145
+ };
146
+ type InspectorEditorMetadata = {
147
+ readonly version: number;
148
+ readonly projectRoot: string;
149
+ readonly generatedAt?: string;
150
+ readonly tokenSources: EditorMetadataSection<EditorTokenSourceTarget>;
151
+ readonly colorTokens: EditorMetadataSection<EditorColorTokenMetadata>;
152
+ readonly semanticColorTokens: EditorMetadataSection<EditorColorTokenMetadata>;
153
+ readonly fontTokens?: EditorMetadataSection<EditorFontTokenMetadata>;
154
+ readonly properties: EditorMetadataSection<EditorPropertyMetadata>;
155
+ };
156
+ type ManifestUpdateEvent = {
157
+ readonly version: number;
158
+ readonly changedFiles: readonly string[];
159
+ readonly entryIds: readonly string[];
160
+ };
161
+ type EditorMetadataUpdateEvent = {
162
+ readonly version: number;
163
+ readonly changedFiles: readonly string[];
164
+ readonly tokenSourceIds: readonly string[];
165
+ };
166
+ type SelectedElementState = 'none' | 'no-panda-metadata' | 'single-supported-target' | 'multiple-supported-targets' | 'mixed-targets' | 'multiple-targets' | 'unsupported-target' | 'stale-target';
167
+ type RuntimeStyleEvidence = {
168
+ readonly computedStyles?: readonly RuntimeCssDeclaration[];
169
+ readonly propertyContext?: RuntimePropertyContext;
170
+ readonly attributes?: readonly RuntimeAttribute[];
171
+ readonly bounds?: RuntimeElementBounds;
172
+ readonly ancestors?: readonly string[];
173
+ readonly componentLayers?: readonly RuntimeComponentLayer[];
174
+ };
175
+ type RuntimeCssDeclaration = {
176
+ readonly property: string;
177
+ readonly value: string;
178
+ readonly condition?: PreviewStyleCondition;
179
+ };
180
+ type PreviewStyleCondition = 'hover' | 'focus' | 'focus-visible' | 'active';
181
+ type RuntimePropertyContext = {
182
+ readonly tagName: string;
183
+ readonly display: string;
184
+ readonly parentDisplay?: string;
185
+ readonly position: string;
186
+ readonly overflow: string;
187
+ readonly overflowX: string;
188
+ readonly overflowY: string;
189
+ readonly whiteSpace: string;
190
+ };
191
+ type RuntimeComponentLayer = {
192
+ readonly component: string;
193
+ readonly elements: readonly RuntimeComponentLayerElement[];
194
+ };
195
+ type RuntimeComponentLayerElement = {
196
+ readonly tagName: string;
197
+ readonly source?: string;
198
+ readonly element?: Element;
199
+ readonly inspected?: boolean;
200
+ };
201
+ type RuntimeAttribute = {
202
+ readonly name: string;
203
+ readonly value: string;
204
+ };
205
+ type RuntimeElementBounds = {
206
+ readonly x: number;
207
+ readonly y: number;
208
+ readonly width: number;
209
+ readonly height: number;
210
+ };
211
+ type SelectedElementInfo = {
212
+ readonly state: SelectedElementState;
213
+ readonly editId?: string;
214
+ readonly source?: string;
215
+ readonly component?: string;
216
+ readonly targets: readonly SourceTarget[];
217
+ readonly editableTargets?: readonly PandaCssSourceTarget[];
218
+ readonly readonlyTargets?: readonly SourceTarget[];
219
+ readonly missingTargetIds?: readonly string[];
220
+ readonly evidence?: RuntimeStyleEvidence;
221
+ readonly message?: string;
222
+ };
223
+ type StyleEditRequest = {
224
+ readonly editId: string;
225
+ readonly kind: 'panda-css';
226
+ readonly edits: readonly StyleEdit[];
227
+ readonly options?: StyleEditOptions;
228
+ };
229
+ type StyleEditBatchRequest = {
230
+ readonly kind: 'panda-css-batch';
231
+ readonly requests: readonly StyleEditRequest[];
232
+ readonly options?: Pick<StyleEditOptions, 'write' | 'format'>;
233
+ };
234
+ type InlineCssSourceCreateRequest = {
235
+ readonly editId: string;
236
+ readonly kind: 'panda-css-inline-source';
237
+ readonly jsxSource: string;
238
+ readonly options?: Pick<StyleEditOptions, 'write' | 'format'>;
239
+ };
240
+ type StyleModuleSourceCreateRequest = {
241
+ readonly editId: string;
242
+ readonly kind: 'panda-css-style-module-source';
243
+ readonly componentSource: string;
244
+ readonly name: string;
245
+ readonly edits?: readonly StyleEdit[];
246
+ readonly options?: Pick<StyleEditOptions, 'write' | 'format'>;
247
+ };
248
+ type StyleModuleSourceAttachRequest = {
249
+ readonly editId: string;
250
+ readonly kind: 'panda-css-style-module-attach';
251
+ readonly jsxSource: string;
252
+ readonly componentSource: string;
253
+ readonly name: string;
254
+ readonly options?: Pick<StyleEditOptions, 'write' | 'format'>;
255
+ };
256
+ type StyleModuleSourceDetachRequest = {
257
+ readonly editId: string;
258
+ readonly kind: 'panda-css-style-module-detach';
259
+ readonly jsxSource: string;
260
+ readonly componentSource: string;
261
+ readonly name: string;
262
+ readonly options?: Pick<StyleEditOptions, 'write' | 'format'>;
263
+ };
264
+ type StyleModuleEditRequest = StyleModuleSourceCreateRequest | StyleModuleSourceAttachRequest | StyleModuleSourceDetachRequest;
265
+ type ComponentStyleModuleSource = {
266
+ readonly name: string;
267
+ readonly editId?: string;
268
+ readonly file: string;
269
+ readonly sourceHash?: string;
270
+ readonly styleObject?: PandaStyleObject;
271
+ };
272
+ type ComponentStyleModuleResponse = {
273
+ readonly ok: true;
274
+ readonly componentFile: string;
275
+ readonly styleFile: string;
276
+ readonly importPath: string;
277
+ readonly exists: boolean;
278
+ readonly sources: readonly ComponentStyleModuleSource[];
279
+ readonly warnings?: readonly string[];
280
+ } | {
281
+ readonly ok: false;
282
+ readonly error: StyleEditError;
283
+ };
284
+ type TokenConfigEditRequest = {
285
+ readonly editId: string;
286
+ readonly kind: 'panda-token-config';
287
+ readonly sourceTargetId: string;
288
+ readonly section: EditorTokenSourceSection;
289
+ readonly path: readonly string[];
290
+ readonly value: JsonPrimitive;
291
+ readonly options?: StyleEditOptions;
292
+ };
293
+ type TokenConfigEditResponse = {
294
+ readonly ok: boolean;
295
+ readonly editId: string;
296
+ readonly file?: string;
297
+ readonly diff?: string;
298
+ readonly nextSource?: string;
299
+ readonly written?: boolean;
300
+ readonly metadataUpdate?: EditorMetadataUpdateEvent;
301
+ readonly warnings?: readonly string[];
302
+ readonly error?: StyleEditError;
303
+ };
304
+ type StyleEditOptions = {
305
+ readonly expectedSourceHash?: string;
306
+ readonly write?: boolean;
307
+ readonly format?: boolean;
308
+ };
309
+ type StyleEdit = {
310
+ readonly op: 'set';
311
+ readonly path: readonly string[];
312
+ readonly value: JsonValue;
313
+ } | {
314
+ readonly op: 'delete';
315
+ readonly path: readonly string[];
316
+ } | {
317
+ readonly op: 'rename';
318
+ readonly from: readonly string[];
319
+ readonly to: readonly string[];
320
+ } | {
321
+ readonly op: 'replace-object';
322
+ readonly value: {
323
+ readonly [key: string]: JsonValue;
324
+ };
325
+ };
326
+ type StyleEditErrorCode = 'ambiguous-target' | 'invalid-edit' | 'invalid-path' | 'manifest-entry-not-found' | 'parse-error' | 'path-outside-project' | 'production-disabled' | 'stale-source' | 'unsupported-operation' | 'unsupported-source-shape' | 'write-failed';
327
+ type StyleEditError = {
328
+ readonly code: StyleEditErrorCode;
329
+ readonly message: string;
330
+ readonly details?: JsonValue;
331
+ };
332
+ type StyleEditResponse = {
333
+ readonly ok: boolean;
334
+ readonly editId: string;
335
+ readonly file?: string;
336
+ readonly diff?: string;
337
+ readonly nextSource?: string;
338
+ readonly written?: boolean;
339
+ readonly manifestUpdate?: ManifestUpdateEvent;
340
+ readonly warnings?: readonly string[];
341
+ readonly error?: StyleEditError;
342
+ };
343
+ type StyleEditBatchResponse = {
344
+ readonly ok: boolean;
345
+ readonly editId: '';
346
+ readonly responses: readonly StyleEditResponse[];
347
+ readonly written?: boolean;
348
+ readonly manifestUpdate?: ManifestUpdateEvent;
349
+ readonly error?: StyleEditError;
350
+ };
351
+ type OpenSourceLocationRequest = {
352
+ readonly kind: 'source';
353
+ readonly source: string;
354
+ } | {
355
+ readonly kind: 'component';
356
+ readonly editId: string;
357
+ };
358
+ type OpenSourceLocationErrorCode = 'invalid-request' | 'missing-metadata' | 'open-failed' | 'path-outside-project' | 'file-not-found';
359
+ type OpenSourceLocationResponse = {
360
+ readonly ok: true;
361
+ readonly file: string;
362
+ readonly line?: number;
363
+ readonly column?: number;
364
+ readonly openEditorUrl: string;
365
+ } | {
366
+ readonly ok: false;
367
+ readonly error: {
368
+ readonly code: OpenSourceLocationErrorCode;
369
+ readonly message: string;
370
+ readonly details?: JsonValue;
371
+ };
372
+ };
373
+ type PreviewStyleRule = {
374
+ readonly editId: string;
375
+ readonly declarations: readonly RuntimeCssDeclaration[];
376
+ };
377
+ type PreviewStyleSheet = {
378
+ readonly rules: readonly PreviewStyleRule[];
379
+ };
380
+ //#endregion
381
+ export { StyleModuleEditRequest as $, RuntimeAttribute as A, SourcePosition as B, OpenSourceLocationRequest as C, PreviewStyleCondition as D, PandaStyleObject as E, RuntimePropertyContext as F, StyleEdit as G, SourceTarget as H, RuntimeStyleEvidence as I, StyleEditError as J, StyleEditBatchRequest as K, SelectedElementInfo as L, RuntimeComponentLayerElement as M, RuntimeCssDeclaration as N, PreviewStyleRule as O, RuntimeElementBounds as P, StyleEditResponse as Q, SelectedElementState as R, OpenSourceLocationErrorCode as S, PandaCssSourceTarget as T, SourceTargetBase as U, SourceRange as V, SourceTargetKind as W, StyleEditOptions as X, StyleEditErrorCode as Y, StyleEditRequest as Z, InspectorManifest as _, EditorColorTokenMetadata as a, TokenConfigEditResponse as at, JsonValue as b, EditorMetadataUnavailableReason as c, EditorPropertyMetadata as d, StyleModuleSourceAttachRequest as et, EditorTokenSourceSection as f, InspectorEditorMetadata as g, InlineCssSourceCreateRequest as h, DynamicSourceTarget as i, TokenConfigEditRequest as it, RuntimeComponentLayer as j, PreviewStyleSheet as k, EditorMetadataUpdateEvent as l, ExternalSourceTarget as m, ComponentStyleModuleSource as n, StyleModuleSourceDetachRequest as nt, EditorFontTokenMetadata as o, UnsupportedReason as ot, EditorTokenSourceTarget as p, StyleEditBatchResponse as q, Confidence as r, StyleValueSource as rt, EditorMetadataSection as s, UnsupportedSourceTarget as st, ComponentStyleModuleResponse as t, StyleModuleSourceCreateRequest as tt, EditorPropertyCategory as u, InspectorManifestEntry as v, OpenSourceLocationResponse as w, ManifestUpdateEvent as x, JsonPrimitive as y, SourceLocation as z };
package/dist/ui.d.mts ADDED
@@ -0,0 +1,54 @@
1
+ import { F as RuntimePropertyContext, L as SelectedElementInfo, N as RuntimeCssDeclaration, j as RuntimeComponentLayer } from "./types-CdByW0ji.mjs";
2
+ import { t as PandaRuntimeInspector } from "./runtime-DwE3PVhB.mjs";
3
+
4
+ //#region src/ui/inspectorPanel.d.ts
5
+ type ReadonlyInspectorPanelOptions = {
6
+ readonly title?: string;
7
+ };
8
+ declare function installReadonlyInspectorPanel(runtime: PandaRuntimeInspector, options?: ReadonlyInspectorPanelOptions): HTMLElement;
9
+ //#endregion
10
+ //#region src/ui/selectionView.d.ts
11
+ type ReadonlyInspectorPanelView = {
12
+ readonly status: string;
13
+ readonly message: string;
14
+ readonly source?: string;
15
+ readonly component?: string;
16
+ readonly targetKind?: string;
17
+ readonly editable: boolean;
18
+ readonly styleRows: readonly ReadonlyInspectorPanelRow[];
19
+ readonly editableTargets: readonly ReadonlyInspectorPanelTarget[];
20
+ readonly inlineSourceCreate?: ReadonlyInspectorPanelInlineSourceCreate;
21
+ readonly inspectedJsxSource?: string;
22
+ readonly inspectedComponentSource?: string;
23
+ readonly readonlyTargets: readonly ReadonlyInspectorPanelReadonlyTarget[];
24
+ readonly missingTargetIds: readonly string[];
25
+ readonly componentLayers: readonly RuntimeComponentLayer[];
26
+ readonly propertyContext?: RuntimePropertyContext;
27
+ readonly computedRows: readonly RuntimeCssDeclaration[];
28
+ };
29
+ type ReadonlyInspectorPanelInlineSourceCreate = {
30
+ readonly jsxSource: string;
31
+ };
32
+ type ReadonlyInspectorPanelRow = {
33
+ readonly path: string;
34
+ readonly value: string;
35
+ readonly previewValue?: string;
36
+ };
37
+ type ReadonlyInspectorPanelTarget = {
38
+ readonly id: string;
39
+ readonly name?: string;
40
+ readonly source: string;
41
+ readonly sourceLocation?: string;
42
+ readonly attribute?: string;
43
+ readonly jsxSource?: string;
44
+ readonly jsxSourceAliases?: readonly string[];
45
+ readonly styleRows: readonly ReadonlyInspectorPanelRow[];
46
+ };
47
+ type ReadonlyInspectorPanelReadonlyTarget = {
48
+ readonly id: string;
49
+ readonly kind: string;
50
+ readonly reason: string;
51
+ };
52
+ declare function selectedElementPanelView(info: SelectedElementInfo | undefined): ReadonlyInspectorPanelView;
53
+ //#endregion
54
+ export { type ReadonlyInspectorPanelOptions, type ReadonlyInspectorPanelReadonlyTarget, type ReadonlyInspectorPanelRow, type ReadonlyInspectorPanelTarget, type ReadonlyInspectorPanelView, installReadonlyInspectorPanel, selectedElementPanelView };