@lace-cloud/proto 0.16.1 → 0.17.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/dist/index.cjs +447 -2931
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.mts +217 -550
- package/dist/index.d.ts +217 -550
- package/dist/index.mjs +437 -2916
- package/dist/index.mjs.map +1 -1
- package/package.json +3 -2
package/dist/index.mjs
CHANGED
|
@@ -1,224 +1,47 @@
|
|
|
1
1
|
// src/converters.ts
|
|
2
|
-
var NODE_KIND_MODULE = 1;
|
|
3
|
-
var NODE_KIND_RESOURCE = 2;
|
|
4
|
-
var NODE_KIND_DATA = 3;
|
|
5
|
-
var INPUT_MODE_EMPTY = 1;
|
|
6
|
-
var INPUT_MODE_LITERAL = 2;
|
|
7
|
-
var INPUT_MODE_VARIABLE = 3;
|
|
8
|
-
var INPUT_MODE_EXPRESSION = 4;
|
|
9
|
-
var INPUT_MODE_WIRED = 5;
|
|
10
2
|
var DIAGNOSTIC_SEVERITY_WARNING = 2;
|
|
11
3
|
var DIAGNOSTIC_SEVERITY_INFO = 3;
|
|
12
|
-
function
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
return "module";
|
|
16
|
-
case NODE_KIND_RESOURCE:
|
|
17
|
-
return "resource";
|
|
18
|
-
case NODE_KIND_DATA:
|
|
19
|
-
return "data";
|
|
20
|
-
default:
|
|
21
|
-
return "module";
|
|
22
|
-
}
|
|
23
|
-
}
|
|
24
|
-
function convertInputMode(value) {
|
|
25
|
-
switch (value) {
|
|
26
|
-
case INPUT_MODE_LITERAL:
|
|
27
|
-
return "literal";
|
|
28
|
-
case INPUT_MODE_VARIABLE:
|
|
29
|
-
return "variable";
|
|
30
|
-
case INPUT_MODE_EXPRESSION:
|
|
31
|
-
return "expression";
|
|
32
|
-
case INPUT_MODE_WIRED:
|
|
33
|
-
return "wired";
|
|
34
|
-
default:
|
|
35
|
-
return "empty";
|
|
36
|
-
}
|
|
37
|
-
}
|
|
38
|
-
function convertDiagnosticSeverity(value) {
|
|
39
|
-
switch (value) {
|
|
4
|
+
function convertDiagnostic(d) {
|
|
5
|
+
let severity;
|
|
6
|
+
switch (d.severity) {
|
|
40
7
|
case DIAGNOSTIC_SEVERITY_WARNING:
|
|
41
|
-
|
|
8
|
+
severity = "warning";
|
|
9
|
+
break;
|
|
42
10
|
case DIAGNOSTIC_SEVERITY_INFO:
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
return "error";
|
|
46
|
-
}
|
|
47
|
-
}
|
|
48
|
-
function modeToInputMode(mode) {
|
|
49
|
-
switch (mode) {
|
|
50
|
-
case "literal":
|
|
51
|
-
return INPUT_MODE_LITERAL;
|
|
52
|
-
case "variable":
|
|
53
|
-
return INPUT_MODE_VARIABLE;
|
|
54
|
-
case "expression":
|
|
55
|
-
return INPUT_MODE_EXPRESSION;
|
|
56
|
-
case "wired":
|
|
57
|
-
return INPUT_MODE_WIRED;
|
|
11
|
+
severity = "info";
|
|
12
|
+
break;
|
|
58
13
|
default:
|
|
59
|
-
|
|
14
|
+
severity = "error";
|
|
60
15
|
}
|
|
61
|
-
}
|
|
62
|
-
function convertRenderInput(input) {
|
|
63
|
-
return {
|
|
64
|
-
name: input.name,
|
|
65
|
-
type: input.type,
|
|
66
|
-
required: input.required,
|
|
67
|
-
description: input.description || void 0,
|
|
68
|
-
default_value: input.default_value ?? void 0,
|
|
69
|
-
validation: input.validation ? { condition: input.validation.condition, error_message: input.validation.error_message } : void 0,
|
|
70
|
-
mode: convertInputMode(input.mode),
|
|
71
|
-
value: input.value ?? void 0,
|
|
72
|
-
variable: input.variable || void 0,
|
|
73
|
-
expression: input.expression || void 0,
|
|
74
|
-
wired_source: input.wired_source || void 0
|
|
75
|
-
};
|
|
76
|
-
}
|
|
77
|
-
function convertRenderNode(node) {
|
|
78
|
-
return {
|
|
79
|
-
id: node.id,
|
|
80
|
-
label: node.label,
|
|
81
|
-
kind: convertNodeKind(node.kind),
|
|
82
|
-
module_key: node.module_key || void 0,
|
|
83
|
-
position: node.position ?? { x: 0, y: 0 },
|
|
84
|
-
has_errors: node.has_errors,
|
|
85
|
-
error_messages: node.error_messages,
|
|
86
|
-
inputs: node.inputs.map((p) => ({
|
|
87
|
-
name: p.name,
|
|
88
|
-
type: p.type,
|
|
89
|
-
required: p.required || void 0,
|
|
90
|
-
wired: p.wired || void 0,
|
|
91
|
-
description: p.description || void 0
|
|
92
|
-
})),
|
|
93
|
-
outputs: node.outputs.map((p) => ({
|
|
94
|
-
name: p.name,
|
|
95
|
-
type: p.type,
|
|
96
|
-
wired: p.wired || void 0,
|
|
97
|
-
description: p.description || void 0,
|
|
98
|
-
sensitive: p.sensitive || void 0
|
|
99
|
-
}))
|
|
100
|
-
};
|
|
101
|
-
}
|
|
102
|
-
function convertRenderError(error) {
|
|
103
|
-
return {
|
|
104
|
-
instance_id: error.instance_id || void 0,
|
|
105
|
-
input_name: error.input_name || void 0,
|
|
106
|
-
message: error.message
|
|
107
|
-
};
|
|
108
|
-
}
|
|
109
|
-
function convertCanvasView(proto) {
|
|
110
|
-
return {
|
|
111
|
-
module_name: proto.module_name,
|
|
112
|
-
nodes: proto.nodes.map(convertRenderNode),
|
|
113
|
-
edges: proto.edges.map((e) => ({
|
|
114
|
-
id: e.id,
|
|
115
|
-
source: e.source,
|
|
116
|
-
target: e.target,
|
|
117
|
-
source_output: e.source_output,
|
|
118
|
-
target_input: e.target_input
|
|
119
|
-
})),
|
|
120
|
-
errors: proto.errors.map(convertRenderError),
|
|
121
|
-
can_undo: proto.can_undo,
|
|
122
|
-
can_redo: proto.can_redo,
|
|
123
|
-
is_dirty: proto.is_dirty,
|
|
124
|
-
groups: proto.groups.map((g) => ({
|
|
125
|
-
id: g.id,
|
|
126
|
-
label: g.label,
|
|
127
|
-
node_ids: g.node_ids,
|
|
128
|
-
collapsed: g.collapsed,
|
|
129
|
-
module_key: g.module_key || void 0,
|
|
130
|
-
inputs: g.inputs && g.inputs.length > 0 ? g.inputs : void 0,
|
|
131
|
-
outputs: g.outputs && g.outputs.length > 0 ? g.outputs : void 0
|
|
132
|
-
}))
|
|
133
|
-
};
|
|
134
|
-
}
|
|
135
|
-
function convertNodeConfig(proto) {
|
|
136
|
-
return {
|
|
137
|
-
instance_id: proto.instance_id,
|
|
138
|
-
inputs: proto.inputs.map(convertRenderInput),
|
|
139
|
-
outputs: proto.outputs.map((o) => ({
|
|
140
|
-
name: o.name,
|
|
141
|
-
type: o.type,
|
|
142
|
-
description: o.description || void 0,
|
|
143
|
-
sensitive: o.sensitive
|
|
144
|
-
})),
|
|
145
|
-
sibling_ids: proto.sibling_ids,
|
|
146
|
-
depends_on: proto.depends_on,
|
|
147
|
-
providers: proto.providers ?? {},
|
|
148
|
-
available_variables: proto.available_variables.map((v) => ({ name: v.name, type: v.type }))
|
|
149
|
-
};
|
|
150
|
-
}
|
|
151
|
-
function convertEdgeConfig(proto) {
|
|
152
|
-
return {
|
|
153
|
-
source_instance: proto.source_instance,
|
|
154
|
-
target_instance: proto.target_instance,
|
|
155
|
-
source_outputs: proto.source_outputs.map((o) => ({
|
|
156
|
-
name: o.name,
|
|
157
|
-
type: o.type,
|
|
158
|
-
description: o.description || void 0,
|
|
159
|
-
sensitive: o.sensitive
|
|
160
|
-
})),
|
|
161
|
-
target_unbound_inputs: proto.target_unbound_inputs.map(convertRenderInput)
|
|
162
|
-
};
|
|
163
|
-
}
|
|
164
|
-
function convertSettingsConfig(proto) {
|
|
165
|
-
return {
|
|
166
|
-
terraform: {
|
|
167
|
-
required_version: proto.terraform?.required_version ?? "",
|
|
168
|
-
required_providers: (proto.terraform?.required_providers ?? []).map((p) => ({
|
|
169
|
-
name: p.name,
|
|
170
|
-
source: p.source,
|
|
171
|
-
version: p.version,
|
|
172
|
-
configuration_aliases: p.configuration_aliases && p.configuration_aliases.length > 0 ? p.configuration_aliases : void 0
|
|
173
|
-
}))
|
|
174
|
-
},
|
|
175
|
-
providers: proto.providers.map((p) => ({
|
|
176
|
-
name: p.name,
|
|
177
|
-
alias: p.alias,
|
|
178
|
-
config: p.config ?? {},
|
|
179
|
-
blocks: p.blocks && p.blocks.length > 0 ? p.blocks : void 0
|
|
180
|
-
})),
|
|
181
|
-
locals: proto.locals.map((l) => ({
|
|
182
|
-
name: l.name,
|
|
183
|
-
mode: l.mode,
|
|
184
|
-
value_display: l.value_display
|
|
185
|
-
})),
|
|
186
|
-
environments: proto.environments ?? {},
|
|
187
|
-
variables: (proto.variables ?? []).map((v) => ({
|
|
188
|
-
name: v.name,
|
|
189
|
-
type: v.type,
|
|
190
|
-
required: v.required,
|
|
191
|
-
description: v.description || void 0,
|
|
192
|
-
default_value: v.default_value,
|
|
193
|
-
validation: v.validation && v.validation.length > 0 ? v.validation.map((b) => ({ condition: b.condition, error_message: b.error_message })) : void 0,
|
|
194
|
-
ephemeral: v.ephemeral,
|
|
195
|
-
sensitive: v.sensitive,
|
|
196
|
-
nullable: v.nullable
|
|
197
|
-
})),
|
|
198
|
-
exports: (proto.exports ?? []).map((e) => ({
|
|
199
|
-
name: e.name,
|
|
200
|
-
source_instance: e.source_instance,
|
|
201
|
-
source_output: e.source_output
|
|
202
|
-
})),
|
|
203
|
-
output_defs: (proto.output_defs ?? []).map((d) => ({
|
|
204
|
-
name: d.name,
|
|
205
|
-
type: d.type,
|
|
206
|
-
description: d.description || void 0,
|
|
207
|
-
sensitive: d.sensitive,
|
|
208
|
-
depends_on: d.depends_on && d.depends_on.length > 0 ? d.depends_on : void 0
|
|
209
|
-
}))
|
|
210
|
-
};
|
|
211
|
-
}
|
|
212
|
-
function convertDiagnostic(d) {
|
|
213
16
|
return {
|
|
214
|
-
severity
|
|
17
|
+
severity,
|
|
215
18
|
message: d.message,
|
|
19
|
+
module_key: d.module_key || void 0,
|
|
20
|
+
instance_id: d.instance_id || void 0,
|
|
21
|
+
input_name: d.input_name || void 0,
|
|
216
22
|
file: d.file || void 0,
|
|
217
23
|
line: d.line || void 0,
|
|
218
24
|
column: d.column || void 0
|
|
219
25
|
};
|
|
220
26
|
}
|
|
221
27
|
|
|
28
|
+
// src/engine-bridge.ts
|
|
29
|
+
var ENGINE_METHODS = [
|
|
30
|
+
"Initialize",
|
|
31
|
+
"SessionOpen",
|
|
32
|
+
"TestSessionOpen",
|
|
33
|
+
"SessionSave",
|
|
34
|
+
"SessionClose",
|
|
35
|
+
"SessionGenerate",
|
|
36
|
+
"SessionResolveConflict",
|
|
37
|
+
"ApplyAction",
|
|
38
|
+
"CancelInvoke"
|
|
39
|
+
];
|
|
40
|
+
var ENGINE_STREAM_METHODS = ["Subscribe", "Invoke"];
|
|
41
|
+
var BRIDGE_METHODS = ENGINE_METHODS.filter(
|
|
42
|
+
(m) => m !== "TestSessionOpen"
|
|
43
|
+
);
|
|
44
|
+
|
|
222
45
|
// src/generated/state.ts
|
|
223
46
|
import { BinaryReader as BinaryReader2, BinaryWriter as BinaryWriter2 } from "@bufbuild/protobuf/wire";
|
|
224
47
|
|
|
@@ -650,7 +473,7 @@ function isSet(value) {
|
|
|
650
473
|
|
|
651
474
|
// src/generated/state.ts
|
|
652
475
|
function createBaseBundle() {
|
|
653
|
-
return { schema_version: "", kind: "", entry: "", modules: {}
|
|
476
|
+
return { schema_version: "", kind: "", entry: "", modules: {} };
|
|
654
477
|
}
|
|
655
478
|
var Bundle = {
|
|
656
479
|
encode(message, writer = new BinaryWriter2()) {
|
|
@@ -666,16 +489,6 @@ var Bundle = {
|
|
|
666
489
|
globalThis.Object.entries(message.modules).forEach(([key, value]) => {
|
|
667
490
|
Bundle_ModulesEntry.encode({ key, value }, writer.uint32(34).fork()).join();
|
|
668
491
|
});
|
|
669
|
-
globalThis.Object.entries(message.environments).forEach(
|
|
670
|
-
([key, value]) => {
|
|
671
|
-
if (value !== void 0) {
|
|
672
|
-
Bundle_EnvironmentsEntry.encode({ key, value }, writer.uint32(42).fork()).join();
|
|
673
|
-
}
|
|
674
|
-
}
|
|
675
|
-
);
|
|
676
|
-
globalThis.Object.entries(message.environment_backends).forEach(([key, value]) => {
|
|
677
|
-
Bundle_EnvironmentBackendsEntry.encode({ key, value }, writer.uint32(50).fork()).join();
|
|
678
|
-
});
|
|
679
492
|
return writer;
|
|
680
493
|
},
|
|
681
494
|
decode(input, length) {
|
|
@@ -716,26 +529,6 @@ var Bundle = {
|
|
|
716
529
|
}
|
|
717
530
|
continue;
|
|
718
531
|
}
|
|
719
|
-
case 5: {
|
|
720
|
-
if (tag !== 42) {
|
|
721
|
-
break;
|
|
722
|
-
}
|
|
723
|
-
const entry5 = Bundle_EnvironmentsEntry.decode(reader, reader.uint32());
|
|
724
|
-
if (entry5.value !== void 0) {
|
|
725
|
-
message.environments[entry5.key] = entry5.value;
|
|
726
|
-
}
|
|
727
|
-
continue;
|
|
728
|
-
}
|
|
729
|
-
case 6: {
|
|
730
|
-
if (tag !== 50) {
|
|
731
|
-
break;
|
|
732
|
-
}
|
|
733
|
-
const entry6 = Bundle_EnvironmentBackendsEntry.decode(reader, reader.uint32());
|
|
734
|
-
if (entry6.value !== void 0) {
|
|
735
|
-
message.environment_backends[entry6.key] = entry6.value;
|
|
736
|
-
}
|
|
737
|
-
continue;
|
|
738
|
-
}
|
|
739
532
|
}
|
|
740
533
|
if ((tag & 7) === 4 || tag === 0) {
|
|
741
534
|
break;
|
|
@@ -755,26 +548,6 @@ var Bundle = {
|
|
|
755
548
|
return acc;
|
|
756
549
|
},
|
|
757
550
|
{}
|
|
758
|
-
) : {},
|
|
759
|
-
environments: isObject2(object.environments) ? globalThis.Object.entries(object.environments).reduce(
|
|
760
|
-
(acc, [key, value]) => {
|
|
761
|
-
acc[key] = value;
|
|
762
|
-
return acc;
|
|
763
|
-
},
|
|
764
|
-
{}
|
|
765
|
-
) : {},
|
|
766
|
-
environment_backends: isObject2(object.environmentBackends) ? globalThis.Object.entries(object.environmentBackends).reduce(
|
|
767
|
-
(acc, [key, value]) => {
|
|
768
|
-
acc[key] = BackendConfig.fromJSON(value);
|
|
769
|
-
return acc;
|
|
770
|
-
},
|
|
771
|
-
{}
|
|
772
|
-
) : isObject2(object.environment_backends) ? globalThis.Object.entries(object.environment_backends).reduce(
|
|
773
|
-
(acc, [key, value]) => {
|
|
774
|
-
acc[key] = BackendConfig.fromJSON(value);
|
|
775
|
-
return acc;
|
|
776
|
-
},
|
|
777
|
-
{}
|
|
778
551
|
) : {}
|
|
779
552
|
};
|
|
780
553
|
},
|
|
@@ -798,24 +571,6 @@ var Bundle = {
|
|
|
798
571
|
});
|
|
799
572
|
}
|
|
800
573
|
}
|
|
801
|
-
if (message.environments) {
|
|
802
|
-
const entries = globalThis.Object.entries(message.environments);
|
|
803
|
-
if (entries.length > 0) {
|
|
804
|
-
obj.environments = {};
|
|
805
|
-
entries.forEach(([k, v]) => {
|
|
806
|
-
obj.environments[k] = v;
|
|
807
|
-
});
|
|
808
|
-
}
|
|
809
|
-
}
|
|
810
|
-
if (message.environment_backends) {
|
|
811
|
-
const entries = globalThis.Object.entries(message.environment_backends);
|
|
812
|
-
if (entries.length > 0) {
|
|
813
|
-
obj.environmentBackends = {};
|
|
814
|
-
entries.forEach(([k, v]) => {
|
|
815
|
-
obj.environmentBackends[k] = BackendConfig.toJSON(v);
|
|
816
|
-
});
|
|
817
|
-
}
|
|
818
|
-
}
|
|
819
574
|
return obj;
|
|
820
575
|
},
|
|
821
576
|
create(base) {
|
|
@@ -835,24 +590,6 @@ var Bundle = {
|
|
|
835
590
|
},
|
|
836
591
|
{}
|
|
837
592
|
);
|
|
838
|
-
message.environments = globalThis.Object.entries(object.environments ?? {}).reduce(
|
|
839
|
-
(acc, [key, value]) => {
|
|
840
|
-
if (value !== void 0) {
|
|
841
|
-
acc[key] = value;
|
|
842
|
-
}
|
|
843
|
-
return acc;
|
|
844
|
-
},
|
|
845
|
-
{}
|
|
846
|
-
);
|
|
847
|
-
message.environment_backends = globalThis.Object.entries(object.environment_backends ?? {}).reduce(
|
|
848
|
-
(acc, [key, value]) => {
|
|
849
|
-
if (value !== void 0) {
|
|
850
|
-
acc[key] = BackendConfig.fromPartial(value);
|
|
851
|
-
}
|
|
852
|
-
return acc;
|
|
853
|
-
},
|
|
854
|
-
{}
|
|
855
|
-
);
|
|
856
593
|
return message;
|
|
857
594
|
}
|
|
858
595
|
};
|
|
@@ -924,142 +661,6 @@ var Bundle_ModulesEntry = {
|
|
|
924
661
|
return message;
|
|
925
662
|
}
|
|
926
663
|
};
|
|
927
|
-
function createBaseBundle_EnvironmentsEntry() {
|
|
928
|
-
return { key: "", value: void 0 };
|
|
929
|
-
}
|
|
930
|
-
var Bundle_EnvironmentsEntry = {
|
|
931
|
-
encode(message, writer = new BinaryWriter2()) {
|
|
932
|
-
if (message.key !== "") {
|
|
933
|
-
writer.uint32(10).string(message.key);
|
|
934
|
-
}
|
|
935
|
-
if (message.value !== void 0) {
|
|
936
|
-
Struct.encode(Struct.wrap(message.value), writer.uint32(18).fork()).join();
|
|
937
|
-
}
|
|
938
|
-
return writer;
|
|
939
|
-
},
|
|
940
|
-
decode(input, length) {
|
|
941
|
-
const reader = input instanceof BinaryReader2 ? input : new BinaryReader2(input);
|
|
942
|
-
const end = length === void 0 ? reader.len : reader.pos + length;
|
|
943
|
-
const message = createBaseBundle_EnvironmentsEntry();
|
|
944
|
-
while (reader.pos < end) {
|
|
945
|
-
const tag = reader.uint32();
|
|
946
|
-
switch (tag >>> 3) {
|
|
947
|
-
case 1: {
|
|
948
|
-
if (tag !== 10) {
|
|
949
|
-
break;
|
|
950
|
-
}
|
|
951
|
-
message.key = reader.string();
|
|
952
|
-
continue;
|
|
953
|
-
}
|
|
954
|
-
case 2: {
|
|
955
|
-
if (tag !== 18) {
|
|
956
|
-
break;
|
|
957
|
-
}
|
|
958
|
-
message.value = Struct.unwrap(Struct.decode(reader, reader.uint32()));
|
|
959
|
-
continue;
|
|
960
|
-
}
|
|
961
|
-
}
|
|
962
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
963
|
-
break;
|
|
964
|
-
}
|
|
965
|
-
reader.skip(tag & 7);
|
|
966
|
-
}
|
|
967
|
-
return message;
|
|
968
|
-
},
|
|
969
|
-
fromJSON(object) {
|
|
970
|
-
return {
|
|
971
|
-
key: isSet2(object.key) ? globalThis.String(object.key) : "",
|
|
972
|
-
value: isObject2(object.value) ? object.value : void 0
|
|
973
|
-
};
|
|
974
|
-
},
|
|
975
|
-
toJSON(message) {
|
|
976
|
-
const obj = {};
|
|
977
|
-
if (message.key !== "") {
|
|
978
|
-
obj.key = message.key;
|
|
979
|
-
}
|
|
980
|
-
if (message.value !== void 0) {
|
|
981
|
-
obj.value = message.value;
|
|
982
|
-
}
|
|
983
|
-
return obj;
|
|
984
|
-
},
|
|
985
|
-
create(base) {
|
|
986
|
-
return Bundle_EnvironmentsEntry.fromPartial(base ?? {});
|
|
987
|
-
},
|
|
988
|
-
fromPartial(object) {
|
|
989
|
-
const message = createBaseBundle_EnvironmentsEntry();
|
|
990
|
-
message.key = object.key ?? "";
|
|
991
|
-
message.value = object.value ?? void 0;
|
|
992
|
-
return message;
|
|
993
|
-
}
|
|
994
|
-
};
|
|
995
|
-
function createBaseBundle_EnvironmentBackendsEntry() {
|
|
996
|
-
return { key: "", value: void 0 };
|
|
997
|
-
}
|
|
998
|
-
var Bundle_EnvironmentBackendsEntry = {
|
|
999
|
-
encode(message, writer = new BinaryWriter2()) {
|
|
1000
|
-
if (message.key !== "") {
|
|
1001
|
-
writer.uint32(10).string(message.key);
|
|
1002
|
-
}
|
|
1003
|
-
if (message.value !== void 0) {
|
|
1004
|
-
BackendConfig.encode(message.value, writer.uint32(18).fork()).join();
|
|
1005
|
-
}
|
|
1006
|
-
return writer;
|
|
1007
|
-
},
|
|
1008
|
-
decode(input, length) {
|
|
1009
|
-
const reader = input instanceof BinaryReader2 ? input : new BinaryReader2(input);
|
|
1010
|
-
const end = length === void 0 ? reader.len : reader.pos + length;
|
|
1011
|
-
const message = createBaseBundle_EnvironmentBackendsEntry();
|
|
1012
|
-
while (reader.pos < end) {
|
|
1013
|
-
const tag = reader.uint32();
|
|
1014
|
-
switch (tag >>> 3) {
|
|
1015
|
-
case 1: {
|
|
1016
|
-
if (tag !== 10) {
|
|
1017
|
-
break;
|
|
1018
|
-
}
|
|
1019
|
-
message.key = reader.string();
|
|
1020
|
-
continue;
|
|
1021
|
-
}
|
|
1022
|
-
case 2: {
|
|
1023
|
-
if (tag !== 18) {
|
|
1024
|
-
break;
|
|
1025
|
-
}
|
|
1026
|
-
message.value = BackendConfig.decode(reader, reader.uint32());
|
|
1027
|
-
continue;
|
|
1028
|
-
}
|
|
1029
|
-
}
|
|
1030
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
1031
|
-
break;
|
|
1032
|
-
}
|
|
1033
|
-
reader.skip(tag & 7);
|
|
1034
|
-
}
|
|
1035
|
-
return message;
|
|
1036
|
-
},
|
|
1037
|
-
fromJSON(object) {
|
|
1038
|
-
return {
|
|
1039
|
-
key: isSet2(object.key) ? globalThis.String(object.key) : "",
|
|
1040
|
-
value: isSet2(object.value) ? BackendConfig.fromJSON(object.value) : void 0
|
|
1041
|
-
};
|
|
1042
|
-
},
|
|
1043
|
-
toJSON(message) {
|
|
1044
|
-
const obj = {};
|
|
1045
|
-
if (message.key !== "") {
|
|
1046
|
-
obj.key = message.key;
|
|
1047
|
-
}
|
|
1048
|
-
if (message.value !== void 0) {
|
|
1049
|
-
obj.value = BackendConfig.toJSON(message.value);
|
|
1050
|
-
}
|
|
1051
|
-
return obj;
|
|
1052
|
-
},
|
|
1053
|
-
create(base) {
|
|
1054
|
-
return Bundle_EnvironmentBackendsEntry.fromPartial(base ?? {});
|
|
1055
|
-
},
|
|
1056
|
-
fromPartial(object) {
|
|
1057
|
-
const message = createBaseBundle_EnvironmentBackendsEntry();
|
|
1058
|
-
message.key = object.key ?? "";
|
|
1059
|
-
message.value = object.value !== void 0 && object.value !== null ? BackendConfig.fromPartial(object.value) : void 0;
|
|
1060
|
-
return message;
|
|
1061
|
-
}
|
|
1062
|
-
};
|
|
1063
664
|
function createBaseModule() {
|
|
1064
665
|
return {
|
|
1065
666
|
id: "",
|
|
@@ -1708,7 +1309,7 @@ var OutputDef = {
|
|
|
1708
1309
|
}
|
|
1709
1310
|
};
|
|
1710
1311
|
function createBaseSource() {
|
|
1711
|
-
return { kind: "", repo: "", subdir: "", ref: ""
|
|
1312
|
+
return { kind: "", repo: "", subdir: "", ref: "" };
|
|
1712
1313
|
}
|
|
1713
1314
|
var Source = {
|
|
1714
1315
|
encode(message, writer = new BinaryWriter2()) {
|
|
@@ -1724,9 +1325,6 @@ var Source = {
|
|
|
1724
1325
|
if (message.ref !== "") {
|
|
1725
1326
|
writer.uint32(34).string(message.ref);
|
|
1726
1327
|
}
|
|
1727
|
-
if (message.organization !== "") {
|
|
1728
|
-
writer.uint32(42).string(message.organization);
|
|
1729
|
-
}
|
|
1730
1328
|
return writer;
|
|
1731
1329
|
},
|
|
1732
1330
|
decode(input, length) {
|
|
@@ -1764,13 +1362,6 @@ var Source = {
|
|
|
1764
1362
|
message.ref = reader.string();
|
|
1765
1363
|
continue;
|
|
1766
1364
|
}
|
|
1767
|
-
case 5: {
|
|
1768
|
-
if (tag !== 42) {
|
|
1769
|
-
break;
|
|
1770
|
-
}
|
|
1771
|
-
message.organization = reader.string();
|
|
1772
|
-
continue;
|
|
1773
|
-
}
|
|
1774
1365
|
}
|
|
1775
1366
|
if ((tag & 7) === 4 || tag === 0) {
|
|
1776
1367
|
break;
|
|
@@ -1784,8 +1375,7 @@ var Source = {
|
|
|
1784
1375
|
kind: isSet2(object.kind) ? globalThis.String(object.kind) : "",
|
|
1785
1376
|
repo: isSet2(object.repo) ? globalThis.String(object.repo) : "",
|
|
1786
1377
|
subdir: isSet2(object.subdir) ? globalThis.String(object.subdir) : "",
|
|
1787
|
-
ref: isSet2(object.ref) ? globalThis.String(object.ref) : ""
|
|
1788
|
-
organization: isSet2(object.organization) ? globalThis.String(object.organization) : ""
|
|
1378
|
+
ref: isSet2(object.ref) ? globalThis.String(object.ref) : ""
|
|
1789
1379
|
};
|
|
1790
1380
|
},
|
|
1791
1381
|
toJSON(message) {
|
|
@@ -1802,9 +1392,6 @@ var Source = {
|
|
|
1802
1392
|
if (message.ref !== "") {
|
|
1803
1393
|
obj.ref = message.ref;
|
|
1804
1394
|
}
|
|
1805
|
-
if (message.organization !== "") {
|
|
1806
|
-
obj.organization = message.organization;
|
|
1807
|
-
}
|
|
1808
1395
|
return obj;
|
|
1809
1396
|
},
|
|
1810
1397
|
create(base) {
|
|
@@ -1816,7 +1403,6 @@ var Source = {
|
|
|
1816
1403
|
message.repo = object.repo ?? "";
|
|
1817
1404
|
message.subdir = object.subdir ?? "";
|
|
1818
1405
|
message.ref = object.ref ?? "";
|
|
1819
|
-
message.organization = object.organization ?? "";
|
|
1820
1406
|
return message;
|
|
1821
1407
|
}
|
|
1822
1408
|
};
|
|
@@ -3749,25 +3335,270 @@ function isSet2(value) {
|
|
|
3749
3335
|
return value !== null && value !== void 0;
|
|
3750
3336
|
}
|
|
3751
3337
|
|
|
3752
|
-
// src/projection/
|
|
3753
|
-
function
|
|
3754
|
-
|
|
3755
|
-
if (
|
|
3756
|
-
|
|
3338
|
+
// src/projection/inspect.ts
|
|
3339
|
+
function hclLiteralText(lit) {
|
|
3340
|
+
if (typeof lit === "string") return quoteHclString(lit);
|
|
3341
|
+
if (typeof lit === "number" || typeof lit === "boolean") return String(lit);
|
|
3342
|
+
if (Array.isArray(lit)) return `[${lit.map(hclLiteralText).join(", ")}]`;
|
|
3343
|
+
if (lit !== null && typeof lit === "object") {
|
|
3344
|
+
return hclObjectText(lit);
|
|
3345
|
+
}
|
|
3346
|
+
return String(lit);
|
|
3757
3347
|
}
|
|
3758
|
-
|
|
3759
|
-
|
|
3760
|
-
|
|
3761
|
-
|
|
3762
|
-
|
|
3763
|
-
|
|
3348
|
+
function quoteHclString(s) {
|
|
3349
|
+
let out = "";
|
|
3350
|
+
for (let i = 0; i < s.length; i++) {
|
|
3351
|
+
const c = s[i];
|
|
3352
|
+
switch (c) {
|
|
3353
|
+
case "\\":
|
|
3354
|
+
out += "\\\\";
|
|
3355
|
+
break;
|
|
3356
|
+
case '"':
|
|
3357
|
+
out += '\\"';
|
|
3358
|
+
break;
|
|
3359
|
+
case "\n":
|
|
3360
|
+
out += "\\n";
|
|
3361
|
+
break;
|
|
3362
|
+
case "\r":
|
|
3363
|
+
out += "\\r";
|
|
3364
|
+
break;
|
|
3365
|
+
case " ":
|
|
3366
|
+
out += "\\t";
|
|
3367
|
+
break;
|
|
3368
|
+
case "$":
|
|
3369
|
+
case "%":
|
|
3370
|
+
out += s[i + 1] === "{" ? c + c : c;
|
|
3371
|
+
break;
|
|
3372
|
+
default:
|
|
3373
|
+
out += c;
|
|
3374
|
+
}
|
|
3375
|
+
}
|
|
3376
|
+
return `"${out}"`;
|
|
3764
3377
|
}
|
|
3765
|
-
|
|
3766
|
-
|
|
3767
|
-
|
|
3768
|
-
|
|
3769
|
-
|
|
3770
|
-
|
|
3378
|
+
function hclObjectText(obj) {
|
|
3379
|
+
const entries = Object.entries(obj).sort(([a], [b]) => a < b ? -1 : a > b ? 1 : 0);
|
|
3380
|
+
if (entries.length === 0) return "{}";
|
|
3381
|
+
const width = Math.max(...entries.map(([k]) => k.length)) + 1;
|
|
3382
|
+
const lines = entries.map(([k, v]) => ` ${k.padEnd(width)}= ${hclLiteralText(v)}`);
|
|
3383
|
+
return `{
|
|
3384
|
+
${lines.join("\n")}
|
|
3385
|
+
}`;
|
|
3386
|
+
}
|
|
3387
|
+
function bindingText(b) {
|
|
3388
|
+
if (!b) return "";
|
|
3389
|
+
if (b.lit !== void 0 && b.lit !== null) return hclLiteralText(b.lit);
|
|
3390
|
+
if (b.var) return `var.${b.var}`;
|
|
3391
|
+
if (b.out) return `module.${b.out.module}.${b.out.name}`;
|
|
3392
|
+
if (b.expr) return b.expr.value;
|
|
3393
|
+
return "";
|
|
3394
|
+
}
|
|
3395
|
+
function bindingMode(b) {
|
|
3396
|
+
if (!b) return { mode: "empty" };
|
|
3397
|
+
if (b.out) return { mode: "wired", wired_source: bindingText(b) };
|
|
3398
|
+
if (b.var) return { mode: "variable", variable: b.var };
|
|
3399
|
+
if (b.expr) return { mode: "expression", expression: b.expr.value };
|
|
3400
|
+
if (b.lit !== void 0 && b.lit !== null) return { mode: "literal", value: b.lit };
|
|
3401
|
+
return { mode: "empty" };
|
|
3402
|
+
}
|
|
3403
|
+
function describeBinding(b) {
|
|
3404
|
+
return { mode: bindingMode(b).mode, display: bindingText(b) };
|
|
3405
|
+
}
|
|
3406
|
+
function findChild(mod, id) {
|
|
3407
|
+
for (const use of mod.modules ?? []) {
|
|
3408
|
+
if (use.id === id) return { id, use };
|
|
3409
|
+
}
|
|
3410
|
+
for (const resource of mod.resources ?? []) {
|
|
3411
|
+
if (resource.id === id) return { id, resource };
|
|
3412
|
+
}
|
|
3413
|
+
return null;
|
|
3414
|
+
}
|
|
3415
|
+
function deriveNodeConfig(bundle, instanceId) {
|
|
3416
|
+
const entry = bundle.modules[bundle.entry];
|
|
3417
|
+
if (!entry) return null;
|
|
3418
|
+
const child = findChild(entry, instanceId);
|
|
3419
|
+
if (!child) return null;
|
|
3420
|
+
const target = child.use ? bundle.modules[child.use.module] : void 0;
|
|
3421
|
+
const schemaInputs = target?.interface?.inputs ?? [];
|
|
3422
|
+
const schemaOutputs = target?.interface?.outputs ?? [];
|
|
3423
|
+
const boundInputs = child.use?.inputs ?? child.resource?.inputs ?? {};
|
|
3424
|
+
const inputs = schemaInputs.map((def) => ({
|
|
3425
|
+
name: def.name,
|
|
3426
|
+
type: def.type,
|
|
3427
|
+
required: def.required,
|
|
3428
|
+
description: def.description || void 0,
|
|
3429
|
+
default_value: def.default_value,
|
|
3430
|
+
validation: def.validation?.[0] ? { condition: def.validation[0].condition, error_message: def.validation[0].error_message } : void 0,
|
|
3431
|
+
...bindingMode(boundInputs[def.name])
|
|
3432
|
+
}));
|
|
3433
|
+
const outputs = schemaOutputs.map((def) => ({
|
|
3434
|
+
name: def.name,
|
|
3435
|
+
type: def.type,
|
|
3436
|
+
description: def.description || void 0,
|
|
3437
|
+
sensitive: def.sensitive || void 0
|
|
3438
|
+
}));
|
|
3439
|
+
const siblingIds = [
|
|
3440
|
+
...(entry.modules ?? []).map((u) => u.id),
|
|
3441
|
+
...(entry.resources ?? []).map((r) => r.id)
|
|
3442
|
+
].filter((id) => id !== instanceId);
|
|
3443
|
+
const dependsOn = child.use?.depends_on ?? child.resource?.depends_on ?? [];
|
|
3444
|
+
const providers = child.use?.providers ?? {};
|
|
3445
|
+
const availableVariables = (entry.interface?.inputs ?? []).map((v) => ({
|
|
3446
|
+
name: v.name,
|
|
3447
|
+
type: v.type
|
|
3448
|
+
}));
|
|
3449
|
+
return {
|
|
3450
|
+
instance_id: instanceId,
|
|
3451
|
+
inputs,
|
|
3452
|
+
outputs,
|
|
3453
|
+
sibling_ids: siblingIds,
|
|
3454
|
+
depends_on: dependsOn,
|
|
3455
|
+
providers,
|
|
3456
|
+
available_variables: availableVariables
|
|
3457
|
+
};
|
|
3458
|
+
}
|
|
3459
|
+
function deriveSettingsConfig(bundle) {
|
|
3460
|
+
const entry = bundle.modules[bundle.entry];
|
|
3461
|
+
const terraform = entry?.terraform ? {
|
|
3462
|
+
required_version: entry.terraform.required_version,
|
|
3463
|
+
required_providers: Object.entries(entry.terraform.required_providers ?? {}).map(
|
|
3464
|
+
([name, req]) => ({
|
|
3465
|
+
name,
|
|
3466
|
+
source: req.source,
|
|
3467
|
+
version: req.version,
|
|
3468
|
+
configuration_aliases: req.configuration_aliases
|
|
3469
|
+
})
|
|
3470
|
+
)
|
|
3471
|
+
} : { required_version: "", required_providers: [] };
|
|
3472
|
+
const providers = (entry?.providers ?? []).map((p) => {
|
|
3473
|
+
const config = {};
|
|
3474
|
+
for (const [k, v] of Object.entries(p.config ?? {})) {
|
|
3475
|
+
config[k] = describeBinding(v).display;
|
|
3476
|
+
}
|
|
3477
|
+
return { name: p.name, alias: p.alias, config, blocks: p.blocks };
|
|
3478
|
+
});
|
|
3479
|
+
const locals = (entry?.locals ?? []).map((l) => {
|
|
3480
|
+
const { mode, display } = describeBinding(l.value);
|
|
3481
|
+
return { name: l.name, mode, value_display: display };
|
|
3482
|
+
});
|
|
3483
|
+
const variables = (entry?.interface?.inputs ?? []).map((v) => ({
|
|
3484
|
+
name: v.name,
|
|
3485
|
+
type: v.type,
|
|
3486
|
+
required: v.required,
|
|
3487
|
+
description: v.description || void 0,
|
|
3488
|
+
default_value: v.default_value,
|
|
3489
|
+
validation: v.validation?.map((b) => ({
|
|
3490
|
+
condition: b.condition,
|
|
3491
|
+
error_message: b.error_message
|
|
3492
|
+
})),
|
|
3493
|
+
ephemeral: v.ephemeral,
|
|
3494
|
+
sensitive: v.sensitive || void 0,
|
|
3495
|
+
nullable: v.nullable
|
|
3496
|
+
}));
|
|
3497
|
+
const output_defs = (entry?.interface?.outputs ?? []).map((o) => ({
|
|
3498
|
+
name: o.name,
|
|
3499
|
+
type: o.type,
|
|
3500
|
+
description: o.description || void 0,
|
|
3501
|
+
sensitive: o.sensitive || void 0,
|
|
3502
|
+
depends_on: o.depends_on
|
|
3503
|
+
}));
|
|
3504
|
+
const exports = Object.entries(entry?.exports?.outputs ?? {}).flatMap(([name, exp]) => {
|
|
3505
|
+
if (!exp.out) return [];
|
|
3506
|
+
return [{ name, source_instance: exp.out.module, source_output: exp.out.name }];
|
|
3507
|
+
});
|
|
3508
|
+
return { terraform, providers, locals, variables, exports, output_defs };
|
|
3509
|
+
}
|
|
3510
|
+
|
|
3511
|
+
// src/projection/join-path.ts
|
|
3512
|
+
function joinPath(prefix, localId) {
|
|
3513
|
+
return prefix === "" ? localId : `${prefix}.${localId}`;
|
|
3514
|
+
}
|
|
3515
|
+
|
|
3516
|
+
// src/projection/node-for-address.ts
|
|
3517
|
+
var INSTANCE_KEY = /\[[^\]]*\]$/;
|
|
3518
|
+
function tokenizeAddress(address) {
|
|
3519
|
+
const tokens = [];
|
|
3520
|
+
let current = "";
|
|
3521
|
+
let depth = 0;
|
|
3522
|
+
for (const ch of address) {
|
|
3523
|
+
if (ch === "[") depth++;
|
|
3524
|
+
else if (ch === "]") depth--;
|
|
3525
|
+
if (ch === "." && depth === 0) {
|
|
3526
|
+
tokens.push(current);
|
|
3527
|
+
current = "";
|
|
3528
|
+
} else {
|
|
3529
|
+
current += ch;
|
|
3530
|
+
}
|
|
3531
|
+
}
|
|
3532
|
+
tokens.push(current);
|
|
3533
|
+
return tokens;
|
|
3534
|
+
}
|
|
3535
|
+
function nodeIdForAddress(view, address) {
|
|
3536
|
+
const tokens = tokenizeAddress(address);
|
|
3537
|
+
const moduleNames = [];
|
|
3538
|
+
let i = 0;
|
|
3539
|
+
while (i + 1 < tokens.length && tokens[i] === "module") {
|
|
3540
|
+
moduleNames.push(tokens[i + 1].replace(INSTANCE_KEY, ""));
|
|
3541
|
+
i += 2;
|
|
3542
|
+
}
|
|
3543
|
+
if (moduleNames.length === 0) return null;
|
|
3544
|
+
const known = /* @__PURE__ */ new Set();
|
|
3545
|
+
for (const n of view.nodes) known.add(n.id);
|
|
3546
|
+
for (const g of view.groups) known.add(g.id);
|
|
3547
|
+
for (let k = moduleNames.length; k >= 1; k--) {
|
|
3548
|
+
let path = "";
|
|
3549
|
+
for (let j = 0; j < k; j++) path = joinPath(path, moduleNames[j]);
|
|
3550
|
+
if (known.has(path)) return path;
|
|
3551
|
+
}
|
|
3552
|
+
return null;
|
|
3553
|
+
}
|
|
3554
|
+
|
|
3555
|
+
// src/projection/node-for-diagnostic.ts
|
|
3556
|
+
function buildScopeIndex(view) {
|
|
3557
|
+
const byModuleKey = /* @__PURE__ */ new Map();
|
|
3558
|
+
const known = /* @__PURE__ */ new Set();
|
|
3559
|
+
for (const n of view.nodes) known.add(n.id);
|
|
3560
|
+
for (const g of view.groups) {
|
|
3561
|
+
known.add(g.id);
|
|
3562
|
+
if (g.module_key) {
|
|
3563
|
+
const ids = byModuleKey.get(g.module_key);
|
|
3564
|
+
if (ids) ids.push(g.id);
|
|
3565
|
+
else byModuleKey.set(g.module_key, [g.id]);
|
|
3566
|
+
}
|
|
3567
|
+
}
|
|
3568
|
+
return { byModuleKey, known };
|
|
3569
|
+
}
|
|
3570
|
+
function nodeIdForDiagnostic(view, diagnostic) {
|
|
3571
|
+
if (diagnostic.address) return nodeIdForAddress(view, diagnostic.address);
|
|
3572
|
+
if (!diagnostic.instance_id) return null;
|
|
3573
|
+
const index = buildScopeIndex(view);
|
|
3574
|
+
const scopeIds = diagnostic.module_key ? index.byModuleKey.get(diagnostic.module_key) : void 0;
|
|
3575
|
+
if (!scopeIds || scopeIds.length === 0) {
|
|
3576
|
+
return index.known.has(diagnostic.instance_id) ? diagnostic.instance_id : null;
|
|
3577
|
+
}
|
|
3578
|
+
if (scopeIds.length > 1) return null;
|
|
3579
|
+
const nodeId = `${scopeIds[0]}.${diagnostic.instance_id}`;
|
|
3580
|
+
return index.known.has(nodeId) ? nodeId : null;
|
|
3581
|
+
}
|
|
3582
|
+
|
|
3583
|
+
// src/projection/parse-module-key.ts
|
|
3584
|
+
function parseModuleKey(key) {
|
|
3585
|
+
const at = key.lastIndexOf("@");
|
|
3586
|
+
if (at < 0) return { id: key, version: "" };
|
|
3587
|
+
return { id: key.slice(0, at), version: key.slice(at + 1) };
|
|
3588
|
+
}
|
|
3589
|
+
|
|
3590
|
+
// src/projection/classify-child.ts
|
|
3591
|
+
function isGroupUse(bundle, use) {
|
|
3592
|
+
const target = bundle.modules[use.module];
|
|
3593
|
+
if (!target) return false;
|
|
3594
|
+
return (target.modules?.length ?? 0) > 0;
|
|
3595
|
+
}
|
|
3596
|
+
|
|
3597
|
+
// src/projection/compute-layout.ts
|
|
3598
|
+
var SPACING_X = 260;
|
|
3599
|
+
var SPACING_Y = 180;
|
|
3600
|
+
function gridPosition(index, n) {
|
|
3601
|
+
const cols = Math.max(2, Math.ceil(Math.sqrt(n)));
|
|
3771
3602
|
const col = index % cols;
|
|
3772
3603
|
const row = Math.floor(index / cols);
|
|
3773
3604
|
return { x: col * SPACING_X, y: row * SPACING_Y };
|
|
@@ -3777,7 +3608,7 @@ function overlapsAny(candidate, occupied) {
|
|
|
3777
3608
|
(o) => candidate.x < o.x + SPACING_X && candidate.x + SPACING_X > o.x && candidate.y < o.y + SPACING_Y && candidate.y + SPACING_Y > o.y
|
|
3778
3609
|
);
|
|
3779
3610
|
}
|
|
3780
|
-
function
|
|
3611
|
+
function partitionStored(ids, arrangementNodes) {
|
|
3781
3612
|
const positions = /* @__PURE__ */ new Map();
|
|
3782
3613
|
const occupied = [];
|
|
3783
3614
|
const unresolved = [];
|
|
@@ -3790,6 +3621,10 @@ function resolveScopePositions(ids, arrangementNodes) {
|
|
|
3790
3621
|
unresolved.push(id);
|
|
3791
3622
|
}
|
|
3792
3623
|
}
|
|
3624
|
+
return { positions, occupied, unresolved };
|
|
3625
|
+
}
|
|
3626
|
+
function resolveScopePositions(ids, arrangementNodes) {
|
|
3627
|
+
const { positions, occupied, unresolved } = partitionStored(ids, arrangementNodes);
|
|
3793
3628
|
let slot = 0;
|
|
3794
3629
|
for (const id of unresolved) {
|
|
3795
3630
|
let candidate = gridPosition(slot, ids.length);
|
|
@@ -3803,6 +3638,82 @@ function resolveScopePositions(ids, arrangementNodes) {
|
|
|
3803
3638
|
}
|
|
3804
3639
|
return positions;
|
|
3805
3640
|
}
|
|
3641
|
+
function resolveScopePositionsByDepth(ids, arrangementNodes, edges) {
|
|
3642
|
+
const { positions, occupied, unresolved } = partitionStored(ids, arrangementNodes);
|
|
3643
|
+
const columns = columnByDepth(ids, edges);
|
|
3644
|
+
const predecessors = /* @__PURE__ */ new Map();
|
|
3645
|
+
for (const edge of edges) {
|
|
3646
|
+
if (edge.source_instance === edge.target_instance) continue;
|
|
3647
|
+
predecessors.set(edge.target_instance, [
|
|
3648
|
+
...predecessors.get(edge.target_instance) ?? [],
|
|
3649
|
+
edge.source_instance
|
|
3650
|
+
]);
|
|
3651
|
+
}
|
|
3652
|
+
const rows = /* @__PURE__ */ new Map();
|
|
3653
|
+
const order = [...ids].sort((a, b) => (columns.get(a) ?? 0) - (columns.get(b) ?? 0));
|
|
3654
|
+
const seeded = /* @__PURE__ */ new Map();
|
|
3655
|
+
for (const id of order) {
|
|
3656
|
+
const column = columns.get(id) ?? 0;
|
|
3657
|
+
const stored = arrangementNodes?.[id];
|
|
3658
|
+
if (stored) {
|
|
3659
|
+
rows.set(id, stored.y);
|
|
3660
|
+
continue;
|
|
3661
|
+
}
|
|
3662
|
+
const seq = seeded.get(column) ?? 0;
|
|
3663
|
+
seeded.set(column, seq + 1);
|
|
3664
|
+
rows.set(id, seq * SPACING_Y);
|
|
3665
|
+
}
|
|
3666
|
+
for (const id of order) {
|
|
3667
|
+
if (arrangementNodes?.[id]) continue;
|
|
3668
|
+
const feeders = (predecessors.get(id) ?? []).filter((f) => rows.has(f));
|
|
3669
|
+
if (feeders.length === 0) continue;
|
|
3670
|
+
rows.set(id, feeders.reduce((sum, f) => sum + (rows.get(f) ?? 0), 0) / feeders.length);
|
|
3671
|
+
}
|
|
3672
|
+
const byColumn = /* @__PURE__ */ new Map();
|
|
3673
|
+
for (const id of ids) {
|
|
3674
|
+
const column = columns.get(id) ?? 0;
|
|
3675
|
+
byColumn.set(column, [...byColumn.get(column) ?? [], id]);
|
|
3676
|
+
}
|
|
3677
|
+
for (const [, members] of byColumn) {
|
|
3678
|
+
const movable = members.filter((id) => !arrangementNodes?.[id]);
|
|
3679
|
+
if (movable.length < 2) continue;
|
|
3680
|
+
const sorted = [...movable].sort((a, b) => (rows.get(a) ?? 0) - (rows.get(b) ?? 0));
|
|
3681
|
+
const centre = sorted.reduce((sum, id) => sum + (rows.get(id) ?? 0), 0) / sorted.length;
|
|
3682
|
+
const first = centre - (sorted.length - 1) * SPACING_Y / 2;
|
|
3683
|
+
for (const [i, id] of sorted.entries()) {
|
|
3684
|
+
rows.set(id, first + i * SPACING_Y);
|
|
3685
|
+
}
|
|
3686
|
+
}
|
|
3687
|
+
for (const id of unresolved) {
|
|
3688
|
+
const column = columns.get(id) ?? 0;
|
|
3689
|
+
let candidate = { x: column * SPACING_X, y: rows.get(id) ?? 0 };
|
|
3690
|
+
while (overlapsAny(candidate, occupied)) {
|
|
3691
|
+
candidate = { x: candidate.x, y: candidate.y + SPACING_Y };
|
|
3692
|
+
}
|
|
3693
|
+
positions.set(id, candidate);
|
|
3694
|
+
occupied.push(candidate);
|
|
3695
|
+
}
|
|
3696
|
+
return positions;
|
|
3697
|
+
}
|
|
3698
|
+
function columnByDepth(ids, edges) {
|
|
3699
|
+
const present = new Set(ids);
|
|
3700
|
+
const real = edges.filter(
|
|
3701
|
+
(e) => e.source_instance !== e.target_instance && present.has(e.source_instance) && present.has(e.target_instance)
|
|
3702
|
+
);
|
|
3703
|
+
const depth = new Map(ids.map((id) => [id, 0]));
|
|
3704
|
+
for (let round = 0; round < ids.length; round += 1) {
|
|
3705
|
+
let moved = false;
|
|
3706
|
+
for (const e of real) {
|
|
3707
|
+
const want = (depth.get(e.source_instance) ?? 0) + 1;
|
|
3708
|
+
if (want > (depth.get(e.target_instance) ?? 0)) {
|
|
3709
|
+
depth.set(e.target_instance, want);
|
|
3710
|
+
moved = true;
|
|
3711
|
+
}
|
|
3712
|
+
}
|
|
3713
|
+
if (!moved) break;
|
|
3714
|
+
}
|
|
3715
|
+
return depth;
|
|
3716
|
+
}
|
|
3806
3717
|
|
|
3807
3718
|
// src/projection/derive-edges.ts
|
|
3808
3719
|
var moduleDepPattern = /\bmodule\.([A-Za-z_][A-Za-z0-9_-]*)(?:\[\s*(?:\*|[0-9]+|"[^"]*")\s*\])?\.([A-Za-z_][A-Za-z0-9_-]*)/g;
|
|
@@ -3863,11 +3774,6 @@ function indexWires(edges) {
|
|
|
3863
3774
|
return { inputs, outputs };
|
|
3864
3775
|
}
|
|
3865
3776
|
|
|
3866
|
-
// src/projection/join-path.ts
|
|
3867
|
-
function joinPath(prefix, localId) {
|
|
3868
|
-
return prefix === "" ? localId : `${prefix}.${localId}`;
|
|
3869
|
-
}
|
|
3870
|
-
|
|
3871
3777
|
// src/projection/project-group.ts
|
|
3872
3778
|
function projectGroup(use, target, fullId, parentArrangement) {
|
|
3873
3779
|
const childIds = (target.modules ?? []).map((u) => joinPath(fullId, u.id));
|
|
@@ -3924,8 +3830,7 @@ function descendScope(bundle, scopeKey, segments) {
|
|
|
3924
3830
|
}
|
|
3925
3831
|
|
|
3926
3832
|
// src/projection/project-node.ts
|
|
3927
|
-
function projectNode(bundle, use, fullId, position, wiredIn, wiredOut
|
|
3928
|
-
const errorMessages = errorsByInstance.get(use.id) ?? [];
|
|
3833
|
+
function projectNode(bundle, use, fullId, position, wiredIn, wiredOut) {
|
|
3929
3834
|
const schema = resolveSchema(bundle, use);
|
|
3930
3835
|
return {
|
|
3931
3836
|
id: fullId,
|
|
@@ -3933,8 +3838,6 @@ function projectNode(bundle, use, fullId, position, wiredIn, wiredOut, errorsByI
|
|
|
3933
3838
|
kind: "module",
|
|
3934
3839
|
module_key: use.module,
|
|
3935
3840
|
position,
|
|
3936
|
-
has_errors: errorMessages.length > 0,
|
|
3937
|
-
error_messages: errorMessages,
|
|
3938
3841
|
inputs: schema.inputs.map((in_) => ({
|
|
3939
3842
|
name: in_.name,
|
|
3940
3843
|
type: in_.type,
|
|
@@ -3953,7 +3856,12 @@ function projectNode(bundle, use, fullId, position, wiredIn, wiredOut, errorsByI
|
|
|
3953
3856
|
}
|
|
3954
3857
|
|
|
3955
3858
|
// src/projection/project-scope.ts
|
|
3956
|
-
function
|
|
3859
|
+
function requirePosition(positions, id) {
|
|
3860
|
+
const pos = positions.get(id);
|
|
3861
|
+
if (!pos) throw new Error(`projectScope: no computed position for "${id}"`);
|
|
3862
|
+
return pos;
|
|
3863
|
+
}
|
|
3864
|
+
function projectScope(bundle, mod, path, arrangement) {
|
|
3957
3865
|
const uses = mod.modules ?? [];
|
|
3958
3866
|
const derived = deriveEdges(uses);
|
|
3959
3867
|
const { inputs: wiredIn, outputs: wiredOut } = indexWires(derived);
|
|
@@ -3963,7 +3871,7 @@ function projectScope(bundle, mod, path, arrangement, errorsByInstance) {
|
|
|
3963
3871
|
const groups = [];
|
|
3964
3872
|
const classified = uses.map((use) => ({ use, group: isGroupUse(bundle, use) }));
|
|
3965
3873
|
const nodeUseIds = classified.filter((c) => !c.group).map((c) => c.use.id);
|
|
3966
|
-
const positions =
|
|
3874
|
+
const positions = resolveScopePositionsByDepth(nodeUseIds, scopeArrangement?.nodes, derived);
|
|
3967
3875
|
for (const { use, group } of classified) {
|
|
3968
3876
|
const fullId = joinPath(path, use.id);
|
|
3969
3877
|
if (group) {
|
|
@@ -3976,13 +3884,12 @@ function projectScope(bundle, mod, path, arrangement, errorsByInstance) {
|
|
|
3976
3884
|
bundle,
|
|
3977
3885
|
use,
|
|
3978
3886
|
fullId,
|
|
3979
|
-
// Every non-group use is in nodeUseIds, so
|
|
3980
|
-
// always has an entry for it —
|
|
3981
|
-
//
|
|
3982
|
-
positions
|
|
3887
|
+
// Every non-group use is in nodeUseIds, so resolveScopePositionsByDepth
|
|
3888
|
+
// always has an entry for it — requirePosition turns that into a
|
|
3889
|
+
// checked invariant instead of a silent gap a fallback would mask.
|
|
3890
|
+
requirePosition(positions, use.id),
|
|
3983
3891
|
wiredIn.get(use.id) ?? /* @__PURE__ */ new Set(),
|
|
3984
|
-
wiredOut.get(use.id) ?? /* @__PURE__ */ new Set()
|
|
3985
|
-
errorsByInstance
|
|
3892
|
+
wiredOut.get(use.id) ?? /* @__PURE__ */ new Set()
|
|
3986
3893
|
)
|
|
3987
3894
|
);
|
|
3988
3895
|
}
|
|
@@ -4000,38 +3907,6 @@ function projectScope(bundle, mod, path, arrangement, errorsByInstance) {
|
|
|
4000
3907
|
return { nodes, edges, groups };
|
|
4001
3908
|
}
|
|
4002
3909
|
|
|
4003
|
-
// src/projection/view-validate.ts
|
|
4004
|
-
function missingRequiredInputErrors(nodes) {
|
|
4005
|
-
const errors = [];
|
|
4006
|
-
for (const node of nodes) {
|
|
4007
|
-
for (const pin of node.inputs ?? []) {
|
|
4008
|
-
if (pin.required && !pin.wired) {
|
|
4009
|
-
errors.push({
|
|
4010
|
-
instance_id: node.id,
|
|
4011
|
-
input_name: pin.name,
|
|
4012
|
-
message: `Required input "${pin.name}" is not set`
|
|
4013
|
-
});
|
|
4014
|
-
}
|
|
4015
|
-
}
|
|
4016
|
-
}
|
|
4017
|
-
return errors;
|
|
4018
|
-
}
|
|
4019
|
-
function danglingEdgeErrors(nodes, groups, edges) {
|
|
4020
|
-
const known = /* @__PURE__ */ new Set();
|
|
4021
|
-
for (const n of nodes) known.add(n.id);
|
|
4022
|
-
for (const g of groups) known.add(g.id);
|
|
4023
|
-
const errors = [];
|
|
4024
|
-
for (const e of edges) {
|
|
4025
|
-
if (!known.has(e.source) || !known.has(e.target)) {
|
|
4026
|
-
errors.push({
|
|
4027
|
-
instance_id: e.id,
|
|
4028
|
-
message: `Edge "${e.id}" has dangling endpoint(s): source="${e.source}" target="${e.target}"`
|
|
4029
|
-
});
|
|
4030
|
-
}
|
|
4031
|
-
}
|
|
4032
|
-
return errors;
|
|
4033
|
-
}
|
|
4034
|
-
|
|
4035
3910
|
// src/projection/walk-modules.ts
|
|
4036
3911
|
function walk(bundle, visit) {
|
|
4037
3912
|
if (!bundle) return;
|
|
@@ -4049,39 +3924,30 @@ function walkFrom(bundle, mod, use, path, visit) {
|
|
|
4049
3924
|
}
|
|
4050
3925
|
|
|
4051
3926
|
// src/projection/project.ts
|
|
3927
|
+
var EMPTY_BUNDLE = Bundle.fromPartial({
|
|
3928
|
+
entry: "root@v1",
|
|
3929
|
+
modules: { "root@v1": { id: "root", version: "v1.0.0" } }
|
|
3930
|
+
});
|
|
4052
3931
|
function projectCanvasView(bundle, arrangement, meta) {
|
|
4053
3932
|
const nodes = [];
|
|
4054
3933
|
const edges = [];
|
|
4055
3934
|
const groups = [];
|
|
4056
|
-
const errorsByInstance = /* @__PURE__ */ new Map();
|
|
4057
3935
|
walk(bundle, (mod, _use, path) => {
|
|
4058
|
-
const scope = projectScope(bundle, mod, path, arrangement
|
|
3936
|
+
const scope = projectScope(bundle, mod, path, arrangement);
|
|
4059
3937
|
nodes.push(...scope.nodes);
|
|
4060
3938
|
edges.push(...scope.edges);
|
|
4061
3939
|
groups.push(...scope.groups);
|
|
4062
3940
|
});
|
|
4063
|
-
const errors = [
|
|
4064
|
-
...missingRequiredInputErrors(nodes),
|
|
4065
|
-
...danglingEdgeErrors(nodes, groups, edges)
|
|
4066
|
-
];
|
|
4067
|
-
errors.sort((a, b) => {
|
|
4068
|
-
const ai = a.instance_id ?? "";
|
|
4069
|
-
const bi = b.instance_id ?? "";
|
|
4070
|
-
if (ai !== bi) return ai < bi ? -1 : 1;
|
|
4071
|
-
const an = a.input_name ?? "";
|
|
4072
|
-
const bn = b.input_name ?? "";
|
|
4073
|
-
if (an !== bn) return an < bn ? -1 : 1;
|
|
4074
|
-
return a.message < b.message ? -1 : a.message > b.message ? 1 : 0;
|
|
4075
|
-
});
|
|
4076
3941
|
const moduleName = meta.moduleName ?? parseModuleKey(bundle.entry).id;
|
|
4077
3942
|
return {
|
|
4078
3943
|
module_name: moduleName,
|
|
4079
3944
|
nodes,
|
|
4080
3945
|
edges,
|
|
4081
|
-
errors,
|
|
4082
3946
|
can_undo: meta.canUndo,
|
|
4083
3947
|
can_redo: meta.canRedo,
|
|
4084
|
-
|
|
3948
|
+
unsaved: meta.unsaved,
|
|
3949
|
+
conflict: meta.conflict,
|
|
3950
|
+
ungenerated: meta.ungenerated ?? false,
|
|
4085
3951
|
// Every group is now a Use whose target has sub-Uses (CreateGroupAction
|
|
4086
3952
|
// mints a module); emission order already mirrors Use declaration order
|
|
4087
3953
|
// via the walk, so no separate user-group sort is needed.
|
|
@@ -4126,145 +3992,8 @@ function nodeKindToJSON(object) {
|
|
|
4126
3992
|
return "UNRECOGNIZED";
|
|
4127
3993
|
}
|
|
4128
3994
|
}
|
|
4129
|
-
function inputModeFromJSON(object) {
|
|
4130
|
-
switch (object) {
|
|
4131
|
-
case 0:
|
|
4132
|
-
case "INPUT_MODE_UNSPECIFIED":
|
|
4133
|
-
return 0 /* INPUT_MODE_UNSPECIFIED */;
|
|
4134
|
-
case 1:
|
|
4135
|
-
case "INPUT_MODE_EMPTY":
|
|
4136
|
-
return 1 /* INPUT_MODE_EMPTY */;
|
|
4137
|
-
case 2:
|
|
4138
|
-
case "INPUT_MODE_LITERAL":
|
|
4139
|
-
return 2 /* INPUT_MODE_LITERAL */;
|
|
4140
|
-
case 3:
|
|
4141
|
-
case "INPUT_MODE_VARIABLE":
|
|
4142
|
-
return 3 /* INPUT_MODE_VARIABLE */;
|
|
4143
|
-
case 4:
|
|
4144
|
-
case "INPUT_MODE_EXPRESSION":
|
|
4145
|
-
return 4 /* INPUT_MODE_EXPRESSION */;
|
|
4146
|
-
case 5:
|
|
4147
|
-
case "INPUT_MODE_WIRED":
|
|
4148
|
-
return 5 /* INPUT_MODE_WIRED */;
|
|
4149
|
-
case -1:
|
|
4150
|
-
case "UNRECOGNIZED":
|
|
4151
|
-
default:
|
|
4152
|
-
return -1 /* UNRECOGNIZED */;
|
|
4153
|
-
}
|
|
4154
|
-
}
|
|
4155
|
-
function inputModeToJSON(object) {
|
|
4156
|
-
switch (object) {
|
|
4157
|
-
case 0 /* INPUT_MODE_UNSPECIFIED */:
|
|
4158
|
-
return "INPUT_MODE_UNSPECIFIED";
|
|
4159
|
-
case 1 /* INPUT_MODE_EMPTY */:
|
|
4160
|
-
return "INPUT_MODE_EMPTY";
|
|
4161
|
-
case 2 /* INPUT_MODE_LITERAL */:
|
|
4162
|
-
return "INPUT_MODE_LITERAL";
|
|
4163
|
-
case 3 /* INPUT_MODE_VARIABLE */:
|
|
4164
|
-
return "INPUT_MODE_VARIABLE";
|
|
4165
|
-
case 4 /* INPUT_MODE_EXPRESSION */:
|
|
4166
|
-
return "INPUT_MODE_EXPRESSION";
|
|
4167
|
-
case 5 /* INPUT_MODE_WIRED */:
|
|
4168
|
-
return "INPUT_MODE_WIRED";
|
|
4169
|
-
case -1 /* UNRECOGNIZED */:
|
|
4170
|
-
default:
|
|
4171
|
-
return "UNRECOGNIZED";
|
|
4172
|
-
}
|
|
4173
|
-
}
|
|
4174
|
-
function createBaseOutputExportEntry() {
|
|
4175
|
-
return { name: "", source_instance: "", source_output: "" };
|
|
4176
|
-
}
|
|
4177
|
-
var OutputExportEntry = {
|
|
4178
|
-
encode(message, writer = new BinaryWriter3()) {
|
|
4179
|
-
if (message.name !== "") {
|
|
4180
|
-
writer.uint32(10).string(message.name);
|
|
4181
|
-
}
|
|
4182
|
-
if (message.source_instance !== "") {
|
|
4183
|
-
writer.uint32(18).string(message.source_instance);
|
|
4184
|
-
}
|
|
4185
|
-
if (message.source_output !== "") {
|
|
4186
|
-
writer.uint32(26).string(message.source_output);
|
|
4187
|
-
}
|
|
4188
|
-
return writer;
|
|
4189
|
-
},
|
|
4190
|
-
decode(input, length) {
|
|
4191
|
-
const reader = input instanceof BinaryReader3 ? input : new BinaryReader3(input);
|
|
4192
|
-
const end = length === void 0 ? reader.len : reader.pos + length;
|
|
4193
|
-
const message = createBaseOutputExportEntry();
|
|
4194
|
-
while (reader.pos < end) {
|
|
4195
|
-
const tag = reader.uint32();
|
|
4196
|
-
switch (tag >>> 3) {
|
|
4197
|
-
case 1: {
|
|
4198
|
-
if (tag !== 10) {
|
|
4199
|
-
break;
|
|
4200
|
-
}
|
|
4201
|
-
message.name = reader.string();
|
|
4202
|
-
continue;
|
|
4203
|
-
}
|
|
4204
|
-
case 2: {
|
|
4205
|
-
if (tag !== 18) {
|
|
4206
|
-
break;
|
|
4207
|
-
}
|
|
4208
|
-
message.source_instance = reader.string();
|
|
4209
|
-
continue;
|
|
4210
|
-
}
|
|
4211
|
-
case 3: {
|
|
4212
|
-
if (tag !== 26) {
|
|
4213
|
-
break;
|
|
4214
|
-
}
|
|
4215
|
-
message.source_output = reader.string();
|
|
4216
|
-
continue;
|
|
4217
|
-
}
|
|
4218
|
-
}
|
|
4219
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
4220
|
-
break;
|
|
4221
|
-
}
|
|
4222
|
-
reader.skip(tag & 7);
|
|
4223
|
-
}
|
|
4224
|
-
return message;
|
|
4225
|
-
},
|
|
4226
|
-
fromJSON(object) {
|
|
4227
|
-
return {
|
|
4228
|
-
name: isSet3(object.name) ? globalThis.String(object.name) : "",
|
|
4229
|
-
source_instance: isSet3(object.sourceInstance) ? globalThis.String(object.sourceInstance) : isSet3(object.source_instance) ? globalThis.String(object.source_instance) : "",
|
|
4230
|
-
source_output: isSet3(object.sourceOutput) ? globalThis.String(object.sourceOutput) : isSet3(object.source_output) ? globalThis.String(object.source_output) : ""
|
|
4231
|
-
};
|
|
4232
|
-
},
|
|
4233
|
-
toJSON(message) {
|
|
4234
|
-
const obj = {};
|
|
4235
|
-
if (message.name !== "") {
|
|
4236
|
-
obj.name = message.name;
|
|
4237
|
-
}
|
|
4238
|
-
if (message.source_instance !== "") {
|
|
4239
|
-
obj.sourceInstance = message.source_instance;
|
|
4240
|
-
}
|
|
4241
|
-
if (message.source_output !== "") {
|
|
4242
|
-
obj.sourceOutput = message.source_output;
|
|
4243
|
-
}
|
|
4244
|
-
return obj;
|
|
4245
|
-
},
|
|
4246
|
-
create(base) {
|
|
4247
|
-
return OutputExportEntry.fromPartial(base ?? {});
|
|
4248
|
-
},
|
|
4249
|
-
fromPartial(object) {
|
|
4250
|
-
const message = createBaseOutputExportEntry();
|
|
4251
|
-
message.name = object.name ?? "";
|
|
4252
|
-
message.source_instance = object.source_instance ?? "";
|
|
4253
|
-
message.source_output = object.source_output ?? "";
|
|
4254
|
-
return message;
|
|
4255
|
-
}
|
|
4256
|
-
};
|
|
4257
3995
|
function createBaseCanvasView() {
|
|
4258
|
-
return {
|
|
4259
|
-
module_name: "",
|
|
4260
|
-
nodes: [],
|
|
4261
|
-
edges: [],
|
|
4262
|
-
errors: [],
|
|
4263
|
-
can_undo: false,
|
|
4264
|
-
can_redo: false,
|
|
4265
|
-
is_dirty: false,
|
|
4266
|
-
groups: []
|
|
4267
|
-
};
|
|
3996
|
+
return { module_name: "", nodes: [], edges: [], can_undo: false, can_redo: false, unsaved: false, groups: [] };
|
|
4268
3997
|
}
|
|
4269
3998
|
var CanvasView = {
|
|
4270
3999
|
encode(message, writer = new BinaryWriter3()) {
|
|
@@ -4277,17 +4006,14 @@ var CanvasView = {
|
|
|
4277
4006
|
for (const v of message.edges) {
|
|
4278
4007
|
RenderEdge.encode(v, writer.uint32(26).fork()).join();
|
|
4279
4008
|
}
|
|
4280
|
-
for (const v of message.errors) {
|
|
4281
|
-
RenderError.encode(v, writer.uint32(34).fork()).join();
|
|
4282
|
-
}
|
|
4283
4009
|
if (message.can_undo !== false) {
|
|
4284
4010
|
writer.uint32(40).bool(message.can_undo);
|
|
4285
4011
|
}
|
|
4286
4012
|
if (message.can_redo !== false) {
|
|
4287
4013
|
writer.uint32(48).bool(message.can_redo);
|
|
4288
4014
|
}
|
|
4289
|
-
if (message.
|
|
4290
|
-
writer.uint32(56).bool(message.
|
|
4015
|
+
if (message.unsaved !== false) {
|
|
4016
|
+
writer.uint32(56).bool(message.unsaved);
|
|
4291
4017
|
}
|
|
4292
4018
|
for (const v of message.groups) {
|
|
4293
4019
|
RenderGroup.encode(v, writer.uint32(66).fork()).join();
|
|
@@ -4322,13 +4048,6 @@ var CanvasView = {
|
|
|
4322
4048
|
message.edges.push(RenderEdge.decode(reader, reader.uint32()));
|
|
4323
4049
|
continue;
|
|
4324
4050
|
}
|
|
4325
|
-
case 4: {
|
|
4326
|
-
if (tag !== 34) {
|
|
4327
|
-
break;
|
|
4328
|
-
}
|
|
4329
|
-
message.errors.push(RenderError.decode(reader, reader.uint32()));
|
|
4330
|
-
continue;
|
|
4331
|
-
}
|
|
4332
4051
|
case 5: {
|
|
4333
4052
|
if (tag !== 40) {
|
|
4334
4053
|
break;
|
|
@@ -4347,7 +4066,7 @@ var CanvasView = {
|
|
|
4347
4066
|
if (tag !== 56) {
|
|
4348
4067
|
break;
|
|
4349
4068
|
}
|
|
4350
|
-
message.
|
|
4069
|
+
message.unsaved = reader.bool();
|
|
4351
4070
|
continue;
|
|
4352
4071
|
}
|
|
4353
4072
|
case 8: {
|
|
@@ -4370,10 +4089,9 @@ var CanvasView = {
|
|
|
4370
4089
|
module_name: isSet3(object.moduleName) ? globalThis.String(object.moduleName) : isSet3(object.module_name) ? globalThis.String(object.module_name) : "",
|
|
4371
4090
|
nodes: globalThis.Array.isArray(object?.nodes) ? object.nodes.map((e) => RenderNode.fromJSON(e)) : [],
|
|
4372
4091
|
edges: globalThis.Array.isArray(object?.edges) ? object.edges.map((e) => RenderEdge.fromJSON(e)) : [],
|
|
4373
|
-
errors: globalThis.Array.isArray(object?.errors) ? object.errors.map((e) => RenderError.fromJSON(e)) : [],
|
|
4374
4092
|
can_undo: isSet3(object.canUndo) ? globalThis.Boolean(object.canUndo) : isSet3(object.can_undo) ? globalThis.Boolean(object.can_undo) : false,
|
|
4375
4093
|
can_redo: isSet3(object.canRedo) ? globalThis.Boolean(object.canRedo) : isSet3(object.can_redo) ? globalThis.Boolean(object.can_redo) : false,
|
|
4376
|
-
|
|
4094
|
+
unsaved: isSet3(object.unsaved) ? globalThis.Boolean(object.unsaved) : false,
|
|
4377
4095
|
groups: globalThis.Array.isArray(object?.groups) ? object.groups.map((e) => RenderGroup.fromJSON(e)) : []
|
|
4378
4096
|
};
|
|
4379
4097
|
},
|
|
@@ -4388,17 +4106,14 @@ var CanvasView = {
|
|
|
4388
4106
|
if (message.edges?.length) {
|
|
4389
4107
|
obj.edges = message.edges.map((e) => RenderEdge.toJSON(e));
|
|
4390
4108
|
}
|
|
4391
|
-
if (message.errors?.length) {
|
|
4392
|
-
obj.errors = message.errors.map((e) => RenderError.toJSON(e));
|
|
4393
|
-
}
|
|
4394
4109
|
if (message.can_undo !== false) {
|
|
4395
4110
|
obj.canUndo = message.can_undo;
|
|
4396
4111
|
}
|
|
4397
4112
|
if (message.can_redo !== false) {
|
|
4398
4113
|
obj.canRedo = message.can_redo;
|
|
4399
4114
|
}
|
|
4400
|
-
if (message.
|
|
4401
|
-
obj.
|
|
4115
|
+
if (message.unsaved !== false) {
|
|
4116
|
+
obj.unsaved = message.unsaved;
|
|
4402
4117
|
}
|
|
4403
4118
|
if (message.groups?.length) {
|
|
4404
4119
|
obj.groups = message.groups.map((e) => RenderGroup.toJSON(e));
|
|
@@ -4413,10 +4128,9 @@ var CanvasView = {
|
|
|
4413
4128
|
message.module_name = object.module_name ?? "";
|
|
4414
4129
|
message.nodes = object.nodes?.map((e) => RenderNode.fromPartial(e)) || [];
|
|
4415
4130
|
message.edges = object.edges?.map((e) => RenderEdge.fromPartial(e)) || [];
|
|
4416
|
-
message.errors = object.errors?.map((e) => RenderError.fromPartial(e)) || [];
|
|
4417
4131
|
message.can_undo = object.can_undo ?? false;
|
|
4418
4132
|
message.can_redo = object.can_redo ?? false;
|
|
4419
|
-
message.
|
|
4133
|
+
message.unsaved = object.unsaved ?? false;
|
|
4420
4134
|
message.groups = object.groups?.map((e) => RenderGroup.fromPartial(e)) || [];
|
|
4421
4135
|
return message;
|
|
4422
4136
|
}
|
|
@@ -4565,18 +4279,7 @@ var RenderGroup = {
|
|
|
4565
4279
|
}
|
|
4566
4280
|
};
|
|
4567
4281
|
function createBaseRenderNode() {
|
|
4568
|
-
return {
|
|
4569
|
-
id: "",
|
|
4570
|
-
label: "",
|
|
4571
|
-
kind: 0,
|
|
4572
|
-
module_key: "",
|
|
4573
|
-
icon_url: "",
|
|
4574
|
-
position: void 0,
|
|
4575
|
-
has_errors: false,
|
|
4576
|
-
error_messages: [],
|
|
4577
|
-
inputs: [],
|
|
4578
|
-
outputs: []
|
|
4579
|
-
};
|
|
4282
|
+
return { id: "", label: "", kind: 0, module_key: "", icon_url: "", position: void 0, inputs: [], outputs: [] };
|
|
4580
4283
|
}
|
|
4581
4284
|
var RenderNode = {
|
|
4582
4285
|
encode(message, writer = new BinaryWriter3()) {
|
|
@@ -4598,12 +4301,6 @@ var RenderNode = {
|
|
|
4598
4301
|
if (message.position !== void 0) {
|
|
4599
4302
|
Position.encode(message.position, writer.uint32(50).fork()).join();
|
|
4600
4303
|
}
|
|
4601
|
-
if (message.has_errors !== false) {
|
|
4602
|
-
writer.uint32(56).bool(message.has_errors);
|
|
4603
|
-
}
|
|
4604
|
-
for (const v of message.error_messages) {
|
|
4605
|
-
writer.uint32(66).string(v);
|
|
4606
|
-
}
|
|
4607
4304
|
for (const v of message.inputs) {
|
|
4608
4305
|
NodePin.encode(v, writer.uint32(74).fork()).join();
|
|
4609
4306
|
}
|
|
@@ -4661,20 +4358,6 @@ var RenderNode = {
|
|
|
4661
4358
|
message.position = Position.decode(reader, reader.uint32());
|
|
4662
4359
|
continue;
|
|
4663
4360
|
}
|
|
4664
|
-
case 7: {
|
|
4665
|
-
if (tag !== 56) {
|
|
4666
|
-
break;
|
|
4667
|
-
}
|
|
4668
|
-
message.has_errors = reader.bool();
|
|
4669
|
-
continue;
|
|
4670
|
-
}
|
|
4671
|
-
case 8: {
|
|
4672
|
-
if (tag !== 66) {
|
|
4673
|
-
break;
|
|
4674
|
-
}
|
|
4675
|
-
message.error_messages.push(reader.string());
|
|
4676
|
-
continue;
|
|
4677
|
-
}
|
|
4678
4361
|
case 9: {
|
|
4679
4362
|
if (tag !== 74) {
|
|
4680
4363
|
break;
|
|
@@ -4705,8 +4388,6 @@ var RenderNode = {
|
|
|
4705
4388
|
module_key: isSet3(object.moduleKey) ? globalThis.String(object.moduleKey) : isSet3(object.module_key) ? globalThis.String(object.module_key) : "",
|
|
4706
4389
|
icon_url: isSet3(object.iconUrl) ? globalThis.String(object.iconUrl) : isSet3(object.icon_url) ? globalThis.String(object.icon_url) : "",
|
|
4707
4390
|
position: isSet3(object.position) ? Position.fromJSON(object.position) : void 0,
|
|
4708
|
-
has_errors: isSet3(object.hasErrors) ? globalThis.Boolean(object.hasErrors) : isSet3(object.has_errors) ? globalThis.Boolean(object.has_errors) : false,
|
|
4709
|
-
error_messages: globalThis.Array.isArray(object?.errorMessages) ? object.errorMessages.map((e) => globalThis.String(e)) : globalThis.Array.isArray(object?.error_messages) ? object.error_messages.map((e) => globalThis.String(e)) : [],
|
|
4710
4391
|
inputs: globalThis.Array.isArray(object?.inputs) ? object.inputs.map((e) => NodePin.fromJSON(e)) : [],
|
|
4711
4392
|
outputs: globalThis.Array.isArray(object?.outputs) ? object.outputs.map((e) => NodePin.fromJSON(e)) : []
|
|
4712
4393
|
};
|
|
@@ -4731,12 +4412,6 @@ var RenderNode = {
|
|
|
4731
4412
|
if (message.position !== void 0) {
|
|
4732
4413
|
obj.position = Position.toJSON(message.position);
|
|
4733
4414
|
}
|
|
4734
|
-
if (message.has_errors !== false) {
|
|
4735
|
-
obj.hasErrors = message.has_errors;
|
|
4736
|
-
}
|
|
4737
|
-
if (message.error_messages?.length) {
|
|
4738
|
-
obj.errorMessages = message.error_messages;
|
|
4739
|
-
}
|
|
4740
4415
|
if (message.inputs?.length) {
|
|
4741
4416
|
obj.inputs = message.inputs.map((e) => NodePin.toJSON(e));
|
|
4742
4417
|
}
|
|
@@ -4756,8 +4431,6 @@ var RenderNode = {
|
|
|
4756
4431
|
message.module_key = object.module_key ?? "";
|
|
4757
4432
|
message.icon_url = object.icon_url ?? "";
|
|
4758
4433
|
message.position = object.position !== void 0 && object.position !== null ? Position.fromPartial(object.position) : void 0;
|
|
4759
|
-
message.has_errors = object.has_errors ?? false;
|
|
4760
|
-
message.error_messages = object.error_messages?.map((e) => e) || [];
|
|
4761
4434
|
message.inputs = object.inputs?.map((e) => NodePin.fromPartial(e)) || [];
|
|
4762
4435
|
message.outputs = object.outputs?.map((e) => NodePin.fromPartial(e)) || [];
|
|
4763
4436
|
return message;
|
|
@@ -5004,2164 +4677,38 @@ var RenderEdge = {
|
|
|
5004
4677
|
return message;
|
|
5005
4678
|
}
|
|
5006
4679
|
};
|
|
5007
|
-
function
|
|
5008
|
-
return {
|
|
5009
|
-
name: "",
|
|
5010
|
-
type: "",
|
|
5011
|
-
required: false,
|
|
5012
|
-
description: "",
|
|
5013
|
-
default_value: void 0,
|
|
5014
|
-
validation: void 0,
|
|
5015
|
-
mode: 0,
|
|
5016
|
-
value: void 0,
|
|
5017
|
-
variable: "",
|
|
5018
|
-
expression: "",
|
|
5019
|
-
wired_source: ""
|
|
5020
|
-
};
|
|
4680
|
+
function createBasePosition() {
|
|
4681
|
+
return { x: 0, y: 0 };
|
|
5021
4682
|
}
|
|
5022
|
-
var
|
|
4683
|
+
var Position = {
|
|
5023
4684
|
encode(message, writer = new BinaryWriter3()) {
|
|
5024
|
-
if (message.
|
|
5025
|
-
writer.uint32(
|
|
5026
|
-
}
|
|
5027
|
-
if (message.type !== "") {
|
|
5028
|
-
writer.uint32(18).string(message.type);
|
|
5029
|
-
}
|
|
5030
|
-
if (message.required !== false) {
|
|
5031
|
-
writer.uint32(24).bool(message.required);
|
|
5032
|
-
}
|
|
5033
|
-
if (message.description !== "") {
|
|
5034
|
-
writer.uint32(34).string(message.description);
|
|
5035
|
-
}
|
|
5036
|
-
if (message.default_value !== void 0) {
|
|
5037
|
-
Value.encode(Value.wrap(message.default_value), writer.uint32(42).fork()).join();
|
|
5038
|
-
}
|
|
5039
|
-
if (message.validation !== void 0) {
|
|
5040
|
-
ValidationBlock2.encode(message.validation, writer.uint32(50).fork()).join();
|
|
4685
|
+
if (message.x !== 0) {
|
|
4686
|
+
writer.uint32(9).double(message.x);
|
|
5041
4687
|
}
|
|
5042
|
-
if (message.
|
|
5043
|
-
writer.uint32(
|
|
5044
|
-
}
|
|
5045
|
-
if (message.value !== void 0) {
|
|
5046
|
-
Value.encode(Value.wrap(message.value), writer.uint32(66).fork()).join();
|
|
5047
|
-
}
|
|
5048
|
-
if (message.variable !== "") {
|
|
5049
|
-
writer.uint32(74).string(message.variable);
|
|
5050
|
-
}
|
|
5051
|
-
if (message.expression !== "") {
|
|
5052
|
-
writer.uint32(82).string(message.expression);
|
|
5053
|
-
}
|
|
5054
|
-
if (message.wired_source !== "") {
|
|
5055
|
-
writer.uint32(90).string(message.wired_source);
|
|
5056
|
-
}
|
|
5057
|
-
return writer;
|
|
5058
|
-
},
|
|
5059
|
-
decode(input, length) {
|
|
5060
|
-
const reader = input instanceof BinaryReader3 ? input : new BinaryReader3(input);
|
|
5061
|
-
const end = length === void 0 ? reader.len : reader.pos + length;
|
|
5062
|
-
const message = createBaseRenderInput();
|
|
5063
|
-
while (reader.pos < end) {
|
|
5064
|
-
const tag = reader.uint32();
|
|
5065
|
-
switch (tag >>> 3) {
|
|
5066
|
-
case 1: {
|
|
5067
|
-
if (tag !== 10) {
|
|
5068
|
-
break;
|
|
5069
|
-
}
|
|
5070
|
-
message.name = reader.string();
|
|
5071
|
-
continue;
|
|
5072
|
-
}
|
|
5073
|
-
case 2: {
|
|
5074
|
-
if (tag !== 18) {
|
|
5075
|
-
break;
|
|
5076
|
-
}
|
|
5077
|
-
message.type = reader.string();
|
|
5078
|
-
continue;
|
|
5079
|
-
}
|
|
5080
|
-
case 3: {
|
|
5081
|
-
if (tag !== 24) {
|
|
5082
|
-
break;
|
|
5083
|
-
}
|
|
5084
|
-
message.required = reader.bool();
|
|
5085
|
-
continue;
|
|
5086
|
-
}
|
|
5087
|
-
case 4: {
|
|
5088
|
-
if (tag !== 34) {
|
|
5089
|
-
break;
|
|
5090
|
-
}
|
|
5091
|
-
message.description = reader.string();
|
|
5092
|
-
continue;
|
|
5093
|
-
}
|
|
5094
|
-
case 5: {
|
|
5095
|
-
if (tag !== 42) {
|
|
5096
|
-
break;
|
|
5097
|
-
}
|
|
5098
|
-
message.default_value = Value.unwrap(Value.decode(reader, reader.uint32()));
|
|
5099
|
-
continue;
|
|
5100
|
-
}
|
|
5101
|
-
case 6: {
|
|
5102
|
-
if (tag !== 50) {
|
|
5103
|
-
break;
|
|
5104
|
-
}
|
|
5105
|
-
message.validation = ValidationBlock2.decode(reader, reader.uint32());
|
|
5106
|
-
continue;
|
|
5107
|
-
}
|
|
5108
|
-
case 7: {
|
|
5109
|
-
if (tag !== 56) {
|
|
5110
|
-
break;
|
|
5111
|
-
}
|
|
5112
|
-
message.mode = reader.int32();
|
|
5113
|
-
continue;
|
|
5114
|
-
}
|
|
5115
|
-
case 8: {
|
|
5116
|
-
if (tag !== 66) {
|
|
5117
|
-
break;
|
|
5118
|
-
}
|
|
5119
|
-
message.value = Value.unwrap(Value.decode(reader, reader.uint32()));
|
|
5120
|
-
continue;
|
|
5121
|
-
}
|
|
5122
|
-
case 9: {
|
|
5123
|
-
if (tag !== 74) {
|
|
5124
|
-
break;
|
|
5125
|
-
}
|
|
5126
|
-
message.variable = reader.string();
|
|
5127
|
-
continue;
|
|
5128
|
-
}
|
|
5129
|
-
case 10: {
|
|
5130
|
-
if (tag !== 82) {
|
|
5131
|
-
break;
|
|
5132
|
-
}
|
|
5133
|
-
message.expression = reader.string();
|
|
5134
|
-
continue;
|
|
5135
|
-
}
|
|
5136
|
-
case 11: {
|
|
5137
|
-
if (tag !== 90) {
|
|
5138
|
-
break;
|
|
5139
|
-
}
|
|
5140
|
-
message.wired_source = reader.string();
|
|
5141
|
-
continue;
|
|
5142
|
-
}
|
|
5143
|
-
}
|
|
5144
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
5145
|
-
break;
|
|
5146
|
-
}
|
|
5147
|
-
reader.skip(tag & 7);
|
|
5148
|
-
}
|
|
5149
|
-
return message;
|
|
5150
|
-
},
|
|
5151
|
-
fromJSON(object) {
|
|
5152
|
-
return {
|
|
5153
|
-
name: isSet3(object.name) ? globalThis.String(object.name) : "",
|
|
5154
|
-
type: isSet3(object.type) ? globalThis.String(object.type) : "",
|
|
5155
|
-
required: isSet3(object.required) ? globalThis.Boolean(object.required) : false,
|
|
5156
|
-
description: isSet3(object.description) ? globalThis.String(object.description) : "",
|
|
5157
|
-
default_value: isSet3(object?.defaultValue) ? object.defaultValue : isSet3(object?.default_value) ? object.default_value : void 0,
|
|
5158
|
-
validation: isSet3(object.validation) ? ValidationBlock2.fromJSON(object.validation) : void 0,
|
|
5159
|
-
mode: isSet3(object.mode) ? inputModeFromJSON(object.mode) : 0,
|
|
5160
|
-
value: isSet3(object?.value) ? object.value : void 0,
|
|
5161
|
-
variable: isSet3(object.variable) ? globalThis.String(object.variable) : "",
|
|
5162
|
-
expression: isSet3(object.expression) ? globalThis.String(object.expression) : "",
|
|
5163
|
-
wired_source: isSet3(object.wiredSource) ? globalThis.String(object.wiredSource) : isSet3(object.wired_source) ? globalThis.String(object.wired_source) : ""
|
|
5164
|
-
};
|
|
5165
|
-
},
|
|
5166
|
-
toJSON(message) {
|
|
5167
|
-
const obj = {};
|
|
5168
|
-
if (message.name !== "") {
|
|
5169
|
-
obj.name = message.name;
|
|
5170
|
-
}
|
|
5171
|
-
if (message.type !== "") {
|
|
5172
|
-
obj.type = message.type;
|
|
5173
|
-
}
|
|
5174
|
-
if (message.required !== false) {
|
|
5175
|
-
obj.required = message.required;
|
|
5176
|
-
}
|
|
5177
|
-
if (message.description !== "") {
|
|
5178
|
-
obj.description = message.description;
|
|
5179
|
-
}
|
|
5180
|
-
if (message.default_value !== void 0) {
|
|
5181
|
-
obj.defaultValue = message.default_value;
|
|
5182
|
-
}
|
|
5183
|
-
if (message.validation !== void 0) {
|
|
5184
|
-
obj.validation = ValidationBlock2.toJSON(message.validation);
|
|
5185
|
-
}
|
|
5186
|
-
if (message.mode !== 0) {
|
|
5187
|
-
obj.mode = inputModeToJSON(message.mode);
|
|
5188
|
-
}
|
|
5189
|
-
if (message.value !== void 0) {
|
|
5190
|
-
obj.value = message.value;
|
|
5191
|
-
}
|
|
5192
|
-
if (message.variable !== "") {
|
|
5193
|
-
obj.variable = message.variable;
|
|
5194
|
-
}
|
|
5195
|
-
if (message.expression !== "") {
|
|
5196
|
-
obj.expression = message.expression;
|
|
5197
|
-
}
|
|
5198
|
-
if (message.wired_source !== "") {
|
|
5199
|
-
obj.wiredSource = message.wired_source;
|
|
5200
|
-
}
|
|
5201
|
-
return obj;
|
|
5202
|
-
},
|
|
5203
|
-
create(base) {
|
|
5204
|
-
return RenderInput.fromPartial(base ?? {});
|
|
5205
|
-
},
|
|
5206
|
-
fromPartial(object) {
|
|
5207
|
-
const message = createBaseRenderInput();
|
|
5208
|
-
message.name = object.name ?? "";
|
|
5209
|
-
message.type = object.type ?? "";
|
|
5210
|
-
message.required = object.required ?? false;
|
|
5211
|
-
message.description = object.description ?? "";
|
|
5212
|
-
message.default_value = object.default_value ?? void 0;
|
|
5213
|
-
message.validation = object.validation !== void 0 && object.validation !== null ? ValidationBlock2.fromPartial(object.validation) : void 0;
|
|
5214
|
-
message.mode = object.mode ?? 0;
|
|
5215
|
-
message.value = object.value ?? void 0;
|
|
5216
|
-
message.variable = object.variable ?? "";
|
|
5217
|
-
message.expression = object.expression ?? "";
|
|
5218
|
-
message.wired_source = object.wired_source ?? "";
|
|
5219
|
-
return message;
|
|
5220
|
-
}
|
|
5221
|
-
};
|
|
5222
|
-
function createBaseRenderOutput() {
|
|
5223
|
-
return { name: "", type: "", description: "", sensitive: false };
|
|
5224
|
-
}
|
|
5225
|
-
var RenderOutput = {
|
|
5226
|
-
encode(message, writer = new BinaryWriter3()) {
|
|
5227
|
-
if (message.name !== "") {
|
|
5228
|
-
writer.uint32(10).string(message.name);
|
|
5229
|
-
}
|
|
5230
|
-
if (message.type !== "") {
|
|
5231
|
-
writer.uint32(18).string(message.type);
|
|
5232
|
-
}
|
|
5233
|
-
if (message.description !== "") {
|
|
5234
|
-
writer.uint32(26).string(message.description);
|
|
5235
|
-
}
|
|
5236
|
-
if (message.sensitive !== false) {
|
|
5237
|
-
writer.uint32(32).bool(message.sensitive);
|
|
5238
|
-
}
|
|
5239
|
-
return writer;
|
|
5240
|
-
},
|
|
5241
|
-
decode(input, length) {
|
|
5242
|
-
const reader = input instanceof BinaryReader3 ? input : new BinaryReader3(input);
|
|
5243
|
-
const end = length === void 0 ? reader.len : reader.pos + length;
|
|
5244
|
-
const message = createBaseRenderOutput();
|
|
5245
|
-
while (reader.pos < end) {
|
|
5246
|
-
const tag = reader.uint32();
|
|
5247
|
-
switch (tag >>> 3) {
|
|
5248
|
-
case 1: {
|
|
5249
|
-
if (tag !== 10) {
|
|
5250
|
-
break;
|
|
5251
|
-
}
|
|
5252
|
-
message.name = reader.string();
|
|
5253
|
-
continue;
|
|
5254
|
-
}
|
|
5255
|
-
case 2: {
|
|
5256
|
-
if (tag !== 18) {
|
|
5257
|
-
break;
|
|
5258
|
-
}
|
|
5259
|
-
message.type = reader.string();
|
|
5260
|
-
continue;
|
|
5261
|
-
}
|
|
5262
|
-
case 3: {
|
|
5263
|
-
if (tag !== 26) {
|
|
5264
|
-
break;
|
|
5265
|
-
}
|
|
5266
|
-
message.description = reader.string();
|
|
5267
|
-
continue;
|
|
5268
|
-
}
|
|
5269
|
-
case 4: {
|
|
5270
|
-
if (tag !== 32) {
|
|
5271
|
-
break;
|
|
5272
|
-
}
|
|
5273
|
-
message.sensitive = reader.bool();
|
|
5274
|
-
continue;
|
|
5275
|
-
}
|
|
5276
|
-
}
|
|
5277
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
5278
|
-
break;
|
|
5279
|
-
}
|
|
5280
|
-
reader.skip(tag & 7);
|
|
5281
|
-
}
|
|
5282
|
-
return message;
|
|
5283
|
-
},
|
|
5284
|
-
fromJSON(object) {
|
|
5285
|
-
return {
|
|
5286
|
-
name: isSet3(object.name) ? globalThis.String(object.name) : "",
|
|
5287
|
-
type: isSet3(object.type) ? globalThis.String(object.type) : "",
|
|
5288
|
-
description: isSet3(object.description) ? globalThis.String(object.description) : "",
|
|
5289
|
-
sensitive: isSet3(object.sensitive) ? globalThis.Boolean(object.sensitive) : false
|
|
5290
|
-
};
|
|
5291
|
-
},
|
|
5292
|
-
toJSON(message) {
|
|
5293
|
-
const obj = {};
|
|
5294
|
-
if (message.name !== "") {
|
|
5295
|
-
obj.name = message.name;
|
|
5296
|
-
}
|
|
5297
|
-
if (message.type !== "") {
|
|
5298
|
-
obj.type = message.type;
|
|
5299
|
-
}
|
|
5300
|
-
if (message.description !== "") {
|
|
5301
|
-
obj.description = message.description;
|
|
5302
|
-
}
|
|
5303
|
-
if (message.sensitive !== false) {
|
|
5304
|
-
obj.sensitive = message.sensitive;
|
|
5305
|
-
}
|
|
5306
|
-
return obj;
|
|
5307
|
-
},
|
|
5308
|
-
create(base) {
|
|
5309
|
-
return RenderOutput.fromPartial(base ?? {});
|
|
5310
|
-
},
|
|
5311
|
-
fromPartial(object) {
|
|
5312
|
-
const message = createBaseRenderOutput();
|
|
5313
|
-
message.name = object.name ?? "";
|
|
5314
|
-
message.type = object.type ?? "";
|
|
5315
|
-
message.description = object.description ?? "";
|
|
5316
|
-
message.sensitive = object.sensitive ?? false;
|
|
5317
|
-
return message;
|
|
5318
|
-
}
|
|
5319
|
-
};
|
|
5320
|
-
function createBaseNodeConfig() {
|
|
5321
|
-
return {
|
|
5322
|
-
instance_id: "",
|
|
5323
|
-
inputs: [],
|
|
5324
|
-
outputs: [],
|
|
5325
|
-
sibling_ids: [],
|
|
5326
|
-
depends_on: [],
|
|
5327
|
-
available_variables: [],
|
|
5328
|
-
providers: {}
|
|
5329
|
-
};
|
|
5330
|
-
}
|
|
5331
|
-
var NodeConfig = {
|
|
5332
|
-
encode(message, writer = new BinaryWriter3()) {
|
|
5333
|
-
if (message.instance_id !== "") {
|
|
5334
|
-
writer.uint32(10).string(message.instance_id);
|
|
5335
|
-
}
|
|
5336
|
-
for (const v of message.inputs) {
|
|
5337
|
-
RenderInput.encode(v, writer.uint32(18).fork()).join();
|
|
5338
|
-
}
|
|
5339
|
-
for (const v of message.outputs) {
|
|
5340
|
-
RenderOutput.encode(v, writer.uint32(26).fork()).join();
|
|
5341
|
-
}
|
|
5342
|
-
for (const v of message.sibling_ids) {
|
|
5343
|
-
writer.uint32(34).string(v);
|
|
5344
|
-
}
|
|
5345
|
-
for (const v of message.depends_on) {
|
|
5346
|
-
writer.uint32(42).string(v);
|
|
5347
|
-
}
|
|
5348
|
-
for (const v of message.available_variables) {
|
|
5349
|
-
VariableRef.encode(v, writer.uint32(50).fork()).join();
|
|
5350
|
-
}
|
|
5351
|
-
globalThis.Object.entries(message.providers).forEach(([key, value]) => {
|
|
5352
|
-
NodeConfig_ProvidersEntry.encode({ key, value }, writer.uint32(58).fork()).join();
|
|
5353
|
-
});
|
|
5354
|
-
return writer;
|
|
5355
|
-
},
|
|
5356
|
-
decode(input, length) {
|
|
5357
|
-
const reader = input instanceof BinaryReader3 ? input : new BinaryReader3(input);
|
|
5358
|
-
const end = length === void 0 ? reader.len : reader.pos + length;
|
|
5359
|
-
const message = createBaseNodeConfig();
|
|
5360
|
-
while (reader.pos < end) {
|
|
5361
|
-
const tag = reader.uint32();
|
|
5362
|
-
switch (tag >>> 3) {
|
|
5363
|
-
case 1: {
|
|
5364
|
-
if (tag !== 10) {
|
|
5365
|
-
break;
|
|
5366
|
-
}
|
|
5367
|
-
message.instance_id = reader.string();
|
|
5368
|
-
continue;
|
|
5369
|
-
}
|
|
5370
|
-
case 2: {
|
|
5371
|
-
if (tag !== 18) {
|
|
5372
|
-
break;
|
|
5373
|
-
}
|
|
5374
|
-
message.inputs.push(RenderInput.decode(reader, reader.uint32()));
|
|
5375
|
-
continue;
|
|
5376
|
-
}
|
|
5377
|
-
case 3: {
|
|
5378
|
-
if (tag !== 26) {
|
|
5379
|
-
break;
|
|
5380
|
-
}
|
|
5381
|
-
message.outputs.push(RenderOutput.decode(reader, reader.uint32()));
|
|
5382
|
-
continue;
|
|
5383
|
-
}
|
|
5384
|
-
case 4: {
|
|
5385
|
-
if (tag !== 34) {
|
|
5386
|
-
break;
|
|
5387
|
-
}
|
|
5388
|
-
message.sibling_ids.push(reader.string());
|
|
5389
|
-
continue;
|
|
5390
|
-
}
|
|
5391
|
-
case 5: {
|
|
5392
|
-
if (tag !== 42) {
|
|
5393
|
-
break;
|
|
5394
|
-
}
|
|
5395
|
-
message.depends_on.push(reader.string());
|
|
5396
|
-
continue;
|
|
5397
|
-
}
|
|
5398
|
-
case 6: {
|
|
5399
|
-
if (tag !== 50) {
|
|
5400
|
-
break;
|
|
5401
|
-
}
|
|
5402
|
-
message.available_variables.push(VariableRef.decode(reader, reader.uint32()));
|
|
5403
|
-
continue;
|
|
5404
|
-
}
|
|
5405
|
-
case 7: {
|
|
5406
|
-
if (tag !== 58) {
|
|
5407
|
-
break;
|
|
5408
|
-
}
|
|
5409
|
-
const entry7 = NodeConfig_ProvidersEntry.decode(reader, reader.uint32());
|
|
5410
|
-
if (entry7.value !== void 0) {
|
|
5411
|
-
message.providers[entry7.key] = entry7.value;
|
|
5412
|
-
}
|
|
5413
|
-
continue;
|
|
5414
|
-
}
|
|
5415
|
-
}
|
|
5416
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
5417
|
-
break;
|
|
5418
|
-
}
|
|
5419
|
-
reader.skip(tag & 7);
|
|
5420
|
-
}
|
|
5421
|
-
return message;
|
|
5422
|
-
},
|
|
5423
|
-
fromJSON(object) {
|
|
5424
|
-
return {
|
|
5425
|
-
instance_id: isSet3(object.instanceId) ? globalThis.String(object.instanceId) : isSet3(object.instance_id) ? globalThis.String(object.instance_id) : "",
|
|
5426
|
-
inputs: globalThis.Array.isArray(object?.inputs) ? object.inputs.map((e) => RenderInput.fromJSON(e)) : [],
|
|
5427
|
-
outputs: globalThis.Array.isArray(object?.outputs) ? object.outputs.map((e) => RenderOutput.fromJSON(e)) : [],
|
|
5428
|
-
sibling_ids: globalThis.Array.isArray(object?.siblingIds) ? object.siblingIds.map((e) => globalThis.String(e)) : globalThis.Array.isArray(object?.sibling_ids) ? object.sibling_ids.map((e) => globalThis.String(e)) : [],
|
|
5429
|
-
depends_on: globalThis.Array.isArray(object?.dependsOn) ? object.dependsOn.map((e) => globalThis.String(e)) : globalThis.Array.isArray(object?.depends_on) ? object.depends_on.map((e) => globalThis.String(e)) : [],
|
|
5430
|
-
available_variables: globalThis.Array.isArray(object?.availableVariables) ? object.availableVariables.map((e) => VariableRef.fromJSON(e)) : globalThis.Array.isArray(object?.available_variables) ? object.available_variables.map((e) => VariableRef.fromJSON(e)) : [],
|
|
5431
|
-
providers: isObject3(object.providers) ? globalThis.Object.entries(object.providers).reduce(
|
|
5432
|
-
(acc, [key, value]) => {
|
|
5433
|
-
acc[key] = globalThis.String(value);
|
|
5434
|
-
return acc;
|
|
5435
|
-
},
|
|
5436
|
-
{}
|
|
5437
|
-
) : {}
|
|
5438
|
-
};
|
|
5439
|
-
},
|
|
5440
|
-
toJSON(message) {
|
|
5441
|
-
const obj = {};
|
|
5442
|
-
if (message.instance_id !== "") {
|
|
5443
|
-
obj.instanceId = message.instance_id;
|
|
5444
|
-
}
|
|
5445
|
-
if (message.inputs?.length) {
|
|
5446
|
-
obj.inputs = message.inputs.map((e) => RenderInput.toJSON(e));
|
|
5447
|
-
}
|
|
5448
|
-
if (message.outputs?.length) {
|
|
5449
|
-
obj.outputs = message.outputs.map((e) => RenderOutput.toJSON(e));
|
|
5450
|
-
}
|
|
5451
|
-
if (message.sibling_ids?.length) {
|
|
5452
|
-
obj.siblingIds = message.sibling_ids;
|
|
5453
|
-
}
|
|
5454
|
-
if (message.depends_on?.length) {
|
|
5455
|
-
obj.dependsOn = message.depends_on;
|
|
5456
|
-
}
|
|
5457
|
-
if (message.available_variables?.length) {
|
|
5458
|
-
obj.availableVariables = message.available_variables.map((e) => VariableRef.toJSON(e));
|
|
5459
|
-
}
|
|
5460
|
-
if (message.providers) {
|
|
5461
|
-
const entries = globalThis.Object.entries(message.providers);
|
|
5462
|
-
if (entries.length > 0) {
|
|
5463
|
-
obj.providers = {};
|
|
5464
|
-
entries.forEach(([k, v]) => {
|
|
5465
|
-
obj.providers[k] = v;
|
|
5466
|
-
});
|
|
5467
|
-
}
|
|
5468
|
-
}
|
|
5469
|
-
return obj;
|
|
5470
|
-
},
|
|
5471
|
-
create(base) {
|
|
5472
|
-
return NodeConfig.fromPartial(base ?? {});
|
|
5473
|
-
},
|
|
5474
|
-
fromPartial(object) {
|
|
5475
|
-
const message = createBaseNodeConfig();
|
|
5476
|
-
message.instance_id = object.instance_id ?? "";
|
|
5477
|
-
message.inputs = object.inputs?.map((e) => RenderInput.fromPartial(e)) || [];
|
|
5478
|
-
message.outputs = object.outputs?.map((e) => RenderOutput.fromPartial(e)) || [];
|
|
5479
|
-
message.sibling_ids = object.sibling_ids?.map((e) => e) || [];
|
|
5480
|
-
message.depends_on = object.depends_on?.map((e) => e) || [];
|
|
5481
|
-
message.available_variables = object.available_variables?.map((e) => VariableRef.fromPartial(e)) || [];
|
|
5482
|
-
message.providers = globalThis.Object.entries(object.providers ?? {}).reduce(
|
|
5483
|
-
(acc, [key, value]) => {
|
|
5484
|
-
if (value !== void 0) {
|
|
5485
|
-
acc[key] = globalThis.String(value);
|
|
5486
|
-
}
|
|
5487
|
-
return acc;
|
|
5488
|
-
},
|
|
5489
|
-
{}
|
|
5490
|
-
);
|
|
5491
|
-
return message;
|
|
5492
|
-
}
|
|
5493
|
-
};
|
|
5494
|
-
function createBaseNodeConfig_ProvidersEntry() {
|
|
5495
|
-
return { key: "", value: "" };
|
|
5496
|
-
}
|
|
5497
|
-
var NodeConfig_ProvidersEntry = {
|
|
5498
|
-
encode(message, writer = new BinaryWriter3()) {
|
|
5499
|
-
if (message.key !== "") {
|
|
5500
|
-
writer.uint32(10).string(message.key);
|
|
5501
|
-
}
|
|
5502
|
-
if (message.value !== "") {
|
|
5503
|
-
writer.uint32(18).string(message.value);
|
|
5504
|
-
}
|
|
5505
|
-
return writer;
|
|
5506
|
-
},
|
|
5507
|
-
decode(input, length) {
|
|
5508
|
-
const reader = input instanceof BinaryReader3 ? input : new BinaryReader3(input);
|
|
5509
|
-
const end = length === void 0 ? reader.len : reader.pos + length;
|
|
5510
|
-
const message = createBaseNodeConfig_ProvidersEntry();
|
|
5511
|
-
while (reader.pos < end) {
|
|
5512
|
-
const tag = reader.uint32();
|
|
5513
|
-
switch (tag >>> 3) {
|
|
5514
|
-
case 1: {
|
|
5515
|
-
if (tag !== 10) {
|
|
5516
|
-
break;
|
|
5517
|
-
}
|
|
5518
|
-
message.key = reader.string();
|
|
5519
|
-
continue;
|
|
5520
|
-
}
|
|
5521
|
-
case 2: {
|
|
5522
|
-
if (tag !== 18) {
|
|
5523
|
-
break;
|
|
5524
|
-
}
|
|
5525
|
-
message.value = reader.string();
|
|
5526
|
-
continue;
|
|
5527
|
-
}
|
|
5528
|
-
}
|
|
5529
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
5530
|
-
break;
|
|
5531
|
-
}
|
|
5532
|
-
reader.skip(tag & 7);
|
|
5533
|
-
}
|
|
5534
|
-
return message;
|
|
5535
|
-
},
|
|
5536
|
-
fromJSON(object) {
|
|
5537
|
-
return {
|
|
5538
|
-
key: isSet3(object.key) ? globalThis.String(object.key) : "",
|
|
5539
|
-
value: isSet3(object.value) ? globalThis.String(object.value) : ""
|
|
5540
|
-
};
|
|
5541
|
-
},
|
|
5542
|
-
toJSON(message) {
|
|
5543
|
-
const obj = {};
|
|
5544
|
-
if (message.key !== "") {
|
|
5545
|
-
obj.key = message.key;
|
|
5546
|
-
}
|
|
5547
|
-
if (message.value !== "") {
|
|
5548
|
-
obj.value = message.value;
|
|
5549
|
-
}
|
|
5550
|
-
return obj;
|
|
5551
|
-
},
|
|
5552
|
-
create(base) {
|
|
5553
|
-
return NodeConfig_ProvidersEntry.fromPartial(base ?? {});
|
|
5554
|
-
},
|
|
5555
|
-
fromPartial(object) {
|
|
5556
|
-
const message = createBaseNodeConfig_ProvidersEntry();
|
|
5557
|
-
message.key = object.key ?? "";
|
|
5558
|
-
message.value = object.value ?? "";
|
|
5559
|
-
return message;
|
|
5560
|
-
}
|
|
5561
|
-
};
|
|
5562
|
-
function createBaseVariableRef() {
|
|
5563
|
-
return { name: "", type: "" };
|
|
5564
|
-
}
|
|
5565
|
-
var VariableRef = {
|
|
5566
|
-
encode(message, writer = new BinaryWriter3()) {
|
|
5567
|
-
if (message.name !== "") {
|
|
5568
|
-
writer.uint32(10).string(message.name);
|
|
5569
|
-
}
|
|
5570
|
-
if (message.type !== "") {
|
|
5571
|
-
writer.uint32(18).string(message.type);
|
|
5572
|
-
}
|
|
5573
|
-
return writer;
|
|
5574
|
-
},
|
|
5575
|
-
decode(input, length) {
|
|
5576
|
-
const reader = input instanceof BinaryReader3 ? input : new BinaryReader3(input);
|
|
5577
|
-
const end = length === void 0 ? reader.len : reader.pos + length;
|
|
5578
|
-
const message = createBaseVariableRef();
|
|
5579
|
-
while (reader.pos < end) {
|
|
5580
|
-
const tag = reader.uint32();
|
|
5581
|
-
switch (tag >>> 3) {
|
|
5582
|
-
case 1: {
|
|
5583
|
-
if (tag !== 10) {
|
|
5584
|
-
break;
|
|
5585
|
-
}
|
|
5586
|
-
message.name = reader.string();
|
|
5587
|
-
continue;
|
|
5588
|
-
}
|
|
5589
|
-
case 2: {
|
|
5590
|
-
if (tag !== 18) {
|
|
5591
|
-
break;
|
|
5592
|
-
}
|
|
5593
|
-
message.type = reader.string();
|
|
5594
|
-
continue;
|
|
5595
|
-
}
|
|
5596
|
-
}
|
|
5597
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
5598
|
-
break;
|
|
5599
|
-
}
|
|
5600
|
-
reader.skip(tag & 7);
|
|
5601
|
-
}
|
|
5602
|
-
return message;
|
|
5603
|
-
},
|
|
5604
|
-
fromJSON(object) {
|
|
5605
|
-
return {
|
|
5606
|
-
name: isSet3(object.name) ? globalThis.String(object.name) : "",
|
|
5607
|
-
type: isSet3(object.type) ? globalThis.String(object.type) : ""
|
|
5608
|
-
};
|
|
5609
|
-
},
|
|
5610
|
-
toJSON(message) {
|
|
5611
|
-
const obj = {};
|
|
5612
|
-
if (message.name !== "") {
|
|
5613
|
-
obj.name = message.name;
|
|
5614
|
-
}
|
|
5615
|
-
if (message.type !== "") {
|
|
5616
|
-
obj.type = message.type;
|
|
5617
|
-
}
|
|
5618
|
-
return obj;
|
|
5619
|
-
},
|
|
5620
|
-
create(base) {
|
|
5621
|
-
return VariableRef.fromPartial(base ?? {});
|
|
5622
|
-
},
|
|
5623
|
-
fromPartial(object) {
|
|
5624
|
-
const message = createBaseVariableRef();
|
|
5625
|
-
message.name = object.name ?? "";
|
|
5626
|
-
message.type = object.type ?? "";
|
|
5627
|
-
return message;
|
|
5628
|
-
}
|
|
5629
|
-
};
|
|
5630
|
-
function createBaseEdgeConfig() {
|
|
5631
|
-
return { source_instance: "", target_instance: "", source_outputs: [], target_unbound_inputs: [] };
|
|
5632
|
-
}
|
|
5633
|
-
var EdgeConfig = {
|
|
5634
|
-
encode(message, writer = new BinaryWriter3()) {
|
|
5635
|
-
if (message.source_instance !== "") {
|
|
5636
|
-
writer.uint32(10).string(message.source_instance);
|
|
5637
|
-
}
|
|
5638
|
-
if (message.target_instance !== "") {
|
|
5639
|
-
writer.uint32(18).string(message.target_instance);
|
|
5640
|
-
}
|
|
5641
|
-
for (const v of message.source_outputs) {
|
|
5642
|
-
RenderOutput.encode(v, writer.uint32(26).fork()).join();
|
|
5643
|
-
}
|
|
5644
|
-
for (const v of message.target_unbound_inputs) {
|
|
5645
|
-
RenderInput.encode(v, writer.uint32(34).fork()).join();
|
|
5646
|
-
}
|
|
5647
|
-
return writer;
|
|
5648
|
-
},
|
|
5649
|
-
decode(input, length) {
|
|
5650
|
-
const reader = input instanceof BinaryReader3 ? input : new BinaryReader3(input);
|
|
5651
|
-
const end = length === void 0 ? reader.len : reader.pos + length;
|
|
5652
|
-
const message = createBaseEdgeConfig();
|
|
5653
|
-
while (reader.pos < end) {
|
|
5654
|
-
const tag = reader.uint32();
|
|
5655
|
-
switch (tag >>> 3) {
|
|
5656
|
-
case 1: {
|
|
5657
|
-
if (tag !== 10) {
|
|
5658
|
-
break;
|
|
5659
|
-
}
|
|
5660
|
-
message.source_instance = reader.string();
|
|
5661
|
-
continue;
|
|
5662
|
-
}
|
|
5663
|
-
case 2: {
|
|
5664
|
-
if (tag !== 18) {
|
|
5665
|
-
break;
|
|
5666
|
-
}
|
|
5667
|
-
message.target_instance = reader.string();
|
|
5668
|
-
continue;
|
|
5669
|
-
}
|
|
5670
|
-
case 3: {
|
|
5671
|
-
if (tag !== 26) {
|
|
5672
|
-
break;
|
|
5673
|
-
}
|
|
5674
|
-
message.source_outputs.push(RenderOutput.decode(reader, reader.uint32()));
|
|
5675
|
-
continue;
|
|
5676
|
-
}
|
|
5677
|
-
case 4: {
|
|
5678
|
-
if (tag !== 34) {
|
|
5679
|
-
break;
|
|
5680
|
-
}
|
|
5681
|
-
message.target_unbound_inputs.push(RenderInput.decode(reader, reader.uint32()));
|
|
5682
|
-
continue;
|
|
5683
|
-
}
|
|
5684
|
-
}
|
|
5685
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
5686
|
-
break;
|
|
5687
|
-
}
|
|
5688
|
-
reader.skip(tag & 7);
|
|
5689
|
-
}
|
|
5690
|
-
return message;
|
|
5691
|
-
},
|
|
5692
|
-
fromJSON(object) {
|
|
5693
|
-
return {
|
|
5694
|
-
source_instance: isSet3(object.sourceInstance) ? globalThis.String(object.sourceInstance) : isSet3(object.source_instance) ? globalThis.String(object.source_instance) : "",
|
|
5695
|
-
target_instance: isSet3(object.targetInstance) ? globalThis.String(object.targetInstance) : isSet3(object.target_instance) ? globalThis.String(object.target_instance) : "",
|
|
5696
|
-
source_outputs: globalThis.Array.isArray(object?.sourceOutputs) ? object.sourceOutputs.map((e) => RenderOutput.fromJSON(e)) : globalThis.Array.isArray(object?.source_outputs) ? object.source_outputs.map((e) => RenderOutput.fromJSON(e)) : [],
|
|
5697
|
-
target_unbound_inputs: globalThis.Array.isArray(object?.targetUnboundInputs) ? object.targetUnboundInputs.map((e) => RenderInput.fromJSON(e)) : globalThis.Array.isArray(object?.target_unbound_inputs) ? object.target_unbound_inputs.map((e) => RenderInput.fromJSON(e)) : []
|
|
5698
|
-
};
|
|
5699
|
-
},
|
|
5700
|
-
toJSON(message) {
|
|
5701
|
-
const obj = {};
|
|
5702
|
-
if (message.source_instance !== "") {
|
|
5703
|
-
obj.sourceInstance = message.source_instance;
|
|
5704
|
-
}
|
|
5705
|
-
if (message.target_instance !== "") {
|
|
5706
|
-
obj.targetInstance = message.target_instance;
|
|
5707
|
-
}
|
|
5708
|
-
if (message.source_outputs?.length) {
|
|
5709
|
-
obj.sourceOutputs = message.source_outputs.map((e) => RenderOutput.toJSON(e));
|
|
5710
|
-
}
|
|
5711
|
-
if (message.target_unbound_inputs?.length) {
|
|
5712
|
-
obj.targetUnboundInputs = message.target_unbound_inputs.map((e) => RenderInput.toJSON(e));
|
|
5713
|
-
}
|
|
5714
|
-
return obj;
|
|
5715
|
-
},
|
|
5716
|
-
create(base) {
|
|
5717
|
-
return EdgeConfig.fromPartial(base ?? {});
|
|
5718
|
-
},
|
|
5719
|
-
fromPartial(object) {
|
|
5720
|
-
const message = createBaseEdgeConfig();
|
|
5721
|
-
message.source_instance = object.source_instance ?? "";
|
|
5722
|
-
message.target_instance = object.target_instance ?? "";
|
|
5723
|
-
message.source_outputs = object.source_outputs?.map((e) => RenderOutput.fromPartial(e)) || [];
|
|
5724
|
-
message.target_unbound_inputs = object.target_unbound_inputs?.map((e) => RenderInput.fromPartial(e)) || [];
|
|
5725
|
-
return message;
|
|
5726
|
-
}
|
|
5727
|
-
};
|
|
5728
|
-
function createBaseSettingsConfig() {
|
|
5729
|
-
return {
|
|
5730
|
-
terraform: void 0,
|
|
5731
|
-
providers: [],
|
|
5732
|
-
locals: [],
|
|
5733
|
-
environments: {},
|
|
5734
|
-
environment_backends: {},
|
|
5735
|
-
variables: [],
|
|
5736
|
-
exports: [],
|
|
5737
|
-
output_defs: []
|
|
5738
|
-
};
|
|
5739
|
-
}
|
|
5740
|
-
var SettingsConfig = {
|
|
5741
|
-
encode(message, writer = new BinaryWriter3()) {
|
|
5742
|
-
if (message.terraform !== void 0) {
|
|
5743
|
-
TerraformView.encode(message.terraform, writer.uint32(10).fork()).join();
|
|
5744
|
-
}
|
|
5745
|
-
for (const v of message.providers) {
|
|
5746
|
-
ProviderView.encode(v, writer.uint32(18).fork()).join();
|
|
5747
|
-
}
|
|
5748
|
-
for (const v of message.locals) {
|
|
5749
|
-
LocalView.encode(v, writer.uint32(26).fork()).join();
|
|
5750
|
-
}
|
|
5751
|
-
globalThis.Object.entries(message.environments).forEach(
|
|
5752
|
-
([key, value]) => {
|
|
5753
|
-
if (value !== void 0) {
|
|
5754
|
-
SettingsConfig_EnvironmentsEntry.encode({ key, value }, writer.uint32(34).fork()).join();
|
|
5755
|
-
}
|
|
5756
|
-
}
|
|
5757
|
-
);
|
|
5758
|
-
globalThis.Object.entries(message.environment_backends).forEach(([key, value]) => {
|
|
5759
|
-
SettingsConfig_EnvironmentBackendsEntry.encode({ key, value }, writer.uint32(42).fork()).join();
|
|
5760
|
-
});
|
|
5761
|
-
for (const v of message.variables) {
|
|
5762
|
-
InputDef2.encode(v, writer.uint32(50).fork()).join();
|
|
5763
|
-
}
|
|
5764
|
-
for (const v of message.exports) {
|
|
5765
|
-
OutputExportEntry.encode(v, writer.uint32(58).fork()).join();
|
|
5766
|
-
}
|
|
5767
|
-
for (const v of message.output_defs) {
|
|
5768
|
-
OutputDef2.encode(v, writer.uint32(66).fork()).join();
|
|
5769
|
-
}
|
|
5770
|
-
return writer;
|
|
5771
|
-
},
|
|
5772
|
-
decode(input, length) {
|
|
5773
|
-
const reader = input instanceof BinaryReader3 ? input : new BinaryReader3(input);
|
|
5774
|
-
const end = length === void 0 ? reader.len : reader.pos + length;
|
|
5775
|
-
const message = createBaseSettingsConfig();
|
|
5776
|
-
while (reader.pos < end) {
|
|
5777
|
-
const tag = reader.uint32();
|
|
5778
|
-
switch (tag >>> 3) {
|
|
5779
|
-
case 1: {
|
|
5780
|
-
if (tag !== 10) {
|
|
5781
|
-
break;
|
|
5782
|
-
}
|
|
5783
|
-
message.terraform = TerraformView.decode(reader, reader.uint32());
|
|
5784
|
-
continue;
|
|
5785
|
-
}
|
|
5786
|
-
case 2: {
|
|
5787
|
-
if (tag !== 18) {
|
|
5788
|
-
break;
|
|
5789
|
-
}
|
|
5790
|
-
message.providers.push(ProviderView.decode(reader, reader.uint32()));
|
|
5791
|
-
continue;
|
|
5792
|
-
}
|
|
5793
|
-
case 3: {
|
|
5794
|
-
if (tag !== 26) {
|
|
5795
|
-
break;
|
|
5796
|
-
}
|
|
5797
|
-
message.locals.push(LocalView.decode(reader, reader.uint32()));
|
|
5798
|
-
continue;
|
|
5799
|
-
}
|
|
5800
|
-
case 4: {
|
|
5801
|
-
if (tag !== 34) {
|
|
5802
|
-
break;
|
|
5803
|
-
}
|
|
5804
|
-
const entry4 = SettingsConfig_EnvironmentsEntry.decode(reader, reader.uint32());
|
|
5805
|
-
if (entry4.value !== void 0) {
|
|
5806
|
-
message.environments[entry4.key] = entry4.value;
|
|
5807
|
-
}
|
|
5808
|
-
continue;
|
|
5809
|
-
}
|
|
5810
|
-
case 5: {
|
|
5811
|
-
if (tag !== 42) {
|
|
5812
|
-
break;
|
|
5813
|
-
}
|
|
5814
|
-
const entry5 = SettingsConfig_EnvironmentBackendsEntry.decode(reader, reader.uint32());
|
|
5815
|
-
if (entry5.value !== void 0) {
|
|
5816
|
-
message.environment_backends[entry5.key] = entry5.value;
|
|
5817
|
-
}
|
|
5818
|
-
continue;
|
|
5819
|
-
}
|
|
5820
|
-
case 6: {
|
|
5821
|
-
if (tag !== 50) {
|
|
5822
|
-
break;
|
|
5823
|
-
}
|
|
5824
|
-
message.variables.push(InputDef2.decode(reader, reader.uint32()));
|
|
5825
|
-
continue;
|
|
5826
|
-
}
|
|
5827
|
-
case 7: {
|
|
5828
|
-
if (tag !== 58) {
|
|
5829
|
-
break;
|
|
5830
|
-
}
|
|
5831
|
-
message.exports.push(OutputExportEntry.decode(reader, reader.uint32()));
|
|
5832
|
-
continue;
|
|
5833
|
-
}
|
|
5834
|
-
case 8: {
|
|
5835
|
-
if (tag !== 66) {
|
|
5836
|
-
break;
|
|
5837
|
-
}
|
|
5838
|
-
message.output_defs.push(OutputDef2.decode(reader, reader.uint32()));
|
|
5839
|
-
continue;
|
|
5840
|
-
}
|
|
5841
|
-
}
|
|
5842
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
5843
|
-
break;
|
|
5844
|
-
}
|
|
5845
|
-
reader.skip(tag & 7);
|
|
5846
|
-
}
|
|
5847
|
-
return message;
|
|
5848
|
-
},
|
|
5849
|
-
fromJSON(object) {
|
|
5850
|
-
return {
|
|
5851
|
-
terraform: isSet3(object.terraform) ? TerraformView.fromJSON(object.terraform) : void 0,
|
|
5852
|
-
providers: globalThis.Array.isArray(object?.providers) ? object.providers.map((e) => ProviderView.fromJSON(e)) : [],
|
|
5853
|
-
locals: globalThis.Array.isArray(object?.locals) ? object.locals.map((e) => LocalView.fromJSON(e)) : [],
|
|
5854
|
-
environments: isObject3(object.environments) ? globalThis.Object.entries(object.environments).reduce(
|
|
5855
|
-
(acc, [key, value]) => {
|
|
5856
|
-
acc[key] = value;
|
|
5857
|
-
return acc;
|
|
5858
|
-
},
|
|
5859
|
-
{}
|
|
5860
|
-
) : {},
|
|
5861
|
-
environment_backends: isObject3(object.environmentBackends) ? globalThis.Object.entries(object.environmentBackends).reduce(
|
|
5862
|
-
(acc, [key, value]) => {
|
|
5863
|
-
acc[key] = BackendView.fromJSON(value);
|
|
5864
|
-
return acc;
|
|
5865
|
-
},
|
|
5866
|
-
{}
|
|
5867
|
-
) : isObject3(object.environment_backends) ? globalThis.Object.entries(object.environment_backends).reduce(
|
|
5868
|
-
(acc, [key, value]) => {
|
|
5869
|
-
acc[key] = BackendView.fromJSON(value);
|
|
5870
|
-
return acc;
|
|
5871
|
-
},
|
|
5872
|
-
{}
|
|
5873
|
-
) : {},
|
|
5874
|
-
variables: globalThis.Array.isArray(object?.variables) ? object.variables.map((e) => InputDef2.fromJSON(e)) : [],
|
|
5875
|
-
exports: globalThis.Array.isArray(object?.exports) ? object.exports.map((e) => OutputExportEntry.fromJSON(e)) : [],
|
|
5876
|
-
output_defs: globalThis.Array.isArray(object?.outputDefs) ? object.outputDefs.map((e) => OutputDef2.fromJSON(e)) : globalThis.Array.isArray(object?.output_defs) ? object.output_defs.map((e) => OutputDef2.fromJSON(e)) : []
|
|
5877
|
-
};
|
|
5878
|
-
},
|
|
5879
|
-
toJSON(message) {
|
|
5880
|
-
const obj = {};
|
|
5881
|
-
if (message.terraform !== void 0) {
|
|
5882
|
-
obj.terraform = TerraformView.toJSON(message.terraform);
|
|
5883
|
-
}
|
|
5884
|
-
if (message.providers?.length) {
|
|
5885
|
-
obj.providers = message.providers.map((e) => ProviderView.toJSON(e));
|
|
5886
|
-
}
|
|
5887
|
-
if (message.locals?.length) {
|
|
5888
|
-
obj.locals = message.locals.map((e) => LocalView.toJSON(e));
|
|
5889
|
-
}
|
|
5890
|
-
if (message.environments) {
|
|
5891
|
-
const entries = globalThis.Object.entries(message.environments);
|
|
5892
|
-
if (entries.length > 0) {
|
|
5893
|
-
obj.environments = {};
|
|
5894
|
-
entries.forEach(([k, v]) => {
|
|
5895
|
-
obj.environments[k] = v;
|
|
5896
|
-
});
|
|
5897
|
-
}
|
|
5898
|
-
}
|
|
5899
|
-
if (message.environment_backends) {
|
|
5900
|
-
const entries = globalThis.Object.entries(message.environment_backends);
|
|
5901
|
-
if (entries.length > 0) {
|
|
5902
|
-
obj.environmentBackends = {};
|
|
5903
|
-
entries.forEach(([k, v]) => {
|
|
5904
|
-
obj.environmentBackends[k] = BackendView.toJSON(v);
|
|
5905
|
-
});
|
|
5906
|
-
}
|
|
5907
|
-
}
|
|
5908
|
-
if (message.variables?.length) {
|
|
5909
|
-
obj.variables = message.variables.map((e) => InputDef2.toJSON(e));
|
|
5910
|
-
}
|
|
5911
|
-
if (message.exports?.length) {
|
|
5912
|
-
obj.exports = message.exports.map((e) => OutputExportEntry.toJSON(e));
|
|
5913
|
-
}
|
|
5914
|
-
if (message.output_defs?.length) {
|
|
5915
|
-
obj.outputDefs = message.output_defs.map((e) => OutputDef2.toJSON(e));
|
|
5916
|
-
}
|
|
5917
|
-
return obj;
|
|
5918
|
-
},
|
|
5919
|
-
create(base) {
|
|
5920
|
-
return SettingsConfig.fromPartial(base ?? {});
|
|
5921
|
-
},
|
|
5922
|
-
fromPartial(object) {
|
|
5923
|
-
const message = createBaseSettingsConfig();
|
|
5924
|
-
message.terraform = object.terraform !== void 0 && object.terraform !== null ? TerraformView.fromPartial(object.terraform) : void 0;
|
|
5925
|
-
message.providers = object.providers?.map((e) => ProviderView.fromPartial(e)) || [];
|
|
5926
|
-
message.locals = object.locals?.map((e) => LocalView.fromPartial(e)) || [];
|
|
5927
|
-
message.environments = globalThis.Object.entries(object.environments ?? {}).reduce(
|
|
5928
|
-
(acc, [key, value]) => {
|
|
5929
|
-
if (value !== void 0) {
|
|
5930
|
-
acc[key] = value;
|
|
5931
|
-
}
|
|
5932
|
-
return acc;
|
|
5933
|
-
},
|
|
5934
|
-
{}
|
|
5935
|
-
);
|
|
5936
|
-
message.environment_backends = globalThis.Object.entries(object.environment_backends ?? {}).reduce(
|
|
5937
|
-
(acc, [key, value]) => {
|
|
5938
|
-
if (value !== void 0) {
|
|
5939
|
-
acc[key] = BackendView.fromPartial(value);
|
|
5940
|
-
}
|
|
5941
|
-
return acc;
|
|
5942
|
-
},
|
|
5943
|
-
{}
|
|
5944
|
-
);
|
|
5945
|
-
message.variables = object.variables?.map((e) => InputDef2.fromPartial(e)) || [];
|
|
5946
|
-
message.exports = object.exports?.map((e) => OutputExportEntry.fromPartial(e)) || [];
|
|
5947
|
-
message.output_defs = object.output_defs?.map((e) => OutputDef2.fromPartial(e)) || [];
|
|
5948
|
-
return message;
|
|
5949
|
-
}
|
|
5950
|
-
};
|
|
5951
|
-
function createBaseSettingsConfig_EnvironmentsEntry() {
|
|
5952
|
-
return { key: "", value: void 0 };
|
|
5953
|
-
}
|
|
5954
|
-
var SettingsConfig_EnvironmentsEntry = {
|
|
5955
|
-
encode(message, writer = new BinaryWriter3()) {
|
|
5956
|
-
if (message.key !== "") {
|
|
5957
|
-
writer.uint32(10).string(message.key);
|
|
5958
|
-
}
|
|
5959
|
-
if (message.value !== void 0) {
|
|
5960
|
-
Struct.encode(Struct.wrap(message.value), writer.uint32(18).fork()).join();
|
|
5961
|
-
}
|
|
5962
|
-
return writer;
|
|
5963
|
-
},
|
|
5964
|
-
decode(input, length) {
|
|
5965
|
-
const reader = input instanceof BinaryReader3 ? input : new BinaryReader3(input);
|
|
5966
|
-
const end = length === void 0 ? reader.len : reader.pos + length;
|
|
5967
|
-
const message = createBaseSettingsConfig_EnvironmentsEntry();
|
|
5968
|
-
while (reader.pos < end) {
|
|
5969
|
-
const tag = reader.uint32();
|
|
5970
|
-
switch (tag >>> 3) {
|
|
5971
|
-
case 1: {
|
|
5972
|
-
if (tag !== 10) {
|
|
5973
|
-
break;
|
|
5974
|
-
}
|
|
5975
|
-
message.key = reader.string();
|
|
5976
|
-
continue;
|
|
5977
|
-
}
|
|
5978
|
-
case 2: {
|
|
5979
|
-
if (tag !== 18) {
|
|
5980
|
-
break;
|
|
5981
|
-
}
|
|
5982
|
-
message.value = Struct.unwrap(Struct.decode(reader, reader.uint32()));
|
|
5983
|
-
continue;
|
|
5984
|
-
}
|
|
5985
|
-
}
|
|
5986
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
5987
|
-
break;
|
|
5988
|
-
}
|
|
5989
|
-
reader.skip(tag & 7);
|
|
5990
|
-
}
|
|
5991
|
-
return message;
|
|
5992
|
-
},
|
|
5993
|
-
fromJSON(object) {
|
|
5994
|
-
return {
|
|
5995
|
-
key: isSet3(object.key) ? globalThis.String(object.key) : "",
|
|
5996
|
-
value: isObject3(object.value) ? object.value : void 0
|
|
5997
|
-
};
|
|
5998
|
-
},
|
|
5999
|
-
toJSON(message) {
|
|
6000
|
-
const obj = {};
|
|
6001
|
-
if (message.key !== "") {
|
|
6002
|
-
obj.key = message.key;
|
|
6003
|
-
}
|
|
6004
|
-
if (message.value !== void 0) {
|
|
6005
|
-
obj.value = message.value;
|
|
6006
|
-
}
|
|
6007
|
-
return obj;
|
|
6008
|
-
},
|
|
6009
|
-
create(base) {
|
|
6010
|
-
return SettingsConfig_EnvironmentsEntry.fromPartial(base ?? {});
|
|
6011
|
-
},
|
|
6012
|
-
fromPartial(object) {
|
|
6013
|
-
const message = createBaseSettingsConfig_EnvironmentsEntry();
|
|
6014
|
-
message.key = object.key ?? "";
|
|
6015
|
-
message.value = object.value ?? void 0;
|
|
6016
|
-
return message;
|
|
6017
|
-
}
|
|
6018
|
-
};
|
|
6019
|
-
function createBaseSettingsConfig_EnvironmentBackendsEntry() {
|
|
6020
|
-
return { key: "", value: void 0 };
|
|
6021
|
-
}
|
|
6022
|
-
var SettingsConfig_EnvironmentBackendsEntry = {
|
|
6023
|
-
encode(message, writer = new BinaryWriter3()) {
|
|
6024
|
-
if (message.key !== "") {
|
|
6025
|
-
writer.uint32(10).string(message.key);
|
|
6026
|
-
}
|
|
6027
|
-
if (message.value !== void 0) {
|
|
6028
|
-
BackendView.encode(message.value, writer.uint32(18).fork()).join();
|
|
6029
|
-
}
|
|
6030
|
-
return writer;
|
|
6031
|
-
},
|
|
6032
|
-
decode(input, length) {
|
|
6033
|
-
const reader = input instanceof BinaryReader3 ? input : new BinaryReader3(input);
|
|
6034
|
-
const end = length === void 0 ? reader.len : reader.pos + length;
|
|
6035
|
-
const message = createBaseSettingsConfig_EnvironmentBackendsEntry();
|
|
6036
|
-
while (reader.pos < end) {
|
|
6037
|
-
const tag = reader.uint32();
|
|
6038
|
-
switch (tag >>> 3) {
|
|
6039
|
-
case 1: {
|
|
6040
|
-
if (tag !== 10) {
|
|
6041
|
-
break;
|
|
6042
|
-
}
|
|
6043
|
-
message.key = reader.string();
|
|
6044
|
-
continue;
|
|
6045
|
-
}
|
|
6046
|
-
case 2: {
|
|
6047
|
-
if (tag !== 18) {
|
|
6048
|
-
break;
|
|
6049
|
-
}
|
|
6050
|
-
message.value = BackendView.decode(reader, reader.uint32());
|
|
6051
|
-
continue;
|
|
6052
|
-
}
|
|
6053
|
-
}
|
|
6054
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
6055
|
-
break;
|
|
6056
|
-
}
|
|
6057
|
-
reader.skip(tag & 7);
|
|
6058
|
-
}
|
|
6059
|
-
return message;
|
|
6060
|
-
},
|
|
6061
|
-
fromJSON(object) {
|
|
6062
|
-
return {
|
|
6063
|
-
key: isSet3(object.key) ? globalThis.String(object.key) : "",
|
|
6064
|
-
value: isSet3(object.value) ? BackendView.fromJSON(object.value) : void 0
|
|
6065
|
-
};
|
|
6066
|
-
},
|
|
6067
|
-
toJSON(message) {
|
|
6068
|
-
const obj = {};
|
|
6069
|
-
if (message.key !== "") {
|
|
6070
|
-
obj.key = message.key;
|
|
6071
|
-
}
|
|
6072
|
-
if (message.value !== void 0) {
|
|
6073
|
-
obj.value = BackendView.toJSON(message.value);
|
|
6074
|
-
}
|
|
6075
|
-
return obj;
|
|
6076
|
-
},
|
|
6077
|
-
create(base) {
|
|
6078
|
-
return SettingsConfig_EnvironmentBackendsEntry.fromPartial(base ?? {});
|
|
6079
|
-
},
|
|
6080
|
-
fromPartial(object) {
|
|
6081
|
-
const message = createBaseSettingsConfig_EnvironmentBackendsEntry();
|
|
6082
|
-
message.key = object.key ?? "";
|
|
6083
|
-
message.value = object.value !== void 0 && object.value !== null ? BackendView.fromPartial(object.value) : void 0;
|
|
6084
|
-
return message;
|
|
6085
|
-
}
|
|
6086
|
-
};
|
|
6087
|
-
function createBaseTerraformView() {
|
|
6088
|
-
return { required_version: "", required_providers: [], backend: void 0 };
|
|
6089
|
-
}
|
|
6090
|
-
var TerraformView = {
|
|
6091
|
-
encode(message, writer = new BinaryWriter3()) {
|
|
6092
|
-
if (message.required_version !== "") {
|
|
6093
|
-
writer.uint32(10).string(message.required_version);
|
|
6094
|
-
}
|
|
6095
|
-
for (const v of message.required_providers) {
|
|
6096
|
-
ProviderReqView.encode(v, writer.uint32(18).fork()).join();
|
|
6097
|
-
}
|
|
6098
|
-
if (message.backend !== void 0) {
|
|
6099
|
-
BackendView.encode(message.backend, writer.uint32(26).fork()).join();
|
|
6100
|
-
}
|
|
6101
|
-
return writer;
|
|
6102
|
-
},
|
|
6103
|
-
decode(input, length) {
|
|
6104
|
-
const reader = input instanceof BinaryReader3 ? input : new BinaryReader3(input);
|
|
6105
|
-
const end = length === void 0 ? reader.len : reader.pos + length;
|
|
6106
|
-
const message = createBaseTerraformView();
|
|
6107
|
-
while (reader.pos < end) {
|
|
6108
|
-
const tag = reader.uint32();
|
|
6109
|
-
switch (tag >>> 3) {
|
|
6110
|
-
case 1: {
|
|
6111
|
-
if (tag !== 10) {
|
|
6112
|
-
break;
|
|
6113
|
-
}
|
|
6114
|
-
message.required_version = reader.string();
|
|
6115
|
-
continue;
|
|
6116
|
-
}
|
|
6117
|
-
case 2: {
|
|
6118
|
-
if (tag !== 18) {
|
|
6119
|
-
break;
|
|
6120
|
-
}
|
|
6121
|
-
message.required_providers.push(ProviderReqView.decode(reader, reader.uint32()));
|
|
6122
|
-
continue;
|
|
6123
|
-
}
|
|
6124
|
-
case 3: {
|
|
6125
|
-
if (tag !== 26) {
|
|
6126
|
-
break;
|
|
6127
|
-
}
|
|
6128
|
-
message.backend = BackendView.decode(reader, reader.uint32());
|
|
6129
|
-
continue;
|
|
6130
|
-
}
|
|
6131
|
-
}
|
|
6132
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
6133
|
-
break;
|
|
6134
|
-
}
|
|
6135
|
-
reader.skip(tag & 7);
|
|
6136
|
-
}
|
|
6137
|
-
return message;
|
|
6138
|
-
},
|
|
6139
|
-
fromJSON(object) {
|
|
6140
|
-
return {
|
|
6141
|
-
required_version: isSet3(object.requiredVersion) ? globalThis.String(object.requiredVersion) : isSet3(object.required_version) ? globalThis.String(object.required_version) : "",
|
|
6142
|
-
required_providers: globalThis.Array.isArray(object?.requiredProviders) ? object.requiredProviders.map((e) => ProviderReqView.fromJSON(e)) : globalThis.Array.isArray(object?.required_providers) ? object.required_providers.map((e) => ProviderReqView.fromJSON(e)) : [],
|
|
6143
|
-
backend: isSet3(object.backend) ? BackendView.fromJSON(object.backend) : void 0
|
|
6144
|
-
};
|
|
6145
|
-
},
|
|
6146
|
-
toJSON(message) {
|
|
6147
|
-
const obj = {};
|
|
6148
|
-
if (message.required_version !== "") {
|
|
6149
|
-
obj.requiredVersion = message.required_version;
|
|
6150
|
-
}
|
|
6151
|
-
if (message.required_providers?.length) {
|
|
6152
|
-
obj.requiredProviders = message.required_providers.map((e) => ProviderReqView.toJSON(e));
|
|
6153
|
-
}
|
|
6154
|
-
if (message.backend !== void 0) {
|
|
6155
|
-
obj.backend = BackendView.toJSON(message.backend);
|
|
6156
|
-
}
|
|
6157
|
-
return obj;
|
|
6158
|
-
},
|
|
6159
|
-
create(base) {
|
|
6160
|
-
return TerraformView.fromPartial(base ?? {});
|
|
6161
|
-
},
|
|
6162
|
-
fromPartial(object) {
|
|
6163
|
-
const message = createBaseTerraformView();
|
|
6164
|
-
message.required_version = object.required_version ?? "";
|
|
6165
|
-
message.required_providers = object.required_providers?.map((e) => ProviderReqView.fromPartial(e)) || [];
|
|
6166
|
-
message.backend = object.backend !== void 0 && object.backend !== null ? BackendView.fromPartial(object.backend) : void 0;
|
|
6167
|
-
return message;
|
|
6168
|
-
}
|
|
6169
|
-
};
|
|
6170
|
-
function createBaseProviderReqView() {
|
|
6171
|
-
return { name: "", source: "", version: "", configuration_aliases: [] };
|
|
6172
|
-
}
|
|
6173
|
-
var ProviderReqView = {
|
|
6174
|
-
encode(message, writer = new BinaryWriter3()) {
|
|
6175
|
-
if (message.name !== "") {
|
|
6176
|
-
writer.uint32(10).string(message.name);
|
|
6177
|
-
}
|
|
6178
|
-
if (message.source !== "") {
|
|
6179
|
-
writer.uint32(18).string(message.source);
|
|
6180
|
-
}
|
|
6181
|
-
if (message.version !== "") {
|
|
6182
|
-
writer.uint32(26).string(message.version);
|
|
6183
|
-
}
|
|
6184
|
-
for (const v of message.configuration_aliases) {
|
|
6185
|
-
writer.uint32(34).string(v);
|
|
6186
|
-
}
|
|
6187
|
-
return writer;
|
|
6188
|
-
},
|
|
6189
|
-
decode(input, length) {
|
|
6190
|
-
const reader = input instanceof BinaryReader3 ? input : new BinaryReader3(input);
|
|
6191
|
-
const end = length === void 0 ? reader.len : reader.pos + length;
|
|
6192
|
-
const message = createBaseProviderReqView();
|
|
6193
|
-
while (reader.pos < end) {
|
|
6194
|
-
const tag = reader.uint32();
|
|
6195
|
-
switch (tag >>> 3) {
|
|
6196
|
-
case 1: {
|
|
6197
|
-
if (tag !== 10) {
|
|
6198
|
-
break;
|
|
6199
|
-
}
|
|
6200
|
-
message.name = reader.string();
|
|
6201
|
-
continue;
|
|
6202
|
-
}
|
|
6203
|
-
case 2: {
|
|
6204
|
-
if (tag !== 18) {
|
|
6205
|
-
break;
|
|
6206
|
-
}
|
|
6207
|
-
message.source = reader.string();
|
|
6208
|
-
continue;
|
|
6209
|
-
}
|
|
6210
|
-
case 3: {
|
|
6211
|
-
if (tag !== 26) {
|
|
6212
|
-
break;
|
|
6213
|
-
}
|
|
6214
|
-
message.version = reader.string();
|
|
6215
|
-
continue;
|
|
6216
|
-
}
|
|
6217
|
-
case 4: {
|
|
6218
|
-
if (tag !== 34) {
|
|
6219
|
-
break;
|
|
6220
|
-
}
|
|
6221
|
-
message.configuration_aliases.push(reader.string());
|
|
6222
|
-
continue;
|
|
6223
|
-
}
|
|
6224
|
-
}
|
|
6225
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
6226
|
-
break;
|
|
6227
|
-
}
|
|
6228
|
-
reader.skip(tag & 7);
|
|
6229
|
-
}
|
|
6230
|
-
return message;
|
|
6231
|
-
},
|
|
6232
|
-
fromJSON(object) {
|
|
6233
|
-
return {
|
|
6234
|
-
name: isSet3(object.name) ? globalThis.String(object.name) : "",
|
|
6235
|
-
source: isSet3(object.source) ? globalThis.String(object.source) : "",
|
|
6236
|
-
version: isSet3(object.version) ? globalThis.String(object.version) : "",
|
|
6237
|
-
configuration_aliases: globalThis.Array.isArray(object?.configurationAliases) ? object.configurationAliases.map((e) => globalThis.String(e)) : globalThis.Array.isArray(object?.configuration_aliases) ? object.configuration_aliases.map((e) => globalThis.String(e)) : []
|
|
6238
|
-
};
|
|
6239
|
-
},
|
|
6240
|
-
toJSON(message) {
|
|
6241
|
-
const obj = {};
|
|
6242
|
-
if (message.name !== "") {
|
|
6243
|
-
obj.name = message.name;
|
|
6244
|
-
}
|
|
6245
|
-
if (message.source !== "") {
|
|
6246
|
-
obj.source = message.source;
|
|
6247
|
-
}
|
|
6248
|
-
if (message.version !== "") {
|
|
6249
|
-
obj.version = message.version;
|
|
6250
|
-
}
|
|
6251
|
-
if (message.configuration_aliases?.length) {
|
|
6252
|
-
obj.configurationAliases = message.configuration_aliases;
|
|
6253
|
-
}
|
|
6254
|
-
return obj;
|
|
6255
|
-
},
|
|
6256
|
-
create(base) {
|
|
6257
|
-
return ProviderReqView.fromPartial(base ?? {});
|
|
6258
|
-
},
|
|
6259
|
-
fromPartial(object) {
|
|
6260
|
-
const message = createBaseProviderReqView();
|
|
6261
|
-
message.name = object.name ?? "";
|
|
6262
|
-
message.source = object.source ?? "";
|
|
6263
|
-
message.version = object.version ?? "";
|
|
6264
|
-
message.configuration_aliases = object.configuration_aliases?.map((e) => e) || [];
|
|
6265
|
-
return message;
|
|
6266
|
-
}
|
|
6267
|
-
};
|
|
6268
|
-
function createBaseBackendView() {
|
|
6269
|
-
return { type: "", config: {} };
|
|
6270
|
-
}
|
|
6271
|
-
var BackendView = {
|
|
6272
|
-
encode(message, writer = new BinaryWriter3()) {
|
|
6273
|
-
if (message.type !== "") {
|
|
6274
|
-
writer.uint32(10).string(message.type);
|
|
6275
|
-
}
|
|
6276
|
-
globalThis.Object.entries(message.config).forEach(([key, value]) => {
|
|
6277
|
-
if (value !== void 0) {
|
|
6278
|
-
BackendView_ConfigEntry.encode({ key, value }, writer.uint32(18).fork()).join();
|
|
6279
|
-
}
|
|
6280
|
-
});
|
|
6281
|
-
return writer;
|
|
6282
|
-
},
|
|
6283
|
-
decode(input, length) {
|
|
6284
|
-
const reader = input instanceof BinaryReader3 ? input : new BinaryReader3(input);
|
|
6285
|
-
const end = length === void 0 ? reader.len : reader.pos + length;
|
|
6286
|
-
const message = createBaseBackendView();
|
|
6287
|
-
while (reader.pos < end) {
|
|
6288
|
-
const tag = reader.uint32();
|
|
6289
|
-
switch (tag >>> 3) {
|
|
6290
|
-
case 1: {
|
|
6291
|
-
if (tag !== 10) {
|
|
6292
|
-
break;
|
|
6293
|
-
}
|
|
6294
|
-
message.type = reader.string();
|
|
6295
|
-
continue;
|
|
6296
|
-
}
|
|
6297
|
-
case 2: {
|
|
6298
|
-
if (tag !== 18) {
|
|
6299
|
-
break;
|
|
6300
|
-
}
|
|
6301
|
-
const entry2 = BackendView_ConfigEntry.decode(reader, reader.uint32());
|
|
6302
|
-
if (entry2.value !== void 0) {
|
|
6303
|
-
message.config[entry2.key] = entry2.value;
|
|
6304
|
-
}
|
|
6305
|
-
continue;
|
|
6306
|
-
}
|
|
6307
|
-
}
|
|
6308
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
6309
|
-
break;
|
|
6310
|
-
}
|
|
6311
|
-
reader.skip(tag & 7);
|
|
6312
|
-
}
|
|
6313
|
-
return message;
|
|
6314
|
-
},
|
|
6315
|
-
fromJSON(object) {
|
|
6316
|
-
return {
|
|
6317
|
-
type: isSet3(object.type) ? globalThis.String(object.type) : "",
|
|
6318
|
-
config: isObject3(object.config) ? globalThis.Object.entries(object.config).reduce(
|
|
6319
|
-
(acc, [key, value]) => {
|
|
6320
|
-
acc[key] = value;
|
|
6321
|
-
return acc;
|
|
6322
|
-
},
|
|
6323
|
-
{}
|
|
6324
|
-
) : {}
|
|
6325
|
-
};
|
|
6326
|
-
},
|
|
6327
|
-
toJSON(message) {
|
|
6328
|
-
const obj = {};
|
|
6329
|
-
if (message.type !== "") {
|
|
6330
|
-
obj.type = message.type;
|
|
6331
|
-
}
|
|
6332
|
-
if (message.config) {
|
|
6333
|
-
const entries = globalThis.Object.entries(message.config);
|
|
6334
|
-
if (entries.length > 0) {
|
|
6335
|
-
obj.config = {};
|
|
6336
|
-
entries.forEach(([k, v]) => {
|
|
6337
|
-
obj.config[k] = v;
|
|
6338
|
-
});
|
|
6339
|
-
}
|
|
6340
|
-
}
|
|
6341
|
-
return obj;
|
|
6342
|
-
},
|
|
6343
|
-
create(base) {
|
|
6344
|
-
return BackendView.fromPartial(base ?? {});
|
|
6345
|
-
},
|
|
6346
|
-
fromPartial(object) {
|
|
6347
|
-
const message = createBaseBackendView();
|
|
6348
|
-
message.type = object.type ?? "";
|
|
6349
|
-
message.config = globalThis.Object.entries(object.config ?? {}).reduce(
|
|
6350
|
-
(acc, [key, value]) => {
|
|
6351
|
-
if (value !== void 0) {
|
|
6352
|
-
acc[key] = value;
|
|
6353
|
-
}
|
|
6354
|
-
return acc;
|
|
6355
|
-
},
|
|
6356
|
-
{}
|
|
6357
|
-
);
|
|
6358
|
-
return message;
|
|
6359
|
-
}
|
|
6360
|
-
};
|
|
6361
|
-
function createBaseBackendView_ConfigEntry() {
|
|
6362
|
-
return { key: "", value: void 0 };
|
|
6363
|
-
}
|
|
6364
|
-
var BackendView_ConfigEntry = {
|
|
6365
|
-
encode(message, writer = new BinaryWriter3()) {
|
|
6366
|
-
if (message.key !== "") {
|
|
6367
|
-
writer.uint32(10).string(message.key);
|
|
6368
|
-
}
|
|
6369
|
-
if (message.value !== void 0) {
|
|
6370
|
-
Value.encode(Value.wrap(message.value), writer.uint32(18).fork()).join();
|
|
6371
|
-
}
|
|
6372
|
-
return writer;
|
|
6373
|
-
},
|
|
6374
|
-
decode(input, length) {
|
|
6375
|
-
const reader = input instanceof BinaryReader3 ? input : new BinaryReader3(input);
|
|
6376
|
-
const end = length === void 0 ? reader.len : reader.pos + length;
|
|
6377
|
-
const message = createBaseBackendView_ConfigEntry();
|
|
6378
|
-
while (reader.pos < end) {
|
|
6379
|
-
const tag = reader.uint32();
|
|
6380
|
-
switch (tag >>> 3) {
|
|
6381
|
-
case 1: {
|
|
6382
|
-
if (tag !== 10) {
|
|
6383
|
-
break;
|
|
6384
|
-
}
|
|
6385
|
-
message.key = reader.string();
|
|
6386
|
-
continue;
|
|
6387
|
-
}
|
|
6388
|
-
case 2: {
|
|
6389
|
-
if (tag !== 18) {
|
|
6390
|
-
break;
|
|
6391
|
-
}
|
|
6392
|
-
message.value = Value.unwrap(Value.decode(reader, reader.uint32()));
|
|
6393
|
-
continue;
|
|
6394
|
-
}
|
|
6395
|
-
}
|
|
6396
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
6397
|
-
break;
|
|
6398
|
-
}
|
|
6399
|
-
reader.skip(tag & 7);
|
|
6400
|
-
}
|
|
6401
|
-
return message;
|
|
6402
|
-
},
|
|
6403
|
-
fromJSON(object) {
|
|
6404
|
-
return {
|
|
6405
|
-
key: isSet3(object.key) ? globalThis.String(object.key) : "",
|
|
6406
|
-
value: isSet3(object?.value) ? object.value : void 0
|
|
6407
|
-
};
|
|
6408
|
-
},
|
|
6409
|
-
toJSON(message) {
|
|
6410
|
-
const obj = {};
|
|
6411
|
-
if (message.key !== "") {
|
|
6412
|
-
obj.key = message.key;
|
|
6413
|
-
}
|
|
6414
|
-
if (message.value !== void 0) {
|
|
6415
|
-
obj.value = message.value;
|
|
6416
|
-
}
|
|
6417
|
-
return obj;
|
|
6418
|
-
},
|
|
6419
|
-
create(base) {
|
|
6420
|
-
return BackendView_ConfigEntry.fromPartial(base ?? {});
|
|
6421
|
-
},
|
|
6422
|
-
fromPartial(object) {
|
|
6423
|
-
const message = createBaseBackendView_ConfigEntry();
|
|
6424
|
-
message.key = object.key ?? "";
|
|
6425
|
-
message.value = object.value ?? void 0;
|
|
6426
|
-
return message;
|
|
6427
|
-
}
|
|
6428
|
-
};
|
|
6429
|
-
function createBaseProviderView() {
|
|
6430
|
-
return { name: "", alias: "", config: {}, blocks: [] };
|
|
6431
|
-
}
|
|
6432
|
-
var ProviderView = {
|
|
6433
|
-
encode(message, writer = new BinaryWriter3()) {
|
|
6434
|
-
if (message.name !== "") {
|
|
6435
|
-
writer.uint32(10).string(message.name);
|
|
6436
|
-
}
|
|
6437
|
-
if (message.alias !== "") {
|
|
6438
|
-
writer.uint32(18).string(message.alias);
|
|
6439
|
-
}
|
|
6440
|
-
globalThis.Object.entries(message.config).forEach(([key, value]) => {
|
|
6441
|
-
ProviderView_ConfigEntry.encode({ key, value }, writer.uint32(26).fork()).join();
|
|
6442
|
-
});
|
|
6443
|
-
for (const v of message.blocks) {
|
|
6444
|
-
Block.encode(v, writer.uint32(34).fork()).join();
|
|
6445
|
-
}
|
|
6446
|
-
return writer;
|
|
6447
|
-
},
|
|
6448
|
-
decode(input, length) {
|
|
6449
|
-
const reader = input instanceof BinaryReader3 ? input : new BinaryReader3(input);
|
|
6450
|
-
const end = length === void 0 ? reader.len : reader.pos + length;
|
|
6451
|
-
const message = createBaseProviderView();
|
|
6452
|
-
while (reader.pos < end) {
|
|
6453
|
-
const tag = reader.uint32();
|
|
6454
|
-
switch (tag >>> 3) {
|
|
6455
|
-
case 1: {
|
|
6456
|
-
if (tag !== 10) {
|
|
6457
|
-
break;
|
|
6458
|
-
}
|
|
6459
|
-
message.name = reader.string();
|
|
6460
|
-
continue;
|
|
6461
|
-
}
|
|
6462
|
-
case 2: {
|
|
6463
|
-
if (tag !== 18) {
|
|
6464
|
-
break;
|
|
6465
|
-
}
|
|
6466
|
-
message.alias = reader.string();
|
|
6467
|
-
continue;
|
|
6468
|
-
}
|
|
6469
|
-
case 3: {
|
|
6470
|
-
if (tag !== 26) {
|
|
6471
|
-
break;
|
|
6472
|
-
}
|
|
6473
|
-
const entry3 = ProviderView_ConfigEntry.decode(reader, reader.uint32());
|
|
6474
|
-
if (entry3.value !== void 0) {
|
|
6475
|
-
message.config[entry3.key] = entry3.value;
|
|
6476
|
-
}
|
|
6477
|
-
continue;
|
|
6478
|
-
}
|
|
6479
|
-
case 4: {
|
|
6480
|
-
if (tag !== 34) {
|
|
6481
|
-
break;
|
|
6482
|
-
}
|
|
6483
|
-
message.blocks.push(Block.decode(reader, reader.uint32()));
|
|
6484
|
-
continue;
|
|
6485
|
-
}
|
|
6486
|
-
}
|
|
6487
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
6488
|
-
break;
|
|
6489
|
-
}
|
|
6490
|
-
reader.skip(tag & 7);
|
|
6491
|
-
}
|
|
6492
|
-
return message;
|
|
6493
|
-
},
|
|
6494
|
-
fromJSON(object) {
|
|
6495
|
-
return {
|
|
6496
|
-
name: isSet3(object.name) ? globalThis.String(object.name) : "",
|
|
6497
|
-
alias: isSet3(object.alias) ? globalThis.String(object.alias) : "",
|
|
6498
|
-
config: isObject3(object.config) ? globalThis.Object.entries(object.config).reduce(
|
|
6499
|
-
(acc, [key, value]) => {
|
|
6500
|
-
acc[key] = globalThis.String(value);
|
|
6501
|
-
return acc;
|
|
6502
|
-
},
|
|
6503
|
-
{}
|
|
6504
|
-
) : {},
|
|
6505
|
-
blocks: globalThis.Array.isArray(object?.blocks) ? object.blocks.map((e) => Block.fromJSON(e)) : []
|
|
6506
|
-
};
|
|
6507
|
-
},
|
|
6508
|
-
toJSON(message) {
|
|
6509
|
-
const obj = {};
|
|
6510
|
-
if (message.name !== "") {
|
|
6511
|
-
obj.name = message.name;
|
|
6512
|
-
}
|
|
6513
|
-
if (message.alias !== "") {
|
|
6514
|
-
obj.alias = message.alias;
|
|
6515
|
-
}
|
|
6516
|
-
if (message.config) {
|
|
6517
|
-
const entries = globalThis.Object.entries(message.config);
|
|
6518
|
-
if (entries.length > 0) {
|
|
6519
|
-
obj.config = {};
|
|
6520
|
-
entries.forEach(([k, v]) => {
|
|
6521
|
-
obj.config[k] = v;
|
|
6522
|
-
});
|
|
6523
|
-
}
|
|
6524
|
-
}
|
|
6525
|
-
if (message.blocks?.length) {
|
|
6526
|
-
obj.blocks = message.blocks.map((e) => Block.toJSON(e));
|
|
6527
|
-
}
|
|
6528
|
-
return obj;
|
|
6529
|
-
},
|
|
6530
|
-
create(base) {
|
|
6531
|
-
return ProviderView.fromPartial(base ?? {});
|
|
6532
|
-
},
|
|
6533
|
-
fromPartial(object) {
|
|
6534
|
-
const message = createBaseProviderView();
|
|
6535
|
-
message.name = object.name ?? "";
|
|
6536
|
-
message.alias = object.alias ?? "";
|
|
6537
|
-
message.config = globalThis.Object.entries(object.config ?? {}).reduce(
|
|
6538
|
-
(acc, [key, value]) => {
|
|
6539
|
-
if (value !== void 0) {
|
|
6540
|
-
acc[key] = globalThis.String(value);
|
|
6541
|
-
}
|
|
6542
|
-
return acc;
|
|
6543
|
-
},
|
|
6544
|
-
{}
|
|
6545
|
-
);
|
|
6546
|
-
message.blocks = object.blocks?.map((e) => Block.fromPartial(e)) || [];
|
|
6547
|
-
return message;
|
|
6548
|
-
}
|
|
6549
|
-
};
|
|
6550
|
-
function createBaseProviderView_ConfigEntry() {
|
|
6551
|
-
return { key: "", value: "" };
|
|
6552
|
-
}
|
|
6553
|
-
var ProviderView_ConfigEntry = {
|
|
6554
|
-
encode(message, writer = new BinaryWriter3()) {
|
|
6555
|
-
if (message.key !== "") {
|
|
6556
|
-
writer.uint32(10).string(message.key);
|
|
6557
|
-
}
|
|
6558
|
-
if (message.value !== "") {
|
|
6559
|
-
writer.uint32(18).string(message.value);
|
|
6560
|
-
}
|
|
6561
|
-
return writer;
|
|
6562
|
-
},
|
|
6563
|
-
decode(input, length) {
|
|
6564
|
-
const reader = input instanceof BinaryReader3 ? input : new BinaryReader3(input);
|
|
6565
|
-
const end = length === void 0 ? reader.len : reader.pos + length;
|
|
6566
|
-
const message = createBaseProviderView_ConfigEntry();
|
|
6567
|
-
while (reader.pos < end) {
|
|
6568
|
-
const tag = reader.uint32();
|
|
6569
|
-
switch (tag >>> 3) {
|
|
6570
|
-
case 1: {
|
|
6571
|
-
if (tag !== 10) {
|
|
6572
|
-
break;
|
|
6573
|
-
}
|
|
6574
|
-
message.key = reader.string();
|
|
6575
|
-
continue;
|
|
6576
|
-
}
|
|
6577
|
-
case 2: {
|
|
6578
|
-
if (tag !== 18) {
|
|
6579
|
-
break;
|
|
6580
|
-
}
|
|
6581
|
-
message.value = reader.string();
|
|
6582
|
-
continue;
|
|
6583
|
-
}
|
|
6584
|
-
}
|
|
6585
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
6586
|
-
break;
|
|
6587
|
-
}
|
|
6588
|
-
reader.skip(tag & 7);
|
|
6589
|
-
}
|
|
6590
|
-
return message;
|
|
6591
|
-
},
|
|
6592
|
-
fromJSON(object) {
|
|
6593
|
-
return {
|
|
6594
|
-
key: isSet3(object.key) ? globalThis.String(object.key) : "",
|
|
6595
|
-
value: isSet3(object.value) ? globalThis.String(object.value) : ""
|
|
6596
|
-
};
|
|
6597
|
-
},
|
|
6598
|
-
toJSON(message) {
|
|
6599
|
-
const obj = {};
|
|
6600
|
-
if (message.key !== "") {
|
|
6601
|
-
obj.key = message.key;
|
|
6602
|
-
}
|
|
6603
|
-
if (message.value !== "") {
|
|
6604
|
-
obj.value = message.value;
|
|
6605
|
-
}
|
|
6606
|
-
return obj;
|
|
6607
|
-
},
|
|
6608
|
-
create(base) {
|
|
6609
|
-
return ProviderView_ConfigEntry.fromPartial(base ?? {});
|
|
6610
|
-
},
|
|
6611
|
-
fromPartial(object) {
|
|
6612
|
-
const message = createBaseProviderView_ConfigEntry();
|
|
6613
|
-
message.key = object.key ?? "";
|
|
6614
|
-
message.value = object.value ?? "";
|
|
6615
|
-
return message;
|
|
6616
|
-
}
|
|
6617
|
-
};
|
|
6618
|
-
function createBaseLocalView() {
|
|
6619
|
-
return { name: "", mode: "", value_display: "" };
|
|
6620
|
-
}
|
|
6621
|
-
var LocalView = {
|
|
6622
|
-
encode(message, writer = new BinaryWriter3()) {
|
|
6623
|
-
if (message.name !== "") {
|
|
6624
|
-
writer.uint32(10).string(message.name);
|
|
6625
|
-
}
|
|
6626
|
-
if (message.mode !== "") {
|
|
6627
|
-
writer.uint32(18).string(message.mode);
|
|
6628
|
-
}
|
|
6629
|
-
if (message.value_display !== "") {
|
|
6630
|
-
writer.uint32(26).string(message.value_display);
|
|
6631
|
-
}
|
|
6632
|
-
return writer;
|
|
6633
|
-
},
|
|
6634
|
-
decode(input, length) {
|
|
6635
|
-
const reader = input instanceof BinaryReader3 ? input : new BinaryReader3(input);
|
|
6636
|
-
const end = length === void 0 ? reader.len : reader.pos + length;
|
|
6637
|
-
const message = createBaseLocalView();
|
|
6638
|
-
while (reader.pos < end) {
|
|
6639
|
-
const tag = reader.uint32();
|
|
6640
|
-
switch (tag >>> 3) {
|
|
6641
|
-
case 1: {
|
|
6642
|
-
if (tag !== 10) {
|
|
6643
|
-
break;
|
|
6644
|
-
}
|
|
6645
|
-
message.name = reader.string();
|
|
6646
|
-
continue;
|
|
6647
|
-
}
|
|
6648
|
-
case 2: {
|
|
6649
|
-
if (tag !== 18) {
|
|
6650
|
-
break;
|
|
6651
|
-
}
|
|
6652
|
-
message.mode = reader.string();
|
|
6653
|
-
continue;
|
|
6654
|
-
}
|
|
6655
|
-
case 3: {
|
|
6656
|
-
if (tag !== 26) {
|
|
6657
|
-
break;
|
|
6658
|
-
}
|
|
6659
|
-
message.value_display = reader.string();
|
|
6660
|
-
continue;
|
|
6661
|
-
}
|
|
6662
|
-
}
|
|
6663
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
6664
|
-
break;
|
|
6665
|
-
}
|
|
6666
|
-
reader.skip(tag & 7);
|
|
6667
|
-
}
|
|
6668
|
-
return message;
|
|
6669
|
-
},
|
|
6670
|
-
fromJSON(object) {
|
|
6671
|
-
return {
|
|
6672
|
-
name: isSet3(object.name) ? globalThis.String(object.name) : "",
|
|
6673
|
-
mode: isSet3(object.mode) ? globalThis.String(object.mode) : "",
|
|
6674
|
-
value_display: isSet3(object.valueDisplay) ? globalThis.String(object.valueDisplay) : isSet3(object.value_display) ? globalThis.String(object.value_display) : ""
|
|
6675
|
-
};
|
|
6676
|
-
},
|
|
6677
|
-
toJSON(message) {
|
|
6678
|
-
const obj = {};
|
|
6679
|
-
if (message.name !== "") {
|
|
6680
|
-
obj.name = message.name;
|
|
6681
|
-
}
|
|
6682
|
-
if (message.mode !== "") {
|
|
6683
|
-
obj.mode = message.mode;
|
|
6684
|
-
}
|
|
6685
|
-
if (message.value_display !== "") {
|
|
6686
|
-
obj.valueDisplay = message.value_display;
|
|
6687
|
-
}
|
|
6688
|
-
return obj;
|
|
6689
|
-
},
|
|
6690
|
-
create(base) {
|
|
6691
|
-
return LocalView.fromPartial(base ?? {});
|
|
6692
|
-
},
|
|
6693
|
-
fromPartial(object) {
|
|
6694
|
-
const message = createBaseLocalView();
|
|
6695
|
-
message.name = object.name ?? "";
|
|
6696
|
-
message.mode = object.mode ?? "";
|
|
6697
|
-
message.value_display = object.value_display ?? "";
|
|
6698
|
-
return message;
|
|
6699
|
-
}
|
|
6700
|
-
};
|
|
6701
|
-
function createBaseRenderError() {
|
|
6702
|
-
return { instance_id: "", input_name: "", message: "" };
|
|
6703
|
-
}
|
|
6704
|
-
var RenderError = {
|
|
6705
|
-
encode(message, writer = new BinaryWriter3()) {
|
|
6706
|
-
if (message.instance_id !== "") {
|
|
6707
|
-
writer.uint32(10).string(message.instance_id);
|
|
6708
|
-
}
|
|
6709
|
-
if (message.input_name !== "") {
|
|
6710
|
-
writer.uint32(18).string(message.input_name);
|
|
6711
|
-
}
|
|
6712
|
-
if (message.message !== "") {
|
|
6713
|
-
writer.uint32(26).string(message.message);
|
|
6714
|
-
}
|
|
6715
|
-
return writer;
|
|
6716
|
-
},
|
|
6717
|
-
decode(input, length) {
|
|
6718
|
-
const reader = input instanceof BinaryReader3 ? input : new BinaryReader3(input);
|
|
6719
|
-
const end = length === void 0 ? reader.len : reader.pos + length;
|
|
6720
|
-
const message = createBaseRenderError();
|
|
6721
|
-
while (reader.pos < end) {
|
|
6722
|
-
const tag = reader.uint32();
|
|
6723
|
-
switch (tag >>> 3) {
|
|
6724
|
-
case 1: {
|
|
6725
|
-
if (tag !== 10) {
|
|
6726
|
-
break;
|
|
6727
|
-
}
|
|
6728
|
-
message.instance_id = reader.string();
|
|
6729
|
-
continue;
|
|
6730
|
-
}
|
|
6731
|
-
case 2: {
|
|
6732
|
-
if (tag !== 18) {
|
|
6733
|
-
break;
|
|
6734
|
-
}
|
|
6735
|
-
message.input_name = reader.string();
|
|
6736
|
-
continue;
|
|
6737
|
-
}
|
|
6738
|
-
case 3: {
|
|
6739
|
-
if (tag !== 26) {
|
|
6740
|
-
break;
|
|
6741
|
-
}
|
|
6742
|
-
message.message = reader.string();
|
|
6743
|
-
continue;
|
|
6744
|
-
}
|
|
6745
|
-
}
|
|
6746
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
6747
|
-
break;
|
|
6748
|
-
}
|
|
6749
|
-
reader.skip(tag & 7);
|
|
6750
|
-
}
|
|
6751
|
-
return message;
|
|
6752
|
-
},
|
|
6753
|
-
fromJSON(object) {
|
|
6754
|
-
return {
|
|
6755
|
-
instance_id: isSet3(object.instanceId) ? globalThis.String(object.instanceId) : isSet3(object.instance_id) ? globalThis.String(object.instance_id) : "",
|
|
6756
|
-
input_name: isSet3(object.inputName) ? globalThis.String(object.inputName) : isSet3(object.input_name) ? globalThis.String(object.input_name) : "",
|
|
6757
|
-
message: isSet3(object.message) ? globalThis.String(object.message) : ""
|
|
6758
|
-
};
|
|
6759
|
-
},
|
|
6760
|
-
toJSON(message) {
|
|
6761
|
-
const obj = {};
|
|
6762
|
-
if (message.instance_id !== "") {
|
|
6763
|
-
obj.instanceId = message.instance_id;
|
|
6764
|
-
}
|
|
6765
|
-
if (message.input_name !== "") {
|
|
6766
|
-
obj.inputName = message.input_name;
|
|
6767
|
-
}
|
|
6768
|
-
if (message.message !== "") {
|
|
6769
|
-
obj.message = message.message;
|
|
6770
|
-
}
|
|
6771
|
-
return obj;
|
|
6772
|
-
},
|
|
6773
|
-
create(base) {
|
|
6774
|
-
return RenderError.fromPartial(base ?? {});
|
|
6775
|
-
},
|
|
6776
|
-
fromPartial(object) {
|
|
6777
|
-
const message = createBaseRenderError();
|
|
6778
|
-
message.instance_id = object.instance_id ?? "";
|
|
6779
|
-
message.input_name = object.input_name ?? "";
|
|
6780
|
-
message.message = object.message ?? "";
|
|
6781
|
-
return message;
|
|
6782
|
-
}
|
|
6783
|
-
};
|
|
6784
|
-
function createBasePosition() {
|
|
6785
|
-
return { x: 0, y: 0 };
|
|
6786
|
-
}
|
|
6787
|
-
var Position = {
|
|
6788
|
-
encode(message, writer = new BinaryWriter3()) {
|
|
6789
|
-
if (message.x !== 0) {
|
|
6790
|
-
writer.uint32(9).double(message.x);
|
|
6791
|
-
}
|
|
6792
|
-
if (message.y !== 0) {
|
|
6793
|
-
writer.uint32(17).double(message.y);
|
|
6794
|
-
}
|
|
6795
|
-
return writer;
|
|
6796
|
-
},
|
|
6797
|
-
decode(input, length) {
|
|
6798
|
-
const reader = input instanceof BinaryReader3 ? input : new BinaryReader3(input);
|
|
6799
|
-
const end = length === void 0 ? reader.len : reader.pos + length;
|
|
6800
|
-
const message = createBasePosition();
|
|
6801
|
-
while (reader.pos < end) {
|
|
6802
|
-
const tag = reader.uint32();
|
|
6803
|
-
switch (tag >>> 3) {
|
|
6804
|
-
case 1: {
|
|
6805
|
-
if (tag !== 9) {
|
|
6806
|
-
break;
|
|
6807
|
-
}
|
|
6808
|
-
message.x = reader.double();
|
|
6809
|
-
continue;
|
|
6810
|
-
}
|
|
6811
|
-
case 2: {
|
|
6812
|
-
if (tag !== 17) {
|
|
6813
|
-
break;
|
|
6814
|
-
}
|
|
6815
|
-
message.y = reader.double();
|
|
6816
|
-
continue;
|
|
6817
|
-
}
|
|
6818
|
-
}
|
|
6819
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
6820
|
-
break;
|
|
6821
|
-
}
|
|
6822
|
-
reader.skip(tag & 7);
|
|
6823
|
-
}
|
|
6824
|
-
return message;
|
|
6825
|
-
},
|
|
6826
|
-
fromJSON(object) {
|
|
6827
|
-
return {
|
|
6828
|
-
x: isSet3(object.x) ? globalThis.Number(object.x) : 0,
|
|
6829
|
-
y: isSet3(object.y) ? globalThis.Number(object.y) : 0
|
|
6830
|
-
};
|
|
6831
|
-
},
|
|
6832
|
-
toJSON(message) {
|
|
6833
|
-
const obj = {};
|
|
6834
|
-
if (message.x !== 0) {
|
|
6835
|
-
obj.x = message.x;
|
|
6836
|
-
}
|
|
6837
|
-
if (message.y !== 0) {
|
|
6838
|
-
obj.y = message.y;
|
|
6839
|
-
}
|
|
6840
|
-
return obj;
|
|
6841
|
-
},
|
|
6842
|
-
create(base) {
|
|
6843
|
-
return Position.fromPartial(base ?? {});
|
|
6844
|
-
},
|
|
6845
|
-
fromPartial(object) {
|
|
6846
|
-
const message = createBasePosition();
|
|
6847
|
-
message.x = object.x ?? 0;
|
|
6848
|
-
message.y = object.y ?? 0;
|
|
6849
|
-
return message;
|
|
6850
|
-
}
|
|
6851
|
-
};
|
|
6852
|
-
function createBaseInputDef2() {
|
|
6853
|
-
return {
|
|
6854
|
-
name: "",
|
|
6855
|
-
type: "",
|
|
6856
|
-
required: false,
|
|
6857
|
-
description: "",
|
|
6858
|
-
default_value: void 0,
|
|
6859
|
-
validation: [],
|
|
6860
|
-
ephemeral: void 0,
|
|
6861
|
-
nullable: void 0,
|
|
6862
|
-
sensitive: false
|
|
6863
|
-
};
|
|
6864
|
-
}
|
|
6865
|
-
var InputDef2 = {
|
|
6866
|
-
encode(message, writer = new BinaryWriter3()) {
|
|
6867
|
-
if (message.name !== "") {
|
|
6868
|
-
writer.uint32(10).string(message.name);
|
|
6869
|
-
}
|
|
6870
|
-
if (message.type !== "") {
|
|
6871
|
-
writer.uint32(18).string(message.type);
|
|
6872
|
-
}
|
|
6873
|
-
if (message.required !== false) {
|
|
6874
|
-
writer.uint32(24).bool(message.required);
|
|
6875
|
-
}
|
|
6876
|
-
if (message.description !== "") {
|
|
6877
|
-
writer.uint32(34).string(message.description);
|
|
6878
|
-
}
|
|
6879
|
-
if (message.default_value !== void 0) {
|
|
6880
|
-
Value.encode(Value.wrap(message.default_value), writer.uint32(42).fork()).join();
|
|
6881
|
-
}
|
|
6882
|
-
for (const v of message.validation) {
|
|
6883
|
-
ValidationBlock2.encode(v, writer.uint32(50).fork()).join();
|
|
6884
|
-
}
|
|
6885
|
-
if (message.ephemeral !== void 0) {
|
|
6886
|
-
writer.uint32(56).bool(message.ephemeral);
|
|
6887
|
-
}
|
|
6888
|
-
if (message.nullable !== void 0) {
|
|
6889
|
-
writer.uint32(64).bool(message.nullable);
|
|
6890
|
-
}
|
|
6891
|
-
if (message.sensitive !== false) {
|
|
6892
|
-
writer.uint32(72).bool(message.sensitive);
|
|
6893
|
-
}
|
|
6894
|
-
return writer;
|
|
6895
|
-
},
|
|
6896
|
-
decode(input, length) {
|
|
6897
|
-
const reader = input instanceof BinaryReader3 ? input : new BinaryReader3(input);
|
|
6898
|
-
const end = length === void 0 ? reader.len : reader.pos + length;
|
|
6899
|
-
const message = createBaseInputDef2();
|
|
6900
|
-
while (reader.pos < end) {
|
|
6901
|
-
const tag = reader.uint32();
|
|
6902
|
-
switch (tag >>> 3) {
|
|
6903
|
-
case 1: {
|
|
6904
|
-
if (tag !== 10) {
|
|
6905
|
-
break;
|
|
6906
|
-
}
|
|
6907
|
-
message.name = reader.string();
|
|
6908
|
-
continue;
|
|
6909
|
-
}
|
|
6910
|
-
case 2: {
|
|
6911
|
-
if (tag !== 18) {
|
|
6912
|
-
break;
|
|
6913
|
-
}
|
|
6914
|
-
message.type = reader.string();
|
|
6915
|
-
continue;
|
|
6916
|
-
}
|
|
6917
|
-
case 3: {
|
|
6918
|
-
if (tag !== 24) {
|
|
6919
|
-
break;
|
|
6920
|
-
}
|
|
6921
|
-
message.required = reader.bool();
|
|
6922
|
-
continue;
|
|
6923
|
-
}
|
|
6924
|
-
case 4: {
|
|
6925
|
-
if (tag !== 34) {
|
|
6926
|
-
break;
|
|
6927
|
-
}
|
|
6928
|
-
message.description = reader.string();
|
|
6929
|
-
continue;
|
|
6930
|
-
}
|
|
6931
|
-
case 5: {
|
|
6932
|
-
if (tag !== 42) {
|
|
6933
|
-
break;
|
|
6934
|
-
}
|
|
6935
|
-
message.default_value = Value.unwrap(Value.decode(reader, reader.uint32()));
|
|
6936
|
-
continue;
|
|
6937
|
-
}
|
|
6938
|
-
case 6: {
|
|
6939
|
-
if (tag !== 50) {
|
|
6940
|
-
break;
|
|
6941
|
-
}
|
|
6942
|
-
message.validation.push(ValidationBlock2.decode(reader, reader.uint32()));
|
|
6943
|
-
continue;
|
|
6944
|
-
}
|
|
6945
|
-
case 7: {
|
|
6946
|
-
if (tag !== 56) {
|
|
6947
|
-
break;
|
|
6948
|
-
}
|
|
6949
|
-
message.ephemeral = reader.bool();
|
|
6950
|
-
continue;
|
|
6951
|
-
}
|
|
6952
|
-
case 8: {
|
|
6953
|
-
if (tag !== 64) {
|
|
6954
|
-
break;
|
|
6955
|
-
}
|
|
6956
|
-
message.nullable = reader.bool();
|
|
6957
|
-
continue;
|
|
6958
|
-
}
|
|
6959
|
-
case 9: {
|
|
6960
|
-
if (tag !== 72) {
|
|
6961
|
-
break;
|
|
6962
|
-
}
|
|
6963
|
-
message.sensitive = reader.bool();
|
|
6964
|
-
continue;
|
|
6965
|
-
}
|
|
6966
|
-
}
|
|
6967
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
6968
|
-
break;
|
|
6969
|
-
}
|
|
6970
|
-
reader.skip(tag & 7);
|
|
6971
|
-
}
|
|
6972
|
-
return message;
|
|
6973
|
-
},
|
|
6974
|
-
fromJSON(object) {
|
|
6975
|
-
return {
|
|
6976
|
-
name: isSet3(object.name) ? globalThis.String(object.name) : "",
|
|
6977
|
-
type: isSet3(object.type) ? globalThis.String(object.type) : "",
|
|
6978
|
-
required: isSet3(object.required) ? globalThis.Boolean(object.required) : false,
|
|
6979
|
-
description: isSet3(object.description) ? globalThis.String(object.description) : "",
|
|
6980
|
-
default_value: isSet3(object?.defaultValue) ? object.defaultValue : isSet3(object?.default_value) ? object.default_value : void 0,
|
|
6981
|
-
validation: globalThis.Array.isArray(object?.validation) ? object.validation.map((e) => ValidationBlock2.fromJSON(e)) : [],
|
|
6982
|
-
ephemeral: isSet3(object.ephemeral) ? globalThis.Boolean(object.ephemeral) : void 0,
|
|
6983
|
-
nullable: isSet3(object.nullable) ? globalThis.Boolean(object.nullable) : void 0,
|
|
6984
|
-
sensitive: isSet3(object.sensitive) ? globalThis.Boolean(object.sensitive) : false
|
|
6985
|
-
};
|
|
6986
|
-
},
|
|
6987
|
-
toJSON(message) {
|
|
6988
|
-
const obj = {};
|
|
6989
|
-
if (message.name !== "") {
|
|
6990
|
-
obj.name = message.name;
|
|
6991
|
-
}
|
|
6992
|
-
if (message.type !== "") {
|
|
6993
|
-
obj.type = message.type;
|
|
6994
|
-
}
|
|
6995
|
-
if (message.required !== false) {
|
|
6996
|
-
obj.required = message.required;
|
|
6997
|
-
}
|
|
6998
|
-
if (message.description !== "") {
|
|
6999
|
-
obj.description = message.description;
|
|
7000
|
-
}
|
|
7001
|
-
if (message.default_value !== void 0) {
|
|
7002
|
-
obj.defaultValue = message.default_value;
|
|
7003
|
-
}
|
|
7004
|
-
if (message.validation?.length) {
|
|
7005
|
-
obj.validation = message.validation.map((e) => ValidationBlock2.toJSON(e));
|
|
7006
|
-
}
|
|
7007
|
-
if (message.ephemeral !== void 0) {
|
|
7008
|
-
obj.ephemeral = message.ephemeral;
|
|
7009
|
-
}
|
|
7010
|
-
if (message.nullable !== void 0) {
|
|
7011
|
-
obj.nullable = message.nullable;
|
|
7012
|
-
}
|
|
7013
|
-
if (message.sensitive !== false) {
|
|
7014
|
-
obj.sensitive = message.sensitive;
|
|
7015
|
-
}
|
|
7016
|
-
return obj;
|
|
7017
|
-
},
|
|
7018
|
-
create(base) {
|
|
7019
|
-
return InputDef2.fromPartial(base ?? {});
|
|
7020
|
-
},
|
|
7021
|
-
fromPartial(object) {
|
|
7022
|
-
const message = createBaseInputDef2();
|
|
7023
|
-
message.name = object.name ?? "";
|
|
7024
|
-
message.type = object.type ?? "";
|
|
7025
|
-
message.required = object.required ?? false;
|
|
7026
|
-
message.description = object.description ?? "";
|
|
7027
|
-
message.default_value = object.default_value ?? void 0;
|
|
7028
|
-
message.validation = object.validation?.map((e) => ValidationBlock2.fromPartial(e)) || [];
|
|
7029
|
-
message.ephemeral = object.ephemeral ?? void 0;
|
|
7030
|
-
message.nullable = object.nullable ?? void 0;
|
|
7031
|
-
message.sensitive = object.sensitive ?? false;
|
|
7032
|
-
return message;
|
|
7033
|
-
}
|
|
7034
|
-
};
|
|
7035
|
-
function createBaseValidationBlock2() {
|
|
7036
|
-
return { condition: "", error_message: "" };
|
|
7037
|
-
}
|
|
7038
|
-
var ValidationBlock2 = {
|
|
7039
|
-
encode(message, writer = new BinaryWriter3()) {
|
|
7040
|
-
if (message.condition !== "") {
|
|
7041
|
-
writer.uint32(10).string(message.condition);
|
|
7042
|
-
}
|
|
7043
|
-
if (message.error_message !== "") {
|
|
7044
|
-
writer.uint32(18).string(message.error_message);
|
|
7045
|
-
}
|
|
7046
|
-
return writer;
|
|
7047
|
-
},
|
|
7048
|
-
decode(input, length) {
|
|
7049
|
-
const reader = input instanceof BinaryReader3 ? input : new BinaryReader3(input);
|
|
7050
|
-
const end = length === void 0 ? reader.len : reader.pos + length;
|
|
7051
|
-
const message = createBaseValidationBlock2();
|
|
7052
|
-
while (reader.pos < end) {
|
|
7053
|
-
const tag = reader.uint32();
|
|
7054
|
-
switch (tag >>> 3) {
|
|
7055
|
-
case 1: {
|
|
7056
|
-
if (tag !== 10) {
|
|
7057
|
-
break;
|
|
7058
|
-
}
|
|
7059
|
-
message.condition = reader.string();
|
|
7060
|
-
continue;
|
|
7061
|
-
}
|
|
7062
|
-
case 2: {
|
|
7063
|
-
if (tag !== 18) {
|
|
7064
|
-
break;
|
|
7065
|
-
}
|
|
7066
|
-
message.error_message = reader.string();
|
|
7067
|
-
continue;
|
|
7068
|
-
}
|
|
7069
|
-
}
|
|
7070
|
-
if ((tag & 7) === 4 || tag === 0) {
|
|
7071
|
-
break;
|
|
7072
|
-
}
|
|
7073
|
-
reader.skip(tag & 7);
|
|
7074
|
-
}
|
|
7075
|
-
return message;
|
|
7076
|
-
},
|
|
7077
|
-
fromJSON(object) {
|
|
7078
|
-
return {
|
|
7079
|
-
condition: isSet3(object.condition) ? globalThis.String(object.condition) : "",
|
|
7080
|
-
error_message: isSet3(object.errorMessage) ? globalThis.String(object.errorMessage) : isSet3(object.error_message) ? globalThis.String(object.error_message) : ""
|
|
7081
|
-
};
|
|
7082
|
-
},
|
|
7083
|
-
toJSON(message) {
|
|
7084
|
-
const obj = {};
|
|
7085
|
-
if (message.condition !== "") {
|
|
7086
|
-
obj.condition = message.condition;
|
|
7087
|
-
}
|
|
7088
|
-
if (message.error_message !== "") {
|
|
7089
|
-
obj.errorMessage = message.error_message;
|
|
7090
|
-
}
|
|
7091
|
-
return obj;
|
|
7092
|
-
},
|
|
7093
|
-
create(base) {
|
|
7094
|
-
return ValidationBlock2.fromPartial(base ?? {});
|
|
7095
|
-
},
|
|
7096
|
-
fromPartial(object) {
|
|
7097
|
-
const message = createBaseValidationBlock2();
|
|
7098
|
-
message.condition = object.condition ?? "";
|
|
7099
|
-
message.error_message = object.error_message ?? "";
|
|
7100
|
-
return message;
|
|
7101
|
-
}
|
|
7102
|
-
};
|
|
7103
|
-
function createBaseOutputDef2() {
|
|
7104
|
-
return { name: "", type: "", description: "", sensitive: false, depends_on: [] };
|
|
7105
|
-
}
|
|
7106
|
-
var OutputDef2 = {
|
|
7107
|
-
encode(message, writer = new BinaryWriter3()) {
|
|
7108
|
-
if (message.name !== "") {
|
|
7109
|
-
writer.uint32(10).string(message.name);
|
|
7110
|
-
}
|
|
7111
|
-
if (message.type !== "") {
|
|
7112
|
-
writer.uint32(18).string(message.type);
|
|
7113
|
-
}
|
|
7114
|
-
if (message.description !== "") {
|
|
7115
|
-
writer.uint32(26).string(message.description);
|
|
7116
|
-
}
|
|
7117
|
-
if (message.sensitive !== false) {
|
|
7118
|
-
writer.uint32(32).bool(message.sensitive);
|
|
7119
|
-
}
|
|
7120
|
-
for (const v of message.depends_on) {
|
|
7121
|
-
writer.uint32(42).string(v);
|
|
4688
|
+
if (message.y !== 0) {
|
|
4689
|
+
writer.uint32(17).double(message.y);
|
|
7122
4690
|
}
|
|
7123
4691
|
return writer;
|
|
7124
4692
|
},
|
|
7125
4693
|
decode(input, length) {
|
|
7126
4694
|
const reader = input instanceof BinaryReader3 ? input : new BinaryReader3(input);
|
|
7127
4695
|
const end = length === void 0 ? reader.len : reader.pos + length;
|
|
7128
|
-
const message =
|
|
4696
|
+
const message = createBasePosition();
|
|
7129
4697
|
while (reader.pos < end) {
|
|
7130
4698
|
const tag = reader.uint32();
|
|
7131
4699
|
switch (tag >>> 3) {
|
|
7132
4700
|
case 1: {
|
|
7133
|
-
if (tag !==
|
|
4701
|
+
if (tag !== 9) {
|
|
7134
4702
|
break;
|
|
7135
4703
|
}
|
|
7136
|
-
message.
|
|
4704
|
+
message.x = reader.double();
|
|
7137
4705
|
continue;
|
|
7138
4706
|
}
|
|
7139
4707
|
case 2: {
|
|
7140
|
-
if (tag !==
|
|
7141
|
-
break;
|
|
7142
|
-
}
|
|
7143
|
-
message.type = reader.string();
|
|
7144
|
-
continue;
|
|
7145
|
-
}
|
|
7146
|
-
case 3: {
|
|
7147
|
-
if (tag !== 26) {
|
|
7148
|
-
break;
|
|
7149
|
-
}
|
|
7150
|
-
message.description = reader.string();
|
|
7151
|
-
continue;
|
|
7152
|
-
}
|
|
7153
|
-
case 4: {
|
|
7154
|
-
if (tag !== 32) {
|
|
7155
|
-
break;
|
|
7156
|
-
}
|
|
7157
|
-
message.sensitive = reader.bool();
|
|
7158
|
-
continue;
|
|
7159
|
-
}
|
|
7160
|
-
case 5: {
|
|
7161
|
-
if (tag !== 42) {
|
|
4708
|
+
if (tag !== 17) {
|
|
7162
4709
|
break;
|
|
7163
4710
|
}
|
|
7164
|
-
message.
|
|
4711
|
+
message.y = reader.double();
|
|
7165
4712
|
continue;
|
|
7166
4713
|
}
|
|
7167
4714
|
}
|
|
@@ -7174,78 +4721,52 @@ var OutputDef2 = {
|
|
|
7174
4721
|
},
|
|
7175
4722
|
fromJSON(object) {
|
|
7176
4723
|
return {
|
|
7177
|
-
|
|
7178
|
-
|
|
7179
|
-
description: isSet3(object.description) ? globalThis.String(object.description) : "",
|
|
7180
|
-
sensitive: isSet3(object.sensitive) ? globalThis.Boolean(object.sensitive) : false,
|
|
7181
|
-
depends_on: globalThis.Array.isArray(object?.dependsOn) ? object.dependsOn.map((e) => globalThis.String(e)) : globalThis.Array.isArray(object?.depends_on) ? object.depends_on.map((e) => globalThis.String(e)) : []
|
|
4724
|
+
x: isSet3(object.x) ? globalThis.Number(object.x) : 0,
|
|
4725
|
+
y: isSet3(object.y) ? globalThis.Number(object.y) : 0
|
|
7182
4726
|
};
|
|
7183
4727
|
},
|
|
7184
4728
|
toJSON(message) {
|
|
7185
4729
|
const obj = {};
|
|
7186
|
-
if (message.
|
|
7187
|
-
obj.
|
|
7188
|
-
}
|
|
7189
|
-
if (message.type !== "") {
|
|
7190
|
-
obj.type = message.type;
|
|
7191
|
-
}
|
|
7192
|
-
if (message.description !== "") {
|
|
7193
|
-
obj.description = message.description;
|
|
7194
|
-
}
|
|
7195
|
-
if (message.sensitive !== false) {
|
|
7196
|
-
obj.sensitive = message.sensitive;
|
|
4730
|
+
if (message.x !== 0) {
|
|
4731
|
+
obj.x = message.x;
|
|
7197
4732
|
}
|
|
7198
|
-
if (message.
|
|
7199
|
-
obj.
|
|
4733
|
+
if (message.y !== 0) {
|
|
4734
|
+
obj.y = message.y;
|
|
7200
4735
|
}
|
|
7201
4736
|
return obj;
|
|
7202
4737
|
},
|
|
7203
4738
|
create(base) {
|
|
7204
|
-
return
|
|
4739
|
+
return Position.fromPartial(base ?? {});
|
|
7205
4740
|
},
|
|
7206
4741
|
fromPartial(object) {
|
|
7207
|
-
const message =
|
|
7208
|
-
message.
|
|
7209
|
-
message.
|
|
7210
|
-
message.description = object.description ?? "";
|
|
7211
|
-
message.sensitive = object.sensitive ?? false;
|
|
7212
|
-
message.depends_on = object.depends_on?.map((e) => e) || [];
|
|
4742
|
+
const message = createBasePosition();
|
|
4743
|
+
message.x = object.x ?? 0;
|
|
4744
|
+
message.y = object.y ?? 0;
|
|
7213
4745
|
return message;
|
|
7214
4746
|
}
|
|
7215
4747
|
};
|
|
7216
|
-
function isObject3(value) {
|
|
7217
|
-
return typeof value === "object" && value !== null;
|
|
7218
|
-
}
|
|
7219
4748
|
function isSet3(value) {
|
|
7220
4749
|
return value !== null && value !== void 0;
|
|
7221
4750
|
}
|
|
7222
4751
|
|
|
7223
4752
|
// src/proto-messages.ts
|
|
7224
4753
|
var CanvasViewProto = CanvasView;
|
|
7225
|
-
var NodeConfigProto = NodeConfig;
|
|
7226
|
-
var EdgeConfigProto = EdgeConfig;
|
|
7227
|
-
var SettingsConfigProto = SettingsConfig;
|
|
7228
4754
|
export {
|
|
4755
|
+
BRIDGE_METHODS,
|
|
7229
4756
|
Bundle,
|
|
7230
4757
|
CanvasViewProto,
|
|
7231
|
-
|
|
7232
|
-
|
|
7233
|
-
|
|
7234
|
-
convertCanvasView,
|
|
4758
|
+
EMPTY_BUNDLE,
|
|
4759
|
+
ENGINE_METHODS,
|
|
4760
|
+
ENGINE_STREAM_METHODS,
|
|
7235
4761
|
convertDiagnostic,
|
|
7236
|
-
|
|
7237
|
-
|
|
7238
|
-
|
|
7239
|
-
|
|
7240
|
-
convertNodeKind,
|
|
7241
|
-
convertRenderError,
|
|
7242
|
-
convertRenderInput,
|
|
7243
|
-
convertRenderNode,
|
|
7244
|
-
convertSettingsConfig,
|
|
7245
|
-
modeToInputMode,
|
|
4762
|
+
deriveNodeConfig,
|
|
4763
|
+
deriveSettingsConfig,
|
|
4764
|
+
nodeIdForAddress,
|
|
4765
|
+
nodeIdForDiagnostic,
|
|
7246
4766
|
parseModuleKey,
|
|
7247
4767
|
projectCanvasView,
|
|
7248
4768
|
resolveScopePath,
|
|
7249
|
-
resolveScopePositions
|
|
4769
|
+
resolveScopePositions,
|
|
4770
|
+
resolveScopePositionsByDepth
|
|
7250
4771
|
};
|
|
7251
4772
|
//# sourceMappingURL=index.mjs.map
|