1 /* Remember the collapse state of the legend on recent changes and watchlist pages. */
2 jQuery( document
).ready( function ( $ ) {
4 cookieName
= 'changeslist-state',
9 isCollapsed
= $.cookie( cookieName
) === 'collapsed';
11 $( '.mw-changeslist-legend' )
13 collapsed
: isCollapsed
15 .on( 'beforeExpand.mw-collapsible', function () {
16 $.cookie( cookieName
, 'expanded', cookieOptions
);
18 .on( 'beforeCollapse.mw-collapsible', function () {
19 $.cookie( cookieName
, 'collapsed', cookieOptions
);