Uploaded image for project: 'XWiki Rendering'
  1. XWiki Rendering
  2. XRENDERING-702

The content macro breaks WYSIWYG editing

    XMLWordPrintable

Details

    • Unit
    • Unknown
    • N/A
    • N/A

    Description

      Steps to reproduce:

      1. Open any document in the WYSIWYG editor.
      2. Insert a content macro using the dialog. Set content to <p>Hello World!</p> and syntax to html/5.0.
      3. Switch to source.

      Expected result:

      Wiki syntax containing the content macro.

      Actual result:

      The content

      <!DOCTYPE html>
      <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"><body><!--startmacro:content|-|syntax="html/5.0"|-|<p>Hello World.</p>--><div data-xwiki-syntax="HTML 5.0" data-xwiki-non-generated-content="java.util.List&lt;org.xwiki.rendering.block.Block&gt;" class="xwiki-metadata-container"><p>Hello World.</p></div><!--stopmacro--><p>&nbsp;</p></body></html>

      is displayed.

      This is a regression introduced in XRENDERING-685 because while the metadata is correct now, the correct metadata is incorrectly serialized into HTML as it can also be seen in the snippet above (the attribute data-xwiki-syntax="HTML 5.0" should have html/5.0 as value.

      Attachments

        Issue Links

          Activity

            People

              MichaelHamann Michael Hamann
              MichaelHamann Michael Hamann
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: