Skip to content

Adding checks for changed scale prop in src/Pdf.js to zoom dynamically#3

Merged
erikras merged 3 commits intoerikras:masterfrom
boristian:master
Jan 14, 2016
Merged

Adding checks for changed scale prop in src/Pdf.js to zoom dynamically#3
erikras merged 3 commits intoerikras:masterfrom
boristian:master

Conversation

@boristian
Copy link
Contributor

Hi,

for a project i'm working on I needed the ability to zoom pdfs. Since you only check for newProps.pagein https://github.com/erikras/react-pdfjs/blob/master/src/Pdf.js#l27 i've added checks for changed scale prop. It would be great if you could merge it.

Also thanks to the original author, @nnarhinen.

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why move this to constructor? It was fine where it was.

@boristian
Copy link
Contributor Author

On my machine, running node v5.3.0., this led to an Unexpected token error. After moving the statement to the constructor it was fine.

@boristian
Copy link
Contributor Author

Hi,
if the moved state declaration is the problem why the PR is not merged, i can move it back. But i cannot test it that way.

@erikras erikras merged commit 9d58162 into erikras:master Jan 14, 2016
@erikras
Copy link
Owner

erikras commented Jan 14, 2016

Published to v1.0.6. Thanks!

@boristian
Copy link
Contributor Author

Thank you for merging. 👍

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.

2 participants