Skip to main content
Question

How to find nodes that use a text or colour style

  • July 24, 2023
  • 3 replies
  • 1205 views

Hi, I want to search and return nodes on the current page where it uses a given text or color style in any way i.e. as a background fill, stroke, text color or font.

AFAIK, I can use fillStyleId to check if a layer’s background is using a color style. In that case, what other node attributes can I use to check for stroke, font and the rest?

This topic has been closed for replies.

3 replies

tank666
  • July 24, 2023

tank666
  • July 24, 2023

The Figma Developers website has a search engine.
https://www.figma.com/plugin-docs/search/


James_Yang
Figmate
  • Figmate
  • July 24, 2023

If you already have a style, you can use the consumers property on the style: BaseStyle | Plugin API, which will give you all the nodes and the fields where the style is applied.