Details
-
Bug
-
Resolution: Unresolved
-
High
-
None
-
2.5.8
-
None
Description
Following the doc] description to override embed template for embed elements using custom class and attributes doesn't work like expected. The warning explains that data attributes and classes are exposed automatically to the target template. data attributes are exposed but class unfortunately not.
Below is a dump from an override embed template:
array:17 [▼ "content" => Content {#58322 ▶} "location" => Location {#58476 ▶} "objectParameters" => array:1 [▶] "data_attributes" => array:2 [▼ "caption" => "true" "fade-duration" => "2" ]
The class is only exposed in : EzPlatformRichTextBundle:RichText/embed:content.html.twig and this template] is adding an additional div outside the template that should be later overridden and including data attributes as well.
To be reviewed in doc:
Instead, you can make use of the data_attributes and class properties in your templates.
Expected behavior:
- custom class and attributes should be only exposed to embed, embed-inline, embed-image templates