From 0aabd425d69f6c7765c7ce4880466e1356b447d8 Mon Sep 17 00:00:00 2001 From: Alex Cabal Date: Mon, 17 Jan 2022 20:23:53 -0600 Subject: [PATCH] Update boilerplate CSS to new standards --- src/epub/css/core.css | 5 +++++ src/epub/css/se.css | 37 ++++++++++++------------------------- 2 files changed, 17 insertions(+), 25 deletions(-) diff --git a/src/epub/css/core.css b/src/epub/css/core.css index 9cddd7e..ebf5a23 100644 --- a/src/epub/css/core.css +++ b/src/epub/css/core.css @@ -131,4 +131,9 @@ section[epub|type~="endnotes"] > ol > li{ img[epub|type~="se:image.color-depth.black-on-transparent"]{ filter: invert(100%); } + + img[epub|type~="se:image.color-depth.black-on-transparent"][epub|type~="se:image.style.realistic"]{ + background: currentColor; + filter: none; + } } diff --git a/src/epub/css/se.css b/src/epub/css/se.css index 88a5cfa..1a6d732 100644 --- a/src/epub/css/se.css +++ b/src/epub/css/se.css @@ -6,6 +6,18 @@ abbr.era{ font-variant: all-small-caps; } +section[epub|type~="titlepage"] h1, +section[epub|type~="titlepage"] p, +section[epub|type~="colophon"] h2, +section[epub|type~="imprint"] h2{ + /* Required for Kobo not to add an extra page to the title */ + font-size: 0; + + /* Required for Kindle */ + position: absolute; + left: -999em; +} + section[epub|type~="titlepage"] img{ display: block; width: 100%; @@ -23,11 +35,6 @@ section[epub|type~="imprint"] header{ margin-top: 3em; } -section[epub|type~="colophon"] h2, -section[epub|type~="imprint"] h2{ - display: none; -} - img[epub|type~="z3998:publisher-logo"]{ max-width: 25%; } @@ -82,23 +89,3 @@ section[epub|type~="copyright-page"] blockquote p span{ section[epub|type~="copyright-page"] blockquote br{ display: none; } - -@supports(display: flex){ - section[epub|type~="imprint"]{ - align-content: center; - display: flex; - flex-direction: column; - justify-content: center; - min-height: calc(98vh - 3em); - padding-top: 3em; - } - - section[epub|type~="imprint"] header{ - margin-bottom: 2em; - margin-top: 0; - } - - img[epub|type~="z3998:publisher-logo"]{ - max-width: 25vw; - } -}