Reproduce:

Create a modal link within the body field of a node on a vanilla 8.0.1 standard profile installation.
<a class="use-ajax" data-dialog-type="modal" href="/node/2">Show me a modal</a>

View the node using Bartik

Expecting:

The node title displayed in the modal title area.

Actual:

The modal title displays encoded markup.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

ratface created an issue. See original summary.

rattusrattus’s picture

Adding screenshot.

rattusrattus’s picture

Patch to strip any markup from content tile before passing to OpenModalDialogCommand.

rattusrattus’s picture

Status: Active » Needs review
rattusrattus’s picture

cilefen’s picture

Version: 8.0.x-dev » 8.1.x-dev

Drupal 8.0.6 was released on April 6 and is the final bugfix release for the Drupal 8.0.x series. Drupal 8.0.x will not receive any further development aside from security fixes. Drupal 8.1.0-rc1 is now available and sites should prepare to update to 8.1.0.

Bug reports should be targeted against the 8.1.x-dev branch from now on, and new development or disruptive changes should be targeted against the 8.2.x-dev branch. For more information see the Drupal 8 minor version schedule and the Allowed changes during the Drupal 8 release cycle.

Version: 8.1.x-dev » 8.2.x-dev

Drupal 8.1.9 was released on September 7 and is the final bugfix release for the Drupal 8.1.x series. Drupal 8.1.x will not receive any further development aside from security fixes. Drupal 8.2.0-rc1 is now available and sites should prepare to upgrade to 8.2.0.

Bug reports should be targeted against the 8.2.x-dev branch from now on, and new development or disruptive changes should be targeted against the 8.3.x-dev branch. For more information see the Drupal 8 minor version schedule and the Allowed changes during the Drupal 8 release cycle.

joelpittet’s picture

This likely needs some tests but I'm not sure. I think the patch is correct, I've seen some other modal related issues that are using PlainTextOutput::renderFromHtml, so I've swapped that out. Do you think that is ok @ratface? Also do you think you'd be up for writing an integration test for this?

joelpittet’s picture

Status: Needs review » Closed (duplicate)