Fix tooltip layout measurement loop (#11284)

This commit is contained in:
Samuel Newman
2026-07-27 13:16:31 +03:00
committed by GitHub
parent 51bcacb20b
commit abde10b7bd
+4 -3
View File
@@ -425,9 +425,10 @@ function Bubble({
},
]}
onLayout={e => {
setBubbleMeasurements({
width: e.nativeEvent.layout.width,
height: e.nativeEvent.layout.height,
const {width, height} = e.nativeEvent.layout
setBubbleMeasurements(prev => {
if (prev?.width === width && prev.height === height) return prev
return {width, height}
})
}}>
{children}