MediaWiki:Common.css
跳转到导航
跳转到搜索
注意:在发布之后,您可能需要清除浏览器缓存才能看到所作出的变更的影响。
- Firefox或Safari:按住Shift的同时单击刷新,或按Ctrl-F5或Ctrl-R(Mac为⌘-R)
- Google Chrome:按Ctrl-Shift-R(Mac为⌘-Shift-R)
- Internet Explorer或Edge:按住Ctrl的同时单击刷新,或按Ctrl-F5
- Opera:按 Ctrl-F5。
/* 这里放置的CSS将应用于所有皮肤 */
/* Reset some default styles */
body, h1, h2, h3, p, ul, li {
margin: 0;
padding: 0;
}
body {
font-family: Arial, sans-serif;
background-color: #f9f9f9;
}
/* Layout structure */
#mw-content-text {
display: flex;
}
#sidebar {
width: 240px;
background-color: #fff;
border-right: 1px solid #e3e3e3;
padding: 15px;
box-shadow: 0 2px 4px rgba(0,0,0,0.1);
height: 100vh; /* Full viewport height */
position: sticky;
top: 0;
}
#main-content {
flex-grow: 1;
padding: 20px;
background-color: #fafafa;
margin-left: 260px; /* To offset the sidebar width */
}
h1, h2, h3 {
color: #282828;
}
/* Sidebar style */
#sidebar ul {
list-style-type: none;
padding: 0;
margin: 0;
}
#sidebar ul li {
margin: 10px 0;
}
#sidebar ul li a {
text-decoration: none;
color: #065fd4;
font-weight: bold;
}
#sidebar ul li a:hover {
text-decoration: underline;
}
/* Main content style */
#main-content h1 {
font-size: 24px;
margin-bottom: 20px;
}
#main-content p {
line-height: 1.6;
color: #606060;
}
/* Footer style */
#footer {
text-align: center;
padding: 20px;
background-color: #fff;
border-top: 1px solid #e3e3e3;
margin-top: 20px;
font-size: 14px;
color: #909090;
}