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

Images in page layout containers configured as "Original" cannot fit the container if the container gets small enough

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Low Low
    • None
    • 8.6.2, 9.2.6, 9.2.7, 10.0.2
    • Content - Page
    • None

      Issue Summary

      Wide images in page layout containers sized as "Original" have issues with margins, causing only a small part of the image to be visible.

       

      Confluence versions tested:

      Version isAffected
      8.5.25  not affected
      8.6.2  is affected (likely version where the behavior was introduced)
      Latest bug-fix LTS version 9.2.7  is affected
      10.0.2  is affected

      Steps to Reproduce

      1. Install a compatible Confluence Source Editor on your Confluence.
      2. Create an empty page
      3. Use the "image.png" uploaded to this ticket and upload it to the Confluence page created in the above step.
      4. Update the page content using the storage format here with the help of Confluence Source Editor: storage_format.txt
      5. Go to edit mode and check if "Original" is selected for the image.

      Expected Results

      The image should fit within the layout.

      replication_steps_8.5.25.mp4.mp4

      Actual Results

      The image is cropped on the right side of the layout.

      replication_steps_9.2.7.mp4

      Workaround

      We can force the CSS behavior at the space or site level based on documentation:

      At the space level, whenever this correction is needed, add the code below under Space Tools > Look and Feel > Stylesheet.

      {code:css}
      .wiki-content .confluence-embedded-file-wrapper .confluence-embedded-image {  
      margin-left: 2px;  
      margin-right: 2px;  
      } 
      

       It is also possible to design the same from the Global Confluence configuration   > General Configuration > Stylesheet (under Look and Feel section)
      You can also define the same small code change behavior there, and it will apply to the entire site.

      {code:css}
      .wiki-content .confluence-embedded-file-wrapper .confluence-embedded-image {  
      margin-left: 2px;  
      margin-right: 2px;  
      } 
      

       2px values are sourced from Confluence 8.5 because this behavior does not happen in that version.

        1. image.png
          image.png
          239 kB
        2. replication_steps_8.5.25.mp4.mp4
          10.91 MB
        3. replication_steps_9.2.7.mp4
          13.86 MB
        4. storage_format.txt
          6 kB

              Unassigned Unassigned
              9f7de485df51 Basar Beykoz (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated: