Skip to content

Commit

Permalink
Fixes #36
Browse files Browse the repository at this point in the history
Angular 2.0.0 breaks svg clipping path
By appending window.location to the referenced clip-path
  • Loading branch information
jhoglin committed Sep 30, 2016
1 parent 36004f2 commit 68b6030
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion TileLayer.GeoJSON.js
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ L.TileLayer.GeoJSON = L.TileLayer.Ajax.extend({

// Add the clip-path attribute to reference the id of the tile clipPath
this._recurseLayerUntilPath(function (pathLayer) {
pathLayer._container.setAttribute('clip-path', 'url(#' + clipPathId + ')');
pathLayer._container.setAttribute('clip-path', 'url(' + window.location.href + '#' + clipPathId + ')');
}, layer);
},

Expand Down

0 comments on commit 68b6030

Please sign in to comment.