feat: support every song difficulty including Easy and Normal
Publish GitHub Pages output / publish (push) Successful in 41s
Publish GitHub Pages output / publish (push) Successful in 41s
This commit is contained in:
@@ -0,0 +1,10 @@
|
||||
export const difficulties = ['expert', 'hard', 'normal', 'easy'] as const;
|
||||
export type DifficultyKey = typeof difficulties[number];
|
||||
|
||||
export function isDifficulty(value: unknown): value is DifficultyKey {
|
||||
return typeof value === 'string' && difficulties.some((difficulty) => difficulty === value);
|
||||
}
|
||||
|
||||
export function difficultyLabel(value: string): string {
|
||||
return value.charAt(0).toUpperCase() + value.slice(1);
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user