diff --git a/OliverBooth/Pages/Shared/_AdminLayout.cshtml b/OliverBooth/Pages/Shared/_AdminLayout.cshtml index 635cf59..42bf356 100644 --- a/OliverBooth/Pages/Shared/_AdminLayout.cshtml +++ b/OliverBooth/Pages/Shared/_AdminLayout.cshtml @@ -73,6 +73,7 @@ @await RenderSectionAsync("Styles", required: false) +
@@ -144,6 +145,7 @@ + diff --git a/OliverBooth/Pages/Shared/_Layout.cshtml b/OliverBooth/Pages/Shared/_Layout.cshtml index 7e365a7..997a6cf 100644 --- a/OliverBooth/Pages/Shared/_Layout.cshtml +++ b/OliverBooth/Pages/Shared/_Layout.cshtml @@ -66,6 +66,7 @@ @await RenderSectionAsync("Styles", required: false) +
@@ -151,6 +152,7 @@ + diff --git a/OliverBooth/Pages/_Imports.razor b/OliverBooth/Pages/_Imports.razor new file mode 100644 index 0000000..aefe217 --- /dev/null +++ b/OliverBooth/Pages/_Imports.razor @@ -0,0 +1,11 @@ +@using System.Net.Http +@using System.Net.Http.Json +@using Microsoft.AspNetCore.Components.Forms +@using Microsoft.AspNetCore.Components.Routing +@using Microsoft.AspNetCore.Components.Web +@using static Microsoft.AspNetCore.Components.Web.RenderMode +@using Microsoft.AspNetCore.Components.Web.Virtualization +@using Microsoft.AspNetCore.Mvc.TagHelpers +@using Microsoft.JSInterop + + \ No newline at end of file diff --git a/OliverBooth/Program.cs b/OliverBooth/Program.cs index fa5b93a..cc0672a 100644 --- a/OliverBooth/Program.cs +++ b/OliverBooth/Program.cs @@ -53,6 +53,8 @@ builder.Services.AddHostedSingleton(); builder.Services.AddHostedSingleton(); builder.Services.AddRazorPages().AddRazorRuntimeCompilation(); builder.Services.AddControllersWithViews(); +builder.Services.AddRazorComponents().AddInteractiveServerComponents(); +builder.Services.AddServerSideBlazor().AddInteractiveServerComponents(); builder.Services.AddRouting(options => options.LowercaseUrls = true); builder.Services.AddReCaptcha(builder.Configuration.GetSection("ReCaptcha")); @@ -78,5 +80,6 @@ app.UseAuthorization(); app.MapControllers(); app.MapRazorPages(); +app.MapBlazorHub(); app.Run();