Import initial du système

This commit is contained in:
2026-03-28 08:44:19 +01:00
parent 068fca00e5
commit f7a01900ac
105 changed files with 7362 additions and 2090 deletions

View File

@@ -9,7 +9,11 @@ export class CDEBaseItemSheet extends HandlebarsApplicationMixin(foundry.applica
actions: {},
}
tabGroups = { primary: "description" }
tabGroups = { primary: "details" }
get title() {
return this.document.name
}
async _prepareContext() {
const cssClass = this.options.classes?.join(" ") ?? ""
@@ -19,6 +23,7 @@ export class CDEBaseItemSheet extends HandlebarsApplicationMixin(foundry.applica
item: this.document,
system: this.document.system,
systemData: this.document.system,
systemFields: this.document.system.schema.fields,
editable: this.isEditable,
cssClass,
enrichedDescription,
@@ -28,14 +33,9 @@ export class CDEBaseItemSheet extends HandlebarsApplicationMixin(foundry.applica
}
}
async _onFirstRender(context, options) {
await super._onFirstRender(context, options)
for (const [group, tab] of Object.entries(this.tabGroups)) {
this.changeTab(tab, group, { force: true })
}
}
// Restore the active tab after every render (including re-renders from submitOnChange).
_onRender(context, options) {
super._onRender?.(context, options)
for (const [group, tab] of Object.entries(this.tabGroups)) {
this.changeTab(tab, group, { force: true })
}