🚨 Variables: Deleted collections and modes don't disappear

I removed/detached all variables, use every command and solution suggested in this whole forum or elsewhere but it didn’t work for me.
I even copied the library components into a new document, one component after the other. Eventually even detached the cleared components before copying into the new document. The deleted collections still appear again.

@jjcm I think it would make sense to have these variables (or at least an option) completely removed everywhere when deleting.

Is this something in the works. It’s quite frustrating right now, because I want to move my design system to variables, but I have these ghost ones that stick around. I tried the solution offered but it’s just not working.

Thank you

I’ve run the Detach deleted variables command and it showed a message that said no deleted variables usages were found, and the ghost collection persisted. But then i found where I was using the deleted variable and changed it to a new variable and that made the ghost collection disappear.

2 Likes

I also ran into ghost color variables persisting, and running the command for deleting detached variables did nothing, nor did restarting Figma. Can supply file for repro if needed.

Edit: I discovered some icons with the union boolean containing some old color tokens, but they do not show up in the ‘Selection colors’ view so very hard to track down. If others run into the same I’d recommend really diving deep into the layers for hidden stuff (esp components with hidden elements)

Hi there,

this is also affecting the Variables REST API. It would be really helpful to know which variables are deleted…

Thank you

1 Like

I just ran into this – a variable which I have deleted is still assigned to the width of a frame.

Problem is, I can’t remove the nonexistent variable from the width property.

I tried doing a detach deleted variables command as the solution above instructs, but it said it found zero variables to detach and did nothing. The old, deleted variable is still assigned to the width.

I can assign an existing variable, but the truth is I don’t want any variable at all anymore. This is a frame with a lot of complex setup in it, so I really don’t want to start over again.

hi, this is still a serious issue … how am i supposed to work professionally with this?!
please asap implement the following options for variable collection updates:

in the importing file

  • option ‘delete all variable sets’ (at ones own risk)

  • option 'delete all orphaned / unused sets (and really make it work! this seems to be one of the main issues here, that even though there are no links any more to variables, their sets still appear as an option

  • update options for variable set imports:

  1. ‘overwrite all variables’; note that this implies logically that there may be some orphaned assignments after the update, in case there were tokens deleted that have been in the last update

  2. ‘rename variables’: this may be a bit tricky with the linkage (how do you know that semantic/primary/button/default is the same as semantic/primary/button/bg in the last update?); i guess here a detailed delta matrix would actually help where one can decide which variable became what … i know this is a lot to ask, but this problem just logically arises if you work professionally with this kind of stuff

  3. have an overview for all the listed token sets that are available in the UI and the option to brute force delete them!! sorry, but i do find it very disturbing that this is not possible – there is a REASON why they are still listed as options, and it is a total timehole to find out why and where. the only thing that can logically happen with this is that there are now some raw values again, where there had been ‘unlinked’ variable values before … i think you get the point. but it would really help keep things sorted and cleaned up …

in case you have questions, please get back to me
christian.schaefer@siemensgamesa.com

thanks …

2 Likes