diff --git a/memory-viz/src/automate.ts b/memory-viz/src/automate.ts index 89f7ed1c..3b45c834 100644 --- a/memory-viz/src/automate.ts +++ b/memory-viz/src/automate.ts @@ -320,7 +320,7 @@ function getSize(obj: DrawnEntity) { obj.x = obj.x || 10; obj.y = obj.y || 10; - const m = new MemoryModel(); + const m = new MemoryModel({}); // As 'drawAll' provides a size list, where our case has just one element, we extract the element at index 0. const size = m.drawAll([obj])[0]; diff --git a/memory-viz/src/memory_model.ts b/memory-viz/src/memory_model.ts index e26b46ab..af8207f4 100644 --- a/memory-viz/src/memory_model.ts +++ b/memory-viz/src/memory_model.ts @@ -80,7 +80,7 @@ export class MemoryModel { ); this.svg.setAttribute( "height", - options.height ? options.width.toString() : "800" + options.height ? options.height.toString() : "800" ); this.roughjs_config = options.roughjs_config; this.rough_svg = rough.svg(this.svg, this.roughjs_config);