首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >在iOS移动应用程序上,在MS团队中,“中心”或“右”的自适应卡水平对齐属性不起作用

在iOS移动应用程序上,在MS团队中,“中心”或“右”的自适应卡水平对齐属性不起作用
EN

Stack Overflow用户
提问于 2020-03-15 13:39:11
回答 1查看 1.4K关注 0票数 1

我们在以下自适应元素中存在“水平对齐”属性的问题: AdaptiveColumn、AdaptiveTextBlock和AdaptiveImage。将此属性设置为“中心”或“右”将导致重大设计问题(请参阅所附图像)。

原件:

“右”对齐:

下面是JSON:

代码语言:javascript
复制
{
  "type": "AdaptiveCard",
  "version": "1.2",
  "body": [
    {
      "type": "Container",
      "items": [
        {
          "type": "ColumnSet",
          "columns": [
            {
              "type": "Column",
              "width": 15,
              "items": []
            },
            {
              "type": "Column",
              "width": 15,
              "items": [
                {
                  "type": "Image",
                  "url": "https://cdn4.iconfinder.com/data/icons/arrows-9/100/arrow-9-512.png",
                  "width": "30px",
                  "height": "24px"
                }
              ],
              "verticalContentAlignment": "Center",
              "selectAction": {
                "type": "Action.Submit",
                "title": "Previous"
              },
              "horizontalAlignment": "Left"
            },
            {
              "type": "Column",
              "width": 40,
              "items": [
                {
                  "type": "Image",
                  "size": "Large",
                  "url": "https://aboutflowers.com/wp-content/uploads/2016/10/AboutFlowers_S600Alstroemera_SymphonyMorita_Esmeralda.jpg",
                  "horizontalAlignment": "Center"
                }
              ]
            },
            {
              "type": "Column",
              "width": 15,
              "items": [
                {
                  "type": "Image",
                  "url": "https://cdn4.iconfinder.com/data/icons/arrows-9/100/arrow-10-512.png",
                  "width": "30px",
                  "horizontalAlignment": "Right",
                  "height": "24px"
                }
              ],
              "verticalContentAlignment": "Center",
              "selectAction": {
                "type": "Action.Submit",
                "title": "Next"
              }
            },
            {
              "type": "Column",
              "width": 15,
              "items": []
            }
          ]
        }
      ]
    },
    {
      "type": "TextBlock",
      "text": "Image1",
      "horizontalAlignment": "Center"
    }
  ],
  "$schema": "http://adaptivecards.io/schemas/adaptive-card.json"
}

同样的设计也适用于Android和桌面客户端。

EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2020-03-16 18:44:15

堆栈溢出不适用于错误报告。您可以通过团队应用程序本身提交反馈,也可以查看以下反馈页面:https://learn.microsoft.com/en-us/microsoftteams/platform/feedback

如果您确实提交了反馈,请随时链接到此堆栈溢出帖子,以便提供必要的信息。

在修复bug之前,您需要找到某种解决办法。也许您可以尝试“中间”对齐,而不是左和右。如果这样做不起作用,那么您可能不得不不使用任何对齐方式。您可能有兴趣知道,模式在使用height属性时提到了图像失真的可能性,因此您也可以尝试省略宽度和高度规范:https://adaptivecards.io/explorer/Image.html

票数 1
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/60693507

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档