@jbpark/live-editor 4.5.0 → 4.6.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 (75) hide show
  1. package/README.ko.md +4 -1
  2. package/README.md +5 -1
  3. package/dist/{boundary-DnjGgsK6.js → boundary-BLB80tyw.js} +2 -2
  4. package/dist/boundary-BLB80tyw.js.map +1 -0
  5. package/dist/cache-B0-XcIxJ.js.map +1 -1
  6. package/dist/{compile-DDfk5P25.js → compile-Dxas-D05.js} +3 -3
  7. package/dist/compile-Dxas-D05.js.map +1 -0
  8. package/dist/{constants-h1JAgOeW.js → constants-DU17Tdwo.js} +3 -3
  9. package/dist/constants-DU17Tdwo.js.map +1 -0
  10. package/dist/{context-DsEXJl4h.js → context-B8MzP7_p.js} +3 -3
  11. package/dist/context-B8MzP7_p.js.map +1 -0
  12. package/dist/{core-CRsAGpei.js → core-Bgfek364.js} +2 -2
  13. package/dist/core-Bgfek364.js.map +1 -0
  14. package/dist/{detect-typescript-CCj9ALXc.js → detect-typescript-Dr_oLniM.js} +2 -2
  15. package/dist/detect-typescript-Dr_oLniM.js.map +1 -0
  16. package/dist/dnd/index.d.ts +1 -1
  17. package/dist/dnd/index.js +1 -1
  18. package/dist/{dnd-DGNp20Nk.js → dnd-V8NAxd_R.js} +435 -413
  19. package/dist/dnd-V8NAxd_R.js.map +1 -0
  20. package/dist/document-CHO215iP.js +33992 -0
  21. package/dist/document-CHO215iP.js.map +1 -0
  22. package/dist/{document-Ct4jW78J.d.ts → document-DqRSCtsx.d.ts} +496 -435
  23. package/dist/editor/index.js +2 -2
  24. package/dist/{editor-DQ8Q--qR.js → editor-CMElfHer.js} +2 -2
  25. package/dist/editor-CMElfHer.js.map +1 -0
  26. package/dist/editor-caches-ClMvdcQF.js.map +1 -1
  27. package/dist/error/index.d.ts +1 -1
  28. package/dist/error/index.js +2 -2
  29. package/dist/{error-DwqwjJ2C.js → error-CN_GCnXB.js} +3 -3
  30. package/dist/{error-DwqwjJ2C.js.map → error-CN_GCnXB.js.map} +1 -1
  31. package/dist/{index-vtyggWy0.d.ts → index-CRwEhJ7w.d.ts} +2 -2
  32. package/dist/index-C_PfR4X9.d.ts +734 -0
  33. package/dist/{index-P9Aifaui.d.ts → index-CiWB0zFb.d.ts} +72 -70
  34. package/dist/{index-WQgFy510.d.ts → index-DrWtSKXu.d.ts} +2 -2
  35. package/dist/index.d.ts +5 -5
  36. package/dist/index.js +6 -6
  37. package/dist/{items-DdrwGxJw.js → items-BXXtMUNI.js} +307 -390
  38. package/dist/items-BXXtMUNI.js.map +1 -0
  39. package/dist/{messages-CzUPVnzH.js → messages-CSrMI4Rm.js} +2 -1
  40. package/dist/messages-CSrMI4Rm.js.map +1 -0
  41. package/dist/{messages-Cp3g1mn1.d.ts → messages-IBPs4TkZ.d.ts} +2 -1
  42. package/dist/preview/index.js +2 -2
  43. package/dist/{preview-BKFgq_5u.js → preview-CtyG5UbH.js} +4 -4
  44. package/dist/{preview-BKFgq_5u.js.map → preview-CtyG5UbH.js.map} +1 -1
  45. package/dist/provider/index.d.ts +2 -2
  46. package/dist/provider/index.js +2 -2
  47. package/dist/{sections-BRH3KHYc.js → sections-jYuqS4KB.js} +3 -3
  48. package/dist/sections-jYuqS4KB.js.map +1 -0
  49. package/dist/states-Ci1AvoQ9.js.map +1 -1
  50. package/dist/{use-dynamic-tailwind-T9r9ExbR.js → use-dynamic-tailwind-BP1toJkW.js} +59 -39
  51. package/dist/use-dynamic-tailwind-BP1toJkW.js.map +1 -0
  52. package/dist/utils/ast/index.d.ts +2 -2
  53. package/dist/utils/ast/index.js +84 -2
  54. package/dist/utils/ast/index.js.map +1 -1
  55. package/dist/utils/index.d.ts +1 -1
  56. package/dist/utils/index.js +4 -4
  57. package/dist/utils/index.js.map +1 -1
  58. package/dist/utils/tailwind/index.js.map +1 -1
  59. package/dist/validate-iLo8IONY.js.map +1 -1
  60. package/package.json +5 -7
  61. package/dist/boundary-DnjGgsK6.js.map +0 -1
  62. package/dist/compile-DDfk5P25.js.map +0 -1
  63. package/dist/constants-h1JAgOeW.js.map +0 -1
  64. package/dist/context-DsEXJl4h.js.map +0 -1
  65. package/dist/core-CRsAGpei.js.map +0 -1
  66. package/dist/detect-typescript-CCj9ALXc.js.map +0 -1
  67. package/dist/dnd-DGNp20Nk.js.map +0 -1
  68. package/dist/document-DGHTfrda.js +0 -38667
  69. package/dist/document-DGHTfrda.js.map +0 -1
  70. package/dist/editor-DQ8Q--qR.js.map +0 -1
  71. package/dist/index-CHknA6k1.d.ts +0 -221
  72. package/dist/items-DdrwGxJw.js.map +0 -1
  73. package/dist/messages-CzUPVnzH.js.map +0 -1
  74. package/dist/sections-BRH3KHYc.js.map +0 -1
  75. package/dist/use-dynamic-tailwind-T9r9ExbR.js.map +0 -1
@@ -0,0 +1,734 @@
1
+ import { b as ExtractedNodeValue$1, c as BindingItem, d as BindingOptions, f as BindingRegistry, g as BindingType, l as BindingKeyMap, m as BindingRenderMap, v as DataAttrNode, x as NodeValueType$1, y as EditableNodeValueType$1 } from "./validate-DB59Z_Nx.js";
2
+ import { C as ObjectExpression, S as Node, b as Expression, x as File, y as ArrayExpression } from "./document-DqRSCtsx.js";
3
+ //#region node_modules/.pnpm/@babel+parser@8.0.6/node_modules/@babel/parser/lib/index.d.ts
4
+ declare const UnparenthesizedPipeBodyDescriptions: Set<"AssignmentExpression" | "ArrowFunctionExpression" | "ConditionalExpression" | "YieldExpression">;
5
+ type GetSetMemberType<T extends Set<any>> = T extends Set<infer M> ? M : unknown;
6
+ type UnparenthesizedPipeBodyTypes = GetSetMemberType<typeof UnparenthesizedPipeBodyDescriptions>;
7
+ declare const _default$5: {
8
+ PipeTopicRequiresHackPipes: string;
9
+ PipeTopicUnbound: string;
10
+ PipeTopicUnconfiguredToken: ({ token }: {
11
+ token: string;
12
+ }) => string;
13
+ PipeTopicUnused: string;
14
+ PipeUnparenthesizedBody: ({ type }: {
15
+ type: UnparenthesizedPipeBodyTypes;
16
+ }) => string;
17
+ PipelineUnparenthesized: string;
18
+ };
19
+ declare class Position {
20
+ line: number;
21
+ column: number;
22
+ index: number;
23
+ constructor(line: number, col: number, index?: number);
24
+ }
25
+ declare const _default$4: {
26
+ ImportMetaOutsideModule: {
27
+ message: string;
28
+ code: "BABEL_PARSER_SOURCETYPE_MODULE_REQUIRED";
29
+ };
30
+ ImportOutsideModule: {
31
+ message: string;
32
+ code: "BABEL_PARSER_SOURCETYPE_MODULE_REQUIRED";
33
+ };
34
+ };
35
+ type LValAncestor = {
36
+ type: "UpdateExpression";
37
+ prefix: boolean;
38
+ } | {
39
+ type: "ArrayPattern" | "AssignmentExpression" | "CatchClause" | "ForOfStatement" | "FormalParameters" | "ForInStatement" | "ForStatement" | "ImportSpecifier" | "ImportNamespaceSpecifier" | "ImportDefaultSpecifier" | "ParenthesizedExpression" | "ObjectPattern" | "RestElement" | "VariableDeclarator";
40
+ };
41
+ declare const _default$3: {
42
+ AccessorIsGenerator: ({ kind }: {
43
+ kind: "get" | "set";
44
+ }) => string;
45
+ ArgumentsInClass: string;
46
+ AsyncFunctionInSingleStatementContext: string;
47
+ AwaitBindingIdentifier: string;
48
+ AwaitBindingIdentifierInStaticBlock: string;
49
+ AwaitExpressionFormalParameter: string;
50
+ AwaitUsingNotInAsyncContext: string;
51
+ AwaitNotInAsyncContext: string;
52
+ BadGetterArity: string;
53
+ BadSetterArity: string;
54
+ BadSetterRestParameter: string;
55
+ ConstructorClassField: string;
56
+ ConstructorClassPrivateField: string;
57
+ ConstructorIsAccessor: string;
58
+ ConstructorIsAsync: string;
59
+ ConstructorIsGenerator: string;
60
+ DeclarationMissingInitializer: ({ kind }: {
61
+ kind: "await using" | "const" | "destructuring" | "using";
62
+ }) => string;
63
+ DecoratorArgumentsOutsideParentheses: string;
64
+ DecoratorsBeforeAfterExport: string;
65
+ DecoratorConstructor: string;
66
+ DecoratorSemicolon: string;
67
+ DecoratorStaticBlock: string;
68
+ DeferImportRequiresNamespace: string;
69
+ DeletePrivateField: string;
70
+ DestructureNamedImport: string;
71
+ DuplicateConstructor: string;
72
+ DuplicateDefaultExport: string;
73
+ DuplicateExport: ({ exportName }: {
74
+ exportName: string;
75
+ }) => string;
76
+ DuplicateProto: string;
77
+ DuplicateRegExpFlags: string;
78
+ ElementAfterRest: string;
79
+ EscapedCharNotAnIdentifier: string;
80
+ ExportBindingIsString: ({ localName, exportName }: {
81
+ localName: string;
82
+ exportName: string;
83
+ }) => string;
84
+ ExportDefaultFromAsIdentifier: string;
85
+ ForInOfLoopInitializer: ({ type }: {
86
+ type: "ForInStatement" | "ForOfStatement";
87
+ }) => string;
88
+ ForInUsing: string;
89
+ ForOfAsync: string;
90
+ ForOfLet: string;
91
+ GeneratorInSingleStatementContext: string;
92
+ IllegalBreakContinue: ({ type }: {
93
+ type: "BreakStatement" | "ContinueStatement";
94
+ }) => string;
95
+ IllegalLanguageModeDirective: string;
96
+ IllegalReturn: string;
97
+ ImportBindingIsString: ({ importName }: {
98
+ importName: string;
99
+ }) => string;
100
+ ImportCallArity: ({ phase }: {
101
+ phase?: string | null;
102
+ }) => string;
103
+ ImportCallNotNewExpression: ({ phase }: {
104
+ phase?: string | null;
105
+ }) => string;
106
+ ImportCallSpreadArgument: ({ phase }: {
107
+ phase?: string | null;
108
+ }) => string;
109
+ IncompatibleRegExpUVFlags: string;
110
+ InvalidBigIntLiteral: string;
111
+ InvalidCodePoint: string;
112
+ InvalidCoverDiscardElement: string;
113
+ InvalidCoverInitializedName: string;
114
+ InvalidDigit: ({ radix }: {
115
+ radix: number;
116
+ }) => string;
117
+ InvalidEscapeSequence: string;
118
+ InvalidEscapeSequenceTemplate: string;
119
+ InvalidEscapedReservedWord: ({ reservedWord }: {
120
+ reservedWord: string;
121
+ }) => string;
122
+ InvalidIdentifier: ({ identifierName }: {
123
+ identifierName: string;
124
+ }) => string;
125
+ InvalidLhs: ({ ancestor }: {
126
+ ancestor: LValAncestor;
127
+ }) => string;
128
+ InvalidLhsBinding: ({ ancestor }: {
129
+ ancestor: LValAncestor;
130
+ }) => string;
131
+ InvalidLhsOptionalChaining: ({ ancestor }: {
132
+ ancestor: LValAncestor;
133
+ }) => string;
134
+ InvalidNumber: string;
135
+ InvalidOrMissingExponent: string;
136
+ InvalidOrUnexpectedToken: ({ unexpected }: {
137
+ unexpected: string;
138
+ }) => string;
139
+ InvalidParenthesizedAssignment: string;
140
+ InvalidPrivateFieldResolution: ({ identifierName }: {
141
+ identifierName: string;
142
+ }) => string;
143
+ InvalidPropertyBindingPattern: string;
144
+ InvalidRestAssignmentPattern: string;
145
+ LabelRedeclaration: ({ labelName }: {
146
+ labelName: string;
147
+ }) => string;
148
+ LetInLexicalBinding: string;
149
+ LineTerminatorBeforeArrow: string;
150
+ MalformedRegExpFlags: string;
151
+ MissingClassName: string;
152
+ MissingEqInAssignment: string;
153
+ MissingSemicolon: string;
154
+ MissingPlugin: ({ missingPlugin }: {
155
+ missingPlugin: [string];
156
+ }) => string;
157
+ MissingOneOfPlugins: ({ missingPlugin }: {
158
+ missingPlugin: string[];
159
+ }) => string;
160
+ MissingUnicodeEscape: string;
161
+ MixingCoalesceWithLogical: string;
162
+ ModuleAttributeInvalidValue: string;
163
+ ModuleAttributesWithDuplicateKeys: ({ key }: {
164
+ key: string;
165
+ }) => string;
166
+ ModuleExportNameHasLoneSurrogate: ({ surrogateCharCode }: {
167
+ surrogateCharCode: number;
168
+ }) => string;
169
+ ModuleExportUndefined: ({ localName }: {
170
+ localName: string;
171
+ }) => string;
172
+ MultipleDefaultsInSwitch: string;
173
+ NewlineAfterThrow: string;
174
+ NoCatchOrFinally: string;
175
+ NumberIdentifier: string;
176
+ NumericSeparatorInEscapeSequence: string;
177
+ ObsoleteAwaitStar: string;
178
+ OptionalChainingNoNew: string;
179
+ OptionalChainingNoTemplate: string;
180
+ OverrideOnConstructor: string;
181
+ ParamDupe: string;
182
+ PatternHasAccessor: string;
183
+ PatternHasMethod: string;
184
+ PrivateInExpectedIn: ({ identifierName }: {
185
+ identifierName: string;
186
+ }) => string;
187
+ PrivateNameRedeclaration: ({ identifierName }: {
188
+ identifierName: string;
189
+ }) => string;
190
+ RestTrailingComma: string;
191
+ SloppyFunction: string;
192
+ SloppyFunctionAnnexB: string;
193
+ SourcePhaseImportRequiresDefault: string;
194
+ StaticPrototype: string;
195
+ SuperCallNotNewExpression: string;
196
+ SuperNotAllowed: string;
197
+ SuperPrivateField: string;
198
+ TrailingDecorator: string;
199
+ UnexpectedArgumentPlaceholder: string;
200
+ UnexpectedDigitAfterHash: string;
201
+ UnexpectedImportExport: string;
202
+ UnexpectedKeyword: ({ keyword }: {
203
+ keyword: string;
204
+ }) => string;
205
+ UnexpectedLeadingDecorator: string;
206
+ UnexpectedLexicalDeclaration: string;
207
+ UnexpectedNewTarget: string;
208
+ UnexpectedNumericSeparator: string;
209
+ UnexpectedPrivateField: string;
210
+ UnexpectedReservedWord: ({ reservedWord }: {
211
+ reservedWord: string;
212
+ }) => string;
213
+ UnexpectedSuper: string;
214
+ UnexpectedToken: ({ expected, unexpected }: {
215
+ expected?: string | null;
216
+ unexpected?: string | null;
217
+ }) => string;
218
+ UnexpectedTokenUnaryExponentiation: string;
219
+ UnexpectedUsingDeclaration: string;
220
+ UnexpectedVoidPattern: string;
221
+ UnsupportedDecoratorExport: string;
222
+ UnsupportedDefaultExport: string;
223
+ UnsupportedImport: string;
224
+ UnsupportedMetaProperty: ({ target, onlyValidPropertyName }: {
225
+ target: string;
226
+ onlyValidPropertyName: string;
227
+ }) => string;
228
+ UnsupportedParameterDecorator: string;
229
+ UnsupportedPropertyDecorator: string;
230
+ UnsupportedSuper: string;
231
+ UnterminatedComment: string;
232
+ UnterminatedRegExp: string;
233
+ UnterminatedString: string;
234
+ UnterminatedTemplate: string;
235
+ UsingDeclarationExport: string;
236
+ UsingDeclarationHasBindingPattern: string;
237
+ VarRedeclaration: ({ identifierName }: {
238
+ identifierName: string;
239
+ }) => string;
240
+ VoidPatternCatchClauseParam: string;
241
+ VoidPatternInitializer: string;
242
+ YieldBindingIdentifier: string;
243
+ YieldInParameter: string;
244
+ YieldNotInGeneratorFunction: string;
245
+ ZeroDigitNumericSeparator: string;
246
+ };
247
+ declare const _default$2: {
248
+ StrictDelete: string;
249
+ StrictEvalArguments: ({ referenceName }: {
250
+ referenceName: string;
251
+ }) => string;
252
+ StrictEvalArgumentsBinding: ({ bindingName }: {
253
+ bindingName: string;
254
+ }) => string;
255
+ StrictFunction: string;
256
+ StrictNumericEscape: string;
257
+ StrictOctalLiteral: string;
258
+ StrictWith: string;
259
+ };
260
+ declare const _default$1: {
261
+ ParseExpressionEmptyInput: string;
262
+ ParseExpressionExpectsEOF: ({ unexpected }: {
263
+ unexpected: number;
264
+ }) => string;
265
+ };
266
+ declare const _default: {
267
+ UnsupportedBind: string;
268
+ UnsupportedBindRHS: string;
269
+ };
270
+ type Accessibility = "public" | "protected" | "private";
271
+ type VarianceAnnotations = "in" | "out";
272
+ declare const JsxErrorTemplates: {
273
+ AttributeIsEmpty: string;
274
+ MissingClosingTagElement: ({ openingTagName }: {
275
+ openingTagName: string;
276
+ }) => string;
277
+ MissingClosingTagFragment: string;
278
+ UnexpectedSequenceExpression: string;
279
+ UnexpectedToken: ({ unexpected, HTMLEntity }: {
280
+ unexpected: string;
281
+ HTMLEntity: string;
282
+ }) => string;
283
+ UnsupportedJsxValue: string;
284
+ UnterminatedJsxContent: string;
285
+ UnwrappedAdjacentJSXElements: string;
286
+ };
287
+ type TsModifier = "readonly" | "abstract" | "declare" | "static" | "override" | "const" | Accessibility | VarianceAnnotations;
288
+ declare const TSErrorTemplates: {
289
+ AbstractMethodHasImplementation: ({ methodName }: {
290
+ methodName: string;
291
+ }) => string;
292
+ AbstractPropertyHasInitializer: ({ propertyName }: {
293
+ propertyName: string;
294
+ }) => string;
295
+ AccessorCannotBeOptional: string;
296
+ AccessorCannotDeclareThisParameter: string;
297
+ AccessorCannotHaveTypeParameters: string;
298
+ ClassMethodHasDeclare: string;
299
+ ClassMethodHasReadonly: string;
300
+ ConstInitializerMustBeStringOrNumericLiteralOrLiteralEnumReference: string;
301
+ ConstructorHasTypeParameters: string;
302
+ DeclaratorDefiniteAssertionRequiresTypeAnnotation: string;
303
+ DeclaratorDefiniteAssertionWithInitializer: string;
304
+ DeclareAccessor: ({ kind }: {
305
+ kind: "get" | "set";
306
+ }) => string;
307
+ DeclareClassFieldHasInitializer: string;
308
+ DeclareFunctionHasImplementation: string;
309
+ DecoratorAbstractMethod: ({ kind }: {
310
+ kind: "abstract method" | "abstract field" | "declare field";
311
+ }) => string;
312
+ DuplicateAccessibilityModifier: ({ modifier }: {
313
+ modifier: Accessibility;
314
+ }) => string;
315
+ DuplicateModifier: ({ modifier }: {
316
+ modifier: TsModifier;
317
+ }) => string;
318
+ EmptyHeritageClauseType: ({ token }: {
319
+ token: "extends" | "implements";
320
+ }) => string;
321
+ EmptyNamespaceName: string;
322
+ EmptyTypeArguments: string;
323
+ EmptyTypeParameters: string;
324
+ ExpectedAmbientAfterExportDeclare: string;
325
+ ExportAssignmentInTSNamespace: string;
326
+ ExportInTSNamespace: string;
327
+ ImportAliasHasImportType: string;
328
+ ImportInTSNamespace: string;
329
+ IncompatibleModifiers: ({ modifiers }: {
330
+ modifiers: [TsModifier, TsModifier];
331
+ }) => string;
332
+ IndexSignatureHasAbstract: string;
333
+ IndexSignatureHasAccessibility: ({ modifier }: {
334
+ modifier: Accessibility;
335
+ }) => string;
336
+ IndexSignatureHasDeclare: string;
337
+ IndexSignatureHasOverride: string;
338
+ IndexSignatureHasStatic: string;
339
+ InitializerNotAllowedInAmbientContext: string;
340
+ InlineModuleDeclarationMustUseString: string;
341
+ InvalidHeritageClauseType: ({ token }: {
342
+ token: "extends" | "implements";
343
+ }) => string;
344
+ InvalidModifierOnAwaitUsingDeclaration: (modifier: TsModifier) => string;
345
+ InvalidModifierOnTypeMember: ({ modifier }: {
346
+ modifier: TsModifier;
347
+ }) => string;
348
+ InvalidModifierOnTypeParameter: ({ modifier }: {
349
+ modifier: TsModifier;
350
+ }) => string;
351
+ InvalidModifierOnTypeParameterPositions: ({ modifier }: {
352
+ modifier: TsModifier;
353
+ }) => string;
354
+ InvalidModifierOnUsingDeclaration: (modifier: TsModifier) => string;
355
+ InvalidModifiersOrder: ({ orderedModifiers }: {
356
+ orderedModifiers: [TsModifier, TsModifier];
357
+ }) => string;
358
+ InvalidNamespaceName: (value: string | number) => string;
359
+ InvalidPropertyAccessAfterInstantiationExpression: string;
360
+ InvalidTupleMemberLabel: string;
361
+ MissingInterfaceName: string;
362
+ NamespaceExportInTSNamespace: string;
363
+ NonAbstractClassHasAbstractMethod: string;
364
+ NonClassMethodPropertyHasAbstractModifier: string;
365
+ OptionalTypeBeforeRequired: string;
366
+ OverrideNotInSubClass: string;
367
+ PatternIsOptional: string;
368
+ PrivateElementHasAbstract: string;
369
+ PrivateElementHasAccessibility: ({ modifier }: {
370
+ modifier: Accessibility;
371
+ }) => string;
372
+ ReadonlyForMethodSignature: string;
373
+ ReservedArrowTypeParam: string;
374
+ ReservedTypeAssertion: string;
375
+ SetAccessorCannotHaveOptionalParameter: string;
376
+ SetAccessorCannotHaveRestParameter: string;
377
+ SetAccessorCannotHaveReturnType: string;
378
+ SingleTypeParameterWithoutTrailingComma: ({ typeParameterName }: {
379
+ typeParameterName: string;
380
+ }) => string;
381
+ StaticBlockCannotHaveModifier: string;
382
+ TupleOptionalAfterType: string;
383
+ TypeAnnotationAfterAssign: string;
384
+ TypeImportCannotSpecifyDefaultAndNamed: string;
385
+ TypeModifierIsUsedInTypeExports: string;
386
+ TypeModifierIsUsedInTypeImports: string;
387
+ UnexpectedParameterInitializer: string;
388
+ UnexpectedParameterModifier: string;
389
+ UnexpectedReadonly: string;
390
+ UnexpectedTypeAnnotation: string;
391
+ UnexpectedTypeCastInParameter: string;
392
+ UnexpectedTypeDeclaration: (type: "interface" | "type") => string;
393
+ UnsupportedImportTypeArgument: string;
394
+ UnsupportedParameterPropertyKind: string;
395
+ UnsupportedSignatureParameterKind: ({ type }: {
396
+ type: string;
397
+ }) => string;
398
+ UsingDeclarationInAmbientContext: (kind: "using" | "await using") => string;
399
+ };
400
+ declare const FlowErrorTemplates: {
401
+ AmbiguousConditionalArrow: string;
402
+ AmbiguousDeclareModuleKind: string;
403
+ AssignReservedType: ({ reservedType }: {
404
+ reservedType: string;
405
+ }) => string;
406
+ DeclareClassElement: string;
407
+ DeclareClassFieldInitializer: string;
408
+ DuplicateDeclareModuleExports: string;
409
+ EnumBooleanMemberNotInitialized: ({ memberName, enumName }: {
410
+ memberName: string;
411
+ enumName: string;
412
+ }) => string;
413
+ EnumDuplicateMemberName: ({ memberName, enumName }: {
414
+ memberName: string;
415
+ enumName: string;
416
+ }) => string;
417
+ EnumInconsistentMemberValues: ({ enumName }: {
418
+ enumName: string;
419
+ }) => string;
420
+ EnumInvalidExplicitType: ({ invalidEnumType, enumName }: {
421
+ invalidEnumType: string;
422
+ enumName: string;
423
+ }) => string;
424
+ EnumInvalidExplicitTypeUnknownSupplied: ({ enumName }: {
425
+ enumName: string;
426
+ }) => string;
427
+ EnumInvalidMemberInitializerPrimaryType: ({ enumName, memberName, explicitType }: {
428
+ enumName: string;
429
+ memberName: string;
430
+ explicitType: EnumExplicitType;
431
+ }) => string;
432
+ EnumInvalidMemberInitializerSymbolType: ({ enumName, memberName }: {
433
+ enumName: string;
434
+ memberName: string;
435
+ explicitType: EnumExplicitType;
436
+ }) => string;
437
+ EnumInvalidMemberInitializerUnknownType: ({ enumName, memberName }: {
438
+ enumName: string;
439
+ memberName: string;
440
+ explicitType: EnumExplicitType;
441
+ }) => string;
442
+ EnumInvalidMemberName: ({ enumName, memberName, suggestion }: {
443
+ enumName: string;
444
+ memberName: string;
445
+ suggestion: string;
446
+ }) => string;
447
+ EnumNumberMemberNotInitialized: ({ enumName, memberName }: {
448
+ enumName: string;
449
+ memberName: string;
450
+ }) => string;
451
+ EnumStringMemberInconsistentlyInitialized: ({ enumName }: {
452
+ enumName: string;
453
+ }) => string;
454
+ GetterMayNotHaveThisParam: string;
455
+ ImportTypeShorthandOnlyInPureImport: string;
456
+ InexactInsideExact: string;
457
+ InexactInsideNonObject: string;
458
+ InexactVariance: string;
459
+ InvalidNonTypeImportInDeclareModule: string;
460
+ MissingTypeParamDefault: string;
461
+ NestedDeclareModule: string;
462
+ NestedFlowComment: string;
463
+ PatternIsOptional: {
464
+ message: string;
465
+ };
466
+ SetterMayNotHaveThisParam: string;
467
+ SpreadVariance: string;
468
+ ThisParamAnnotationRequired: string;
469
+ ThisParamBannedInConstructor: string;
470
+ ThisParamMayNotBeOptional: string;
471
+ ThisParamMustBeFirst: string;
472
+ ThisParamNoDefault: string;
473
+ TypeBeforeInitializer: string;
474
+ TypeCastInPattern: string;
475
+ UnexpectedExplicitInexactInObject: string;
476
+ UnexpectedReservedType: ({ reservedType }: {
477
+ reservedType: string;
478
+ }) => string;
479
+ UnexpectedReservedUnderscore: string;
480
+ UnexpectedSpaceBetweenModuloChecks: string;
481
+ UnexpectedSpreadType: string;
482
+ UnexpectedSubtractionOperand: string;
483
+ UnexpectedTokenAfterTypeParameter: string;
484
+ UnexpectedTypeParameterBeforeAsyncArrowFunction: string;
485
+ UnsupportedDeclareExportKind: ({ unsupportedExportKind, suggestion }: {
486
+ unsupportedExportKind: string;
487
+ suggestion: string;
488
+ }) => string;
489
+ UnsupportedStatementInDeclareModule: string;
490
+ UnterminatedFlowComment: string;
491
+ };
492
+ type EnumExplicitType = null | "boolean" | "number" | "string" | "symbol";
493
+ type ParseError = SyntaxError & {
494
+ missingPlugin?: string | string[];
495
+ loc: Position;
496
+ pos: number;
497
+ } & ErrorInfo;
498
+ type ToMessage<ErrorDetails> = (self: ErrorDetails) => string;
499
+ type ErrorToObject<T> = { [K in keyof T]: {
500
+ code: T[K] extends {
501
+ code: string;
502
+ } ? T[K]["code"] : "BABEL_PARSER_SYNTAX_ERROR";
503
+ reasonCode: K;
504
+ details: T[K] extends {
505
+ message: string | ToMessage<any>;
506
+ } ? T[K]["message"] extends ToMessage<any> ? Parameters<T[K]["message"]>[0] : object : T[K] extends ToMessage<any> ? Parameters<T[K]>[0] : object;
507
+ }; };
508
+ type __ExtractMe = typeof _default$4 & typeof _default$3 & typeof _default$2 & typeof _default$1 & typeof _default & typeof _default$5 & typeof TSErrorTemplates & typeof FlowErrorTemplates & typeof JsxErrorTemplates & typeof PlaceholderErrorTemplates;
509
+ type __PatchMe = never & Decompress<ErrorInfoCompressed>;
510
+ type ErrorsObjects = ErrorToObject<__ExtractMe>;
511
+ type ErrorInfo = __PatchMe | ErrorsObjects[keyof ErrorsObjects];
512
+ type ErrorInfoCompressed = {};
513
+ type Decompress<T extends object> = { [K in keyof T]: T[K] extends [infer Param, infer Code] ? {
514
+ code: Code;
515
+ reasonCode: K;
516
+ details: Param;
517
+ } : T[K] extends [infer Param] ? {
518
+ code: "BABEL_PARSER_SYNTAX_ERROR";
519
+ reasonCode: K;
520
+ details: Param;
521
+ } : T[K] extends [] ? {
522
+ code: "BABEL_PARSER_SYNTAX_ERROR";
523
+ reasonCode: K;
524
+ details: object;
525
+ } : never; };
526
+ declare const PlaceholderErrorTemplates: {
527
+ ClassNameIsRequired: string;
528
+ UnexpectedSpace: string;
529
+ };
530
+ type ParseResult<Result extends File | Expression = File> = Result & {
531
+ comments: File["comments"];
532
+ errors: ParseError[];
533
+ tokens?: File["tokens"];
534
+ };
535
+ //#endregion
536
+ //#region src/utils/ast/extract.d.ts
537
+ declare function extract(raw: string, options?: BindingOptions): DataAttrNode[];
538
+ declare function clearExtractCache$1(): void;
539
+ //#endregion
540
+ //#region src/utils/ast/items.d.ts
541
+ type ItemKind$1 = 'object' | 'primitive';
542
+ interface ArrayItem$1 {
543
+ index: number;
544
+ kind: ItemKind$1;
545
+ node: Expression;
546
+ }
547
+ //#endregion
548
+ //#region src/utils/ast/binding.d.ts
549
+ declare const findEditableChildren: (node: DataAttrNode) => DataAttrNode[];
550
+ //#endregion
551
+ //#region src/utils/ast/editable-value.d.ts
552
+ type EditablePathSegment = string | number;
553
+ type EditablePrimitive = string | number | boolean;
554
+ interface EditableValueEntry {
555
+ path: EditablePathSegment[];
556
+ value: EditablePrimitive;
557
+ }
558
+ declare const flattenEditableValue: (value: string) => EditableValueEntry[] | null;
559
+ declare const setEditableValue: (value: string, path: EditablePathSegment[], next: EditablePrimitive) => string;
560
+ //#endregion
561
+ //#region src/utils/ast/value.d.ts
562
+ declare const parseValue: (value: unknown) => unknown;
563
+ //#endregion
564
+ //#region src/utils/ast/update.d.ts
565
+ type UpdateFailure = {
566
+ reason: 'element-not-found';
567
+ dataId: string;
568
+ } | {
569
+ reason: 'no-binding';
570
+ dataId: string;
571
+ } | {
572
+ reason: 'reserved-property';
573
+ dataId: string;
574
+ property: string;
575
+ } | {
576
+ reason: 'required-property';
577
+ dataId: string;
578
+ property: string;
579
+ } | {
580
+ reason: 'binding-not-declared';
581
+ dataId: string;
582
+ label: string;
583
+ property?: string;
584
+ } | {
585
+ reason: 'duplicate-binding';
586
+ dataId: string;
587
+ label: string;
588
+ property?: string;
589
+ count: number;
590
+ } | {
591
+ reason: 'attribute-not-found';
592
+ dataId: string;
593
+ property: string;
594
+ } | {
595
+ reason: 'self-closing';
596
+ dataId: string;
597
+ property: string;
598
+ } | {
599
+ reason: 'unsupported-syntax';
600
+ dataId: string;
601
+ property: string;
602
+ } | {
603
+ reason: 'parse-error';
604
+ error: unknown;
605
+ };
606
+ interface UpdateResult {
607
+ code: string;
608
+ success: boolean;
609
+ failure?: UpdateFailure;
610
+ failures?: UpdateFailure[];
611
+ }
612
+ declare const update: (code: string, dataId: string, label: string, value: unknown, property?: string, options?: BindingOptions) => UpdateResult;
613
+ interface UpdateEntry {
614
+ dataId: string;
615
+ label: string;
616
+ value: unknown;
617
+ property?: string;
618
+ }
619
+ type UpdateAllResult = {
620
+ success: true;
621
+ code: string;
622
+ } | {
623
+ success: false;
624
+ code: string;
625
+ failure: UpdateFailure;
626
+ index: number;
627
+ };
628
+ declare const updateAll: (raw: string, entries: UpdateEntry[], options?: BindingOptions) => UpdateAllResult;
629
+ /**
630
+ * @deprecated Not atomic: when an entry fails, the ones before and after it
631
+ * are still applied, and the returned `code` carries them. Use `updateAll`,
632
+ * which applies every entry or none. Will be removed in the next major.
633
+ */
634
+ declare const bulkUpdate: (raw: string, entries: UpdateEntry[]) => UpdateResult;
635
+ //#endregion
636
+ //#region src/utils/ast/children.d.ts
637
+ type ChildrenAction = {
638
+ type: 'move';
639
+ from: number;
640
+ to: number;
641
+ } | {
642
+ type: 'move-selected';
643
+ indices: number[];
644
+ direction: 'up' | 'down';
645
+ } | {
646
+ type: 'remove' | 'duplicate';
647
+ indices: number[];
648
+ } | {
649
+ type: 'append';
650
+ };
651
+ interface ChildrenEdit {
652
+ kind: 'children-edit';
653
+ expected: string[];
654
+ action: ChildrenAction;
655
+ }
656
+ declare const getChildrenSignatures: (nodes: DataAttrNode[]) => string[];
657
+ //#endregion
658
+ //#region src/utils/ast/index.d.ts
659
+ /** @deprecated Internal. Use `useDndItems` from `./dnd`. Removed in the next major. */
660
+ declare const appendArrayItem: (code: string, kind: ItemKind$1, generateId?: () => string) => string | null;
661
+ /** @deprecated Internal. Use `useDndItems` from `./dnd`. Removed in the next major. */
662
+ declare const duplicateArrayItems: (code: string, indices: Set<number>, generateId?: () => string) => string | null;
663
+ /** @deprecated Internal. Use `useDndItems` from `./dnd`. Removed in the next major. */
664
+ declare const moveArrayItem: (code: string, from: number, to: number) => string | null;
665
+ /** @deprecated Internal. Use `useDndItems` from `./dnd`. Removed in the next major. */
666
+ declare const moveArrayItems: (code: string, indices: Set<number>, direction: "up" | "down") => {
667
+ code: string;
668
+ indices: Set<number>;
669
+ } | null;
670
+ /** @deprecated Internal. Use `useDndItems` from `./dnd`. Removed in the next major. */
671
+ declare const parseItems: (code: string) => ArrayItem$1[] | null;
672
+ /** @deprecated Internal. Use `useDndItems` from `./dnd`. Removed in the next major. */
673
+ declare const removeArrayItems: (code: string, indices: Set<number>, kind?: ItemKind$1) => string | null;
674
+ /** @deprecated Internal. Use `useDndItems` from `./dnd`. Removed in the next major. */
675
+ declare const updateArrayItemProperty: (code: string, index: number, key: string, value: unknown, render?: BindingRenderMap) => string | null;
676
+ /** @deprecated Internal. Use `useDndItems` from `./dnd`. Removed in the next major. */
677
+ declare const updateArrayItemValue: (code: string, index: number, value: unknown) => string | null;
678
+ /** @deprecated Internal. Use `useDndItems` from `./dnd`. Removed in the next major. */
679
+ declare const parseArrayExpression: (value: string) => ArrayExpression | null;
680
+ /** @deprecated Internal. Use `useDndItems` from `./dnd`. Removed in the next major. */
681
+ declare const arrayExpressionToCode: (elements: ObjectExpression[]) => string;
682
+ /** @deprecated Internal. Use `useDndItems` from `./dnd`. Removed in the next major. */
683
+ declare const canStructurallyEditArray: (source: string) => boolean;
684
+ /** @deprecated Internal. Use `useDndItems` from `./dnd`. Removed in the next major. */
685
+ type ArrayItem = ArrayItem$1;
686
+ /** @deprecated Internal. Use `useDndItems` from `./dnd`. Removed in the next major. */
687
+ type ItemKind = ItemKind$1;
688
+ /** @deprecated Internal. Read values through `extract` or `PanelBinding.value`. Removed in the next major. */
689
+ declare const extractNodeValue: (node: Node) => ExtractedNodeValue$1;
690
+ /** @deprecated Internal. Read values through `extract` or `PanelBinding.value`. Removed in the next major. */
691
+ declare const extractObjectProperties: (element: ObjectExpression) => Record<string, ExtractedNodeValue$1 & {
692
+ astNode: Node;
693
+ }>;
694
+ /** @deprecated Internal. Write values through `update` or `PanelBinding.onChange`. Removed in the next major. */
695
+ declare const createNodeFromValue: (type: NodeValueType$1, value: unknown) => Expression | null;
696
+ /** @deprecated Internal. Check `PanelBinding.canEditValue` instead. Removed in the next major. */
697
+ declare const canLosslesslyEvaluateSource: (source: string) => boolean;
698
+ /** @deprecated Internal. Read values through `extract` or `PanelBinding.value`. Removed in the next major. */
699
+ declare const getCurrentValue: (node: DataAttrNode, property: string) => string;
700
+ /** @deprecated Internal. Read values through `extract` or `PanelBinding.value`. Removed in the next major. */
701
+ declare const getStructuredValue: (node: DataAttrNode, property: string, type?: BindingType) => unknown;
702
+ /** @deprecated Internal. Removed in the next major. */
703
+ type ExtractedNodeValue = ExtractedNodeValue$1;
704
+ /** @deprecated Internal. Removed in the next major. */
705
+ type NodeValueType = NodeValueType$1;
706
+ /** @deprecated Internal. Removed in the next major. */
707
+ type EditableNodeValueType = EditableNodeValueType$1;
708
+ /** @deprecated Internal. Read bindings through `extract` or `useDndPanel().bindings`. Removed in the next major. */
709
+ declare const parseBinding: (bindingValue: string | null) => BindingItem[];
710
+ /** @deprecated Internal. Read bindings through `extract` or `useDndPanel().bindings`. Removed in the next major. */
711
+ declare const parseBindingExpression: (expression: ArrayExpression) => BindingItem[];
712
+ /** @deprecated Internal. Read bindings through `extract` or `useDndPanel().bindings`. Removed in the next major. */
713
+ declare const readNodeBindings: (node: DataAttrNode) => BindingItem[];
714
+ /** @deprecated Internal. Read bindings through `extract` or `useDndPanel().bindings`. Removed in the next major. */
715
+ declare const resolveBindings: (own: BindingItem[] | undefined, key: string | null | undefined, tagName: string, options?: BindingOptions) => BindingItem[];
716
+ /** @deprecated Internal. Read bindings through `extract` or `useDndPanel().bindings`. Removed in the next major. */
717
+ declare const getKeyBindings: (bindingKeys: BindingKeyMap | undefined, key: string) => BindingItem[] | undefined;
718
+ /** @deprecated Internal. Read bindings through `extract` or `useDndPanel().bindings`. Removed in the next major. */
719
+ declare const getRegistryBindings: (registry: BindingRegistry | undefined, tagName: string) => BindingItem[] | undefined;
720
+ /** @deprecated Internal. Removed in the next major. */
721
+ declare const isComponentTagName: (tagName: string) => boolean;
722
+ /** @deprecated Internal. Removed in the next major. */
723
+ declare const fillIds: (code: string, generateId?: () => string) => string;
724
+ /** @deprecated Internal. Removed in the next major. */
725
+ declare const replaceIds: (code: string, generateId?: () => string) => string;
726
+ /** @deprecated Internal. Removed in the next major. */
727
+ declare const clone: (element: Node, generateId?: () => string) => ParseResult<Expression>;
728
+ /** @deprecated Internal. Removed in the next major. */
729
+ declare const generateCode: (node: Node) => string;
730
+ /** @deprecated Internal. Use `clearEditorCaches` from `./utils`. Removed in the next major. */
731
+ declare const clearExtractCache: typeof clearExtractCache$1;
732
+ //#endregion
733
+ export { removeArrayItems as A, UpdateFailure as B, moveArrayItem as C, parseBindingExpression as D, parseBinding as E, ChildrenAction as F, parseValue as G, bulkUpdate as H, ChildrenEdit as I, EditableValueEntry as J, EditablePathSegment as K, getChildrenSignatures as L, resolveBindings as M, updateArrayItemProperty as N, parseItems as O, updateArrayItemValue as P, extract as Q, UpdateAllResult as R, isComponentTagName as S, parseArrayExpression as T, update as U, UpdateResult as V, updateAll as W, setEditableValue as X, flattenEditableValue as Y, findEditableChildren as Z, generateCode as _, NodeValueType as a, getRegistryBindings as b, canLosslesslyEvaluateSource as c, clone as d, createNodeFromValue as f, fillIds as g, extractObjectProperties as h, ItemKind as i, replaceIds as j, readNodeBindings as k, canStructurallyEditArray as l, extractNodeValue as m, EditableNodeValueType as n, appendArrayItem as o, duplicateArrayItems as p, EditablePrimitive as q, ExtractedNodeValue as r, arrayExpressionToCode as s, ArrayItem as t, clearExtractCache as u, getCurrentValue as v, moveArrayItems as w, getStructuredValue as x, getKeyBindings as y, UpdateEntry as z };
734
+ //# sourceMappingURL=index-C_PfR4X9.d.ts.map