opencloud icon indicating copy to clipboard operation
opencloud copied to clipboard

[FR] PDF Preview

Open AlexAndBear opened this issue 2 months ago • 5 comments

Initial Checklist

  • [x] I understand this is a feature request and questions should be posted in the Community Discussions
  • [x] I searched issues and couldn’t find anything (or linked relevant results below)

User Story

As a user, I want the Web UI to support rich previews of PDF files so that I can easily view documents and reports directly without downloading them.

User Value

  • Quickly preview PDF documents directly in the browser
  • Enhance overall usability for teams working with reports, invoices, and multi-page documents

Acceptance Criteria

  • Web UI shows an inline preview (thumbnail) of PDF files
  • Clicking a PDF opens a full-size, scrollable and zoomable preview viewer

original request

It would be great to have PDF previews, especially now that we have tiles view on every page. Seeing a quick preview without opening the file would make browsing much faster and more convenient.

AlexAndBear avatar Oct 10 '25 21:10 AlexAndBear

PDFs can also embed Javascript code, so basically https://github.com/opencloud-eu/opencloud/issues/1465#issuecomment-3265268120 does apply here as well.

cc @db-ot @tbsbdr

rhafer avatar Oct 14 '25 09:10 rhafer

needs backend support

db-ot avatar Oct 14 '25 11:10 db-ot

Needs security concept.

micbar avatar Oct 14 '25 11:10 micbar

We need to check how the libvips is built within our image. It can be built with different PDF readers, which can be configured to not load Javascript.

Example: If our libvips is built with pdfium, it needs to be verified that the version of pdfium is built with option pdf_enable_v8 = false # Set false to remove Javascript support..

If somebody points me to the build instructions for our libvips that we use, I am happy to check that.

Back in the days, distributions were making sure that dependencies were secure. That was great.

dragotin avatar Oct 14 '25 12:10 dragotin

Our images are alpine based currently. I don't know much about alpine package building, but I suppose this is spec file equivalent for libvips on alpine: https://gitlab.alpinelinux.org/alpine/aports/-/blob/master/community/vips/APKBUILD

IIUC it's using poppler for PDF support.

rhafer avatar Oct 14 '25 12:10 rhafer