123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279 |
- @import "../../themes/ionic.globals.md";
-
- // Material Design Card
- // --------------------------------------------------
-
- /// @prop - Margin top of the card
- $card-md-margin-top: 10px !default;
-
- // deprecated
- $card-md-margin-right: 10px !default;
- /// @prop - Margin end of the card
- $card-md-margin-end: $card-md-margin-right !default;
-
- /// @prop - Margin bottom of the card
- $card-md-margin-bottom: 10px !default;
-
- // deprecated
- $card-md-margin-left: 10px !default;
- /// @prop - Margin start of the card
- $card-md-margin-start: $card-md-margin-left !default;
-
-
- /// @prop - Padding top of the card
- $card-md-padding-top: 13px !default;
-
- // deprecated
- $card-md-padding-right: 16px !default;
- /// @prop - Padding right of the card
- $card-md-padding-end: $card-md-padding-right !default;
-
- /// @prop - Padding bottom of the card
- $card-md-padding-bottom: 13px !default;
-
- // deprecated
- $card-md-padding-left: 16px !default;
- /// @prop - Padding start of the card
- $card-md-padding-start: $card-md-padding-left !default;
-
- /// @prop - Padding top of the media on the card
- $card-md-padding-media-top: 10px !default;
-
- /// @prop - Padding bottom of the media on the card
- $card-md-padding-media-bottom: 10px !default;
-
- /// @prop - Size of the card avatar
- $card-md-avatar-size: 4rem !default;
-
- /// @prop - Size of the card thumbnail
- $card-md-thumbnail-size: 8rem !default;
-
- /// @prop - Background color of the card
- $card-md-background-color: $list-md-background-color !default;
-
- /// @prop - Box shadow of the card
- $card-md-box-shadow: 0 2px 2px 0 rgba(0, 0, 0, .14), 0 3px 1px -2px rgba(0, 0, 0, .2), 0 1px 5px 0 rgba(0, 0, 0, .12) !default;
-
- /// @prop - Border radius of the card
- $card-md-border-radius: 2px !default;
-
-
- /// @prop - Font size of the card
- $card-md-font-size: 1.4rem !default;
-
- /// @prop - Line height of the card
- $card-md-line-height: 1.5 !default;
-
- /// @prop - Color of the card text
- $card-md-text-color: #222 !default;
-
- /// @prop - Font size of the card title
- $card-md-title-font-size: 2.4rem !default;
-
- // deprecated
- $card-md-title-padding: null !default;
-
- /// @prop - Padding top of the card title
- $card-md-title-padding-top: 8px !default;
-
- /// @prop - Padding end of the card title
- $card-md-title-padding-end: 0 !default;
-
- /// @prop - Padding bottom of the card title
- $card-md-title-padding-bottom: 8px !default;
-
- /// @prop - Padding start of the card title
- $card-md-title-padding-start: 0 !default;
-
- // deprecated
- $card-md-title-margin: null !default;
-
- /// @prop - Margin top of the card title
- $card-md-title-margin-top: 2px !default;
-
- /// @prop - Margin end of the card title
- $card-md-title-margin-end: 0 !default;
-
- /// @prop - Margin bottom of the card title
- $card-md-title-margin-bottom: 2px !default;
-
- /// @prop - Margin start of the card title
- $card-md-title-margin-start: $card-md-title-margin-end !default;
-
- /// @prop - Color of the card title
- $card-md-title-text-color: #222 !default;
-
- /// @prop - Font size of the card header
- $card-md-header-font-size: 1.6rem !default;
-
- // deprecated
- $card-md-header-padding: null !default;
-
- /// @prop - Padding top of the card header
- $card-md-header-padding-top: 16px !default;
-
- /// @prop - Padding end of the card header
- $card-md-header-padding-end: $card-md-header-padding-top !default;
-
- /// @prop - Padding bottom of the card header
- $card-md-header-padding-bottom: $card-md-header-padding-top !default;
-
- /// @prop - Padding start of the card header
- $card-md-header-padding-start: $card-md-header-padding-end !default;
-
- /// @prop - Color of the card header
- $card-md-header-color: #222 !default;
-
-
- .card-md {
- @include margin($card-md-margin-top, $card-md-margin-end, $card-md-margin-bottom, $card-md-margin-start);
- @include border-radius($card-md-border-radius);
-
- width: calc(100% - #{($card-md-margin-end + $card-md-margin-start)});
-
- font-size: $card-md-font-size;
-
- background: $card-md-background-color;
- box-shadow: $card-md-box-shadow;
- }
-
- .card-md ion-list {
- @include margin(null, null, 0, null);
- }
-
- .card-md > .item:last-child,
- .card-md > .item:last-child .item-inner,
- .card-md > .item-wrapper:last-child .item {
- border-bottom: 0;
- }
-
- .card-md .item-md.item-block .item-inner {
- border: 0;
- }
-
- .card-content-md {
- @include padding($card-md-padding-top, $card-md-padding-end, $card-md-padding-bottom, $card-md-padding-start);
-
- font-size: $card-md-font-size;
- line-height: $card-md-line-height;
- }
-
- .card-header-md {
- font-size: $card-md-header-font-size;
- color: $card-md-header-color;
-
- @include deprecated-variable(padding, $card-md-header-padding) {
- @include padding($card-md-header-padding-top, $card-md-header-padding-end, $card-md-header-padding-bottom, $card-md-header-padding-start);
- }
- }
-
- .card-header-md + .card-content-md,
- .card-md .item + .card-content-md {
- @include padding(0, null, null, null);
- }
-
- .card .note-md {
- font-size: 1.3rem;
- }
-
- .card-title-md {
- display: block;
-
- font-size: $card-md-title-font-size;
- line-height: 1.2;
- color: $card-md-title-text-color;
-
- @include deprecated-variable(margin, $card-md-title-margin) {
- @include margin($card-md-title-margin-top, $card-md-title-margin-end, $card-md-title-margin-bottom, $card-md-title-margin-start);
- }
-
- @include deprecated-variable(padding, $card-md-title-padding) {
- @include padding($card-md-title-padding-top, $card-md-title-padding-end, $card-md-title-padding-bottom, $card-md-title-padding-start);
- }
- }
-
- .card-md h1 {
- @include margin(0, 0, 2px);
-
- font-size: 2.4rem;
- font-weight: normal;
- color: $card-md-text-color;
- }
-
- .card-md h2 {
- @include margin(2px, 0);
-
- font-size: 1.6rem;
- font-weight: normal;
- color: $card-md-text-color;
- }
-
- .card-md h3,
- .card-md h4,
- .card-md h5,
- .card-md h6 {
- @include margin(2px, 0);
-
- font-size: 1.4rem;
- font-weight: normal;
- color: $card-md-text-color;
- }
-
- .card-md p {
- @include margin(0, 0, 2px);
-
- font-size: 1.4rem;
- font-weight: normal;
- line-height: 1.5;
- color: $card-md-text-color;
- }
-
- .card-md + ion-card {
- @include margin(0, null, null, null);
- }
-
-
- // Generate Material Design Card Colors
- // --------------------------------------------------
-
- @each $color-name, $color-base, $color-contrast in get-colors($colors-md) {
-
- .card-md .text-md-#{$color-name} {
- color: $color-base;
- }
-
- .card-md-#{$color-name} {
- color: $color-contrast;
- background-color: $color-base;
-
- .card-header-md,
- .card-title-md,
- .card-content-md,
- h1,
- h2,
- h3,
- h4,
- h5,
- h6,
- p {
- color: $color-contrast;
- }
-
- @each $color-name, $color-base, $color-contrast in get-colors($colors-md) {
- .text-md-#{$color-name},
- .card-header-md-#{$color-name},
- .card-title-md-#{$color-name},
- .card-content-md-#{$color-name} {
- color: $color-base;
- }
- }
- }
-
- .card-header-md-#{$color-name},
- .card-title-md-#{$color-name},
- .card-content-md-#{$color-name} {
- color: $color-base;
- }
-
- }
|