josh-tt
@josh1111
6:43am
I just did a test with a new file.
Create a layer in sketch called colors / black(add extra space with cursor here)
Create a style from it
Create a document in puzzle tokens with .colors .black
A new style with be created and you end up with two. So, you have to write .black__ in the scss file and look out for any extra spaces people may have used when creating styles.
Spaces at the end of a style are hard to visually identify, so I missed that one several times. If you try to find the style later, it seems that sketch corrects the space (at least in the latest version), so it looks normal in the components panel which makes it even harder to find, but in the code where sketch stores the style it must still have the space.
Edited
7:17am
Perhaps, some sort of simple hack debugger that finds styles that are exactly the same, looking (with the exception of spaces) gives you a hint that says - "these two styles were found identically named, but have different spacings, which sketch will interpret to be a new style" would be really helpful to catch on import.
Actually, an alphabetical 2-column inventory would be really useful to debug/check things in general so you can see the old style vs new style. Spaces could be highlighted.
from https://spectrum.chat/puzzle-tokens/general/documentation-of-required-attributes~7ffa350a-c423-43ee-a88a-0774d801d78a?m=MTU3NDMwNzgxODI1OA==
josh-tt @josh1111 6:43am I just did a test with a new file. Create a layer in sketch called colors / black(add extra space with cursor here) Create a style from it Create a document in puzzle tokens with .colors .black A new style with be created and you end up with two. So, you have to write .black__ in the scss file and look out for any extra spaces people may have used when creating styles. Spaces at the end of a style are hard to visually identify, so I missed that one several times. If you try to find the style later, it seems that sketch corrects the space (at least in the latest version), so it looks normal in the components panel which makes it even harder to find, but in the code where sketch stores the style it must still have the space. Edited
7:07am Attaching an example example to test, one sec: https://drive.google.com/file/d/17_y3mg_fGzwv_KKaMdaJAMJKl7EdGscC/view?usp=sharing
7:17am Perhaps, some sort of simple hack debugger that finds styles that are exactly the same, looking (with the exception of spaces) gives you a hint that says - "these two styles were found identically named, but have different spacings, which sketch will interpret to be a new style" would be really helpful to catch on import. Actually, an alphabetical 2-column inventory would be really useful to debug/check things in general so you can see the old style vs new style. Spaces could be highlighted.