+
+
+
+ {% assign card_body_col = '7' %}
{% endif %}
-
-
{{ post.title }}
+
+
+
{{ post.title }}
-
-
-
- - {% include no-linenos.html content=post.content %} - {{ content | markdownify | strip_html | truncate: 200 | escape }} -
-
-
-
-
- {% include datetime.html date=post.date lang=lang %}
-
-
- {% if post.categories.size > 0 %}
-
-
- {% for category in post.categories %}
- {{ category }}
- {%- unless forloop.last -%},{%- endunless -%}
- {% endfor %}
-
- {% endif %}
+
-
{% endfor %}
-{% endcapture %}
-
-
+
- {% if post.pin %}
- + {% include no-linenos.html content=post.content %} + {{ content | markdownify | strip_html | truncate: 200 | escape }} +
-
- {{ site.data.locales[lang].post.pin_prompt }}
+
-
+
+
+
+
+
+ {% include datetime.html date=post.date lang=lang %}
+
+
+ {% if post.categories.size > 0 %}
+
+
+ {% for category in post.categories %}
+ {{ category }}
+ {%- unless forloop.last -%},{%- endunless -%}
+ {% endfor %}
+
+ {% endif %}
- {% endif %}
+
+ {% if post.pin %}
+
+
+ {{ site.data.locales[lang].post.pin_prompt }}
+
+ {% endif %}
+
- {% include refactor-content.html content=content lang=lang %}
+{% endcapture %}
+
+{% include refactor-content.html content=_content lang=lang %}
{% if paginator.total_pages > 1 %}
{% include post-paginator.html %}
diff --git a/_sass/addon/commons.scss b/_sass/addon/commons.scss
index 7439330..0fa515f 100644
--- a/_sass/addon/commons.scss
+++ b/_sass/addon/commons.scss
@@ -71,54 +71,13 @@ a {
img {
max-width: 100%;
height: auto;
- transition: all 0.35s ease-in-out;
+ transition: all 0.7s ease-in-out;
- &[data-src] {
- &[data-lqip='true'] {
- &.lazyload,
- &.lazyloading {
- -webkit-filter: blur(20px);
- filter: blur(20px);
- }
- }
+ &[data-lqip='true'] {
+ $blur: 20px;
- &:not([data-lqip='true']) {
- &.lazyload,
- &.lazyloading {
- background: var(--img-bg);
- }
-
- &.lazyloaded {
- -webkit-animation: fade-in 0.35s ease-in;
- animation: fade-in 0.35s ease-in;
- }
- }
-
- &.shadow {
- -webkit-filter: drop-shadow(2px 4px 6px rgba(0, 0, 0, 0.08));
- filter: drop-shadow(2px 4px 6px rgba(0, 0, 0, 0.08));
- box-shadow: none !important; /* cover the Bootstrap 4.6.1 styles */
- }
-
- @extend %img-caption;
- }
-
- @-webkit-keyframes fade-in {
- from {
- opacity: 0;
- }
- to {
- opacity: 1;
- }
- }
-
- @keyframes fade-in {
- from {
- opacity: 0;
- }
- to {
- opacity: 1;
- }
+ -webkit-filter: blur($blur);
+ filter: blur($blur);
}
}
@@ -349,6 +308,29 @@ sup {
/* --- post --- */
+.preview-img {
+ aspect-ratio: 40 / 21;
+ width: 100%;
+ height: 100%;
+ overflow: hidden;
+
+ @extend %rounded;
+
+ &:not(.no-bg) {
+ img {
+ background: var(--img-bg);
+ }
+ }
+
+ img {
+ height: 100%;
+ -o-object-fit: cover;
+ object-fit: cover;
+
+ @extend %rounded;
+ }
+}
+
.post-preview {
@extend %rounded;
@@ -384,7 +366,6 @@ main {
}
p {
- > img[data-src],
> a.popup {
&:not(.normal):not(.left):not(.right) {
@include align-center;
@@ -538,8 +519,8 @@ main {
background: var(--shimmer-bg);
height: 100%;
width: 100%;
- -webkit-animation: shimmer 1s infinite;
- animation: shimmer 1s infinite;
+ -webkit-animation: shimmer 1.3s infinite;
+ animation: shimmer 1.3s infinite;
}
@-webkit-keyframes shimmer {
diff --git a/_sass/layout/home.scss b/_sass/layout/home.scss
index 5b43261..7f9fd2e 100644
--- a/_sass/layout/home.scss
+++ b/_sass/layout/home.scss
@@ -6,8 +6,6 @@
margin-top: 2rem;
.card-wrapper {
- display: block;
-
&:hover {
text-decoration: none;
}
@@ -18,27 +16,23 @@
}
.card {
+ border: 0;
+ background: none;
+
%img-radius {
border-radius: $base-radius $base-radius 0 0;
}
.preview-img {
- height: 10rem;
-
@extend %img-radius;
img {
- width: 100%;
- height: 100%;
- -o-object-fit: cover;
- object-fit: cover;
-
@extend %img-radius;
}
}
.card-body {
- min-height: 10.5rem;
+ height: 100%;
padding: 1rem;
.card-title {
@@ -136,20 +130,13 @@
/* Tablet */
@media all and (min-width: 768px) {
+ %img-radius {
+ border-radius: 0 $base-radius $base-radius 0;
+ }
+
#post-list {
- %img-radius {
- border-radius: 0 $base-radius $base-radius 0;
- }
-
.card {
- .preview-img {
- width: 20rem;
- height: 11.55rem; // can hold 2 lines each for title and content
- }
-
.card-body {
- min-height: 10.75rem;
- width: 60%;
padding: 1.75rem 1.75rem 1.25rem 1.75rem;
.card-text {
diff --git a/_sass/layout/post.scss b/_sass/layout/post.scss
index ebc2582..955c958 100644
--- a/_sass/layout/post.scss
+++ b/_sass/layout/post.scss
@@ -26,26 +26,6 @@
color: var(--text-color);
}
-.preview-img {
- overflow: hidden;
- aspect-ratio: 40 / 21;
-
- @extend %rounded;
-
- &:not(.no-bg) {
- img.lazyloaded {
- background: var(--img-bg);
- }
- }
-
- img {
- -o-object-fit: cover;
- object-fit: cover;
-
- @extend %rounded;
- }
-}
-
h1 + .post-meta {
> span + span::before {
@include dot;
@@ -368,10 +348,6 @@ h1 + .post-meta {
}
@media all and (max-width: 576px) {
- .preview-img[data-src] {
- margin-top: 2.2rem;
- }
-
.post-tail-bottom {
flex-wrap: wrap-reverse !important;
@@ -396,9 +372,4 @@ h1 + .post-meta {
margin-left: -0.5rem;
margin-right: -0.5rem;
}
-
- .preview-img[data-src] {
- max-width: 100vw;
- border-radius: 0;
- }
}
diff --git a/assets/lib b/assets/lib
index 6737eab..f80ba2f 160000
--- a/assets/lib
+++ b/assets/lib
@@ -1 +1 @@
-Subproject commit 6737eab720e4cdd8330d32053053356f200d8819
+Subproject commit f80ba2f1616496cba34f3fd3eef1564d8fa843cd