Blazored / Home

The home repo for Blazored

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Proposal for Blazor PDF viewer

VenkateshSrini opened this issue · comments

The proposal is to have a free PDF rendering control. The control should be able to tell us the total number of pages and also the current page in which the user is in. To start with like BlazoredVideo, can a control be created using PDF.JS (https://github.com/mozilla/pdf.js/) and get an embedded PDF viewer in Blazor. As the user view changes from one page to another it should raise an event that will tell the current page number.

Hey @VenkateshSrini thanks for opening this issue.

Is there much of a requirement for this sort of functionality? Don't browser do this by default pretty much now a days?

I there is actually a big vacuum when handling the PDF. The browser will in most cases downloads the pdf or if set the content-type correctly then will open in a new window. We would not be able to track how much page has user read the entire PDF pages. We would also like to know how many pages are there in a PDF and also the current page that the user is reading.

Ok I see the use case. Is this something you are happy to maintain or is this just a suggestion?

@chrissainty,
I'm not sure how much time I would be able to spend or fixing bugs or issues. Since I work with enterprises, most of the enterprises have these kind of requirement. So I can suggest this and implement the same in project code and can contribute to request for enhancement or contribute by highlighting any bugs that I face in the use case where I use this

Ok no problem. I don't think this is something I can undertake at the moment either. But it's a good suggestion and I'll leave the issue for when time is available.

@chrissainty,
If you could provide some sample outline we will try to take it from there with the above said jS library
May be once implemented in the project I can try to re incorporate the same thing into the open source version. Will that work