From 16e4c95a092229b8797444c0a0dc02fe40a990cd Mon Sep 17 00:00:00 2001 From: Tdxdxoz Date: Tue, 14 Dec 2021 20:52:41 +0800 Subject: [PATCH] support video --- static/index.html | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/static/index.html b/static/index.html index 8e94cc2..bf9eca7 100644 --- a/static/index.html +++ b/static/index.html @@ -140,12 +140,12 @@ .comment-list-wrapper { background: #3333; padding-left: 7%; - font-size: 80%; + font-size: 90%; } - .status-media-image { + .status-media { max-height: 500px; - max-width: 90%; + max-width: 100%; margin: 10px auto; } @@ -258,10 +258,14 @@ status.content.replace(/^

\[([^\]]*)\]:
/, '

') : status.content} ${status.media_attachments.map((media) => { - if (media.type === 'image') { - return ``; + switch (media.type) { + case 'image': + return ``; + case 'video': + return ``; + default: + return ''; } - return ''; }).join('\n')}