mirror of
https://gerrit.wikimedia.org/r/mediawiki/skins/MinervaNeue
synced 2024-11-23 22:03:39 +00:00
Create new skins.minerva.styles module
This merges the existing modules skins.minerva.base.styles and skins.minerva.mainMenu.styles into a new module skins.minerva.styles which is named consistently with Vector's style module. The old modules will be kept for caching reasons for at least one, and possibly two deploy cycles, after which we will continue this task. Additional change: * drop .minerva-icon--{name}-base20 and .minerva-icon--{name}-disabled variants since these are no longer utilized and only serve cached HTML Bug: T266361 Change-Id: Iccf415a22e9535603befae25b8cea467f9905437
This commit is contained in:
parent
c5b6709e8f
commit
ee47c3d0bb
|
@ -21,7 +21,7 @@
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"resourceModule": "skins.minerva.mainMenu.styles",
|
"resourceModule": "skins.minerva.mainMenu.styles",
|
||||||
"maxSize": "1.0KB"
|
"maxSize": "1.1KB"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"resourceModule": "skins.minerva.scripts",
|
"resourceModule": "skins.minerva.scripts",
|
||||||
|
|
25
skin.json
25
skin.json
|
@ -141,13 +141,12 @@
|
||||||
"skins.minerva.scripts"
|
"skins.minerva.scripts"
|
||||||
],
|
],
|
||||||
"styles": [
|
"styles": [
|
||||||
"skins.minerva.base.styles",
|
"skins.minerva.styles",
|
||||||
"skins.minerva.content.styles.images",
|
"skins.minerva.content.styles.images",
|
||||||
"mediawiki.hlist",
|
"mediawiki.hlist",
|
||||||
"skins.minerva.codex.styles",
|
"skins.minerva.codex.styles",
|
||||||
"skins.minerva.icons.wikimedia",
|
"skins.minerva.icons.wikimedia",
|
||||||
"skins.minerva.mainMenu.icons",
|
"skins.minerva.mainMenu.icons"
|
||||||
"skins.minerva.mainMenu.styles"
|
|
||||||
],
|
],
|
||||||
"messages": [
|
"messages": [
|
||||||
"variants",
|
"variants",
|
||||||
|
@ -323,7 +322,24 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"ResourceModules": {
|
"ResourceModules": {
|
||||||
|
"skins.minerva.styles": {
|
||||||
|
"class": "MediaWiki\\ResourceLoader\\SkinModule",
|
||||||
|
"features": [
|
||||||
|
"normalize",
|
||||||
|
"accessibility",
|
||||||
|
"i18n-ordered-lists",
|
||||||
|
"content-body",
|
||||||
|
"content-tables",
|
||||||
|
"interface-core"
|
||||||
|
],
|
||||||
|
"styles": [
|
||||||
|
"resources/skins.minerva.base.styles/CSSCustomProperties.less",
|
||||||
|
"resources/skins.minerva.base.styles/skin.less",
|
||||||
|
"resources/skins.minerva.mainMenu.styles/index.less"
|
||||||
|
]
|
||||||
|
},
|
||||||
"skins.minerva.base.styles": {
|
"skins.minerva.base.styles": {
|
||||||
|
"deprecated": "Retained for caching reasons. Please use skins.minerva.styles instead.",
|
||||||
"class": "MediaWiki\\ResourceLoader\\SkinModule",
|
"class": "MediaWiki\\ResourceLoader\\SkinModule",
|
||||||
"features": [
|
"features": [
|
||||||
"normalize",
|
"normalize",
|
||||||
|
@ -397,7 +413,7 @@
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"skins.minerva.icons.wikimedia": {
|
"skins.minerva.icons.wikimedia": {
|
||||||
"selectorWithoutVariant": ".minerva-icon--{name}-base20, .minerva-icon--{name}-disabled, .minerva-icon--{name}",
|
"selectorWithoutVariant": ".minerva-icon--{name}",
|
||||||
"useDataURI": false,
|
"useDataURI": false,
|
||||||
"defaultColor": "#54595d",
|
"defaultColor": "#54595d",
|
||||||
"class": "MediaWiki\\ResourceLoader\\OOUIIconPackModule",
|
"class": "MediaWiki\\ResourceLoader\\OOUIIconPackModule",
|
||||||
|
@ -473,6 +489,7 @@
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"skins.minerva.mainMenu.styles": {
|
"skins.minerva.mainMenu.styles": {
|
||||||
|
"deprecated": "Retained for caching reasons. Please use skins.minerva.styles instead.",
|
||||||
"styles": [
|
"styles": [
|
||||||
"resources/skins.minerva.mainMenu.styles/index.less"
|
"resources/skins.minerva.mainMenu.styles/index.less"
|
||||||
]
|
]
|
||||||
|
|
|
@ -99,6 +99,23 @@ class SkinMinervaTest extends MediaWikiIntegrationTestCase {
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @covers ::getDefaultModules
|
||||||
|
*/
|
||||||
|
public function testGetDefaultModules() {
|
||||||
|
$context = new RequestContext();
|
||||||
|
$context->setTitle( Title::makeTitle( 0, 'Hello' ) );
|
||||||
|
$context->setActionName( 'view' );
|
||||||
|
|
||||||
|
$skinFactory = $this->getServiceContainer()->getSkinFactory();
|
||||||
|
$skin = $skinFactory->makeSkin( 'minerva' );
|
||||||
|
|
||||||
|
$skin->setContext( $context );
|
||||||
|
|
||||||
|
$this->assertContains( 'skins.minerva.styles', $skin->getDefaultModules()['styles']['skin'],
|
||||||
|
'Check entry point' );
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @dataProvider provideHasPageTabs
|
* @dataProvider provideHasPageTabs
|
||||||
* @covers ::hasPageTabs
|
* @covers ::hasPageTabs
|
||||||
|
|
Loading…
Reference in a new issue