Fix #441: Improve validity of epub output

This commit is contained in:
Samy Pessé
2014-11-13 08:34:35 +01:00
parent 77043464b2
commit 05eaeeb0d0
3 changed files with 26 additions and 4 deletions
+22
View File
@@ -0,0 +1,22 @@
<!DOCTYPE HTML>
<html lang="en-US" {% block htmlTag %}{% endblock %}>
{{ htmlSnippet("html:start")|default("") }}
<head>
{{ htmlSnippet("head:start")|default("") }}
<meta charset="UTF-8">
<title>{% block title %}{% endblock %}</title>
<meta content="text/html; charset=utf-8" http-equiv="Content-Type">
<meta name="description" content="{% block description %}{% endblock %}">
<meta name="generator" content="GitBook {{ gitbook.version }}">
{% block head %}{% endblock %}
{{ htmlSnippet("head:end")|default("") }}
</head>
<body>
{{ htmlSnippet("body:start")|default("") }}
{% block style %}{% endblock %}
{% block content %}{% endblock %}
{% block javascript %}{% endblock %}
{{ htmlSnippet("body:end")|default("") }}
</body>
{{ htmlSnippet("html:end")|default("") }}
</html>
+3 -3
View File
@@ -1,4 +1,4 @@
{% extends "../layout.html" %}
{% extends "./layout.html" %}
{% block title %}{{ progress.current.title }} | {{ title }}{% endblock %}
@@ -17,7 +17,7 @@
<div class="page">
<h1 class="book-chapter book-chapter-{{ progress.current.level|lvl }}">{{ progress.current.title }}</h1>
{% for section in content %}
<section class="{{ section.type }}" id="section-{{ section.id }}">
<div class="{{ section.type }}" id="section-{{ section.id }}">
{% if section.type == "normal" %}
{% autoescape false %}{{ section.content }}{% endautoescape %}
{% elif section.type == "exercise" %}
@@ -25,7 +25,7 @@
{% elif section.type == "quiz" %}
{% include "./includes/quiz.html" with {section: section} %}
{% endif %}
</section>
</div>
{% endfor %}
</div>
{% endblock %}
+1 -1
View File
@@ -1,4 +1,4 @@
{% extends "../layout.html" %}
{% extends "./layout.html" %}
{% block title %}Table of Contents | {{ title }}{% endblock %}