Import initial du système
This commit is contained in:
@@ -0,0 +1,23 @@
|
||||
import { CDEBaseItemSheet } from "./base.js"
|
||||
|
||||
export class CDESanheiSheet extends CDEBaseItemSheet {
|
||||
static DEFAULT_OPTIONS = {
|
||||
classes: ["sanhei"],
|
||||
position: { width: 580, height: 620 },
|
||||
}
|
||||
|
||||
static PARTS = {
|
||||
main: { template: "systems/fvtt-chroniques-de-l-etrange/templates/item/cde-sanhei-sheet.html" },
|
||||
}
|
||||
|
||||
async _prepareContext() {
|
||||
const context = await super._prepareContext()
|
||||
const enrich = (content) => foundry.applications.ux.TextEditor.implementation.enrichHTML(content ?? "", { async: true })
|
||||
const props = this.document.system.properties
|
||||
context.prop1DescriptionHTML = await enrich(props.prop1.description)
|
||||
context.prop2DescriptionHTML = await enrich(props.prop2.description)
|
||||
context.prop3DescriptionHTML = await enrich(props.prop3.description)
|
||||
context.propFields = this.document.system.schema.fields.properties.fields
|
||||
return context
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user