[Kss-devel] drag & drop
Duco Dokter
dokter at w20e.com
Mon Jul 23 16:52:45 CEST 2007
On Monday 23 July 2007 12:18:05 Balazs Ree wrote:
A short research period has revealed five potential candidates for drag-n-drop
in KSS, holding only two assumptions:
1. free license;
2. active community.
The five candidates are:
1. Dojo
2. YUI
3. Mochikit
4. Prototype/Scriptaculous
5. jQuery
Prototype/Scriptaculous is the current implementation, that seems to lack the
ability to have more than one dragable/droppable pool on one page, although I
can't find this shortcoming in the code.
Some other prerequisites may put focus on one of the other four.
* YUI is very modular, backed up by good documentation, and very fast.
* Mochikit is the most Python-esque of all, API-wise, has a small footprint
and is well documented. Seems to be a little slow in operations.
* Dojo is backed up by IBM, but is seemingly a tad on the monolothic side.
* jQuery is rapidly accumulating popularity, and has lot's of examples and
documentation.
Other considerations that I can think of:
* what's already in use? (Found Mochikit.js in core...)
* is python-esqueness a good thing?
* is a modular approach preferred? So as to be able to include only _some_
supported functions.
Anything else?
Duco
> On Mon, 23 Jul 2007 09:52:25 +0200 Duco Dokter wrote:
> > Is there a list of features that a drag & drop implementation should
> > provide? Or a general description of this? For instance to list all KSS
> > attributes that may be set on an element, and what kind of parameters
> > they would take. I assume drag & drop would look something like:
> >
> > #someElt {
> > allow-drag: True;
> > snap-grid: True;
> > allow-parents: <whatever list>
> > }
>
> There is no docs. We need to work together on this.
>
> This would require a deeper knowledge of the kss internals. The current
> drag and drop implementation is one of the most complex plugins we have
> because it operates on internal state and incorporates more kss events
> that need to be bound together (because that's what the underlying
> libraries require.)
>
> We have a working implementation that is based on the prototype/
> scriptaculous library, however I did not have time to write a working
> demo for it that would show you how to use evt-xxx parameters to
> parametrize the events. More importantly, the way the js wrapper for kss
> e constructed is sparsely documented. This documentation will be coming
> soon but not right now.
>
> I can only repeat now that at the moment I can give you zero time for
> help, I don't even attempt to show you why the parameters need to be done
> a bit differently then in your example. The plone release and my other
> project work keeps me 100% busy for this week. I would however be more
> then happy to work together with you and give you all the necessary
> support to make a kss binding for the javascript library you use,
> following the next week or after.
>
> The main reason for why this would be a priority, is that it turned out
> that scriptaculous drag and drop is not usable in its current form for
> general application building, because it does not support more
> independent drag and drop "pools" within the same page. Of course we
> could fix that which would practically mean a significant rewrite of the
> scriptaculous code. However this is not an option for us. Not because we
> cannot write the program, but because it is an impossible burden (and
> luxury) to maintain our own javascript code for something that is used in
> every single application on the web. Instead, we prefer to reuse
> libraries that are widely used outside the Plone community too and make
> kss wrapper for them. So replacing scriptaculous with one of jQuery or
> MochiKit or something else is a must.
>
> By the way, which is the library that you reuse in your product? I did
> not remember mentioned it so far.
--
It has long been an axiom of mine that the little things are infinitely
the most important.
-- Sir Arthur Conan Doyle, "A Case of Identity"
More information about the Kss-devel
mailing list