microsoft / microsoft-ui-xaml

Windows UI Library: the latest Windows 10 native controls and Fluent styles for your applications
MIT License
6.35k stars 678 forks source link

DataTemplate doesn't support its datatype to self-refer. #9395

Open yaoyisen opened 8 months ago

yaoyisen commented 8 months ago

Describe the bug

I tried to show a computing expression like ((1 + 2) + 3) using a ContentControl and DataTemplates. But error occurred when a DataTemplate contained a child using the same template as itself. As comparison, it works well when the adding expression doen't contains an adding expression as its child.

Steps to reproduce the bug

check the sample code

Expected behavior

No response

Screenshots

screenprint

NuGet package version

WinUI 3 - Windows App SDK 1.5.0: 1.5.240227000

Windows version

No response

Additional context

sample.zip

yaoyisen commented 4 months ago

Any information about this issue?