MediaWiki:Vector.css: различия между версиями
Shihov (обсуждение | вклад) Полностью удалено содержимое страницы Метка: очистка |
Shihov (обсуждение | вклад) Нет описания правки |
||
(не показано 7 промежуточных версий этого же участника) | |||
Строка 1: | Строка 1: | ||
.vector-legacy-sidebar { | |||
font-size: 0.8em !important; | |||
} | |||
/* Весь CSS будет отсюда будет загружен пользователям темы оформления «Векторная» */ | |||
.mw-content-ltr img { | |||
display: inline !important; | |||
} | |||
#p-logo a{ | |||
position: absolute !important; | |||
top: 10px !important; | |||
left: -70px !important; | |||
height: 60px !important; /* Ограниченная высота */ | |||
width: 500px !important; | |||
background-size: contain !important; | |||
} | |||
/* Увеличение ширины сайдбара */ | |||
/* Увеличение ширины сайдбара */ | |||
#mw-panel { | |||
width: 32em !important; | |||
} | |||
/* Сдвиг основного контента, чтобы учесть расширение сайдбара */ | |||
#content { | |||
margin-left: 27em !important; /* Немного больше, чтобы учесть отступы */ | |||
} | |||
#footer { | |||
margin-left: 30em !important; | |||
} | |||
#mw-panel .portal:first-child { | |||
order: -1; | |||
} | |||
/*.catlinks { display: none !important; } | |||
.mw-subcategories { | |||
display: none !important; | |||
}*/ | |||
/* Выравнивание текста при переносе */ | |||
.CategoryTreeChildren .CategoryTreeItem .CategoryTreePageBullet { | |||
margin-left: -1em; | |||
} | |||
#p-categorytree-portlet { | |||
top: -95px; | |||
background: linear-gradient(145deg, #f8f9fa, #e9ecef); | |||
border: 2px solid #cfd8dc !important; | |||
border-radius: 12px !important; | |||
padding: 15px !important; | |||
margin-bottom: 20px !important; | |||
box-shadow: 0 6px 12px rgba(0, 0, 0, 0.1), inset 0 2px 4px rgba(255, 255, 255, 0.6) !important; | |||
} | |||
#p-categorytree-portlet .vector-menu-heading { | |||
font-size: 1.4em !important; | |||
font-weight: 700 !important; | |||
color: #495057 !important; | |||
border-bottom: 2px dashed #adb5bd !important; | |||
padding-bottom: 8px !important; | |||
margin-bottom: 12px !important; | |||
text-shadow: 1px 1px 2px rgba(255, 255, 255, 0.8) !important; | |||
} | |||
#p-categorytree-portlet .vector-menu-content-list > li { | |||
margin: 10px 0 !important; | |||
padding: 12px !important; | |||
border: 1px solid #dee2e6 !important; | |||
border-radius: 10px !important; | |||
background: linear-gradient(145deg, #ffffff, #f1f3f5); | |||
transition: background 0.3s ease, transform 0.3s ease !important; | |||
box-shadow: 0 3px 6px rgba(0, 0, 0, 0.08), inset 0 1px 3px rgba(255, 255, 255, 0.6) !important; | |||
} | |||
#p-categorytree-portlet .vector-menu-content-list > li:hover { | |||
background: linear-gradient(145deg, #e9ecef, #dee2e6) !important; | |||
transform: translateY(-2px) !important; | |||
} | |||
#p-categorytree-portlet .CategoryTreeItem { | |||
margin: 6px 0 !important; | |||
padding: 10px !important; | |||
border: 1px solid #d1d9de !important; | |||
border-radius: 8px !important; | |||
background: linear-gradient(145deg, #fdfdfd, #f3f6f9); | |||
transition: transform 0.2s ease, background-color 0.3s ease !important; | |||
box-shadow: 0 4px 8px rgba(0, 0, 0, 0.08), inset 0 2px 4px rgba(255, 255, 255, 0.5) !important; | |||
} | |||
#p-categorytree-portlet .CategoryTreeItem:hover { | |||
background: linear-gradient(145deg, #ebf0f5, #e2e8ee) !important; | |||
transform: scale(1.03) !important; | |||
} | |||
#p-categorytree-portlet .CategoryTreeBullet a { | |||
font-size: 1em !important; | |||
color: #007bff !important; | |||
font-weight: 600 !important; | |||
text-decoration: none !important; | |||
transition: color 0.3s ease, text-shadow 0.3s ease !important; | |||
} | |||
#p-categorytree-portlet .CategoryTreeBullet a:hover { | |||
color: #0056b3 !important; | |||
text-shadow: 1px 1px 3px rgba(0, 123, 255, 0.5) !important; | |||
} | |||
#p-categorytree-portlet .CategoryTreeChildren { | |||
margin-left: 20px !important; | |||
border-left: 2px solid #d0d9de !important; | |||
padding-left: 12px !important; | |||
background: linear-gradient(145deg, #fcfcfc, #f1f3f5) !important; | |||
border-radius: 6px !important; | |||
} | |||
#p-categorytree-portlet a { | |||
color: #007bff !important; | |||
font-weight: 500 !important; | |||
text-decoration: none !important; | |||
transition: color 0.3s ease !important; | |||
} | |||
#p-categorytree-portlet a:hover { | |||
text-decoration: underline !important; | |||
color: #0056b3 !important; | |||
} | |||
/* Скрываем все элементы внутри основного текстового блока страницы категории */ | |||
.ns-14 .mw-category-generated { | |||
display: none !important; | |||
} | |||
/* Ограничение ширины изображений */ | |||
.mw-content-ltr img { | |||
max-width: 100% !important; | |||
height: auto !important; | |||
display: block; | |||
margin: 0 auto; | |||
} | |||
/* Ограничение ширины встроенных изображений */ | |||
.thumb img, | |||
.mw-file-element { | |||
max-width: 90% !important; | |||
height: auto !important; | |||
} | |||
.CategoryTreeItem { | |||
/* Ваши предыдущие стили */ | |||
cursor: pointer; /* Изменяем курсор при наведении */ | |||
} | |||
.CategoryTreeItem:hover { | |||
/* Ваши предыдущие стили для hover */ | |||
background: linear-gradient(145deg, #ebf0f5, #e2e8ee) !important; | |||
transform: scale(1.03) !important; | |||
} | |||
/* Сдвиг обсуждение */ | |||
#left-navigation { | |||
position: absolute !important; /* Абсолютное позиционирование */ | |||
z-index: 10 !important; /* Устанавливаем высокий z-index, чтобы был поверх */ | |||
left: 280px !important; /* Устанавливаем отступ слева */ | |||
} | |||
/* Промотка индексменю */ | |||
/* Контейнер категорий, добавляем прокрутку */ | |||
#p-categorytree-portlet { | |||
max-height: 900px !important; /* Ограничиваем высоту контейнера */ | |||
overflow-y: auto !important; /* Разрешаем прокрутку */ | |||
position: relative !important; | |||
} | |||
/* Добавляем градиентные маски для эффекта исчезновения */ | |||
#p-categorytree-portlet::before, | |||
#p-categorytree-portlet::after { | |||
content: "" !important; | |||
position: absolute !important; | |||
left: 0 !important; | |||
width: 100% !important; | |||
height: 30px !important; | |||
pointer-events: none !important; | |||
transition: opacity 0.3s ease-in-out !important; | |||
} | |||
#p-categorytree-portlet::before { | |||
top: 0 !important; | |||
background: linear-gradient(to bottom, rgba(248, 249, 250, 1), rgba(248, 249, 250, 0)) !important; | |||
opacity: 0 !important; | |||
} | |||
#p-categorytree-portlet::after { | |||
bottom: 0 !important; | |||
background: linear-gradient(to top, rgba(248, 249, 250, 1), rgba(248, 249, 250, 0)) !important; | |||
opacity: 0 !important; | |||
} | |||
/* Изменяем прозрачность при прокрутке */ | |||
#p-categorytree-portlet:hover { | |||
opacity: 1 !important; | |||
} | |||
/* Стиль для подсветки последнего открытого элемента */ | |||
/* Подсветка выбранного элемента, стилизуем так же, как hover */ | |||
.CategoryTreeItem.highlighted { | |||
background: linear-gradient(145deg, #ebf0f5, #e2e8ee) !important; | |||
transform: scale(1.03) !important; | |||
border: 2px solid #007bff !important; /* Синий контур для выделения */ | |||
} | |||
/* По умолчанию скрываем дерево категорий */ | |||
@media (max-width: 768px) { | |||
/* По умолчанию скрываем дерево категорий только на мобильных */ | |||
#p-categorytree-portlet { | |||
display: none; | |||
} | |||
/* Кнопка для раскрытия дерева */ | |||
#category-toggle { | |||
display: block; | |||
text-align: center; | |||
background: #007bff; | |||
color: white; | |||
padding: 8px 12px; | |||
border-radius: 6px; | |||
cursor: pointer; | |||
font-size: 14px; | |||
margin: 10px 0; | |||
transition: background 0.3s ease; | |||
} | |||
#category-toggle:hover { | |||
background: #0056b3; | |||
} | |||
} |