Open alisonjoseph opened 4 months ago
In this stage of code-connect (v 1.0.6) it is not possible. but we can get same results with variant restriction.
see this -> https://github.com/figma/code-connect/issues/80#issuecomment-2200476356
@Chanki-Min I'm not sure variant restrictions would help me here since its a nested prop, unless I missed something and variant restrictions support nesting.
+1
@Chanki-Min In my case, there are multiple nested components that I want to display based on specific boolean conditions. I'd like this feature to be supported.
accentButton: figma.boolean('accentButton', {
true: figma.nestedProps('Button', {
variant: figma.enum('variant', {
normal: 'normal',
outlined: 'outlined',
}),
}) + figma.nestedProps('ButtonContent', {
label: figma.string('label'),
}), // Please support this case.
false: {
variant: undefined,
label: undefined,
},
}),