File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -50,7 +50,7 @@ export default function Tooltip<TDatum>(): React.ReactPortal | null {
50
50
const [ focusedDatum ] = useFocusedDatumAtom ( )
51
51
const latestFocusedDatum = useLatestWhen ( focusedDatum , ! ! focusedDatum )
52
52
53
- const preTooltipOptions = getOptions ( ) . tooltip
53
+ const preTooltipOptions = getOptions ( ) . tooltip ?? true
54
54
55
55
const secondaryAxis =
56
56
secondaryAxes . find ( d => d . id === latestFocusedDatum ?. secondaryAxisId ) ??
@@ -162,7 +162,9 @@ export default function Tooltip<TDatum>(): React.ReactPortal | null {
162
162
} ,
163
163
} )
164
164
165
- return portalEl
165
+ const show = ! ! preTooltipOptions
166
+
167
+ return show && portalEl
166
168
? ReactDOM . createPortal (
167
169
< animated . div style = { springProps } >
168
170
< div
You can’t perform that action at this time.
0 commit comments