2019-10-09 11:42:53 +02:00
|
|
|
/*
|
|
|
|
* 2. Cards and containers
|
|
|
|
* All elements that are supposed to contain other stuff
|
|
|
|
*
|
|
|
|
*
|
|
|
|
*/
|
|
|
|
|
2019-12-07 16:06:38 +01:00
|
|
|
$card-bigpad: $lineheight;
|
|
|
|
$card-smallpad: $lineheight_half;
|
2019-10-09 11:42:53 +02:00
|
|
|
|
2021-07-25 14:12:29 +02:00
|
|
|
@mixin card-color($background-color) {
|
2019-12-07 16:06:38 +01:00
|
|
|
& .card-header, & .menu-header {
|
2021-07-28 18:05:39 +02:00
|
|
|
@include colorize-shape($background-color);
|
2021-07-28 17:45:24 +02:00
|
|
|
color:getTextColorFromBackground($background-color);
|
2019-10-09 11:42:53 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2021-07-30 12:09:47 +02:00
|
|
|
.card {
|
2021-07-30 11:37:23 +02:00
|
|
|
@include panel($card-bigpad);
|
2021-07-29 11:59:25 +02:00
|
|
|
display: flex;
|
|
|
|
flex-direction: column;
|
2019-10-09 11:42:53 +02:00
|
|
|
|
2019-10-17 14:04:20 +02:00
|
|
|
&-body {
|
|
|
|
padding:0!important;
|
2019-10-09 11:42:53 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
&-header {
|
2021-07-30 11:37:23 +02:00
|
|
|
@include panel-header($card-bigpad);
|
2020-11-08 20:17:49 +01:00
|
|
|
.fa {
|
|
|
|
margin-right: 0.5em;
|
|
|
|
}
|
2019-10-09 11:42:53 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2019-10-18 15:26:26 +02:00
|
|
|
/* CARD LIST - Make a list part of a card */
|
|
|
|
|
|
|
|
|
|
|
|
@mixin list-symbol($symbol) {
|
|
|
|
li.list-element {
|
|
|
|
list-style: none;
|
|
|
|
&::before {
|
|
|
|
font-family: "ForkAwesome";
|
|
|
|
content:$symbol;
|
2019-12-07 16:06:38 +01:00
|
|
|
padding-right:$lineheight_half;
|
2019-10-18 15:26:26 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
@mixin list-color($color) {
|
|
|
|
li.list-element {
|
|
|
|
&::before {
|
|
|
|
color: $color;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2021-07-24 16:59:42 +02:00
|
|
|
ul.card-list, .card > ul {
|
2019-10-18 15:26:26 +02:00
|
|
|
padding:0;
|
|
|
|
margin:0;
|
|
|
|
li.list-element {
|
2019-12-07 16:06:38 +01:00
|
|
|
line-height:$lineheight;
|
|
|
|
padding-right:$lineheight_half;
|
|
|
|
padding-left:$lineheight_quarter;
|
|
|
|
padding-top:$lineheight_quarter;
|
|
|
|
padding-bottom:$lineheight_quarter;
|
2019-10-18 15:26:26 +02:00
|
|
|
margin:0;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
.list {
|
|
|
|
&-check {@include list-symbol("\f00c");}
|
|
|
|
&-cross {@include list-symbol("\f00d");}
|
|
|
|
|
|
|
|
&-danger{@include list-color($color-danger);}
|
|
|
|
&-success{@include list-color($color-success);}
|
|
|
|
}
|
|
|
|
|
2019-10-17 14:04:20 +02:00
|
|
|
.smallcard, .toast {
|
2021-07-30 11:37:23 +02:00
|
|
|
@include panel($card-smallpad);
|
2019-10-17 14:04:20 +02:00
|
|
|
&-header {
|
2021-07-30 11:37:23 +02:00
|
|
|
@include panel-header($card-bigpad);
|
2019-10-17 14:04:20 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2021-07-29 11:59:25 +02:00
|
|
|
.toast {
|
|
|
|
padding:$card-smallpad,
|
|
|
|
}
|
|
|
|
|
2019-10-09 11:42:53 +02:00
|
|
|
/* COLORIZE CARDS and TOASTS */
|
|
|
|
|
|
|
|
.card, .smallcard, .menu {
|
2021-07-25 14:12:29 +02:00
|
|
|
@each $name, $color in list-colors() {
|
|
|
|
&-#{$name} { @include card-color(get-color($name)); }
|
|
|
|
}
|
2019-10-09 11:42:53 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
.toast {
|
2021-07-25 14:12:29 +02:00
|
|
|
@each $name, $color in list-colors() {
|
|
|
|
&-#{$name} { @include background-color(get-color($name)); }
|
|
|
|
}
|
2021-07-24 16:59:42 +02:00
|
|
|
|
|
|
|
a, a:visited {
|
2021-07-25 14:12:29 +02:00
|
|
|
color: $color-font-light;
|
2021-07-24 16:59:42 +02:00
|
|
|
background-color:rgba(0,0,0,0.15);
|
|
|
|
text-decoration:none;
|
|
|
|
opacity:1;
|
|
|
|
&:hover, &:active, &:visited {
|
2021-07-25 14:12:29 +02:00
|
|
|
color: $color-font-light;
|
2021-07-24 16:59:42 +02:00
|
|
|
background-color:transparent;
|
|
|
|
opacity:1;
|
|
|
|
}
|
|
|
|
}
|
2019-12-07 16:06:38 +01:00
|
|
|
}
|