FEAT: add TypedPseudoDocument

REFACTOR: PreudoDocument
FIX: Typos Bug
This commit is contained in:
Joaquin Pereyra 2025-06-11 01:14:14 -03:00
parent a0b0411a48
commit 88bf26dad0
21 changed files with 559 additions and 447 deletions

View file

@ -0,0 +1,25 @@
import PseudoDocument from '../base/pseudoDocument.mjs';
export default class BaseFeatureData extends PseudoDocument {
/**@inheritdoc */
static get metadata() {
return foundry.utils.mergeObject(
super.metadata,
{
name: 'feature',
label: 'DAGGERHEART.Feature.Label',
embedded: {},
sheetClass: null //TODO: define feature-sheet
},
{ inplace: false }
);
}
static defineSchema() {
const { fields } = foundry.data;
const schema = super.defineSchema();
return Object.assign(schema, {
subtype: new fields.StringField({ initial: 'test' })
});
}
}