MediaWiki:Common.css: различия между версиями
Страница интерфейса MediaWiki
Дополнительные действия
Нет описания правки |
Нет описания правки |
||
| Строка 4: | Строка 4: | ||
} | } | ||
body::before | /* ===== ОБЩИЕ СТИЛИ ДЛЯ ФОНОВОГО ИЗОБРАЖЕНИЯ ===== */ | ||
body::before { | |||
content: ''; | content: ''; | ||
position: fixed; | position: fixed; | ||
| Строка 15: | Строка 16: | ||
background-position: center center; | background-position: center center; | ||
background-size: 50% auto; | background-size: 50% auto; | ||
z-index: 0; | z-index: 0; | ||
} | |||
/* ===== РЕЖИМ ПО УМОЛЧАНИЮ (СВЕТЛАЯ ТЕМА) ===== */ | |||
@media screen { | |||
html.skin-theme-clientpref-light .pane, | |||
html.skin-theme-clientpref-os .pane { | |||
background-color: white; | |||
color: black; | |||
} | |||
/* Стили для фона в светлой теме */ | |||
html.skin-theme-clientpref-light body::before, | |||
html.skin-theme-clientpref-os body::before { | |||
filter: invert(100%) grayscale(100%) opacity(0.03); | |||
/* Белый SVG → черный → очень прозрачный серый */ | |||
} | |||
} | } | ||
/* ===== ТЕМНАЯ ТЕМА ===== */ | |||
@media screen { | |||
html.skin-theme-clientpref-night .pane { | |||
background-color: black; | |||
color: white; | |||
} | |||
/* Стили для фона в темной теме */ | |||
html.skin-theme-clientpref-night body::before { | |||
filter: grayscale(100%) brightness(110%) opacity(0.05); | |||
/* Белый SVG → немного brighter белый → прозрачный */ | |||
} | |||
} | |||
@media (prefers-color-scheme: | /* ===== АВТОМАТИЧЕСКИЙ РЕЖИМ (ОС Preference) ===== */ | ||
body::before { | @media screen and (prefers-color-scheme: dark) { | ||
filter: grayscale(100%) brightness( | html.skin-theme-clientpref-os .pane { | ||
background-color: black; | |||
color: white; | |||
} | |||
/* Стили для фона в автоматическом режиме (темная ОС) */ | |||
html.skin-theme-clientpref-os body::before { | |||
filter: grayscale(100%) brightness(110%) opacity(0.05); | |||
} | } | ||
} | } | ||
@media screen and (prefers-color-scheme: light) { | |||
html.skin-theme-clientpref-os .pane { | |||
background-color: white; | |||
color: black; | |||
} | |||
/* Стили для фона в автоматическом режиме (светлая ОС) */ | |||
html.skin-theme-clientpref-os body::before { | |||
filter: invert(100%) grayscale(100%) opacity(0.03); | |||
} | |||
} | |||
.tooltip{ | .tooltip{ | ||
Версия от 04:26, 24 августа 2025
/* Размещённый здесь CSS будет применяться ко всем темам оформления */
body {
position: relative;
}
/* ===== ОБЩИЕ СТИЛИ ДЛЯ ФОНОВОГО ИЗОБРАЖЕНИЯ ===== */
body::before {
content: '';
position: fixed;
top: 0;
left: 0;
width: 100%;
height: 100%;
background-image: url('/images/8/83/Bglogo.svg');
background-repeat: no-repeat;
background-position: center center;
background-size: 50% auto;
z-index: 0;
}
/* ===== РЕЖИМ ПО УМОЛЧАНИЮ (СВЕТЛАЯ ТЕМА) ===== */
@media screen {
html.skin-theme-clientpref-light .pane,
html.skin-theme-clientpref-os .pane {
background-color: white;
color: black;
}
/* Стили для фона в светлой теме */
html.skin-theme-clientpref-light body::before,
html.skin-theme-clientpref-os body::before {
filter: invert(100%) grayscale(100%) opacity(0.03);
/* Белый SVG → черный → очень прозрачный серый */
}
}
/* ===== ТЕМНАЯ ТЕМА ===== */
@media screen {
html.skin-theme-clientpref-night .pane {
background-color: black;
color: white;
}
/* Стили для фона в темной теме */
html.skin-theme-clientpref-night body::before {
filter: grayscale(100%) brightness(110%) opacity(0.05);
/* Белый SVG → немного brighter белый → прозрачный */
}
}
/* ===== АВТОМАТИЧЕСКИЙ РЕЖИМ (ОС Preference) ===== */
@media screen and (prefers-color-scheme: dark) {
html.skin-theme-clientpref-os .pane {
background-color: black;
color: white;
}
/* Стили для фона в автоматическом режиме (темная ОС) */
html.skin-theme-clientpref-os body::before {
filter: grayscale(100%) brightness(110%) opacity(0.05);
}
}
@media screen and (prefers-color-scheme: light) {
html.skin-theme-clientpref-os .pane {
background-color: white;
color: black;
}
/* Стили для фона в автоматическом режиме (светлая ОС) */
html.skin-theme-clientpref-os body::before {
filter: invert(100%) grayscale(100%) opacity(0.03);
}
}
.tooltip{
position: relative;
}
.tooltiptext,
.tooltiptext2 {
position: absolute;
width: 18em;
visibility: hidden;
opacity: 0;
white-space: normal;
text-align: left;
transition: all 0.2s;
border: 1px solid #aaa;
}
.tooltiptext {
display: block;
z-index: 2;
padding: 20px;
background-color: #ffdd66;
}
.tooltiptext2 {
display:inline;
z-index: 100;
padding: 0.2em;
background-color: #FEF6E7;
border-radius: .2em;
top:1.5em;
left:1em;
box-shadow: 0 0 .3em #999;
}
.tooltiptable {
position: absolute;
display: block;
z-index: 2;
max-width:600px;
width:max-content;
padding: 10px;
top:11pt;
right:-55px;
visibility: hidden;
opacity: 0;
white-space: normal;
text-align: left;
transition: all 0.2s;
border: 1px solid #666;
background-color: #ff6666;
}
.tooltip:hover>.tooltiptext,
.tooltip:hover>.tooltiptext2,
.tooltip:hover>.tooltiptable {
visibility: visible;
opacity: 1;
}
img {
image-rendering: optimizeSpeed;
image-rendering: -webkit-optimize-contrast;
image-rendering: optimize-contrast;
image-rendering: -moz-crisp-edges;
image-rendering: -o-crisp-edges;
image-rendering: crisp-edges;
image-rendering: pixelated;
-ms-interpolation-mode: nearest-neighbor;
}
/* Кнопка "Вверх": [[Файл:Scroll_top.png]] */
#scroll-top
{
display: none;
background: url(/images/f/f4/Scroll_top.gif) 0% 0%/56px 56px no-repeat;
opacity: 0.3;
width: 76px;
height: 76px;
cursor: pointer;
position: fixed;
left: calc(11em - 56px);
bottom: 30px;
z-index: 10000;
image-rendering: optimizeSpeed;
image-rendering: -webkit-optimize-contrast;
image-rendering: optimize-contrast;
image-rendering: -moz-crisp-edges;
image-rendering: -o-crisp-edges;
image-rendering: crisp-edges;
image-rendering: pixelated;
-ms-interpolation-mode: nearest-neighbor;
}
#scroll-top:hover
{
opacity: 0.8;
}
/* Дальше зона SweetMaurse, ничего не сломается. А если сломается я починю.*/
:root {
/* Civilian colors - светлая тема */
--civilian-opaque: #3498db;
--civilian-primary: #2980b9;
--civilian-secondary: #1f6390;
--civilian-light: #5dade2;
--civilian-transparent: rgba(52, 152, 219, 0.7);
}
/* Темная тема */
@media (prefers-color-scheme: dark) {
:root {
--civilian-opaque: #2c3e50;
--civilian-primary: #34495e;
--civilian-secondary: #2c3e50;
--civilian-light: #4a6572;
--civilian-transparent: rgba(44, 62, 80, 0.7);
}
}