diff --git a/packages/interactive/src/components/HoverTextNearMouse.tsx b/packages/interactive/src/components/HoverTextNearMouse.tsx index 7fda29ea4..3f1ac0a45 100644 --- a/packages/interactive/src/components/HoverTextNearMouse.tsx +++ b/packages/interactive/src/components/HoverTextNearMouse.tsx @@ -32,6 +32,15 @@ export class HoverTextNearMouse extends React.Component(); + public constructor(props: HoverTextNearMouseProps) { + super(props); + + this.state = { + textWidth: undefined, + textHeight: undefined, + }; + } + public componentDidMount() { this.updateTextSize(); }