kora
kora copied to clipboard
Safari Drag and Drop
Drag and Drop currently not supported
This needs to be fixed for all file inputs.
drag n drop for user profile pictures handled in user/edit.js:131
currently can't navigate to edit-profile page, I will fix this issue first in order to address this one I am commenting on here
Reference #165 for edit user
There were two issues here. The first being that two separate Ajax calls were being triggered by the user pressing the submit
button. This broke the normal file upload, with normal referring to using the buttons to input a new file.
The second issue was that ajaxData.append('profile'...
did not populate the existing profile
field, but rather created a new, identical, field to populate. Deleting the existing, empty, profile
field fixed this issue.
Moving to code review
Safari does not support both form.get()
as well as formData.delete()
added a check to disable drag and drop on safari
What page should I review this on? What branch?
on branch suth-35
on the edit-user page there is a drag and drop to edit profile pictures
Huh. Unfortunately everytime I tried to go to an edit user page, it would redirect me to the the users main profile page. This only happens on this branch.
fixed routing issue. Should be able to navigate to this page now
Okay. It seems to work, but as soon as I drop something in, it automatically submits the page. It shouldn't do that.
I am sad about safari though. I think that for now we should get this pushed, but should come back to safari eventually.
The file uploaders are designed to encourage drag and drop, and will definitely cause confusion for safari users for when they just don't work as expected. Safari is apparently the second most widely used browser behind chrome. So its definitely worth seeking a solution.
We could implement a visual change when Safari is detected to avoid this confusion you are talking about. This would ideally be a temporary fix for until safari-drag-n-drop is figured out
I'm going to reopen this, in the hopes that we can fix safari in the future. If thats okay.
Safari drag and drop seems to work for all document/file fields, however needs to be fixed for the dragging and dropping of profile images on signup, invited signup, and edit profile pages.
Also, drag and drop file fields need to be updated on all import pages as well. Import project, form, records etc.