Styles Generator

Programmatically generate Shared Styles based on the layers name

v1.3.2 is compatible with Sketch 3.0.0

Sketch Styles Generator

Sketch Styles Generator

Programmatically generate hundreds Shared Styles, all at once

Sketch Styles Generator is a plugin made for Sketch. It helps designers who want to generate Shared Styles for a Design System in a matter of seconds.

Follow me on Twitter @lucaorio_ for updates, help and other stuff! πŸŽ‰

Looking for other plugins? Give these a try! 😎

Sketch Resize Sketch Reverse

Contents

Why this Plugin?

  • Sketch doesn't allow to generate multiple Shared Styles (text, shapes, or both) at once
  • Sketch appends a Style suffix to the name of every style you try to create
  • Craft and other tools generate guidelines that may not fit your app styling

If you experienced at least one of the problems above, you know how painful the bootstrap of a Design System can be. The manual creation, renaming and double-check of every Shared Style is a slow process. And time is a precious resource (aka we got a lot of shit to do).

Sketch Styles Generator allows you to select any amount of layers (text, shapes, or all of them at once), and generate multiple Shared Styles named exactly like the layer itself. Have a look at the usage section to know more about how to use it.

If you need a similar approach to automate the Symbols creation, Batch Create Symbols released by Paul Demers is what you're looking for.

Installation

Manual

Via Sketch Runner

  • Trigger Sketch Runner (cmd+')
  • Move to the Install tab
  • Search for Styles Generator and install it

Usage

  • Rename the layers you want to generate your Shared Styles from. The speed of this boring process can be dramatically improved by using plugins like Find-And-Replace and RenameIt.
  • Select all of them, it doesn't matter if they are Shape or Text entities
  • Run the plugin by clicking Plugins->Styles Generator->Generate Shared Styles, or by using the ctrl+cmd+s shortcut
  • A little log on the bottom of the window will show you how many Styles were generated, and how many were updated.

Styles Generator Usage

FAQ

What happens if in my multiple selection there are some Symbols/Groups?

Sketch Styles Generator will detect the kind of layer you selected, and automatically skip Symbols and other entities that can't be converted into a Text/Shared Style.

Integrations

Sketch Styles Generator is now fully integrated with Sketch Runner, the ultimate tool to speed up your Sketch workflow. You can trigger the plugin by simply typing its first letters, in pure Spotlight style!

Sketch Runner Integration

License

https://github.com/lucaorio/sketch-styles-generator/blob/master/license


Contacts


Join the discussion

Download v1.3.2
Usage Activity
400100

Avg. user activity in the last 30 days

Stats
  • 794 downloads all–time
  • 17 downloads this week
  • 91 downloads this month
About this plugin

lucaorio published this plugin a year ago.

v1.3.2 is the latest of 3 releases

Native updates are supported within Sketch.app.