From 1312d4f825d9fb5775062e72780adb4b397b2859 Mon Sep 17 00:00:00 2001 From: Jannik Tappert <38758606+CodeTappert@users.noreply.github.com> Date: Thu, 6 Jun 2024 21:01:21 +0200 Subject: [PATCH] [Qol] The title will now be displayed in the voucher overview (and flyout) (#1886) * The title will now be displayed in the voucher overview * Update src/system/voucher.ts * Intend --- src/system/voucher.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/system/voucher.ts b/src/system/voucher.ts index 9381dd650f8..c11410400b5 100644 --- a/src/system/voucher.ts +++ b/src/system/voucher.ts @@ -108,12 +108,13 @@ const voucherAchvs: Achv[] = [ achvs.CLASSIC_VICTORY ]; : VoucherType.PREMIUM; const key = TrainerType[trainerType]; const trainerName = trainerConfigs[trainerType].name; + const trainer = trainerConfigs[trainerType]; + const title = trainer.title ? ` (${trainer.title})` : ""; vouchers[key] = new Voucher( voucherType, - i18next.t("voucher:defeatTrainer", { trainerName }) + `${i18next.t("voucher:defeatTrainer", { trainerName })} ${title}`, ); } - const voucherKeys = Object.keys(vouchers); for (const k of voucherKeys) { vouchers[k].id = k;