mirror of
https://github.com/Foundryborne/daggerheart.git
synced 2026-01-12 19:51:08 +01:00
FEAT: add TypedPseudoDocument
REFACTOR: PreudoDocument FIX: Typos Bug
This commit is contained in:
parent
a0b0411a48
commit
88bf26dad0
21 changed files with 559 additions and 447 deletions
25
module/data/pseudo-documents/feature/baseFeatureData.mjs
Normal file
25
module/data/pseudo-documents/feature/baseFeatureData.mjs
Normal 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' })
|
||||
});
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue