mostrar errores en dataset mejor

This commit is contained in:
Cat /dev/Nulo 2023-12-08 01:41:35 -03:00
parent c860d37db1
commit 972bec6015

View file

@ -43,10 +43,6 @@
e.distributionIdentifier === dist.identifier, e.distributionIdentifier === dist.identifier,
)} )}
<li class="flex px-6 py-5 justify-between items-center"> <li class="flex px-6 py-5 justify-between items-center">
{#if error}
{dist.title}
(no está en este dump porque hubo un error al bajarlo)
{:else}
<div> <div>
<h3> <h3>
{dist.title} {dist.title}
@ -58,17 +54,24 @@
</span> </span>
{/if} {/if}
</h3> </h3>
{#if error}
<small class="block text-red-700">
No está en este dump porque hubo un error al descargarlo :(
</small>
{/if}
{#if dist.fileName} {#if dist.fileName}
<small>{dist.fileName}</small> <small>{dist.fileName}</small>
{/if} {/if}
</div> </div>
<div class="flex flex-col items-center"> <div class="flex flex-col items-center">
{#if !error}
<button <button
type="button" type="button"
class="inline-flex items-center justify-center px-4 py-2 text-sm font-medium tracking-wide text-white transition-colors duration-200 bg-blue-600 rounded-md hover:bg-blue-700 focus:ring-2 focus:ring-offset-2 focus:ring-blue-700 focus:shadow-outline focus:outline-none" class="inline-flex items-center justify-center px-4 py-2 text-sm font-medium tracking-wide text-white transition-colors duration-200 bg-blue-600 rounded-md hover:bg-blue-700 focus:ring-2 focus:ring-offset-2 focus:ring-blue-700 focus:shadow-outline focus:outline-none"
on:click={() => downloadFile(url, dataset.identifier, dist)} on:click={() => downloadFile(url, dataset.identifier, dist)}
>Descargar</button >Descargar</button
> >
{/if}
<a <a
class="flex items-center leading-none text-gray-600 gap-1 pt-2" class="flex items-center leading-none text-gray-600 gap-1 pt-2"
href={dist.downloadURL} href={dist.downloadURL}
@ -79,7 +82,6 @@
Fuente Fuente
</a> </a>
</div> </div>
{/if}
</li> </li>
{/each} {/each}
</ul> </ul>