feat : better ui
This commit is contained in:
@@ -42,6 +42,15 @@ export function targetStatIconName(value: string): string | null {
|
||||
: stat.toLowerCase();
|
||||
}
|
||||
|
||||
export function recommendedStatIconName(value: string): string | null {
|
||||
if (value === "CRIT Rate%/CRIT DMG%") return "critrate";
|
||||
if (value === "Healing Bonus%") return "healing-bonus";
|
||||
if (value.endsWith(" DMG%")) return "elemental-bonus";
|
||||
|
||||
const base = value.replace(/%$/, "").toLowerCase();
|
||||
return ["hp", "atk", "def", "em", "er"].includes(base) ? base : null;
|
||||
}
|
||||
|
||||
export function statPriorityColorClass(index: number): string {
|
||||
return index === 0
|
||||
? "text-tier-gold"
|
||||
|
||||
Reference in New Issue
Block a user