Valkyrie icon indicating copy to clipboard operation
Valkyrie copied to clipboard

[CLI] Add the possibility to add "autoMirror = true" for ImageVector

Open contrudar opened this issue 10 months ago • 6 comments

Hello again! I didn't find any option in cli to add autoMirror. Now after getting ImageVectors I run my code to add it where I need. But I think it will be nice to support it in cli.

contrudar avatar Mar 07 '25 12:03 contrudar

Right now I parse "autoMirror" tag directly from xml.

https://github.com/ComposeGears/Valkyrie/blob/462f009c6561a50a7ed14704fd8c4e8ed91893a4/components/sharedTestResources/imagevector/xml/ic_all_path_params.xml#L6

Option can be added into CLI, but it will apply to the whole list of icons that you are converting

egorikftp avatar Mar 07 '25 12:03 egorikftp

I'm interested in ImageVector format. Maybe the option can be added to cli with the names of files which should include autoMirror. Not everyone icon should have it

contrudar avatar Mar 07 '25 13:03 contrudar

Could you please describe your case more detail? 🙂

I have long-term feature to introduce ImageVector icons optimization #154. Maybe we can introduce first feature in this area: make some icons automirror

for example:

 ./valkyrie imagevectoredit --input-path="" --file-names="Icon1,Icon2" --edit-automirror=true

It will rewrite existing icon with new param

egorikftp avatar Mar 07 '25 14:03 egorikftp

We have in design system some icons which should be mirrored and some which shouldn't. So, your future tool imagevectoredit I guess is doing the same as I do with my script now, but yours will have more functionality.

contrudar avatar Mar 07 '25 15:03 contrudar

Right now I parse "autoMirror" tag directly from xml.

What if the asset is SVG?

efemoney avatar Apr 09 '25 06:04 efemoney

Right now I parse "autoMirror" tag directly from xml.

What if the asset is SVG?

As I remember "autoMirror" xml only

egorikftp avatar Apr 09 '25 14:04 egorikftp

Will be part of 0.15 release.

egorikftp avatar Jun 03 '25 06:06 egorikftp