feat: node rendering

Co-authored-by: Copilot <[email protected]>
This commit is contained in:
TrèsAbhiandCopilot committed 2026-04-29 10:46:37 -05:00
1 parent ff56f1441e
commit 76dc9f0742
4 files changed
+36 -9

No files matched your search

@@ -4,6 +4,8 @@ import {
TankClass,
TankType,
} from "@protos/game/proto/legacy/blitz_static_tank_component";
import type { ReactNode } from "react";
import { VintageIcon } from "../../icons/Vintage";
import {
GunType,
type CharacteristicName,
@@ -24,7 +26,7 @@ export interface CharacteristicRenderConfig {
output: CharacteristicOutput;
strings: Strings;
gameStrings: Record<string, string>;
}) => string;
}) => ReactNode;
}
type CharacteristicsOrder = {
@@ -52,6 +54,11 @@ export const characteristicsOrder: CharacteristicsOrder = [
name: "tier",
render({ output, strings }) {
const [, name] = (output as string).split(".");
if (name == "vintage") {
return <VintageIcon />;
}
return strings.tiers[name as keyof typeof strings.tiers];
},
},