kitabu 1.0.6 → 2.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitignore +5 -3
- data/.travis.yml +18 -0
- data/CHANGELOG.md +9 -0
- data/Gemfile.lock +67 -50
- data/README.md +235 -0
- data/attachments/browser-version.png +0 -0
- data/attachments/cover.png +0 -0
- data/attachments/kitabu.epub +0 -0
- data/attachments/kitabu.mobi +0 -0
- data/attachments/kitabu.pdf +0 -0
- data/{spec/support/mybook/output → examples/kitabu/output/epub/images}/.gitkeep +0 -0
- data/examples/kitabu/output/epub/images/kitabu-icon.png +0 -0
- data/examples/kitabu/output/epub/images/kitabu-icon.svg +19 -0
- data/examples/kitabu/output/epub/images/kitabu-word.png +0 -0
- data/examples/kitabu/output/epub/images/kitabu-word.svg +14 -0
- data/examples/kitabu/output/epub/images/kitabu.png +0 -0
- data/examples/kitabu/output/epub/images/kitabu.svg +20 -0
- data/examples/kitabu/output/epub/section_0.html +266 -0
- data/examples/kitabu/output/epub/section_1.html +246 -0
- data/examples/kitabu/output/epub/section_2.html +520 -0
- data/examples/kitabu/output/epub/section_3.html +282 -0
- data/examples/kitabu/output/epub/section_4.html +276 -0
- data/examples/kitabu/output/epub/styles/epub.css +437 -0
- data/examples/kitabu/output/epub/styles/html.css +712 -0
- data/examples/kitabu/output/epub/styles/pdf.css +840 -0
- data/examples/kitabu/output/epub/styles/print.css +1278 -0
- data/examples/kitabu/output/epub/toc.html +37 -0
- data/{spec/support/mybook/templates/epub/style.css → examples/kitabu/output/images/.gitkeep} +0 -0
- data/examples/kitabu/output/images/kitabu-icon.png +0 -0
- data/examples/kitabu/output/images/kitabu-icon.svg +19 -0
- data/examples/kitabu/output/images/kitabu-word.png +0 -0
- data/examples/kitabu/output/images/kitabu-word.svg +14 -0
- data/examples/kitabu/output/images/kitabu.png +0 -0
- data/examples/kitabu/output/images/kitabu.svg +20 -0
- data/examples/kitabu/output/kitabu.epub +0 -0
- data/examples/kitabu/output/kitabu.html +513 -0
- data/examples/kitabu/output/kitabu.mobi +0 -0
- data/examples/kitabu/output/kitabu.pdf +0 -0
- data/examples/kitabu/output/kitabu.pdf.html +729 -0
- data/examples/kitabu/output/kitabu.print.html +729 -0
- data/examples/kitabu/output/kitabu.print.pdf +0 -0
- data/examples/kitabu/output/kitabu.txt +440 -0
- data/examples/kitabu/output/styles/epub.css +437 -0
- data/examples/kitabu/output/styles/html.css +712 -0
- data/examples/kitabu/output/styles/pdf.css +840 -0
- data/examples/kitabu/output/styles/print.css +1278 -0
- data/kitabu.gemspec +7 -5
- data/lib/kitabu.rb +10 -20
- data/lib/kitabu/cli.rb +0 -5
- data/lib/kitabu/dependency.rb +0 -4
- data/lib/kitabu/exporter.rb +2 -0
- data/lib/kitabu/extensions/rouge.rb +9 -0
- data/lib/kitabu/generator.rb +9 -21
- data/lib/kitabu/helpers.rb +47 -0
- data/lib/kitabu/markdown.rb +31 -0
- data/lib/kitabu/parser.rb +21 -3
- data/lib/kitabu/parser/epub.rb +31 -18
- data/lib/kitabu/parser/html.rb +48 -29
- data/lib/kitabu/parser/mobi.rb +1 -1
- data/lib/kitabu/parser/pdf.rb +52 -8
- data/lib/kitabu/version.rb +2 -2
- data/spec/kitabu/cli/export_spec.rb +4 -4
- data/spec/kitabu/cli/new_spec.rb +2 -2
- data/spec/kitabu/markdown_spec.rb +24 -0
- data/spec/kitabu/parser/html_spec.rb +20 -25
- data/spec/kitabu/parser/mobi_spec.rb +14 -0
- data/spec/kitabu/parser/pdf_spec.rb +18 -1
- data/spec/kitabu/parser/txt_spec.rb +14 -0
- data/spec/spec_helper.rb +10 -6
- data/spec/support/mybook/config/helper.rb +4 -29
- data/spec/support/mybook/config/kitabu.yml +0 -10
- data/spec/support/mybook/templates/epub/cover.erb +4 -3
- data/{templates → spec/support/mybook/templates/epub}/cover.png +0 -0
- data/spec/support/mybook/templates/epub/page.erb +3 -2
- data/spec/support/mybook/templates/html/layout.erb +10 -13
- data/spec/support/mybook/templates/styles/epub.scss +3 -0
- data/spec/support/mybook/templates/styles/html.scss +3 -0
- data/spec/support/mybook/templates/styles/pdf.scss +3 -0
- data/spec/support/mybook/templates/styles/print.scss +3 -0
- data/spec/support/mybook/text/{01_Markdown_Chapter.markdown → 01_Markdown_Chapter.md} +2 -3
- data/spec/support/mybook/text/02_ERB_Chapter.md.erb +7 -0
- data/spec/support/mybook/text/{04_With_Directory/Some_Chapter.mkdn → 03_With_Directory/Some_Chapter.md} +0 -0
- data/spec/support/mybook/text/{CHANGELOG.textile → CHANGELOG.md} +2 -2
- data/spec/support/mybook/text/{TOC.textile → TOC.md} +0 -0
- data/spec/support/mybook/text/{_00_Introduction.markdown → _00_Introduction.md} +0 -0
- data/spec/support/shared.rb +14 -10
- data/templates/Gemfile +3 -3
- data/templates/Guardfile +1 -5
- data/templates/config.erb +5 -5
- data/templates/cover.erb +4 -3
- data/templates/epub.erb +3 -2
- data/templates/helper.rb +28 -29
- data/templates/images/.gitkeep +0 -0
- data/templates/images/kitabu-icon.png +0 -0
- data/templates/images/kitabu-icon.svg +19 -0
- data/templates/images/kitabu-word.png +0 -0
- data/templates/images/kitabu-word.svg +14 -0
- data/templates/images/kitabu.png +0 -0
- data/templates/images/kitabu.svg +20 -0
- data/{examples/RailsGuides/templates → templates/templates/epub}/cover.erb +4 -3
- data/templates/templates/epub/cover.png +0 -0
- data/templates/templates/epub/page.erb +16 -0
- data/templates/{layout.erb → templates/html/layout.erb} +22 -11
- data/templates/templates/styles/epub.scss +1 -0
- data/templates/templates/styles/files/_normalize.scss +427 -0
- data/templates/templates/styles/html.scss +252 -0
- data/templates/templates/styles/pdf.scss +371 -0
- data/templates/templates/styles/print.scss +2 -0
- data/templates/text/01_Getting_Started.md +26 -0
- data/templates/text/02_Creating_Chapters.md +22 -0
- data/templates/text/03_Syntax_Highlighting.erb +69 -0
- data/templates/text/04_Dynamic_Content.erb +64 -0
- data/templates/text/05_Exporting_Files.md +49 -0
- metadata +143 -83
- data/README.rdoc +0 -218
- data/examples/RailsGuides/config/helper.rb +0 -29
- data/examples/RailsGuides/config/kitabu.yml +0 -44
- data/examples/RailsGuides/images/challenge.png +0 -0
- data/examples/RailsGuides/images/posts_index.png +0 -0
- data/examples/RailsGuides/images/rails_welcome.png +0 -0
- data/examples/RailsGuides/output/RailsGuides.epub +0 -0
- data/examples/RailsGuides/output/RailsGuides.html +0 -1556
- data/examples/RailsGuides/output/RailsGuides.pdf +3 -4934
- data/examples/RailsGuides/templates/layout.css +0 -352
- data/examples/RailsGuides/templates/layout.erb +0 -43
- data/examples/RailsGuides/templates/syntax.css +0 -62
- data/examples/RailsGuides/templates/user.css +0 -19
- data/examples/RailsGuides/text/01_Guide_Assumptions.mkdn +0 -13
- data/examples/RailsGuides/text/02_What_is_Rails.mkdn +0 -106
- data/examples/RailsGuides/text/03_Creating_a_new_Rails_project.mkdn +0 -200
- data/examples/RailsGuides/text/04_Hello_Rails.mkdn +0 -62
- data/examples/RailsGuides/text/05_Getting_Up_and_Running_Quickly_with_Scaffolding.mkdn +0 -4
- data/examples/RailsGuides/text/06_Creating_a_resource.mkdn +0 -503
- data/examples/RailsGuides/text/07_Adding_a_second_model.mkdn +0 -232
- data/examples/RailsGuides/text/08_Refactoring.mkdn +0 -123
- data/examples/RailsGuides/text/09_Deleting_comments.mkdn +0 -57
- data/examples/RailsGuides/text/09_Security.mkdn +0 -56
- data/examples/RailsGuides/text/10_Building_a_multi_model_form.mkdn +0 -130
- data/examples/RailsGuides/text/11_View_helpers.mkdn +0 -50
- data/examples/RailsGuides/text/12_Whats_next.mkdn +0 -14
- data/examples/RailsGuides/text/13_Configuration_gotchas.mkdn +0 -10
- data/lib/kitabu/adapters/markdown.rb +0 -34
- data/lib/kitabu/extensions/redcloth.rb +0 -69
- data/lib/kitabu/syntax.rb +0 -130
- data/spec/kitabu/extensions/redcloth_spec.rb +0 -57
- data/spec/kitabu/syntax_spec.rb +0 -106
- data/spec/support/mybook/templates/html/layout.css +0 -353
- data/spec/support/mybook/templates/html/syntax.css +0 -58
- data/spec/support/mybook/templates/html/user.css +0 -1
- data/spec/support/mybook/text/02_Textile_Chapter.textile +0 -3
- data/spec/support/mybook/text/03_HTML_Chapter.html +0 -3
- data/templates/epub.css +0 -500
- data/templates/layout.css +0 -353
- data/templates/sample.md +0 -6
- data/templates/syntax.css +0 -58
- data/templates/user.css +0 -1
File without changes
|
File without changes
|
File without changes
|
data/spec/support/shared.rb
CHANGED
@@ -13,10 +13,6 @@ shared_examples_for "e-book" do
|
|
13
13
|
expect(mybook.join("text")).to be_directory
|
14
14
|
end
|
15
15
|
|
16
|
-
it "creates code directory" do
|
17
|
-
expect(mybook.join("code")).to be_directory
|
18
|
-
end
|
19
|
-
|
20
16
|
it "creates template directory" do
|
21
17
|
expect(mybook.join("templates")).to be_directory
|
22
18
|
end
|
@@ -29,27 +25,35 @@ shared_examples_for "e-book" do
|
|
29
25
|
expect(mybook.join("config/helper.rb")).to be_file
|
30
26
|
end
|
31
27
|
|
32
|
-
it "copies sample
|
33
|
-
expect(mybook.join("text/
|
28
|
+
it "copies sample texts" do
|
29
|
+
expect(mybook.join("text/01_Getting_Started.md")).to be_file
|
30
|
+
expect(mybook.join("text/02_Creating_Chapters.md")).to be_file
|
31
|
+
expect(mybook.join("text/03_Syntax_Highlighting.erb")).to be_file
|
32
|
+
expect(mybook.join("text/04_Dynamic_Content.erb")).to be_file
|
33
|
+
expect(mybook.join("text/05_Exporting_Files.md")).to be_file
|
34
34
|
end
|
35
35
|
|
36
36
|
it "copies Guardfile" do
|
37
37
|
expect(mybook.join("Guardfile")).to be_file
|
38
38
|
end
|
39
39
|
|
40
|
+
it "copies stylesheets" do
|
41
|
+
expect(mybook.join("templates/styles")).to be_directory
|
42
|
+
expect(mybook.join("templates/styles/epub.scss")).to be_file
|
43
|
+
expect(mybook.join("templates/styles/print.scss")).to be_file
|
44
|
+
expect(mybook.join("templates/styles/pdf.scss")).to be_file
|
45
|
+
expect(mybook.join("templates/styles/html.scss")).to be_file
|
46
|
+
end
|
47
|
+
|
40
48
|
it "copies Gemfile" do
|
41
49
|
expect(mybook.join("Gemfile")).to be_file
|
42
50
|
end
|
43
51
|
|
44
52
|
it "copies html template files" do
|
45
|
-
expect(mybook.join("templates/html/user.css")).to be_file
|
46
|
-
expect(mybook.join("templates/html/layout.css")).to be_file
|
47
53
|
expect(mybook.join("templates/html/layout.erb")).to be_file
|
48
|
-
expect(mybook.join("templates/html/syntax.css")).to be_file
|
49
54
|
end
|
50
55
|
|
51
56
|
it "copies epub template files" do
|
52
|
-
expect(mybook.join("templates/epub/user.css")).to be_file
|
53
57
|
expect(mybook.join("templates/epub/cover.erb")).to be_file
|
54
58
|
expect(mybook.join("templates/epub/cover.png")).to be_file
|
55
59
|
expect(mybook.join("templates/epub/page.erb")).to be_file
|
data/templates/Gemfile
CHANGED
@@ -1,3 +1,3 @@
|
|
1
|
-
source
|
2
|
-
gem
|
3
|
-
|
1
|
+
source 'https://rubygems.org'
|
2
|
+
gem 'kitabu'
|
3
|
+
gem 'guard-shell'
|
data/templates/Guardfile
CHANGED
data/templates/config.erb
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
# The book's title. Will be used everywhere!
|
2
|
-
title: "
|
2
|
+
title: "Kitabu"
|
3
3
|
|
4
4
|
# The book's language.
|
5
5
|
language: en
|
@@ -22,10 +22,10 @@ publisher: "<%= @name %>"
|
|
22
22
|
published_at: "<%= Date.today %>"
|
23
23
|
|
24
24
|
# Some book description.
|
25
|
-
subject: "
|
25
|
+
subject: "This guide will help you understand how all of the pieces fit together on Kitabu."
|
26
26
|
|
27
27
|
# Some keywords that identify this book.
|
28
|
-
keywords: "
|
28
|
+
keywords: "kitabu, e-book, kindlegen, epub, mobi, pdf, prince"
|
29
29
|
|
30
30
|
# Some unique identification. Works great with your domain
|
31
31
|
# like `http://yourbook.example.com`.
|
@@ -40,5 +40,5 @@ identifier:
|
|
40
40
|
authors:
|
41
41
|
- "<%= @name %>"
|
42
42
|
|
43
|
-
#
|
44
|
-
|
43
|
+
# Syntax highlight theme. Can be any of supported by Rouge.
|
44
|
+
theme: github
|
data/templates/cover.erb
CHANGED
@@ -2,15 +2,16 @@
|
|
2
2
|
<!DOCTYPE html PUBLIC
|
3
3
|
"-//W3C//DTD XHTML 1.1//EN"
|
4
4
|
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
|
5
|
-
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="<%= language %>">
|
5
|
+
<html class="epub" xmlns="http://www.w3.org/1999/xhtml" xml:lang="<%= language %>">
|
6
6
|
<head>
|
7
7
|
<title><%= title %></title>
|
8
|
-
<link
|
8
|
+
<link name="stylesheet" rel="stylesheet" type="text/css" href="styles/epub.css" />
|
9
9
|
<meta http-equiv="Content-Type" content="application/xhtml+xml; charset=utf-8" />
|
10
10
|
</head>
|
11
|
+
|
11
12
|
<body>
|
12
13
|
<div>
|
13
|
-
|
14
|
+
<h1><%= title %></h1>
|
14
15
|
</div>
|
15
16
|
</body>
|
16
17
|
</html>
|
data/templates/epub.erb
CHANGED
@@ -1,10 +1,11 @@
|
|
1
1
|
<?xml version="1.0" encoding="UTF-8"?>
|
2
2
|
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
|
3
|
-
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="<%= language %>">
|
3
|
+
<html class="epub" xmlns="http://www.w3.org/1999/xhtml" xml:lang="<%= language %>">
|
4
4
|
<head>
|
5
5
|
<title></title>
|
6
6
|
<meta http-equiv="Content-type" content="text/html; charset=utf-8" />
|
7
|
-
<link rel="stylesheet" type="text/css" href="
|
7
|
+
<link name="stylesheet" rel="stylesheet" type="text/css" href="styles/epub.css" />
|
8
|
+
<%= highlight_theme %>
|
8
9
|
</head>
|
9
10
|
|
10
11
|
<body>
|
data/templates/helper.rb
CHANGED
@@ -1,29 +1,28 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
#
|
1
|
+
module Kitabu
|
2
|
+
module Helpers
|
3
|
+
def lexers_list
|
4
|
+
buffer = '<ul class="lexers">'
|
5
|
+
|
6
|
+
Rouge::Lexers.constants.each do |const|
|
7
|
+
lexer = Rouge::Lexers.const_get(const)
|
8
|
+
|
9
|
+
begin
|
10
|
+
title = lexer.title
|
11
|
+
tag = lexer.tag
|
12
|
+
description = lexer.desc
|
13
|
+
rescue Exception => e
|
14
|
+
next
|
15
|
+
end
|
16
|
+
|
17
|
+
buffer << '<li>'
|
18
|
+
buffer << "<strong>#{title}</strong> "
|
19
|
+
buffer << "<code>#{tag}</code><br>"
|
20
|
+
buffer << "<span>#{description}</span>"
|
21
|
+
buffer << '</li>'
|
22
|
+
end
|
23
|
+
|
24
|
+
buffer << '</ul>'
|
25
|
+
buffer
|
26
|
+
end
|
27
|
+
end
|
28
|
+
end
|
File without changes
|
Binary file
|
@@ -0,0 +1,19 @@
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
2
|
+
<svg width="79px" height="108px" viewBox="0 0 79 108" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:sketch="http://www.bohemiancoding.com/sketch/ns">
|
3
|
+
<!-- Generator: Sketch 3.2.2 (9983) - http://www.bohemiancoding.com/sketch -->
|
4
|
+
<title>kitabu-icon</title>
|
5
|
+
<desc>Created with Sketch.</desc>
|
6
|
+
<defs></defs>
|
7
|
+
<g id="Page-1" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd" sketch:type="MSPage">
|
8
|
+
<g id="Artboard-1" sketch:type="MSArtboardGroup" transform="translate(-731.000000, -27.000000)" fill="#FFFFFF">
|
9
|
+
<g id="kitabu-icon" sketch:type="MSLayerGroup" transform="translate(731.000000, 27.000000)">
|
10
|
+
<g id="icon" transform="translate(0.895522, 0.000000)" sketch:type="MSShapeGroup">
|
11
|
+
<path d="M22.5432836,0.158684932 L22.5432836,0.225876712 L0.0402985075,22.6918219 L0.0402985075,107.69689 L77.9477612,107.69689 L77.9477612,0.158684932 L22.5432836,0.158684932 L22.5432836,0.158684932 Z M68.9925373,98.7379863 L8.99552239,98.7379863 L8.99552239,31.650726 L31.4985075,31.650726 L31.4985075,9.11758904 L68.9925373,9.11758904 L68.9925373,98.7379863 L68.9925373,98.7379863 Z" id="Fill-811"></path>
|
12
|
+
<path d="M16.9567164,41.0710137 L53.0014925,41.0710137 L53.0014925,48.2246986 L16.9567164,48.2246986 L16.9567164,41.0710137 Z" id="Fill-812"></path>
|
13
|
+
<path d="M16.9567164,57.1895753 L42.4641791,57.1895753 L42.4641791,64.3432603 L16.9567164,64.3432603 L16.9567164,57.1895753 Z" id="Fill-813"></path>
|
14
|
+
<path d="M16.9567164,73.2006301 L60.7552239,73.2006301 L60.7552239,80.3543151 L16.9567164,80.3543151 L16.9567164,73.2006301 Z" id="Fill-814"></path>
|
15
|
+
</g>
|
16
|
+
</g>
|
17
|
+
</g>
|
18
|
+
</g>
|
19
|
+
</svg>
|
Binary file
|
@@ -0,0 +1,14 @@
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
2
|
+
<svg width="197px" height="63px" viewBox="0 0 197 63" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:sketch="http://www.bohemiancoding.com/sketch/ns">
|
3
|
+
<!-- Generator: Sketch 3.2.2 (9983) - http://www.bohemiancoding.com/sketch -->
|
4
|
+
<title>kitabu-word</title>
|
5
|
+
<desc>Created with Sketch.</desc>
|
6
|
+
<defs></defs>
|
7
|
+
<g id="Page-1" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd" sketch:type="MSPage">
|
8
|
+
<g id="Artboard-1" sketch:type="MSArtboardGroup" transform="translate(-76.000000, -61.000000)" fill="#FFFFFF">
|
9
|
+
<g id="kitabu-word" sketch:type="MSLayerGroup" transform="translate(76.000000, 61.000000)">
|
10
|
+
<path d="M28.5288568,61.6462919 C30.9812881,61.6462919 32.9263198,59.7041663 32.9263198,57.2553991 C32.9263198,56.4109967 32.67262,55.482154 31.9960872,54.5533113 L19.5647976,38.2563439 L30.6430217,29.8123193 C31.7423874,28.9679169 32.3343536,27.6168729 32.3343536,26.3502692 C32.3343536,23.9015021 30.3893219,21.9593765 27.9368906,21.9593765 C26.9220914,21.9593765 26.0764255,22.2126972 24.9770597,23.0570997 L9.67050582,35.0476145 L9.67050582,5.24020784 C9.67050582,2.70700047 7.64090751,0.849315068 5.10390963,0.849315068 C2.48234515,0.849315068 0.537313433,2.70700047 0.537313433,5.24020784 L0.537313433,57.2553991 C0.537313433,59.7886065 2.48234515,61.6462919 5.10390963,61.6462919 C7.64090751,61.6462919 9.67050582,59.7886065 9.67050582,57.2553991 L9.67050582,45.0960038 L12.3766369,42.9849976 L24.9770597,59.8730468 C25.7381591,60.8863297 26.9220914,61.6462919 28.5288568,61.6462919 L28.5288568,61.6462919 Z M47.9791739,26.5191497 C47.9791739,23.9859424 45.9495756,21.9593765 43.4125777,21.9593765 C40.8755798,21.9593765 38.8459815,23.9859424 38.8459815,26.5191497 L38.8459815,57.0865187 C38.8459815,59.619726 40.8755798,61.6462919 43.4125777,61.6462919 C45.9495756,61.6462919 47.9791739,59.619726 47.9791739,57.0865187 L47.9791739,26.5191497 Z M43.4125777,17.3996032 C46.9643747,17.3996032 48.9094065,15.3730373 48.9094065,12.0798677 C48.9094065,8.19561644 46.9643747,6.50681153 43.4125777,6.50681153 C39.9453473,6.50681153 38.0003155,8.19561644 38.0003155,12.0798677 C38.0003155,15.3730373 39.9453473,17.3996032 43.4125777,17.3996032 L43.4125777,17.3996032 Z M59.3956644,22.6348984 L57.4506327,22.6348984 C55.3364678,22.6348984 53.6451358,24.3237034 53.6451358,26.4347095 C53.6451358,28.5457156 55.3364678,30.2345205 57.4506327,30.2345205 L59.3956644,30.2345205 L59.3956644,50.1624185 C59.3956644,56.8331979 64.0468272,61.6462919 71.5732542,61.6462919 C73.7719857,61.6462919 75.5478843,59.8730468 75.5478843,57.6776004 C75.5478843,55.482154 73.7719857,53.7089088 71.5732542,53.7089088 C70.0510555,53.7089088 68.3597236,52.6111856 68.3597236,50.66906 L68.3597236,30.2345205 L72.1652204,30.2345205 C74.2793853,30.2345205 75.9707172,28.5457156 75.9707172,26.4347095 C75.9707172,24.3237034 74.2793853,22.6348984 72.1652204,22.6348984 L68.3597236,22.6348984 L68.3597236,15.5419178 C68.3597236,13.0931507 66.3301253,11.0665848 63.877694,11.0665848 C61.4252627,11.0665848 59.3956644,13.0931507 59.3956644,15.5419178 L59.3956644,22.6348984 Z M97.4506327,29.5589986 C102.355495,29.5589986 105.146193,32.092206 105.146193,35.892017 L105.146193,37.4119414 L94.0679688,37.4119414 C86.710675,37.4119414 80.3681802,41.4650732 80.3681802,49.3180161 C80.3681802,56.9176382 85.865009,62.0684932 94.1525354,62.0684932 C99.2265312,62.0684932 102.947461,60.8018895 105.23076,57.1709589 C105.23076,59.619726 107.260358,61.6462919 109.712789,61.6462919 C112.16522,61.6462919 114.194819,59.619726 114.194819,57.1709589 L114.194819,35.554256 C114.194819,26.60359 107.936891,21.452735 97.4506327,21.452735 C90.1779054,21.452735 85.9495756,24.2392631 83.5817109,26.8569107 C82.8206115,27.7013132 82.4823451,28.7145961 82.4823451,29.6434388 C82.4823451,31.8388852 84.2582437,33.6121304 86.4569752,33.6121304 C87.4717743,33.6121304 88.1483071,33.3588096 88.9939731,32.7677279 C91.108138,31.2478035 93.7297024,29.5589986 97.4506327,29.5589986 L97.4506327,29.5589986 Z M96.5204001,54.468871 C91.7846707,54.468871 89.5013726,52.5267454 89.5013726,49.3180161 C89.5013726,46.2781672 91.5309709,44.5049221 95.2519012,44.5049221 L105.146193,44.5049221 L105.146193,46.8692489 C105.146193,51.5979027 101.00243,54.468871 96.5204001,54.468871 L96.5204001,54.468871 Z M131.361838,33.5276901 C131.361838,33.5276901 134.659935,29.2212376 139.733931,29.2212376 C145.484459,29.2212376 148.782557,33.4432499 148.782557,41.8028342 C148.782557,50.0779783 145.569026,54.2999906 139.733931,54.2999906 C134.829068,54.2999906 131.361838,51.006821 131.361838,45.180444 L131.361838,33.5276901 Z M140.664163,21.452735 C136.604967,21.452735 133.05317,23.1415399 131.361838,24.8303448 L131.361838,5.40908833 C131.361838,2.87588096 129.332239,0.849315068 126.795242,0.849315068 C124.258244,0.849315068 122.228645,2.87588096 122.228645,5.40908833 L122.228645,45.180444 C122.228645,56.4109967 129.501373,62.0684932 139.733931,62.0684932 C151.150421,62.0684932 157.831182,55.5665942 157.831182,41.8028342 C157.831182,28.0390742 151.319554,21.452735 140.664163,21.452735 L140.664163,21.452735 Z M167.894607,21.9593765 C165.357609,21.9593765 163.328011,23.9859424 163.328011,26.5191497 L163.328011,46.193727 C163.328011,54.468871 166.456975,62.0684932 180.072197,62.0684932 C193.602853,62.0684932 196.731817,54.468871 196.731817,46.193727 L196.731817,26.5191497 C196.731817,23.9859424 194.702218,21.9593765 192.16522,21.9593765 C189.628223,21.9593765 187.598624,23.9859424 187.598624,26.5191497 L187.598624,46.193727 C187.598624,50.0779783 186.245559,53.7933491 180.072197,53.7933491 C173.814269,53.7933491 172.461203,50.0779783 172.461203,46.193727 L172.461203,26.5191497 C172.461203,23.9859424 170.431605,21.9593765 167.894607,21.9593765 L167.894607,21.9593765 Z" id="kitabu" sketch:type="MSShapeGroup"></path>
|
11
|
+
</g>
|
12
|
+
</g>
|
13
|
+
</g>
|
14
|
+
</svg>
|
Binary file
|
@@ -0,0 +1,20 @@
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
2
|
+
<svg width="299px" height="108px" viewBox="0 0 299 108" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:sketch="http://www.bohemiancoding.com/sketch/ns">
|
3
|
+
<!-- Generator: Sketch 3.2.2 (9983) - http://www.bohemiancoding.com/sketch -->
|
4
|
+
<title>kitabu</title>
|
5
|
+
<desc>Created with Sketch.</desc>
|
6
|
+
<defs></defs>
|
7
|
+
<g id="Page-1" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd" sketch:type="MSPage">
|
8
|
+
<g id="Artboard-1" sketch:type="MSArtboardGroup" transform="translate(-306.000000, -171.000000)" fill="#FFFFFF">
|
9
|
+
<g id="kitabu" sketch:type="MSLayerGroup" transform="translate(306.000000, 171.000000)">
|
10
|
+
<g id="icon" transform="translate(220.895522, 0.000000)" sketch:type="MSShapeGroup">
|
11
|
+
<path d="M22.5432836,0.158684932 L22.5432836,0.225876712 L0.0402985075,22.6918219 L0.0402985075,107.69689 L77.9477612,107.69689 L77.9477612,0.158684932 L22.5432836,0.158684932 L22.5432836,0.158684932 Z M68.9925373,98.7379863 L8.99552239,98.7379863 L8.99552239,31.650726 L31.4985075,31.650726 L31.4985075,9.11758904 L68.9925373,9.11758904 L68.9925373,98.7379863 L68.9925373,98.7379863 Z" id="Fill-811"></path>
|
12
|
+
<path d="M16.9567164,41.0710137 L53.0014925,41.0710137 L53.0014925,48.2246986 L16.9567164,48.2246986 L16.9567164,41.0710137 Z" id="Fill-812"></path>
|
13
|
+
<path d="M16.9567164,57.1895753 L42.4641791,57.1895753 L42.4641791,64.3432603 L16.9567164,64.3432603 L16.9567164,57.1895753 Z" id="Fill-813"></path>
|
14
|
+
<path d="M16.9567164,73.2006301 L60.7552239,73.2006301 L60.7552239,80.3543151 L16.9567164,80.3543151 L16.9567164,73.2006301 Z" id="Fill-814"></path>
|
15
|
+
</g>
|
16
|
+
<path d="M28.5288568,92.6462919 C30.9812881,92.6462919 32.9263198,90.7041663 32.9263198,88.2553991 C32.9263198,87.4109967 32.67262,86.482154 31.9960872,85.5533113 L19.5647976,69.2563439 L30.6430217,60.8123193 C31.7423874,59.9679169 32.3343536,58.6168729 32.3343536,57.3502692 C32.3343536,54.9015021 30.3893219,52.9593765 27.9368906,52.9593765 C26.9220914,52.9593765 26.0764255,53.2126972 24.9770597,54.0570997 L9.67050582,66.0476145 L9.67050582,36.2402078 C9.67050582,33.7070005 7.64090751,31.8493151 5.10390963,31.8493151 C2.48234515,31.8493151 0.537313433,33.7070005 0.537313433,36.2402078 L0.537313433,88.2553991 C0.537313433,90.7886065 2.48234515,92.6462919 5.10390963,92.6462919 C7.64090751,92.6462919 9.67050582,90.7886065 9.67050582,88.2553991 L9.67050582,76.0960038 L12.3766369,73.9849976 L24.9770597,90.8730468 C25.7381591,91.8863297 26.9220914,92.6462919 28.5288568,92.6462919 L28.5288568,92.6462919 Z M47.9791739,57.5191497 C47.9791739,54.9859424 45.9495756,52.9593765 43.4125777,52.9593765 C40.8755798,52.9593765 38.8459815,54.9859424 38.8459815,57.5191497 L38.8459815,88.0865187 C38.8459815,90.619726 40.8755798,92.6462919 43.4125777,92.6462919 C45.9495756,92.6462919 47.9791739,90.619726 47.9791739,88.0865187 L47.9791739,57.5191497 Z M43.4125777,48.3996032 C46.9643747,48.3996032 48.9094065,46.3730373 48.9094065,43.0798677 C48.9094065,39.1956164 46.9643747,37.5068115 43.4125777,37.5068115 C39.9453473,37.5068115 38.0003155,39.1956164 38.0003155,43.0798677 C38.0003155,46.3730373 39.9453473,48.3996032 43.4125777,48.3996032 L43.4125777,48.3996032 Z M59.3956644,53.6348984 L57.4506327,53.6348984 C55.3364678,53.6348984 53.6451358,55.3237034 53.6451358,57.4347095 C53.6451358,59.5457156 55.3364678,61.2345205 57.4506327,61.2345205 L59.3956644,61.2345205 L59.3956644,81.1624185 C59.3956644,87.8331979 64.0468272,92.6462919 71.5732542,92.6462919 C73.7719857,92.6462919 75.5478843,90.8730468 75.5478843,88.6776004 C75.5478843,86.482154 73.7719857,84.7089088 71.5732542,84.7089088 C70.0510555,84.7089088 68.3597236,83.6111856 68.3597236,81.66906 L68.3597236,61.2345205 L72.1652204,61.2345205 C74.2793853,61.2345205 75.9707172,59.5457156 75.9707172,57.4347095 C75.9707172,55.3237034 74.2793853,53.6348984 72.1652204,53.6348984 L68.3597236,53.6348984 L68.3597236,46.5419178 C68.3597236,44.0931507 66.3301253,42.0665848 63.877694,42.0665848 C61.4252627,42.0665848 59.3956644,44.0931507 59.3956644,46.5419178 L59.3956644,53.6348984 Z M97.4506327,60.5589986 C102.355495,60.5589986 105.146193,63.092206 105.146193,66.892017 L105.146193,68.4119414 L94.0679688,68.4119414 C86.710675,68.4119414 80.3681802,72.4650732 80.3681802,80.3180161 C80.3681802,87.9176382 85.865009,93.0684932 94.1525354,93.0684932 C99.2265312,93.0684932 102.947461,91.8018895 105.23076,88.1709589 C105.23076,90.619726 107.260358,92.6462919 109.712789,92.6462919 C112.16522,92.6462919 114.194819,90.619726 114.194819,88.1709589 L114.194819,66.554256 C114.194819,57.60359 107.936891,52.452735 97.4506327,52.452735 C90.1779054,52.452735 85.9495756,55.2392631 83.5817109,57.8569107 C82.8206115,58.7013132 82.4823451,59.7145961 82.4823451,60.6434388 C82.4823451,62.8388852 84.2582437,64.6121304 86.4569752,64.6121304 C87.4717743,64.6121304 88.1483071,64.3588096 88.9939731,63.7677279 C91.108138,62.2478035 93.7297024,60.5589986 97.4506327,60.5589986 L97.4506327,60.5589986 Z M96.5204001,85.468871 C91.7846707,85.468871 89.5013726,83.5267454 89.5013726,80.3180161 C89.5013726,77.2781672 91.5309709,75.5049221 95.2519012,75.5049221 L105.146193,75.5049221 L105.146193,77.8692489 C105.146193,82.5979027 101.00243,85.468871 96.5204001,85.468871 L96.5204001,85.468871 Z M131.361838,64.5276901 C131.361838,64.5276901 134.659935,60.2212376 139.733931,60.2212376 C145.484459,60.2212376 148.782557,64.4432499 148.782557,72.8028342 C148.782557,81.0779783 145.569026,85.2999906 139.733931,85.2999906 C134.829068,85.2999906 131.361838,82.006821 131.361838,76.180444 L131.361838,64.5276901 Z M140.664163,52.452735 C136.604967,52.452735 133.05317,54.1415399 131.361838,55.8303448 L131.361838,36.4090883 C131.361838,33.875881 129.332239,31.8493151 126.795242,31.8493151 C124.258244,31.8493151 122.228645,33.875881 122.228645,36.4090883 L122.228645,76.180444 C122.228645,87.4109967 129.501373,93.0684932 139.733931,93.0684932 C151.150421,93.0684932 157.831182,86.5665942 157.831182,72.8028342 C157.831182,59.0390742 151.319554,52.452735 140.664163,52.452735 L140.664163,52.452735 Z M167.894607,52.9593765 C165.357609,52.9593765 163.328011,54.9859424 163.328011,57.5191497 L163.328011,77.193727 C163.328011,85.468871 166.456975,93.0684932 180.072197,93.0684932 C193.602853,93.0684932 196.731817,85.468871 196.731817,77.193727 L196.731817,57.5191497 C196.731817,54.9859424 194.702218,52.9593765 192.16522,52.9593765 C189.628223,52.9593765 187.598624,54.9859424 187.598624,57.5191497 L187.598624,77.193727 C187.598624,81.0779783 186.245559,84.7933491 180.072197,84.7933491 C173.814269,84.7933491 172.461203,81.0779783 172.461203,77.193727 L172.461203,57.5191497 C172.461203,54.9859424 170.431605,52.9593765 167.894607,52.9593765 L167.894607,52.9593765 Z" sketch:type="MSShapeGroup"></path>
|
17
|
+
</g>
|
18
|
+
</g>
|
19
|
+
</g>
|
20
|
+
</svg>
|
@@ -2,15 +2,16 @@
|
|
2
2
|
<!DOCTYPE html PUBLIC
|
3
3
|
"-//W3C//DTD XHTML 1.1//EN"
|
4
4
|
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
|
5
|
-
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="<%= language %>">
|
5
|
+
<html class="epub" xmlns="http://www.w3.org/1999/xhtml" xml:lang="<%= language %>">
|
6
6
|
<head>
|
7
7
|
<title><%= title %></title>
|
8
|
-
<link
|
8
|
+
<link name="stylesheet" rel="stylesheet" type="text/css" href="styles/epub.css" />
|
9
9
|
<meta http-equiv="Content-Type" content="application/xhtml+xml; charset=utf-8" />
|
10
10
|
</head>
|
11
|
+
|
11
12
|
<body>
|
12
13
|
<div>
|
13
|
-
|
14
|
+
<h1><%= title %></h1>
|
14
15
|
</div>
|
15
16
|
</body>
|
16
17
|
</html>
|
Binary file
|
@@ -0,0 +1,16 @@
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
2
|
+
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
|
3
|
+
<html class="epub" xmlns="http://www.w3.org/1999/xhtml" xml:lang="<%= language %>">
|
4
|
+
<head>
|
5
|
+
<title></title>
|
6
|
+
<meta http-equiv="Content-type" content="text/html; charset=utf-8" />
|
7
|
+
<link name="stylesheet" rel="stylesheet" type="text/css" href="styles/epub.css" />
|
8
|
+
<%= highlight_theme %>
|
9
|
+
</head>
|
10
|
+
|
11
|
+
<body>
|
12
|
+
<div class="chapter">
|
13
|
+
<%= content %>
|
14
|
+
</div>
|
15
|
+
</body>
|
16
|
+
</html>
|
@@ -1,29 +1,29 @@
|
|
1
|
-
<!
|
2
|
-
|
3
|
-
<html>
|
1
|
+
<!doctype html>
|
2
|
+
<html class="html">
|
4
3
|
<head>
|
5
4
|
<title><%= title %></title>
|
6
5
|
<meta http-equiv="Content-type" content="text/html; charset=utf-8" />
|
7
|
-
<link rel="stylesheet" type="text/css" href="
|
8
|
-
<link rel="stylesheet" type="text/css" href="../templates/html/syntax.css"/>
|
9
|
-
<link rel="stylesheet" type="text/css" href="../templates/html/user.css"/>
|
10
|
-
|
6
|
+
<link name="stylesheet" rel="stylesheet" type="text/css" href="styles/html.css" />
|
11
7
|
<meta name="author" content="<%= authors.join(', ') %>" />
|
12
8
|
<meta name="subject" content="<%= subject %>" />
|
13
9
|
<meta name="keywords" content="<%= keywords %>" />
|
14
10
|
<meta name="date" content="<%= published_at %>" />
|
11
|
+
<%= highlight_theme %>
|
15
12
|
</head>
|
13
|
+
|
16
14
|
<body>
|
17
15
|
<div class="frontcover container">
|
18
16
|
<div>
|
19
|
-
<
|
17
|
+
<div class="logo"><%= image_tag 'kitabu.svg', alt: 'Kitabu' %></div>
|
20
18
|
<p class="description"><%= subject %></p>
|
21
19
|
<p class="authors"><%= authors.to_sentence %></p>
|
22
20
|
</div>
|
23
21
|
</div>
|
24
22
|
|
23
|
+
<div class="white-page"></div>
|
24
|
+
|
25
25
|
<div class="table-of-contents">
|
26
|
-
<h2 class="no-toc">
|
26
|
+
<h2 class="no-toc">Contents</h2>
|
27
27
|
<div id="toc">
|
28
28
|
<%= toc %>
|
29
29
|
</div>
|
@@ -33,12 +33,23 @@
|
|
33
33
|
<%= content %>
|
34
34
|
</div>
|
35
35
|
|
36
|
+
<% if changelog %>
|
37
|
+
<div class="container changelog">
|
38
|
+
<%= changelog %>
|
39
|
+
</div>
|
40
|
+
<% end %>
|
41
|
+
|
42
|
+
<div class="white-page"></div>
|
43
|
+
|
36
44
|
<div class="imprint container">
|
37
45
|
<div>
|
38
46
|
<h2><%= title %></h2>
|
39
|
-
<p><%=
|
40
|
-
<p><%=
|
47
|
+
<p class="description"><%= subject %></p>
|
48
|
+
<p class="authors"><%= authors.to_sentence %></p>
|
49
|
+
<p class="copyright"><%= copyright %></p>
|
41
50
|
</div>
|
42
51
|
</div>
|
52
|
+
|
53
|
+
<a href="#" class="go-top">⇧</a>
|
43
54
|
</body>
|
44
55
|
</html>
|
@@ -0,0 +1 @@
|
|
1
|
+
@import './files/normalize';
|
@@ -0,0 +1,427 @@
|
|
1
|
+
/*! normalize.css v3.0.2 | MIT License | git.io/normalize */
|
2
|
+
|
3
|
+
/**
|
4
|
+
* 1. Set default font family to sans-serif.
|
5
|
+
* 2. Prevent iOS text size adjust after orientation change, without disabling
|
6
|
+
* user zoom.
|
7
|
+
*/
|
8
|
+
|
9
|
+
html {
|
10
|
+
font-family: sans-serif; /* 1 */
|
11
|
+
-ms-text-size-adjust: 100%; /* 2 */
|
12
|
+
-webkit-text-size-adjust: 100%; /* 2 */
|
13
|
+
}
|
14
|
+
|
15
|
+
/**
|
16
|
+
* Remove default margin.
|
17
|
+
*/
|
18
|
+
|
19
|
+
body {
|
20
|
+
margin: 0;
|
21
|
+
}
|
22
|
+
|
23
|
+
/* HTML5 display definitions
|
24
|
+
========================================================================== */
|
25
|
+
|
26
|
+
/**
|
27
|
+
* Correct `block` display not defined for any HTML5 element in IE 8/9.
|
28
|
+
* Correct `block` display not defined for `details` or `summary` in IE 10/11
|
29
|
+
* and Firefox.
|
30
|
+
* Correct `block` display not defined for `main` in IE 11.
|
31
|
+
*/
|
32
|
+
|
33
|
+
article,
|
34
|
+
aside,
|
35
|
+
details,
|
36
|
+
figcaption,
|
37
|
+
figure,
|
38
|
+
footer,
|
39
|
+
header,
|
40
|
+
hgroup,
|
41
|
+
main,
|
42
|
+
menu,
|
43
|
+
nav,
|
44
|
+
section,
|
45
|
+
summary {
|
46
|
+
display: block;
|
47
|
+
}
|
48
|
+
|
49
|
+
/**
|
50
|
+
* 1. Correct `inline-block` display not defined in IE 8/9.
|
51
|
+
* 2. Normalize vertical alignment of `progress` in Chrome, Firefox, and Opera.
|
52
|
+
*/
|
53
|
+
|
54
|
+
audio,
|
55
|
+
canvas,
|
56
|
+
progress,
|
57
|
+
video {
|
58
|
+
display: inline-block; /* 1 */
|
59
|
+
vertical-align: baseline; /* 2 */
|
60
|
+
}
|
61
|
+
|
62
|
+
/**
|
63
|
+
* Prevent modern browsers from displaying `audio` without controls.
|
64
|
+
* Remove excess height in iOS 5 devices.
|
65
|
+
*/
|
66
|
+
|
67
|
+
audio:not([controls]) {
|
68
|
+
display: none;
|
69
|
+
height: 0;
|
70
|
+
}
|
71
|
+
|
72
|
+
/**
|
73
|
+
* Address `[hidden]` styling not present in IE 8/9/10.
|
74
|
+
* Hide the `template` element in IE 8/9/11, Safari, and Firefox < 22.
|
75
|
+
*/
|
76
|
+
|
77
|
+
[hidden],
|
78
|
+
template {
|
79
|
+
display: none;
|
80
|
+
}
|
81
|
+
|
82
|
+
/* Links
|
83
|
+
========================================================================== */
|
84
|
+
|
85
|
+
/**
|
86
|
+
* Remove the gray background color from active links in IE 10.
|
87
|
+
*/
|
88
|
+
|
89
|
+
a {
|
90
|
+
background-color: transparent;
|
91
|
+
}
|
92
|
+
|
93
|
+
/**
|
94
|
+
* Improve readability when focused and also mouse hovered in all browsers.
|
95
|
+
*/
|
96
|
+
|
97
|
+
a:active,
|
98
|
+
a:hover {
|
99
|
+
outline: 0;
|
100
|
+
}
|
101
|
+
|
102
|
+
/* Text-level semantics
|
103
|
+
========================================================================== */
|
104
|
+
|
105
|
+
/**
|
106
|
+
* Address styling not present in IE 8/9/10/11, Safari, and Chrome.
|
107
|
+
*/
|
108
|
+
|
109
|
+
abbr[title] {
|
110
|
+
border-bottom: 1px dotted;
|
111
|
+
}
|
112
|
+
|
113
|
+
/**
|
114
|
+
* Address style set to `bolder` in Firefox 4+, Safari, and Chrome.
|
115
|
+
*/
|
116
|
+
|
117
|
+
b,
|
118
|
+
strong {
|
119
|
+
font-weight: bold;
|
120
|
+
}
|
121
|
+
|
122
|
+
/**
|
123
|
+
* Address styling not present in Safari and Chrome.
|
124
|
+
*/
|
125
|
+
|
126
|
+
dfn {
|
127
|
+
font-style: italic;
|
128
|
+
}
|
129
|
+
|
130
|
+
/**
|
131
|
+
* Address variable `h1` font-size and margin within `section` and `article`
|
132
|
+
* contexts in Firefox 4+, Safari, and Chrome.
|
133
|
+
*/
|
134
|
+
|
135
|
+
h1 {
|
136
|
+
font-size: 2em;
|
137
|
+
margin: 0.67em 0;
|
138
|
+
}
|
139
|
+
|
140
|
+
/**
|
141
|
+
* Address styling not present in IE 8/9.
|
142
|
+
*/
|
143
|
+
|
144
|
+
mark {
|
145
|
+
background: #ff0;
|
146
|
+
color: #000;
|
147
|
+
}
|
148
|
+
|
149
|
+
/**
|
150
|
+
* Address inconsistent and variable font size in all browsers.
|
151
|
+
*/
|
152
|
+
|
153
|
+
small {
|
154
|
+
font-size: 80%;
|
155
|
+
}
|
156
|
+
|
157
|
+
/**
|
158
|
+
* Prevent `sub` and `sup` affecting `line-height` in all browsers.
|
159
|
+
*/
|
160
|
+
|
161
|
+
sub,
|
162
|
+
sup {
|
163
|
+
font-size: 75%;
|
164
|
+
line-height: 0;
|
165
|
+
position: relative;
|
166
|
+
vertical-align: baseline;
|
167
|
+
}
|
168
|
+
|
169
|
+
sup {
|
170
|
+
top: -0.5em;
|
171
|
+
}
|
172
|
+
|
173
|
+
sub {
|
174
|
+
bottom: -0.25em;
|
175
|
+
}
|
176
|
+
|
177
|
+
/* Embedded content
|
178
|
+
========================================================================== */
|
179
|
+
|
180
|
+
/**
|
181
|
+
* Remove border when inside `a` element in IE 8/9/10.
|
182
|
+
*/
|
183
|
+
|
184
|
+
img {
|
185
|
+
border: 0;
|
186
|
+
}
|
187
|
+
|
188
|
+
/**
|
189
|
+
* Correct overflow not hidden in IE 9/10/11.
|
190
|
+
*/
|
191
|
+
|
192
|
+
svg:not(:root) {
|
193
|
+
overflow: hidden;
|
194
|
+
}
|
195
|
+
|
196
|
+
/* Grouping content
|
197
|
+
========================================================================== */
|
198
|
+
|
199
|
+
/**
|
200
|
+
* Address margin not present in IE 8/9 and Safari.
|
201
|
+
*/
|
202
|
+
|
203
|
+
figure {
|
204
|
+
margin: 1em 40px;
|
205
|
+
}
|
206
|
+
|
207
|
+
/**
|
208
|
+
* Address differences between Firefox and other browsers.
|
209
|
+
*/
|
210
|
+
|
211
|
+
hr {
|
212
|
+
-moz-box-sizing: content-box;
|
213
|
+
box-sizing: content-box;
|
214
|
+
height: 0;
|
215
|
+
}
|
216
|
+
|
217
|
+
/**
|
218
|
+
* Contain overflow in all browsers.
|
219
|
+
*/
|
220
|
+
|
221
|
+
pre {
|
222
|
+
overflow: auto;
|
223
|
+
}
|
224
|
+
|
225
|
+
/**
|
226
|
+
* Address odd `em`-unit font size rendering in all browsers.
|
227
|
+
*/
|
228
|
+
|
229
|
+
code,
|
230
|
+
kbd,
|
231
|
+
pre,
|
232
|
+
samp {
|
233
|
+
font-family: monospace, monospace;
|
234
|
+
font-size: 1em;
|
235
|
+
}
|
236
|
+
|
237
|
+
/* Forms
|
238
|
+
========================================================================== */
|
239
|
+
|
240
|
+
/**
|
241
|
+
* Known limitation: by default, Chrome and Safari on OS X allow very limited
|
242
|
+
* styling of `select`, unless a `border` property is set.
|
243
|
+
*/
|
244
|
+
|
245
|
+
/**
|
246
|
+
* 1. Correct color not being inherited.
|
247
|
+
* Known issue: affects color of disabled elements.
|
248
|
+
* 2. Correct font properties not being inherited.
|
249
|
+
* 3. Address margins set differently in Firefox 4+, Safari, and Chrome.
|
250
|
+
*/
|
251
|
+
|
252
|
+
button,
|
253
|
+
input,
|
254
|
+
optgroup,
|
255
|
+
select,
|
256
|
+
textarea {
|
257
|
+
color: inherit; /* 1 */
|
258
|
+
font: inherit; /* 2 */
|
259
|
+
margin: 0; /* 3 */
|
260
|
+
}
|
261
|
+
|
262
|
+
/**
|
263
|
+
* Address `overflow` set to `hidden` in IE 8/9/10/11.
|
264
|
+
*/
|
265
|
+
|
266
|
+
button {
|
267
|
+
overflow: visible;
|
268
|
+
}
|
269
|
+
|
270
|
+
/**
|
271
|
+
* Address inconsistent `text-transform` inheritance for `button` and `select`.
|
272
|
+
* All other form control elements do not inherit `text-transform` values.
|
273
|
+
* Correct `button` style inheritance in Firefox, IE 8/9/10/11, and Opera.
|
274
|
+
* Correct `select` style inheritance in Firefox.
|
275
|
+
*/
|
276
|
+
|
277
|
+
button,
|
278
|
+
select {
|
279
|
+
text-transform: none;
|
280
|
+
}
|
281
|
+
|
282
|
+
/**
|
283
|
+
* 1. Avoid the WebKit bug in Android 4.0.* where (2) destroys native `audio`
|
284
|
+
* and `video` controls.
|
285
|
+
* 2. Correct inability to style clickable `input` types in iOS.
|
286
|
+
* 3. Improve usability and consistency of cursor style between image-type
|
287
|
+
* `input` and others.
|
288
|
+
*/
|
289
|
+
|
290
|
+
button,
|
291
|
+
html input[type="button"], /* 1 */
|
292
|
+
input[type="reset"],
|
293
|
+
input[type="submit"] {
|
294
|
+
-webkit-appearance: button; /* 2 */
|
295
|
+
cursor: pointer; /* 3 */
|
296
|
+
}
|
297
|
+
|
298
|
+
/**
|
299
|
+
* Re-set default cursor for disabled elements.
|
300
|
+
*/
|
301
|
+
|
302
|
+
button[disabled],
|
303
|
+
html input[disabled] {
|
304
|
+
cursor: default;
|
305
|
+
}
|
306
|
+
|
307
|
+
/**
|
308
|
+
* Remove inner padding and border in Firefox 4+.
|
309
|
+
*/
|
310
|
+
|
311
|
+
button::-moz-focus-inner,
|
312
|
+
input::-moz-focus-inner {
|
313
|
+
border: 0;
|
314
|
+
padding: 0;
|
315
|
+
}
|
316
|
+
|
317
|
+
/**
|
318
|
+
* Address Firefox 4+ setting `line-height` on `input` using `!important` in
|
319
|
+
* the UA stylesheet.
|
320
|
+
*/
|
321
|
+
|
322
|
+
input {
|
323
|
+
line-height: normal;
|
324
|
+
}
|
325
|
+
|
326
|
+
/**
|
327
|
+
* It's recommended that you don't attempt to style these elements.
|
328
|
+
* Firefox's implementation doesn't respect box-sizing, padding, or width.
|
329
|
+
*
|
330
|
+
* 1. Address box sizing set to `content-box` in IE 8/9/10.
|
331
|
+
* 2. Remove excess padding in IE 8/9/10.
|
332
|
+
*/
|
333
|
+
|
334
|
+
input[type="checkbox"],
|
335
|
+
input[type="radio"] {
|
336
|
+
box-sizing: border-box; /* 1 */
|
337
|
+
padding: 0; /* 2 */
|
338
|
+
}
|
339
|
+
|
340
|
+
/**
|
341
|
+
* Fix the cursor style for Chrome's increment/decrement buttons. For certain
|
342
|
+
* `font-size` values of the `input`, it causes the cursor style of the
|
343
|
+
* decrement button to change from `default` to `text`.
|
344
|
+
*/
|
345
|
+
|
346
|
+
input[type="number"]::-webkit-inner-spin-button,
|
347
|
+
input[type="number"]::-webkit-outer-spin-button {
|
348
|
+
height: auto;
|
349
|
+
}
|
350
|
+
|
351
|
+
/**
|
352
|
+
* 1. Address `appearance` set to `searchfield` in Safari and Chrome.
|
353
|
+
* 2. Address `box-sizing` set to `border-box` in Safari and Chrome
|
354
|
+
* (include `-moz` to future-proof).
|
355
|
+
*/
|
356
|
+
|
357
|
+
input[type="search"] {
|
358
|
+
-webkit-appearance: textfield; /* 1 */
|
359
|
+
-moz-box-sizing: content-box;
|
360
|
+
-webkit-box-sizing: content-box; /* 2 */
|
361
|
+
box-sizing: content-box;
|
362
|
+
}
|
363
|
+
|
364
|
+
/**
|
365
|
+
* Remove inner padding and search cancel button in Safari and Chrome on OS X.
|
366
|
+
* Safari (but not Chrome) clips the cancel button when the search input has
|
367
|
+
* padding (and `textfield` appearance).
|
368
|
+
*/
|
369
|
+
|
370
|
+
input[type="search"]::-webkit-search-cancel-button,
|
371
|
+
input[type="search"]::-webkit-search-decoration {
|
372
|
+
-webkit-appearance: none;
|
373
|
+
}
|
374
|
+
|
375
|
+
/**
|
376
|
+
* Define consistent border, margin, and padding.
|
377
|
+
*/
|
378
|
+
|
379
|
+
fieldset {
|
380
|
+
border: 1px solid #c0c0c0;
|
381
|
+
margin: 0 2px;
|
382
|
+
padding: 0.35em 0.625em 0.75em;
|
383
|
+
}
|
384
|
+
|
385
|
+
/**
|
386
|
+
* 1. Correct `color` not being inherited in IE 8/9/10/11.
|
387
|
+
* 2. Remove padding so people aren't caught out if they zero out fieldsets.
|
388
|
+
*/
|
389
|
+
|
390
|
+
legend {
|
391
|
+
border: 0; /* 1 */
|
392
|
+
padding: 0; /* 2 */
|
393
|
+
}
|
394
|
+
|
395
|
+
/**
|
396
|
+
* Remove default vertical scrollbar in IE 8/9/10/11.
|
397
|
+
*/
|
398
|
+
|
399
|
+
textarea {
|
400
|
+
overflow: auto;
|
401
|
+
}
|
402
|
+
|
403
|
+
/**
|
404
|
+
* Don't inherit the `font-weight` (applied by a rule above).
|
405
|
+
* NOTE: the default cannot safely be changed in Chrome and Safari on OS X.
|
406
|
+
*/
|
407
|
+
|
408
|
+
optgroup {
|
409
|
+
font-weight: bold;
|
410
|
+
}
|
411
|
+
|
412
|
+
/* Tables
|
413
|
+
========================================================================== */
|
414
|
+
|
415
|
+
/**
|
416
|
+
* Remove most spacing between table cells.
|
417
|
+
*/
|
418
|
+
|
419
|
+
table {
|
420
|
+
border-collapse: collapse;
|
421
|
+
border-spacing: 0;
|
422
|
+
}
|
423
|
+
|
424
|
+
td,
|
425
|
+
th {
|
426
|
+
padding: 0;
|
427
|
+
}
|