react-pdf icon indicating copy to clipboard operation
react-pdf copied to clipboard

Add back functionality for bookmark props

Open mgmolisani opened this issue 1 year ago • 5 comments

This restores functionality that seemed to have accidentally erased in a minor version update to converge the forked pdfkit vendor package. This resulted in all bookmarks being created in fit mode on the last page not respecting any of the props.

I additionally added some comments to roughly show where the custom logic of this file exists to give some signal that this should not be altered in future fork maintenance.

I tested this locally in a simple repro and observed both the raw output and the PDF in Adobe Reader were again properly linking to the page and respecting props.

There are no unit tests for the custom logic in this vendor package hence I did not add any new ones.

Resolves https://github.com/diegomura/react-pdf/issues/2700

mgmolisani avatar Apr 12 '24 15:04 mgmolisani

🦋 Changeset detected

Latest commit: e993f89d78d021b9e61b99aa7ca3d81c252c47a0

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 7 packages
Name Type
@react-pdf/pdfkit Patch
@react-pdf/layout Patch
@react-pdf/renderer Patch
@react-pdf/svgkit Patch
@react-pdf/examples 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

changeset-bot[bot] avatar Apr 12 '24 15:04 changeset-bot[bot]

Nice! this probably closes #2682 too 🙌

typesafeui avatar Apr 19 '24 08:04 typesafeui

pls merge

AgustinBilldin avatar Jun 20 '24 11:06 AgustinBilldin

Confirmed this fixes #2700 for me

EvHaus avatar Jun 23 '24 05:06 EvHaus

@diegomura @wojtekmaj can we merge this?

typesafeui avatar Sep 22 '24 07:09 typesafeui

Polite bump. I've been pinned to an old version of @react-pdf/pdfkit for months to avoid the bugs this resolves.

danomatic avatar Dec 04 '24 19:12 danomatic

Thanks for pushing this. I really need to start using the base pdfkit thought 😞 Do you think you can try finding a way to fix this on react-pdf side?

I think since this is a regression from the original behavior in this lib and is blocking consumers from updating, its probably best to get this merged and then consider making changes to the vendor source package. I think blocking new features might be appropriate to steer the ship in that direction but fixing the regression should be priority # 1.

mgmolisani avatar Dec 11 '24 03:12 mgmolisani