User:Melecie/sans-script.js

let trg = false; if ( $("aprilfools").length ) { trg = true; } else if ( $(".ombox-humor").length ) { trg = true; } else if ( $(".ombox-humorantipolicy").length ) { trg = true; } else { for (let c of mw.config.get("wgCategories")) { if ([			"Wikipedia April Fools' Day",			"Category:Wikipedia humor",		].includes(c)) { trg = true } else { let regex = new RegExp("Wikipedia April Fools'"); if (regex.test(c)) { trg = true; } }	} }

if (trg) { $("body").css("font-family", "Comic Sans MS, Chalkboard, Papyrus, sans-serif"); } if (typeof hideFools != "undefined" && hideFools) { $(".aprilfools").html(""); $(".ombox-humor").html(""); $(".ombox-humorantipolicy").html(""); }