Can there be either a menu item for copying the URL(s) of the selected asset(s) (see below), or if "Preview file" isn't able to handle a filetype, include a direct link to the file in the preview window (or both)? Something like, "Preview not available. You can try to open this file in a new tab."
Yes! It seems that Preview File replaced View Asset when asset previews got added. Definitely confusing for users coming from Craft 2.
@proimage For now, you can enable the Link option to quickly view an asset's source.
For now, you can enable the Link option
What is this "Link option" of which you speak?
Doh, forgot about that – so this is already implemented (or something close enough, anyway). Just click the gear icon below the volume list on the Assets page, and check the box next to “Link”, for whichever volumes you want to be able to access files in directly.
I ran into this today, as well. It's extremely unintuitive coming from Craft 2, especially since I need to add the link column to all of my asset folders, which is a little frustrating.
Add one more vote to having the ability to open a link to the asset if "preview" doesn't work for the file type.
Fair enough, I’ll reopen.
As mentioned above, I am aware that we can add the Link as a column, but there are already quite a few options in the cog drop down that relate to copying, eg previewing, download, I think it would make sense to add a Copy URL in that drop down as well.
It never occurred to me to add the Link column in the list view, but this feels a bit like a cheat considering how many other options are already in the gear dropdown. Also, I pretty much have to go through 30-40 asset volumes and remember to add that to the view. I'd assume that so long as "Assets in this volume have public URLs" is checked, there could be a way to get that from the gear in almost exactly the same way as "Copy reference tag" works.
Video of how to add a Link column for anyone who might be searching on how to do this.
In case the PR was missed: https://github.com/craftcms/cms/pull/4499
And by "the PR" you really mean "one that was closed with no explanation"? :(
The link column should be on by default
A good workaround for this (until we get a permanent fix) is enabling the _Link_ column (as suggested by multiple folks) by default using the Element Index Defaults plugin, with the following config:
// config/element-index-defaults.php
return [
'Asset' => [
'title',
'filename',
'size',
'dateModified',
'link',
]
];
I also support adding a dropdown option for "Copy URL" or something like that. It took me having to lookup this thread to realize I could add the "Link" column to an asset volume. Can't hurt to have the option in both places.
This has just been released as a Plugin. Though it would still be convenient to have this added to the core @brandonkelly 🤞
This has been added for Craft 3.5. Thanks @putyourlightson for the initial PR!
Most helpful comment
This has been added for Craft 3.5. Thanks @putyourlightson for the initial PR!