From 56978579632fcefebc6fb306c5801bb036c8266d Mon Sep 17 00:00:00 2001 From: Firq Date: Sat, 21 Jan 2023 20:07:51 +0100 Subject: [PATCH] Refactored servant data to hopefully fix astro --- src/components/servantCard.astro | 9 +++++---- static/_servantdata.json | 9 ++++++--- 2 files changed, 11 insertions(+), 7 deletions(-) diff --git a/src/components/servantCard.astro b/src/components/servantCard.astro index 6abcda4..0afcc9d 100644 --- a/src/components/servantCard.astro +++ b/src/components/servantCard.astro @@ -4,15 +4,16 @@ export interface Props { level: string; skills: string; np: string; - asc: string; + image_servant: string; + image_bond: string; ml: string; bond10: string; } -const {bond10, ml, asc, np, skills, level, name } = Astro.props; +const {bond10, ml, image_bond, image_servant, np, skills, level, name } = Astro.props; -const servant_img: string = `servant/${name}_${asc}.png`; -const bondce_img: string = `ce/bond-ce/${name}.png` +const servant_img: string = `servant/${image_servant}.png`; +const bondce_img: string = `ce/bond-ce/${image_bond}.png` let bondce_css: string = "bond-ce"; if(bond10 === "false") { diff --git a/static/_servantdata.json b/static/_servantdata.json index 29230c8..2817c11 100644 --- a/static/_servantdata.json +++ b/static/_servantdata.json @@ -5,7 +5,8 @@ "np": "4", "skills": "10 / 10 / 10 ", "ml": "10", - "asc": "03", + "image_servant": "skadi_03", + "image_bond": "skadi", "bond10": "true" }, { @@ -14,7 +15,8 @@ "np": "1", "skills": "10 / 10 / 10 ", "ml": "1", - "asc": "01", + "image_servant": "skadi_01", + "image_bond": "skadi", "bond10": "true" }, { @@ -23,7 +25,8 @@ "np": "1", "skills": "10 / 10 / 10 ", "ml": "Not Unlocked", - "asc": "01", + "image_servant": "castoria_01", + "image_bond": "castoria", "bond10": "true" } ]