SidebarDirectory

SidebarDirectory

A shared pattern for the sidebar directory which Actors, Items, and Scenes all use

Extends

Members

(static) cls

Source:

A reference to the Entity class which is displayed within this EntityCollection

(static) collection :EntityCollection

Source:

The Entity collection which this Sidebar Directory contains

Type:

(static) defaultOptions

Source:

(static) entity :string

Source:

The named entity which this Sidebar Directory contains

Type:
  • string

_original :SidebarTab

Source:
Overrides:

Denote whether or not this is the original version of the sidebar tab, or a pop-out variant

Type:

entities :Array.<Entity>

Source:

References to the set of Entities which are displayed in the Sidebar

Type:

folders :Array.<Folder>

Source:

Reference the set of Folders which exist in this Sidebar

Type:

tabName :string

Source:
Overrides:

The base name of this sidebar tab

Type:
  • string

Methods

(static) setupFolders(folders, entities) → {Object}

Source:

Given an entity type and a list of entities, set up the folder tree for that entity

Parameters:
Name Type Description
folders Array.<Folder>

The Array of Folder objects to organize

entities Array.<Entity>

The Array of Entity objects to organize

Returns:

A tree structure containing the folders and entities

Type
Object

_onDragHighlight(event)

Source:

Highlight folders as drop targets when a drag event enters or exits their area

Parameters:
Name Type Description
event DragEvent

The DragEvent which is in progress

_onDragStart()

Source:

_onDrop()

Source:

_onLazyLoadImage(entries, observer)

Source:
Overrides:

Handle lazy loading for sidebar images to only load them once they become observed

Parameters:
Name Type Description
entries
observer

_onSearchFilter()

Source:

(async) _render()

Source:
Inherited From:

(async) _renderInner()

Source:
Inherited From:

activate()

Source:
Overrides:

Activate this SidebarTab, switching focus to it

activateListeners()

Source:

Activate event listeners triggered within the Actor Directory HTML

(async) close()

Source:
Inherited From:

collapseAll()

Source:

Collapse all subfolders in this directory

createPopout() → {SidebarTab}

Source:
Overrides:

Create a second instance of this SidebarTab class which represents a singleton popped-out container

Returns:

The popped out sidebar tab instance

Type
SidebarTab

getData()

Source:

initialize()

Source:

Initialize the content of the directory by categorizing folders and entities into a hierarchical tree structure.

render()

Source:

renderPopout()

Source:
Overrides:

Render the SidebarTab as a pop-out container