Aloha Editor

Aloha Editor Guides

These guides help you to make your content editable and to develop Aloha Editor.

Meta View Plugin

The Meta View Plugin is used to visualize HTML elements for the editor.

1 Overview

The following elements will be highlighted:

  • p
  • h1 – h6
  • pre
  • blockquote
  • ol / ul
  • div
  • dl / dt / dd
  • table / td / th
  • caption
  • abbr
  • dfn
  • q
  • a and elements with a lang attribute

2 Usage

Click the “Switch between meta and normal view” button to show block level elements.

Elements are indicated with icons added via CSS.

3 Components

  • A button in the floating menu to toggle between meta and normal view.

4 Configuration


Aloha.settings.plugins: {
	metaview: {
		config: [ 'metaview' ],
		editables: {
			'#one': [ 'metaview', 'enabled' ],
			'#two': [ ],
			'#three': [ 'metaview' ],
			'#four': [ 'enabled' ]
		}
	}
};

To enable the metaview button for an editable, put the ‘metaview’-String in the editable configuration array. To enable the metaview view by default for an editable, place the ‘enabled’-String in the editable configuration array.