diff options
| author | Samantaz Fox <coding@samantaz.fr> | 2023-05-08 15:41:39 +0200 |
|---|---|---|
| committer | Samantaz Fox <coding@samantaz.fr> | 2023-05-08 15:41:39 +0200 |
| commit | febd14f70396fc8c0f5eea9c10d8ea5b040a04aa (patch) | |
| tree | e593d596aa5bf8001575f86b88120ccf0864934b /src | |
| parent | 92f6a4d5463b26131db4ef065f5c2256bb8bb0cb (diff) | |
| parent | 720789b6221518fd1614debfcee794a422df9466 (diff) | |
| download | invidious-febd14f70396fc8c0f5eea9c10d8ea5b040a04aa.tar.gz invidious-febd14f70396fc8c0f5eea9c10d8ea5b040a04aa.tar.bz2 invidious-febd14f70396fc8c0f5eea9c10d8ea5b040a04aa.zip | |
Community: Minor HTML/CSS fixes (#3783)
Diffstat (limited to 'src')
| -rw-r--r-- | src/invidious/comments.cr | 20 |
1 files changed, 7 insertions, 13 deletions
diff --git a/src/invidious/comments.cr b/src/invidious/comments.cr index ec4449f0..01556099 100644 --- a/src/invidious/comments.cr +++ b/src/invidious/comments.cr @@ -372,32 +372,25 @@ def template_youtube_comments(comments, locale, thin_mode, is_replies = false) </div> END_HTML when "video" - html << <<-END_HTML - <div class="pure-g"> - <div class="pure-u-1 pure-u-md-1-2"> - <div style="position:relative;width:100%;height:0;padding-bottom:56.25%;margin-bottom:5px"> - END_HTML - if attachment["error"]? html << <<-END_HTML + <div class="pure-g video-iframe-wrapper"> <p>#{attachment["error"]}</p> + </div> END_HTML else html << <<-END_HTML - <iframe id='ivplayer' style='position:absolute;width:100%;height:100%;left:0;top:0' src='/embed/#{attachment["videoId"]?}?autoplay=0' style='border:none;'></iframe> + <div class="pure-g video-iframe-wrapper"> + <iframe class="video-iframe" src='/embed/#{attachment["videoId"]?}?autoplay=0'></iframe> + </div> END_HTML end - - html << <<-END_HTML - </div> - </div> - </div> - END_HTML else nil # Ignore end end html << <<-END_HTML + <p> <span title="#{Time.unix(child["published"].as_i64).to_s(translate(locale, "%A %B %-d, %Y"))}">#{translate(locale, "`x` ago", recode_date(Time.unix(child["published"].as_i64), locale))} #{child["isEdited"] == true ? translate(locale, "(edited)") : ""}</span> | END_HTML @@ -416,6 +409,7 @@ def template_youtube_comments(comments, locale, thin_mode, is_replies = false) html << <<-END_HTML <i class="icon ion-ios-thumbs-up"></i> #{number_with_separator(child["likeCount"])} + </p> END_HTML if child["creatorHeart"]? |
