DRAFT; still incomplete

Overview

One of the primary functions of the Infusion Preferences Framework is to allow you to create a Preferences Editor: a collection of adjusters that users can use to set their interface preferences.

The Preferences Framework provides a utility that creates and instantiates a preferences editor in a single step, given primary and auxiliary schemas.

var prefsEditor = fluid.prefs.create(container[, options]);

Parameters

container(required) (String) A CSS-style selector that will contain the preferences editor markup.

options

(optional) (Object) Configuration options. See Options below for more information.

Return Value

Object

(Object) The preferences editor instance.

Options

NameDescriptionValuesDefault
build(Optional) Configuration options for the builder; see Builder Options below for more information.Object

{}

prefsEditor

(Optional) Configuration options for the preferences editor itself. See PrefsEditor Options below for more information.Object{}

Builder Options

PrefsEditor Options

NameDescriptionValuesDefault

prefsEditorType

(Optional) The string name of a grade of preference editor.

The Preferences Framework provides three built-in types of editor:

"fluid.prefs.separatedPanelPrefsEditor"
"fluid.prefs.fullNoPreview"
"fluid.prefs.fullPreview"

Integrators can use one of these grades, or define their own grade, using one of these grades as a base grade.

"fluid.prefs.separatedPanelPrefsEditor"

Usage

The simplest way to create a separated panel preferences editor is to provide the primary and auxiliary schema using the options:

var prefsEditor = fluid.prefs.create({
    build: {
        primarySchema: {...},
        auxiliarySchema: {...}
    }
});

The preferences editor will be instantiated and rendered into the container specified as the first argument to fluid.prefs.create().

Examples