Skip to content

Commit

Permalink
Improving backwards compatibility
Browse files Browse the repository at this point in the history
  • Loading branch information
nvh committed Jul 13, 2017
1 parent 3c5bbb6 commit fc6bd36
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions framer/SVGLayer.coffee
Expand Up @@ -13,9 +13,12 @@ toFill = (value) ->
class exports.SVGLayer extends Layer

constructor: (options={}) ->
if options.backgroundColor?
# Backwards compatibility for old Vekter exporter
# Ugly: detect Vekter export with html intrinsic size
if options.htmlIntrinsicSize? and options.backgroundColor?
# Backwards compatibility for old Vekter exporter that would
# set backgroundColor instead of color
options.color ?= options.backgroundColor
delete options.backgroundColor
super options
@updateGradientSVG()

Expand Down

0 comments on commit fc6bd36

Please sign in to comment.