New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improve PDF export #1350
Comments
The Malte PDF should have the Malte Logo in the bottom right hand of the PDF, right? |
At the moment, we don't have the possibility to set individual logos other than the Integreat logo, but it's planned (see issue #1093). |
I don't remember whether it had a Malte Logo - I just found the Integreat Logo in the Malte PDF confusing...especially for people who only know Malte... |
Regarding the Malte Logo I opened PR #1364 which handles all logos in the CMS, so as soon as this is merged, there will the Malte logo in the PDF footer. |
@osmers the PR is now merged and released, so the Malte CMS is now styled in the Malte design which includes the logo in the footer of exported PDFs. |
BUT we seem to have an issue with the handling of malformed HTML. As you can see in the picture some items are missing because there are some unnecessary HTML entities in the content which are only visible in the source code. Verlängerung des Ankunftsnachweises
Aufenthaltsgestattung ausstellen und verlängern (Asyl)
Beantragung der Arbeitserlaubnis
Aufenthaltserlaubnis und Ausnahmegenehmigungen für Reisen
@svenseeberg @osmers As these are pure content issues: Should we handle them somehow in the implementation or is this something our users are supposed to fix by editing the content? |
What do you mean by files linking to the old TUM-server? We also have this problem on Malte which never was on the servers of TUM afaik, so I don't think this has anything to do with it. What you probably mean are the old wordpress-styled image paths with
In my opinion, this should be fixed in the content (and proper |
Okay, I see. I found some Sources linking to the "vkcmar..." URL that weren't working, but right: If the @timoludwig Regarding the other issue. Unfortunately Markdown doesn't support raw HTML, but as you can see in the Screenshot we also have this issue with the div inside the list items that are causing troubles. The |
@ulliholtgrave you can insert html code into markdown with three backticks:
Since |
Okay, I see, but this Issue is from 2013 🙈 We might want to fill a new one :D |
Yes, or just update the existing issue with a very detailed explanation how to reproduce the problem and what the expected output would be, probably the original issue was not tackled because it's too vague. |
I created a new Issue for it in the upstream repository (see xhtml2pdf/xhtml2pdf#611) |
At least for the issue with the line breaks I see 3 possible solutions:
|
Is this still current? ToC looks fine, what changes are intended?
Is this still current? Latin characters in arabic text appear to have the font we also use in latin PDFs:
Unable to reproduce. Would be great to get an example of a page where this is happening.
|
No, I think the service team does not yet know what they want here 😉
I think it's the other way round: Arabic letters in e.g. German pages are not working, e.g.:
I took the screenshot from here: Could also be an infrastructure problem with some broken media links or similar, didn't have time yet to look into it.
Awesome, thanks a lot! 🚀 |
Is something keeping us from just using Either |
Yes, looks like it. Is there some location mapping that works for all of these files? Don't think I have access to the Apache config. Alternatively I can leave this issue for someone who has access. |
Something appears to be wrong with the icons themselves, at least in regards to Try manually downloading https://cms.malteapp.de/schwerin/wp-content/uploads/sites/124/2020/07/phone.png, then uploading it to the CMS Media Library and insert it into a page. Same issue occurs. Open the file in an image editor, reexport, add to Media Library again, insert into page, bug is gone. Unless we want to use |
Ohh, interesting, thanks for figuring that out. Ok, then sorry for bothering you, yes this should be fixed in the content.
In an ideal world, the PDF looks exactly like the content in the apps, which use Raleway for headings and open sans for the content (see Fonts for Alphabets). However, it's more important that text is actually readable, so if using a different font is the only option, I'd go with it.
— https://xhtml2pdf.readthedocs.io/en/latest/reference.html#arabic-hebrew-persian-etc-fonts-support |
Motivation
At the moment, the PDF export feels a bit rudimentary and buggy.
Proposed Solution
Add cover page with city & integreat logospolish table of contents - on hold until requirements are clarifiedFix images & icons in content- Rejected: content issueAlternatives
Additional Context
The text was updated successfully, but these errors were encountered: