Skip to main content
Elaya
New Member
Jun 1, 2025 12:34 PM UTC
Solved

The file name should be changed from the plugin

Hey, I’m building on a Figma plugin. I’m trying to change the Figma file name if the user types the name & submitted from the plugin. I’m currently using this function. figma.root.name. but it’s still not changing the file name. It still keeps as untitled. Please help me if we even have that capability. 

This topic has been closed for replies.
tank666
tank666Solution
Jun 1, 2025 6:09 PM UTC

figma.root.name is read-only. Thus, it is not possible to change the file name.

Related topic:

 

UX/UI designer. Figma expert. Creator and developer of plugins and widgets for Figma and FigJam. Check out my resources in Figma Community: figma.com/@tank

4 replies

tank666
tank666Solution
Jun 1, 2025 6:09 PM UTC

figma.root.name is read-only. Thus, it is not possible to change the file name.

Related topic:

 

UX/UI designer. Figma expert. Creator and developer of plugins and widgets for Figma and FigJam. Check out my resources in Figma Community: figma.com/@tank
Elaya
ElayaAuthor
New Member
Jun 1, 2025 6:17 PM UTC

got it, thanks. Also is it possible to set the thumbnail automatically from the instance or component key?

tank666
Jun 3, 2025 7:47 PM UTC

Also is it possible to set the thumbnail automatically from the instance or component key?

If I understand your question correctly, you can set a component node, but not an instance, as a thumbnail using the corresponding API method (setFileThumbnailNodeAsync). As for a remote component, you will need to import it by key first.

UX/UI designer. Figma expert. Creator and developer of plugins and widgets for Figma and FigJam. Check out my resources in Figma Community: figma.com/@tank
Elaya
ElayaAuthor
New Member
Jun 4, 2025 8:57 AM UTC

Thanks, will give it a try on this!