settingsDialogRenderer

(require("settingsDialogRenderer"))() → {function} #

Creates a render function that will create the settings dialog and return a set of methods to operate on it

Source:

Returns:

render function

Type
function

Methods

toggleHelp(dialog, visible)static #

Toggles the visibility between a form and the help

Parameters:

Name Type Description
dialog HTMLElement

element that contains form and help

visible boolean

if the help should be visible, or the form

Source:

appendTo(el)inner #

Append the dialog and overlay to a DOM element

Parameters:

Name Type Description
el HTMLElement
Source:

hide()inner #

Hide the settings dialog.

Source:

hideAll(nodes)inner #

Parameters:

Name Type Description
nodes NodeList
Source:

refresh(previewTypesEnabledNew)inner #

Re-initialize the dialog when the available settings have changed.

Parameters:

Name Type Description
previewTypesEnabledNew Object

updated key value pairs

Source:

setEnabled(enabled)inner #

Update the form depending on the enabled flag

Parameters:

Name Type Description
enabled Object

Mapping preview type identifiers to boolean flags

Source:

show()inner #

Show the settings element and position it correctly

Source:

showAll(nodes)inner #

Parameters:

Name Type Description
nodes NodeList
Source:

toggleHelp(visible)inner #

Toggle the help dialog on or off

Parameters:

Name Type Description
visible boolean

if you want to show or hide the help dialog

Source: