chore: add and apply eslint

This commit is contained in:
Axel Cocat 2022-05-14 18:44:50 +02:00
parent 7cd2748d33
commit bb6428955f
17 changed files with 1455 additions and 132 deletions

View file

@ -41,7 +41,16 @@ export class Utils {
return [1, 3, 4, 7, 11].includes(race) ? EFaction.Alliance : EFaction.Horde;
}
public static makeEmblemObject(obj: any, padWithZeroes: boolean = true): IEmblem {
public static makeEmblemObject(
obj: {
background: number;
emblemStyle: number;
emblemColor: number;
borderStyle: number;
borderColor: number;
},
padWithZeroes = true,
): IEmblem {
const padLength = padWithZeroes ? 2 : 0;
return {
icon: obj.emblemStyle.toString().padStart(padLength, "0"),