-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
2d5a897
commit 3a2738e
Showing
14 changed files
with
123 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,3 @@ | ||
# Copy to .env.local and edit | ||
PUBLIC_API_ENDPOINT= | ||
PUBLIC_OPENGRAPH_ENDPOINT= | ||
PUBLIC_DISCORD_INVITE= | ||
PUBLIC_SUPPORT_MAIL= | ||
PUBLIC_GTM_ID= | ||
PUBLIC_GA_ID= | ||
|
||
PUBLIC_USE_ACCOUNT= | ||
|
||
PUBLIC_TELEMETRY_ENDPOINT= | ||
PUBLIC_TELEMETRY_API_KEY= | ||
PUBLIC_API_BASE= | ||
PUBLIC_ACCOUNT_SERVICE_URL= |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
<script lang="ts"> | ||
import type { UserListItemModel, TranslationKey } from '@adofai-gg/ui' | ||
import { UserList, Panel, PanelTitle, Translation } from '@adofai-gg/ui' | ||
interface Props { | ||
items: UserListItemModel[] | ||
title: TranslationKey | ||
} | ||
const { items, title }: Props = $props() | ||
</script> | ||
|
||
<Panel> | ||
<PanelTitle> | ||
<Translation key={title} /> | ||
</PanelTitle> | ||
|
||
<div class="user-list"> | ||
<UserList {items} /> | ||
</div> | ||
</Panel> | ||
|
||
<style lang="scss"> | ||
.user-list { | ||
margin-top: 8px; | ||
} | ||
</style> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,6 @@ | ||
song-length = 노래 길이 | ||
bpm = BPM | ||
tiles = 타일 수 | ||
tiles = 타일 수 | ||
artists = 아티스트 | ||
creators = 레벨 제작자 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
import type { APIMember } from '../types' | ||
import { env } from '$env/dynamic/public' | ||
import defaultDark from '$lib/assets/defaultAvatars/dark.png' | ||
import defaultLight from '$lib/assets/defaultAvatars/light.png' | ||
|
||
export const getAvatarUrl = ( | ||
user: APIMember, | ||
usage: 'artist' | 'creator' | null = null | ||
): string => { | ||
if (!user.username) { | ||
return usage === 'artist' ? defaultDark : defaultLight | ||
} | ||
|
||
return `${env.PUBLIC_ACCOUNT_SERVICE_URL}/content/avatars/${user}/${user.avatar ?? 'default'}` | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
import type { User } from '@adofai-gg/ui' | ||
import type { APIMember } from '../types' | ||
import { getAvatarUrl } from './avatar' | ||
|
||
export const convertUser = (from: APIMember, usage: 'artist' | 'creator' | null = null): User => { | ||
return { | ||
avatarURL: getAvatarUrl(from, usage), | ||
displayName: from.displayName, | ||
isAdmin: false | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters