Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
[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

This comment has been minimized.

Copy link

@SFaraji 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

This comment has been minimized.

Copy link
Owner Author

@wiseoldman wiseoldman commented Jun 3, 2019

@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

This comment has been minimized.

Copy link

@SFaraji 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