mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/CategoryTree
synced 2024-11-30 11:06:55 +00:00
Followup r98500, fixes flash of unstyled content
This commit is contained in:
parent
c842a0e190
commit
4383d6d598
Notes:
John Du Hart
2012-02-08 14:07:10 +00:00
|
@ -139,10 +139,12 @@ $wgAjaxExportList[] = 'efCategoryTreeAjaxWrapper';
|
|||
/**
|
||||
* Register ResourceLoader modules
|
||||
*/
|
||||
$wgResourceModules['ext.categoryTree'] = array(
|
||||
$commonModuleInfo = array(
|
||||
'localBasePath' => dirname( __FILE__ ) . '/modules',
|
||||
'remoteExtPath' => 'CategoryTree/modules',
|
||||
'styles' => 'ext.categoryTree.css',
|
||||
);
|
||||
|
||||
$wgResourceModules['ext.categoryTree'] = array(
|
||||
'scripts' => 'ext.categoryTree.js',
|
||||
'messages' => array(
|
||||
'categorytree-collapse',
|
||||
|
@ -158,7 +160,11 @@ $wgResourceModules['ext.categoryTree'] = array(
|
|||
'categorytree-error',
|
||||
'categorytree-retry',
|
||||
),
|
||||
);
|
||||
) + $commonModuleInfo;
|
||||
|
||||
$wgResourceModules['ext.categoryTree.css'] = array(
|
||||
'styles' => 'ext.categoryTree.css',
|
||||
) + $commonModuleInfo;
|
||||
|
||||
/**
|
||||
* Hook it up
|
||||
|
|
|
@ -161,7 +161,8 @@ class CategoryTree {
|
|||
* @param OutputPage $outputPage
|
||||
*/
|
||||
static function setHeaders( $outputPage ) {
|
||||
# Add the module
|
||||
# Add the modules
|
||||
$outputPage->addModuleStyles( 'ext.categoryTree.css' );
|
||||
$outputPage->addModules( 'ext.categoryTree' );
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue