Image and radio widgets

This commit is contained in:
space-nuko
2023-05-08 01:25:10 -05:00
parent b53d04286b
commit 584119433d
17 changed files with 332 additions and 94 deletions

View File

@@ -394,6 +394,18 @@ const ALL_ATTRIBUTES: AttributesSpecList = [
values: ["large", "small"],
defaultValue: "large"
},
// Gallery
{
name: "variant",
type: "enum",
location: "widget",
editable: true,
validNodeTypes: ["ui/gallery"],
values: ["gallery", "image"],
defaultValue: "gallery",
refreshPanelOnChange: true
},
]
},
{
@@ -483,7 +495,7 @@ const ALL_ATTRIBUTES: AttributesSpecList = [
defaultValue: "bang"
},
// gallery
// Gallery
{
name: "updateMode",
type: "enum",
@@ -494,6 +506,18 @@ const ALL_ATTRIBUTES: AttributesSpecList = [
defaultValue: "replace"
},
// Radio
{
name: "choices",
type: "string",
location: "nodeProps",
editable: true,
validNodeTypes: ["ui/radio"],
defaultValue: ["Choice A", "Choice B", "Choice C"],
serialize: serializeStringArray,
deserialize: deserializeStringArray,
},
// Workflow
{
name: "defaultSubgraph",