The shared concept is to keep the main core files small & clean.
At this stage, both library are mainly ready-to-use CSS UI elements + a bit of Javascript to deal with sliding transitions, browser back & forward buttons & ajax submission.
That's pretty much it.
That's why any other functionalities like Themes, Google Analytics or Extended Styles plugins (and so would this edit/validation) are separate files. And why you won't find anything like this in iUI neither Emy at the moment.
That said, we have something very interesting here for a nice plugin!
Two different ways to handle edit / delete a list
This first one (very iPhonish in fact)
Or this second one
Where you select row by row, and hit "Delete selected".
Like in the iOS Mail app, and in pretty much all other platforms in fact
So as a cross-platform library, my $0.02 would be to implement something similar than this, rather than the touchscreen-only iPhonish first solution.
Plugin should then:
- Listen for the aftertransition event and check if a data-editablelist attribute is set on the active view node
- Add and "Edit“ button
- If tapped, a class "editable" might be added to the view's node, and each list item should get a delete toggle element.
- Once "Delete selected" is fired, all selected element should get deleted form the list
- A callback function should return all deleted elements ID.
In fact, it really sounds more like an editing plugin more than a delete plugin, since the callback should returns you the selection, then you should be able to do whatever you want with it.
Use cases could be: mark as read, mark as unread, delete, keep only those and remove others, send a grouped email to those selected people, set as done … endless use cases in fact.
So i guess the callback function should only return the selection, then the developer decides what to do with it.
And a few cases could be pre-built, like removeItems for example.
Any Javascript dev to handle this (or just a part) ?
Remi