Skip to content

fix: open recommended files with the viewer library - #1205

Open
skjnldsv wants to merge 2 commits into
masterfrom
fix/viewer-library
Open

skjnldsv wants to merge 2 commits into
masterfrom
fix/viewer-library

Conversation

@skjnldsv

Copy link
Copy Markdown
Member

Recommendations opened files through OCA.Viewer, which is gone in Nextcloud 36. It now uses @nextcloud/viewer: canView() decides whether the viewer shows the file, and open() gets the recommended file alone. Opening it with its folder gave the viewer previous and next files that had nothing to do with the recommendation.

Fixes #1174
Fixes #325

Tried on master: a recommended picture opens in the viewer from the Files list. Not tried from the dashboard widget. The app has no JS tests to extend.

👾 This pull request was assisted by Claude Code, commits carry an Assisted-by trailer.

OCA.Viewer is gone in Nextcloud 36. Ask the viewer library whether it
shows the file, and open it alone rather than with its folder.

Assisted-by: ClaudeCode:claude-opus-5-5
Signed-off-by: John Molakvoæ <14975046+skjnldsv@users.noreply.github.com>
Assisted-by: ClaudeCode:claude-opus-5-5
Signed-off-by: John Molakvoæ <14975046+skjnldsv@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

3. to review bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Migrate off the OCA.Viewer global before Nextcloud 36 Disable previous and next image on recommendations

1 participant