AutoUpdater

Primitive #68

๐Ÿ” Problem it solves

Scrolling or resizing the window leaves a floating element (tooltip, dropdown) in a stale position. It should automatically reposition itself to stay anchored to its trigger.

โœ… Solution

AutoUpdater listens to scroll and resize events (and optionally DOM mutations) and reโ€‘runs a positioning callback with debouncing.

๐Ÿงฉ Used by components

Tooltip, Popover, Dropdown, ContextMenu, any overlay that should follow a moving anchor.

๐ŸŽฎ Interactive demo