nextcloud / nextcloud/text

PDF in *.md not opening in viewer - only download

Open
#7,109 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug feature: attachments
Dominant language
JavaScript
Stars
659
Forks
133
Avg merge
1d 20h
Merged PRs (30d)
110

Description

Describe the bug
PDF inserted in markdown files are not opened with the Nexcloud PDF viewer. Only download.

To Reproduce
Steps to reproduce the behavior:

  1. Add a PDF file into a markdown file, either with the attach button or drag and drop.
  2. The PDF in the markdown file is seen with a thumbnail-image (screenshot)
  3. Click on PDF thumbnail
  4. PDF gets downloaded

Clicking a PDF in the Filebrowser of NC opens the built in viewer as expected.

Expected behavior
When clicking the PDF thumbnail the PDF would open in the NC PDF viewer in the browser.

Screenshots
Image

Server details:
Newest version of NC-AIO

  • Nextcloud version: 30.0.8 - 30.0.8.1
  • PHP version: 8.3.19
  • Database: pgsql PostgreSQL 16.8 on x86_64-pc-linux-musl, compiled by gcc (Alpine 14.2.0) 14.2.0, 64-bit

Client details:

  • Browser: Safari and Chrome (both with same behavior)

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the issue by adding a PDF to a markdown file with the attach button or drag and drop, then clicking its thumbnail in Safari or Chrome. Compare that behavior with opening the same PDF from the Nextcloud Filebrowser viewer; done means the markdown thumbnail opens the built-in PDF viewer instead of downloading the file.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.