Block/inline setting not working

Created on 1 January 2025, 3 months ago

Plugins have the option to set the component as block or inline.

This is an option in CKEditor to treat the element as block level, or inline.

With a component that has isInline = false, the component doesn't take up the full width in the editor.

In editing.js, a span is injected with .embedded-content-preview between ckeditor's figure element, and the component code.

embedded_content.css has that class displayed as an inline-block.

It also appears the plugin setting doesn't affect this or any wrapper classes.

This ends up forcing all components to be inline.

Proposal:

Adjust editing.js to use a div for blocks and span for inline, and remove the inline-block style.

Or, fix up the classes to provide a block/inline indicator and adjust the css to work with it.

πŸ› Bug report
Status

Active

Version

2.0

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States mortona2k Seattle

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

  • Issue created by @mortona2k
  • πŸ‡ΊπŸ‡ΈUnited States mortona2k Seattle
  • πŸ‡ͺπŸ‡ΈSpain nuez Madrid, Spain

    I can't reproduce this issue:

    The isInline method doesn't have any impact on the rendered content: It only places it inside inline in ckeditor, e.g. inside a

    tag.

    If you let your plugin render a , but the plugin is not inline, then it will come after the

    (or ), instead of inside.

    Please provide steps to reproduce

Production build 0.71.5 2024