MediaWiki:Common.js: Difference between revisions
From Seven Sages of Rome
No edit summary Tag: Reverted |
No edit summary Tag: Reverted |
||
Line 1: | Line 1: | ||
function drilldownswitcher() { | |||
$('#drilldown-switch:contains("Expand all filters")').length | |||
? ($(".drilldown-filter-values:has(a)").css("display", "block"), | |||
$(".drilldown-values-toggle").each(function () { | |||
$("img").each(function () { | |||
$(this).attr("src", $(this).attr("src").replace("right-arrow.png", "down-arrow.png")); | |||
}); | |||
}), | |||
(document.getElementById("drilldown-switch").innerHTML = 'Hide all filters <i class="fa fa-minus"></i>')) | |||
: $('#drilldown-switch:contains("Hide all filters")').length && | |||
($(".drilldown-filter-values:has(a)").css("display", "none"), | |||
$(".drilldown-values-toggle").each(function () { | |||
$("img").each(function () { | |||
$(this).attr("src", $(this).attr("src").replace("down-arrow.png", "right-arrow.png")); | |||
}); | |||
}), | |||
(document.getElementById("drilldown-switch").innerHTML = 'Alle Filter ausklappen <i class="fa fa-plus"></i>')); | |||
} | |||
$(document).ready(function () { | $(document).ready(function () { | ||
$(".drilldown-results").css({ "-webkit-filter": "blur(0)", "-moz-filter": "blur(0)", "-o-filter": "blur(0)", "-ms-filter": "blur(0)", filter: "blur(0)" }), $(".drilldown-filter-values:has(a)").css("display", "none"); | $(".drilldown-results").css({ "-webkit-filter": "blur(0)", "-moz-filter": "blur(0)", "-o-filter": "blur(0)", "-ms-filter": "blur(0)", filter: "blur(0)" }), $(".drilldown-filter-values:has(a)").css("display", "none"); |
Revision as of 21:46, 12 February 2024
function drilldownswitcher() {
$('#drilldown-switch:contains("Expand all filters")').length
? ($(".drilldown-filter-values:has(a)").css("display", "block"),
$(".drilldown-values-toggle").each(function () {
$("img").each(function () {
$(this).attr("src", $(this).attr("src").replace("right-arrow.png", "down-arrow.png"));
});
}),
(document.getElementById("drilldown-switch").innerHTML = 'Hide all filters <i class="fa fa-minus"></i>'))
: $('#drilldown-switch:contains("Hide all filters")').length &&
($(".drilldown-filter-values:has(a)").css("display", "none"),
$(".drilldown-values-toggle").each(function () {
$("img").each(function () {
$(this).attr("src", $(this).attr("src").replace("down-arrow.png", "right-arrow.png"));
});
}),
(document.getElementById("drilldown-switch").innerHTML = 'Alle Filter ausklappen <i class="fa fa-plus"></i>'));
}
$(document).ready(function () {
$(".drilldown-results").css({ "-webkit-filter": "blur(0)", "-moz-filter": "blur(0)", "-o-filter": "blur(0)", "-ms-filter": "blur(0)", filter: "blur(0)" }), $(".drilldown-filter-values:has(a)").css("display", "none");
})
$(document).ready(function () {
$("#drilldown-header").next().remove(),
$('<br /><h3 class="drilldown-pre-header">1. Selected Filters</h3>').insertBefore("#drilldown-header"),
$('<h3 class="drilldown-pre-filters">2. Availble Filters</h3>').insertBefore(".drilldown-filters"),
$('<h3 class="drilldown-post-filters">3. Filtered Results</h3>').insertAfter(".drilldown-filters"),
$(
'<htmL><div class="button-wrapper"><a class="btn btn-sm drilldown-btn-test thar-three" href="javascript:;" onclick="drilldownswitcher()" id="drilldown-switch">Expand all filters <i class="fa fa-plus"></i></a></div></html>'
).insertBefore(".drilldown-filters");
})
$(document).ready(function () {
$(".drilldown-values-toggle").each(function () {
$("img").each(function () {
$(this).attr("src", $(this).attr("src").replace("down-arrow.png", "right-arrow.png"));
});
});
})