feat: tv episode results
This commit is contained in:
@@ -19,8 +19,24 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{% if "movies" == results.media.mediaType %}
|
||||
<div id="results" {{ stimulus_controller('movie_results', {imdbId: results.media.imdbId}) }}>
|
||||
</div>
|
||||
{% elseif "tvshows" == results.media.mediaType %}
|
||||
{% for season, episodes in results.media.episodes %}
|
||||
{% set active = (season == '1') ? true : false %}
|
||||
{% for episode in episodes %}
|
||||
<div id="results" {{ stimulus_controller('tv_results', {
|
||||
tmdbId: results.media.tmdbId,
|
||||
imdbId: results.media.imdbId,
|
||||
season: season,
|
||||
episode: episode['episode_number'],
|
||||
active: active,
|
||||
}) }}>
|
||||
</div>
|
||||
{% endfor %}
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
|
||||
</twig:Card>
|
||||
</div>
|
||||
|
||||
@@ -1,3 +1,73 @@
|
||||
<div class="p-2 flex flex-row gap-6 bg-orange-500 bg-clip-padding backdrop-filter backdrop-blur-md bg-opacity-60 rounded-md">
|
||||
<h3 class="text-md">Episodes</h3>
|
||||
</div>
|
||||
<div class="p-2 flex flex-col gap-6 bg-orange-500 bg-clip-padding backdrop-filter backdrop-blur-md bg-opacity-60 rounded-md">
|
||||
<h4 class="text-md font-bold">Episode {{ results.episode }}</h4>
|
||||
<div class="flex flex-row gap-4">
|
||||
<img class="w-24 rounded-lg" src="{{ results.media.poster }}" />
|
||||
<div class="flex flex-col gap-4">
|
||||
<h5 class="text-md font-bold">{{ results.media.title }}</h5>
|
||||
<p>{{ results.media.description }}</p>
|
||||
</div>
|
||||
</div>
|
||||
<table class="divide-y divide-gray-200 dark:divide-gray-50 dark:bg-transparent rounded-lg">
|
||||
<thead>
|
||||
<tr class="dark:bg-stone-600 overflow-hidden rounded-md">
|
||||
<th scope="col"
|
||||
class="px-6 py-3 text-start text-xs font-medium text-stone-500 uppercase dark:text-gray-50">
|
||||
Size
|
||||
</th>
|
||||
<th scope="col"
|
||||
class="px-6 py-3 text-start text-xs font-medium text-gray-500 uppercase dark:text-gray-50">
|
||||
Resolution
|
||||
</th>
|
||||
<th scope="col"
|
||||
class="px-6 py-3 text-start text-xs font-medium text-gray-500 uppercase dark:text-gray-50">
|
||||
Codec
|
||||
</th>
|
||||
<th scope="col"
|
||||
class="px-6 py-3 text-start text-xs font-medium text-gray-500 uppercase dark:text-gray-50">
|
||||
Seeders
|
||||
</th>
|
||||
<th scope="col"
|
||||
class="px-6 py-3 text-start text-xs font-medium text-gray-500 uppercase dark:text-gray-50">
|
||||
Provider
|
||||
</th>
|
||||
<th scope="col"
|
||||
class="px-6 py-3 text-start text-xs font-medium text-gray-500 uppercase dark:text-gray-50">
|
||||
Language
|
||||
</th>
|
||||
<th scope="col"
|
||||
class="px-6 py-3 text-start text-xs font-medium text-gray-500 uppercase dark:text-gray-50">
|
||||
</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody class="divide-y divide-gray-200 dark:divide-gray-50">
|
||||
{% for result in results.results %}
|
||||
<tr>
|
||||
<td class="px-6 py-4 whitespace-nowrap text-sm font-medium text-gray-800 dark:text-gray-50">
|
||||
{{ result.size }}
|
||||
</td>
|
||||
<td class="px-6 py-4 whitespace-nowrap text-sm font-medium text-gray-800 dark:text-gray-50">
|
||||
{{ result.resolution }}
|
||||
</td>
|
||||
<td class="px-6 py-4 whitespace-nowrap text-sm font-medium text-gray-800 dark:text-gray-50">
|
||||
{{ result.codec }}
|
||||
</td>
|
||||
<td class="px-6 py-4 whitespace-nowrap text-sm font-medium text-gray-800 dark:text-gray-50">
|
||||
{{ result.seeders }}
|
||||
</td>
|
||||
<td class="px-6 py-4 whitespace-nowrap text-sm font-medium text-gray-800 dark:text-gray-50">
|
||||
{{ result.provider }}
|
||||
</td>
|
||||
<td class="px-6 py-4 whitespace-nowrap text-sm font-medium text-gray-800 dark:text-gray-50">
|
||||
{{ result.languageFlags }}
|
||||
</td>
|
||||
<td class="px-6 py-4 whitespace-nowrap text-sm text-end text-gray-800 dark:text-gray-50">
|
||||
<span class="p-1.5 bg-green-600 rounded-md">
|
||||
<span class="text-gray-50">Download</span>
|
||||
</span>
|
||||
<input class="ml-1" type="checkbox" name="select" />
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user