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

Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 9 Next »

This documentation refers to the latest trunk version of the Inline Edit code.

Inline Edit Overview

Allow users to edit content within the context of their work rather than going to an "edit mode".


Constructor

fluid.InlineEdit(componentContainerId, options);

Parameters

componentContainerId

The componentContainerId parameter is the ID of the root DOM node of the Inline Edit markup.

On This Page
See Also
Still need help?

Join the fluid-talk mailing list and ask your questions there.

options

The options parameter is an optional collection of name-value pairs that configure the Inline Edit component:

Name

Description

Values

Default

selectors

Javascript object containing selectors for various fragments of the Inline Edit component.

The object can contain any subset of the following keys:
  text
  editContainer
  edit
Any values not provided will revert to the default.

selectors: {
    text: ".text",
    editContainer: ".editContainer",
    edit: ".edit"
}

styles

Javascript object containing CSS style names that will be applied to the Inline Edit component.

The object can contain any subset of the following keys:
  invitation
  focus
Any values not provided will revert to the default.

styles: {
    invitation: "invitation",
    focus: "focus"
}

paddings

Javascript object containing pixed values that will configure the size of the edit field.

The object can contain any subset of the following keys:
  add
  minimum
Any values not provided will revert to the default.

paddings: {
    add: 10,
    minimum: 80
}

finishedEditing

A function that will be called each time the Inline Edit component leaves edit mode. This function can be used to communicate changes in the field to the server, or to take any other action desired by the implementor.

a function

finishedEditing: function () {
}

Functions

fluid.InlineEdit.edit();

Switches the component into edit mode.

fluid.InlineEdit.finish();

Switches the component out of edit mode into display mode, updating the displayed text with the current content of the edit field.

  • No labels