Missing icon and incorrect border for admonition in PDF output
See original GitHub issueContribution guidelines
- I’ve read the contribution guidelines and wholeheartedly agree
I’ve found a bug and checked that …
- … the problem doesn’t occur with the
mkdocs
orreadthedocs
themes - … the problem persists when all overrides are removed, i.e.
custom_dir
,extra_javascript
andextra_css
- … the documentation does not mention anything about my problem
- … there are no open or closed issues that are related to my problem
Description
When using mkdocs-pdf-export-plugin
, icons are no longer shown for admonitions in the PDF output since mkdocs-material
rev b345a0b65 and the border does not look correct.
Expected behaviour
It should look like this (this is with c79b786ea):
Actual behaviour
But it looks like this (this is with master):
Note the lack of icon, and how the blue border extends all around the admonition.
Steps to reproduce
Test input test/docs/index.md
(test/mkdocs.yml
as below under Configuration)
# Welcome to MkDocs
!!! note
This is a note
Incorrect behavior with master
python3 -m venv bad_env
source bad_env/bin/activate
pip install wheel
pip install mkdocs mkdocs-pdf-export-plugin git+ssh://git@github.com/squidfunk/mkdocs-material.git
mkdocs build -f test/mkdocs.yml && xdg-open test/site/index.pdf
Correct behavior with rev c79b786ea
python3 -m venv good_env
source good_env/bin/activate
pip install wheel
pip install mkdocs mkdocs-pdf-export-plugin git+ssh://git@github.com/squidfunk/mkdocs-material.git@c79b786ea
mkdocs build -f test/mkdocs.yml && xdg-open test/site/index.pdf
I git bisect
:ed and the first bad commit seems to be b345a0b65:
b345a0b65 Prototyped material icon SVG integration
Package versions
- Python:
3.8.10
- MkDocs:
1.3.0
(git rev7418e7961
) - Material:
4.6.3
Configuration
site_name: My Docs
theme:
name: material
plugins:
- pdf-export
markdown_extensions:
- admonition
System information
- Operating system: Ubuntu 20.04.4 LTS
- Browser: Firefox 98.0.2 and Okular 1.9.3 for PDF viewing
Issue Analytics
- State:
- Created a year ago
- Comments:5 (2 by maintainers)
Top Results From Across the Web
Admonition Styles (PDF) - Paligo
The admonitions for PDF publications are styled via the Layout tab. ... and after an admonition, positioning, border style, used icons, ...
Read more >Adobe icon missing when embedding a .pdf file in Word 2013
In the file path specified, I tried copying an existing icon and renaming it to (OLE2.DLL) to see if it picked it up,...
Read more >CSS Tip: Creating Styled Boxes for Notes, Warnings ...
The styles with the border look great in web output. However, I too had problems in print output. The right border is not...
Read more >PDF Styling - Paligo - Zendesk
To control the look and feel of your PDF outputs, we recommend that ... an admonition, positioning, border style, used icons, font style, ......
Read more >Convertng Markdown admonition syntax to HTML, using Lua ...
@Gustavo Reis pandoc read wrong indentation before filter processing the ... then title_html = '<p class="admonition-title no-title"/>' else ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Turns out there was an open issue for mask-image support in weasyprint already: https://github.com/Kozea/WeasyPrint/issues/1458
Thanks. I think this info will be of use. Possibly the place to fix is in weasyprint which the plugin is using.