leonardpauli / layer-renamer

Find or rename multiple layers at once using RegEx and flags in Sketch
MIT License
51 stars 2 forks source link

[Feature request] Rename group after first child layer #6

Closed Maikenvv closed 7 years ago

Maikenvv commented 7 years ago

I would like to rename groups after a layer within them. Is it possible to add this?

leonardpauli commented 7 years ago

Ahh, interesting! Absolutely, although not sure how user-friendly it will be with a text-input only (would love to add custom UI later on, no time right now).

rename group using inner layer name

Well, think I solved it :)

(Using the same principle as when navigating layer tree for selecting; > for children, < for parent, digits for layer index, etc, so %>0 would be first child, to get its title; append .t. So %>1>0.t would be the name/title of the first layer in the second group inside the selected group...)

"Added ability to rename group by its children layers (fixes #6) ie. put "%>0.t" (without quotes) in the replace-with-input-box to get first child name Bumped version nr"

leonardpauli commented 7 years ago

A more concrete use case I actually run into today;

rename using children

Maikenvv commented 7 years ago

The above example was exactly my problem. Thank you for adding this. This will save a lot of time working on projects and keeping everything in sync.