microsoft / microsoft/AdaptiveCards
[Designer] Setting attributes to (not set) does not actually remove the property
Nobody has claimed this yet.
- Dominant language
- C#
- Stars
- 2k
- Forks
- 595
- Avg merge
- 1d 19h
- Merged PRs (30d)
- 1
Description
Problem Description
When using the designer to set an attribute, for example fontType to “Monospace”, the corresponding JSON property is added:
However, when later changing the attribute back to “(not set)”, I expect the JSON property to be removed. However, it is kept as-is.
Card JSON
{
"type": "AdaptiveCard",
"body": [
{
"type": "TextBlock",
"text": "${title}",
"fontType": "Monospace"
}
],
"$schema": "http://adaptivecards.io/schemas/adaptive-card.json",
"version": "1.6"
}
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the issue in the Designer by setting a TextBlock's fontType to Monospace and then back to “(not set)”. Trace how the Designer updates and serializes the Card JSON, then verify that resetting the attribute removes the fontType property and that the behavior is covered by an appropriate regression test.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- csharp
- Domain
- tooling
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100