diff --git a/README.md b/README.md index 98e2acb..47cd4b1 100644 --- a/README.md +++ b/README.md @@ -90,6 +90,8 @@ public partial class Index ### Supported Components +- [Application](#application) **(since 0.4.8)** +- [Application Header](#application-header) **(since 0.4.8)** - [Basic Navigation](#basic-navigation) - [Navigation Menu](#navigation-menu) - [About and Legal](#about-and-legal) @@ -149,6 +151,65 @@ public partial class Index - [Form Validation](#form-validation) - [Workflow](#workflow) +## Application +```razor + + + + + + Item 1 + Item 2 + + + + + + + +``` + +```csharp +Application _app; + +// Set the app switch config when the component is rendered. +protected override async Task OnAfterRenderAsync(bool firstRender) +{ + if(firstRender) + { + AppSwitchConfig config = new() + { + CurrentAppId = "1", + Apps = + [ + new App() + { + Id = "App1", + Name = "App 1", + Description = "Awesome app", + Url = "app1", + Target = "_self", + IconSrc = "..." + } + ] + } + + _app.AppSwitchConfig = config; + } +} +``` + +## Application Header + +```razor + + + +``` + ## Basic Navigation ```razor