mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2026-03-13 10:22:08 +08:00
refactor(list): cleaned up some SCSS in MD mode and fixed the no lines
references #437
This commit is contained in:
@@ -238,6 +238,7 @@ ion-card {
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/**************/
|
||||
/* INSET LIST */
|
||||
/**************/
|
||||
@@ -280,6 +281,7 @@ ion-card {
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/*****************/
|
||||
/* NO LINES LIST */
|
||||
/*****************/
|
||||
|
||||
@@ -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;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user