From c3a1639641dd07b16884daa26d00b49eccb93c84 Mon Sep 17 00:00:00 2001 From: Greg Wilson <gvwilson@third-bit.com> Date: Sun, 26 Jun 2016 00:25:00 -0400 Subject: [PATCH] Markdownifying questions, keypoints, etc. --- _includes/all_keypoints.html | 6 +++--- _includes/episode_keypoints.html | 2 +- _includes/episode_overview.html | 4 ++-- _includes/syllabus.html | 7 ++++++- assets/css/lesson.scss | 1 - 5 files changed, 12 insertions(+), 8 deletions(-) diff --git a/_includes/all_keypoints.html b/_includes/all_keypoints.html index bedfd73..898133a 100644 --- a/_includes/all_keypoints.html +++ b/_includes/all_keypoints.html @@ -11,9 +11,9 @@ </td> <td class="col-md-9"> <ul> - {% for keypoint in episode.keypoints %} - <li>{{ keypoint }}</li> - {% endfor %} + {% for keypoint in episode.keypoints %} + <li>{{ keypoint|markdownify }}</li> + {% endfor %} </ul> </td> </tr> diff --git a/_includes/episode_keypoints.html b/_includes/episode_keypoints.html index e14de40..85378a5 100644 --- a/_includes/episode_keypoints.html +++ b/_includes/episode_keypoints.html @@ -2,7 +2,7 @@ <h2>Key Points</h2> <ul> {% for keypoint in page.keypoints %} - <li>{{ keypoint }}</li> + <li>{{ keypoint|markdownify }}</li> {% endfor %} </ul> </blockquote> diff --git a/_includes/episode_overview.html b/_includes/episode_overview.html index f4a5a7c..f22a1a6 100644 --- a/_includes/episode_overview.html +++ b/_includes/episode_overview.html @@ -14,7 +14,7 @@ <strong>Questions</strong> <ul> {% for question in page.questions %} - <li>{{ question }}</li> + <li>{{ question|markdownify }}</li> {% endfor %} </ul> </div> @@ -27,7 +27,7 @@ <strong>Objectives</strong> <ul> {% for objective in page.objectives %} - <li>{{ objective }}</li> + <li>{{ objective|markdownify }}</li> {% endfor %} </ul> </div> diff --git a/_includes/syllabus.html b/_includes/syllabus.html index 5f4b7c8..bb7d1ef 100644 --- a/_includes/syllabus.html +++ b/_includes/syllabus.html @@ -41,7 +41,12 @@ Break {% else %} {% if episode.questions %} - {{ episode.questions | join: '<br/>' }} + {% for question in episode.questions %} + {{question|markdownify|strip_html}} + {% unless forloop.last %} + <br/> + {% endunless %} + {% endfor %} {% endif %} {% endif %} </td> diff --git a/assets/css/lesson.scss b/assets/css/lesson.scss index 0f3e47e..7c6de99 100644 --- a/assets/css/lesson.scss +++ b/assets/css/lesson.scss @@ -131,7 +131,6 @@ ol { padding-left: 1em; } - span.fold-unfold { margin-left: 1em; opacity: 0.5; -- GitLab