Skip to content

Commit

Permalink
docs: update hook headers
Browse files Browse the repository at this point in the history
  • Loading branch information
atomiks committed Jan 26, 2024
1 parent 2ab9f9a commit ddd2c00
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 8 deletions.
4 changes: 0 additions & 4 deletions website/pages/docs/useFocus.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,6 @@ like CSS `:focus`.
import {useFocus} from '@floating-ui/react';
```

This is useful when you want the floating element to be open only
while the reference element has focus, and by default only when
`:focus-visible` is applied.

To manage focus within the floating element itself, use
[`FloatingFocusManager`](/docs/FloatingFocusManager).

Expand Down
4 changes: 1 addition & 3 deletions website/pages/docs/useHover.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,7 @@ element, like CSS `:hover`.
import {useHover} from '@floating-ui/react';
```

This is useful when you want to open the floating element when
the user hovers over the reference element, including the ability
to enter the floating element
Includes the ability to enter the floating element
[without it closing](/docs/useHover#safepolygon).

<ShowFor packages={['react-dom']}>
Expand Down
2 changes: 1 addition & 1 deletion website/pages/docs/useTypeahead.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import {useTypeahead} from '@floating-ui/react';
```

This is useful for creating a menu with typeahead support, where
the user can type to focus an item and then immeditately select
the user can type to focus an item and then immediately select
it, especially if it contains a large number of items.

See [`FloatingList`](/docs/FloatingList) for creating composable
Expand Down

0 comments on commit ddd2c00

Please sign in to comment.