check for existing help mode button

This commit is contained in:
Valentin Mihai 2024-06-06 18:29:48 +03:00
parent 5b7dd6a55a
commit 5eef6d403a

View File

@ -62,7 +62,7 @@ export class HelpButtonComponent implements OnInit, AfterViewInit, OnDestroy {
onResize() {
const currentComponent = this._elementRef.nativeElement;
const currentComponentRect = currentComponent.getBoundingClientRect();
this.helpModeButton.style.setProperty('top', `${currentComponentRect.top}px`);
this.helpModeButton.style.setProperty('left', `${currentComponentRect.left}px`);
this.helpModeButton?.style.setProperty('top', `${currentComponentRect.top}px`);
this.helpModeButton?.style.setProperty('left', `${currentComponentRect.left}px`);
}
}