{ if (e.target === e.currentTarget) hideModal(); }} onkeydown={(e) => { if (e.target === e.currentTarget) hideModal(); }} role="button" tabindex="-1" transition:fade >
e.stopPropagation()} onkeydown={(e) => e.stopPropagation()} > {#if theme}
hideModal()}> {'\ued8a'}
{theme.name}
{(theme.download_count ?? 0).toLocaleString()} downloads
{(theme.favorite_count ?? 0).toLocaleString()} favorites
{theme.description}
{#if toggleFavorite && theme}
{theme.is_favorited ? 'Favorited' : 'Favorite'}
{/if} {#if currentThemes.includes(theme.id)}
{installing = true; await onRemove(theme.id); installing = false}} class="flex relative justify-center items-center px-4 py-2 w-32 text-black rounded-full dark:text-white bg-zinc-300 dark:bg-zinc-700 dark:hover:bg-zinc-600/50 hover:bg-zinc-200 transition-all duration-200 hover:scale-105 active:scale-95"> {#if installing}
{/if}
Remove
{:else}
{installing = true; await onInstall(theme.id); installing = false}} class="flex relative justify-center items-center px-4 py-2 w-32 text-black rounded-full dark:text-white bg-zinc-300 dark:bg-zinc-700 dark:hover:bg-zinc-600/50 hover:bg-zinc-200 transition-all duration-200 hover:scale-105 active:scale-95"> {#if installing}
{/if}
Install
{/if}
Similar Themes
{#each getRelatedThemes() as relatedTheme (relatedTheme.id)}
{ hideModal(relatedTheme) }} class="w-full cursor-pointer">
{relatedTheme.name}
{/each}
{:else}
hideModal()}> Close
{/if}
{#if showSignInModal}
(showSignInModal = false)} /> {/if}