If a filter wraps the drupal-media tag in a paragraph, the edit button breaks

Created on 17 February 2023, almost 2 years ago
Updated 18 April 2024, 7 months ago

Problem/Motivation

There is an open core issue πŸ› If a filter wraps the drupal-media tag in a paragraph, the edit button breaks Needs work for a JS error when embedding media, which prevents the "Edit media" button from appearing in the editor. I'm experiencing this issue when "Limit allowed HTML tags and correct faulty HTML" and "Convert line breaks into HTML" are disabled. Applying the changes from https://www.drupal.org/project/drupal/issues/3097338#comment-13384875 πŸ› If a filter wraps the drupal-media tag in a paragraph, the edit button breaks Needs work fixes the issue for me.

Steps to reproduce

  1. Disable Limit allowed HTML tags, Convert line breaks into HTML for a text format using CKEditor.
  2. Embed media into a textarea using the text format.
  3. Observe the missing edit button, check the console.

Proposed resolution

Re-roll the patch from πŸ› If a filter wraps the drupal-media tag in a paragraph, the edit button breaks Needs work .

Remaining tasks

MR, test, merge :)

User interface changes

N/A

API changes

N/A

Data model changes

N/A

πŸ› Bug report
Status

RTBC

Version

1.0

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States scottsawyer Atlanta

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

Comments & Activities

Production build 0.71.5 2024