()
| 4339 | useLayoutEffect(() => { |
| 4340 | if (!open) return |
| 4341 | const update = (): void => { |
| 4342 | const el = buttonRef.current |
| 4343 | if (!el) return |
| 4344 | const r = el.getBoundingClientRect() |
| 4345 | setRect({ left: r.left, top: r.bottom + 4, width: Math.max(260, r.width) }) |
| 4346 | } |
| 4347 | update() |
| 4348 | window.addEventListener('resize', update) |
| 4349 | window.addEventListener('scroll', update, true) |
no outgoing calls
no test coverage detected