fix bug
All checks were successful
Gitea Auto Deploy / Deploy-Container (push) Successful in 1m45s

This commit is contained in:
2025-08-14 21:41:21 +07:00
parent 12aad00f2d
commit f40a403ea2

View File

@@ -144,16 +144,16 @@ export default function ShowCaseInfo() {
return { return {
img: `https://api.hakush.in/hsr/UI/relicfigures/IconRelic_${value.relic_set_id}_${key}.webp`, img: `https://api.hakush.in/hsr/UI/relicfigures/IconRelic_${value.relic_set_id}_${key}.webp`,
mainAffix: { mainAffix: {
property: mainAffixMap?.[value.main_affix_id]?.property, property: mainAffixMap?.[value?.main_affix_id]?.property,
level: value.level, level: value?.level,
valueAffix: calcMainAffixBonus(mainAffixMap?.[value.main_affix_id], value.level), valueAffix: calcMainAffixBonus(mainAffixMap?.[value?.main_affix_id], value?.level),
detail: mappingStats[mainAffixMap?.[value.main_affix_id].property] detail: mappingStats?.[mainAffixMap?.[value?.main_affix_id]?.property]
}, },
subAffix: value?.sub_affixes.map((subValue) => { subAffix: value?.sub_affixes?.map((subValue) => {
return { return {
property: subAffixMap?.[subValue.sub_affix_id]?.property, property: subAffixMap?.[subValue?.sub_affix_id]?.property,
valueAffix: calcAffixBonus(subAffixMap?.[subValue.sub_affix_id], subValue.step, subValue.count), valueAffix: calcAffixBonus(subAffixMap?.[subValue?.sub_affix_id], subValue?.step, subValue?.count),
detail: mappingStats[subAffixMap?.[subValue.sub_affix_id].property] detail: mappingStats?.[subAffixMap?.[subValue?.sub_affix_id]?.property]
} }
}) })
} }
@@ -899,7 +899,13 @@ export default function ShowCaseInfo() {
return ( return (
<div key={index} className="flex flex-col"> <div key={index} className="flex flex-col">
<div className="flex flex-row items-center"> <div className="flex flex-row items-center">
{subAffix?.detail?.icon ? (
<NextImage src={subAffix?.detail?.icon || ""} width={36} height={36} alt="Sub Affix Icon" className="h-auto w-9" /> <NextImage src={subAffix?.detail?.icon || ""} width={36} height={36} alt="Sub Affix Icon" className="h-auto w-9" />
) : (
<div className="h-9 w-9 bg-black/50 rounded flex items-center justify-center">
<span className="text-xs text-white">?</span>
</div>
)}
<span className="text-sm">+{subAffix?.valueAffix + subAffix?.detail?.unit}</span> <span className="text-sm">+{subAffix?.valueAffix + subAffix?.detail?.unit}</span>
</div> </div>
</div> </div>