SHEGARE (обсуждение | вклад) Нет описания правки |
SHEGARE (обсуждение | вклад) Нет описания правки |
||
| Строка 2: | Строка 2: | ||
function foo(el) { | function foo(el) { | ||
console.log(el.querySelector('.mw-headline')) | console.log(el.querySelector('.mw-headline')) | ||
console.log(el.querySelector('.citizen-section-indicator')) | console.log(el.querySelector('.citizen-sections-enabled,.citizen-section-indicator')) | ||
if (el.querySelector('.mw-headline') !== null) { | if (el.querySelector('.mw-headline') !== null) { | ||
el.querySelector('.mw-headline').style.borderImage = 'linear-gradient(to right top, red, red, red)'; | el.querySelector('.mw-headline').style.borderImage = 'linear-gradient(to right top, red, red, red)'; | ||
Версия от 10:13, 22 сентября 2024
if(document.getElementsByClassName('colorHeader').length >= 1) {
function foo(el) {
console.log(el.querySelector('.mw-headline'))
console.log(el.querySelector('.citizen-sections-enabled,.citizen-section-indicator'))
if (el.querySelector('.mw-headline') !== null) {
el.querySelector('.mw-headline').style.borderImage = 'linear-gradient(to right top, red, red, red)';
el.querySelector('.mw-headline').style.borderImageSlice = '1';
}
}
document.querySelectorAll('h1, h2, h3 , h4, h5').forEach(foo);
}
// Лого сайта
document.getElementsByClassName('citizen-header__logo')[0].innerHTML = '<div class="logo1"><a href="https://spacestories.club/index.php?title=Заглавная страница" class="mw-logo citizen-header__button" title="Перейти на заглавную страницу"><img class="mw-logo-icon" src="/resources/assets/logo.png" alt="" aria-hidden="true" height="32" width="32"</a></div><div class="logo2"><a href="https://spacestories.club/index.php?title=Colonial_Marines" class="mw-logo citizen-header__button" title="Перейти на заглавную страницу CM"><img class="mw-logo-icon" src="/images/0/0d/CMlog.png" alt="" aria-hidden="true" height="32" width="32"></a></div>';
// Для поиска и применения стилей к .citizen-table-wrapper
document.querySelectorAll('.citizen-table-wrapper').forEach(function(wrapper) {
if (wrapper.querySelector('.job_gear')) {
wrapper.style.overflowX = 'unset'; // Применяем стиль
}
});
// Для поиска и применения стилей к .citizen-overflow--right
document.querySelectorAll('.citizen-overflow--right').forEach(function(overflowRight) {
if (overflowRight.querySelector('.job_gear')) {
overflowRight.style.webkitMaskImage = 'unset'; // Для WebKit браузеров (Safari)
overflowRight.style.maskImage = 'unset'; // Для остальных браузеров
}
});