diff --git a/Hyperbar.Windows.Primary/PrimaryWidgetProvider.cs b/Hyperbar.Windows.Primary/PrimaryWidgetProvider.cs index 7cfafc5..3fae557 100644 --- a/Hyperbar.Windows.Primary/PrimaryWidgetProvider.cs +++ b/Hyperbar.Windows.Primary/PrimaryWidgetProvider.cs @@ -7,7 +7,7 @@ public class PrimaryWidgetProvider : IWidgetProvider { public void Create(IServiceCollection services) => services.AddConfiguration() - .AddTransient() - .AddTransient(provider => provider.GetRequiredService().Create()) + .AddTransient() + .AddTransient(provider => provider.GetRequiredService().Create()) .AddWidgetTemplate(); } \ No newline at end of file diff --git a/Hyperbar.Windows.Primary/PrimaryWidgetViewModelFactory.cs b/Hyperbar.Windows.Primary/WidgetComponentMappinglFactory.cs similarity index 70% rename from Hyperbar.Windows.Primary/PrimaryWidgetViewModelFactory.cs rename to Hyperbar.Windows.Primary/WidgetComponentMappinglFactory.cs index 03db3dc..669d5e1 100644 --- a/Hyperbar.Windows.Primary/PrimaryWidgetViewModelFactory.cs +++ b/Hyperbar.Windows.Primary/WidgetComponentMappinglFactory.cs @@ -1,12 +1,12 @@ namespace Hyperbar.Windows.Primary; -public class PrimaryWidgetViewModelFactory : - IViewModelFactory> +public class WidgetComponentMappinglFactory : + MappingFactory> { private readonly PrimaryWidgetConfiguration configuration; private readonly IServiceFactory service; - public PrimaryWidgetViewModelFactory(PrimaryWidgetConfiguration configuration, + public WidgetComponentMappinglFactory(PrimaryWidgetConfiguration configuration, IServiceFactory service) { this.configuration = configuration; diff --git a/Hyperbar/Views/IViewModelFactory.cs b/Hyperbar/Views/IViewModelFactory.cs deleted file mode 100644 index ced60dd..0000000 --- a/Hyperbar/Views/IViewModelFactory.cs +++ /dev/null @@ -1,6 +0,0 @@ -namespace Hyperbar; - -public interface IViewModelFactory -{ - TTo Create(); -} diff --git a/Hyperbar/Views/MappingFactory.cs b/Hyperbar/Views/MappingFactory.cs new file mode 100644 index 0000000..287a42c --- /dev/null +++ b/Hyperbar/Views/MappingFactory.cs @@ -0,0 +1,6 @@ +namespace Hyperbar; + +public interface MappingFactory +{ + TTo Create(); +}