Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Not working in Firefox #869

Open
schmaluk opened this issue Sep 7, 2017 · 37 comments
Open

Not working in Firefox #869

schmaluk opened this issue Sep 7, 2017 · 37 comments
Labels
pinned won't become stale from stalebot

Comments

@schmaluk
Copy link

schmaluk commented Sep 7, 2017

Hello,
reactdnd is not working anymore in the latest Firefox-Version 55.0.3
Using reactdnd version:
"react-dnd": "^2.5.1",
"react-dnd-html5-backend": "^2.5.1",

Does anyone knows the latest version of reactdnd where Firefox is working?

@schmaluk
Copy link
Author

schmaluk commented Sep 7, 2017

React-dnd does work however in Firefox 55.0.2.

@Paddy-Hamilton
Copy link

Paddy-Hamilton commented Oct 6, 2017

not working in 56.0 either, no errors thrown. Simply unable to click and drag at all. works fine in Chrome

@alexfi
Copy link

alexfi commented Oct 13, 2017

Any ideas on this one?
"react-dnd": "^2.5.4",
"react-dnd-html5-backend": "^2.5.4",

Firefox: 56.0
Often times stops working. Especially if many tabs are opened.

@bjrmatos
Copy link

bjrmatos commented Oct 13, 2017

can someone point to a repository with a sample case in which react-dnd is failing? i have an app that uses react-dnd a lot but i don't see any problem in firefox 56.

also please make sure to specify the OS that you are using, i have seen that recently html5 Drag and Drop API is having some inconsistencies in different OS

@lvpro
Copy link

lvpro commented Oct 30, 2017

I've observed issues with FF 56 on Linux, as well (didn't test on Windows or OSX).

http://react-dnd.github.io/react-dnd/examples-sortable-simple.html

Trying that simple example, an element will move at max 1 position and then no longer shift elements, if for example, I grab the bottom element and try to move it up to the top.

Also discussed in #778

erwinverdonk pushed a commit to erwinverdonk/react-dnd that referenced this issue Nov 28, 2017
…newer Firefox versions and potential other browsers as well
@erwinverdonk
Copy link

erwinverdonk commented Nov 29, 2017

For our case - DnD not working in FF, example case https://react-dnd.github.io/react-dnd/examples-drag-around-naive.html - I did fix the issue with the pull request I submitted yesterday. Perhaps you could try and report back whether it solves your case as well.

@fikip
Copy link

fikip commented Dec 20, 2017

Still having issues on FF 57.0.1 on Ubuntu 16.04. I'm not able to drag & drop at all, seems like the drag event starts but cancels immediately afterwards. Works fine in chrome.

@yankopetrov
Copy link

yankopetrov commented Dec 24, 2017

I also have problems with FF and OSX 10.13.1

Edit: I found another issue similar to this one (#778). Check it for more details. Also tried the beta FF Nightly(https://nightly.mozilla.org/) and the bugs are gone. Maybe this is FF issue and not react-dnd.

@Paddy-Hamilton
Copy link

@yankopetrov

I'm still experiencing the problems in Nightly, but it seems to break a whole lot more in the app than just RDandD. So not sure I trust that as an indication if FF is the real cause of the bug, and if they have fixed it.

@Paddy-Hamilton
Copy link

@erwinverdonk , could you share your fix ? what was the PR?
cheers

@yankopetrov
Copy link

@Paddy-Hamilton yes with FF Nightly still some bugs appears. Working with chrome and safari like a charm so should be FF issue. My case is exact the one in the reported FF issue.

@erwinverdonk
Copy link

@Paddy-Hamilton: Yeah I see it did not auto link here, so here is the link to PR: #928

@dmitrystril
Copy link

So does anyone know what is the issue?
I'm using FF 57.0.4 64bit on Ubuntu 17.04 and it's still not working. Even this example: http://react-dnd.github.io/react-dnd/examples-chessboard-tutorial-app.html

erwinverdonk pushed a commit to erwinverdonk/react-dnd that referenced this issue Feb 6, 2018
…lace 'this' with '_' mistake and add type
erwinverdonk pushed a commit to erwinverdonk/react-dnd that referenced this issue Feb 6, 2018
erwinverdonk pushed a commit to erwinverdonk/react-dnd that referenced this issue Feb 7, 2018
erwinverdonk pushed a commit to erwinverdonk/react-dnd that referenced this issue Feb 7, 2018
erwinverdonk pushed a commit to erwinverdonk/react-dnd that referenced this issue Feb 7, 2018
…newer Firefox versions and potential other browsers as well
erwinverdonk pushed a commit to erwinverdonk/react-dnd that referenced this issue Feb 7, 2018
@dmitrystril
Copy link

Hi, I've found some sort of workaround that worked for me. My drag-n-drop worked fine in Chrome but didn't work in FF at all.
So my code before:
render() { return ( isDragging ? null : <div className='myDraggableComponent'>...</div>)}
And after:
render() { return <div className='myDraggableComponent' style={{ visibility: isDragging ? 'hidden' : 'visible' }}>...</div>)}

@Paddy-Hamilton
Copy link

@dmitrystril @yankopetrov

The issue was still their for me in FF Nightly so I had to look for alternatives, I came across react-beautiful-dnd and it works like a charm in FF as well as all other major browsers, and has less markup than react-dnd which is a bonus.

darthtrevino pushed a commit that referenced this issue Mar 21, 2018
#928)

* #869 - Fix issue which causes drag operation to not work on newer Firefox versions and potential other browsers as well

* #869 - Increase delay to make sure the 'mousemove' listener will be added at the correct time
@gsantiago
Copy link

The Chess example still does not work in FF 59.0.2

@adamhooper
Copy link

The chess tutorial does not work on Linux with FF 60.0:

  1. Click and hold the knight
  2. Move to a valid square (one that renders green)
  3. Move to an adjacent square

Expected results: the square is highlighted red
Actual results: the green square stays highlighted, forever

Also: no matter what square my cursor is on, releasing the mouse cancels the drag.

@darthtrevino
Copy link
Member

Ae you on Linux @adamhooper? I can't reproduce in OSX

@adamhooper
Copy link

Fedora 28

@JacksonGariety
Copy link
Contributor

I was hoping that installing today's 3.0.2 update would fix it. Unfortunately, it is still broken. I have only tested on Linux, however. Has anyone tried the example on a different operating system?

@darthtrevino
Copy link
Member

The 3.x updates have been mainly targeted at improving types. I don't have a Linux machine, but if someone can reproduce this and cut a PR, that would be great

@darthtrevino
Copy link
Member

I'm going to look into different cross-browser testing tools we can use to catch issues like this. The existing examples should be a pretty good baseline for tests.

@lvpro
Copy link

lvpro commented May 30, 2018

I can confirm I've only seen this problem on the Linux version of Firefox. Works fine on Windows.

@koox00
Copy link

koox00 commented Jun 5, 2018

If you look at the sortable examples simple doesn't work, but stress test works.
The difference is that stress test is updating the state inside a requestAnimationFrame.

Using requestAnimationFrame solves it for me.
Firefox for Linux.

@darthtrevino
Copy link
Member

darthtrevino commented Jun 5, 2018 via email

@koox00
Copy link

koox00 commented Jun 5, 2018

@darthtrevino yeah of course!

@Skylsmoi
Copy link

Skylsmoi commented Jun 17, 2019

I just ran into a similar issue.
Although I already had latest versions of Firefox and react dnd (on linux).

What was causing my issue was that my drag handler (component with ref={props.connectDragSource}) was inside a <Link> from react router.

I don't know why it was causing the issue but as soon as I put it outside the  <Link>, everything worked fine.

Posting here in case it helps someone

@SystemParadox
Copy link

I've got the same issue in Firefox 60.8.0esr on Debian 10.

Updating the state inside requestAnimationFrame fixes it for Firefox, but it makes dragging and Chrome sluggish and broken.

@stale
Copy link

stale bot commented Sep 29, 2019

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the wontfix label Sep 29, 2019
@SystemParadox
Copy link

SystemParadox commented Sep 30, 2019

Please do not close this. It is still broken in Firefox 60.9.0esr.

@stale stale bot removed the wontfix label Sep 30, 2019
@darthtrevino darthtrevino added the pinned won't become stale from stalebot label Oct 2, 2019
@darthtrevino
Copy link
Member

@SystemParadox What OS are you using?

@SystemParadox
Copy link

Linux (Debian 10). I haven't had chance to try it on Windows yet but it seem very strange for it to be different.

@Spaubleit
Copy link

Spaubleit commented Oct 9, 2019

Fedora 30
All works fine in Firefox 69.0.1
Broken in Firefox Nightly 70.0a1 (2019-08-21)

@SystemParadox
Copy link

  • Works in 68.10.0esr
  • Works in 78.0.2

If they broke it in 70.0a1 then it would seem this keeps breaking for some reason, which is a bit concerning. If it breaks again then we really need to create a bare minimum test case and submit a ticket to the firefox devs.

@devyeshtandon
Copy link

devyeshtandon commented Sep 18, 2021

It's 2021 and chess example still does not work.
Firefox version: 92.0
OS: Ubuntu 18.04

@darthtrevino
Copy link
Member

darthtrevino commented Sep 18, 2021

I haven't had time to dig into a triage here, although I can confirm this is a case in Windows as well with FF 92. PRs are welcome.

Edit: looks fine running locally, there may have been a transient dependency update that fixed this

masonmcelvain added a commit to masonmcelvain/hop that referenced this issue May 9, 2022
This fixes a bug where the cards were not sortable in firefox due to a
drag and drop bug. The ref for the drag item needs to be on the top
level component apparently.
react-dnd/react-dnd#869 (comment)
@markbeacom
Copy link

For anyone who is still experiencing this issue, i found that on firefox, using a button with the ref drag will not work sadly.

Not exactly sure why this is the case but i avoided the issue by just replacing the button with a div and remove the button element.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pinned won't become stale from stalebot
Projects
None yet
Development

No branches or pull requests