Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Rendering] Adaptive card with svg background looks great on web; bad in the new winui3 widget board #9094

Open
davesmits opened this issue Jan 23, 2025 · 0 comments

Comments

@davesmits
Copy link

Target Platforms

Other

SDK Version

Windows Widget Board; no idea

Application Name

MyCollegueas

Problem Description

SVG background looks great in the web renderer while in the winui3 it's nog looking so good. I noticed this difference while building widgets for windows 11. See screenshot and card json below

Screenshots

In the designer; this is also how it looked in the old web based widget board
Image

In the new winui3 widget board

Image

as you see the background is no longer filling the entire card

Card JSON

Card json
`
{
  "type": "AdaptiveCard",
  "$schema": "http://adaptivecards.io/schemas/adaptive-card.json",
  "version": "1.6",
  "body": [

  ],
  "backgroundImage": {
    "url": "${if(equals($host.hostTheme,'light'), $root.LightBackground, $root.DarkBackground)}"
  }
}
`

Data json
`
{
  "LightBackground": "data:image/svg+xml;base64,PHN2ZyB4bWxucz0naHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmcnIHdpZHRoPScxMDAlJyBoZWlnaHQ9JzEwMCUnIHZpZXdCb3g9JzAgMCAyIDEnPjxyZWN0IGZpbGw9JyNFQUY0RkYnIHdpZHRoPScyJyBoZWlnaHQ9JzEnLz48ZGVmcz48bGluZWFyR3JhZGllbnQgaWQ9J2EnIGdyYWRpZW50VW5pdHM9J3VzZXJTcGFjZU9uVXNlJyB4MT0nMCcgeDI9JzAnIHkxPScwJyB5Mj0nMSc+PHN0b3Agb2Zmc2V0PScwJyAgc3RvcC1jb2xvcj0nI0VBRjRGRicvPjxzdG9wIG9mZnNldD0nMScgIHN0b3AtY29sb3I9JyNCMEQ4RkYnLz48L2xpbmVhckdyYWRpZW50PjxsaW5lYXJHcmFkaWVudCBpZD0nYicgZ3JhZGllbnRVbml0cz0ndXNlclNwYWNlT25Vc2UnIHgxPScwJyB5MT0nMCcge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0PScwJyAgc3RvcC1jb2xvcj0nIzAzMDY2QScvPjxzdG9wIG9mZnNldD0nMScgIHN0b3AtY29sb3I9JyMwNzAxMzMnLz48L2xpbmVhckdyYWRpZW50PjxsaW5lYXJHcmFkaWVudCBpZD0nYicgZ3JhZGllbnRVbml0cz0ndXNlclNwYWNlT25Vc2UnIHgxPScwJyB5MT0nMCcgeDI9JzAnIHkyPScxJz48c3RvcCBvZmZzZXQ9JzAnICBzdG9wLWNvbG9yPScjMDAwMjI1JyBzdG9wLW9wYWNpdHk9JzAnLz48c3RvcCBvZmZzZXQ9JzEnICBzdG9wLWNvbG9yPScjMDAwMjI1JyBzdG9wLW9wYWNpdHk9JzEnLz48L2xpbmVhckdyYWRpZW50PjxsaW5lYXJHcmFkaWVudCBpZD0nYycgZ3JhZGllbnRVbml0cz0ndXNlclNwYWNlT25Vc2UnIHgxPScwJyB5MT0nMCcgeDI9JzInIHkyPScyJz48c3RvcCAgb2Zmc2V0PScwJyBzdG9wLWNvbG9yPScjMDAwMjI1JyBzdG9wLW9wYWNpdHk9JzAnLz48c3RvcCAgb2Zmc2V0PScxJyBzdG9wLWNvbG9yPScjMDAwMjI1JyBzdG9wLW9wYWNpdHk9JzEnLz48L2xpbmVhckdyYWRpZW50PjwvZGVmcz48cmVjdCB4PScwJyB5PScwJyBmaWxsPSd1cmwoI2EpJyB3aWR0aD0nMicgaGVpZ2h0PScxJy8+PGcgZmlsbC1vcGFjaXR5PScwLjUnPjxwb2x5Z29uIGZpbGw9J3VybCgjYiknIHBvaW50cz0nMCAxIDAgMCAyIDAnLz48cG9seWdvbiBmaWxsPSd1cmwoI2MpJyBwb2ludHM9JzIgMSAyIDAgMCAwJy8+PC9nPjwvc3ZnPg==",
}
`

Sample Code Language

No response

Sample Code

No response

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant