Uploaded image for project: 'XWiki Platform'
  1. XWiki Platform
  2. XWIKI-21765

Macros that load custom CSS are not properly synchronized

    XMLWordPrintable

Details

    • Bug
    • Resolution: Solved By
    • Major
    • 16.2.0
    • 15.5.4, 15.10.4
    • Realtime
    • None
    • Integration
    • Unknown
    • N/A
    • N/A

    Description

      Macros are often loading their own CSS styles. Without these styles the macro output looks bad. Take for instance this Velocity macro:

      {{velocity}}
      {{html clean="false"}}
      $xwiki.ssfx.use('uicomponents/pagination/pagination.css', true)
      <div>
        Pagination
        <span class="controlPagination">
          <a title="Previous Page" class="noPrevPagination" href="#"><span class="hidden">Previous Page</span></a>
          <a title="Next Page" class="noNextPagination" href="#"><span class="hidden">Next Page</span></a>
        </span>
      </div>
      {{/html}}
      {{/velocity}}
      

      Without the styles the previous and next page buttons are not properly displayed. The problem is that these styles are loaded from the HTML page head which is currently not synchronized by the realtime WYSIWYG editor. So when one user inserts such a macro the other users will receive the HTML output of the macro but not the CSS styles, so the macro won't be displayed correctly for them.

      Attachments

        Issue Links

          Activity

            People

              mflorea Marius Dumitru Florea
              mflorea Marius Dumitru Florea
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: