zenno: format

This commit is contained in:
2026-03-31 12:07:38 -04:00
parent 08deedea8f
commit 22ca5c98f3
15 changed files with 196 additions and 179 deletions
+10 -7
View File
@@ -1,5 +1,5 @@
import type { RegionalName } from '$lib/regional-name'
import globalJSON from '../../../../global/character.json'
import type { RegionalName } from '$lib/regional-name';
import globalJSON from '../../../../global/character.json';
/**
* Character definitions.
@@ -8,16 +8,19 @@ export interface Character {
/**
* Character ID.
*/
chara_id: number
chara_id: number;
/**
* Regional name of the character.
* E.g., Special Week for Global, or スペシャルウィーク for JP.
*/
name: string
name: string;
}
export const character = {
global: globalJSON as Character[],
}
global: globalJSON as Character[],
};
export const charaNames = globalJSON.reduce((m, c) => m.set(c.chara_id, {en: c.name}), new Map<Character['chara_id'], RegionalName>());
export const charaNames = globalJSON.reduce(
(m, c) => m.set(c.chara_id, { en: c.name }),
new Map<Character['chara_id'], RegionalName>(),
);