Migrate to FoundryVTT v13 AppV2 +
│ DataModels │ │ - Reorganize DataModels into src/module/models/ (one .mjs per type) │ - Create AppV2 actor/item sheets (HandlebarsApplicationMixin)…
This commit is contained in:
@@ -38,7 +38,7 @@ export default class MGT2ActorSheet extends HandlebarsApplicationMixin(foundry.a
|
||||
return this._sheetMode === this.constructor.SHEET_MODES.EDIT;
|
||||
}
|
||||
|
||||
tabGroups = { primary: "stats" }
|
||||
tabGroups = { sidebar: "health" }
|
||||
|
||||
/** @override */
|
||||
async _prepareContext() {
|
||||
@@ -66,6 +66,9 @@ export default class MGT2ActorSheet extends HandlebarsApplicationMixin(foundry.a
|
||||
/** @override */
|
||||
_onRender(context, options) {
|
||||
super._onRender(context, options);
|
||||
// Inject theme class dynamically (can't use game.settings in static DEFAULT_OPTIONS)
|
||||
const theme = game.settings.get("mgt2", "theme");
|
||||
if (theme) this.element.classList.add(theme);
|
||||
this._activateTabGroups();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user