Skip to content

Commit

Permalink
Add Radzen
Browse files Browse the repository at this point in the history
  • Loading branch information
oveldman committed Apr 1, 2024
1 parent e88cc70 commit 53a0f22
Show file tree
Hide file tree
Showing 7 changed files with 18 additions and 2 deletions.
1 change: 1 addition & 0 deletions sources/Clients.Admin.Web/Clients.Admin.Web.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
<ItemGroup>
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly" />
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly.DevServer" PrivateAssets="all"/>
<PackageReference Include="Radzen.Blazor" />
</ItemGroup>

<ItemGroup>
Expand Down
1 change: 1 addition & 0 deletions sources/Clients.Admin.Web/Layout/MainLayout.razor
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

<main>
<div class="top-row px-4">
<RadzenComponents/>
<NavLink class="nav-link" href="Login">
Login
</NavLink>
Expand Down
3 changes: 3 additions & 0 deletions sources/Clients.Admin.Web/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,14 @@
using Microsoft.AspNetCore.Components.WebAssembly.Hosting;
using MadWorldNL.Clients.Admin.Web;
using MadWorldNL.Clients.Identity.Blazor.Shared.Extensions;
using Radzen;

var builder = WebAssemblyHostBuilder.CreateDefault(args);
builder.RootComponents.Add<App>("#app");
builder.RootComponents.Add<HeadOutlet>("head::after");

builder.Services.AddRadzenComponents();

builder.AddIdentity();

builder.Services.AddScoped(sp => new HttpClient { BaseAddress = new Uri(builder.HostEnvironment.BaseAddress) });
Expand Down
7 changes: 6 additions & 1 deletion sources/Clients.Admin.Web/_Imports.razor
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,10 @@
@using Microsoft.AspNetCore.Components.Web.Virtualization
@using Microsoft.AspNetCore.Components.WebAssembly.Http
@using Microsoft.JSInterop

@using Radzen
@using Radzen.Blazor

@using Clients.Admin.Web
@using Clients.Admin.Web.Layout
@using Clients.Admin.Web.Layout

2 changes: 2 additions & 0 deletions sources/Clients.Admin.Web/wwwroot/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
<link rel="stylesheet" href="css/app.css" />
<link rel="icon" type="image/png" href="favicon.png" />
<link href="MadWorldNL.Clients.Admin.Web.styles.css" rel="stylesheet" />
<link rel="stylesheet" href="_content/Radzen.Blazor/css/material-base.css">
</head>

<body>
Expand All @@ -27,6 +28,7 @@
<a class="dismiss">🗙</a>
</div>
<script src="_framework/blazor.webassembly.js"></script>
<script src="_content/Radzen.Blazor/Radzen.Blazor.js"></script>
</body>

</html>
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
<PackageReference Include="Microsoft.AspNetCore.Components.Web" />
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly" />
<PackageReference Include="Microsoft.Extensions.Http" />
<PackageReference Include="Radzen.Blazor" />
</ItemGroup>

<ItemGroup>
Expand Down
5 changes: 4 additions & 1 deletion sources/Clients.Identity.Blazor.Shared/_Imports.razor
Original file line number Diff line number Diff line change
@@ -1 +1,4 @@
@using Microsoft.AspNetCore.Components.Web
@using Microsoft.AspNetCore.Components.Web

@using Radzen
@using Radzen.Blazor

0 comments on commit 53a0f22

Please sign in to comment.