react-pdf
react-pdf copied to clipboard
feat: add fallback font support
Allows to add multiple fallback fonts and will fall back to the next font and eventually last font in case the glyph is not available.
I added an example for testing:
Happy to adept the PR in case something is missing e.g. test. Just need to know what and where.
🦋 Changeset detected
Latest commit: 90a17dac32198ae6117185ab544964b78218e256
The changes in this PR will be included in the next version bump.
This PR includes changesets to release 6 packages
Name | Type |
---|---|
@react-pdf/examples | Minor |
@react-pdf/layout | Minor |
@react-pdf/font | Minor |
@react-pdf/renderer | Patch |
@react-pdf/e2e-node-cjs | Patch |
@react-pdf/e2e-node-esm | Patch |
Not sure what this means? Click here to learn what changesets are.
Click here if you're a maintainer who wants to add another changeset to this PR
Looking forward to getting this merged! 🚀
hey @diegomura, wanted to ping and ask if you have some time to review this PR it in the near future
This would be really useful to be merged !
@nikgraf Should we also update the types package to allow an array of strings for fontFamily
?
@hendrikmolder definitely, will do as soon as there is any sign that the author is interested to merge it
Hi @nikgraf ! Thanks for working on this and sorry for the silence. Not usually easy to find the time unfortunately. If you can submit the types update I promise I'll review this in a timely manner.
@diegomura types are updated, I force pushed my branch
Thanks!!
Thank you @diegomura! This is such a fantastic library. Great job!
Hey, realised we didn't bump the types package – https://github.com/diegomura/react-pdf/pull/2723