MediaWiki:Mobile.js: Difference between revisions
Content deleted Content added
Johnrdorazio (talk | contribs) No edit summary Tags: Mobile edit Mobile web edit |
Johnrdorazio (talk | contribs) No edit summary Tags: Mobile edit Mobile web edit |
||
Line 9:
//<nowiki>
let MMCollap = {};
MMCollap.do = function(
console.log('MMCollap.do was called');
/* Outcommented for now, to be revisited later as some people raised potential concerns with providing mobile-only features:
Line 20:
}
}*/
MMCollap.
MMCollap.els = $content.find( '.mw-collapsible' );
if ( MMCollap.els
}
if ( MMCollap.modules.length ) {
console.log('collapsible elements were found');
mw.loader.using( MMCollap.modules ).then( function () {
if ( MMCollap.els && MMCollap.els.length ) {
mw.loader.addStyleTag('.mw-parser-output .mw-collapsible-toggle{font-weight:normal;min-width:6em}');▼
}▼
$(MMCollap.els).makeCollapsible(); //T111565 FTFY▼
▲ mw.loader.using(['jquery.makeCollapsible']).then( function () {
▲ }
▲ mw.loader.addStyleTag('.mw-parser-output .mw-collapsible-toggle{font-weight:normal;min-width:6em}');
▲ $(MMCollap.els).makeCollapsible(); //T111565 FTFY
});
}
if ( $content[ 0 ] && $content[ 0 ].isConnected === false ) {
mw.log.warn( 'wikipage.content hook should not be fired on unattached content' );
}
};
|