refactor(list): cleaned up some SCSS in MD mode and fixed the no lines

references #437
This commit is contained in:
Brandy Carney
2015-11-05 19:51:36 -05:00
parent f9d1049029
commit 1a00458b7c
2 changed files with 33 additions and 23 deletions

View File

@@ -238,6 +238,7 @@ ion-card {
}
}
/**************/
/* INSET LIST */
/**************/
@@ -280,6 +281,7 @@ ion-card {
}
}
/*****************/
/* NO LINES LIST */
/*****************/

View File

@@ -18,6 +18,10 @@ $list-md-header-font-size: 1.4rem !default;
$list-md-header-color: #858585 !default;
/****************/
/* DEFAULT LIST */
/****************/
.list {
margin: 0 $list-md-margin-right $list-md-margin-bottom $list-md-margin-left;
@@ -27,16 +31,20 @@ $list-md-header-color: #858585 !default;
color: $list-md-header-color;
}
+ .list {
margin-top: $list-md-margin-top + $list-md-margin-bottom;
ion-header {
margin-top: -$list-md-margin-top;
padding-top: 0;
}
}
}
.list + .list {
margin-top: $list-md-margin-top + $list-md-margin-bottom;
}
.list + .list ion-header {
margin-top: -$list-md-margin-top;
padding-top: 0;
}
/**************/
/* INSET LIST */
/**************/
.list[inset] {
margin: $list-inset-md-margin-top $list-inset-md-margin-right $list-inset-md-margin-bottom $list-inset-md-margin-left;
@@ -46,10 +54,6 @@ $list-md-header-color: #858585 !default;
margin-top: 0;
border-top-right-radius: $list-inset-md-border-radius;
border-top-left-radius: $list-inset-md-border-radius;
&:before {
border-top: none;
}
}
.item:last-child {
@@ -57,23 +61,27 @@ $list-md-header-color: #858585 !default;
border-bottom-right-radius: $list-inset-md-border-radius;
border-bottom-left-radius: $list-inset-md-border-radius;
}
.item:not(ion-input):last-child:after {
border-top: none;
}
+ .list[inset] {
margin-top: 0;
}
}
.list[inset] .item:not(ion-input):last-child:after {
border-top: none;
}
.list[inset] + .list[inset] {
margin-top: 0;
}
/*****************/
/* NO LINES LIST */
/*****************/
.list[no-lines] {
ion-header + .item:before {
border-width: 1px;
}
.item:before,
.item:after {
.item {
border-width: 0;
}
ion-header + .item {
border-width: 1px !important;
}
}