From d36bc3544752de8b033535de3bdab9de1cd4d7ed Mon Sep 17 00:00:00 2001 From: basti1dr Date: Sun, 27 Sep 2015 18:38:46 +0200 Subject: [PATCH 1/4] feat: add in configuration option for disqus --- _config.yml | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/_config.yml b/_config.yml index 619e469..031e878 100644 --- a/_config.yml +++ b/_config.yml @@ -5,9 +5,16 @@ url: https://example.github.io description: "Write an awesome description for your new site here. You can edit this line in _config.yml. It will appear in your document head meta (for Google search results) and in your feed.xml site description." skills: "Web Developer - Graphic Artist - User Experience Designer" -# Contact form: comment the line below if you want to stick with the default PHP contact form +# Contact form: +# - static : pass through formspree.io to validate email sending +# - disqus : replace contact form by disqus thread +# - comment the line below if you want to stick with the default PHP contact form contact: static +# If you use disqus you need disqus shortname +# https://help.disqus.com/customer/portal/articles/466208 +disqus_shortname: myshortname + # Color settings (hex-codes without the leading hash-tag) color: primary: 18bc9c #80B3FF From 02a82d74409e7186b3495e907da480cb600528ef Mon Sep 17 00:00:00 2001 From: basti1dr Date: Sun, 27 Sep 2015 18:39:34 +0200 Subject: [PATCH 2/4] feat: add includes part for disqus display --- _includes/contact_disqus.html | 16 ++++++++++++++++ _includes/js_disqus.html | 21 +++++++++++++++++++++ 2 files changed, 37 insertions(+) create mode 100644 _includes/contact_disqus.html create mode 100644 _includes/js_disqus.html diff --git a/_includes/contact_disqus.html b/_includes/contact_disqus.html new file mode 100644 index 0000000..851ecc8 --- /dev/null +++ b/_includes/contact_disqus.html @@ -0,0 +1,16 @@ + +
+
+
+
+

Contactez-moi

+
+
+
+
+
+
+
+
+
+
diff --git a/_includes/js_disqus.html b/_includes/js_disqus.html new file mode 100644 index 0000000..0144c3a --- /dev/null +++ b/_includes/js_disqus.html @@ -0,0 +1,21 @@ + + +comments powered by Disqus From c6a9deace26d4f878115caac05a8002474ef7663 Mon Sep 17 00:00:00 2001 From: basti1dr Date: Sun, 27 Sep 2015 18:40:16 +0200 Subject: [PATCH 3/4] feat: include disqus if we enable it --- _includes/js.html | 5 +++++ _layouts/default.html | 2 ++ 2 files changed, 7 insertions(+) diff --git a/_includes/js.html b/_includes/js.html index 7d37df5..9357111 100644 --- a/_includes/js.html +++ b/_includes/js.html @@ -19,3 +19,8 @@ + + {% if site.contact == "disqus" %} + + {% include js_disqus.html %} + {% endif %} diff --git a/_layouts/default.html b/_layouts/default.html index 0482848..640dc5f 100644 --- a/_layouts/default.html +++ b/_layouts/default.html @@ -9,6 +9,8 @@ {% if site.contact == "static" %} {% include contact_static.html %} + {% elsif site.contact == "disqus" %} + {% include contact_disqus.html %} {% else %} {% include contact.html %} {% endif %} From 2b350975745d3c3723c0f5d727f372e9d813951b Mon Sep 17 00:00:00 2001 From: Jerome Lachaud Date: Thu, 12 Nov 2015 14:09:27 +0000 Subject: [PATCH 4/4] Update contact_disqus.html --- _includes/contact_disqus.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/_includes/contact_disqus.html b/_includes/contact_disqus.html index 851ecc8..8189a3c 100644 --- a/_includes/contact_disqus.html +++ b/_includes/contact_disqus.html @@ -3,7 +3,7 @@
-

Contactez-moi

+

Contact me