Skip to main content

This has been mentioned here:

I am looking for the availability to HIDE a layer when a Boolean variable is TRUE and SHOW it when it is FALSE. So, the inverse of the default/current behavior. I want to do this without using components.

Use case: When a variable is true, show one frame. When that same variable is false, show a different frame.

I can get basically this by using two different variables:


but it would be more convenient to be able to do it with just one. Just give me a Boolean toggle when the variable is used to say if the variable should be inverted or not.

This just force me to create unnecessary component versions.

I don’t understand such a basic thing isnot offered but we have an AI tool integrated to add images...


I just encountered this (after only a short while with the product).  Yes, Visibility of a layer should allow the specification of an expression.  So, ‘Item Selected’ variable can be referenced as ‘Item Selected’, ‘!(Item Selection)’, or any number of other more complex expressions.  Please add this functionality soon so that we don’t have to duplicate all booleans and define (and set) a negated value alongside every boolean.


+1

Please add this, it would save a lot of effort and reduce confusion from redundant variables.


+100

There is so much bloat and unnecessary complexity in both if/else logic and creating variants to achieve this.


A hack I use is to set a conditional instead of connection lines and then use true/false statements in there


It’s insane that it wasn’t designed like this to begin with.

This is how variables work and are used in programming languages, and by Figma’s own UI – e.g. I toggle the visibility button on a layer to false, I expect it to hide, and I expect the Figma UI to update the visibility icon to display the closed eye – having two variables for this state in web development would be absurd, and is just as absurd in a design context. 

I am learning Figma variables at the moment and this was my reaction when I saw how they are currently setup: 

It is very hard to defend the current design logic if I were to say to a designer I work with that ‘Figma is easy’.