[Feature] Homebrew Domains (#639)

* Split into tabs

* Finished homebrew settings

* .

* Improved domainremoval cleanup
This commit is contained in:
WBHarry 2025-08-06 13:58:17 +02:00 committed by GitHub
parent d186c62ee5
commit 02958f9574
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
24 changed files with 560 additions and 49 deletions

View file

@ -14,7 +14,7 @@ export default class ClassSheet extends DHBaseItemSheet {
tagifyConfigs: [
{
selector: '.domain-input',
options: () => CONFIG.DH.DOMAIN.domains,
options: () => CONFIG.DH.DOMAIN.orderedDomains(),
callback: ClassSheet.#onDomainSelect,
tagifyOptions: {
maxTags: () => game.settings.get(CONFIG.DH.id, CONFIG.DH.SETTINGS.gameSettings.Homebrew).maxDomains

View file

@ -34,4 +34,12 @@ export default class DomainCardSheet extends DHBaseItemSheet {
scrollable: ['.effects']
}
};
async _prepareContext(options) {
const context = await super._prepareContext(options);
context.domain = CONFIG.DH.DOMAIN.allDomains()[this.document.system.domain];
context.domainChoices = CONFIG.DH.DOMAIN.orderedDomains();
return context;
}
}