Giter Club home page Giter Club logo

pdfjs-viewer's People

Contributors

dealfonso avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

pdfjs-viewer's Issues

Loading PDF as URL

Nice work!

I am wondering if it is possible to open PDF's using the name in a URL. For example:

example.com/pdfjs-viewer/index.php?pdffile=somedoc.pdf

Need something like your pdfjs-viewer to use on school network to open local PDF's and restrict downloading them.

Thanks for sharing.

Adding Find to the viewer

I figured out how to integrate your simple viewer into my website, but I am wondering how I would extend it to add a Find function. I believe the pdfjs has a built in find controller (I used it with the old 2.x pdfjs version with my simpleviewer implementation), but I am wondering how I would use that via your viewer as you did not add that to the js code.

Print feature

Thanks for creating this simple and easy to use library.

The original pdf.js library has print feature.

image

Is there any possibility to include this feature in this library?

pdf.js version update

Thanks for this package, can the version of pdf.js be updated ? current is 4.2.67

Pixel Ratio causes crashes on iPads

Just wanted to bring up a possible issue in that using the pixel ratio value that you have in the viewer to determine the rendering canvas size can cause so much memory to be needed for full screen display on high res screens (I believe on my iPad the ratio is 2), that it crashes my site with longish documents on iOS devices. Hard coding the pixel ratio to 1 and then using the rendering scale that you recently added for more sharpness stopped all the crashes. It never crashes on my Windows computer with Chrome even with a rendering scale of 4, but my iPadd has been crash city until I overrode the pixel ration variable.

I am still mystified by the lack of character crispness of pdfjs version 3.x (which I am using), it seems that version 1 of pdfjs was VERY sharp with text-based documents but with the 'newer' versions is a bit fuzzy unless I up the rendering scale. Some sort of nonsense anti aliasing or something? Sheesh. If version 1 would render the latest versions of PDFs I would just use that, but some newer pdfs get a parse error and show just blank pages.

Pdf files are not shown in Firefox

I'm using latest Firefox 126.01 (Ubuntu) and the pdfjs-viewer doesn't show pdf files at all.

I can reproduce it with all codepen examples.

For instance: https://codepen.io/dealfonso/pen/qBPPEEd is rendered as:

Firefox-PDFjs-viewer (example 2)

No errors are printed in the console, also there are no network errors. Happens also in the incognito mode with all adblockers etc being turned off. At the same time all is good in other browsers like Vivaldi.

Rendering problem

Carlos: really appreciated pdfs-viewer.js. I have incorporated it into a large project.
Had a problem rendering many PDFs that had multiple pages. I changed one line of code and now it renders successfully:

    _setPageContent($page, $content) {
        //$page.find(`.${this.settings.contentClass}`).empty().append($content);
        $page.find(`.${this.settings.contentClass}`).append($content);
    }

I think that there was a race condition where empty() was completing after append() finished, so the image briefly appeared and then was removed. Even when append() runs more than once, it doesn't seem to duplicate the content of the page?

Thanks again for good work. [email protected]
!Que le vaya bien!

How use pinch to zoom in/out pdf doc

Hello,

I test your pdfjs-viewer, It's great for me. But on mobile device, I can't not use pinch gusture for 2 fingers to zoom in or out the pdf document(now can use only topbar button to zoom).

Please guide to use this feature.

Thank you

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.