Skip to content

Instantly share code, notes, and snippets.

@wiseoldman
Last active August 27, 2021 12:13
  • Star 6 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save wiseoldman/b7660e1acb39229f1d06db484506eeb4 to your computer and use it in GitHub Desktop.
[Adobe XD letter-spacing] SCSS mixin to convert letter-spacing from Adobe XD to CSS #xd #letter-spacing
@mixin letter-spacing($spacing) {
letter-spacing: ($spacing / 1000) * 1em;
}
@SFaraji
Copy link

SFaraji commented Feb 7, 2019

Hey, for some reason when I add this "@include letter-spacing(-41);" to my scss class, I don't get the result.
When I then do it manually it is working. Have you faced with something like this before?
Thanks,
Shahryar

@wiseoldman
Copy link
Author

@SFaraji sorry, I haven't been active on github for some time, did you resolve this?

I set up a test pen and can't find any issues myself: https://codepen.io/wiseoldman/pen/pmGmxy

@SFaraji
Copy link

SFaraji commented Jun 3, 2019

Yes, no worries. Also thanks for the codepen reference!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment