feat: new caption design

This commit is contained in:
Damillora 2021-07-11 03:19:24 +07:00
parent a1d30b3b13
commit 77c6d76d46
3 changed files with 42 additions and 2 deletions

View File

@ -36,6 +36,7 @@
&__contents { &__contents {
z-index: 1; z-index: 1;
width: 100%;
padding-top: 3rem; padding-top: 3rem;
@include screen(md) { @include screen(md) {
padding-top: 4rem; padding-top: 4rem;

View File

@ -1,4 +1,6 @@
.post-header { .post-header {
width: 100%;
&__heading { &__heading {
@include my(0.5rem); @include my(0.5rem);
@ -44,7 +46,6 @@
flex-direction: row; flex-direction: row;
justify-content: center; justify-content: center;
@include my(0.5rem); @include my(0.5rem);
@include py(0.5rem);
} }
&__author-images { &__author-images {
display: flex; display: flex;
@ -69,4 +70,26 @@
&__social { &__social {
color: $white; color: $white;
} }
&__caption {
text-align: center;
font-size: 0.75rem;
margin-top: 0;
margin-bottom: 0;
@include screen(md) {
text-align: center;
font-size: 0.875rem;
}
}
&__caption-text {
background: var(--bg-color);
color: var(--highlight-color);
padding: 0.25rem 1rem;
border-radius: 1rem;
font-size: $text-sm;
box-shadow: 0px 0px 4px 1px var(--accent-color);
@include screen(md) {
padding: 0.5rem 2rem;
}
}
} }

View File

@ -13,6 +13,8 @@
flex-direction: column; flex-direction: column;
align-items: center; align-items: center;
object-fit: contain; object-fit: contain;
position: relative;
.kg-image { .kg-image {
width: 100%; width: 100%;
} }
@ -35,9 +37,23 @@
} }
.kg-card figcaption { .kg-card figcaption {
font-size: $text-sm; font-size: $text-sm;
background: var(--bg-color);
color: var(--highlight-color); color: var(--highlight-color);
margin-top: 0.5rem; padding: 0.25rem 1rem;
border-radius: 1rem;
margin-left: 0.5rem;
margin-right: 0.5rem;
text-align: center; text-align: center;
@include screen(md) {
padding: 0.5rem 2rem;
}
}
.kg-image-card figcaption {
position: absolute;
bottom: 2rem;
box-shadow: 0px 0px 4px 1px var(--accent-color);
} }
.kg-gallery-container { .kg-gallery-container {