makeCollapsible: fix state of nested collapsibles
authorDerk-Jan Hartman <hartman.wiki@gmail.com>
Tue, 8 May 2018 20:46:56 +0000 (22:46 +0200)
committerJdlrobson <jrobson@wikimedia.org>
Thu, 10 May 2018 00:00:21 +0000 (00:00 +0000)
commit9114fbfdaea90a092c42b2530a6995a56449e69d
tree938477e4c2da22e381af50ac226cb0a444e48bdf
parent2d46c9e574c559281439a924441683776ca2f2e0
makeCollapsible: fix state of nested collapsibles

When collapsing or expanding an element which has nested other
collapsibles, the labels of all nested toggles were updating to the
value of the parent, while their state was not.

Apply to the specific toggle only, just as the classes are applied to
just the specific toggle.

Bug: T168689
Change-Id: I1c3c29dc9ca4ccbf8da83796e56964a7a6d58a81
resources/src/jquery/jquery.makeCollapsible.js