Fix layout shift on turn change and restore concentration border width
Give all combatant rows a consistent border-l-2 + border on all sides (transparent when inactive) so toggling active/concentration states never changes the row's box size. Show purple left border when a combatant is both active and concentrating. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -365,9 +365,13 @@ function rowBorderClass(
|
||||
isActive: boolean,
|
||||
isConcentrating: boolean | undefined,
|
||||
): string {
|
||||
if (isActive) return "border border-accent/40 bg-accent/10 card-glow";
|
||||
if (isConcentrating) return "border-l-2 border-l-purple-400";
|
||||
return "border-l-2 border-l-transparent";
|
||||
if (isActive && isConcentrating)
|
||||
return "border border-l-2 border-accent/40 border-l-purple-400 bg-accent/10 card-glow";
|
||||
if (isActive)
|
||||
return "border border-l-2 border-accent/40 bg-accent/10 card-glow";
|
||||
if (isConcentrating)
|
||||
return "border border-l-2 border-transparent border-l-purple-400";
|
||||
return "border border-l-2 border-transparent";
|
||||
}
|
||||
|
||||
function concentrationIconClass(
|
||||
|
||||
Reference in New Issue
Block a user