Image attachment links with custom link text render as filenames and trigger downloads instead of redirection in Confluence Cloud

XMLWordPrintable

    • 1
    • Minor

      Issue Summary:
      After migrating from Confluence Data Center to Cloud, attachment links (specifically for non-PDF media types like .png, .jpg) that utilize custom link text via the <ac:plain-text-link-body> element fail to render correctly. Instead of displaying the custom text (e.g., "Figure"), the Cloud renderer "unwraps" the element and displays the raw attachment filename.

      Furthermore, attempting to use standard HTML links as a workaround triggers a secondary issue where clicking the link initiates a file download rather than redirecting/ jumping to the image preview on the page.

      Steps to Reproduce:

      1. Migrate a page from DC to Cloud containing: <ac:link><ri:attachment ri:filename="image.png" /><ac:plain-text-link-body><![CDATA[Figure]]></ac:plain-text-link-body></ac:link>.
      1. View the page in Confluence Cloud.

      Expected Results:
      The link should display as "Figure" and, when clicked, should redirect the user to the image on the page.

      Actual Results:

      1. The link displays as "image.png".
      1. If manually converted to a standard link to restore the "Figure" text, clicking it triggers a browser download instead of an in-page redirection.

      Notes:
      This is related to CONFCLOUD-81794, but that ticket was closed as "Fixed" only for PDF attachments. The issue persists for all other media types.

              Assignee:
              Unassigned
              Reporter:
              Vidyalakshmi M
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated: