Drop support for MW < 1.36

Compatibility policy is rel

Change-Id: Icc8ab4f74ec8b81f049b53e705deca8d5bb937bd
isekai
Reedy 3 years ago
parent c2d67ce519
commit 1160c07841

@ -6,7 +6,6 @@
*/ */
class SkinTimeless extends SkinTemplate { class SkinTimeless extends SkinTemplate {
/** /**
* Provide support for < 1.36. Can be deleted when no longer supported.
* @inheritDoc * @inheritDoc
*/ */
public function __construct( public function __construct(
@ -14,20 +13,6 @@ class SkinTimeless extends SkinTemplate {
) { ) {
$out = $this->getOutput(); $out = $this->getOutput();
// This code block can be removed when 1.35 is no longer supported.
if ( version_compare( MW_VERSION, '1.36', '<' ) ) {
// Add external links - this is replaced by `content-links` feature in 1.36
$out->addModuleStyles( [
'mediawiki.skinning.content.externallinks'
] );
// Make responsive - this is replaced by `responsive` option in 1.36
$out->addMeta( 'viewport',
'width=device-width, initial-scale=1.0, ' .
'user-scalable=yes, minimum-scale=0.25, maximum-scale=5.0'
);
// Associate template - this is replaced by `template` option in 1.36
$this->template = 'TimelessTemplate';
}
// Basic IE support without flexbox // Basic IE support without flexbox
$out->addStyle( $this->stylename . '/resources/IE9fixes.css', 'screen', 'IE' ); $out->addStyle( $this->stylename . '/resources/IE9fixes.css', 'screen', 'IE' );

@ -3,22 +3,6 @@
* ResourceLoader module to set some LESS variables for the skin * ResourceLoader module to set some LESS variables for the skin
*/ */
class TimelessVariablesModule extends ResourceLoaderSkinModule { class TimelessVariablesModule extends ResourceLoaderSkinModule {
/**
* Add compatibility to < 1.36
* @inheritDoc
*/
public function __construct(
array $options = [],
$localBasePath = null,
$remoteBasePath = null
) {
if ( version_compare( MW_VERSION, '1.36', '<' ) ) {
$options['features'] = [ "logo", "legacy" ];
}
parent::__construct( $options, $localBasePath, $remoteBasePath );
}
/** /**
* Add our LESS variables * Add our LESS variables
* *
@ -37,7 +21,7 @@ class TimelessVariablesModule extends ResourceLoaderSkinModule {
$backdrop = 'images/cat.svg'; $backdrop = 'images/cat.svg';
} }
$vars = array_merge( return array_merge(
$vars, $vars,
[ [
'backdrop-image' => "url($backdrop)", 'backdrop-image' => "url($backdrop)",
@ -46,8 +30,6 @@ class TimelessVariablesModule extends ResourceLoaderSkinModule {
// +width cutoffs ... // +width cutoffs ...
] ]
); );
return $vars;
} }
/** /**

@ -8,7 +8,7 @@
"license-name": "GPL-2.0-or-later", "license-name": "GPL-2.0-or-later",
"type": "skin", "type": "skin",
"requires": { "requires": {
"MediaWiki": ">= 1.35" "MediaWiki": ">= 1.36"
}, },
"ValidSkinNames": { "ValidSkinNames": {
"timeless": { "timeless": {

Loading…
Cancel
Save