-
-
Notifications
You must be signed in to change notification settings - Fork 537
Open
Labels
Description
Is your feature request related to a problem? Please describe.
It would be great if we could specify an array of preferred places in order for the tooltip to attempt to satisfy before falling back to an internally decided place. Example:
- When the screen is wide enough, I like place
bottom
.
- As the screen width shrinks, the tooltip automatically gets repositioned to
left
.
- I've verified
bottom-end
would work, though, and that would be my preference overleft
.
Describe the solution you'd like
Support prop place: PlacesType | PlacesType[]
. If an array is passed, react-tooltip could try each in order for feasibility before falling back to its own placement decision.
Describe alternatives you've considered
For now, I settle on using bottom-end
as the next best alternative.
Additional context
A similar request was made long ago in #225, but I don't understand the suggested resolution there.