Uploaded image for project: 'Confluence Data Center'
  1. Confluence Data Center
  2. CONFSERVER-23007

Export to PDF mangles {jira} macro images

    XMLWordPrintable

Details

    Description

      Exporting to PDF a page containing {jira} macros results in an unreadable rendering:

      Screenshots of macro rendered in Chrome (HTML) and Acrobat (PDF)

      It seems that the PDF renderer misses out on the padding-left and background-repeat style attributes used by the macro.

      The Confluence source text used was

      * {jira:MOPS-531}
      * {jira:MOPS-530}

      Using Chrome's inspect element, I can see that the first macro expanded to this HTML:

      <span class="jira-issue">
        <a style="background-image: url('http://jira/images/icons/bug.gif')"
           href="http://jira/browse/MOPS-531">MOPS-531</a>
         - Incorrect penetration rate data generated by JActionDrill - 
         <span class="jira-status">SCOPED</span>
      </span>
      

      And that the jira-issue class is styled by confluence.extra.jira:common-resources.css:

      .jira-issue > a {
          background-repeat: no-repeat;
          padding-left: 20px;
          padding-bottom: 2px;
          font-weight: bold;
      }

      We need to be able to export these pages to PDF for site engineers without comms access.

      Fix

      Install version 1.14 or newer of the Confluence PDF Export plugin, which can be downloaded at the Atlassian Plugin Exchange.

      Attachments

        Activity

          People

            nbhawnani Niraj Bhawnani
            8440267db961 David Leonard
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: