mirror of
https://github.com/openfrontio/OpenFrontIO.git
synced 2026-06-24 13:52:45 +00:00
clan stats breakdown (#3869)
## Description: improvements to clan ui. <img width="788" height="290" alt="image" src="https://github.com/user-attachments/assets/736ca147-bff4-44d8-8180-7b80a85556fe" /> added "expand all" and new collapsible sections. <img width="787" height="550" alt="image" src="https://github.com/user-attachments/assets/deb2f813-854b-46a9-a767-52c4f749f30f" /> which changes to collapse all when expanded also adds more info about team (d,t,q,2,3,4,5,6,7 team) ## Please complete the following: - [x] I have added screenshots for all UI updates - [x] I process any text displayed to the user through translateText() and I've added it to the en.json file - [x] I have added relevant tests to the test directory - [x] I confirm I have thoroughly tested these changes and take full responsibility for any bugs introduced ## Please put your Discord username so you can be contacted if a bug or regression is found: w.o.n
This commit is contained in:
@@ -55,11 +55,36 @@ export const ClanMemberStatsSchema = z.object({
|
||||
ffa: ClanMemberWLSchema,
|
||||
team: ClanMemberWLSchema,
|
||||
hvn: ClanMemberWLSchema,
|
||||
duos: ClanMemberWLSchema,
|
||||
trios: ClanMemberWLSchema,
|
||||
quads: ClanMemberWLSchema,
|
||||
"2": ClanMemberWLSchema,
|
||||
"3": ClanMemberWLSchema,
|
||||
"4": ClanMemberWLSchema,
|
||||
"5": ClanMemberWLSchema,
|
||||
"6": ClanMemberWLSchema,
|
||||
"7": ClanMemberWLSchema,
|
||||
ranked: ClanMemberWLSchema,
|
||||
"1v1": ClanMemberWLSchema,
|
||||
});
|
||||
export type ClanMemberStats = z.infer<typeof ClanMemberStatsSchema>;
|
||||
|
||||
export const TEAM_BREAKDOWN_KEYS = [
|
||||
"duos",
|
||||
"trios",
|
||||
"quads",
|
||||
"2",
|
||||
"3",
|
||||
"4",
|
||||
"5",
|
||||
"6",
|
||||
"7",
|
||||
] as const satisfies readonly (keyof ClanMemberStats)[];
|
||||
|
||||
export const RANKED_BREAKDOWN_KEYS = [
|
||||
"1v1",
|
||||
] as const satisfies readonly (keyof ClanMemberStats)[];
|
||||
|
||||
export const ClanMemberSchema = z.object({
|
||||
role: z.enum(["leader", "officer", "member"]),
|
||||
joinedAt: z.iso.datetime(),
|
||||
|
||||
Reference in New Issue
Block a user