Fix Grid bug

master
NeiroNx 2018-12-04 08:53:09 +04:00 committed by GitHub
parent 9f844f6496
commit 9fa5955b9c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 2 deletions

View File

@ -34,7 +34,7 @@ export default {
display: 'none'
});
canvBG.append(canvasGrid);
const gridDefs = svgdoc.createElementNS(NS.SVG, 'defs');
// grid-pattern
const gridPattern = svgdoc.createElementNS(NS.SVG, 'pattern');
assignAttributes(gridPattern, {
@ -54,7 +54,8 @@ export default {
height: 100
});
gridPattern.append(gridimg);
$('#svgroot defs').append(gridPattern);
gridDefs.append(gridPattern);
$('#canvasGrid').append(gridDefs);
// grid-box
const gridBox = svgdoc.createElementNS(NS.SVG, 'rect');