dragster icon indicating copy to clipboard operation
dragster copied to clipboard

Add support for older versions of IE

Open catmanjan opened this issue 11 years ago • 8 comments

Great idea, useless in production without IE support :(

catmanjan avatar Mar 03 '14 00:03 catmanjan

@catmanjan I'm taking the progressive enhancement approach here. I mostly use these events to add/remove styling classes to indicate a user has dragged over an element. It's nice UI polish, but it's not vital to drag and drop. You can still drop on a dropzone that doesn't change its appearance on dragover.

I basically treat the events like I treat :hover in the world of touch devices. Nice & useful if you have an input device that supports them, never vital though.

Do you have a use case where these events are vital in old IE? (Will reopen if so)

bensmithett avatar Mar 03 '14 00:03 bensmithett

What exactly is your reason for closing?

My use case is adding a hover style when dragging/dropping a file onto an element. It doesn't work in IE, therefore it is vital? :confused:

catmanjan avatar Mar 03 '14 00:03 catmanjan

@catmanjan at this point it's an enhancement, I've never promised old IE support. Reopened & labeled as such :smiley:

Old IE doesn't support DOM event constructors, and I don't want to bloat the library with cross-browser event junk to support a use-case I haven't had a need for.

There's a pull request in for a jQuery plugin version here that I haven't had a chance to play with yet: https://github.com/bensmithett/dragster/pull/2/files

That feels like a much nicer way to handle IE support - can you try it out & see if it solves your problems as is?

bensmithett avatar Mar 03 '14 01:03 bensmithett

jQuery does help with IE support but that PR is buggy.

I will maintain a seperate repo with a jquery.dragster project, for anyone else seeing this, it is also available on Nuget, making version control easier for your MVC folk.

https://github.com/catmanjan/jquery-dragster

https://www.nuget.org/packages/jQuery.Dragster/1.0.0

catmanjan avatar Mar 03 '14 05:03 catmanjan

@catmanjan sweet, thanks! I'll chuck a link in the main readme

bensmithett avatar Mar 03 '14 05:03 bensmithett

@catmanjan any chance you can list off the bugs you found in the other jquery plugin PR?

bensmithett avatar Mar 03 '14 05:03 bensmithett

Was suffering the same problem as issue #5.

Also does not pass in global jQuery namespace correctly, causing issues with other incorrect plugins.

catmanjan avatar Mar 03 '14 05:03 catmanjan

Following Pull Request is working with IE9, IE10, IE11 and Edge: https://github.com/christophermina/dragster

MickL avatar Jun 07 '16 14:06 MickL