Adaptivecards: [iOS][Framework] [Container's backgroundImage renders incorrectly on iOS with Cover fillMode]

Created on 13 Jan 2021  路  2Comments  路  Source: microsoft/AdaptiveCards

Platform

  • [ ] iOS

Version of SDK

Latest from master

Details

See attached screenshots. backgroundImage is not being rendered correctly on iOS using the same JSON as on the web.

Steps to reproduce:

  1. Load the below JSON on both web & iOS.
  2. Look at AlkiBeach.jpg background image on web. Notice that the entire width of the image is shown without cutting off.
  3. Now look at AlkiBeach.jpg background image on iOS. Notice that image width is too wide & gets cut off.

iOS
Web

JSON:

{
    "type": "AdaptiveCard",
    "body": [
        {
            "type": "Container",
            "minHeight": "150px",
            "backgroundImage": "https://adaptivecards.io/content/AlkiBeach.jpg",
            "items": [
                {
                    "type": "TextBlock",
                    "text": "What a beautiful background"
                }
            ]
        },
        {
            "type": "TextBlock",
            "text": "They can even repeat a bunch of different ways..."
        },
        {
            "type": "Container",
            "minHeight": "100px",
            "backgroundImage": {
                "url": "https://adaptivecards.io/content/uparrow.png",
                "fillMode": "Repeat"
            }
        },
        {
            "type": "Container",
            "backgroundImage": {
                "url": "https://adaptivecards.io/content/uparrow.png",
                "fillMode": "RepeatHorizontally",
                "verticalAlignment": "Center"
            }
        },
        {
            "type": "Container",
            "minHeight": "100px",
            "backgroundImage": {
                "url": "https://adaptivecards.io/content/uparrow.png",
                "fillMode": "RepeatVertically",
                "horizontalAlignment": "Center"
            }
        }
    ],
    "$schema": "http://adaptivecards.io/schemas/adaptive-card.json",
    "version": "1.2"
}
AdaptiveCards v21.01 Area-Inconsistency Bug Priority-Now Triage-Approved for Fix

Most helpful comment

@daveymcgav
thanks for reporting the issue, approved for fix.

All 2 comments

please review this issue for target Milestone, Inconsistencies & Priority upon triage.

@daveymcgav
thanks for reporting the issue, approved for fix.

Was this page helpful?
0 / 5 - 0 ratings