microsoft / microsoft/AdaptiveCards

[Rendering] Newlines for Adaptive Cards don't work in New Teams

Open
#8,921 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Area-Renderers Bug
Dominant language
C#
Stars
2k
Forks
595
Avg merge
1d 19h
Merged PRs (30d)
1

Description

Target Platforms

Other

SDK Version

3.0.0

Application Name

Microsoft Teams

Problem Description

When using the new line functionality for adaptive cards in new Teams, the existing spacing between paragraphs is not being inserted as is the case in classic Teams.

New Teams

image

Classic Teams

image

Screenshots

No response

Card JSON
{
    "type": "AdaptiveCard",
    "version": "1.5",
    "body": [
        {
            "type": "TextBlock",
            "size": "extraLarge",
            "weight": "bolder",
            "text": "Lorem Ipsum",
            "wrap": true
        },
        {
            "type": "TextBlock",
            "text": "Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. \n\nIt has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. \n\nIt was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.",
            "wrap": true
        },
        {
            "type": "TextBlock",
            "size": "small",
            "weight": "lighter",
            "text": "Lorem Ipsum",
            "wrap": true
        }
    ],
    "msteams": {
        "width": "full"
    }
}
Sample Code Language

No response

Sample Code

No response

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the supplied Adaptive Card JSON in new Teams and classic Teams, focusing on the missing spacing between paragraphs. Trace the rendering path responsible for newline handling and verify the result by confirming that the same card preserves paragraph spacing in new Teams without changing its appearance in classic Teams.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp
Domain
frontend
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.