Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support MediaWiki >= 1.35 #16

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 1 addition & 11 deletions Overclocked.skin.php
Original file line number Diff line number Diff line change
Expand Up @@ -60,16 +60,6 @@ public function initPage( OutputPage $out ) {
$out->addHeadItem('pcgw-admanager', '<script src="https://hb.vntsm.com/v3/live/ad-manager.min.js" type="text/javascript" data-site-id="5ee882ebb519801b8a4d573b" data-mode="scan" async></script>');
}
$out->addModules( array( 'skins.overclocked.js' ) );
}

/**
* Add CSS via ResourceLoader
*
* @param $out OutputPage
*/
function setupSkinUserCss( OutputPage $out ) {
parent::setupSkinUserCss( $out );

$out->addModuleStyles( array(
'mediawiki.skinning.elements', 'skins.overclocked.styles'
) );
Expand Down Expand Up @@ -188,7 +178,7 @@ public function execute() {

foreach($sidebar as $boxName => $box) {
?>
<li id='<?php echo Sanitizer::escapeId( $box['id'] ) ?>'<?php echo Linker::tooltip( $box['id'] ) ?>>
<li id='<?php echo Sanitizer::escapeIdForAttribute( $box['id'] ) ?>'<?php echo Linker::tooltip( $box['id'] ) ?>>
<span class="header-item dropdown-toggle"><?php echo htmlspecialchars( $box['header'] ); ?></span>
<?php
if(is_array($box['content'])) { ?>
Expand Down
69 changes: 69 additions & 0 deletions skin.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
{
"name": "Overclocked",
"version": "1.0",
"author": [
"PCGamingWiki Team"
],
"url": "https://github.com/PCGamingWiki/overclocked",
"descriptionmsg": "overclocked-desc",
"namemsg": "skinname-overclocked",
"license-name": "GPL-2.0+",
"type": "skin",
"manifest_version": 2,
"ValidSkinNames": {
"overclocked": {
"class": "SkinOverclocked",
"args": [
{
"name": "overclocked"
}
]
}
},
"MessagesDirs": {
"ModernSkylight": [
"i18n"
]
},
"AutoloadClasses": {
"SkinOverclocked": "Overclocked.skin.php"
},
"ResourceModules": {
"skins.overclocked.styles": {
"styles": [
"resources/general-header.less",
"resources/general-footer.less",
"resources/general-personalbar.less",
"resources/general-toc.less",
"resources/general-inputfields.less",
"resources/general-specialpages.less",
"resources/pcgw.less",
"resources/pcgw-templates.less",
"resources/pcgw-icons.less",
"resources/mediawiki.custom.less",
"resources/mediawiki.mediaviewer.overrides.less",
"resources/page-home.less",
"resources/page-extension.less",
"resources/page-donate.less",
"resources/page-editing-guide.less",
"resources/other.less"
]
},
"skins.overclocked.js": {
"scripts": [
"resources/jquery/jquery.waypoints.min.js",
"resources/jquery/jquery.ba-outside-events.min.js",
"resources/pcgw.js"
]
}
},
"ResourceModuleSkinStyles": {
"mediawiki.special.preferences": [
"resources/mediawiki.special.preferences.less"
]
},
"ResourceFileModulePaths": {
"localBasePath": "",
"remoteSkinPath": "Overclocked"
}
}