-
Notifications
You must be signed in to change notification settings - Fork 839
fix: Allow static x:Bind in DataTemplate without x:DataType #22324
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
base: master
Are you sure you want to change the base?
Conversation
Co-authored-by: MartinZikmund <1075116+MartinZikmund@users.noreply.github.com>
|
|
Co-authored-by: MartinZikmund <1075116+MartinZikmund@users.noreply.github.com>
Co-authored-by: MartinZikmund <1075116+MartinZikmund@users.noreply.github.com>
|
🤖 Your Docs stage site is ready! Visit it here: https://unodocsprstaging.z13.web.core.windows.net/pr-22324/docs/index.html |
|
@copilot Uno.UI.SourceGenerators.XamlGenerator.XamlCodeGenerator/BindingExpression_With_Converter_07e5b85741c18e42ed743478c0cd3c9b.cs(723,180): error CS0103: The name '___tctx' does not exist in the current context [/agent/_work/1/s/src/Uno.UI.RuntimeTests/Uno.UI.RuntimeTests.Skia.csproj::TargetFramework=net10.0] |
Co-authored-by: MartinZikmund <1075116+MartinZikmund@users.noreply.github.com>
Fixed in commit 545ed8f. The issue was that empty path bindings (e.g., |
|
🤖 Your Docs stage site is ready! Visit it here: https://unodocsprstaging.z13.web.core.windows.net/pr-22324/docs/index.html |
|
🤖 Your WebAssembly Skia Sample App stage site is ready! Visit it here: https://unowasmprstaging.z20.web.core.windows.net/pr-22324/wasm-skia-net9/index.html |
Summary
Fixed an issue where static x:Bind expressions in DataTemplates failed to compile without an x:DataType specified.
Changes Made
Technical Details
Property Bindings
{x:Bind}) bind to DataContext itself, not static membersEvent Bindings
Build Fix
The build error
The name '___tctx' does not exist in the current contextwas caused by:{x:Bind}with just a Converter) were incorrectly classified as "fully static"Compatibility
✅ Fully backward compatible
✅ Aligns with WinAppSDK behavior
✅ No breaking changes
✅ Existing bindings unaffected
Original prompt
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.