()
| 32 | useLayoutEffect(() => { |
| 33 | if (!open) return; |
| 34 | const reposition = (): void => { |
| 35 | const bounds = trigger.current?.getBoundingClientRect(); |
| 36 | if (bounds) setPlacement(projectPickerPlacement(bounds, { width: window.innerWidth, height: window.innerHeight })); |
| 37 | }; |
| 38 | reposition(); |
| 39 | const observer = typeof ResizeObserver === 'undefined' ? undefined : new ResizeObserver(reposition); |
| 40 | const header = disclosure.current?.closest('.atlas-header') ?? trigger.current; |
no test coverage detected