-
-
Notifications
You must be signed in to change notification settings - Fork 169
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Preview links of some files aren't working #6786
Comments
Can you reproduce it with a fresh starter kit? Or any actual description to reproduce it? Cause the steps you describe just work fine with the demo kit: https://getkirby.com/try |
Hi sorry for the missing info. I can't reproduce the issue with files uploaded via the panel. But the plugin author does have the issue with other files uploaded via the panel.
|
I can reproduce the issue as described here. The problem occurs when uploading a file to a page with a blueprint that has the preview permission set to false. What would be the correct solution here? Sometimes, you may want to disable the page preview while still allowing the file preview. I also noticed in the screenshot that the button classname "k-file-view-options" might be incorrect and should perhaps be "k-file-view-preview" instead. |
Can confirm @dominiklaube’s findings. |
@dominiklaube @nilsmielke thanks for figuring out how to reproduce the issue, very helpful. I can replicate it as well. |
It's caused by this commit: bc2e9fc My question to you, @samlinck @dominiklaube @nilsmielke, would be if the commit has the right intention and the file preview should also be gone if the parent page preview is disabled (and we just need to fix the UI to not show the button) or if you have use cases where this behavior is problematic and the file preview should be independent. |
@distantnative In my use case, the file preview is intended in a page, that is not previewable. The page only holds information, that is not displayed on a single page basis in the frontend, thus, the preview is futile. Still, the file needs to be downloadable from the panel. |
Description
The preview link for some files appears as a button instead of a standard link. As a result, clicking it does nothing. However, the file can be accessed by manually copying and pasting the URL.
Initially, I thought it was a Dreamform bug since the file was uploaded through Dreamform. However, after further testing, we found that some files not uploaded via Dreamform also have this issue. Referring issue
Expected behavior
The preview link opens the file url in a new tab.
Screenshots
The file I have problems with
The preview button html
To reproduce
Your setup
Kirby Version
4.4.1
Console output
Your system (please complete the following information)
Additional context
The text was updated successfully, but these errors were encountered: