summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTom Milligan <tom.milligan@uipath.com>2023-11-13 17:09:38 +0100
committerGitHub <noreply@github.com>2023-11-13 17:09:38 +0100
commit52ca8fc8318dfab6c26d6f556e86ab102ab1f0f4 (patch)
tree1ec1b154e811dd34b3be2bc95e0421c233400e6d
parent31d5a27a6d69c5550816964cd05641303842081b (diff)
parente1ea411e9ac02271b4fbe3578ba9d781a09e94fc (diff)
Merge pull request #152 from tommilligan/print-pdf-render
fix: better rendering for pdf/print view
-rw-r--r--book/book.toml2
-rw-r--r--compile_assets/scss/admonition.scss6
-rw-r--r--integration/book.toml2
-rw-r--r--integration/expected/book.toml2
-rw-r--r--src/bin/assets/VERSION2
-rw-r--r--src/bin/assets/mdbook-admonish.css4
6 files changed, 14 insertions, 4 deletions
diff --git a/book/book.toml b/book/book.toml
index 50e292c..77673ec 100644
--- a/book/book.toml
+++ b/book/book.toml
@@ -9,7 +9,7 @@ title = "The mdbook-admonish book"
[preprocessor.admonish]
command = "mdbook-admonish"
-assets_version = "3.0.0" # do not edit: managed by `mdbook-admonish install`
+assets_version = "3.0.1" # do not edit: managed by `mdbook-admonish install`
[preprocessor.toc]
command = "mdbook-toc"
diff --git a/compile_assets/scss/admonition.scss b/compile_assets/scss/admonition.scss
index 75114d3..d9b88d2 100644
--- a/compile_assets/scss/admonition.scss
+++ b/compile_assets/scss/admonition.scss
@@ -165,6 +165,9 @@ a.admonition-anchor-link {
padding-inline: 4.4rem 1.2rem;
font-weight: 700;
background-color: color.adjust($clr-blue-a200, $alpha: -0.9);
+ // Always print title bar tint
+ print-color-adjust: exact;
+ -webkit-print-color-adjust: exact;
// Compatilility with rendering markdown inside the content
display: flex;
@@ -186,6 +189,9 @@ a.admonition-anchor-link {
width: 2rem;
height: 2rem;
background-color: $clr-blue-a200;
+ // Always print icon
+ print-color-adjust: exact;
+ -webkit-print-color-adjust: exact;
mask-image: url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"></svg>');
-webkit-mask-image: url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"></svg>');
mask-repeat: no-repeat;
diff --git a/integration/book.toml b/integration/book.toml
index a8ecd50..3e4ea48 100644
--- a/integration/book.toml
+++ b/integration/book.toml
@@ -9,7 +9,7 @@ title = "mdbook-admonish-integration"
[preprocessor.admonish]
command = "mdbook-admonish"
-assets_version = "3.0.0" # do not edit: managed by `mdbook-admonish install`
+assets_version = "3.0.1" # do not edit: managed by `mdbook-admonish install`
after = ["links"]
[preprocessor.admonish.renderer.test]
diff --git a/integration/expected/book.toml b/integration/expected/book.toml
index a8ecd50..3e4ea48 100644
--- a/integration/expected/book.toml
+++ b/integration/expected/book.toml
@@ -9,7 +9,7 @@ title = "mdbook-admonish-integration"
[preprocessor.admonish]
command = "mdbook-admonish"
-assets_version = "3.0.0" # do not edit: managed by `mdbook-admonish install`
+assets_version = "3.0.1" # do not edit: managed by `mdbook-admonish install`
after = ["links"]
[preprocessor.admonish.renderer.test]
diff --git a/src/bin/assets/VERSION b/src/bin/assets/VERSION
index 4a36342..cb2b00e 100644
--- a/src/bin/assets/VERSION
+++ b/src/bin/assets/VERSION
@@ -1 +1 @@
-3.0.0
+3.0.1
diff --git a/src/bin/assets/mdbook-admonish.css b/src/bin/assets/mdbook-admonish.css
index e0a3365..a0a566a 100644
--- a/src/bin/assets/mdbook-admonish.css
+++ b/src/bin/assets/mdbook-admonish.css
@@ -71,6 +71,8 @@ a.admonition-anchor-link::before {
padding-inline: 4.4rem 1.2rem;
font-weight: 700;
background-color: rgba(68, 138, 255, 0.1);
+ print-color-adjust: exact;
+ -webkit-print-color-adjust: exact;
display: flex;
}
:is(.admonition-title, summary.admonition-title) p {
@@ -86,6 +88,8 @@ html :is(.admonition-title, summary.admonition-title):last-child {
width: 2rem;
height: 2rem;
background-color: #448aff;
+ print-color-adjust: exact;
+ -webkit-print-color-adjust: exact;
mask-image: url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"></svg>');
-webkit-mask-image: url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"></svg>');
mask-repeat: no-repeat;