Bureaucrats, editor, Interface administrators, Administrators (Semantic MediaWiki), Curators (Semantic MediaWiki), Editors (Semantic MediaWiki), Administrators
47,390
edits
No edit summary |
No edit summary |
||
Line 11:
if (namespace === -1 || namespace === 8) {
var page = mw.config.get('wgPageName');
addLink('Discord');
addLink('the RuneScape Wiki', 'rsw', page);
addLink('the RuneScape Classic Wiki', 'classicrsw', page);
Line 31 ⟶ 32:
});
}
function addLink(page) {
var url = 'https://www.runerealm.org/discord';
var title = 'Join our Discord to talk about wiki content or becoming an editor.';
var link = mw.util.addPortletLink('p-namespaces', url, '',
// no text - use background-image instead
'gadget-external-discord',
// button id
title // title text shown on hover
);
// for styling all links at once - addPortletLink only sets an id
$(link).addClass('gadget-external-icon');
}
function addLink(wikiname, interwiki, page) {
var url = mw.util.getUrl(interwiki + ':' + page);
|