asciidoctor-epub3 1.5.0.alpha.14 → 1.5.0.alpha.19

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 61c778469422ef65c9ae4f3ca20cb326a61fca5fc4733eabd1eb8eb0a71f9c61
4
- data.tar.gz: 8bac1f2fba3b11504dfe5a4020445fe4b2d2b9c6a01ecad1d9c1a1c45eb4ee3a
3
+ metadata.gz: 30d660ed4a7fc21dc01c61ae77515dbba77dd8bbbd7618e45709f7048745040c
4
+ data.tar.gz: f3b2d04be71c163e9ed29ae907f2a2c2ab00ecd3e6ecb329775952b5853ebf9d
5
5
  SHA512:
6
- metadata.gz: b5663adeb39345f53a7e80f8f0b2ebdeb253bf70011fc1428e0322a63b9570d2ba539fa6595297e576445dc53b668f3da1dd463d9548cbcff2fca40d83fd75fe
7
- data.tar.gz: 3d54e7f7ab62cd37306552267a7bd315fb6c970d185cf976912c0a57aac24b7f315386dbcd1d7e1c67afb038f66a17281e73c27c3f92ecaaa416bbddad8a0d16
6
+ metadata.gz: 06fb18e09b9ec33401e46168f85436c871accb1f3774b51a8f29373185ba1a538bb2f7a00663e37a43c778238b8bd55ac01883b58f8a173041b0fcb20acdea91
7
+ data.tar.gz: 248b718e05d9e8750dbb44117de81a04cdde271da64f96b720f145e54de61a19cf79d29e7f2dd4b2664f84b9c534c38d94ca84e6e87982839a31144c0cf0a3f2
@@ -5,6 +5,54 @@
5
5
  This document provides a high-level view of the changes to the {project-name} by release.
6
6
  For a detailed view of what has changed, refer to the {uri-repo}/commits/master[commit history] on GitHub.
7
7
 
8
+ == 1.5.0.alpha.19 (2020-10-21) - @slonopotamus
9
+
10
+ * add title and id support for literal blocks (#357)
11
+ * fix quotes not being properly escaped in section titles (#358)
12
+ * fix crash when encountering unsupported Asciidoctor node (#360)
13
+ * add support for 100%-wide table (#356)
14
+ * do not add multiple entries for same media files in book manifest (#370)
15
+ * do not add bogus entries to manifest when `:data-uri:` attribute is set (#371)
16
+ * add id support for listing blocks (#372)
17
+ * stop using deprecated `epub:type` for admonitions (#373)
18
+ * fix `epub:type` attributes for special sections (#374)
19
+ * fix font resize not working in iBooks (#368)
20
+ * fix visited link color in iBooks night mode (#366)
21
+
22
+ == 1.5.0.alpha.18 (2020-07-27) - @slonopotamus
23
+
24
+ * remove <b> from chapter subtitle (#123)
25
+ * improve tables support: cell content alignment, column width (#350)
26
+ * fix chapter titles to actually be chapter titles instead of document title (#343)
27
+ * store syntax highlighter CSS in a separate file (#339)
28
+ * initial landmarks support: appendix, bibliography, bodymatter, cover, frontmatter, glossary, index, preface, toc (#174)
29
+ * add support for in-document table of contents via `:toc:` document attribute (#174)
30
+ * add support for MathML (#10)
31
+ * rescale color palette to use darker shades of gray (#338)
32
+ * gracefully handle invalid `:front-cover-image:` value (#353)
33
+
34
+ == 1.5.0.alpha.17 (2020-05-25) - @slonopotamus
35
+
36
+ * support remote URLs for audio/video/image (#333, #334)
37
+
38
+ == 1.5.0.alpha.16 (2020-04-26) - @slonopotamus
39
+
40
+ * add basic audio and video support (#9)
41
+ * add support for `[horizontal]` definition list (#165)
42
+ * add proper handling of `:data-uri:` document attribute (#324)
43
+ * add support for customizable document splitting into chapters via `epub-chapter-level` attribute (#327)
44
+ * avoid outputting 'true' for unsupported blocks (#332)
45
+
46
+ == 1.5.0.alpha.15 (2020-03-11) - @slonopotamus
47
+
48
+ * support section numbering and captions (#20)
49
+ * fix `\<<anchor,link text>>` to show link text (#317)
50
+ * add xref ids to paragraphs (#317)
51
+ * support syntax highlighting with CodeRay and Rouge (#262)
52
+ * pygments.rb is no longer auto-activated
53
+ * add series metadata (#307)
54
+ * fix Sony Reader crash (#152)
55
+
8
56
  == 1.5.0.alpha.14 (2020-02-29) - @slonopotamus
9
57
 
10
58
  * support conversion of article documents to a single-chapter file
@@ -78,6 +126,7 @@ For a detailed view of what has changed, refer to the {uri-repo}/commits/master[
78
126
  * upgrade pygments.rb to 1.2.1 (#216)
79
127
  * gepub dependency is no longer locked to 1.0.2 and will use latest 1.0.x version
80
128
  * fix `-a ebook-validate` not working on Windows (#232)
129
+ * fix crash when inline pass macro `m` contains an icon (#375)
81
130
 
82
131
  == 1.5.0.alpha.9 (2019-04-04) - @mojavelinux
83
132
 
data/Gemfile CHANGED
@@ -13,13 +13,5 @@ end
13
13
 
14
14
  group :optional do
15
15
  # epubcheck-ruby might be safe to be converted into runtime dependency, but could have issues when packaged into asciidoctorj-epub3
16
- gem 'epubcheck-ruby', '~> 4.2.2.0'
17
- # We would like to make kindlegen a runtime dependency, but can't because of the way asciidoctorj-epub3 packaging works
18
- # See https://github.com/asciidoctor/asciidoctor-epub3/issues/288
19
- gem 'kindlegen', '~> 3.0.3'
20
- gem 'pygments.rb', '1.2.1'
21
- end
22
-
23
- group :docs do
24
- gem 'yard', require: false
16
+ gem 'epubcheck-ruby', '~> 4.2.4.0'
25
17
  end
data/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2014-2020 OpenDevise Inc. and the Asciidoctor Project
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
16
+ EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
17
+ MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
18
+ IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
19
+ DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
20
+ OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE
21
+ OR OTHER DEALINGS IN THE SOFTWARE.
@@ -1,6 +1,6 @@
1
1
  = {project-name}: A _native_ EPUB3 converter for AsciiDoc
2
2
  Dan Allen <https://github.com/mojavelinux[@mojavelinux]>; Sarah White <https://github.com/graphitefriction[@graphitefriction]>
3
- v1.5.0.alpha.14, 2020-02-29
3
+ v1.5.0.alpha.19, 2020-10-21
4
4
  // Settings:
5
5
  :experimental:
6
6
  :idprefix:
@@ -27,31 +27,30 @@ endif::[]
27
27
  :project-handle: asciidoctor-epub3
28
28
  // URIs:
29
29
  :uri-project: https://github.com/asciidoctor/{project-handle}
30
- :uri-gem: http://rubygems.org/gems/asciidoctor-epub3
30
+ :uri-gem: https://rubygems.org/gems/asciidoctor-epub3
31
31
  :uri-repo: {uri-project}
32
32
  :uri-issues: {uri-repo}/issues
33
- :uri-ci: {uri-repo}/actions?query=workflow%3ACI
34
- :uri-discuss: http://discuss.asciidoctor.org
33
+ :uri-ci: {uri-repo}/actions?query=branch%3Amaster
34
+ :uri-discuss: https://discuss.asciidoctor.org/
35
35
  :uri-rvm: https://rvm.io
36
- :uri-asciidoctor: http://asciidoctor.org
36
+ :uri-asciidoctor: https://asciidoctor.org/
37
37
  :uri-idpf: http://www.idpf.org/
38
38
  :uri-epub: http://www.idpf.org/epub/31/spec/epub-spec.html
39
- :uri-epubcheck: https://github.com/idpf/epubcheck
40
- :uri-kindlegen: http://www.amazon.com/gp/feature.html?docId=1000765211
39
+ :uri-epubcheck: https://github.com/w3c/epubcheck
40
+ :uri-kindlegen: https://www.amazon.com/gp/feature.html?docId=1000765211
41
41
  :uri-kf8: http://www.amazon.com/gp/feature.html?docId=1000729511
42
42
  :uri-send-to-kindle: https://www.amazon.com/gp/sendtokindle/
43
43
  :uri-metadata-elem: http://www.idpf.org/epub/30/spec/epub30-publications.html#sec-metadata-elem
44
- :uri-dc: http://dublincore.org/documents/2004/12/20/dces
44
+ :uri-dc: https://www.dublincore.org/specifications/dublin-core/dces/2004-12-20/
45
45
  :uri-github-guides: https://guides.github.com
46
46
  :uri-github-guides-fork: https://github.com/opendevise/github-guides-asciidoc
47
- :uri-asciidoctor-i18n: http://asciidoctor.org/docs/user-manual/#builtin-attributes-i18n
47
+ :uri-asciidoctor-i18n: https://asciidoctor.org/docs/user-manual/#builtin-attributes-i18n
48
48
  :uri-epubreadingsystem: http://www.idpf.org/epub/301/spec/epub-contentdocs.html#app-epubReadingSystem
49
- :uri-android-sdk: http://developer.android.com/sdk/index.html
49
+ :uri-android-sdk: https://developer.android.com/sdk/index.html
50
50
 
51
51
  ifdef::status[]
52
52
  image:https://img.shields.io/gem/v/asciidoctor-epub3.svg[Latest Release,link={uri-gem}]
53
- image:https://img.shields.io/badge/license-MIT-blue.svg[MIT License,link=#copyright]
54
- image:{uri-repo}/workflows/CI/badge.svg[GitHub Actions,link={uri-ci}]
53
+ image:{uri-repo}/workflows/CI/badge.svg?branch=master[GitHub Actions,link={uri-ci}]
55
54
  endif::[]
56
55
 
57
56
  {project-name} is a set of Asciidoctor extensions for converting AsciiDoc documents directly to the EPUB3 and KF8/MOBI e-book formats.
@@ -103,12 +102,13 @@ Of course, there's always room for improvement, so we'll continue to work with y
103
102
  * EPUB3 metadata, manifest and spine (assembled by Gepub)
104
103
  * Document metadata (title, authors, subject, keywords, etc.)
105
104
  * Internal cross reference links
106
- * Syntax highlighting with CodeRay or Pygments (must use inline styles)
105
+ * Syntax highlighting with Rouge, CodeRay or Pygments
107
106
  * Unicode callout numbers
108
107
  * Page breaks avoided in block content (so much as it's supported by the e-reader)
109
108
  * Orphan section titles avoided (so much as it's supported by the e-reader)
110
109
  * Table border settings honored
111
110
  * Support for SVG images in the content
111
+ * Stem blocks via AsciiMath
112
112
 
113
113
  === Project Status
114
114
 
@@ -122,7 +122,7 @@ We may explore the use of fixed layout documents in the future if the need arise
122
122
  ifdef::env-github[]
123
123
  === Planned Features and Work In Progress
124
124
 
125
- See <<WORKLOG#,WORKLOG.adoc>>.
125
+ See link:WORKLOG.adoc[].
126
126
  endif::[]
127
127
 
128
128
  == Converter Workflow
@@ -141,6 +141,7 @@ Like other converters, Asciidoctor EPUB3 handles this chunking task by automatic
141
141
 
142
142
  When `doctype` attribute is set to `book`, each top-level section will become a separate ebook "chapter" file.
143
143
  This includes preface, bibliography, appendix, etc.
144
+ This behavior can be configured via `epub-chapter-level` document attribute.
144
145
 
145
146
  Otherwise, whole document is converted to a single ebook chapter.
146
147
 
@@ -160,7 +161,6 @@ Here's an example showing the structure of a book:
160
161
  Author Name
161
162
  :doctype: book
162
163
  :imagesdir: images
163
- \ifndef::ebook-format[:leveloffset: 1]
164
164
  //...and so on
165
165
 
166
166
  == Chapter One
@@ -198,26 +198,28 @@ You can install the published gem using the following command:
198
198
  This optional environment variable tells the gem installer to link against the C libraries on the system, if available, instead of compiling the libraries from scratch.
199
199
  This speeds up the installation of Nokogiri considerably.
200
200
 
201
- If you want to syntax highlight source listings, you'll also want to install CodeRay or Pygments.
201
+ If you want to syntax highlight source listings, you'll also want to install Rouge, CodeRay or Pygments.
202
202
  Choose one (or more) of the following:
203
203
 
204
+ .Rouge
205
+ $ gem install rouge
206
+
204
207
  .CodeRay
205
208
  $ gem install coderay
206
209
 
207
210
  .Pygments
208
211
  $ gem install pygments.rb
209
212
 
210
- You then activate syntax highlighting for a given document by adding the `source-highlighter` attribute to the document header (CodeRay shown):
213
+ You then activate syntax highlighting for a given document by adding the `source-highlighter` attribute to the document header (Rouge shown):
211
214
 
212
215
  [source,asciidoc]
213
216
  ----
214
- :source-highlighter: coderay
217
+ :source-highlighter: rouge
215
218
  ----
216
219
 
217
- NOTE: At the moment, Pygments is automatically used if it's available.
218
- If a style is not specified, the black and white theme (i.e., bw) is used.
219
- This default is used so that the syntax highlighting is legibile regardless of which reading mode the reader selects (white, black, sepia, etc).
220
- To override this default, you must pass a valid Pygments style name to the `pygments-style` attribute when invoking the `asciidoctor-epub3` script (e.g., `-a pygments-style=pastie`).
220
+ NOTE: If a style is not specified, the black and white theme (i.e., bw) is used.
221
+ This default is used so that the syntax highlighting is legible regardless of which reading mode the reader selects (white, black, sepia, etc).
222
+ To override this default, you must set `<highlighter>-style` document header attribute to a valid highlighter style name (e.g., `:rouge-style: pastie`).
221
223
 
222
224
  Assuming all the required gems install properly, verify you can run the `asciidoctor-epub3` script:
223
225
 
@@ -298,6 +300,17 @@ The recommended practice is to identify the referenced resource by means of a st
298
300
  |An optional override of the properties attribute for this document's item in the manifest.
299
301
  _Only applies to a chapter document._
300
302
 
303
+ |epub-chapter-level
304
+ |Specify the section level at which to split the EPUB into separate "chapter" files.
305
+ This attribute only affects documents with `:doctype: book`.
306
+ The default is to split into chapters at level-1 sections.
307
+ This attribute only affects the internal composition of the EPUB, not the way chapters and sections are displayed to users.
308
+ Some readers may be slow if the chapter files are too large, so for large documents with few level-1 headings, one might want to use a chapter level of 2 or 3.
309
+
310
+ |series-name, series-volume, series-id
311
+ |Populates the series statements (`belongs-to-collection`) in the package metadata.
312
+ Volume is a number, ID probably a UUID that is constant for all volumes in the series.
313
+
301
314
  |epub3-frontmatterdir
302
315
  |The path to a directory that contains frontmatter files. The file names must match `front-matter*.html` and will be included in alphabetic order. The files are expected to be valid EPUB HTML files. _If only one front matter page is
303
316
  required, the default 'front-matter.html' file can be used instead._
@@ -309,6 +322,12 @@ _Only applies to a chapter document._
309
322
  |Used to control the inclusion of special content in the generated HTML.
310
323
  If set to a value other than book, the byline information (author and avatar) is included below the chapter header and a typographic end mark is added at the end of the last paragraph.
311
324
  Suggested values include: book (default), article.
325
+
326
+ |toc
327
+ |Adds table of contents at the beginning of the book. Depth is controlled by `:toclevels:` attribute.
328
+
329
+ |outlinelevels
330
+ |Sets the depth of table of contents metadata. If not set, defaults to `:toclevels:`
312
331
  |===
313
332
 
314
333
  When using the EPUB3 converter, the `ebook-format` attribute resolves to the name of the e-book format being generated (epub3 or kf8) and the corresponding attribute `ebook-format-<name>` is defined, where `<name>` is `epub3` or `kf8`.
@@ -590,7 +609,7 @@ The theme's fonts are located in the [path]_data/fonts_ directory.
590
609
  The M+ Outline fonts are used for titles, headings, literal (monospace) text, and annotation numbers.
591
610
  The body text uses Noto Serif.
592
611
  Admonition icons and the end-of-chapter mark are from the Font Awesome icon font.
593
- Refer to the <<NOTICE#,NOTICE>> file for further information about the fonts.
612
+ Refer to the link:NOTICE.adoc[] file for further information about the fonts.
594
613
 
595
614
  // TODO document command to generate the M+ 1p latin fonts
596
615
 
@@ -885,8 +904,8 @@ endif::[]
885
904
  Copyright (C) 2014-2019 OpenDevise Inc. and the Asciidoctor Project.
886
905
  Free use of this software is granted under the terms of the MIT License.
887
906
 
888
- For the full text of the license, see the <<LICENSE#,LICENSE>> file.
889
- Refer to the <<NOTICE#,NOTICE>> file for information about third-party Open Source software in use.
907
+ For the full text of the license, see the link:LICENSE[] file.
908
+ Refer to the link:NOTICE.adoc[] file for information about third-party Open Source software in use.
890
909
 
891
910
  ////
892
911
  == Additional Points of Note
@@ -24,18 +24,23 @@ An extension for Asciidoctor that converts AsciiDoc documents to EPUB3 and KF8/M
24
24
  rescue
25
25
  Dir['**/*']
26
26
  end
27
- s.files = files.grep %r/^(?:(?:data\/(?:fonts|images|styles)|lib)\/.+|Gemfile|Rakefile|(?:CHANGELOG|LICENSE|NOTICE|README)\.adoc|\.yardopts|#{s.name}\.gemspec)$/
27
+ s.files = files.grep %r/^(?:(?:data\/(?:fonts|images|styles)|lib)\/.+|Gemfile|Rakefile|LICENSE|(?:CHANGELOG|NOTICE|README)\.adoc|\.yardopts|#{s.name}\.gemspec)$/
28
28
  s.executables = %w(asciidoctor-epub3 adb-push-ebook)
29
29
  s.test_files = s.files.grep(/^(?:test|spec|feature)\/.*$/)
30
30
 
31
31
  s.require_paths = ['lib']
32
32
 
33
33
  s.add_development_dependency 'asciidoctor-diagram', '>= 1.5.0', '< 3.0.0'
34
+ s.add_development_dependency 'asciimath', '~> 2.0'
35
+ s.add_development_dependency 'coderay', '~> 1.1.0'
36
+ s.add_development_dependency 'pygments.rb', '~> 1.2.0'
34
37
  s.add_development_dependency 'rake', '~> 13.0.0'
38
+ s.add_development_dependency 'rouge', '~> 3.0'
35
39
  s.add_development_dependency 'rspec', '~> 3.9.0'
36
- s.add_development_dependency 'rubocop', '~> 0.80.0'
40
+ s.add_development_dependency 'rubocop', '~> 0.81.0'
37
41
  s.add_development_dependency 'rubocop-rspec', '~> 1.38.0'
38
42
 
39
43
  s.add_runtime_dependency 'asciidoctor', '>= 1.5.6', '< 3.0.0'
40
44
  s.add_runtime_dependency 'gepub', '~> 1.0.0'
45
+ s.add_runtime_dependency 'mime-types', '~> 3.0'
41
46
  end
@@ -1,14 +1,11 @@
1
1
  .palette-grayscale {
2
- color: #191918; /* black :: literal, blockquote text */
3
- color: #333332; /* off-black :: body text, heading default, chapter header background */
4
- color: #4F4F4C; /* deep gray :: h4 */
5
- /* what about 40403E or 4C4C4B? for h4 */
6
- color: #666665; /* dark gray :: h5, visited link, list bullets, abstract, caption, open quote */
7
- color: #80807F; /* medium gray :: table borders */
8
- color: #B3B3B1; /* gray :: chapter title, footer subtitle, sidebar border */
9
- color: #DCDCDE; /* lighter gray :: footer lines, byline text, pre border, masthead bottom line */
10
- /* what about DEDEDC instead of DCDCDE? */
11
- color: #F2F2F2; /* off white :: pre background, sidebar background */
2
+ color: #000000; /* black :: body text, heading default */
3
+ color: #101010; /* off-black :: code, literal, blockquote text */
4
+ color: #202020; /* deep gray :: h4 */
5
+ color: #333332; /* dark gray :: h5, visited link, list bullets, abstract, caption, open quote */
6
+ color: #707070; /* medium gray :: table borders */
7
+ color: #C8C8C8; /* gray :: footer subtitle, sidebar border */
8
+ color: #E0E0E0; /* off white :: pre background, sidebar background */
12
9
  color: #FFFFFF; /* white :: chapter subtitle */
13
10
  }
14
11
 
@@ -28,8 +28,7 @@ body.gitden-reader {
28
28
  }*/
29
29
 
30
30
  /* Use tighter margins and smaller font (18px) on phones (Nexus 4 and smaller) */
31
- @media only screen and (max-device-width: 768px) and (max-device-height: 1280px),
32
- only screen and (max-device-width: 1280px) and (max-device-height: 768px) {
31
+ @media only screen and (max-device-width: 768px) and (max-device-height: 1280px), only screen and (max-device-width: 1280px) and (max-device-height: 768px) {
33
32
  body.gitden-reader,
34
33
  body.namo-epub-library {
35
34
  font-size: 112.5%;
@@ -38,7 +37,6 @@ only screen and (max-device-width: 1280px) and (max-device-height: 768px) {
38
37
  /*body.gitden-reader {
39
38
  margin: 0 5pt !important;
40
39
  }*/
41
-
42
40
  /*body.namo-epub-library > section.chapter {
43
41
  margin: 0 5pt;
44
42
  }*/
@@ -69,7 +67,6 @@ body code, body kbd, body pre, pre :not(code) {
69
67
  /*body {
70
68
  margin: 0 !important;
71
69
  }*/
72
-
73
70
  /* text-rendering is the only way to enable kerning in Kindle (and Calibre, though it seems to kern automatically) */
74
71
  /* personally, I think Kindle overdoes kerning, but we're running with it for now */
75
72
  /* text-rendering: optimizeLegibility kills certain Kindle eInk devices */
@@ -79,24 +76,6 @@ body code, body kbd, body pre, pre :not(code) {
79
76
  text-rendering: optimizeLegibility;
80
77
  }*/
81
78
 
82
- /* hack line height of subtitle using floats on Kindle */
83
- h1.chapter-title .subtitle {
84
- margin-top: -0.2em;
85
- margin-bottom: 0.3em; /* compensate for reduced line height */
86
- }
87
-
88
- /* NOTE using b instead of span since Firefox ePubReader applies immutable styles to span */
89
- h1.chapter-title .subtitle > b {
90
- float: left;
91
- display: inline-block;
92
- margin-bottom: -0.3em; /* reduce the line height */
93
- padding-right: 0.2em; /* spacing between words */
94
- }
95
-
96
- h1.chapter-title .subtitle > b:last-child {
97
- padding-right: 0;
98
- }
99
-
100
79
  h1.chapter-title .subtitle::after {
101
80
  display: table;
102
81
  content: ' ';
@@ -104,40 +83,6 @@ body code, body kbd, body pre, pre :not(code) {
104
83
  }
105
84
  }
106
85
 
107
- /* Use darker font colors on Kindle Paperwhite */
108
- @media amzn-kf8 and (device-height: 1024px) and (device-width: 758px),
109
- amzn-kf8 and (device-height: 758px) and (device-width: 1024px) {
110
- body p,
111
- div.abstract > p,
112
- ul, ol, li, dl, dt, dd, footer,
113
- div.verse .attribution, table.table th, table.table td,
114
- figcaption, caption,
115
- h1, h2, h3, h4, h5 {
116
- color: #000000;
117
- }
118
-
119
- body a:link,
120
- div.abstract > p a:link {
121
- color: #000000;
122
- -webkit-text-fill-color: #000000;
123
- }
124
-
125
- body a:visited {
126
- color: #333332;
127
- -webkit-text-fill-color: #333332;
128
- }
129
-
130
- .chapter-header {
131
- color: #191918;
132
- border-bottom-color: #191918;
133
- }
134
-
135
- h1.chapter-title .subtitle,
136
- .chapter-header p.byline {
137
- color: #000000;
138
- }
139
- }
140
-
141
86
  .chapter-header p.byline {
142
87
  height: auto; /* Aldiko requires this value to be 0; reset it for all others */
143
88
  }
@@ -17,7 +17,6 @@ html {
17
17
  /* set the em base (and relative em anchor) by setting the font-size on html */
18
18
  /* TODO set font-size > 100% except for Kindle */
19
19
  font-size: 100%;
20
- -webkit-text-size-adjust: 100%;
21
20
  }
22
21
 
23
22
  /* don't set margin on body as that's how many readers frame reading area */
@@ -81,8 +80,8 @@ b, strong {
81
80
 
82
81
  b.button {
83
82
  font-weight: normal;
84
- text-shadow: 1px 0 0 #666665;
85
- color: #191918;
83
+ text-shadow: 1px 0 0 #333332;
84
+ color: #101010;
86
85
  white-space: nowrap;
87
86
  }
88
87
 
@@ -143,7 +142,7 @@ img {
143
142
 
144
143
  mark {
145
144
  background-color: #FFC14F;
146
- color: #191918;
145
+ color: #101010;
147
146
  }
148
147
 
149
148
  small {
@@ -198,14 +197,36 @@ td, th {
198
197
  padding: 0;
199
198
  }
200
199
 
200
+ /* We need to apply text-align to <p> too in order to override global text-align:justify */
201
+ th.halign-left, td.halign-left, th.halign-left > p, td.halign-left > p {
202
+ text-align: left
203
+ }
204
+
205
+ th.halign-right, td.halign-right, th.halign-right > p, td.halign-right > p {
206
+ text-align: right
207
+ }
208
+
209
+ th.halign-center, td.halign-center, th.halign-center > p, td.halign-center > p {
210
+ text-align: center
211
+ }
212
+
213
+ th.valign-top, td.valign-top, th.valign-top > p, td.valign-top > p {
214
+ vertical-align: top
215
+ }
216
+
217
+ th.valign-bottom, td.valign-bottom, th.valign-bottom > p, td.valign-bottom > p {
218
+ vertical-align: bottom
219
+ }
220
+
221
+ th.valign-middle, td.valign-middle, th.valign-middle > p, td.valign-middle > p {
222
+ vertical-align: middle
223
+ }
224
+
201
225
  body a:link {
202
- color: #333332;
203
- /* hack for font color in iBooks and Gitden (though Gitden would accept color !important too) */
204
- -webkit-text-fill-color: #333332;
205
226
  /* Kindle requires the !important on text-decoration */
206
227
  /* In night mode, the only indicator of a link is the underline, so we need it or a background image */
207
228
  text-decoration: none !important;
208
- border-bottom: 1px dashed #666665;
229
+ border-bottom: 1px dashed #333332;
209
230
  /* allow URLs to break anywhere if they don't fit on a line; but how do we know it's a URL? */
210
231
  /*
211
232
  word-break: break-all;
@@ -215,18 +236,12 @@ body a:link {
215
236
  body:first-of-type a:link {
216
237
  border-bottom: none;
217
238
  background-repeat: no-repeat;
218
- background-image: -webkit-linear-gradient(left, rgba(255,255,255,0) 0%, #666665 5%, #666665 95%, rgba(255,255,255,0) 100%);
219
- background-image: linear-gradient(to right, rgba(255,255,255,0) 0%, #666665 5%, #666665 95%, rgba(255,255,255,0) 100%);
239
+ background-image: -webkit-linear-gradient(left, rgba(255, 255, 255, 0) 0%, #666665 5%, #666665 95%, rgba(255, 255, 255, 0) 100%);
240
+ background-image: linear-gradient(to right, rgba(255, 255, 255, 0) 0%, #666665 5%, #666665 95%, rgba(255, 255, 255, 0) 100%);
220
241
  background-size: 100% 1px;
221
242
  background-position: 0 1.2em;
222
243
  }
223
244
 
224
- body a:visited {
225
- color: #666665;
226
- /* hack for font color in iBooks */
227
- -webkit-text-fill-color: #666665;
228
- }
229
-
230
245
  code.literal {
231
246
  /* don't let it affect line spacing */
232
247
  /* disable since M+ 1mn won't interrupt line height */
@@ -270,7 +285,6 @@ body p,
270
285
  ul, ol, li, dl, dt, dd, footer,
271
286
  div.verse .attribution, table.table th, table.table td,
272
287
  figcaption, caption {
273
- color: #333332;
274
288
  /* NOTE iBooks will forcefully override font-family of text inside div, p and span elements when font other than Original is selected */
275
289
  /* NOTE iBooks honors Original font for prose text if declared in display-options.xml */
276
290
  font-family: "Noto Serif", serif;
@@ -281,7 +295,7 @@ body p, li, dt, dd, footer {
281
295
  }
282
296
 
283
297
  code, kbd, pre {
284
- color: #191918;
298
+ color: #101010;
285
299
  font-family: "M+ 1mn", monospace;
286
300
  -webkit-hyphens: none; /* disable hyphenation where supported (e.g., iBooks) */
287
301
  }
@@ -357,6 +371,11 @@ dl dd {
357
371
  margin-top: 0.25em;
358
372
  }
359
373
 
374
+ td.hdlist1 {
375
+ font-weight: bold;
376
+ padding-right: 0.625em;
377
+ }
378
+
360
379
  div.callout-list {
361
380
  margin-top: 0.5em;
362
381
  }
@@ -457,7 +476,7 @@ ul > li::before {
457
476
 
458
477
  ul > li::before {
459
478
  content: "\25AA"; /* small black square */
460
- color: #666665;
479
+ color: #333332;
461
480
  }
462
481
 
463
482
  ul ul > li::before {
@@ -467,7 +486,7 @@ ul ul > li::before {
467
486
 
468
487
  ul ul ul > li::before {
469
488
  content: "\2022"; /* small black circle */
470
- color: #666665;
489
+ color: #333332;
471
490
  }
472
491
 
473
492
  ul ul ul ul > li::before {
@@ -529,7 +548,6 @@ ul.references > li > span.principal {
529
548
 
530
549
  /* sized based on the major third modular scale (4:5, 16px, 24px) */
531
550
  h1, h2 {
532
- color: #333332;
533
551
  font-size: 1.5em;
534
552
  word-spacing: -0.075em;
535
553
  margin-top: 1em; /* 1.5rem */
@@ -537,14 +555,13 @@ h1, h2 {
537
555
  }
538
556
 
539
557
  h3 {
540
- color: #333332;
541
558
  font-size: 1.25em;
542
559
  margin-top: 0.84em; /* 1.05rem */
543
560
  margin-bottom: -0.5em; /* -0.625rem, 0.375rem to content */
544
561
  }
545
562
 
546
563
  h4 {
547
- color: #4F4F4C;
564
+ color: #202020;
548
565
  font-weight: 200;
549
566
 
550
567
  font-size: 1.1em;
@@ -559,7 +576,7 @@ h4 {
559
576
  }
560
577
 
561
578
  h5 {
562
- color: #666665;
579
+ color: #333332;
563
580
  /*
564
581
  font-size: 1em;
565
582
  text-transform: uppercase;
@@ -589,7 +606,7 @@ h5 code {
589
606
  /*padding: 0.75em 1.5em 0.25em 1.5em;*/
590
607
  padding: 0.25em 0;
591
608
  margin-bottom: 2.5em;
592
- border-bottom: 1px solid #666665;
609
+ border-bottom: 1px solid #333332;
593
610
  /* TODO maybe what we need to get articles to start in left column
594
611
  -webkit-column-break-before: left;
595
612
  page-break-before: left;
@@ -602,7 +619,7 @@ h1.chapter-title {
602
619
  margin-top: 3.5em; /* 4.2rem - would like to use 9vh */
603
620
  margin-bottom: 0;
604
621
  padding-bottom: 0.8333em; /* 1.2rem */
605
- color: #666665;
622
+ color: #333332;
606
623
  text-transform: uppercase; /* not supported in Adobe Digital Editions */
607
624
  word-spacing: -0.075em;
608
625
  letter-spacing: -0.01em;
@@ -610,7 +627,6 @@ h1.chapter-title {
610
627
 
611
628
  h1.chapter-title .subtitle {
612
629
  font-weight: 400;
613
- color: #333332;
614
630
  display: block;
615
631
  font-size: 1.5em;
616
632
  margin: 0 0 0 0.75em; /* would like to use 2vw */
@@ -627,7 +643,6 @@ h1.chapter-title b {
627
643
  }
628
644
 
629
645
  .chapter-header p.byline {
630
- color: #333332;
631
646
  /* float left and height 0 takes this line out of the flow */
632
647
  float: left;
633
648
  height: 0;
@@ -658,17 +673,11 @@ div.abstract {
658
673
  }
659
674
 
660
675
  div.abstract > p {
661
- color: #666665;
676
+ color: #333332;
662
677
  font-size: 1.05em; /* or 1.1em? */
663
678
  line-height: 1.75;
664
679
  }
665
680
 
666
- div.abstract > p a:link {
667
- color: #666665;
668
- /* hack for font color in iBooks */
669
- -webkit-text-fill-color: #666665;
670
- }
671
-
672
681
  div.abstract > p:first-child::first-line {
673
682
  font-weight: bold;
674
683
  -webkit-font-feature-settings: "kern" off;
@@ -743,7 +752,7 @@ figcaption,
743
752
  caption {
744
753
  font-size: 0.9em;
745
754
  font-style: italic;
746
- color: #666665;
755
+ color: #333332;
747
756
  letter-spacing: -0.01em;
748
757
  line-height: 1.4;
749
758
  text-align: left;
@@ -775,10 +784,10 @@ figure.listing > figcaption + pre {
775
784
  }
776
785
 
777
786
  aside.sidebar {
778
- border: 1px solid #B3B3B1;
787
+ border: 1px solid #C8C8C8;
779
788
  padding: 0 1.5em;
780
789
  font-size: 0.9em;
781
- background-color: #F2F2F2;
790
+ background-color: #E0E0E0;
782
791
  text-align: right; /* aligns heading to right */
783
792
  /*
784
793
  -webkit-box-shadow: 0px 1px 1px rgba(102, 102, 101, 0.15);
@@ -806,7 +815,7 @@ aside.sidebar > h2 {
806
815
  letter-spacing: 0;
807
816
  display: inline-block;
808
817
  white-space: nowrap; /* for some reason it's wrapping prematurely */
809
- border: 1px solid #B3B3B1;
818
+ border: 1px solid #C8C8C8;
810
819
  padding: 1.5em .75em .5em .75em;
811
820
  margin: -1em 0.5em -0.25em 0.5em;
812
821
  background-color: #FFFFFF;
@@ -843,7 +852,7 @@ div[class~="blockquote"] {
843
852
  }
844
853
 
845
854
  blockquote > p {
846
- color: #191918;
855
+ color: #101010;
847
856
  font-style: italic;
848
857
 
849
858
  /*
@@ -860,7 +869,7 @@ blockquote > p {
860
869
 
861
870
  blockquote > p:first-of-type::before {
862
871
  display: inline-block;
863
- color: #666665;
872
+ color: #333332;
864
873
  text-shadow: 0 1px 2px rgba(102, 102, 101, 0.3);
865
874
 
866
875
  /* using serif quote from entypo */
@@ -893,7 +902,7 @@ blockquote footer {
893
902
  blockquote footer .context {
894
903
  font-size: 0.9em;
895
904
  letter-spacing: -0.05em;
896
- color: #666665;
905
+ color: #333332;
897
906
  }
898
907
 
899
908
  pre {
@@ -904,14 +913,10 @@ pre {
904
913
  overflow-wrap: break-word; /* break in middle of long word if no other break opportunities are available */
905
914
  font-size: 0.85em;
906
915
  line-height: 1.4; /* matches what Kindle uses and can't go less */
907
- background-color: #F2F2F2;
908
- padding: 0.5rem 0.75rem;
909
- /*
910
- border-top: 3px solid #DCDCDE;
911
- */
912
- /* QUESTION #B3B3B1? */
913
- border-top: 1px solid #DCDCDE;
914
- border-right: 1px solid #DCDCDE;
916
+ background-color: #E0E0E0;
917
+ padding: 0.6em 0.9em; /* this is supposed to be '0.5rem 0.75rem' but Sony Readers crash when see that (at least, PRS-350, PRS-505, PRS-T1) */
918
+ border-top: 1px solid #C8C8C8;
919
+ border-right: 1px solid #C8C8C8;
915
920
  }
916
921
 
917
922
  body:first-of-type pre {
@@ -1028,8 +1033,8 @@ aside.note::before {
1028
1033
  }
1029
1034
 
1030
1035
  aside[class~="note"] > div[class~="content"] {
1031
- background-image: -webkit-linear-gradient(left, rgba(255,255,255,0) 42.5%, #FFC14F 45%, #FFC14F 55%, rgba(255,255,255,0) 57.5%);
1032
- background-image: linear-gradient(to right, rgba(255,255,255,0) 42.5%, #FFC14F 45%, #FFC14F 55%, rgba(255,255,255,0) 57.5%);
1036
+ background-image: -webkit-linear-gradient(left, rgba(255, 255, 255, 0) 42.5%, #FFC14F 45%, #FFC14F 55%, rgba(255, 255, 255, 0) 57.5%);
1037
+ background-image: linear-gradient(to right, rgba(255, 255, 255, 0) 42.5%, #FFC14F 45%, #FFC14F 55%, rgba(255, 255, 255, 0) 57.5%);
1033
1038
  }
1034
1039
 
1035
1040
  aside.tip::before {
@@ -1038,8 +1043,8 @@ aside.tip::before {
1038
1043
  }
1039
1044
 
1040
1045
  aside[class~="tip"] > div[class~="content"] {
1041
- background-image: -webkit-linear-gradient(left, rgba(255,255,255,0) 42.5%, #40403E 45%, #40403E 55%, rgba(255,255,255,0) 57.5%);
1042
- background-image: linear-gradient(to right, rgba(255,255,255,0) 42.5%, #40403E 45%, #40403E 55%, rgba(255,255,255,0) 57.5%);
1046
+ background-image: -webkit-linear-gradient(left, rgba(255, 255, 255, 0) 42.5%, #40403E 45%, #40403E 55%, rgba(255, 255, 255, 0) 57.5%);
1047
+ background-image: linear-gradient(to right, rgba(255, 255, 255, 0) 42.5%, #40403E 45%, #40403E 55%, rgba(255, 255, 255, 0) 57.5%);
1043
1048
  }
1044
1049
 
1045
1050
  aside.caution::before {
@@ -1048,8 +1053,8 @@ aside.caution::before {
1048
1053
  }
1049
1054
 
1050
1055
  aside[class~="caution"] > div[class~="content"] {
1051
- background-image: -webkit-linear-gradient(left, rgba(255,255,255,0) 42.5%, #7F7F7D 45%, #7F7F7D 55%, rgba(255,255,255,0) 57.5%);
1052
- background-image: linear-gradient(to right, rgba(255,255,255,0) 42.5%, #7F7F7D 45%, #7F7F7D 55%, rgba(255,255,255,0) 57.5%);
1056
+ background-image: -webkit-linear-gradient(left, rgba(255, 255, 255, 0) 42.5%, #7F7F7D 45%, #7F7F7D 55%, rgba(255, 255, 255, 0) 57.5%);
1057
+ background-image: linear-gradient(to right, rgba(255, 255, 255, 0) 42.5%, #7F7F7D 45%, #7F7F7D 55%, rgba(255, 255, 255, 0) 57.5%);
1053
1058
  }
1054
1059
 
1055
1060
  aside.warning::before {
@@ -1058,8 +1063,8 @@ aside.warning::before {
1058
1063
  }
1059
1064
 
1060
1065
  aside[class~="warning"] > div[class~="content"] {
1061
- background-image: -webkit-linear-gradient(left, rgba(255,255,255,0) 42.5%, #C83737 45%, #C83737 55%, rgba(255,255,255,0) 57.5%);
1062
- background-image: linear-gradient(to right, rgba(255,255,255,0) 42.5%, #C83737 45%, #C83737 55%, rgba(255,255,255,0) 57.5%);
1066
+ background-image: -webkit-linear-gradient(left, rgba(255, 255, 255, 0) 42.5%, #C83737 45%, #C83737 55%, rgba(255, 255, 255, 0) 57.5%);
1067
+ background-image: linear-gradient(to right, rgba(255, 255, 255, 0) 42.5%, #C83737 45%, #C83737 55%, rgba(255, 255, 255, 0) 57.5%);
1063
1068
  }
1064
1069
 
1065
1070
  aside.important::before {
@@ -1068,8 +1073,8 @@ aside.important::before {
1068
1073
  }
1069
1074
 
1070
1075
  aside[class~="important"] > div[class~="content"] {
1071
- background-image: -webkit-linear-gradient(left, rgba(255,255,255,0) 42.5%, #F2642A 45%, #F2642A 55%, rgba(255,255,255,0) 57.5%);
1072
- background-image: linear-gradient(to right, rgba(255,255,255,0) 42.5%, #F2642A 45%, #F2642A 55%, rgba(255,255,255,0) 57.5%);
1076
+ background-image: -webkit-linear-gradient(left, rgba(255, 255, 255, 0) 42.5%, #F2642A 45%, #F2642A 55%, rgba(255, 255, 255, 0) 57.5%);
1077
+ background-image: linear-gradient(to right, rgba(255, 255, 255, 0) 42.5%, #F2642A 45%, #F2642A 55%, rgba(255, 255, 255, 0) 57.5%);
1073
1078
  }
1074
1079
 
1075
1080
  aside.admonition > h2 {
@@ -1104,8 +1109,6 @@ table.table th,
1104
1109
  table.table td {
1105
1110
  line-height: 1.4;
1106
1111
  padding: 0.5em 0.5em 1em 0.1em;
1107
- vertical-align: top;
1108
- text-align: left;
1109
1112
  -webkit-column-break-inside: avoid;
1110
1113
  page-break-inside: avoid;
1111
1114
  }
@@ -1115,7 +1118,7 @@ table.table th {
1115
1118
  }
1116
1119
 
1117
1120
  table.table thead th {
1118
- border-bottom: 1px solid #80807F;
1121
+ border-bottom: 1px solid #707070;
1119
1122
  }
1120
1123
 
1121
1124
  table.table td > p,
@@ -1123,47 +1126,43 @@ table.table div.embed > * {
1123
1126
  margin-top: 0;
1124
1127
  }
1125
1128
 
1126
- table.table td > p {
1127
- text-align: left;
1128
- }
1129
-
1130
1129
  /* REVIEW */
1131
1130
  table.table td > p + p,
1132
1131
  table.table div.embed > * + * {
1133
1132
  margin-top: 1em;
1134
1133
  }
1135
1134
 
1136
- table.table-framed {
1135
+ table.table-framed-all {
1137
1136
  border-width: 1px;
1138
1137
  border-style: solid;
1139
- border-color: #80807F;
1138
+ border-color: #707070;
1140
1139
  }
1141
1140
 
1142
1141
  table.table-framed-topbot {
1143
1142
  border-width: 1px 0;
1144
1143
  border-style: solid;
1145
- border-color: #80807F;
1144
+ border-color: #707070;
1146
1145
  }
1147
1146
 
1148
1147
  table.table-framed-sides {
1149
1148
  border-width: 0 1px;
1150
1149
  border-style: solid;
1151
- border-color: #80807F;
1150
+ border-color: #707070;
1152
1151
  }
1153
1152
 
1154
- table.table-grid th,
1155
- table.table-grid td {
1156
- border-width: 0 1px 1px 0;
1153
+ table.table-grid-all th,
1154
+ table.table-grid-all td {
1155
+ border-width: 1px 1px 1px 1px;
1157
1156
  border-style: solid;
1158
- border-color: #80807F;
1157
+ border-color: #707070;
1159
1158
  }
1160
1159
 
1161
- table.table-grid thead tr > *:last-child {
1160
+ table.table-grid-all thead tr > *:last-child {
1162
1161
  border-right-width: 0;
1163
1162
  }
1164
1163
 
1165
- table.table-grid tbody tr:last-child > th,
1166
- table.table-grid tbody tr:last-child > td {
1164
+ table.table-grid-all tbody tr:last-child > th,
1165
+ table.table-grid-all tbody tr:last-child > td {
1167
1166
  border-bottom-width: 0;
1168
1167
  }
1169
1168
 
@@ -1171,14 +1170,14 @@ table.table-grid-rows tbody th,
1171
1170
  table.table-grid-rows tbody td {
1172
1171
  border-width: 1px 0 0 0;
1173
1172
  border-style: solid;
1174
- border-color: #80807F;
1173
+ border-color: #707070;
1175
1174
  }
1176
1175
 
1177
1176
  table.table-grid-cols th,
1178
1177
  table.table-grid-cols td {
1179
1178
  border-width: 0 1px 0 0;
1180
1179
  border-style: solid;
1181
- border-color: #80807F;
1180
+ border-color: #707070;
1182
1181
  }
1183
1182
 
1184
1183
  table.table-grid-cols thead th:last-child {
@@ -1209,7 +1208,7 @@ hr.pagebreak + * {
1209
1208
 
1210
1209
  img.headshot {
1211
1210
  float: left;
1212
- border: 1px solid #80807F;
1211
+ border: 1px solid #707070;
1213
1212
  padding: 1px;
1214
1213
  margin: 0.35em 1em 0.15em 0;
1215
1214
  height: 5em !important;
@@ -1247,6 +1246,11 @@ nav#toc ol {
1247
1246
  list-style-type: none;
1248
1247
  }
1249
1248
 
1249
+ /* Calibre doesn't hide <nav hidden="hidden"> for some reason */
1250
+ nav[hidden~="hidden"] {
1251
+ display: none;
1252
+ }
1253
+
1250
1254
  .icon {
1251
1255
  display: none;
1252
1256
  }
@@ -1257,9 +1261,11 @@ nav#toc ol {
1257
1261
  table.table th, table.table td, div.verse .attribution {
1258
1262
  font-family: serif;
1259
1263
  }
1264
+
1260
1265
  h1, h2, h3, h4, h5, h6 {
1261
1266
  font-family: sans-serif;
1262
1267
  }
1268
+
1263
1269
  code, kbd, pre, i.conum {
1264
1270
  font-family: monospace;
1265
1271
  }