Export Symbols

This commit is contained in:
Dominic Zimmer
2020-11-18 17:54:39 +01:00
parent c44be9ec68
commit 6facbd4c93
3 changed files with 7 additions and 5 deletions

View File

@@ -35,7 +35,7 @@ class Resistor {
var [width, height] = [50, 100]
return [svg, width, height]
}
draw() {
draw(element = document.getElementsByTagName("body")[0]) {
var [svg, width, height] = this.getSVG();
var maxHeight = height + 2*25
var maxWidth = width
@@ -47,7 +47,7 @@ class Resistor {
${svg}
</g>
</svg>`
document.getElementsByTagName("body")[0].innerHTML = thesvg;
element.innerHTML += thesvg;
}
}