From 28989c2d3590f56cedbc2d5cf173c58a87ab0387 Mon Sep 17 00:00:00 2001 From: Eldritch-Oliver Date: Sun, 12 Oct 2025 14:07:39 -0600 Subject: [PATCH] Update fate path preparation to use localized labels --- module/Apps/ActorSheets/BookGeistSheet.mjs | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/module/Apps/ActorSheets/BookGeistSheet.mjs b/module/Apps/ActorSheets/BookGeistSheet.mjs index 1a789e1..a744669 100644 --- a/module/Apps/ActorSheets/BookGeistSheet.mjs +++ b/module/Apps/ActorSheets/BookGeistSheet.mjs @@ -1,6 +1,7 @@ import { filePath } from "../../consts.mjs"; import { GenericAppMixin } from "../mixins/GenericApp.mjs"; import { LaidOutAppMixin } from "../mixins/LaidOutAppMixin.mjs"; +import { localizer } from "../../utils/Localizer.mjs"; const { HandlebarsApplicationMixin } = foundry.applications.api; const { ActorSheetV2 } = foundry.applications.sheets; @@ -77,7 +78,21 @@ export class BookGeistSheet extends LaidOutAppMixin(GenericAppMixin(HandlebarsAp _prepareStatsContext(ctx) { const system = this.actor.system; - ctx.path = system.fate; + + const fate = system.fate; + if (fate) { + ctx.path = { + full: localizer(`RipCrypt.common.ordinals.${fate}.full`), + abbv: localizer(`RipCrypt.common.ordinals.${fate}.abbv`), + }; + } + else { + ctx.path = { + full: null, + abbv: localizer(`RipCrypt.common.empty`), + }; + }; + Object.assign(ctx, system.ability); ctx.guts = system.guts; ctx.speed = system.speed;