Revert "Print styles in Vector are no longer feature flagged"

This reverts commit c863b94302.

This breaks the MediaWiki Installer ui.

Bug: T183640
Change-Id: I9f249db503c4df6ab9d87b97d9f2d1dca80744ba
This commit is contained in:
Paladox 2017-12-23 19:15:17 +00:00
parent bf698128f2
commit 7d2fc6df27
2 changed files with 23 additions and 4 deletions

View File

@ -44,6 +44,10 @@ class SkinVector extends SkinTemplate {
/** @inheritDoc */
public function getPageClasses( $title ) {
$className = parent::getPageClasses( $title );
if ( $this->vectorConfig->get( 'VectorExperimentalPrintStyles' ) ) {
$className .= ' vector-experimental-print-styles';
}
$className .= ' vector-nav-directionality';
return $className;
}
@ -70,6 +74,14 @@ class SkinVector extends SkinTemplate {
$this->enableResponsiveMode();
}
// Print styles are feature flagged.
// This flag can be removed when T169732 is resolved.
if ( $this->vectorConfig->get( 'VectorExperimentalPrintStyles' ) ) {
// Note, when deploying (T169732) we'll want to fold the stylesheet into
// skins.vector.styles and remove this module altogether.
$out->addModuleStyles( 'skins.vector.styles.experimental.print' );
}
$out->addModules( 'skins.vector.js' );
}

View File

@ -38,7 +38,6 @@
"@note": "When modifying skins.vector.styles definition, make sure the installer still works",
"ResourceModules": {
"skins.vector.styles": {
"class": "Vector\\ResourceLoaderLessModule",
"targets": [ "desktop", "mobile" ],
"position": "top",
"styles": {
@ -47,11 +46,17 @@
},
"screen-hd.less": {
"media": "screen and (min-width: 982px)"
},
"print.less": {}
}
}
},
"skins.vector.styles.experimental.print": {
"class": "Vector\\ResourceLoaderLessModule",
"targets": [ "desktop", "mobile" ],
"position": "top",
"styles": [
"print.less"
]
},
"skins.vector.styles.responsive": {
"targets": [ "desktop", "mobile" ],
"position": "top",
@ -105,6 +110,8 @@
"config": {
"VectorUseSimpleSearch": true,
"VectorUseIconWatch": true,
"@VectorExperimentalPrintStyles": "Temporary config variable to feature flag new print styles (T154965)",
"VectorExperimentalPrintStyles": false,
"VectorResponsive": false,
"VectorPrintLogo": false
},