- {%- if project.img %}
- {%- include figure.html
- path=project.img
- alt="project thumbnail" -%}
- {%- endif %}
-
-
{{ project.title }}
-
{{ project.description }}
-
- {%- if project.github -%}
-
-
- {%- if project.github_stars -%}
-
-
-
-
- {%- endif %}
+
+ {%- if project.img %}
+ {%- include figure.html
+ path=project.img
+ alt="project thumbnail" -%}
+ {%- endif %}
+
+
{{ project.title }}
+
{{ project.description }}
+
+ {%- if project.github -%}
+
+
+ {%- if project.github_stars -%}
+
+
+
+
{%- endif %}
+ {%- endif %}
-
-
\ No newline at end of file
+
+
+
\ No newline at end of file
diff --git a/_includes/scripts/masonry.html b/_includes/scripts/masonry.html
index f610a7695ec1..804389d31ad3 100644
--- a/_includes/scripts/masonry.html
+++ b/_includes/scripts/masonry.html
@@ -1,6 +1,6 @@
{%- if site.enable_masonry -%}
-
+
-
+
{%- endif -%}
diff --git a/_sass/_base.scss b/_sass/_base.scss
index 7c46b5813b4a..a1465d77b8a7 100644
--- a/_sass/_base.scss
+++ b/_sass/_base.scss
@@ -51,6 +51,30 @@ blockquote {
text-align: center;
}
+// Card
+
+.card {
+ background-color: var(--global-card-bg-color);
+
+ img {
+ width: 100%;
+ }
+
+ .card-title {
+ color: var(--global-text-color);
+ }
+
+ .card-item {
+ width: auto;
+ margin-bottom: 10px;
+
+ .row {
+ display: flex;
+ align-items: center;
+ }
+ }
+}
+
// Citation
.citation, .citation-number {
color: var(--global-theme-color);
@@ -349,9 +373,6 @@ footer.sticky-bottom {
img {
width: 100%;
}
- .card-title {
- color: $black-color;
- }
}
.card-item {
@@ -364,7 +385,7 @@ footer.sticky-bottom {
}
}
- .grid-item {
+ .grid-sizer, .grid-item {
width: 250px;
margin-bottom: 10px;
}
diff --git a/_sass/_themes.scss b/_sass/_themes.scss
index 79a8e047c876..118bca7a873a 100644
--- a/_sass/_themes.scss
+++ b/_sass/_themes.scss
@@ -14,6 +14,7 @@
--global-footer-link-color: #{$white-color};
--global-distill-app-color: #{$grey-color};
--global-divider-color: rgba(0,0,0,.1);
+ --global-card-bg-color: #{$white-color};
.fa-sun {
display : none;
@@ -37,6 +38,7 @@ html[data-theme='dark'] {
--global-footer-link-color: #{$black-color};
--global-distill-app-color: #{$grey-color-light};
--global-divider-color: #424246;
+ --global-card-bg-color: #{$grey-900};
.fa-sun {
padding-left: 10px;
diff --git a/_sass/_variables.scss b/_sass/_variables.scss
index 5045a3df1f3b..b050aa6e7f67 100644
--- a/_sass/_variables.scss
+++ b/_sass/_variables.scss
@@ -26,6 +26,7 @@ $yellow-color: #efcc00 !default;
$grey-color: #828282 !default;
$grey-color-light: lighten($grey-color, 40%);
$grey-color-dark: #1C1C1D;
+$grey-900: #212529;
$white-color: #ffffff !default;
$black-color: #000000 !default;
diff --git a/assets/js/mansory.js b/assets/js/masonry.js
similarity index 100%
rename from assets/js/mansory.js
rename to assets/js/masonry.js
diff --git a/assets/js/theme.js b/assets/js/theme.js
index 371365ec2f50..169ea21d41bd 100644
--- a/assets/js/theme.js
+++ b/assets/js/theme.js
@@ -11,6 +11,8 @@ let toggleTheme = (theme) => {
let setTheme = (theme) => {
transTheme();
+ setHighlight(theme);
+
if (theme) {
document.documentElement.setAttribute("data-theme", theme);
}
@@ -28,6 +30,16 @@ let setTheme = (theme) => {
}
};
+let setHighlight = (theme) => {
+ if (theme == "dark") {
+ document.getElementById("highlight_theme_light").media = "none";
+ document.getElementById("highlight_theme_dark").media = "";
+ } else {
+ document.getElementById("highlight_theme_dark").media = "none";
+ document.getElementById("highlight_theme_light").media = "";
+ }
+}
+
let transTheme = () => {
document.documentElement.classList.add("transition");