mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-18 11:17:19 +08:00
202 lines
4.4 KiB
SCSS
202 lines
4.4 KiB
SCSS
@import "../../../ionic.globals";
|
|
@import "../item";
|
|
|
|
// Material Design Item
|
|
// --------------------------------------------------
|
|
|
|
$item-md-border-color: grayscale(lighten($list-border-color, 8%)) !default;
|
|
$item-md-activated-background-color: #f1f1f1 !default;
|
|
$item-md-font-size: 1.6rem !default;
|
|
|
|
$item-md-padding-top: 13px !default;
|
|
$item-md-padding-right: 16px !default;
|
|
$item-md-padding-bottom: 13px !default;
|
|
$item-md-padding-left: 16px !default;
|
|
|
|
$item-md-padding-media-top: 9px !default;
|
|
$item-md-padding-media-bottom: 9px !default;
|
|
|
|
$item-md-padding-icon-top: 11px !default;
|
|
$item-md-padding-icon-bottom: 10px !default;
|
|
|
|
$item-md-body-text-font-size: 1.4rem !default;
|
|
$item-md-body-text-line-height: 1.5 !default;
|
|
|
|
$item-md-avatar-size: 4rem !default;
|
|
$item-md-thumbnail-size: 8rem !default;
|
|
$item-md-note-color: darken($item-md-border-color, 10%) !default;
|
|
|
|
$item-md-divider-bg: #fff !default;
|
|
$item-md-divider-color: #222 !default;
|
|
$item-md-divider-padding: 5px 15px !default;
|
|
|
|
$item-md-sliding-content-bg: $background-color !default;
|
|
$item-md-sliding-transition: transform 250ms ease-in-out !default;
|
|
|
|
|
|
ion-item-divider {
|
|
padding: $item-md-padding-top $item-md-padding-right $item-md-padding-bottom $item-md-padding-left;
|
|
background-color: $item-md-divider-bg;
|
|
color: $item-md-divider-color;
|
|
}
|
|
|
|
ion-note {
|
|
color: $item-md-note-color;
|
|
}
|
|
|
|
.item {
|
|
position: relative;
|
|
padding-right: 0;
|
|
padding-left: ($item-md-padding-left);
|
|
font-size: $item-md-font-size;
|
|
text-transform: none;
|
|
font-weight: normal;
|
|
box-shadow: none;
|
|
|
|
h1 {
|
|
margin: 0 0 2px;
|
|
font-size: 2.4rem;
|
|
font-weight: normal;
|
|
}
|
|
|
|
h2 {
|
|
margin: 2px 0 2px;
|
|
font-size: 1.6rem;
|
|
font-weight: normal;
|
|
}
|
|
|
|
h3,
|
|
h4,
|
|
h5,
|
|
h6 {
|
|
line-height: normal;
|
|
margin: 2px 0 2px;
|
|
font-size: 1.4rem;
|
|
font-weight: normal;
|
|
}
|
|
|
|
p {
|
|
line-height: normal;
|
|
color: #666;
|
|
font-size: 1.4rem;
|
|
margin: 0 0 2px;
|
|
}
|
|
}
|
|
|
|
.item-inner {
|
|
border-bottom: 1px solid $item-md-border-color;
|
|
padding-right: ($item-md-padding-right / 2);
|
|
}
|
|
|
|
ion-item-content {
|
|
margin: $item-md-padding-top ($item-md-padding-right / 2) $item-md-padding-bottom 0;
|
|
}
|
|
|
|
button.item.activated {
|
|
box-shadow: none;
|
|
}
|
|
|
|
[item-left],
|
|
[item-right] {
|
|
margin: $item-md-padding-media-top ($item-md-padding-right / 2) $item-md-padding-media-bottom 0;
|
|
}
|
|
|
|
icon[item-left],
|
|
icon[item-right] {
|
|
margin-top: $item-md-padding-icon-top;
|
|
margin-left: 0;
|
|
margin-bottom: $item-md-padding-icon-bottom;
|
|
}
|
|
|
|
button[item-left],
|
|
button[item-right],
|
|
[button][item-left],
|
|
[button][item-right] {
|
|
padding: 0 0.6em;
|
|
min-height: 26px;
|
|
font-size: 1.2rem;
|
|
}
|
|
|
|
[item-left].icon-only,
|
|
[item-right].icon-only,
|
|
[item-left].icon-only icon,
|
|
[item-right].icon-only icon {
|
|
padding: 0 1px;
|
|
}
|
|
|
|
[item-left][clear],
|
|
[item-right][clear] {
|
|
padding: 0 8px;
|
|
}
|
|
|
|
[item-left].icon-left icon,
|
|
[item-right].icon-left icon {
|
|
margin-left: 0;
|
|
margin-bottom: 1px;
|
|
padding-right: 0.3em;
|
|
}
|
|
|
|
[item-left].icon-right icon,
|
|
[item-right].icon-right icon {
|
|
margin-right: 0;
|
|
margin-bottom: 1px;
|
|
}
|
|
|
|
[text-wrap] ion-item-content {
|
|
font-size: $item-md-body-text-font-size;
|
|
line-height: $item-md-body-text-line-height;
|
|
}
|
|
|
|
icon[item-left] + .item-inner,
|
|
icon[item-left] + [text-input] {
|
|
margin-left: $item-md-padding-left + ($item-md-padding-left / 2);
|
|
}
|
|
|
|
ion-avatar[item-left],
|
|
ion-thumbnail[item-left] {
|
|
margin: ($item-md-padding-right / 2) $item-md-padding-right ($item-md-padding-right / 2) 0;
|
|
}
|
|
|
|
ion-avatar[item-right],
|
|
ion-thumbnail[item-right] {
|
|
margin: ($item-md-padding-right / 2);
|
|
}
|
|
|
|
ion-avatar {
|
|
min-width: $item-md-avatar-size;
|
|
min-height: $item-md-avatar-size;
|
|
|
|
img {
|
|
max-width: $item-md-avatar-size;
|
|
max-height: $item-md-avatar-size;
|
|
border-radius: $item-md-avatar-size / 2;
|
|
}
|
|
}
|
|
|
|
ion-thumbnail {
|
|
min-width: $item-md-thumbnail-size;
|
|
min-height: $item-md-thumbnail-size;
|
|
|
|
img {
|
|
max-width: $item-md-thumbnail-size;
|
|
max-height: $item-md-thumbnail-size;
|
|
}
|
|
}
|
|
|
|
.item,
|
|
a.item,
|
|
button.item {
|
|
transition: background-color $button-md-transition-duration $button-md-animation-curve, transform 300ms;
|
|
}
|
|
|
|
.item.activated,
|
|
a.item.activated,
|
|
button.item.activated {
|
|
background-color: $item-md-activated-background-color;
|
|
box-shadow: none;
|
|
}
|
|
|
|
.item[no-lines] {
|
|
border-width: 0;
|
|
}
|