Merge "Convert Special:DeletedContributions to use OOUI."
[lhc/web/wiklou.git] / includes / resourceloader / ResourceLoaderSiteModule.php
index 380b7a5..7401d58 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 /**
- * Resource loader module for site customizations.
+ * ResourceLoader module for site customizations.
  *
  * This program is free software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License as published by
@@ -34,17 +34,18 @@ class ResourceLoaderSiteModule extends ResourceLoaderWikiModule {
         * @return array List of pages
         */
        protected function getPages( ResourceLoaderContext $context ) {
-               $pages = array();
+               $pages = [];
                if ( $this->getConfig()->get( 'UseSiteJs' ) ) {
-                       $pages['MediaWiki:Common.js'] = array( 'type' => 'script' );
-                       $pages['MediaWiki:' . ucfirst( $context->getSkin() ) . '.js'] = array( 'type' => 'script' );
-               }
-               if ( $this->getConfig()->get( 'UseSiteCss' ) ) {
-                       $pages['MediaWiki:Common.css'] = array( 'type' => 'style' );
-                       $pages['MediaWiki:' . ucfirst( $context->getSkin() ) . '.css'] = array( 'type' => 'style' );
-                       $pages['MediaWiki:Print.css'] = array( 'type' => 'style', 'media' => 'print' );
-
+                       $pages['MediaWiki:Common.js'] = [ 'type' => 'script' ];
+                       $pages['MediaWiki:' . ucfirst( $context->getSkin() ) . '.js'] = [ 'type' => 'script' ];
                }
                return $pages;
        }
+
+       /*
+        * @return array
+        */
+       public function getDependencies( ResourceLoaderContext $context = null ) {
+               return [ 'site.styles' ];
+       }
 }