aboutsummaryrefslogtreecommitdiff
path: root/src/lib/Tools/Wrapped/MediaExtras.svelte
diff options
context:
space:
mode:
authorFuwn <[email protected]>2024-10-09 00:41:20 -0700
committerFuwn <[email protected]>2024-10-09 00:41:43 -0700
commit998b63a35256ac985a5a2714dd1ca451af4dfd8a (patch)
tree50796121a9d5ab0330fdc5d7e098bda2860d9726 /src/lib/Tools/Wrapped/MediaExtras.svelte
parentfeat(graphql): add badgeCount field (diff)
downloaddue.moe-998b63a35256ac985a5a2714dd1ca451af4dfd8a.tar.xz
due.moe-998b63a35256ac985a5a2714dd1ca451af4dfd8a.zip
chore(prettier): use spaces instead of tabs
Diffstat (limited to 'src/lib/Tools/Wrapped/MediaExtras.svelte')
-rw-r--r--src/lib/Tools/Wrapped/MediaExtras.svelte136
1 files changed, 68 insertions, 68 deletions
diff --git a/src/lib/Tools/Wrapped/MediaExtras.svelte b/src/lib/Tools/Wrapped/MediaExtras.svelte
index 9ef8cb65..9e755ea5 100644
--- a/src/lib/Tools/Wrapped/MediaExtras.svelte
+++ b/src/lib/Tools/Wrapped/MediaExtras.svelte
@@ -1,74 +1,74 @@
<script lang="ts">
- import type { TopMedia } from '$lib/Data/AniList/wrapped';
- import proxy from '$lib/Utility/proxy';
+ import type { TopMedia } from '$lib/Data/AniList/wrapped';
+ import proxy from '$lib/Utility/proxy';
- export let topMedia: TopMedia;
- export let updateWidth: () => void;
- export let highestRatedGenreTagPercentage: boolean;
- export let genreTagTitle: string;
+ export let topMedia: TopMedia;
+ export let updateWidth: () => void;
+ export let highestRatedGenreTagPercentage: boolean;
+ export let genreTagTitle: string;
</script>
<div class="categories-grid" style="padding-top: 0;">
- {#if topMedia.topGenreMedia && topMedia.genres.length > 0}
- <div class="category-grid pure-category category">
- <div class="grid-item image-grid">
- <a
- href={`https://anilist.co/${topMedia.topGenreMedia.type.toLowerCase()}/${
- topMedia.topGenreMedia.id
- }`}
- target="_blank"
- >
- <img
- src={proxy(topMedia.topGenreMedia.coverImage.extraLarge)}
- alt="Highest Rated Genre Cover"
- class="cover-image"
- on:load={updateWidth}
- />
- </a>
- <div>
- <b>{genreTagTitle} Genres</b>
- <ol>
- {#each topMedia.genres as genre}
- <li>
- <a href={`https://anilist.co/search/anime?genres=${genre.genre}`} target="_blank">
- {genre.genre}{highestRatedGenreTagPercentage ? `: ${genre.averageScore}%` : ''}
- </a>
- </li>
- {/each}
- </ol>
- </div>
- </div>
- </div>
- {/if}
- {#if topMedia.topTagMedia && topMedia.tags.length > 0}
- <div class="category-grid pure-category category">
- <div class="grid-item image-grid">
- <a
- href={`https://anilist.co/${topMedia.topTagMedia.type.toLowerCase()}/${
- topMedia.topTagMedia.id
- }`}
- target="_blank"
- >
- <img
- src={proxy(topMedia.topTagMedia.coverImage.extraLarge)}
- alt="Highest Rated Tag Cover"
- class="cover-image"
- on:load={updateWidth}
- />
- </a>
- <div>
- <b>{genreTagTitle} Tags</b>
- <ol>
- {#each topMedia.tags as tag}
- <li>
- <a href={`https://anilist.co/search/anime?genres=${tag.tag}`} target="_blank">
- {tag.tag}{highestRatedGenreTagPercentage ? `: ${tag.averageScore}%` : ''}
- </a>
- </li>
- {/each}
- </ol>
- </div>
- </div>
- </div>
- {/if}
+ {#if topMedia.topGenreMedia && topMedia.genres.length > 0}
+ <div class="category-grid pure-category category">
+ <div class="grid-item image-grid">
+ <a
+ href={`https://anilist.co/${topMedia.topGenreMedia.type.toLowerCase()}/${
+ topMedia.topGenreMedia.id
+ }`}
+ target="_blank"
+ >
+ <img
+ src={proxy(topMedia.topGenreMedia.coverImage.extraLarge)}
+ alt="Highest Rated Genre Cover"
+ class="cover-image"
+ on:load={updateWidth}
+ />
+ </a>
+ <div>
+ <b>{genreTagTitle} Genres</b>
+ <ol>
+ {#each topMedia.genres as genre}
+ <li>
+ <a href={`https://anilist.co/search/anime?genres=${genre.genre}`} target="_blank">
+ {genre.genre}{highestRatedGenreTagPercentage ? `: ${genre.averageScore}%` : ''}
+ </a>
+ </li>
+ {/each}
+ </ol>
+ </div>
+ </div>
+ </div>
+ {/if}
+ {#if topMedia.topTagMedia && topMedia.tags.length > 0}
+ <div class="category-grid pure-category category">
+ <div class="grid-item image-grid">
+ <a
+ href={`https://anilist.co/${topMedia.topTagMedia.type.toLowerCase()}/${
+ topMedia.topTagMedia.id
+ }`}
+ target="_blank"
+ >
+ <img
+ src={proxy(topMedia.topTagMedia.coverImage.extraLarge)}
+ alt="Highest Rated Tag Cover"
+ class="cover-image"
+ on:load={updateWidth}
+ />
+ </a>
+ <div>
+ <b>{genreTagTitle} Tags</b>
+ <ol>
+ {#each topMedia.tags as tag}
+ <li>
+ <a href={`https://anilist.co/search/anime?genres=${tag.tag}`} target="_blank">
+ {tag.tag}{highestRatedGenreTagPercentage ? `: ${tag.averageScore}%` : ''}
+ </a>
+ </li>
+ {/each}
+ </ol>
+ </div>
+ </div>
+ </div>
+ {/if}
</div>