mirror of
https://github.com/NoCrypt/migu.git
synced 2026-04-20 16:12:31 +00:00
chore: higher res avatar
This commit is contained in:
parent
6768d67e7b
commit
a0599b2de6
4 changed files with 6 additions and 4 deletions
|
|
@ -95,7 +95,7 @@
|
|||
<button class='close pointer z-30 top-20 right-0 position-absolute' type='button' use:click={close}> × </button>
|
||||
<div class='d-flex flex-column align-items-center'>
|
||||
{#if $currentProfile}
|
||||
<img class='h-150 rounded-circle' src={$currentProfile.viewer.data.Viewer.avatar?.medium || $currentProfile.viewer.data.Viewer.picture} alt='Current Profile' title='Current Profile'>
|
||||
<img class='h-150 rounded-circle' src={$currentProfile.viewer.data.Viewer.avatar?.large || $currentProfile.viewer.data.Viewer.avatar?.medium || $currentProfile.viewer.data.Viewer.picture} alt='Current Profile' title='Current Profile'>
|
||||
<img class='h-3 auth-icon rounded-circle' src={isAniProfile($currentProfile) ? './anilist_icon.png' : './myanimelist_icon.png'} alt={isAniProfile($currentProfile) ? 'Logged in with AniList' : 'Logged in with MyAnimeList'} title={isAniProfile($currentProfile) ? 'Logged in with AniList' : 'Logged in with MyAnimeList'}>
|
||||
<p class='font-size-18 font-weight-bold'>{$currentProfile.viewer.data.Viewer.name}</p>
|
||||
{/if}
|
||||
|
|
@ -109,7 +109,7 @@
|
|||
{#each $profiles as profile}
|
||||
<button type='button' class='profile-item box text-left pointer border-0 d-flex align-items-center justify-content-between position-relative flex-wrap' on:click={() => switchProfile(profile)}>
|
||||
<div class='d-flex align-items-center flex-wrap'>
|
||||
<img class='h-50 ml-10 mt-5 mb-5 mr-10 rounded-circle bg-transparent' src={profile.viewer.data.Viewer.avatar?.medium || profile.viewer.data.Viewer.picture} alt={profile.viewer.data.Viewer.name}>
|
||||
<img class='h-50 ml-10 mt-5 mb-5 mr-10 rounded-circle bg-transparent' src={profile.viewer.data.Viewer.avatar?.large || profile.viewer.data.Viewer.avatar?.medium || profile.viewer.data.Viewer.picture} alt={profile.viewer.data.Viewer.name}>
|
||||
<img class='ml-5 auth-icon rounded-circle' src={isAniProfile(profile) ? './anilist_icon.png' : './myanimelist_icon.png'} alt={isAniProfile(profile) ? 'Logged in with AniList' : 'Logged in with MyAnimeList'} title={isAniProfile(profile) ? 'Logged in with AniList' : 'Logged in with MyAnimeList'}>
|
||||
<p class='text-wrap'>{profile.viewer.data.Viewer.name}</p>
|
||||
</div>
|
||||
|
|
|
|||
1
common/modules/al.d.ts
vendored
1
common/modules/al.d.ts
vendored
|
|
@ -145,6 +145,7 @@ export type MediaListCollection = {
|
|||
export type Viewer = {
|
||||
avatar: {
|
||||
medium: string
|
||||
large: string
|
||||
}
|
||||
name: string
|
||||
id: number
|
||||
|
|
|
|||
|
|
@ -467,7 +467,8 @@ class AnilistClient {
|
|||
query {
|
||||
Viewer {
|
||||
avatar {
|
||||
medium
|
||||
medium,
|
||||
large
|
||||
},
|
||||
name,
|
||||
id,
|
||||
|
|
|
|||
|
|
@ -120,7 +120,7 @@ export default class Helper {
|
|||
|
||||
static getUserAvatar() {
|
||||
if (anilistClient.userID?.viewer?.data?.Viewer) {
|
||||
return anilistClient.userID.viewer.data.Viewer.avatar.medium
|
||||
return anilistClient.userID.viewer.data.Viewer.avatar.large || anilistClient.userID.viewer.data.Viewer.avatar.medium
|
||||
} else if (malClient.userID?.viewer?.data?.Viewer) {
|
||||
return malClient.userID.viewer.data.Viewer.picture
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue