Skip to content

Commit

Permalink
fix: add missing null check
Browse files Browse the repository at this point in the history
  • Loading branch information
paodb committed Jul 13, 2022
1 parent 4a04064 commit 609a1a7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/vcf-tooltip.js
Original file line number Diff line number Diff line change
Expand Up @@ -350,7 +350,7 @@ export class Tooltip extends ElementMixin(ThemableMixin(PolymerElement)) {

// Detct if the offset parent is [positoned](https://developer.mozilla.org/en-US/docs/Web/CSS/position#types_of_positioning)
get _parentPostioned() {
return window.getComputedStyle(this.offsetParent).position !== 'static';
return this.offsetParent && window.getComputedStyle(this.offsetParent).position !== 'static';
}

_setPositionInVisibleBounds(parentRectHeight, parentRectWidth, tooltipLeft, tooltipTop, thisRect) {
Expand Down

0 comments on commit 609a1a7

Please sign in to comment.