Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
.filter((d) => d.data && d.data.type === Value.EnumValue)
.map(Utils.nodeDefinitionToAcceptedEditorNodeDefinition),
static resolve(f: ParserField) {
let returnedValue = `${f.name}`;
if (f.data && f.data.type) {
if (f.data.type === Value.EnumValue) {
returnedValue = `${f.type.name}`;
}
if (f.data.type === Value.StringValue) {
returnedValue = `"${f.name}"`;
}
if (f.data.type === Value.ObjectValue) {
returnedValue = `{${(f.args || []).map(TemplateUtils.resolverForConnection)}}`;
}
}
return returnedValue;
}
}
.filter((d) => d.data && d.data.type === Value.EnumValue)
.map(Utils.nodeDefinitionToAcceptedEditorNodeDefinition),
const enumValue: EditorNodeDefinition = {
node: { ...Utils.createOND(), inputs: [], outputs: [] },
type: ValueDefinition.EnumValueDefinition,
data: {
type: ValueDefinition.EnumValueDefinition,
for: [TypeDefinition.EnumTypeDefinition],
},
help: help.EnumValue,
acceptsInputs: (d, defs) =>
Utils.dataForTypes(defs, [ValueDefinition.EnumValueDefinition]).map(
Utils.nodeDefinitionToAcceptedEditorNodeDefinition,
),
instances: [
{
data: {
type: Value.EnumValue,
},
node: {
inputs: null,
outputs: [],
notEditable: true,
name: undefined,
},
},
],
};
const objectValue: EditorNodeDefinition = {
node: {
...Utils.createOND(Value.ObjectValue, true),
inputs: [],
outputs: [],
},