Skip to content

Commit 20dd863

Browse files
authored
Merge pull request #21 from dcmjs-org/bugfix/viewport-element
Ensure viewport element is obtained
2 parents 0150310 + e4132ee commit 20dd863

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/api.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -705,7 +705,7 @@ class VLWholeSlideMicroscopyImageViewer {
705705
const allDrawOptions = Object.assign(defaultDrawOptions, customDrawOptions);
706706
this[_interactions].draw = new Draw(allDrawOptions);
707707

708-
const container = this[_map].getTarget();
708+
const container = this[_map].getTargetElement();
709709

710710
//attaching openlayers events handling
711711
this[_interactions].draw.on('drawend', (e) => {
@@ -737,7 +737,7 @@ class VLWholeSlideMicroscopyImageViewer {
737737
layers: [this[_drawingLayer]]
738738
});
739739

740-
const container = this[_map].getTarget();
740+
const container = this[_map].getTargetElement();
741741

742742
this[_interactions].select.on('select', (e) => {
743743
publish(container, EVENT.ROI_SELECTED, _getROIFromFeature(e.selected[0], this._pyramid));

0 commit comments

Comments
 (0)