fix: renders media exists badge on movie results
This commit is contained in:
@@ -6,7 +6,7 @@
|
||||
<template data-popover-target="content">
|
||||
<div data-popover-target="card"
|
||||
class="absolute z-40 p-1 bg-stone-400 p-1 text-black rounded-md m-1 animate-fade">
|
||||
<p class="font-bold text-sm text-left">Existing file(s) for this episode:</p>
|
||||
<p class="font-bold text-sm text-left">Existing file(s) for this media:</p>
|
||||
<ul class="list-disc ml-3">
|
||||
<li class="font-normal">{{ result.file.filename|strip_media_path }} — <strong>{{ result.file.size|filesize }}</strong></li>
|
||||
</ul>
|
||||
@@ -23,7 +23,7 @@
|
||||
|
||||
{% if result.exists == false %}
|
||||
<small class="py-1 px-1.5 mr-1 grow-0 font-bold bg-rose-600 rounded-lg text-white"
|
||||
title="Episode has not been downloaded yet.">
|
||||
title="Media has not been downloaded yet.">
|
||||
missing
|
||||
</small>
|
||||
{% endif %}
|
||||
|
||||
@@ -49,9 +49,32 @@
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
<p class="text-gray-50">
|
||||
{{ results.media.description }}
|
||||
</p>
|
||||
|
||||
{% if "movies" == results.media.mediaType %}
|
||||
<div class="flex flex-row justify-start items-end grow">
|
||||
<span class="py-1 px-1.5 mr-1 grow-0 font-bold text-xs bg-green-600 rounded-lg hover:cursor-pointer hover:bg-green-700 text-white">
|
||||
<span id="movie_results_count">-</span> results
|
||||
</span>
|
||||
|
||||
<small class="py-1 px-1.5 mr-1 grow-0 font-bold bg-gray-700 rounded-lg font-normal text-white" title="Release date {{ results.media.episodeAirDate }}">
|
||||
{{ results.media.episodeAirDate|date(null, 'UTC') }}
|
||||
</small>
|
||||
|
||||
<twig:Turbo:Frame id="meb_{{ results.media.imdbId }}" src="{{ path('api.library.search', {
|
||||
title: results.media.title,
|
||||
block: 'media_exists_badge',
|
||||
target: "meb_" ~ results.media.imdbId
|
||||
}) }}">
|
||||
<small class="py-1 px-1.5 mr-1 grow-0 font-bold bg-rose-600 rounded-lg text-white" title="Movie has not been downloaded yet.">
|
||||
missing
|
||||
</small>
|
||||
</twig:Turbo:Frame>
|
||||
</div>
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user