Using OutputPage::addModules lets the style loaded over javascript
Using OutputPage::addModuleStyles forces loading over css
Follows I32697c2c65824d7622c1840330d6074ebb68b488
Bug: T117328
Change-Id: I3ddf105d180336b6eb7ae31286221151055e649f
array( 'class' => 'gallery mw-gallery-' . $this->mMode ), $this->mAttribs );
$modules = $this->getModules();
- $modules[] = 'mediawiki.page.gallery.styles';
if ( $this->mParser ) {
$this->mParser->getOutput()->addModules( $modules );
+ $this->mParser->getOutput()->addModuleStyles( 'mediawiki.page.gallery.styles' );
} else {
$this->getOutput()->addModules( $modules );
+ $this->getOutput()->addModuleStyles( 'mediawiki.page.gallery.styles' );
}
$output = Xml::openElement( 'ul', $attribs );
if ( $this->mCaption ) {