Per-document-type registration block within SohlConfig.

interface DocumentConfig {
    compendiums?: string[];
    dataModels: StrictObject<
        Constructor<
            SohlDataModel<any, any, any>
            | TypeDataModel<any, any>,
            any[],
        >,
    >;
    defaultType?: string;
    documentClass: any;
    documentSheets: { cls: any; types: string[] }[];
    macros?: StrictObject<FilePath>;
    typeIcons: StrictObject<string>;
    typeLabels: StrictObject<string>;
    types: string[];
}

Properties

compendiums?: string[]

Compendium pack ids associated with this type.

dataModels: StrictObject<
    Constructor<
        SohlDataModel<any, any, any>
        | TypeDataModel<any, any>,
        any[],
    >,
>

DataModel constructors keyed by subtype.

defaultType?: string

Default subtype for new documents.

documentClass: any

The document subclass Foundry should instantiate.

documentSheets: { cls: any; types: string[] }[]

Sheet classes paired with the subtypes they apply to.

Type declaration

  • cls: any

    Sheet class constructor.

  • types: string[]

    Subtypes this sheet handles.

macros?: StrictObject<FilePath>

Macro file paths keyed by name.

typeIcons: StrictObject<string>

Type icons keyed by subtype.

typeLabels: StrictObject<string>

Localized type labels keyed by subtype.

types: string[]

All registered subtypes.