Add the Layouts plugin to the editor and configure it
Press the button to add a layout
Choose one of the available layouts
The HTML for the layout will be injected into the editor

This module allows the use of layouts defined via the core Layout API within WYSIWYG content by supplying a Layouts plugin for CKEditor.

Installation

  1. Install the module as any other contributed module for Drupal (https://www.drupal.org/docs/extending-drupal/installing-modules) .
  2. Add the Layouts plugin to the editor configuration of any text format (i.e. /admin/config/content/formats/manage/full_html) by dragging the button on the toolbar.
  3. Optionally limit the allowed layouts on the Layouts plugin settings tab in the editor configuration.

Using default layouts

The Layout Discovery module in Drupal core will provide some default layouts.

Defining your own layouts

Custom layouts can be added via the core Layout API (https://www.drupal.org/docs/drupal-apis/layout-api/how-to-register-layouts).

Versions

2.x

As of version 2.0.0 CKeditor Layouts supports CKEditor 5. The 2.x versions support CKEditor 5 only. It is the recommended version to use with Drupal 10.

1.x

As of version 1.1.0 this module is Drupal 10 compatible. But the 1.x versions do not include a plugin for CKeditor 5. Using a 1.x version only makes sense together with the CKeditor 4 contrib module (https://www.drupal.org/project/ckeditor).

Credits

This module is loosely based on the work of Kgaut (https://www.drupal.org/u/kgaut) in https://www.drupal.org/project/ckeditor_responsive_plugin.

Supporting organizations: 
Sponsored development time

Project information

Releases