Repository navigation
v0.2.49
v0.2.49 — Restores focus on overlay close using preventScroll to avoid page jump and exports a small focus helper used across components.
Note: all packages share the same version number in this monorepo; only the packages listed below have code changes in this release.
@data-slot/core
- ✨ Exported a new focusElement utility that calls element.focus({ preventScroll: true }) with a safe fallback — used to restore focus without causing the page to jump.
@data-slot/dialog
- 🐛 Switched to using focusElement when restoring focus after the dialog closes, preventing scroll/jump when focus is returned to the trigger or previous element.
@data-slot/dropdown-menu
- 🐛 Now uses focusElement to restore focus on close, avoiding page scrolling/jump when the menu is dismissed.
@data-slot/popover
- 🐛 Restores focus with focusElement on close so returning focus to the trigger or previous element does not cause page scrolling.
@data-slot/select
- 🐛 Uses focusElement for focus restoration on close to prevent unexpected page jumps.
Other
- chore: bumped repo version to v0.2.49.
💥 Breaking changes: none.