Figma Support Forum

Move master components from different files to a new library

Thank you very much Gleb! I will try that.

2 Likes

The Figma team needs to fix this. Ok this plugin is amazing. Thank you very much Gleb! But this is an important problem. Figma team you need to fix this. Please!

9 Likes

@gleb This is pretty awesome! Doesn’t seem to work with variants, right? I’m on a team that uses a lot of atomic components that are organized as variants, and a new team needs to start sharing these atomic components. I currently have a separate shared library for color, type, and grids, and would like to move the existing atomic components to this shared library so both teams can use it. However, because most of them are organized as variants, I don’t think I’d be able to move them to the shared library and use the Master plug-in to “move” the master status from the existing file to the shared library file. Is my only option to “un-variant” the existing atomic components, and then move them to the shared library or am I missing something?

1 Like

It works with variants the same way it works with regular components: each variant in the variant set is technically a regular component.

I understand that you want to link multiple components (variants) at the same time — that’s a very common question. Unfortunately currently it’s quite a technically challenging task, but I’m hoping to make it work with multiple components in the near future. Just not sure when, but I’ll definitely let everyone know once I update it.

1 Like

Hey Lucie! How are you doing?

I have your exact same problem now. I’m trying to migrate a set of components from a Core Components lib to a Base Components lib and Master doesn’t work with component->component relationship :cry:
I was trying to avoid to visit each file which these components are being used and do all this manual work using Master in the files directly.

I think what we need to do is this manual painful work, and after doing it, we just go to the older lib and just DELETE all the components we “”“migrated”"" to the newer lib.

Did you do this? Or did you find some more intelligent way to solve it?

Thanks!

1 Like

Hey Bruno, could you clarify what you mean by “component->component” relationship? You can do this: Move master components from different files to a new library - #7 by Gleb — no need for manual work other than you need to do it for each component, should still be faster then manually finding and replacing all instances of each component.

Hey Gleb! I mean that at the “Team Components” I have graph components that are being used in tons of files.

We are moving one entire graph library that is on “Team Components” to the “Base Components” file (both are different Figma files on our DS project).

  1. I copy/paste the graph components from Team Components to Base Components, they become instances of Team Components.

  2. On Base Components DS file, I detach them and then convert them into new components, so now I can use Master to select them as target components.

  3. I go back to Team Components and select some graph component I need to replace with the new ones on Base Components.

  4. It doesn’t work. Master’s error message “No objects that can be attached found”.

It happens because Master doesn’t work with component → component replacement, right?

That said, I think that the only solution is go to each one of the tons of files and select all the graphs and start using Master to relink them to the new Base Components graphs components.

I don’t know if I got your instructions correctly. It didn’t work for me.
Thanks!

At the moment this functionality is a bit hidden, but what you did is correct and it should work. After you see the message “No objects that can be attached found” Master will remember the component that you linked, so now you can go to other files and do the third step in my instruction above (plugins don’t have access to other files so it can be only done in each file individually). Alternatively you can first manually link some instances of the component, and Master will remember them as well (this way you won’t see the error message). I get that it is confusing so I’m working on improving this.

Gotcha, Gleb.

But my main point is exactly the needing of open each file that is using my graph components and “manually” do it, you know? Even Master helping me saving some minutes, I still need to open all the files that is using the master components I am moving to a new library :cry:

Figma should perfectly better handle this 'master components migration between 2 DS files" feature.

1 Like

Yeah I hear you. When you wrote:

I think what we need to do is this manual painful work, and after doing it, we just go to the older lib and just DELETE all the components we “”“migrated”"" to the newer lib.

I thought you meant you will go to each file and manually find and replace all instances you need, without using Master, that’s why I wanted to clarify that there is a better way with Master. And yeah I totally agree, it would be great if Figma makes moving components between files possible.

1 Like

@Gleb sure, man! Thanks for your quick answers trying to help us and your proactivity.

I’m looking forward for having this feature covered by Figma team asap!

Cheers!
Bruno

1 Like

Figma should really implement this, at least in the paid version.

2 Likes

Hey @John_Stewart, it’s been a while but if that’s still relevant, I added the basic support for variants attachment! So now you can move variants between files a bit more easily.

1 Like

Unfortunately the major pain point is the needing of open each project file, individually, and manually link the old components with the new ones by using Master.
My company has more than 30 Figma files for different features and its individual different versions. So, open each file to update the components with the new library is insanely painful.

:frowning_face:

3 Likes

Got an easier workaround for free @Bruno_Barreto @Mario @Gleb .

How to transfer old figma projects and their components to a new design library.

  1. On your old project file, make sure the designs and their components are together on the same page
  2. Select all and Copy
  3. Paste them in the new design library you wish the components to live. The design and components must still be linked. ​
  4. Publish your new design library
  5. Select and Cut the designs (without the main components)
  6. Open a new figma file
  7. Go to Assets > Team Library and connect the new design library (or update it if you have already done it)
  8. Paste the designs.
  9. The components and overrides must still be linked to the new design library.
  10. Done!
9 Likes

Thanks @Konstantinos_Partheniadis, this sounds like a much easier method, however, I’m having a hard time following what the needed steps are here. Any chance you can revisit the steps here and provide a bit more detail? For one, I’m not sure what “The design and components must still be linked” means. Or similarly, what “The components and overrides must still be linked to the new design library.” means.

Figma just released a way to move components between files natively!

Short tutorial:

2 Likes

Hey everyone, has anyone encountered overrides’ reset after moving components? https://help.figma.com/hc/en-us/articles/4404848314647

Unlike Gleb’s Master components (which I used quite often before), this Figma’s new feature doesn’t seem to retain the overrides and ended up breaking a lot of screens in my case.

2 Likes

Yeah, I’m also having the same issue! :confused:

Yep, me too, lots of overrides lost which means lost information and broken layouts. Have you tried moving back the components and then restoring the previous version? If you restore it without moving them back it won’t undo the moving.