Want to continue the fun of planet.soyjak.st? Use SoyPlace, it will be online for as long as Gold can pay his server bills. Faggot (talk) 19:41, 25 September 2025 (UTC)
EFFECTIVE IMMEDIATELY: All unofficial revivals of the shemmy will be treated as hostile communities without prior approval by jannies, this is because they all seem to be run by Discord pedophiles. Faggot (talk) 11:41, 26 September 2025 (UTC)
MediaWiki:Common.js: Difference between revisions
From SNCApedia, the shit nobody cares about encyclopedia
Jump to navigationJump to search
Created page with "→Any JavaScript here will be loaded for all users on every page load.: →Below is stolen from ED at User:Cobblestone's request: →Collapsible toggle: $(document).ready(function() { $(".collapsibletoggletext").click(function() { $(this).parent().children(".collapsibletoggletext").toggleClass("hiddentext"); }); }); →Cycle forwards or backwards through elements one at a time via click: $(function(){ $(".cyclesequence").find(".cyclesequencelinknext..." |
(No difference)
|
Revision as of 13:02, 20 August 2025
/* Any JavaScript here will be loaded for all users on every page load. */
/* Below is stolen from ED at User:Cobblestone's request */
/* Collapsible toggle */
$(document).ready(function() {
$(".collapsibletoggletext").click(function() {
$(this).parent().children(".collapsibletoggletext").toggleClass("hiddentext");
});
});
/* Cycle forwards or backwards through elements one at a time via click */
$(function(){
$(".cyclesequence").find(".cyclesequencelinknext").click(function(){
if ($(this).closest(".cyclesequence").find(".cyclesequenceitem:visible").next(".cyclesequenceitem").length === 0) {
$(this).closest(".cyclesequence").find(".cyclesequenceitem:first").removeClass("hiddentext").siblings(".cyclesequenceitem").addClass("hiddentext");
}
else {
$(this).closest(".cyclesequence").find(".cyclesequenceitem:visible").next(".cyclesequenceitem").removeClass("hiddentext").siblings(".cyclesequenceitem").addClass("hiddentext");
}
});
$(".cyclesequence").find(".cyclesequencelinkprev").click(function(){
if ($(this).closest(".cyclesequence").find(".cyclesequenceitem:visible").prev(".cyclesequenceitem").length === 0) {
$(this).closest(".cyclesequence").find(".cyclesequenceitem:last").removeClass("hiddentext").siblings(".cyclesequenceitem").addClass("hiddentext");
}
else {
$(this).closest(".cyclesequence").find(".cyclesequenceitem:visible").prev(".cyclesequenceitem").removeClass("hiddentext").siblings(".cyclesequenceitem").addClass("hiddentext");
}
});
});
/* Click link to show one or more items and hide other items */
$(function() {
$(".morphlink").click(function() {
var correspondingContent = $(this).data("correspondingcontent");
if ($(this).parents(".morphcontainer").length) {
$(this).parents(".morphcontainer").find(".morphcontent").addClass("hiddentext");
if ($("#" + correspondingContent).length) // morphing object uses IDs
$("#" + correspondingContent).removeClass("hiddentext");
else // morphing object uses classes
$("." + correspondingContent).removeClass("hiddentext");
}
else {
if ($("#" + correspondingContent).length) { // morphing object uses IDs
$("#" + correspondingContent).removeClass("hiddentext");
$("#" + correspondingContent).siblings().filter($(".morphcontent")).addClass("hiddentext");
}
else { // morphing object uses classes
$("." + correspondingContent).removeClass("hiddentext");
$("." + correspondingContent).siblings().filter($(".morphcontent")).addClass("hiddentext");
}
}
});
});