glekli / jquery-sortable-photos Goto Github PK
View Code? Open in Web Editor NEWLicense: GNU General Public License v2.0
License: GNU General Public License v2.0
Hello there. Thanks for the plug. I couldn't figure out how to get queue information with AfterDrop. Where is the information about the order in which the changing picture is placed?
Firstly, thank you so much for this jQuery plug-in - I was able to build my code around it and it worked perfectly but I noted the issue re the last image too.
Would it be possible to add a 'serialize' method in the next release?
Again, thank you.
Hi,
Thank you for a really nice plugin but i'm having an issue. The plugin works perfect in the browser but on mobile its hard to scroll without accidentally dragging a photo, is there anyway to make sortablePhotos trigger on taphold instead of onClick?
Any help would be greatly appreciated
Hello. In your demo for sorting photos I am unable to drag a photo to the end of the photo list. It will either go before or back to where it was.
In my scenario it was one image per row so a simple fix was updating the _onDrop function as follows:
_onDrop: function(droppable, ui) {
// Move the dragged item to the new position in the DOM
// and rearrange the items.
// Need to use .detach() to keep the event listeners added
// by jQuery UI.
var draggable = $(ui.draggable);
var movedItem = draggable.detach();
//put if else check for movedItem.insertBefore() where it only puts the draggable object after
//if its row id is less than the droppable object's row id
if(draggable.attr("data-row-id") < $(droppable).attr("data-row-id")){
movedItem.insertAfter(droppable);
}
else{
movedItem.insertBefore(droppable);
}
this.arrange();
// Trigger event so that third parties have a chance to process the result.
this._trigger('afterDrop', null, this.element);
}
Hope this helps. Thanks for the library.
Hello,
I am a true beginner, and I like to hope that I can easily add a jquery plugin to my wordpress... Does anyone could point me in the right direction ? thanks in advance
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.