-
Notifications
You must be signed in to change notification settings - Fork 17
Export
If opacity is 100%, don't export additional hex digits for that color.Skip disabled fills and borders- Add "Save raw colours in comments" checkbox
- Export styles with non-unique name correctly
- [Done][To release] Another thing that made me think along these lines, is that perhaps also including the library source in the comments for themes (such as Carbon) that reference several outside documents (See details below)
Another thing that made me think along these lines, is that perhaps also including the library source in the comments for themes (such as Carbon) that reference several outside documents. This would be similar to what you did with PP to show the source of the style. That would be helpful as well to track down rogue styles which is really hard to do in Sketch. See picture attached for example.
Which leads me to wonder, if things like 'library source' could also be used for import back into Sketch as well, then you could easily remap your styles to point to different libraries (each of which are managed by PT).
The goal would be to create a single master Sketch library using PT, but to have all your color styles in separate sketch file(s), text styles in other(s) and symbols/components in the third, similar to how a dev might set things up. You could build/design them in either Sketch (or code), and easily point to the different sources from your master project once they've been created using PT.
For example (workflow once you've created SCSS documents for color/type/symbols):
Export style list from master project (similar to generate styles overview doc - but gives you a scss file with styles src overview):
/color/green/10
library src=hd/documents/night-theme
/color/red/10
library src=hd/documents/night-theme
#button
library src=hd/documents/3d
#button
library src=hd/documents/3d
/text-01
library src=hd/documents/friendly
Find/replace 'night-theme' with 'day-theme'
Find/replace '3d with 'flat'.
Find/replace 'friendly with techy'.
Import style sources back into sketch.
Your sketch master file now points to all the 'night-theme' style themes (which you created with PT) for colors and 3d buttons become flat, and font becomes 'techy'.
I suppose these themes could be kept in a plugin UI itself (like presets for text/colors/symbols) and you could swap them without leaving sketch. I've seen some plugins that do similar things (states, night mode etc.), but the advantage of PT is having a single source of truth somewhere that's easily editable in code with the ability to export in and out of Sketch.
Just a morning brainstorm for now and I haven't finished my coffee yet. Perhaps it's a totally pointless as I suppose this is similar to just splitting your scss files by type and then setting up using
@import to use different variants.
But at the very least, as a simple Sketch file management utility it would help a lot to be able to get an existing library's 'styles' pointing to different Sketch library(s), provided the naming conventions across all of them stay synced.