aboutsummaryrefslogtreecommitdiff
path: root/.themes/classic/source/_layouts
diff options
context:
space:
mode:
authorFrederic Hemberger <mail@frederic-hemberger.de>2011-09-21 13:37:59 +0200
committerFrederic Hemberger <mail@frederic-hemberger.de>2011-09-21 14:09:48 +0200
commit2a30d9a1eb5219e5335d1afdd214204d61ea6367 (patch)
tree6f5c9cb556bd1b5aa46d93cd0a128e087abe5485 /.themes/classic/source/_layouts
parentb2828eb039ddc7c0108b6af06ca7f5d8c87a5459 (diff)
downloadmy_new_personal_website-2a30d9a1eb5219e5335d1afdd214204d61ea6367.tar.xz
my_new_personal_website-2a30d9a1eb5219e5335d1afdd214204d61ea6367.zip
Refactored inclusion of disqus script
- Added ARIA setting `aria-live="polite"` to comment output - Removed duplicate <div id="disqus_thread"> from page/post templates - Moved blocking JavaScript loading to the end of the document body. - Merged JavaScript code for index and pages/posts using conditionals - Moved global JavaScript disqus variables into the anonymous function to stop pollution of global namespace
Diffstat (limited to '.themes/classic/source/_layouts')
-rw-r--r--.themes/classic/source/_layouts/default.html1
-rw-r--r--.themes/classic/source/_layouts/page.html2
-rw-r--r--.themes/classic/source/_layouts/post.html4
3 files changed, 4 insertions, 3 deletions
diff --git a/.themes/classic/source/_layouts/default.html b/.themes/classic/source/_layouts/default.html
index 629468d3..d84da44c 100644
--- a/.themes/classic/source/_layouts/default.html
+++ b/.themes/classic/source/_layouts/default.html
@@ -9,6 +9,7 @@
</div>
</div>
<footer>{% include footer.html %}</footer>
+ {% include disqus.html %}
{% include google_analytics.html %}
{% include google_plus_one.html %}
{% include twitter_sharing.html %}
diff --git a/.themes/classic/source/_layouts/page.html b/.themes/classic/source/_layouts/page.html
index dbf209c4..20c17452 100644
--- a/.themes/classic/source/_layouts/page.html
+++ b/.themes/classic/source/_layouts/page.html
@@ -27,7 +27,7 @@ layout: default
{% if site.disqus_short_name and page.comments == true %}
<section>
<h1>Comments</h1>
- <div id="disqus_thread">{% include post/disqus_thread.html %}</div>
+ <div id="disqus_thread" aria-live="polite">{% include post/disqus_thread.html %}</div>
</section>
{% endif %}
</div>
diff --git a/.themes/classic/source/_layouts/post.html b/.themes/classic/source/_layouts/post.html
index ce8a5dea..e81cc787 100644
--- a/.themes/classic/source/_layouts/post.html
+++ b/.themes/classic/source/_layouts/post.html
@@ -17,10 +17,10 @@ single: true
{% endunless %}
</footer>
</article>
-{% if site.disqus_short_name and page.comments != false %}
+{% if site.disqus_short_name and page.comments == true %}
<section>
<h1>Comments</h1>
- <div id="disqus_thread">{% include post/disqus_thread.html %}</div>
+ <div id="disqus_thread" aria-live="polite">{% include post/disqus_thread.html %}</div>
</section>
{% endif %}
</div>