Parse RTE to get referenced entities

Created on 24 May 2019, about 5 years ago
Updated 26 March 2024, 3 months ago

When pulling content, in RTE fields, parse the RTE to pull the referenced entities.

Compatibility with:

  • Linkit
  • Entity Embed
  • Core Media embed
  • Core Image widget

Needs to:

  • make a JSON:API Extras field enhancer plugin to add additional attributes in the expected HTML tag and remove it when deserializing.
  • make an import processor that will parse and use these HTML attributes to import automatically the embed entities

Warning, on how to handle language.

✨ Feature request
Status

Fixed

Version

3.0

Component

Code

Created by

πŸ‡«πŸ‡·France Grimreaper France πŸ‡«πŸ‡·

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

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • πŸ‡¨πŸ‡¦Canada mahde Vancouver

    I am facing this issue again and getting this error when importing a node that has referenced media files:
    The referenced media source is missing and needs to be re-embedded.

    I am using the latest version of Entity share module 8.x-3.0.

  • πŸ‡ΊπŸ‡ΈUnited States pbabin

    I am experiencing this issue with media (images) embedded in an event content type RTE body in CkEditor 5. We are in Drupal 10.2.4 w/ PHP 8.2 and using the 8.x-3.0 branch of the Entity Share suite of modules. I also have the "Embedded entity' configuration option turned on in my import entity config settings.

    On the client side we end up with - The referenced media source is missing and needs to be re-embedded.

    I have json api extras turned on to disable some items. As a test, I re-enabled all of the items I disabled and attempted the sync of the content type and the issue remains the same.

    There are no errors in the log that appear.

    I added xdebug breaks on the functions doTransform() and doUndoTransform() in the EntityShareEmbeddedEntitiesEnhancer.php; however, when I run the pull on the client these function are not triggered. This is the only place I saw .*data-entity-type="(.*)... being used as referenced in this ticket.

    Is there anything that I might be overlooking what would cause the entity within the RTE instance not to be brought over correctly?

    Thank you in advance.

Production build 0.69.0 2024