The audience picker closes on the click past it, not the press (#918) #948
Loading…
Reference in a new issue
No description provided.
Delete branch "fix/918-audience-click"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Closes #918.
Cause: the "Chosen people" picker sits in the Show it dialog's flow, so while it's open the dialog is taller. It closed on the outside press, so the dialog re-laid out before the release. The click aimed at "Send it to them on Discord" then landed on empty space and was lost.
Fix:
useOnClickOutsidetakes{ on: "click" }, andAudienceControluses it. The click has found its target before the panel closes, so one click both closes the picker and toggles the box. Menu and every other caller keep the press, for the drag reasons in the hook's docstring.Tests:
on: "click";AudienceControltest: a press alone leaves it open, then one click closes it and checks the box. It fails on main.Real-browser check (seeded e2e stack, Playwright, one real mouse click after ticking a person):
The screenshots show the dialog growing around the open picker (the cause) and collapsing after the single click.
Changelog:
changelog.d/918-audience-click.fixed.md.🤖 Generated with Claude Code
Closed on the press, the Show it dialog re-laid out before the release, so the click aimed at "Send it to them on Discord" landed on empty space and was lost. useOnClickOutside takes { on: "click" }; AudienceControl uses it, so the click has found its target before the panel closes. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>