adobe / adobe/react-spectrum

Hovering Button with Tooltip in a PreviewTrigger Popover closes the Popover

Open
#10,460 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
15.9k
Forks
1.6k
Avg merge
3d 9m
Merged PRs (30d)
59

Description

### Provide a general summary of the issue here

When a `Button` inside the `PreviewTrigger`'s `Popover` has a `Tooltip`, hovering the `Button` closes the `Popover` immediately.

### 🤔 Expected Behavior?

The `Tooltip` should display per usual and the `PreviewTrigger`'s `Popover` should remain open.

### 😯 Current Behavior

The `PreviewTrigger` `Popover` closes when the user's pointer hovers over the `Button` that is used as a `Tooltip` trigger.

### 💁 Possible Solution

_No response_

### 🔦 Context

In a `Popover` component that displays user's locale and UTC date strings, I'd like to include a gear icon `Button` that links to timezone settings; to remain accessible the icon button needs a RAC `Tooltip` i.e. "Timezone settings".

### 🖥️ Steps to Reproduce

https://stackblitz.com/edit/sb1-m6jng7rc?file=src%2FApp.tsx

### Version

1.20.0

### What browsers are you seeing the problem on?

Chrome

### If other, please specify.

_No response_

### What operating system are you using?

macOS

### 🧢 Your Company/Team

_No response_

### 🕷 Tracking Issue

_No response_

Contributor guide

Open the contributing guide

Research direction

Start by running the linked StackBlitz reproduction in src/App.tsx and inspect how the PreviewTrigger Popover, Button, and Tooltip interact on hover. Confirm that the Tooltip displays normally while the Popover stays open, including for the timezone-settings icon-button scenario described in the issue.

Written by the indexing model from the issue text.

Assessment

Tech stack
react, typescript
Domain
accessibility, frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
61/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.