mirror of
https://github.com/catdevnull/transicion-desordenada-diablo
synced 2024-11-15 02:21:39 +00:00
mostrar errores en dataset mejor
This commit is contained in:
parent
c860d37db1
commit
972bec6015
1 changed files with 33 additions and 31 deletions
|
@ -29,7 +29,7 @@
|
||||||
class="flex text-blue-500 leading-none gap-1 items-center"
|
class="flex text-blue-500 leading-none gap-1 items-center"
|
||||||
href={inject(routes.DumpIndex, { dumpUrl: params.dumpUrl })}
|
href={inject(routes.DumpIndex, { dumpUrl: params.dumpUrl })}
|
||||||
>
|
>
|
||||||
<ArrowBack fill="currentColor" class="h-[1.25em]" /> Viendo {data.title}
|
<ArrowBack fill="currentColor" class="h-[1.25em]" /> Viendo {data.title}
|
||||||
</a>
|
</a>
|
||||||
</small>
|
</small>
|
||||||
<h1 class="font-bold text-3xl">{dataset.title}</h1>
|
<h1 class="font-bold text-3xl">{dataset.title}</h1>
|
||||||
|
@ -43,43 +43,45 @@
|
||||||
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}
|
<div>
|
||||||
{dist.title}
|
<h3>
|
||||||
(no está en este dump porque hubo un error al bajarlo)
|
{dist.title}
|
||||||
{:else}
|
{#if dist.format}
|
||||||
<div>
|
<span
|
||||||
<h3>
|
class="border border-current text-blue-800 relative inline-flex items-center text-xs font-semibold px-2 py-1 rounded-full ml-1"
|
||||||
{dist.title}
|
>
|
||||||
{#if dist.format}
|
<span>{dist.format}</span>
|
||||||
<span
|
</span>
|
||||||
class="border border-current text-blue-800 relative inline-flex items-center text-xs font-semibold px-2 py-1 rounded-full ml-1"
|
|
||||||
>
|
|
||||||
<span>{dist.format}</span>
|
|
||||||
</span>
|
|
||||||
{/if}
|
|
||||||
</h3>
|
|
||||||
{#if dist.fileName}
|
|
||||||
<small>{dist.fileName}</small>
|
|
||||||
{/if}
|
{/if}
|
||||||
</div>
|
</h3>
|
||||||
<div class="flex flex-col items-center">
|
{#if error}
|
||||||
|
<small class="block text-red-700">
|
||||||
|
No está en este dump porque hubo un error al descargarlo :(
|
||||||
|
</small>
|
||||||
|
{/if}
|
||||||
|
{#if dist.fileName}
|
||||||
|
<small>{dist.fileName}</small>
|
||||||
|
{/if}
|
||||||
|
</div>
|
||||||
|
<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
|
||||||
>
|
>
|
||||||
<a
|
{/if}
|
||||||
class="flex items-center leading-none text-gray-600 gap-1 pt-2"
|
<a
|
||||||
href={dist.downloadURL}
|
class="flex items-center leading-none text-gray-600 gap-1 pt-2"
|
||||||
target="_blank"
|
href={dist.downloadURL}
|
||||||
rel="noopener"
|
target="_blank"
|
||||||
>
|
rel="noopener"
|
||||||
<ExternalLink fill="currentColor" class="h-4" />
|
>
|
||||||
Fuente
|
<ExternalLink fill="currentColor" class="h-4" />
|
||||||
</a>
|
Fuente
|
||||||
</div>
|
</a>
|
||||||
{/if}
|
</div>
|
||||||
</li>
|
</li>
|
||||||
{/each}
|
{/each}
|
||||||
</ul>
|
</ul>
|
||||||
|
|
Loading…
Reference in a new issue