Remove dead color code (#3613)

## Description:

Remove dead code relating to colors.

## 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:

DISCORD_USERNAME

babyboucher
This commit is contained in:
babyboucher
2026-04-08 16:52:12 -05:00
committed by GitHub
parent 646d7ecaf6
commit f3cbca059f
4 changed files with 0 additions and 19 deletions
-5
View File
@@ -240,7 +240,6 @@ export async function getPlayerCosmeticsRefs(): Promise<PlayerCosmeticRefs> {
return {
flag: flag ?? undefined,
color: userSettings.getSelectedColor() ?? undefined,
patternName: pattern?.name ?? undefined,
patternColorPaletteName: pattern?.colorPalette?.name ?? undefined,
};
@@ -256,10 +255,6 @@ export async function getPlayerCosmetics(): Promise<PlayerCosmetics> {
result.flag = await resolveFlagUrl(refs.flag);
}
if (refs.color) {
result.color = { color: refs.color };
}
if (refs.patternName && cosmetics) {
const pattern = cosmetics.patterns[refs.patternName];
-1
View File
@@ -267,7 +267,6 @@ export class StoreModal extends BaseModal {
private selectPattern(pattern: PlayerPattern | null) {
this.selectedColor = null;
this.userSettings.setSelectedColor(undefined);
if (pattern === null) {
this.userSettings.setSelectedPatternName(undefined);
} else {
-1
View File
@@ -215,7 +215,6 @@ export class TerritoryPatternsModal extends BaseModal {
private selectPattern(pattern: PlayerPattern | null) {
this.selectedColor = null;
this.userSettings.setSelectedColor(undefined);
if (pattern === null) {
this.userSettings.setSelectedPatternName(undefined);
} else {
-12
View File
@@ -229,18 +229,6 @@ export class UserSettings {
}
}
getSelectedColor(): string | undefined {
return this.getCached(COLOR_KEY) ?? undefined;
}
setSelectedColor(color: string | undefined): void {
if (color === undefined) {
this.removeCached(COLOR_KEY);
} else {
this.setCached(COLOR_KEY, color);
}
}
getFlag(): string | null {
let flag = this.getCached(FLAG_KEY);
if (!flag) return null;