nolastan / sync.sketchplugin

Keep your design team in sync!
http://www.usesync.com/
MIT License
349 stars 15 forks source link

Styles are removed and re-added on each sync. Ideally they would update. #7

Closed andyhennie closed 8 years ago

andyhennie commented 8 years ago

If you change a font in google spreadsheet and sync, text styles are unselected in Sketch. Not sure if it's a bug, or the way it works. But would be nice, if it didn't happen.

Bug explained: https://dl.dropboxusercontent.com/u/430406/Live%20%5Bdo%20not%20delete%5D/Github/Sync-bug.mp4

nolastan commented 8 years ago

Or put another way, all the styles are removed and re-added each sync. Ideally the styles would update. Would love to see someone work on this and submit a pull request.

rodnem commented 8 years ago

No news ??? I would like too that the styles updated rather than cleared

nolastan commented 8 years ago

I've been trying but it seems the styles are immutable. If anyone can link to another plugin that modifies saved styles that'd be a huge help.

rodnem commented 8 years ago

Does this kind of "update" helps you ? https://medium.com/design-prototype-develop/flatten-plugin-for-sketch-af2d59b0458#.z65cx9lsg

In case, you don't know it, on https://teamsketch.slack.com/ there is a channel to help developpers of plugins

JWhiteUX commented 8 years ago

Yeah, this just happened to me. I tried to sync my styles from sketch to Google Doc, and lost all my styles, in exchange, I now have the google doc styles, and all my previous styles are no longer linked to their appropriate labels/copy/text.

I'll wait for a "Update" and "Push" feature to be added.

nolastan commented 8 years ago

@rodnem It looks like that plugin is updating a layer that has a style applied, thus updating the style. I could try creating a layer, applying the style, then updating the layer, and doing this for each style. I'll see if that works.

And yeah I've asked about this in Team Sketch but haven't gotten any helpful answers. Perhaps I should be more persistent :wink:

nolastan commented 8 years ago

Good news! Thanks to @patrickhill, the plugin now updates your text styles instead of replacing them.

We should be able to take similar technique and apply it to layer styles as well.

nolastan commented 8 years ago

I'm working on applying the update to layer styles as well. Would appreciate if anyone could test this version (source). You'll need to rename the unzipped file to remove -update-styles from the filename.