Display the correct file extension on download button
This commit is contained in:
@@ -28,9 +28,15 @@
|
||||
<path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M19 14l-7 7m0 0l-7-7m7 7V3"></path>
|
||||
</svg>
|
||||
</div>
|
||||
@php
|
||||
$fileExtension = "HEVC";
|
||||
if (str_contains($episode->getDownloadByType('FHD')->url, 'AV1')) {
|
||||
$fileExtension = "AV1";
|
||||
}
|
||||
@endphp
|
||||
<div class="flex flex-col text-center w-full">
|
||||
<p class="text-xl">Episode {{ $episode->episode }}</p>
|
||||
<p class="text-xs">HEVC MKV {{ $episode->getDownloadByType('FHD')->getFileSize() ?? '' }}</p>
|
||||
<p class="text-xs">{{ $fileExtension }} MKV {{ $episode->getDownloadByType('FHD')->getFileSize() ?? '' }}</p>
|
||||
<p class="text-xs" id="downloadCount">Downloaded {{ $episode->getDownloadByType('FHD')->count }} times</p>
|
||||
</div>
|
||||
</button>
|
||||
|
||||
Reference in New Issue
Block a user