From fe74aacc0cfc7c014948c42d286674ef9af73b79 Mon Sep 17 00:00:00 2001 From: Airat Abdrakov <52558686+CrackAndDie@users.noreply.github.com> Date: Mon, 12 Feb 2024 18:11:38 +0300 Subject: [PATCH 01/10] Removed the Avalonia.ReactiveUI dependency Removed the dependency and replaced some stuff with internal code --- build/AvaloniaDependency.props | 1 - build/SampleApp.props | 1 + .../Common/AnonymousObserver.cs | 67 +++++++++++++++++++ src/Prism.Avalonia/Common/ObservableObject.cs | 4 +- src/Prism.Avalonia/Common/Stubs.cs | 10 +++ .../Extensions/ObservableExtensions.cs | 34 ++++++++++ src/Prism.Avalonia/Mvvm/ViewModelLocator.cs | 4 +- src/Prism.Avalonia/Regions/ItemMetadata.cs | 3 +- src/Prism.Avalonia/Regions/RegionContext.cs | 3 +- src/Prism.Avalonia/Regions/RegionManager.cs | 3 +- src/Prism.Avalonia/Services/Dialogs/Dialog.cs | 4 +- 11 files changed, 123 insertions(+), 11 deletions(-) create mode 100644 src/Prism.Avalonia/Common/AnonymousObserver.cs create mode 100644 src/Prism.Avalonia/Common/Stubs.cs create mode 100644 src/Prism.Avalonia/Extensions/ObservableExtensions.cs diff --git a/build/AvaloniaDependency.props b/build/AvaloniaDependency.props index fd5be6a..f6e537b 100644 --- a/build/AvaloniaDependency.props +++ b/build/AvaloniaDependency.props @@ -4,7 +4,6 @@ - diff --git a/build/SampleApp.props b/build/SampleApp.props index f06c124..3e4c06d 100644 --- a/build/SampleApp.props +++ b/build/SampleApp.props @@ -12,6 +12,7 @@ + diff --git a/src/Prism.Avalonia/Common/AnonymousObserver.cs b/src/Prism.Avalonia/Common/AnonymousObserver.cs new file mode 100644 index 0000000..c541590 --- /dev/null +++ b/src/Prism.Avalonia/Common/AnonymousObserver.cs @@ -0,0 +1,67 @@ +using System; +using System.Threading.Tasks; + +namespace Prism.Common +{ + /// + /// Class to create an instance from delegate-based implementations of the On* methods. + /// + /// The type of the elements in the sequence. + public class AnonymousObserver : IObserver + { + private static readonly Action ThrowsOnError = ex => throw ex; + private static readonly Action NoOpCompleted = () => { }; + private readonly Action _onNext; + private readonly Action _onError; + private readonly Action _onCompleted; + + public AnonymousObserver(TaskCompletionSource tcs) + { + if (tcs is null) + { + throw new ArgumentNullException(nameof(tcs)); + } + + _onNext = tcs.SetResult; + _onError = tcs.SetException; + _onCompleted = NoOpCompleted; + } + + public AnonymousObserver(Action onNext, Action onError, Action onCompleted) + { + _onNext = onNext ?? throw new ArgumentNullException(nameof(onNext)); + _onError = onError ?? throw new ArgumentNullException(nameof(onError)); + _onCompleted = onCompleted ?? throw new ArgumentNullException(nameof(onCompleted)); + } + + public AnonymousObserver(Action onNext) + : this(onNext, ThrowsOnError, NoOpCompleted) + { + } + + public AnonymousObserver(Action onNext, Action onError) + : this(onNext, onError, NoOpCompleted) + { + } + + public AnonymousObserver(Action onNext, Action onCompleted) + : this(onNext, ThrowsOnError, onCompleted) + { + } + + public void OnCompleted() + { + _onCompleted.Invoke(); + } + + public void OnError(Exception error) + { + _onError.Invoke(error); + } + + public void OnNext(T value) + { + _onNext.Invoke(value); + } + } +} diff --git a/src/Prism.Avalonia/Common/ObservableObject.cs b/src/Prism.Avalonia/Common/ObservableObject.cs index cde4a6d..9a7358a 100644 --- a/src/Prism.Avalonia/Common/ObservableObject.cs +++ b/src/Prism.Avalonia/Common/ObservableObject.cs @@ -1,5 +1,5 @@ -using System; -using System.ComponentModel; +using System.ComponentModel; +using Prism.Extensions; using Avalonia; using Avalonia.Controls; diff --git a/src/Prism.Avalonia/Common/Stubs.cs b/src/Prism.Avalonia/Common/Stubs.cs new file mode 100644 index 0000000..c414a71 --- /dev/null +++ b/src/Prism.Avalonia/Common/Stubs.cs @@ -0,0 +1,10 @@ +using System; + +namespace Prism.Common +{ + internal static class Stubs + { + public static readonly Action Nop = () => { }; + public static readonly Action Throw = ex => { throw ex; }; + } +} diff --git a/src/Prism.Avalonia/Extensions/ObservableExtensions.cs b/src/Prism.Avalonia/Extensions/ObservableExtensions.cs new file mode 100644 index 0000000..4e538a7 --- /dev/null +++ b/src/Prism.Avalonia/Extensions/ObservableExtensions.cs @@ -0,0 +1,34 @@ +using System; +using Prism.Common; + +namespace Prism.Extensions +{ + internal static class ObservableExtensions + { + /// + /// Subscribes an element handler to an observable sequence. + /// + /// The type of the elements in the source sequence. + /// Observable sequence to subscribe to. + /// Action to invoke for each element in the observable sequence. + /// object used to unsubscribe from the observable sequence. + /// or is null. + public static IDisposable Subscribe(this IObservable source, Action onNext) + { + if (source == null) + { + throw new ArgumentNullException(nameof(source)); + } + + if (onNext == null) + { + throw new ArgumentNullException(nameof(onNext)); + } + + // + // [OK] Use of unsafe Subscribe: non-pretentious constructor for an observer; this overload is not to be used internally. + // + return source.Subscribe/*Unsafe*/(new AnonymousObserver(onNext, Stubs.Throw, Stubs.Nop)); + } + } +} diff --git a/src/Prism.Avalonia/Mvvm/ViewModelLocator.cs b/src/Prism.Avalonia/Mvvm/ViewModelLocator.cs index b6c68f5..dcfa255 100644 --- a/src/Prism.Avalonia/Mvvm/ViewModelLocator.cs +++ b/src/Prism.Avalonia/Mvvm/ViewModelLocator.cs @@ -1,6 +1,4 @@ -using System.ComponentModel; -using System.Threading; -using System; +using Prism.Extensions; using Avalonia; using Avalonia.Controls; diff --git a/src/Prism.Avalonia/Regions/ItemMetadata.cs b/src/Prism.Avalonia/Regions/ItemMetadata.cs index 321ff25..b7debab 100644 --- a/src/Prism.Avalonia/Regions/ItemMetadata.cs +++ b/src/Prism.Avalonia/Regions/ItemMetadata.cs @@ -1,4 +1,5 @@ -using Avalonia; +using Avalonia; +using Prism.Extensions; using System; namespace Prism.Regions diff --git a/src/Prism.Avalonia/Regions/RegionContext.cs b/src/Prism.Avalonia/Regions/RegionContext.cs index e21bccd..946b46e 100644 --- a/src/Prism.Avalonia/Regions/RegionContext.cs +++ b/src/Prism.Avalonia/Regions/RegionContext.cs @@ -1,6 +1,7 @@ -using System; +using System; using Avalonia; using Prism.Common; +using Prism.Extensions; namespace Prism.Regions { diff --git a/src/Prism.Avalonia/Regions/RegionManager.cs b/src/Prism.Avalonia/Regions/RegionManager.cs index 14037be..9940c82 100644 --- a/src/Prism.Avalonia/Regions/RegionManager.cs +++ b/src/Prism.Avalonia/Regions/RegionManager.cs @@ -1,4 +1,4 @@ -using System; +using System; using System.Collections; using System.Collections.Generic; using System.Collections.Specialized; @@ -9,6 +9,7 @@ using System.Threading; using Prism.Common; using Prism.Events; +using Prism.Extensions; using Prism.Ioc; using Prism.Properties; using Prism.Regions.Behaviors; diff --git a/src/Prism.Avalonia/Services/Dialogs/Dialog.cs b/src/Prism.Avalonia/Services/Dialogs/Dialog.cs index faf8d43..9255ab0 100644 --- a/src/Prism.Avalonia/Services/Dialogs/Dialog.cs +++ b/src/Prism.Avalonia/Services/Dialogs/Dialog.cs @@ -1,7 +1,7 @@ -using System; -using Avalonia; +using Avalonia; using Avalonia.Controls; using Avalonia.Styling; +using Prism.Extensions; namespace Prism.Services.Dialogs { From 82be71c88dbd7dfca356aec8a8b5ed193a12380a Mon Sep 17 00:00:00 2001 From: Airat Abdrakov <52558686+CrackAndDie@users.noreply.github.com> Date: Wed, 14 Feb 2024 16:28:22 +0300 Subject: [PATCH 02/10] Added tests for ObservableExtensions --- .../Extensions/ObservableExtensions.cs | 2 +- .../ObservableBehaviorFixture.cs | 56 +++++++++++++++++++ 2 files changed, 57 insertions(+), 1 deletion(-) create mode 100644 tests/Avalonia/Prism.Avalonia.Tests/Interactivity/ObservableBehaviorFixture.cs diff --git a/src/Prism.Avalonia/Extensions/ObservableExtensions.cs b/src/Prism.Avalonia/Extensions/ObservableExtensions.cs index 4e538a7..fef1d97 100644 --- a/src/Prism.Avalonia/Extensions/ObservableExtensions.cs +++ b/src/Prism.Avalonia/Extensions/ObservableExtensions.cs @@ -3,7 +3,7 @@ namespace Prism.Extensions { - internal static class ObservableExtensions + public static class ObservableExtensions { /// /// Subscribes an element handler to an observable sequence. diff --git a/tests/Avalonia/Prism.Avalonia.Tests/Interactivity/ObservableBehaviorFixture.cs b/tests/Avalonia/Prism.Avalonia.Tests/Interactivity/ObservableBehaviorFixture.cs new file mode 100644 index 0000000..1c58b61 --- /dev/null +++ b/tests/Avalonia/Prism.Avalonia.Tests/Interactivity/ObservableBehaviorFixture.cs @@ -0,0 +1,56 @@ +using Avalonia; +using Xunit; +using Prism.Extensions; + +namespace Prism.Avalonia.Tests.Interactivity +{ + public class ObservableBehaviorFixture + { + [Fact] + public void SubscribeWorksOnIObservableWithLambda() + { + var targetUIElement = new TestAvaloniaObject(); + targetUIElement.Test = "123"; + + Assert.Equal("123", targetUIElement.OutTest); + } + } + + class TestAvaloniaObject : AvaloniaObject + { + /// + /// The property to subscribe on. + /// + public static readonly StyledProperty TestProperty = + AvaloniaProperty.Register("Test"); + + /// + /// Gets or sets a value to the TestProperty. + /// + public string Test + { + get { return (string)GetValue(TestProperty); } + set { SetValue(TestProperty, value); } + } + + /// + /// The out test property to check after TestProperty change + /// + public string OutTest { get; set; } + + /// + /// Initializes a new instance of . + /// +#pragma warning disable CS8618 // Non-nullable field must contain a non-null value when exiting constructor. Consider declaring as nullable. + public TestAvaloniaObject() +#pragma warning restore CS8618 // Non-nullable field must contain a non-null value when exiting constructor. Consider declaring as nullable. + { + TestProperty.Changed.Subscribe(args => OnPropertyChanged(args)); + } + + private void OnPropertyChanged(AvaloniaPropertyChangedEventArgs args) + { + OutTest = args.NewValue.Value; + } + } +} From 1a43a5fec6537d0227fbf27b29d93df8ed7c398c Mon Sep 17 00:00:00 2001 From: Airat Abdrakov <52558686+CrackAndDie@users.noreply.github.com> Date: Mon, 19 Feb 2024 11:52:54 +0300 Subject: [PATCH 03/10] AnonymousObserver removed beacuse it was already in Avalonia.Base. ObservableExtensions is internal now and visible only for Tests --- .../Common/AnonymousObserver.cs | 67 ------------------- .../Extensions/ObservableExtensions.cs | 3 +- src/Prism.Avalonia/Properties/AssemblyInfo.cs | 3 + 3 files changed, 5 insertions(+), 68 deletions(-) delete mode 100644 src/Prism.Avalonia/Common/AnonymousObserver.cs diff --git a/src/Prism.Avalonia/Common/AnonymousObserver.cs b/src/Prism.Avalonia/Common/AnonymousObserver.cs deleted file mode 100644 index c541590..0000000 --- a/src/Prism.Avalonia/Common/AnonymousObserver.cs +++ /dev/null @@ -1,67 +0,0 @@ -using System; -using System.Threading.Tasks; - -namespace Prism.Common -{ - /// - /// Class to create an instance from delegate-based implementations of the On* methods. - /// - /// The type of the elements in the sequence. - public class AnonymousObserver : IObserver - { - private static readonly Action ThrowsOnError = ex => throw ex; - private static readonly Action NoOpCompleted = () => { }; - private readonly Action _onNext; - private readonly Action _onError; - private readonly Action _onCompleted; - - public AnonymousObserver(TaskCompletionSource tcs) - { - if (tcs is null) - { - throw new ArgumentNullException(nameof(tcs)); - } - - _onNext = tcs.SetResult; - _onError = tcs.SetException; - _onCompleted = NoOpCompleted; - } - - public AnonymousObserver(Action onNext, Action onError, Action onCompleted) - { - _onNext = onNext ?? throw new ArgumentNullException(nameof(onNext)); - _onError = onError ?? throw new ArgumentNullException(nameof(onError)); - _onCompleted = onCompleted ?? throw new ArgumentNullException(nameof(onCompleted)); - } - - public AnonymousObserver(Action onNext) - : this(onNext, ThrowsOnError, NoOpCompleted) - { - } - - public AnonymousObserver(Action onNext, Action onError) - : this(onNext, onError, NoOpCompleted) - { - } - - public AnonymousObserver(Action onNext, Action onCompleted) - : this(onNext, ThrowsOnError, onCompleted) - { - } - - public void OnCompleted() - { - _onCompleted.Invoke(); - } - - public void OnError(Exception error) - { - _onError.Invoke(error); - } - - public void OnNext(T value) - { - _onNext.Invoke(value); - } - } -} diff --git a/src/Prism.Avalonia/Extensions/ObservableExtensions.cs b/src/Prism.Avalonia/Extensions/ObservableExtensions.cs index fef1d97..dad8f94 100644 --- a/src/Prism.Avalonia/Extensions/ObservableExtensions.cs +++ b/src/Prism.Avalonia/Extensions/ObservableExtensions.cs @@ -1,9 +1,10 @@ using System; +using Avalonia.Reactive; using Prism.Common; namespace Prism.Extensions { - public static class ObservableExtensions + internal static class ObservableExtensions { /// /// Subscribes an element handler to an observable sequence. diff --git a/src/Prism.Avalonia/Properties/AssemblyInfo.cs b/src/Prism.Avalonia/Properties/AssemblyInfo.cs index e503e22..3cfc4be 100644 --- a/src/Prism.Avalonia/Properties/AssemblyInfo.cs +++ b/src/Prism.Avalonia/Properties/AssemblyInfo.cs @@ -1,4 +1,5 @@ using System; +using System.Runtime.CompilerServices; using System.Runtime.InteropServices; using Avalonia.Metadata; @@ -18,3 +19,5 @@ [assembly: XmlnsDefinition("http://prismlibrary.com/", "Prism.Interactivity")] [assembly: XmlnsDefinition("http://prismlibrary.com/", "Prism.Services.Dialogs")] [assembly: XmlnsDefinition("http://prismlibrary.com/", "Prism.Ioc")] + +[assembly: InternalsVisibleTo("Prism.Avalonia.Tests")] From 1b8c7f199c5a0de07c704dce21485d1bf2cb1a9c Mon Sep 17 00:00:00 2001 From: Damian Date: Wed, 6 Mar 2024 11:45:31 -0500 Subject: [PATCH 04/10] README.md Moved Contributing Rules to the top --- README.md | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/README.md b/README.md index 5578a8c..1a414bc 100644 --- a/README.md +++ b/README.md @@ -15,6 +15,8 @@ With Prism.Avalonia's logic and development approach being **similar** to that of [Prism for WPF](https://github.com/PrismLibrary/Prism/), so you can get started right away! Keep in mind, they are **similar** and not 1-to-1. Check out our [Wiki](https://github.com/AvaloniaCommunity/Prism.Avalonia/wiki) and [Avalonia Outlookish](https://github.com/DamianSuess/Learn.PrismAvaloniaOutlookish) app for tips and tricks. +## Package Releases + Just like Prism.WPF or Prism.Maui, your project must reference both the Prism.Avalonia (_Core_) and Prism.DryIoc.Avalonia (_IoC container_) packages to work. | Package | Stable | Preview @@ -22,7 +24,7 @@ Just like Prism.WPF or Prism.Maui, your project must reference both the Prism.Av | Prism.Avalonia | [![Prism.Avalonia NuGet Badge](https://buildstats.info/nuget/Prism.Avalonia?dWidth=70&includePreReleases=false)](https://www.nuget.org/packages/Prism.Avalonia/) | [![Prism.Avalonia NuGet Badge](https://buildstats.info/nuget/Prism.Avalonia?dWidth=70&includePreReleases=true)](https://www.nuget.org/packages/Prism.Avalonia/) | Prism.DryIoc.Avalonia | [![Prism.DryIoc.Avalonia NuGet Badge](https://buildstats.info/nuget/Prism.DryIoc.Avalonia?dWidth=70&includePreReleases=false)](https://www.nuget.org/packages/Prism.DryIoc.Avalonia/) | [![Prism.DryIoc.Avalonia NuGet Badge](https://buildstats.info/nuget/Prism.DryIoc.Avalonia?dWidth=70&includePreReleases=true)](https://www.nuget.org/packages/Prism.DryIoc.Avalonia/) -## Version Notice +### Version Notice Choose the NuGet package version that matches your Avalonia version. @@ -40,6 +42,14 @@ the Avalonia version support. For instance `v8.1.97.11000` of this library suppo Be sure to check out the [ChangeLog.md](ChangeLog.md) and [Upgrading-to-Avalonia-11.md](Upgrading-to-Avalonia-11.md) when upgrading your NuGet packages. Also, view the official [Avalonia Upgrading from v0.10](https://docs.avaloniaui.net/docs/next/stay-up-to-date/upgrade-from-0.10). +## Contributing + +Prism.Avalonia is an open-source project under the MIT license. We encourage community members like yourself to contribute. + +You can contribute today by creating a **feature request**, **issue**, or **discussion** on the forum. From there we can have a brief discussion as to where this fits into the backlog priority. If this is something that fits within the Prism architecture, we'll kindly ask you to create a **Pull Request**. Any PR made without first having an issue/discussion may be closed. + +Issues posted without a description may be closed immediately. Use the discussion boards if you have a question, not Issues. + ## Install Add the Prism.Avalonia and its DryIoc packages to your project: @@ -188,12 +198,4 @@ Below is a basic branching hierarchy and strategy. | `feature/*` | New feature branch. Once completed, it is merged into `develop` and the branch must be deleted. | `stable/*` | Stable release base build which shares cherry-picked merges from `develop`. This branch **must not** be deleted. -## Contributing - -Prism.Avalonia is an open-source project under the MIT license. We encourage community members like yourself to contribute. - -You can contribute today by creating a **feature request**, **issue**, or **discussion** on the forum. From there we can have a brief discussion as to where this fits into the backlog priority. If this is something that fits within the Prism architecture, we'll kindly ask you to create a **Pull Request**. Any PR made without first having an issue/discussion may be closed. - - - **Sponsored by:** [Suess Labs](https://suesslabs.com) a subsidary of Xeno Innovations, Inc. From 89db59595197716319653e9fb4df90aeb67206d8 Mon Sep 17 00:00:00 2001 From: Damian Suess Date: Mon, 8 Apr 2024 18:38:42 -0400 Subject: [PATCH 05/10] Removed reference to Avalonia.ReactiveUI for sample projects --- build/SampleApp.props | 1 - 1 file changed, 1 deletion(-) diff --git a/build/SampleApp.props b/build/SampleApp.props index 3e4c06d..f06c124 100644 --- a/build/SampleApp.props +++ b/build/SampleApp.props @@ -12,7 +12,6 @@ - From 69bd961ff3646d62a95329eaacba20871266df5b Mon Sep 17 00:00:00 2001 From: Damian Date: Sat, 13 Apr 2024 10:16:11 -0400 Subject: [PATCH 06/10] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 1a414bc..f22bd72 100644 --- a/README.md +++ b/README.md @@ -3,7 +3,7 @@ [Prism.Avalonia](https://github.com/AvaloniaCommunity/Prism.Avalonia) provides your [Avalonia](https://avaloniaui.net/) apps with [Prism framework](https://github.com/PrismLibrary/Prism) support so you can **Navigate**, create **Dialog Windows** and **Notifications**, provide **Dependency Injection** and internal **Messaging** easier than before! You will need both packages installed to get started. > ### **Announcement:** -> _Prism.Avalonia v9.0 beta coming soon!_ +> _Prism.Avalonia v9.0-pre just arrived!_ **For more samples outside of this repo, check out:** From e00e34553384903531d5b3fe80bea6473d9cdbd8 Mon Sep 17 00:00:00 2001 From: Damian Suess Date: Sun, 28 Apr 2024 09:13:52 -0400 Subject: [PATCH 07/10] Added notes for Prism.Avalonia v9.0.401-pre and v9.0.271-pre --- README.md | 34 ++++++++++++++++++---------------- 1 file changed, 18 insertions(+), 16 deletions(-) diff --git a/README.md b/README.md index f22bd72..fd86b45 100644 --- a/README.md +++ b/README.md @@ -2,8 +2,8 @@ [Prism.Avalonia](https://github.com/AvaloniaCommunity/Prism.Avalonia) provides your [Avalonia](https://avaloniaui.net/) apps with [Prism framework](https://github.com/PrismLibrary/Prism) support so you can **Navigate**, create **Dialog Windows** and **Notifications**, provide **Dependency Injection** and internal **Messaging** easier than before! You will need both packages installed to get started. -> ### **Announcement:** -> _Prism.Avalonia v9.0-pre just arrived!_ +> **Announcement!** +> * _Prism.Avalonia v9.0.401-pre just arrived!_ **For more samples outside of this repo, check out:** @@ -11,7 +11,8 @@ * [Learn PrismLibrary](https://github.com/DamianSuess/Learn.PrismLibrary) * _If you have samples, let us know and we'll feature them!_ -![Sample Outlookish](logo/Sample-Outlookish.png) + +![Sample Outlookish](https://raw.githubusercontent.com/AvaloniaCommunity/Prism.Avalonia/v9.0.401.11000-pre/images/Sample-Outlookish.png) With Prism.Avalonia's logic and development approach being **similar** to that of [Prism for WPF](https://github.com/PrismLibrary/Prism/), so you can get started right away! Keep in mind, they are **similar** and not 1-to-1. Check out our [Wiki](https://github.com/AvaloniaCommunity/Prism.Avalonia/wiki) and [Avalonia Outlookish](https://github.com/DamianSuess/Learn.PrismAvaloniaOutlookish) app for tips and tricks. @@ -28,19 +29,20 @@ Just like Prism.WPF or Prism.Maui, your project must reference both the Prism.Av Choose the NuGet package version that matches your Avalonia version. -The Avalonia version of this package uses [SemVer](https://semver.org/) format: `MAJOR.MINOR.PATCH.REVISION`. The `REVISION` segment indicates -the Avalonia version support. For instance `v8.1.97.11000` of this library supports, Avalonia v11.0.0. +Our [versioning schema](https://github.com/AvaloniaCommunity/Prism.Avalonia/wiki/Versioning-Schema) is based on the [SemVer](https://semver.org/) using the format `MAJOR.MINOR.PATCH.REVISION`. The `REVISION` segment indicates the Avalonia version support. For instance `v8.1.97.11000` of this library supports, Prism `v8.1.97` and Avalonia `v11.0.x`. -| Avalonia Version | NuGet Package | -|-|-| -| **11.0** | 8.1.97.11000 ([Core](https://www.nuget.org/packages/Prism.Avalonia/8.1.97.11000)) ([DryIoc](https://www.nuget.org/packages/Prism.DryIoc.Avalonia/8.1.97.11000)) -| **0.10.21** | 8.1.97.1021 ([Core](https://www.nuget.org/packages/Prism.Avalonia/8.1.97.1021)) ([DryIoc](https://www.nuget.org/packages/Prism.DryIoc.Avalonia/8.1.97.1021)) -| **11.0 RC-1.1** | 8.1.97.11000-rc1.1 ([Core](https://www.nuget.org/packages/Prism.Avalonia/8.1.97.11000-rc1.1)) ([DryIoc](https://www.nuget.org/packages/Prism.DryIoc.Avalonia/8.1.97.11000-rc1.1)) -| 11.0 Preview 8 | 8.1.97.11-preview.11.8 -| 11.0 Preview 5 | 8.1.97.4-preview.11.5 -| 11.0 Preview 4 | 8.1.97.3-preview.11.4 +| Prism Version | Avalonia Version | NuGet Package +|-|-|- +| v9.0.401-pre | **11.0.7** | v9.0.401.11000-pre ([Core](https://www.nuget.org/packages/Prism.Avalonia/9.0.401.11000-pre)) ([DryIoc](https://www.nuget.org/packages/Prism.DryIoc.Avalonia/9.0.401.11000-pre)) +| v9.0.271-pre | **11.0.7** | v9.0.271.11000-pre ([Core](https://www.nuget.org/packages/Prism.Avalonia/9.0.271.11000-pre)) ([DryIoc](https://www.nuget.org/packages/Prism.DryIoc.Avalonia/9.0.271.11000-pre)) +| v8.1.97 | **11.0.7** | v8.1.97.11000 ([Core](https://www.nuget.org/packages/Prism.Avalonia/8.1.97.11000)) ([DryIoc](https://www.nuget.org/packages/Prism.DryIoc.Avalonia/8.1.97.11000)) +| v8.1.97 | **0.10.21** | v8.1.97.1021 ([Core](https://www.nuget.org/packages/Prism.Avalonia/8.1.97.1021)) ([DryIoc](https://www.nuget.org/packages/Prism.DryIoc.Avalonia/8.1.97.1021)) + +Be sure to check out the [ChangeLog.md](ChangeLog.md) and guides when upgrading your NuGet packages: -Be sure to check out the [ChangeLog.md](ChangeLog.md) and [Upgrading-to-Avalonia-11.md](Upgrading-to-Avalonia-11.md) when upgrading your NuGet packages. Also, view the official [Avalonia Upgrading from v0.10](https://docs.avaloniaui.net/docs/next/stay-up-to-date/upgrade-from-0.10). +* [Upgrading to Prism v9.0.x-pre](https://github.com/AvaloniaCommunity/Prism.Avalonia/wiki/Upgrading-to-Prism-v9.0) +* [Upgrading to Avalonia-11](Upgrading-to-Avalonia-11.md) +* Also, the official [Avalonia Upgrading from v0.10](https://docs.avaloniaui.net/docs/next/stay-up-to-date/upgrade-from-0.10). ## Contributing @@ -56,8 +58,8 @@ Add the Prism.Avalonia and its DryIoc packages to your project: ```powershell # Avalonia v11 -Install-Package Prism.Avalonia -Version 8.1.97.11000 -Install-Package Prism.DryIoc.Avalonia -Version 8.1.97.11000 +Install-Package Prism.Avalonia -Version 8.1.97.11072 +Install-Package Prism.DryIoc.Avalonia -Version 8.1.97.11072 # Avalonia v0.10.1021 Install-Package Prism.Avalonia -Version 8.1.97.1021 From d024a57dbd80e3afbc869192b4d9382f95b3aee3 Mon Sep 17 00:00:00 2001 From: Damian Suess Date: Sun, 28 Apr 2024 09:16:26 -0400 Subject: [PATCH 08/10] Link to upgrade wiki --- README.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/README.md b/README.md index fd86b45..e8d4806 100644 --- a/README.md +++ b/README.md @@ -3,7 +3,10 @@ [Prism.Avalonia](https://github.com/AvaloniaCommunity/Prism.Avalonia) provides your [Avalonia](https://avaloniaui.net/) apps with [Prism framework](https://github.com/PrismLibrary/Prism) support so you can **Navigate**, create **Dialog Windows** and **Notifications**, provide **Dependency Injection** and internal **Messaging** easier than before! You will need both packages installed to get started. > **Announcement!** +> > * _Prism.Avalonia v9.0.401-pre just arrived!_ +> * _Prism.Avalonia v9.0.271-pre just arrived!_ +> * Follow the [Upgrading to Prism v9.0.x-pre](https://github.com/AvaloniaCommunity/Prism.Avalonia/wiki/Upgrading-to-Prism-v9.0) guide for breaking changes **For more samples outside of this repo, check out:** From 013f7f38a6f7d82e5b5871997f798427c8056ca2 Mon Sep 17 00:00:00 2001 From: Damian Suess Date: Sun, 28 Apr 2024 09:36:20 -0400 Subject: [PATCH 09/10] Bump version to v8.1.97.11073. Updated readme files --- README.md | 8 ++++---- build/Base.props | 2 +- samples/SampleMvvmApp/readme.md | 4 ++-- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index e8d4806..de11063 100644 --- a/README.md +++ b/README.md @@ -15,7 +15,7 @@ * _If you have samples, let us know and we'll feature them!_ -![Sample Outlookish](https://raw.githubusercontent.com/AvaloniaCommunity/Prism.Avalonia/v9.0.401.11000-pre/images/Sample-Outlookish.png) +![Sample Outlookish](https://raw.githubusercontent.com/AvaloniaCommunity/Prism.Avalonia/stable/v8.1.97.11xx/logo/Sample-Outlookish.png) With Prism.Avalonia's logic and development approach being **similar** to that of [Prism for WPF](https://github.com/PrismLibrary/Prism/), so you can get started right away! Keep in mind, they are **similar** and not 1-to-1. Check out our [Wiki](https://github.com/AvaloniaCommunity/Prism.Avalonia/wiki) and [Avalonia Outlookish](https://github.com/DamianSuess/Learn.PrismAvaloniaOutlookish) app for tips and tricks. @@ -38,7 +38,7 @@ Our [versioning schema](https://github.com/AvaloniaCommunity/Prism.Avalonia/wiki |-|-|- | v9.0.401-pre | **11.0.7** | v9.0.401.11000-pre ([Core](https://www.nuget.org/packages/Prism.Avalonia/9.0.401.11000-pre)) ([DryIoc](https://www.nuget.org/packages/Prism.DryIoc.Avalonia/9.0.401.11000-pre)) | v9.0.271-pre | **11.0.7** | v9.0.271.11000-pre ([Core](https://www.nuget.org/packages/Prism.Avalonia/9.0.271.11000-pre)) ([DryIoc](https://www.nuget.org/packages/Prism.DryIoc.Avalonia/9.0.271.11000-pre)) -| v8.1.97 | **11.0.7** | v8.1.97.11000 ([Core](https://www.nuget.org/packages/Prism.Avalonia/8.1.97.11000)) ([DryIoc](https://www.nuget.org/packages/Prism.DryIoc.Avalonia/8.1.97.11000)) +| v8.1.97 | **11.0.7** | v8.1.97.11073 ([Core](https://www.nuget.org/packages/Prism.Avalonia/8.1.97.11073)) ([DryIoc](https://www.nuget.org/packages/Prism.DryIoc.Avalonia/8.1.97.11073)) | v8.1.97 | **0.10.21** | v8.1.97.1021 ([Core](https://www.nuget.org/packages/Prism.Avalonia/8.1.97.1021)) ([DryIoc](https://www.nuget.org/packages/Prism.DryIoc.Avalonia/8.1.97.1021)) Be sure to check out the [ChangeLog.md](ChangeLog.md) and guides when upgrading your NuGet packages: @@ -61,8 +61,8 @@ Add the Prism.Avalonia and its DryIoc packages to your project: ```powershell # Avalonia v11 -Install-Package Prism.Avalonia -Version 8.1.97.11072 -Install-Package Prism.DryIoc.Avalonia -Version 8.1.97.11072 +Install-Package Prism.Avalonia -Version 8.1.97.11073 +Install-Package Prism.DryIoc.Avalonia -Version 8.1.97.11073 # Avalonia v0.10.1021 Install-Package Prism.Avalonia -Version 8.1.97.1021 diff --git a/build/Base.props b/build/Base.props index f374eea..722bbf3 100644 --- a/build/Base.props +++ b/build/Base.props @@ -2,7 +2,7 @@ - 8.1.97.11072 + 8.1.97.11073 https://github.com/AvaloniaCommunity/Prism.Avalonia Copyright (c) 2024 Xeno Innovations, Inc. MIT diff --git a/samples/SampleMvvmApp/readme.md b/samples/SampleMvvmApp/readme.md index fcc47b4..2ff79aa 100644 --- a/samples/SampleMvvmApp/readme.md +++ b/samples/SampleMvvmApp/readme.md @@ -2,10 +2,10 @@ This demonstrates the following Prism.Avalonia features: -* .NET 6 - Cross-platform +* .NET 6, 7, 8 - Cross-platform * MVVM Pattern - _Model View ViewModel_ * Prism Navigation with and without passing parameters. -* Prism Journling backwards +* Prism Journaling backwards * Prism Regions for placing views * Prism Region with multiple views - registering multiple views and displaying them in a single ItemsControl using a custom ItemsControlRegionAdapter * Prism.DryIoc for Dependency Injection of Services From 74d50405129f6c1b353f3e2cf8de298b4eb8e365 Mon Sep 17 00:00:00 2001 From: Damian Suess Date: Sun, 28 Apr 2024 09:41:15 -0400 Subject: [PATCH 10/10] Change log notes --- ChangeLog.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ChangeLog.md b/ChangeLog.md index 009dff7..e4cdcdb 100644 --- a/ChangeLog.md +++ b/ChangeLog.md @@ -2,6 +2,10 @@ Change log history for Prism.Avalonia +## v8.1.97.11073 (2024-04-28) + +* Removed dependency on Avalonia.ReactiveUI + ## v8.1.97.11072 (2024-01-27) * Added support for .NET 8