fixed firefox issue, more weapon abilities

This commit is contained in:
NilsUeter
2023-06-06 17:00:54 +02:00
parent 48a25cbf98
commit 12ae008e9c
3 changed files with 28 additions and 7 deletions
+13 -2
View File
@@ -264,7 +264,11 @@ const Unit = ({ unit, index, catalog, onePerPage, forceRules }) => {
}} }}
> >
<Spells title="PSYCHIC" spells={spells} /> <Spells title="PSYCHIC" spells={spells} />
<table className="weapons-table" style={{ width: "100%" }}> <table
cellspacing="0"
className="weapons-table"
style={{ width: "100%" }}
>
<Weapons <Weapons
title="RANGED WEAPONS" title="RANGED WEAPONS"
weapons={rangedWeapons} weapons={rangedWeapons}
@@ -279,7 +283,11 @@ const Unit = ({ unit, index, catalog, onePerPage, forceRules }) => {
/> />
</table> </table>
<div style={{ flex: "1" }}></div> <div style={{ flex: "1" }}></div>
<table className="weapons-table" style={{ width: "100%" }}> <table
cellspacing="0"
className="weapons-table"
style={{ width: "100%" }}
>
<tbody> <tbody>
{weaponDescriptions.map((weapon, index) => ( {weaponDescriptions.map((weapon, index) => (
<tr key={index} className="emptyRow noBorderTop"> <tr key={index} className="emptyRow noBorderTop">
@@ -603,6 +611,7 @@ const FancyBox = ({ children }) => {
const Psykers = ({ title, psykers }) => { const Psykers = ({ title, psykers }) => {
return ( return (
<table <table
cellspacing="0"
className="weapons-table" className="weapons-table"
style={{ width: "100%", margin: "4px 2px" }} style={{ width: "100%", margin: "4px 2px" }}
> >
@@ -674,6 +683,7 @@ const WoundTracker = ({ woundTracker }) => {
}} }}
> >
<table <table
cellspacing="0"
className="weapons-table" className="weapons-table"
style={{ width: "100%", margin: "4px 2px", marginBottom: -16 }} style={{ width: "100%", margin: "4px 2px", marginBottom: -16 }}
> >
@@ -709,6 +719,7 @@ const WoundTracker = ({ woundTracker }) => {
const Spells = ({ title, spells }) => { const Spells = ({ title, spells }) => {
return ( return (
<table <table
cellspacing="0"
className="weapons-table" className="weapons-table"
style={{ width: "100%", marginTop: "var(--size-20)" }} style={{ width: "100%", marginTop: "var(--size-20)" }}
> >
+15 -1
View File
@@ -67,7 +67,7 @@ const Weapon = ({ weapon, modelStats, isMelee, className, forceRules }) => {
} }
const differentProfiles = const differentProfiles =
selectionName && selectionName &&
selectionName !== name && selectionName.toLowerCase() !== name.toLowerCase() &&
!name.includes("(Shooting)") && !name.includes("(Shooting)") &&
!name.includes("(Melee)"); !name.includes("(Melee)");
@@ -113,6 +113,7 @@ const Weapon = ({ weapon, modelStats, isMelee, className, forceRules }) => {
[ [
"Each time an attack is made with this weapon, that attack automatically hits the target.", "Each time an attack is made with this weapon, that attack automatically hits the target.",
"This weapon automatically hits its target.", "This weapon automatically hits its target.",
"This weapon automatically hits its targets.",
"When resolving an attack made with this weapon, do not make a hit roll: it automatically scores a hit.", "When resolving an attack made with this weapon, do not make a hit roll: it automatically scores a hit.",
], ],
"Torrent", "Torrent",
@@ -123,6 +124,13 @@ const Weapon = ({ weapon, modelStats, isMelee, className, forceRules }) => {
"Indirect Fire", "Indirect Fire",
"This weapon can target units that are not visible to the bearer." "This weapon can target units that are not visible to the bearer."
); );
replaceAbilityWithType(
[
"Each time an attack is made with this weapon, the target does not receive the benefits of cover against that attack.",
],
"Ignores Cover",
"Each time an attack is made with this weapon, the target does not receive the benefits of cover against that attack."
);
replaceAbilityWithType( replaceAbilityWithType(
[ [
"The bearer can only shoot with this weapon once per battle.", "The bearer can only shoot with this weapon once per battle.",
@@ -300,6 +308,9 @@ const Weapon = ({ weapon, modelStats, isMelee, className, forceRules }) => {
abilities?.includes( abilities?.includes(
"Each time an attack is made wit this weapon profile, make 2 hit rolls instead of 1." "Each time an attack is made wit this weapon profile, make 2 hit rolls instead of 1."
) || ) ||
abilities?.includes(
"Each time an attack is made with this profile, make 2 hit rolls instead of 1."
) ||
abilities?.includes( abilities?.includes(
"Make 2 hit rolls for each attack made with this profile, instead of 1" "Make 2 hit rolls for each attack made with this profile, instead of 1"
) )
@@ -321,6 +332,9 @@ const Weapon = ({ weapon, modelStats, isMelee, className, forceRules }) => {
"Each time an attack is made wit this weapon profile, make 2 hit rolls instead of 1.", "Each time an attack is made wit this weapon profile, make 2 hit rolls instead of 1.",
"" ""
) )
.replaceAll(
"Each time an attack is made with this profile, make 2 hit rolls instead of 1."
)
.replaceAll( .replaceAll(
"Make 2 hit rolls for each attack made with this profile, instead of 1", "Make 2 hit rolls for each attack made with this profile, instead of 1",
"" ""
-4
View File
@@ -127,10 +127,6 @@ button:focus-visible {
border-radius: 8px; border-radius: 8px;
} }
.weapons-table {
border-collapse: collapse;
}
.weapons-table th { .weapons-table th {
font-size: 1.1em; font-size: 1.1em;
padding: 2px 6px; padding: 2px 6px;