Corrections CSS sur fiche archetype et système
All checks were successful
Release Creation / build (release) Successful in 50s

This commit is contained in:
2026-04-21 13:43:29 +02:00
parent 5cc060b102
commit 956ed9e916
41 changed files with 167 additions and 206 deletions

View File

@@ -29,7 +29,8 @@ export default class MaleficesArchetypeSheet extends MaleficesItemSheet {
async _prepareContext() {
const context = await super._prepareContext()
context.tabs = this.#getTabs()
context.tarots = MaleficesUtility.getTarots()
const tarots = MaleficesUtility.getTarots() ?? []
context.tarots = Object.fromEntries(tarots.map(t => [t._id, t.name]))
return context
}
}

View File

@@ -73,7 +73,7 @@ export class MaleficesUtility {
/*-------------------------------------------- */
static getTarots() {
return foundry.utils.duplicate(this.tarots)
return foundry.utils.duplicate(this.tarots ?? [])
}
static getTarot(tId) {
return this.tarots.find(t => t._id == tId)