Skip to content

Conversation

atomiks
Copy link
Contributor

@atomiks atomiks commented Oct 18, 2025

Fixes #3008

This ensures pressing on nested children (in the React tree) doesn't dismiss on pointermove (swiping/scrolling) by using the capture event trick, which is already done for the other event handlers

Also refactored from pointer to touch events because (at least on non-iOS/on Chrome DevTools), pointermove stops firing once scroll starts, while touchmove always fires which ensures the popover always dismisses while scrolling away

Note: #2978 refactors away the timeout for the handleCaptureInside logic - I will rebase one of the PRs depending on which is merged first

@atomiks atomiks added type: bug It doesn't behave as expected. component: popover Changes related to the popover component. labels Oct 18, 2025
Copy link

pkg-pr-new bot commented Oct 18, 2025

vite-css-base-ui-example

pnpm add https://pkg.pr.new/mui/base-ui/@base-ui-components/react@3011
pnpm add https://pkg.pr.new/mui/base-ui/@base-ui-components/utils@3011

commit: dce519c

Copy link

netlify bot commented Oct 18, 2025

Deploy Preview for base-ui ready!

Name Link
🔨 Latest commit dce519c
🔍 Latest deploy log https://app.netlify.com/projects/base-ui/deploys/68f38bb7e11c140008ba61dc
😎 Deploy Preview https://deploy-preview-3011--base-ui.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@mui-bot
Copy link

mui-bot commented Oct 18, 2025

Bundle size report

Bundle Parsed size Gzip size
@base-ui-components/react 🔺+404B(+0.11%) 🔺+111B(+0.09%)

Details of bundle changes

@atomiks atomiks force-pushed the fix/pointer-move-children branch from 1e49be7 to f45a406 Compare October 18, 2025 11:57
@atomiks atomiks marked this pull request as ready for review October 18, 2025 12:29
@atomiks atomiks force-pushed the fix/pointer-move-children branch from 23548eb to a7806f2 Compare October 18, 2025 12:37
@atomiks atomiks force-pushed the fix/pointer-move-children branch from a7806f2 to 039fb7e Compare October 18, 2025 12:39
@github-actions github-actions bot added the PR: out-of-date The pull request has merge conflicts and can't be merged. label Oct 21, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

component: popover Changes related to the popover component. PR: out-of-date The pull request has merge conflicts and can't be merged. type: bug It doesn't behave as expected.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Modal inside Popover is closed unexpectedly on mobile when swiping

2 participants