This project integrates the CKEditor IndentBlock plugin with the CKEditor or CKEditor5 module in Drupal core.

The IndentBlock plugin adds the functionality of indenting text paragraphs using CKEditor. The plugin doesn't come with its own buttons, but uses the same buttons as the built-in Indent plugin which provides the functionality of increasing/decreasing the indentation of list items. The configuration allows to enable/disable the IndentBlock plugin for each text format individually.

Requires modules

CKEditor|CKEditor5 module (core)
Dependency on Libraries module removed from 8.x-1.0-beta2 and up.

Installation (CK5)

All ck5 dependencies are part of Drupal core. No need to download anything extra! Install per normal in the Drupal administration Extend menu.

Installation (only applies to CKEditor, not CK5)

  1. Download the plugin from http://ckeditor.com/addon/indentblock
  2. Unzip the plugin and place it into one of the following libraries paths:
    • Multisite, individual domain:
      <drupal_root>/sites/<domain.tld>/libraries/indentblock/plugin.js
    • Single site or multisite, all domains:
      <drupal_root>/libraries/indentblock/plugin.js
    • CKEditor plugin standard:
      <drupal_root>/libraries/ckeditor/plugins/indentblock/plugin.js
    • Installation profile:
      <drupal_root>/profiles/<profile-name>/libraries/indentblock/plugin.js
    • If the plugin is installed at more than one libraries path, the priority is according to this list.

  3. Enable CKEditor IndentBlock module in the Drupal administration Extend menu.

Adding paragraph indentation to a text format

  1. Go to menu Configuration=>Text formats and editors.
  2. Click on the Configuration button of the text format (i.e. Basic HTML).
  3. If not already in the toolbar, drag the buttons with the title tags indent and outdent into it, which enables the built-in Indent plugin for lists.
  4. Open the vertical tab Indent Block and make sure the plugin is enabled. Should the checkbox be disabled, the IndentBlock plugin has not been found in any of the above listed libraries paths.
  5. Make sure, the tag <p class> is added to the field Allowed HTM tags, otherwise the buttons will not become active for paragraphs despite the IndentBlock plugin being enabled.
Supporting organizations: 
Drupal 10 maintenance and development

Project information

Releases