Permalink
Browse files

Possible fix for images with direct mask in Sketch

  • Loading branch information...
koenbok committed Feb 24, 2015
1 parent efc5aa4 commit 22c2e4eb8667fbcdd0dc85131c9bdbd1107303d4
Showing with 7 additions and 0 deletions.
  1. +7 −0 framer/Importer.coffee
View
@@ -76,6 +76,13 @@ class exports.Importer
if info.maskFrame
layerInfo.frame = info.maskFrame
layerInfo.clip = true
# Possible fix for images that have a mask in Sketch
# So if a layer without children has a mask, Sketch imports the full image
# That is whay we then take the image frame over the mask frame again
if superLayer?.clip and info.children.length is 0
layerInfo.frame = info.image.frame
layerInfo.clip = false
# Figure out what the super layer should be. If this layer has a contentLayer
# (like a scroll view) we attach it to that instead.

0 comments on commit 22c2e4e

Please sign in to comment.