diff --git a/packages/website/src/components/CompareTable/index.tsx b/packages/website/src/components/CompareTable/index.tsx index bd874955b..809ec8d5f 100644 --- a/packages/website/src/components/CompareTable/index.tsx +++ b/packages/website/src/components/CompareTable/index.tsx @@ -213,7 +213,6 @@ function Group({ group, characteristics }: GroupProps) { if (items.length === 0) return null; - const isShellGroup = group.name === "shell"; const title = ( strings.tanks.characteristics.titles as Record )[group.name]; @@ -222,12 +221,12 @@ function Group({ group, characteristics }: GroupProps) { {title} - {isShellGroup && + {group.shells && members.map((member, index) => ( diff --git a/packages/website/src/config/characteristicsGroups.ts b/packages/website/src/config/characteristicsGroups.ts index 74b9aeebc..b2282637b 100644 --- a/packages/website/src/config/characteristicsGroups.ts +++ b/packages/website/src/config/characteristicsGroups.ts @@ -334,6 +334,7 @@ export const characteristicsGroups: CharacteristicsGroup[] = [ { name: "gun", + shells: true, // render: CharacteristicsGroupRender.Statistical, order: [ { @@ -394,6 +395,7 @@ export const characteristicsGroups: CharacteristicsGroup[] = [ { name: "clip", + shells: true, // render: CharacteristicsGroupRender.Statistical, order: [ { name: "clipping_potential", localize: true, units: "hp" }, @@ -420,6 +422,7 @@ export const characteristicsGroups: CharacteristicsGroup[] = [ { name: "shell", + shells: true, // render: CharacteristicsGroupRender.Statistical, order: [ { name: "penetration", units: "mm" }, diff --git a/packages/website/src/types/characteristics.ts b/packages/website/src/types/characteristics.ts index e7122efc0..bce2c03b5 100644 --- a/packages/website/src/types/characteristics.ts +++ b/packages/website/src/types/characteristics.ts @@ -130,5 +130,7 @@ export type CharacteristicsGroup = { name: string; // Groups that only some tanks have are no use as a sort key sortable?: boolean; + // Shows each tank's shell switcher in the group's title row + shells?: boolean; order: (CharacteristicRenderConfig | LabelRenderConfig | ToyRenderConfig)[]; };