@bonsae/nrg 0.16.0 → 0.18.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 +112 -19
- package/package.json +38 -6
- package/server/index.cjs +38 -24
- package/server/resources/nrg-client.js +3667 -3521
- package/test/client/component/index.js +244 -0
- package/test/client/component/setup.js +201 -0
- package/test/client/e2e/index.js +2698 -0
- package/test/client/unit/index.js +200 -0
- package/test/client/unit/setup.js +199 -0
- package/test/{index.js → server/unit/index.js} +23 -8
- package/tsconfig/core/client.json +11 -0
- package/tsconfig/{server.json → core/server.json} +1 -1
- package/tsconfig/test/client/component.json +11 -0
- package/tsconfig/test/client/e2e.json +6 -0
- package/tsconfig/test/client/unit.json +6 -0
- package/tsconfig/test/server/unit.json +6 -0
- package/types/client.d.ts +66 -0
- package/types/server.d.ts +74 -58
- package/types/shims/form/components/node-red-config-input.vue.d.ts +15 -2
- package/types/shims/form/components/node-red-editor-input.vue.d.ts +18 -3
- package/types/shims/form/components/node-red-input.vue.d.ts +17 -5
- package/types/shims/form/components/node-red-json-schema-form.vue.d.ts +117 -19
- package/types/shims/form/components/node-red-select-input.vue.d.ts +15 -1
- package/types/shims/form/components/node-red-typed-input.vue.d.ts +52 -8
- package/types/test-client-component.d.ts +70 -0
- package/types/test-client-e2e.d.ts +152 -0
- package/types/test-client-unit.d.ts +52 -0
- package/types/{test.d.ts → test-server-unit.d.ts} +12 -2
- package/vite/index.js +15 -7
- package/tsconfig/client.json +0 -11
package/types/server.d.ts
CHANGED
|
@@ -364,45 +364,6 @@ interface NrgSchemaExtensions {
|
|
|
364
364
|
toggle?: boolean;
|
|
365
365
|
};
|
|
366
366
|
}
|
|
367
|
-
/** Schema type representing a reference to a config node. Resolves to the node instance at runtime. */
|
|
368
|
-
export interface TNodeRef<T = any> extends TSchema {
|
|
369
|
-
[Kind]: "NodeRef";
|
|
370
|
-
static: T;
|
|
371
|
-
type: "string";
|
|
372
|
-
format: "node-id";
|
|
373
|
-
"x-nrg-node-type"?: string;
|
|
374
|
-
}
|
|
375
|
-
type ResolveNodeRefs<T> = T extends TypedInput<any> ? T : T extends (...args: any[]) => any ? T : T extends Array<infer Item> ? ResolveNodeRefs<Item>[] : T extends object ? {
|
|
376
|
-
[K in keyof T]: ResolveNodeRefs<T[K]>;
|
|
377
|
-
} : T;
|
|
378
|
-
/**
|
|
379
|
-
* Infers the TypeScript type from a schema or a record of schemas.
|
|
380
|
-
*
|
|
381
|
-
* - Single schema: `Infer<typeof MySchema>` → the inferred message type
|
|
382
|
-
* - Record of schemas: `Infer<typeof outputsSchema>` → `{ portName: InferredType }` port map
|
|
383
|
-
*
|
|
384
|
-
* The record form produces a simple mapped type that resolves eagerly,
|
|
385
|
-
* giving `sendToPort()` proper autocomplete in class-based nodes.
|
|
386
|
-
*/
|
|
387
|
-
export type Infer<T extends TSchema | Record<string, TSchema>> = T extends TSchema ? ResolveNodeRefs<Static<T>> : {
|
|
388
|
-
[K in keyof T & string]: T[K] extends TSchema ? ResolveNodeRefs<Static<T[K]>> : never;
|
|
389
|
-
};
|
|
390
|
-
type TypedInputType = (typeof TYPED_INPUT_TYPES)[number];
|
|
391
|
-
/** Schema type representing a Node-RED TypedInput (value + type pair). */
|
|
392
|
-
export interface TTypedInput<T = unknown> extends TSchema {
|
|
393
|
-
[Kind]: "TypedInput";
|
|
394
|
-
static: TypedInput<T>;
|
|
395
|
-
}
|
|
396
|
-
interface NrgSchemaOptions extends SchemaOptions, NrgSchemaExtensions {
|
|
397
|
-
}
|
|
398
|
-
/** An NRG object schema created by {@link defineSchema}. */
|
|
399
|
-
export type Schema<T extends TProperties = TProperties> = TObject<T>;
|
|
400
|
-
type InferOr<T, Fallback> = T extends TSchema ? Infer<T> : Fallback;
|
|
401
|
-
type InferOutputs<T> = T extends readonly TSchema[] ? {
|
|
402
|
-
[K in keyof T]: T[K] extends TSchema ? Infer<T[K]> : never;
|
|
403
|
-
} : T extends TSchema ? Infer<T> : T extends Record<string, TSchema> ? {
|
|
404
|
-
[K in keyof T & string]: Infer<T[K]>;
|
|
405
|
-
} : any;
|
|
406
367
|
declare const NodeConfigSchema: import("@sinclair/typebox").TObject<{
|
|
407
368
|
id: import("@sinclair/typebox").TString;
|
|
408
369
|
type: import("@sinclair/typebox").TString;
|
|
@@ -426,6 +387,11 @@ declare const IONodeConfigSchema: import("@sinclair/typebox").TObject<{
|
|
|
426
387
|
name: import("@sinclair/typebox").TString;
|
|
427
388
|
z: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
|
|
428
389
|
}>;
|
|
390
|
+
export declare const NodeSourceSchema: import("@sinclair/typebox").TObject<{
|
|
391
|
+
id: import("@sinclair/typebox").TString;
|
|
392
|
+
type: import("@sinclair/typebox").TString;
|
|
393
|
+
name: import("@sinclair/typebox").TString;
|
|
394
|
+
}>;
|
|
429
395
|
export declare const ErrorPortSchema: import("@sinclair/typebox").TObject<{
|
|
430
396
|
error: import("@sinclair/typebox").TObject<{
|
|
431
397
|
message: import("@sinclair/typebox").TString;
|
|
@@ -446,23 +412,74 @@ export declare const CompletePortSchema: import("@sinclair/typebox").TObject<{
|
|
|
446
412
|
}>;
|
|
447
413
|
}>;
|
|
448
414
|
export declare const StatusPortSchema: import("@sinclair/typebox").TObject<{
|
|
449
|
-
status: import("@sinclair/typebox").
|
|
450
|
-
|
|
451
|
-
import("@sinclair/typebox").
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
import("@sinclair/typebox").
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
415
|
+
status: import("@sinclair/typebox").TUnion<[
|
|
416
|
+
import("@sinclair/typebox").TObject<{
|
|
417
|
+
fill: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnion<[
|
|
418
|
+
import("@sinclair/typebox").TLiteral<"red">,
|
|
419
|
+
import("@sinclair/typebox").TLiteral<"green">
|
|
420
|
+
]>>;
|
|
421
|
+
shape: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUnion<[
|
|
422
|
+
import("@sinclair/typebox").TLiteral<"dot">,
|
|
423
|
+
import("@sinclair/typebox").TLiteral<"string">
|
|
424
|
+
]>>;
|
|
425
|
+
text: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
|
|
426
|
+
}>,
|
|
427
|
+
import("@sinclair/typebox").TString
|
|
428
|
+
]>;
|
|
460
429
|
source: import("@sinclair/typebox").TObject<{
|
|
461
430
|
id: import("@sinclair/typebox").TString;
|
|
462
431
|
type: import("@sinclair/typebox").TString;
|
|
463
432
|
name: import("@sinclair/typebox").TString;
|
|
464
433
|
}>;
|
|
465
434
|
}>;
|
|
435
|
+
interface NodeRefResolved<T = any> {
|
|
436
|
+
readonly __nrg_node_ref: true;
|
|
437
|
+
readonly __instance: T;
|
|
438
|
+
}
|
|
439
|
+
/** Schema type representing a reference to a config node. Resolves to the node instance at runtime. */
|
|
440
|
+
export interface TNodeRef<T = any> extends TSchema {
|
|
441
|
+
[Kind]: "NodeRef";
|
|
442
|
+
static: NodeRefResolved<T>;
|
|
443
|
+
type: "string";
|
|
444
|
+
format: "node-id";
|
|
445
|
+
"x-nrg-node-type"?: string;
|
|
446
|
+
}
|
|
447
|
+
type ResolveNodeRefs<T> = T extends NodeRefResolved<infer I> ? I : T extends TypedInput<any> ? T : T extends (...args: any[]) => any ? T : T extends Array<infer Item> ? ResolveNodeRefs<Item>[] : T extends object ? {
|
|
448
|
+
[K in keyof T]: ResolveNodeRefs<T[K]>;
|
|
449
|
+
} : T;
|
|
450
|
+
/**
|
|
451
|
+
* Infers the TypeScript type from a schema or a record of schemas.
|
|
452
|
+
*
|
|
453
|
+
* - Single schema: `Infer<typeof MySchema>` → the inferred message type
|
|
454
|
+
* - Record of schemas: `Infer<typeof outputsSchema>` → `{ portName: InferredType }` port map
|
|
455
|
+
*
|
|
456
|
+
* The record form produces a simple mapped type that resolves eagerly,
|
|
457
|
+
* giving `sendToPort()` proper autocomplete in class-based nodes.
|
|
458
|
+
*/
|
|
459
|
+
export type Infer<T extends TSchema | Record<string, TSchema>> = T extends TSchema ? ResolveNodeRefs<Static<T>> : {
|
|
460
|
+
[K in keyof T & string]: T[K] extends TSchema ? ResolveNodeRefs<Static<T[K]>> : never;
|
|
461
|
+
};
|
|
462
|
+
type TypedInputType = (typeof TYPED_INPUT_TYPES)[number];
|
|
463
|
+
/** Schema type representing a Node-RED TypedInput (value + type pair). */
|
|
464
|
+
export interface TTypedInput<T = unknown> extends TSchema {
|
|
465
|
+
[Kind]: "TypedInput";
|
|
466
|
+
static: TypedInput<T>;
|
|
467
|
+
"x-nrg-typed-input": true;
|
|
468
|
+
}
|
|
469
|
+
interface NrgSchemaOptions extends SchemaOptions, NrgSchemaExtensions {
|
|
470
|
+
}
|
|
471
|
+
/** An NRG object schema created by {@link defineSchema}. */
|
|
472
|
+
export type Schema<T extends TProperties = TProperties> = TObject<T>;
|
|
473
|
+
export type NodeSource = Static<typeof NodeSourceSchema>;
|
|
474
|
+
export type ErrorPortMessage = Static<typeof ErrorPortSchema>;
|
|
475
|
+
export type CompletePortMessage = Static<typeof CompletePortSchema>;
|
|
476
|
+
export type StatusPortMessage = Static<typeof StatusPortSchema>;
|
|
477
|
+
type InferOr<T, Fallback> = T extends TSchema ? Infer<T> : Fallback;
|
|
478
|
+
type InferOutputs<T> = T extends readonly TSchema[] ? {
|
|
479
|
+
[K in keyof T]: T[K] extends TSchema ? Infer<T[K]> : never;
|
|
480
|
+
} : T extends TSchema ? Infer<T> : T extends Record<string, TSchema> ? {
|
|
481
|
+
[K in keyof T & string]: Infer<T[K]>;
|
|
482
|
+
} : any;
|
|
466
483
|
declare function NodeRef<T extends new (...args: any[]) => any>(nodeClass: T, options?: NrgSchemaOptions): TNodeRef<InstanceType<T>>;
|
|
467
484
|
declare function TypedInput$1<T = unknown>(options?: NrgSchemaOptions): TTypedInput<T>;
|
|
468
485
|
/**
|
|
@@ -620,17 +637,16 @@ export declare abstract class IONode<TConfig = any, TCredentials = any, TInput =
|
|
|
620
637
|
get totalOutputs(): number;
|
|
621
638
|
/**
|
|
622
639
|
* Send a message to a specific output port by index or name.
|
|
623
|
-
* Built-in port `"status"` is resolved automatically based on the node's
|
|
624
|
-
* built-in port configuration.
|
|
625
640
|
* Custom named ports are resolved from `outputsSchema` when it is a record.
|
|
626
641
|
* Numeric indices refer to the base output ports (0-based).
|
|
627
642
|
*
|
|
628
|
-
*
|
|
629
|
-
* cannot be sent to directly.
|
|
630
|
-
*
|
|
643
|
+
* Built-in ports (`"error"`, `"complete"`, `"status"`) are managed by the
|
|
644
|
+
* framework and cannot be sent to directly. Use `this.status()` for status,
|
|
645
|
+
* throw an error or call `this.error()` for the error port, and the complete
|
|
646
|
+
* port is sent automatically on successful input processing.
|
|
631
647
|
*/
|
|
632
|
-
sendToPort<P extends (TOutput extends Record<string, Record<string, any>> ? keyof TOutput & string : never) | number
|
|
633
|
-
status(status: IONodeStatus
|
|
648
|
+
sendToPort<P extends (TOutput extends Record<string, Record<string, any>> ? keyof TOutput & string : never) | number>(port: P, msg: P extends keyof TOutput ? TOutput[P] : unknown): void;
|
|
649
|
+
status(status: IONodeStatus): void;
|
|
634
650
|
error(message: string, msg?: any): void;
|
|
635
651
|
updateWires(wires: string[][]): void;
|
|
636
652
|
receive(msg: TInput): void;
|
|
@@ -674,7 +690,7 @@ export interface IIONode<TConfig = any, TCredentials = any, TInput = any, TOutpu
|
|
|
674
690
|
receive(msg: TInput): void;
|
|
675
691
|
readonly baseOutputs: number;
|
|
676
692
|
readonly totalOutputs: number;
|
|
677
|
-
sendToPort<P extends (TOutput extends Record<string, Record<string, any>> ? keyof TOutput & string : never) | number
|
|
693
|
+
sendToPort<P extends (TOutput extends Record<string, Record<string, any>> ? keyof TOutput & string : never) | number>(port: P, msg: P extends keyof TOutput ? TOutput[P] : unknown): void;
|
|
678
694
|
}
|
|
679
695
|
interface IONodeDefinition<TConfigSchema extends TSchema | undefined = undefined, TCredsSchema extends TSchema | undefined = undefined, TSettingsSchema extends TSchema | undefined = undefined, TInputSchema extends TSchema | undefined = undefined, TOutputsSchema extends TSchema | readonly TSchema[] | Record<string, TSchema> | undefined = undefined> {
|
|
680
696
|
type: string;
|
|
@@ -1,4 +1,8 @@
|
|
|
1
1
|
declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
2
|
+
modelValue: {
|
|
3
|
+
type: StringConstructor;
|
|
4
|
+
default: undefined;
|
|
5
|
+
};
|
|
2
6
|
value: {
|
|
3
7
|
type: StringConstructor;
|
|
4
8
|
default: string;
|
|
@@ -31,9 +35,16 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
31
35
|
type: StringConstructor;
|
|
32
36
|
default: string;
|
|
33
37
|
};
|
|
34
|
-
}>, {
|
|
38
|
+
}>, {
|
|
39
|
+
jqInput: import("vue").ShallowRef<any, any>;
|
|
40
|
+
}, {}, {
|
|
35
41
|
inputId(): string;
|
|
36
|
-
|
|
42
|
+
effectiveValue(): string;
|
|
43
|
+
}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:modelValue" | "update:value")[], "update:modelValue" | "update:value", import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
44
|
+
modelValue: {
|
|
45
|
+
type: StringConstructor;
|
|
46
|
+
default: undefined;
|
|
47
|
+
};
|
|
37
48
|
value: {
|
|
38
49
|
type: StringConstructor;
|
|
39
50
|
default: string;
|
|
@@ -67,11 +78,13 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
67
78
|
default: string;
|
|
68
79
|
};
|
|
69
80
|
}>> & Readonly<{
|
|
81
|
+
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
70
82
|
"onUpdate:value"?: ((...args: any[]) => any) | undefined;
|
|
71
83
|
}>, {
|
|
72
84
|
label: string;
|
|
73
85
|
icon: string;
|
|
74
86
|
required: boolean;
|
|
87
|
+
modelValue: string;
|
|
75
88
|
value: string;
|
|
76
89
|
error: string;
|
|
77
90
|
}, {}, {
|
|
@@ -1,4 +1,8 @@
|
|
|
1
1
|
declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
2
|
+
modelValue: {
|
|
3
|
+
type: StringConstructor;
|
|
4
|
+
default: undefined;
|
|
5
|
+
};
|
|
2
6
|
value: {
|
|
3
7
|
type: StringConstructor;
|
|
4
8
|
default: string;
|
|
@@ -24,16 +28,25 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
24
28
|
type: StringConstructor;
|
|
25
29
|
default: string;
|
|
26
30
|
};
|
|
27
|
-
}>, {
|
|
31
|
+
}>, {
|
|
32
|
+
editor: import("vue").ShallowRef<any, any>;
|
|
33
|
+
expandedEditorTray: import("vue").ShallowRef<any, any>;
|
|
34
|
+
}, {
|
|
28
35
|
editorId: string;
|
|
29
36
|
stateId: string;
|
|
30
37
|
trayElement: HTMLElement | null;
|
|
31
|
-
}, {
|
|
38
|
+
}, {
|
|
39
|
+
effectiveValue(): string;
|
|
40
|
+
}, {
|
|
32
41
|
mountEditor(): void;
|
|
33
42
|
createEditorInstance(): void;
|
|
34
43
|
createExpandeEditorTray(): void;
|
|
35
44
|
onClickExpand(): void;
|
|
36
|
-
}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:value" | "editor-ready" | "tray-open" | "tray-close")[], "update:value" | "editor-ready" | "tray-open" | "tray-close", import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
45
|
+
}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:modelValue" | "update:value" | "editor-ready" | "tray-open" | "tray-close")[], "update:modelValue" | "update:value" | "editor-ready" | "tray-open" | "tray-close", import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
46
|
+
modelValue: {
|
|
47
|
+
type: StringConstructor;
|
|
48
|
+
default: undefined;
|
|
49
|
+
};
|
|
37
50
|
value: {
|
|
38
51
|
type: StringConstructor;
|
|
39
52
|
default: string;
|
|
@@ -60,6 +73,7 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
60
73
|
default: string;
|
|
61
74
|
};
|
|
62
75
|
}>> & Readonly<{
|
|
76
|
+
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
63
77
|
"onUpdate:value"?: ((...args: any[]) => any) | undefined;
|
|
64
78
|
"onEditor-ready"?: ((...args: any[]) => any) | undefined;
|
|
65
79
|
"onTray-open"?: ((...args: any[]) => any) | undefined;
|
|
@@ -68,6 +82,7 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
68
82
|
label: string;
|
|
69
83
|
icon: string;
|
|
70
84
|
required: boolean;
|
|
85
|
+
modelValue: string;
|
|
71
86
|
value: string;
|
|
72
87
|
error: string;
|
|
73
88
|
language: string;
|
|
@@ -1,6 +1,10 @@
|
|
|
1
1
|
declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
2
|
+
modelValue: {
|
|
3
|
+
type: (StringConstructor | NumberConstructor)[];
|
|
4
|
+
default: undefined;
|
|
5
|
+
};
|
|
2
6
|
value: {
|
|
3
|
-
type: StringConstructor;
|
|
7
|
+
type: (StringConstructor | NumberConstructor)[];
|
|
4
8
|
default: string;
|
|
5
9
|
};
|
|
6
10
|
type: {
|
|
@@ -29,13 +33,19 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
29
33
|
};
|
|
30
34
|
}>, {}, {
|
|
31
35
|
internalValue: string;
|
|
32
|
-
}, {
|
|
36
|
+
}, {
|
|
37
|
+
effectiveValue(): string;
|
|
38
|
+
}, {
|
|
33
39
|
onInput(event: any): void;
|
|
34
40
|
onFocus(): void;
|
|
35
41
|
onBlur(): void;
|
|
36
|
-
}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("input" | "update:value")[], "input" | "update:value", import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
42
|
+
}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("input" | "update:modelValue" | "update:value")[], "input" | "update:modelValue" | "update:value", import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
43
|
+
modelValue: {
|
|
44
|
+
type: (StringConstructor | NumberConstructor)[];
|
|
45
|
+
default: undefined;
|
|
46
|
+
};
|
|
37
47
|
value: {
|
|
38
|
-
type: StringConstructor;
|
|
48
|
+
type: (StringConstructor | NumberConstructor)[];
|
|
39
49
|
default: string;
|
|
40
50
|
};
|
|
41
51
|
type: {
|
|
@@ -64,13 +74,15 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
64
74
|
};
|
|
65
75
|
}>> & Readonly<{
|
|
66
76
|
onInput?: ((...args: any[]) => any) | undefined;
|
|
77
|
+
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
67
78
|
"onUpdate:value"?: ((...args: any[]) => any) | undefined;
|
|
68
79
|
}>, {
|
|
69
80
|
label: string;
|
|
70
81
|
type: string;
|
|
71
82
|
icon: string;
|
|
72
83
|
required: boolean;
|
|
73
|
-
|
|
84
|
+
modelValue: string | number;
|
|
85
|
+
value: string | number;
|
|
74
86
|
placeholder: string;
|
|
75
87
|
error: string;
|
|
76
88
|
}, {}, {
|
|
@@ -102,8 +102,12 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
102
102
|
modelValue: boolean;
|
|
103
103
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
104
104
|
NodeRedInput: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
105
|
+
modelValue: {
|
|
106
|
+
type: (StringConstructor | NumberConstructor)[];
|
|
107
|
+
default: undefined;
|
|
108
|
+
};
|
|
105
109
|
value: {
|
|
106
|
-
type: StringConstructor;
|
|
110
|
+
type: (StringConstructor | NumberConstructor)[];
|
|
107
111
|
default: string;
|
|
108
112
|
};
|
|
109
113
|
type: {
|
|
@@ -132,13 +136,19 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
132
136
|
};
|
|
133
137
|
}>, {}, {
|
|
134
138
|
internalValue: string;
|
|
135
|
-
}, {
|
|
139
|
+
}, {
|
|
140
|
+
effectiveValue(): string;
|
|
141
|
+
}, {
|
|
136
142
|
onInput(event: any): void;
|
|
137
143
|
onFocus(): void;
|
|
138
144
|
onBlur(): void;
|
|
139
|
-
}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("input" | "update:value")[], "input" | "update:value", import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
145
|
+
}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("input" | "update:modelValue" | "update:value")[], "input" | "update:modelValue" | "update:value", import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
146
|
+
modelValue: {
|
|
147
|
+
type: (StringConstructor | NumberConstructor)[];
|
|
148
|
+
default: undefined;
|
|
149
|
+
};
|
|
140
150
|
value: {
|
|
141
|
-
type: StringConstructor;
|
|
151
|
+
type: (StringConstructor | NumberConstructor)[];
|
|
142
152
|
default: string;
|
|
143
153
|
};
|
|
144
154
|
type: {
|
|
@@ -167,13 +177,15 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
167
177
|
};
|
|
168
178
|
}>> & Readonly<{
|
|
169
179
|
onInput?: ((...args: any[]) => any) | undefined;
|
|
180
|
+
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
170
181
|
"onUpdate:value"?: ((...args: any[]) => any) | undefined;
|
|
171
182
|
}>, {
|
|
172
183
|
label: string;
|
|
173
184
|
type: string;
|
|
174
185
|
icon: string;
|
|
175
186
|
required: boolean;
|
|
176
|
-
|
|
187
|
+
modelValue: string | number;
|
|
188
|
+
value: string | number;
|
|
177
189
|
placeholder: string;
|
|
178
190
|
error: string;
|
|
179
191
|
}, {}, {
|
|
@@ -212,6 +224,10 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
212
224
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
213
225
|
}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
214
226
|
NodeRedSelectInput: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
227
|
+
modelValue: {
|
|
228
|
+
type: (StringConstructor | ArrayConstructor)[];
|
|
229
|
+
default: undefined;
|
|
230
|
+
};
|
|
215
231
|
value: {
|
|
216
232
|
type: (StringConstructor | ArrayConstructor)[];
|
|
217
233
|
default: () => string;
|
|
@@ -247,7 +263,15 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
247
263
|
type: StringConstructor;
|
|
248
264
|
default: string;
|
|
249
265
|
};
|
|
250
|
-
}>, {
|
|
266
|
+
}>, {
|
|
267
|
+
selectWidget: import("vue").ShallowRef<any, any>;
|
|
268
|
+
}, {}, {
|
|
269
|
+
effectiveValue(): string | unknown[];
|
|
270
|
+
}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:modelValue" | "update:value")[], "update:modelValue" | "update:value", import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
271
|
+
modelValue: {
|
|
272
|
+
type: (StringConstructor | ArrayConstructor)[];
|
|
273
|
+
default: undefined;
|
|
274
|
+
};
|
|
251
275
|
value: {
|
|
252
276
|
type: (StringConstructor | ArrayConstructor)[];
|
|
253
277
|
default: () => string;
|
|
@@ -284,11 +308,13 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
284
308
|
default: string;
|
|
285
309
|
};
|
|
286
310
|
}>> & Readonly<{
|
|
311
|
+
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
287
312
|
"onUpdate:value"?: ((...args: any[]) => any) | undefined;
|
|
288
313
|
}>, {
|
|
289
314
|
label: string;
|
|
290
315
|
icon: string;
|
|
291
316
|
required: boolean;
|
|
317
|
+
modelValue: string | unknown[];
|
|
292
318
|
value: string | unknown[];
|
|
293
319
|
error: string;
|
|
294
320
|
multiple: boolean;
|
|
@@ -328,13 +354,27 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
328
354
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
329
355
|
}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
330
356
|
NodeRedTypedInput: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
357
|
+
modelValue: {
|
|
358
|
+
type: PropType<{
|
|
359
|
+
value: string;
|
|
360
|
+
type: string;
|
|
361
|
+
} | undefined>;
|
|
362
|
+
default: undefined;
|
|
363
|
+
validator: (obj: {
|
|
364
|
+
value: string;
|
|
365
|
+
type: string;
|
|
366
|
+
} | undefined) => boolean;
|
|
367
|
+
};
|
|
331
368
|
value: {
|
|
332
|
-
type:
|
|
333
|
-
|
|
369
|
+
type: PropType<{
|
|
370
|
+
value: string;
|
|
371
|
+
type: string;
|
|
372
|
+
} | undefined>;
|
|
373
|
+
default: undefined;
|
|
334
374
|
validator: (obj: {
|
|
335
375
|
value: string;
|
|
336
376
|
type: string;
|
|
337
|
-
}) => boolean;
|
|
377
|
+
} | undefined) => boolean;
|
|
338
378
|
};
|
|
339
379
|
types: {
|
|
340
380
|
type: PropType<(NodeRED.DefaultTypedInputType | NodeRED.TypedInputTypeDefinition)[]>;
|
|
@@ -356,18 +396,39 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
356
396
|
type: StringConstructor;
|
|
357
397
|
default: string;
|
|
358
398
|
};
|
|
359
|
-
}>, {
|
|
399
|
+
}>, {
|
|
400
|
+
inputWidget: import("vue").ShallowRef<any, any>;
|
|
401
|
+
mutationObserver: import("vue").ShallowRef<MutationObserver | null, MutationObserver | null>;
|
|
402
|
+
}, {}, {
|
|
403
|
+
effectiveValue(): {
|
|
404
|
+
value: string;
|
|
405
|
+
type: string;
|
|
406
|
+
};
|
|
360
407
|
isProvidedValueTypeValid(): boolean;
|
|
361
408
|
}, {
|
|
362
409
|
onChange(): void;
|
|
363
|
-
}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "update:value"[], "update:value", import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
410
|
+
}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:modelValue" | "update:value")[], "update:modelValue" | "update:value", import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
411
|
+
modelValue: {
|
|
412
|
+
type: PropType<{
|
|
413
|
+
value: string;
|
|
414
|
+
type: string;
|
|
415
|
+
} | undefined>;
|
|
416
|
+
default: undefined;
|
|
417
|
+
validator: (obj: {
|
|
418
|
+
value: string;
|
|
419
|
+
type: string;
|
|
420
|
+
} | undefined) => boolean;
|
|
421
|
+
};
|
|
364
422
|
value: {
|
|
365
|
-
type:
|
|
366
|
-
|
|
423
|
+
type: PropType<{
|
|
424
|
+
value: string;
|
|
425
|
+
type: string;
|
|
426
|
+
} | undefined>;
|
|
427
|
+
default: undefined;
|
|
367
428
|
validator: (obj: {
|
|
368
429
|
value: string;
|
|
369
430
|
type: string;
|
|
370
|
-
}) => boolean;
|
|
431
|
+
} | undefined) => boolean;
|
|
371
432
|
};
|
|
372
433
|
types: {
|
|
373
434
|
type: PropType<(NodeRED.DefaultTypedInputType | NodeRED.TypedInputTypeDefinition)[]>;
|
|
@@ -390,11 +451,20 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
390
451
|
default: string;
|
|
391
452
|
};
|
|
392
453
|
}>> & Readonly<{
|
|
454
|
+
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
393
455
|
"onUpdate:value"?: ((...args: any[]) => any) | undefined;
|
|
394
456
|
}>, {
|
|
395
457
|
label: string;
|
|
396
458
|
icon: string;
|
|
397
459
|
required: boolean;
|
|
460
|
+
modelValue: {
|
|
461
|
+
value: string;
|
|
462
|
+
type: string;
|
|
463
|
+
} | undefined;
|
|
464
|
+
value: {
|
|
465
|
+
value: string;
|
|
466
|
+
type: string;
|
|
467
|
+
} | undefined;
|
|
398
468
|
error: string;
|
|
399
469
|
types: ("msg" | "flow" | "global" | "str" | "num" | "bool" | "json" | "bin" | "re" | "jsonata" | "date" | "env" | "node" | "cred" | NodeRED.TypedInputTypeDefinition)[];
|
|
400
470
|
}, {}, {
|
|
@@ -433,6 +503,10 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
433
503
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
434
504
|
}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
435
505
|
NodeRedConfigInput: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
506
|
+
modelValue: {
|
|
507
|
+
type: StringConstructor;
|
|
508
|
+
default: undefined;
|
|
509
|
+
};
|
|
436
510
|
value: {
|
|
437
511
|
type: StringConstructor;
|
|
438
512
|
default: string;
|
|
@@ -465,9 +539,16 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
465
539
|
type: StringConstructor;
|
|
466
540
|
default: string;
|
|
467
541
|
};
|
|
468
|
-
}>, {
|
|
542
|
+
}>, {
|
|
543
|
+
jqInput: import("vue").ShallowRef<any, any>;
|
|
544
|
+
}, {}, {
|
|
469
545
|
inputId(): string;
|
|
470
|
-
|
|
546
|
+
effectiveValue(): string;
|
|
547
|
+
}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:modelValue" | "update:value")[], "update:modelValue" | "update:value", import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
548
|
+
modelValue: {
|
|
549
|
+
type: StringConstructor;
|
|
550
|
+
default: undefined;
|
|
551
|
+
};
|
|
471
552
|
value: {
|
|
472
553
|
type: StringConstructor;
|
|
473
554
|
default: string;
|
|
@@ -501,11 +582,13 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
501
582
|
default: string;
|
|
502
583
|
};
|
|
503
584
|
}>> & Readonly<{
|
|
585
|
+
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
504
586
|
"onUpdate:value"?: ((...args: any[]) => any) | undefined;
|
|
505
587
|
}>, {
|
|
506
588
|
label: string;
|
|
507
589
|
icon: string;
|
|
508
590
|
required: boolean;
|
|
591
|
+
modelValue: string;
|
|
509
592
|
value: string;
|
|
510
593
|
error: string;
|
|
511
594
|
}, {}, {
|
|
@@ -544,6 +627,10 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
544
627
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
545
628
|
}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
546
629
|
NodeRedEditorInput: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
630
|
+
modelValue: {
|
|
631
|
+
type: StringConstructor;
|
|
632
|
+
default: undefined;
|
|
633
|
+
};
|
|
547
634
|
value: {
|
|
548
635
|
type: StringConstructor;
|
|
549
636
|
default: string;
|
|
@@ -569,16 +656,25 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
569
656
|
type: StringConstructor;
|
|
570
657
|
default: string;
|
|
571
658
|
};
|
|
572
|
-
}>, {
|
|
659
|
+
}>, {
|
|
660
|
+
editor: import("vue").ShallowRef<any, any>;
|
|
661
|
+
expandedEditorTray: import("vue").ShallowRef<any, any>;
|
|
662
|
+
}, {
|
|
573
663
|
editorId: string;
|
|
574
664
|
stateId: string;
|
|
575
665
|
trayElement: HTMLElement | null;
|
|
576
|
-
}, {
|
|
666
|
+
}, {
|
|
667
|
+
effectiveValue(): string;
|
|
668
|
+
}, {
|
|
577
669
|
mountEditor(): void;
|
|
578
670
|
createEditorInstance(): void;
|
|
579
671
|
createExpandeEditorTray(): void;
|
|
580
672
|
onClickExpand(): void;
|
|
581
|
-
}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:value" | "editor-ready" | "tray-open" | "tray-close")[], "update:value" | "editor-ready" | "tray-open" | "tray-close", import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
673
|
+
}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:modelValue" | "update:value" | "editor-ready" | "tray-open" | "tray-close")[], "update:modelValue" | "update:value" | "editor-ready" | "tray-open" | "tray-close", import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
674
|
+
modelValue: {
|
|
675
|
+
type: StringConstructor;
|
|
676
|
+
default: undefined;
|
|
677
|
+
};
|
|
582
678
|
value: {
|
|
583
679
|
type: StringConstructor;
|
|
584
680
|
default: string;
|
|
@@ -605,6 +701,7 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
605
701
|
default: string;
|
|
606
702
|
};
|
|
607
703
|
}>> & Readonly<{
|
|
704
|
+
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
608
705
|
"onUpdate:value"?: ((...args: any[]) => any) | undefined;
|
|
609
706
|
"onEditor-ready"?: ((...args: any[]) => any) | undefined;
|
|
610
707
|
"onTray-open"?: ((...args: any[]) => any) | undefined;
|
|
@@ -613,6 +710,7 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
613
710
|
label: string;
|
|
614
711
|
icon: string;
|
|
615
712
|
required: boolean;
|
|
713
|
+
modelValue: string;
|
|
616
714
|
value: string;
|
|
617
715
|
error: string;
|
|
618
716
|
language: string;
|
|
@@ -1,4 +1,8 @@
|
|
|
1
1
|
declare const _default: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
2
|
+
modelValue: {
|
|
3
|
+
type: (StringConstructor | ArrayConstructor)[];
|
|
4
|
+
default: undefined;
|
|
5
|
+
};
|
|
2
6
|
value: {
|
|
3
7
|
type: (StringConstructor | ArrayConstructor)[];
|
|
4
8
|
default: () => string;
|
|
@@ -34,7 +38,15 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
34
38
|
type: StringConstructor;
|
|
35
39
|
default: string;
|
|
36
40
|
};
|
|
37
|
-
}>, {
|
|
41
|
+
}>, {
|
|
42
|
+
selectWidget: import("vue").ShallowRef<any, any>;
|
|
43
|
+
}, {}, {
|
|
44
|
+
effectiveValue(): string | unknown[];
|
|
45
|
+
}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("update:modelValue" | "update:value")[], "update:modelValue" | "update:value", import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
46
|
+
modelValue: {
|
|
47
|
+
type: (StringConstructor | ArrayConstructor)[];
|
|
48
|
+
default: undefined;
|
|
49
|
+
};
|
|
38
50
|
value: {
|
|
39
51
|
type: (StringConstructor | ArrayConstructor)[];
|
|
40
52
|
default: () => string;
|
|
@@ -71,11 +83,13 @@ declare const _default: import("vue").DefineComponent<import("vue").ExtractPropT
|
|
|
71
83
|
default: string;
|
|
72
84
|
};
|
|
73
85
|
}>> & Readonly<{
|
|
86
|
+
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
74
87
|
"onUpdate:value"?: ((...args: any[]) => any) | undefined;
|
|
75
88
|
}>, {
|
|
76
89
|
label: string;
|
|
77
90
|
icon: string;
|
|
78
91
|
required: boolean;
|
|
92
|
+
modelValue: string | unknown[];
|
|
79
93
|
value: string | unknown[];
|
|
80
94
|
error: string;
|
|
81
95
|
multiple: boolean;
|