From e3dfbf67c72414a10cd3b237e8ce435b3ea2b9d0 Mon Sep 17 00:00:00 2001 From: Maruan Al-Shedivat Date: Tue, 20 Oct 2015 12:05:37 -0400 Subject: [PATCH] Add math support through kramdown and katex. Light style improvements. --- _config.yml | 13 +++++++++++-- _includes/footer.html | 2 +- _includes/head.html | 22 +++++++++++++-------- _includes/header.html | 2 +- _layouts/default.html | 2 ++ _posts/2015-10-20-comments.markdown | 8 ++++++++ _posts/2015-10-20-math.markdown | 15 +++++++++++++++ _sass/_base.scss | 30 +++++++++++++++++------------ _sass/_layout.scss | 17 +++++++++------- js/katex.js | 15 +++++++++++++++ 10 files changed, 95 insertions(+), 31 deletions(-) create mode 100644 _posts/2015-10-20-comments.markdown create mode 100644 _posts/2015-10-20-math.markdown create mode 100644 js/katex.js diff --git a/_config.yml b/_config.yml index 2575811..18f2100 100644 --- a/_config.yml +++ b/_config.yml @@ -10,16 +10,21 @@ twitter_username: twitter_username github_username: github_username # Build settings -markdown: redcarpet +markdown: kramdown highlighter: pygments -include: ['_pages'] +# Math support +kramdown: + math_engine: mathjax # Pagination paginate: 15 permalink: /blog/:year/:title/ paginate_path: /blog/page:num/ +# Includes +include: ['_pages'] + # Collections collections: projects: @@ -50,3 +55,7 @@ scholar: details_link: Details query: "@*" + +# Advanced (don't if you are not sure what it is) +jquery_version: "1.11.1" +katex_version: "0.1.1" diff --git a/_includes/footer.html b/_includes/footer.html index 252e170..bc775b9 100644 --- a/_includes/footer.html +++ b/_includes/footer.html @@ -1,7 +1,7 @@ diff --git a/_includes/head.html b/_includes/head.html index da93bd8..08fb77e 100644 --- a/_includes/head.html +++ b/_includes/head.html @@ -1,13 +1,19 @@ - - - + + + - {{ site.name }}{% if page.title and page.url != "/" %} | {{ page.title }}{% endif %} - + {{ site.name }}{% if page.title and page.url != "/" %} | {{ page.title }}{% endif %} + - - + + - + + + + + + + diff --git a/_includes/header.html b/_includes/header.html index 486a276..58ac4d7 100644 --- a/_includes/header.html +++ b/_includes/header.html @@ -5,7 +5,7 @@