adobe/aem-core-email-components

Text Component - Links with ACC markup doesn't get displayed correctly

edoardo-goracci opened this issue · 2 comments

  1. When inserting Links with ACC markup in Text Component, they get rendered correctly in the edit dialog. But if you close and re-open the edit dialog, or refresh the page, the links are no longer displayed in edit mode (they are still displayed in wcmmode=disabled)
  2. Link with ACC markup in first dialog tab doesn't get rendered as link if there are no call-to-action elements

Quote of the original message by priyankpardiwala in #132:

I was testing this feature and now I am able to add a personalization token as "href" in the Link RTE plugin for Text component. 

One issue that I am seeing is that, when I reopen/re-edit the component, it loses the link. Please see the screenshots below. 

The issue is in two places:

  1. the rendered coralui dialog already removed the href attribute due to suspicious, potential xss attributes. This behaviour can be disabled by setting disableXSSFiltering=true on the richtext fields. When set the link is preserved but still encoded when the link plugin dialog is opened a subsequent time.
  2. the link plugin dialog encodes the href when the dialog properties are applied to the markup of the rte. It does not decode them. This seems to be a product issue. @gabrielwalt any idea which team could look into that?