fast framework Help

Text

purpose

Enables textual content management for DOM nodes in the template. This enables authorised users to front-end edit texts of a website and manage multilingual contents.

usage

Add data-ffText attribute to any DOM node in the template

<p data-ffText>placeholder text (gets overwritten by managed content)</p> <p data-ffText="sectionIdentifier">placeholder text (gets overwritten by managed content)</p> <p data-ffText='{"section":"sectionIdentifier","editorType": "inline"}'>placeholder text (gets overwritten by managed content)</p>

options

{ "section": null, // (optional) "id" of the text-section. // must be unique across all text-sections // within the storage-node "fallbackText": null, // string to output, if there’s no content set "omitIfEmpty": false, // if `true`, the output of the DOM-element // is suppressed, if there is no content "paragraphWrap": null, // wraps content and each block between // newline in a tag or a set of nested tags // (try 'p' or [ 'li', 'p' ]) "paragraphWrapOmitOuter": null, // if `true` while `paragraphWrap` is also // `true`, content is not wrapped, only // newlines "scope": null, // ff-structure-node in which the text- // section is stored. Default (null) is the // current path // `values: [valid node-trace], "_root"` "show": true, // outputs the content "edit": true, // outputs the edit-widget "editorType": "textarea", // type of editor. Values: "text", "textarea", // "inline" "editorMultilang": true, // if set true (default), editor-input will // apply only to the currently selected // language "editorAllowedHtml": [], // contains a collection of allowed html. // uses the tinyMce-notation (see tinyMce // doc). ['strong', 'i', 'table'], etc. // defaults to global setting. "widgetOptions": { // options for edit widge "title": "", "titleTag": "span", "orientation": "nw", //[...] } }
{ "editor": { "markup": "html", // markup-flavours [values: "txt","html","md"] "type": "textarea", // type of editor. [values: "text", "textarea", "inline"] "multilang": true, // "allowedHtml": [], //[...] }, "widget": { "title": "", "titleTag": "span", "orientation": "nw", // the direction in which widget-body opens when // clicking on the widget-button defined by compass- // notation: sw, se, nw, ne [...] } }
13 Februar 2024