chuni: don't display decimal if level <= 7
This commit is contained in:
parent
40aab7bd1f
commit
1424be95fc
@ -15,7 +15,7 @@ export const ChuniLevelBadge = ({ music, className }: ChuniLevelBadgeProps) => {
|
|||||||
{music.worldsEndTag ? worldsEndStars(Math.ceil((music.level!) / 2)) : '\u200b'}
|
{music.worldsEndTag ? worldsEndStars(Math.ceil((music.level!) / 2)) : '\u200b'}
|
||||||
</div>
|
</div>
|
||||||
<div className="bg-black text-[45cqh] w-full flex-grow flex items-center justify-center text-white font-bold" lang="ja">
|
<div className="bg-black text-[45cqh] w-full flex-grow flex items-center justify-center text-white font-bold" lang="ja">
|
||||||
{music.worldsEndTag ?? (floorToDp(music.level!, 1))}
|
{music.worldsEndTag ?? (music.level! <= 7 && Number.isInteger(music.level) ? music.level : floorToDp(music.level!, 1))}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
Loading…
Reference in New Issue
Block a user