forked from andyburke/autonomous.contact
feature: some more media embeds
This commit is contained in:
parent
d9bfca3131
commit
94af047527
4 changed files with 30 additions and 0 deletions
13
public/js/embeds/mov.js
Normal file
13
public/js/embeds/mov.js
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
function embed_mov(link_info) {
|
||||
if (typeof link_info.extension !== "string") {
|
||||
return;
|
||||
}
|
||||
|
||||
const is_mov = get_mime_types(link_info.extension).includes("video/quicktime");
|
||||
|
||||
if (!is_mov) {
|
||||
return;
|
||||
}
|
||||
|
||||
return `<div class="embed-container video letterbox"><video autostart="0" controls="true"><source src="${link_info.url}" type="video/quicktime"><a href="${link_info.url}">${link_info.url}</a></video></div>`;
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue