krata/_sass/layout/home.scss

190 lines
3.0 KiB
SCSS
Raw Normal View History

2021-01-23 06:20:58 +01:00
/*
Style for Homepage
*/
#post-list {
margin-top: 2rem;
.card-wrapper {
&:hover {
text-decoration: none;
}
&:not(:last-child) {
margin-bottom: 1.25rem;
}
}
.card {
border: 0;
background: none;
%img-radius {
border-radius: $base-radius $base-radius 0 0;
}
.preview-img {
@extend %img-radius;
img {
@extend %img-radius;
}
}
.card-body {
height: 100%;
padding: 1rem;
.card-title {
@extend %text-clip;
2023-09-09 16:38:19 +02:00
color: var(--heading-color) !important;
font-size: 1.25rem;
}
%muted {
color: var(--text-muted-color) !important;
}
.card-text.content {
@extend %muted;
p {
@extend %text-clip;
line-height: 1.5;
margin: 0;
}
}
.post-meta {
@extend %muted;
i {
&:not(:first-child) {
margin-left: 1.5rem;
}
}
em {
@extend %normal-font-style;
color: inherit;
}
> div:first-child {
display: block;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
}
}
}
} /* #post-list */
2019-11-15 17:01:33 +01:00
.pagination {
color: var(--text-color);
2022-10-19 20:05:29 +02:00
font-family: Lato, sans-serif;
justify-content: space-evenly;
2020-02-25 10:56:03 +01:00
a:hover {
text-decoration: none;
}
2019-11-15 17:01:33 +01:00
2020-06-06 18:42:21 +02:00
.page-item {
.page-link {
color: var(--btn-patinator-text-color);
padding: 0 0.6rem;
2020-02-25 10:56:03 +01:00
display: -webkit-box;
2020-06-06 18:42:21 +02:00
-webkit-box-pack: center;
-webkit-box-align: center;
border-radius: 0.5rem;
border: 0;
background-color: inherit;
}
2021-10-25 21:04:15 +02:00
&.active {
.page-link {
background-color: var(--btn-paginator-hover-color);
2020-06-17 10:17:03 +02:00
}
2020-02-25 10:56:03 +01:00
}
2021-10-25 21:04:15 +02:00
&:not(.active) {
2020-06-06 18:42:21 +02:00
.page-link {
&:hover {
box-shadow: inset var(--btn-border-color) 0 0 0 1px;
}
2020-06-06 18:42:21 +02:00
}
2020-02-25 10:56:03 +01:00
}
2021-10-25 21:04:15 +02:00
2020-06-06 18:42:21 +02:00
&.disabled {
cursor: not-allowed;
2021-10-25 21:04:15 +02:00
2020-06-06 18:42:21 +02:00
.page-link {
color: rgba(108, 117, 125, 0.57);
}
2020-02-25 10:56:03 +01:00
}
2022-10-19 20:05:29 +02:00
} /* .page-item */
} /* .pagination */
2019-11-15 17:01:33 +01:00
/* Tablet */
@media all and (min-width: 768px) {
%img-radius {
border-radius: 0 $base-radius $base-radius 0;
}
#post-list {
.card {
.card-body {
padding: 1.75rem 1.75rem 1.25rem 1.75rem;
2022-10-19 20:05:29 +02:00
.card-text {
display: inherit !important;
2022-10-19 20:05:29 +02:00
}
2021-10-25 21:04:15 +02:00
.post-meta {
i {
&:not(:first-child) {
margin-left: 1.75rem;
}
}
}
}
}
}
}
/* Hide SideBar and TOC */
@media all and (max-width: 830px) {
.pagination {
.page-item {
&:not(:first-child):not(:last-child) {
display: none;
}
}
}
}
2019-11-25 15:01:40 +01:00
/* Sidebar is visible */
@media all and (min-width: 831px) {
#post-list {
margin-top: 2.5rem;
}
2019-11-22 17:27:41 +01:00
.pagination {
2020-10-27 15:08:04 +01:00
font-size: 0.85rem;
justify-content: center;
.page-item {
&:not(:last-child) {
margin-right: 0.7rem;
}
2020-06-06 18:42:21 +02:00
}
.page-index {
display: none;
}
2022-10-19 20:05:29 +02:00
} /* .pagination */
2019-11-22 17:27:41 +01:00
}