From 0058d3e2910f07a2fc1f24f4c4006db57a4e3d7e Mon Sep 17 00:00:00 2001 From: NilsUeter Date: Sun, 23 Feb 2025 10:50:01 +0100 Subject: [PATCH] some units are now more compact, for example pc squad --- src/10th/Roster.jsx | 86 ++++++++++++++++++++++++--------------------- 1 file changed, 45 insertions(+), 41 deletions(-) diff --git a/src/10th/Roster.jsx b/src/10th/Roster.jsx index 2fcbddc..63af7fa 100644 --- a/src/10th/Roster.jsx +++ b/src/10th/Roster.jsx @@ -190,6 +190,7 @@ const Unit = ({ unit, index, catalog, onePerPage, forceRules }) => {
{ {cost.points}pts
- -
- {modelStats.map((model, index) => ( - 1} - /> - ))} +
+
+ {modelStats.map((model, index) => ( + 1} + /> + ))} +
+ {modelStats?.[0] && ( +
1 ? "" : "self-center" + }`} + style={{ + fontSize: "0.7em", + }} + > + {modelList.map((model, index) => ( +
{model}
+ ))} +
+ )}
{ wounds = "/"; } - const showWeapons = index === 0; return (
@@ -462,26 +475,17 @@ const ModelStats = ({ modelStat, index, showName, modelList }) => { -
- {showName &&
{name}
} - {showWeapons && ( -
- {modelList.map((model, index) => ( -
{model}
- ))} -
- )} -
+ {showName && ( +
+
{name}
+
+ )}
); };