MediaWiki:Vector.css: Difference between revisions
Appearance
Created page with "→All CSS here will be loaded for users of the Vector skin: →Make sidebar sticky: #mw-panel { position: sticky; top: 0; z-index: 100; height: 100vh; overflow-y: auto; background-color: #f8f9fa; →Optional: matches skin: padding-top: 1em; }" |
No edit summary |
||
Line 1: | Line 1: | ||
/* All CSS here will be loaded for users of the Vector skin */ | /* All CSS here will be loaded for users of the Vector skin */ | ||
/* Make sidebar sticky */ | /* Make sidebar sticky */ | ||
#mw-panel { | #mw-panel { | ||
Line 9: | Line 10: | ||
background-color: #f8f9fa; /* Optional: matches skin */ | background-color: #f8f9fa; /* Optional: matches skin */ | ||
padding-top: 1em; | padding-top: 1em; | ||
} | |||
/* Center and style the main page logo */ | |||
.mainpage-logo { | |||
text-align: center; | |||
margin: 20px 0; | |||
} | |||
.mainpage-logo img { | |||
max-width: 100%; | |||
height: auto; | |||
} | |||
/* Responsive tables */ | |||
table { | |||
width: 100%; | |||
overflow-x: auto; | |||
display: block; | |||
} | |||
/* Responsive layout adjustments */ | |||
@media (max-width: 768px) { | |||
#mw-head-base, | |||
#mw-panel, | |||
#mw-navigation { | |||
display: none; /* Optional: hide sidebars on small screens */ | |||
} | |||
#content, | |||
#bodyContent { | |||
margin: 0; | |||
padding: 10px; | |||
width: 100%; | |||
} | |||
h1, h2, h3 { | |||
font-size: 1.5em; | |||
} | |||
.mainpage-logo img { | |||
width: 100%; | |||
height: auto; | |||
} | |||
body, .mw-body { | |||
font-size: 14px; | |||
line-height: 1.6; | |||
} | |||
h1, h2, h3, h4 { | |||
margin-top: 20px; | |||
margin-bottom: 10px; | |||
} | |||
pre, code { | |||
white-space: pre-wrap; | |||
word-break: break-word; | |||
} | |||
.mw-body, | |||
.mw-content-ltr, | |||
#content { | |||
box-sizing: border-box; | |||
padding: 10px; | |||
width: 100%; | |||
} | |||
.vector-menu-portal { | |||
display: none !important; | |||
} | |||
} | } |
Latest revision as of 06:47, 17 May 2025
/* All CSS here will be loaded for users of the Vector skin */ /* Make sidebar sticky */ #mw-panel { position: sticky; top: 0; z-index: 100; height: 100vh; overflow-y: auto; background-color: #f8f9fa; /* Optional: matches skin */ padding-top: 1em; } /* Center and style the main page logo */ .mainpage-logo { text-align: center; margin: 20px 0; } .mainpage-logo img { max-width: 100%; height: auto; } /* Responsive tables */ table { width: 100%; overflow-x: auto; display: block; } /* Responsive layout adjustments */ @media (max-width: 768px) { #mw-head-base, #mw-panel, #mw-navigation { display: none; /* Optional: hide sidebars on small screens */ } #content, #bodyContent { margin: 0; padding: 10px; width: 100%; } h1, h2, h3 { font-size: 1.5em; } .mainpage-logo img { width: 100%; height: auto; } body, .mw-body { font-size: 14px; line-height: 1.6; } h1, h2, h3, h4 { margin-top: 20px; margin-bottom: 10px; } pre, code { white-space: pre-wrap; word-break: break-word; } .mw-body, .mw-content-ltr, #content { box-sizing: border-box; padding: 10px; width: 100%; } .vector-menu-portal { display: none !important; } }