Initial commit
This commit is contained in:
13
api/collections/lib/foreignMediaRender.yml
Normal file
13
api/collections/lib/foreignMediaRender.yml
Normal file
@@ -0,0 +1,13 @@
|
||||
raw: true
|
||||
eval: |
|
||||
//js
|
||||
(function() {
|
||||
let out = ""
|
||||
if ($foreignEntry?.file?.src && $foreignEntry?.file?.type?.startsWith("image/")) {
|
||||
out += "<img src='" + $projectBase + "medialib/" + $foreignEntry.id + "/" + $foreignEntry.file.src + "?filter=s' style='max-width: 100%;' /><br>"
|
||||
}
|
||||
out += $foreignEntry?.title || ""
|
||||
|
||||
return out
|
||||
})()
|
||||
//!js
|
||||
Reference in New Issue
Block a user