diff --git a/_config.yml b/_config.yml index 462b37e..ad9e9e4 100644 --- a/_config.yml +++ b/_config.yml @@ -27,6 +27,19 @@ plugins: mermaid: src: 'https://unpkg.com/mermaid@10.6.1/dist/mermaid.min.js' +# Giscus comments configuration +giscus: + repo: "devnomadic/devnomadic.github.io" + repo-id: "MDEwOlJlcG9zaXRvcnkyOTYyMjkxOTE=" # Get this from giscus.app + category: "General" + category-id: "DIC_kwDOEagZR84CtcBV" # Get this from giscus.app + mapping: "pathname" + reactions-enabled: "1" + emit-metadata: "0" + input-position: "bottom" + theme: "preferred_color_scheme" + lang: "en" + # Theme settings dash: date_format: "%b %-d, %Y" diff --git a/_includes/giscus.html b/_includes/giscus.html new file mode 100644 index 0000000..d6ee1ca --- /dev/null +++ b/_includes/giscus.html @@ -0,0 +1,69 @@ +{% if site.giscus and site.giscus.repo %} +
+ +
+ + +{% endif %} diff --git a/_includes/header.html b/_includes/header.html index f1823ac..dbd010c 100644 --- a/_includes/header.html +++ b/_includes/header.html @@ -10,6 +10,25 @@ {% endif %} {% endfor %} + + +
+ + +
+
About @@ -18,3 +37,51 @@
+ + diff --git a/_layouts/post.html b/_layouts/post.html index 8dd118f..aa89f89 100644 --- a/_layouts/post.html +++ b/_layouts/post.html @@ -28,9 +28,9 @@

{{ page.title }}

{{ content }} -{% if site.dash.disqus.shortname %} +{% if site.giscus and site.giscus.repo %}
-{% include disqus.html %} +{% include giscus.html %}
{% endif %} diff --git a/assets/css/custom.css b/assets/css/custom.css index add37db..5114cd1 100644 --- a/assets/css/custom.css +++ b/assets/css/custom.css @@ -192,3 +192,27 @@ margin-bottom: 0.5em; } } + +/* Giscus comments styling */ +.comments { + margin-top: 3rem; + padding-top: 2rem; + border-top: 1px solid #e8eaed; +} + +.giscus-comments { + margin: 1rem 0; +} + +/* Ensure Giscus adapts to theme */ +.giscus-frame { + width: 100% !important; + border: none; +} + +/* Dark mode support for Giscus */ +@media (prefers-color-scheme: dark) { + .comments { + border-top-color: #3c4043; + } +}