Spanish Total.js
English
Documentation For AI agents
Contents

Editor classes reference

The CMS_ classes that make parts of a widget editable, and the image attributes.

.md GitHub
On this page

Add these classes to the elements of <body>. CMS removes them from the public page, except CMS_mv and CMS_mh. See Editable content for examples.

API

class

class="CMS_edit"

Makes the element editable with Edit.

Text is typed in place. An img opens the picture picker, an icon (ti) opens the icon picker and a link can be changed with Change link. It also enables Change attributes.

class

class="CMS_edit CMS_multiline"

Lets Enter add a line break in an edited text.

Without it, Enter ends the editing. Pasted text keeps its lines.

class

class="CMS_attribute"

Enables Change attributes.

Opens the attributes editor for the element.

class

class="CMS_repeat"

Enables Duplicate.

The copy is added after the element and gets CMS_remove.

class

class="CMS_remove"

Enables Remove.

The user can delete the element. Inside it, Remove on a child removes the nearest parent with this class.

class

class="CMS_widgets"

Makes the element an area for other widgets.

Enables Add a widget and pasting a copied widget.

class

class="CMS_edit CMS_unwrap"

Removes the tag of the element on the public page.

The content stays. Use it for a span that exists only to be editable.

class

class="CMS_editor"

Shows the element only in the editor.

CMS removes the element with its content from the public page. CMS_trash does the same.

class

.CMS_preview .CLASS-part { }

Is on the body of the page in the editor.

Use it in CSS to show in the editor what visitors see only after an action.

class

class="CMS_mv CMS_mh"

The vertical and horizontal margins of an instance.

The editor adds them to the wrapper, and the user switches them with Toggle vertical margin and Toggle horizontal margin. The layout defines their size, and they stay on the public page.

property

<img class="CMS_edit" data-cms-width="300" data-cms-height="200" />

The size of an editable image.

The editor shows a grey placeholder of this size and crops the picked picture to it. Leave src empty in the file.

Made in Europe