Documentation for a historical release of Infusion: 1.4
Please view the Infusion Documentation site for the latest documentation, or the Infusion 1.3. Documentation for the previous release.
If you're looking for Fluid Project coordination, design, communication, etc, try the Fluid Project Wiki.

Preview


The Preview subcomponent is used by Full Page UI Options (with Preview) to ...

Do not use this component directly. The information on this page should be use when customizing Full Page UI Options (with Preview).

See Also
Full Page UI Options (with Preview)
Fat Panel UI Options
Full Page UI Options

#Supported Events

#onReady
Fires when the Preview is ready.

#Methods

#updateModel(that, selections)
Used to update the model of the preview window's UI Enhancer.

#Options

listeners
See #Supported Events for information.

#templateUrl
Path to the template for the preview.

Supported Events

back to top

Listeners can be attached to any supported events through a component's listeners option. Values can be a function reference (not a string function name) or an anonymous function definition, as illustrated below:

var myComponent = component.name("#myContainerID", {
    listeners: {
        eventName1: functionName,
        eventName2: function (params) {
            ...
        }
    }
});

For information on the different types of events, see Infusion Event System.

onReady

Description

This event is fired when the preview template page has loaded.

Type

default

Parameters

none

Availability

Infusion v1.4

Methods

back to top

This component has public methods that can be invoked by integrators as necessary. Some of these methods may be implemented as Invokers, which resolve their arguments from the environment at invocation time. These methods can be configured by the integrator if necessary: arguments can be changed, and in fact the entire implementation function can be replaced by a custom function (though it is likely rare that this would be necessary or desirable).

Configuration of invokers is carried out using Demands Specifications, using the following pattern:

fluid.demands("component.name", [<context>], {
    invokers: {
        <invokerName>: {
            funcName: <implementation function name>,
            args: [<array of argument specifications>]
        }
    }
});

updateModel(that, selections)

Description

Used by the component to filter a list of headings. The default implementation filters the list based on visibility.

Parameters

that
The preview component

selections
The current user settings

Configurable

yes
Default implementation: "fluid.tableOfContents.filterHeadings"
Default arguments:

[
    "{preview}",
    "{uiOptions}.model.selections"
]

Availability

Infusion v1.4

Options

back to top

templateUrl

Description

Path to the HTML file that will be displayed as the preview.

Default

"UIOptionsPreview.html"

Example

templateUrl: "../templates/PreviewTemplate.html"