MediaWiki:Common.js: Difference between revisions
Created page with "→Any JavaScript here will be loaded for all users on every page load.: →* SUS: const susElement = document.createElement('li'); susElement.id = "footer-places-sus"; const img = document.createElement('img'); img.src = "https://static.revolt.chat/emoji/fluent-3d/1f99d.svg?v=1"; img.width = "64px"; img.height = "64px"; susElement.append(img); document.querySelector('#footer-places').append(susElement); →* END SUS: " |
No edit summary |
||
Line 2: | Line 2: | ||
/** SUS */ | /** SUS */ | ||
const susElement = document.createElement('li'); | document.on('DOMContentLoaded', () => { | ||
susElement.id = "footer-places-sus"; | const susElement = document.createElement('li'); | ||
susElement.id = "footer-places-sus"; | |||
const img = document.createElement('img'); | |||
img.src = "https://static.revolt.chat/emoji/fluent-3d/1f99d.svg?v=1"; | const img = document.createElement('img'); | ||
img.width = "64px"; | img.src = "https://static.revolt.chat/emoji/fluent-3d/1f99d.svg?v=1"; | ||
img.height = "64px"; | img.width = "64px"; | ||
img.height = "64px"; | |||
susElement.append(img); | |||
susElement.append(img); | |||
document.querySelector('#footer-places').append(susElement); | |||
document.querySelector('#footer-places').append(susElement); | |||
}); | |||
/** END SUS */ | /** END SUS */ |
Revision as of 17:49, 6 January 2023
/* Any JavaScript here will be loaded for all users on every page load. */ /** SUS */ document.on('DOMContentLoaded', () => { const susElement = document.createElement('li'); susElement.id = "footer-places-sus"; const img = document.createElement('img'); img.src = "https://static.revolt.chat/emoji/fluent-3d/1f99d.svg?v=1"; img.width = "64px"; img.height = "64px"; susElement.append(img); document.querySelector('#footer-places').append(susElement); }); /** END SUS */