Skip to content

Windows (WinAppSDK) head fails with WMC0001 on LottieVisualSource: Uno.Sdk 7.0 ignores the Lottie feature and adds no Lottie package there #25449

Closed

Description

@MartinZikmund

What would you like to be added? 💡

Make the Windows (WinAppSDK) head of a single-project app build when its XAML uses LottieVisualSource, without the app having to discover that CommunityToolkit.WinUI.Lottie is needed there.

Since the Lottie Uno Feature was removed in 7.0 (cc5a349), Uno.Sdk ignores Lottie in UnoFeatures (Uno.Features.targets#L14-L16) and nothing adds a Lottie package on the Windows TFM. The same XAML builds on the Uno heads and fails on the Windows head with an error that doesn't mention the missing package.

Options (any of these would do):

  1. Add CommunityToolkit.WinUI.Lottie (with a manifest version) to the WinAppSDK head when Lottie is listed in UnoFeatures, i.e. keep the token meaningful on that one head.
  2. Emit a build warning/error on the WinAppSDK head when Lottie is listed but the package isn't referenced.
  3. At minimum, call it out in the 7.0 release guidance and in the AnimatedVisualPlayer / Lottie docs next to "no package is needed".

Why is this needed? 🤔

Guidance for 7.0 says Lottie needs no package ("AnimatedVisualPlayer, LottieVisualSource and ThemableLottieVisualSource are part of Uno.WinUI... so no package is needed on Uno Platform targets"). The doc does mention a Windows exception further down, but a default unoapp multi-head project has a Windows TFM, so following the "no package" message gives an app that works on desktop/WASM/mobile and breaks the Windows head with:

MainPage.xaml(12,73): XamlCompiler error WMC0001: Unknown type 'LottieVisualSource' in XML namespace 'using:CommunityToolkit.WinUI.Lottie'

This is not a regression from 6.x: 6.7 also did not add CommunityToolkit.WinUI.Lottie on the WinAppSDK head (the Lottie feature only added SkiaSharp.Views.WinUI there). It is a gap that the 7.0 change made more visible, because the feature that used to be the place to hook this is now gone.

How to reproduce

Confirmed by a real build with Uno.Sdk 7.0.0-dev.75 (latest public dev build when tested), .NET SDK 10.0.401.

  1. global.json: { "msbuild-sdks": { "Uno.Sdk": "7.0.0-dev.75" } }
  2. .csproj (single project):
    <Project Sdk="Uno.Sdk">
      <PropertyGroup>
        <TargetFrameworks>net10.0-desktop;net10.0-windows10.0.26100</TargetFrameworks>
        <OutputType>Exe</OutputType>
        <UnoSingleProject>true</UnoSingleProject>
        <UnoFeatures>SkiaRenderer;Lottie;</UnoFeatures>
      </PropertyGroup>
    </Project>
  3. MainPage.xaml:
    <Page ... xmlns:lottie="using:CommunityToolkit.WinUI.Lottie">
      <AnimatedVisualPlayer Width="100" Height="100" AutoPlay="True">
        <lottie:LottieVisualSource UriSource="ms-appx:///Assets/a.json" />
      </AnimatedVisualPlayer>
    </Page>
  4. dotnet build -f net10.0-desktop succeeds (and the app starts).
  5. dotnet build -f net10.0-windows10.0.26100 -c Release fails with WMC0001 above. (A Debug build of the Windows head currently fails earlier with a different, already reported error: Debug build of the WinAppSDK head fails with MSB4057: target "_UnoAddLibraryAssets" does not exist (Uno.UI.HotDesign.props) #24983.)

Workaround

<ItemGroup>
  <PackageReference Include="CommunityToolkit.WinUI.Lottie" Condition="$(TargetFramework.Contains('windows'))" />
</ItemGroup>

plus <PackageVersion Include="CommunityToolkit.WinUI.Lottie" Version="8.2.250604" /> in Directory.Packages.props. With that, dotnet build -f net10.0-windows10.0.26100 -c Release succeeds (verified). Or drop the Windows TFM.

Works on UWP/WinUI

On Windows App SDK the type comes from CommunityToolkit.WinUI.Lottie, which has to be referenced explicitly.

Environment

Uno.Sdk 7.0.0-dev.75, .NET SDK 10.0.401, net10.0-windows10.0.26100. Code references are at master 4393a80.

Anything else we need to know? 💬

  • project.assets.json of the Windows TFM contains no Lottie package.
  • Docs on master already say "On Windows (WinAppSDK), reference the CommunityToolkit.WinUI.Lottie NuGet package" (Lottie.md), so the behavior is documented; the issue is discoverability from the single-project experience.
  • The change would be small for option 1 or 2: Uno.Implicit.Packages.ProjectSystem.WinAppSdk.targets plus the Sdk package manifest; but it needs a decision on whether the removed feature token should mean something on the Windows head.

Activity

  1. added
    kind/enhancement
    triage/untriaged
    project/animations 🎡
    difficulty/medium 🤔
    area/sdk
    7.0
    on Oct 14, 2026
  2. removed
    triage/untriaged
    7.0
    on Oct 29, 2026
  3. self-assigned this
    on Nov 3, 2026
  4. added 2 commits that reference this issue on Nov 4, 2026
    389e612
    5210ad3
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

area/sdkdifficulty/medium 🤔kind/enhancementproject/animations 🎡

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions