Repository navigation
Update Avalonia to 12.1 - #23
Merged
Merged
Conversation
- Avalonia, Desktop, Themes.Fluent, Fonts.Inter 12.1.4; CommunityToolkit.Mvvm 8.4.2; Microsoft.Extensions.DependencyInjection 10.0.13 - Drag & drop: DragEventArgs.Data / DataFormats.Files -> DataTransfer / DataFormat.File, GetFiles() -> TryGetFiles() - Drop the template code that removed the DataAnnotations validation plugin; BindingPlugins is internal in 12 and the validation is opt-in - Remove the unused Avalonia.Diagnostics reference (it only goes up to 11.3 and nothing called AttachDevTools) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
There was a problem hiding this comment.
🔵 Needs a closer look
Native drag-and-drop behavior remains unverified after the major framework upgrade and needs human validation.
0 open findings
What changed in this PR
Updates the Avalonia application to 12.1.4 and addresses the breaking APIs behind #12’s CI failure.
Changes:
- Updates Avalonia and supporting dependencies; removes unused diagnostics.
- Migrates drag-and-drop handlers to
DataTransfer. - Removes obsolete DataAnnotations validation suppression.
| File | Description |
|---|---|
| dotnet-avalonia/Views/MainWindow.axaml.cs | Uses Avalonia 12 file-drop APIs. |
| dotnet-avalonia/dnd.csproj | Updates dependencies and removes diagnostics. |
| dotnet-avalonia/App.axaml.cs | Removes obsolete validation-plugin access. |
🧠 Review effort: Balanced
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Supersedes #12 (Dependabot), whose CI fails because Avalonia 12 has breaking API changes.
Changes
Avalonia,Avalonia.Desktop,Avalonia.Themes.Fluent,Avalonia.Fonts.Inter11.2.1 → 12.1.4;CommunityToolkit.Mvvm8.2.1 → 8.4.2;Microsoft.Extensions.DependencyInjection9.0.0 → 10.0.13 (same versions as Bump the avalonia group with 7 updates #12)MainWindow.axaml.cs:e.Data.Contains(DataFormats.Files)→e.DataTransfer.Contains(DataFormat.File),e.Data.GetFiles()→e.DataTransfer.TryGetFiles()App.axaml.cs: remove the template'sDisableAvaloniaDataAnnotationValidation().BindingPluginsis internal in 12, and DataAnnotations validation is now opt-in (AppBuilder.WithDataAnnotationsValidation()), so there is nothing to remove.dnd.csproj: removeAvalonia.Diagnostics. Dependabot could only move it to 11.3.22 (no 12.x), and nothing calledAttachDevTools().Verified
dotnet build(0 warnings, 0 errors) with .NET SDK 10dotnet runstarts the appNot verified
🤖 Generated with Claude Code