Vector-Local/skin.json
Baha 413870d350 Add print logo
Logo cannot be displayed as a background image because it won't be
visible in print unless the user prints backgrounds too.

A sample configuration looks like this:

$wgVectorPrintLogo = [
	'url' => 'https://en.wikipedia.org/static/images/mobile/copyright/wikipedia-wordmark-en.svg',
	'width' => 174,
	'height' => 27
];

The solution presented in the patch has a downside of not being able
to scale images down if their dimensions are bigger than the
dimensions specified in the config variable. For example, if we want
to go with an SVG image, then IE8 won't be able to render it.
Alternatively, if we want to go with a PNG image, its dimensions need
to match the exact dimensoins in the config variable, otherwise the
image will show up larger or smaller depending on its dimensions.

A more complicated approach of scaling images using `transform: scale`
hasn't been used because we wanted to keep the configuration simple
while supporting the majority of our users. With the current change,
we can reuse the existing configuration options from Minerva, for
exmaple. It would look something like this:

$wgVectorPrintLogo = [
	'url' => $wgMFCustomLogos['copyright'],
	'width' => $wgMFCustomLogos['copyright-width'],
	'height' => $wgMFCustomLogos['copyright-height']
];

Bug: T169826
Change-Id: If8f9f8d95fd3c955ece37d6c8ab6995596189667
2017-08-01 10:55:53 -04:00

120 lines
3.5 KiB
JSON

{
"name": "Vector",
"author": [
"Trevor Parscal",
"Roan Kattouw",
"..."
],
"url": "https://www.mediawiki.org/wiki/Skin:Vector",
"descriptionmsg": "vector-skin-desc",
"namemsg": "skinname-vector",
"license-name": "GPL-2.0+",
"type": "skin",
"requires": {
"MediaWiki": ">= 1.29.0"
},
"ConfigRegistry": {
"vector": "GlobalVarConfig::newInstance"
},
"ValidSkinNames": {
"vector": "Vector"
},
"MessagesDirs": {
"Vector": [
"i18n"
]
},
"AutoloadClasses": {
"VectorHooks": "Hooks.php",
"SkinVector": "SkinVector.php",
"VectorTemplate": "VectorTemplate.php",
"Vector\\ResourceLoaderLessModule": "ResourceLoaderLessModule.php"
},
"Hooks": {
"BeforePageDisplayMobile": [
"VectorHooks::onBeforePageDisplayMobile"
]
},
"@note": "When modifying skins.vector.styles definition, make sure the installer still works",
"ResourceModules": {
"skins.vector.styles": {
"targets": [ "desktop", "mobile" ],
"position": "top",
"styles": {
"screen.less": {
"media": "screen"
},
"screen-hd.less": {
"media": "screen and (min-width: 982px)"
}
}
},
"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",
"styles": [
"responsive.less"
]
},
"skins.vector.js": {
"scripts": [
"collapsibleTabs.js",
"vector.js"
],
"position": "top",
"dependencies": [
"jquery.throttle-debounce",
"jquery.tabIndex"
]
}
},
"ResourceFileModulePaths": {
"localBasePath": "",
"remoteSkinPath": "Vector"
},
"ResourceModuleSkinStyles": {
"vector": {
"jquery.tipsy": "skinStyles/jquery.tipsy.less",
"jquery.ui.core": [
"skinStyles/jquery.ui/jquery.ui.core.css",
"skinStyles/jquery.ui/jquery.ui.theme.css"
],
"jquery.ui.accordion": "skinStyles/jquery.ui/jquery.ui.accordion.css",
"jquery.ui.autocomplete": "skinStyles/jquery.ui/jquery.ui.autocomplete.css",
"jquery.ui.button": "skinStyles/jquery.ui/jquery.ui.button.css",
"jquery.ui.datepicker": "skinStyles/jquery.ui/jquery.ui.datepicker.css",
"jquery.ui.dialog": "skinStyles/jquery.ui/jquery.ui.dialog.css",
"jquery.ui.menu": "skinStyles/jquery.ui/jquery.ui.menu.css",
"jquery.ui.progressbar": "skinStyles/jquery.ui/jquery.ui.progressbar.css",
"jquery.ui.resizable": "skinStyles/jquery.ui/jquery.ui.resizable.css",
"jquery.ui.selectable": "skinStyles/jquery.ui/jquery.ui.selectable.css",
"jquery.ui.slider": "skinStyles/jquery.ui/jquery.ui.slider.css",
"jquery.ui.spinner": "skinStyles/jquery.ui/jquery.ui.spinner.css",
"jquery.ui.tabs": "skinStyles/jquery.ui/jquery.ui.tabs.css",
"jquery.ui.tooltips": "skinStyles/jquery.ui/jquery.ui.tooltips.css",
"+mediawiki.action.view.redirectPage": "skinStyles/mediawiki.action.view.redirectPage.less",
"+mediawiki.notification": "skinStyles/mediawiki.notification.less",
"+oojs-ui-core.styles": "skinStyles/ooui.less",
"mediawiki.special": "skinStyles/mediawiki.special.less",
"+mediawiki.special.preferences.styles": "skinStyles/mediawiki.special.preferences.styles.less"
}
},
"config": {
"VectorUseSimpleSearch": true,
"VectorUseIconWatch": true,
"@VectorExperimentalPrintStyles": "Temporary config variable to feature flag new print styles (T154965)",
"VectorExperimentalPrintStyles": false,
"VectorResponsive": false,
"VectorPrintLogo": false
},
"manifest_version": 1
}