[Toast] Disable swipe gesture optionally
See original GitHub issueFeature request
Overview
Users cannot copy text in Toast, as Toast has swipe gesture enabled by default.
I understand that this specification is useful, since dismissing notifications with swiping is a familiar interaction for mobile users. But most desktop users probably don’t perform swiping with the mouse cursor on webpages. I think their swipe gesture is often a drag and drop to copy text.
I’d like to toggle the ability to swipe gesture with a property like disableSwipeGesture in Toast.Provider .
Examples in other libraries
Who does this impact? Who is this for?
- Desktop users using the mouse cursor
- All users who want to copy text in Toast
Additional context
Issue Analytics
- State:
- Created a year ago
- Comments:7 (3 by maintainers)
Top Results From Across the Web
Issue #154 · calintamas/react-native-toast-message - GitHub
Hello,. Is there anyway to disable the onpress / gesture that swipes the toast away? I'm using a custom toast if that makes...
Read more >Android – Disable gesture listener on DrawerLayout - iTecNote
How can I disable the gesture recognition for the DrawerLayout? (swipe left to right) and only accept the close gesture (right to left)...
Read more >How to disable back swipe gesture in UINavigationController ...
I found out setting the gesture to disabled only doesn't always work. It does work, but for me it only did after I...
Read more >Disable Toast Notifications - Android Central Forum
One second or five, swiping or not, they are a waste of time... the ones I want to dump are system toasts. ETA:...
Read more >UI Manager - Zebra Technologies TechDocs
Attempting to use a disabled clipboard will result in an Android Toast message ... using a two-finger downward swipe gesture on some versions...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found

Yeah we were talking about this earlier. I think it’s either we need a dedicated example in the docs, or we do introduce a prop to disable it.
Looks good. Either way, we can disable swiping, so I will follow the decision based on Radix’s design policy. If needed, I can contribute to this issue.