The configuration object to replace a core sidebar with a Svelte sidebar.

type FVTTSidebarReplaceData = {
    condition?: boolean | (() => boolean);
    icon: string | Embed;
    id: string;
    mergeAppImpl?: object;
    popoutApplication?: SvelteApp;
    popoutOptions?: object;
    popoutPostInitialize?: (app: SvelteApp) => void;
    sidebarClasses?: Iterable<string>;
    svelte: Embed;
    title?: string;
    tooltip?: string;
}
Index

Properties

condition?: boolean | (() => boolean)

A boolean value or function to invoke that returns a boolean value to control sidebar replacement. This is executed in the renderSidebar callback internally.

icon: string | Embed

The FontAwesome icon css classes or a Svelte configuration object to load a custom Svelte component to use as the "icon".

id: string

The ID for the sidebar to replace. This must be an existing sidebar tab ID.

mergeAppImpl?: object

Provides a custom base implementation for the object instance for this sidebar app stored in globalThis.ui.<SIDEBAR ID>.

popoutApplication?: SvelteApp

Provides a custom SvelteApp class to instantiate for the popout sidebar.

popoutOptions?: object

Provides SvelteApp options overrides for the default popout sidebar.

popoutPostInitialize?: (app: SvelteApp) => void

An optional function invoked after the popout app has been created.

sidebarClasses?: Iterable<string>

Additional CSS classes to add to the outer sidebar wrapper.

svelte: Embed

A Svelte configuration object.

title?: string

The popout application title text or i18n lang key.

tooltip?: string

The sidebar tab tooltip text or i18n lang key.