样式表使用类名,移除使用ID的样式

This commit is contained in:
Argo-Lenovo 2016-11-24 19:21:10 +08:00
parent f3d72f9a2d
commit f7681d02f0
5 changed files with 17 additions and 20 deletions

View File

@ -11,22 +11,22 @@
}
@media (max-width: 768px) {
#sidebar {
.sidebar {
display: none;
overflow-y: auto;
width: 100%;
z-index: 5;
}
#sidebar ul li a {
.sidebar ul li a {
padding-right: 25px;
}
#main-content {
.main-content {
margin-left: 0;
}
#main-content.open {
.main-content.open {
display: none;
}
@ -97,7 +97,7 @@
}
@media (min-width: 768px) {
#sidebar {
.sidebar {
top: 94px;
bottom: 40px;
position: absolute;
@ -106,7 +106,7 @@
}
@media (min-height: 672px) {
#sidebar {
.sidebar {
top: 94px;
bottom: 40px;
position: absolute;

View File

@ -122,34 +122,34 @@
border-color: #3c763d;
}
#main-content {
.main-content {
padding: 15px 15px 0 15px;
margin-left: 210px;
height: auto;
}
#main-content > .panel:last-child .panel-body {
.main-content > .panel:last-child .panel-body {
padding-bottom: 0;
}
#main-content > .panel > .panel-body > .modal-footer {
.main-content > .panel > .panel-body > .modal-footer {
text-align: left;
}
#main-content.closed {
.main-content.closed {
margin-left: 0;
}
#sidebar {
.sidebar {
width: 210px;
background: #2a3542;
}
#sidebar .sub-menu > .sub li {
.sidebar .sub-menu > .sub li {
padding-left: 32px;
}
#sidebar ul li {
.sidebar ul li {
position: relative;
}

View File

@ -1,7 +1,4 @@
@media (max-width: 930px) {
/*#main-content {
margin: 0px !important;
}*/
}
@media (max-width: 666px) {
@ -47,7 +44,7 @@
z-index: 50;
}
#main-content {
.main-content {
margin-top: 0;
position: fixed;
left: 0;
@ -72,7 +69,7 @@
z-index: 50;
}
#main-content {
.main-content {
margin-top: 0;
position: fixed;
left: 0;

View File

@ -1,6 +1,6 @@
@model NavigatorBarModel
<aside>
<div id="sidebar" class="nav-collapse">
<div id="sidebar" class="nav-collapse sidebar">
<!-- sidebar menu start-->
<ul class="sidebar-menu" id="nav-accordion">
@foreach (var menu in Model.Navigations)

View File

@ -21,7 +21,7 @@
<section>
@RenderSection("header", false)
@RenderSection("navigator", false)
<section id="main-content">
<section id="main-content" class="main-content">
@RenderBody()
</section>
@Html.Partial("Footer")