Selectively add left and right padding only for letterboxed thumbnails.

This commit is contained in:
John Mertz 2023-03-22 18:15:58 -04:00
parent e3dc3578a4
commit f59076af0f
Signed by: jpm
GPG Key ID: E9C5EA2D867501AB
2 changed files with 5 additions and 2 deletions

View File

@ -146,10 +146,13 @@ div.thumb, div.details {
z-index: 20; z-index: 20;
} }
div.thumb { div.thumb {
padding: 0px 10px 0px 10px; padding: 0px;
position: relative; position: relative;
overflow-y: hidden; overflow-y: hidden;
} }
div.letterbox {
padding: 0px 10px;
}
div.thumb img { div.thumb img {
display: block; display: block;
padding-right: 0px; padding-right: 0px;

View File

@ -233,7 +233,7 @@ function print_video($video,$settings,$mobile,$show_seen)
} }
$html .= " $html .= "
$default" . ' $default" . '
<div class="thumb" id="thumbnail:' . $video['videoId'] . '"> <div class="thumb' . ($settings['thumbnail_quality'] == 'maxresdefault' ? '' : ' letterbox') . '" id="thumbnail:' . $video['videoId'] . '">
<img src="https://i.ytimg.com/vi/' . $video['videoId'] . '/' . ($settings['thumbnail_quality'] ? $settings['thumbnail_quality'] : 'default') . '.jpg"/> <img src="https://i.ytimg.com/vi/' . $video['videoId'] . '/' . ($settings['thumbnail_quality'] ? $settings['thumbnail_quality'] : 'default') . '.jpg"/>
<div class="time"> <div class="time">
<h4>' . $video['lengthText'] . '</h4> <h4>' . $video['lengthText'] . '</h4>