Skip to content
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

fix: fix page break issue when document has images #531

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

kassah-mahmoud
Copy link

Page break produces unpredictable behavior when the document has images
This is due to the fact that the images may be fully loaded and rendered or not while calculating the element's rects values, which leads to incorrect calculations. As a result, page breaks and hyperlinks are located in incorrect positions.
In this PR, the worker chain make sure that all images are fully loaded then execute the page break logic
This modification solved the issues in my project so I made this PR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant