jquery.makeCollapsible: add plainMode support
authorMatmaRex <matma.rex@gmail.com>
Fri, 15 Mar 2013 20:10:08 +0000 (21:10 +0100)
committerCatrope <roan.kattouw@gmail.com>
Sat, 16 Mar 2013 00:32:10 +0000 (00:32 +0000)
commitdf93eedd8b9ed9b71e4b16a9afec40763f1bb418
treef577b1e2c23f28a1d1fcdaa3145f2b79e75eeba1
parenta9188c4fdedc1d77edec76b05623950c950c8fa9
jquery.makeCollapsible: add plainMode support

When .makeCollapsible() is used on a <ol>/<ul> list, the toggler is
inserted as the zeroth list item and clicking is causes all the other
list items to be hidden separately, one by one.

This hiding behavior is applied even when using custom togglers placed
outside of the list. This has some pretty serious performance
considerations when applied to large lists or tables (more than
~25 items/rows).

Enter plainMode. In combination with custom togglers, it makes all
types of elements to be treated the same and hidden/shown as a whole.

Change-Id: Idd9429b20d70741af72657feef26e1c95c76d51f
resources/jquery/jquery.makeCollapsible.js