papercss/src/components/_modals.scss

80 lines
1.3 KiB
SCSS
Raw Normal View History

2017-12-06 17:12:17 +01:00
.modal{
2017-12-06 17:12:17 +01:00
&:before{
content: "";
2017-12-06 17:12:17 +01:00
display: none;
2017-12-19 17:52:33 +01:00
background: rgba(black,.6);
2017-12-06 17:12:17 +01:00
position: fixed;
top: 0; left: 0; right: 0; bottom: 0;
2017-12-06 17:12:17 +01:00
z-index: 10;
}
&:target{
&:before{
2017-12-08 12:44:59 +01:00
display: flex;
}
2017-12-06 17:12:17 +01:00
.modal-body{
@include translate(0, 0);
top: 20%;
2017-12-06 17:12:17 +01:00
}
}
.modal-body{
flex: 1 1 auto;
padding: 1.25rem;
background: $white;
border: 2px solid $muted-light;
2017-12-06 17:12:17 +01:00
word-wrap: break-word;
position: fixed;
z-index: 11;
2017-12-08 12:44:59 +01:00
max-width: 960px;
@include translate(0, -5000%);
2017-12-31 12:19:27 +01:00
@include transition(transform);
2017-12-19 17:52:33 +01:00
@include resp(medium) {
2017-12-08 12:44:59 +01:00
max-width: 85%;
}
2017-12-19 17:52:33 +01:00
@include resp(xsmall) {
2017-12-08 12:44:59 +01:00
max-width: 90%;
}
2017-12-06 17:12:17 +01:00
}
.btn-close{
color: $primary-light;
2017-12-06 17:12:17 +01:00
font-size: 30px;
text-decoration: none;
position: absolute; right: 0; top: 0;
2017-12-19 17:52:33 +01:00
@extend .margin;
2017-12-06 17:12:17 +01:00
background: inherit;
&:hover{
color: $muted;
2017-12-06 17:12:17 +01:00
}
}
.modal-title, h4 {
margin-top: 0;
margin-bottom: 0.5rem;
}
.modal-subtitle, h5 {
2017-12-19 17:52:33 +01:00
@extend .text-secondary;
2017-12-06 17:12:17 +01:00
margin-top: 0;
margin-bottom: 0.5rem;
}
.modal-text, p {
margin-top: 0;
margin-bottom: 1rem;
}
.modal-link + .modal-link,
a + a {
margin-left: 1.25rem;
}
a button {
text-decoration: none;
background: $white;
2017-12-06 17:12:17 +01:00
}
}