Kimi.MudThemeManager
1.0.1
See the version list below for details.
dotnet add package Kimi.MudThemeManager --version 1.0.1
NuGet\Install-Package Kimi.MudThemeManager -Version 1.0.1
<PackageReference Include="Kimi.MudThemeManager" Version="1.0.1" />
paket add Kimi.MudThemeManager --version 1.0.1
#r "nuget: Kimi.MudThemeManager, 1.0.1"
// Install Kimi.MudThemeManager as a Cake Addin #addin nuget:?package=Kimi.MudThemeManager&version=1.0.1 // Install Kimi.MudThemeManager as a Cake Tool #tool nuget:?package=Kimi.MudThemeManager&version=1.0.1
Update the mudblazor thememanager UI to support manul input font family list.
below is the readme of mudblazor thememanager
<h1> <picture> <source media="(prefers-color-scheme: dark)" srcset="content/MudBlazor-GitHub-NoBg-Dark.png"> <source media="(prefers-color-scheme: light)" srcset="content/MudBlazor-GitHub-NoBg.png"> <img alt="MudBlazor" src="content/MudBlazor-GitHub-NoBg.png"> </picture> </h1>
Theme Manager / Generator for MudBlazor
Blazor Theme Manager component for MudBlazor library. Can be used live or during development to fast and easy try out different theme settings.
This component is currently not suitable for production applications, be ready for performance issues, bugs and missing features. Feel free to help improve it.
Workflow
Prerequisites
- MudBlazor Installed and configurated.
Installation
Install Package
dotnet add package MudBlazor.ThemeManager
Add the following to _Imports.razor
@using MudBlazor.ThemeManager
Add the following to your HTML head
section, it's either index.html
or _Layout.cshtml
/_Host.cshtml
/App.razor
depending on whether you're running WebAssembly or Server.
<link href="https://fonts.googleapis.com/css2?family=Ubuntu:wght@300;400;500;700&display=swap" rel="stylesheet">
<link href="https://fonts.googleapis.com/css2?family=Montserrat:wght@400;500;600;700&display=swap" rel="stylesheet">
<link href="https://fonts.googleapis.com/css?family=Roboto:300,400,500,700&display=swap" rel="stylesheet" />
<link href="_content/MudBlazor.ThemeManager/MudBlazorThemeManager.css" rel="stylesheet" />
Add the components in your MainLayout.razor
and inside <MudLayout>
<MudThemeManagerButton OnClick="@((e) => OpenThemeManager(true))" />
<MudThemeManager Open="_themeManagerOpen" OpenChanged="OpenThemeManager" Theme="_themeManager" ThemeChanged="UpdateTheme" />
Add the following inside your @code for MainLayout.razor
private ThemeManagerTheme _themeManager = new ThemeManagerTheme();
public bool _themeManagerOpen = false;
void OpenThemeManager(bool value)
{
_themeManagerOpen = value;
}
void UpdateTheme(ThemeManagerTheme value)
{
_themeManager = value;
StateHasChanged();
}
protected override void OnInitialized()
{
StateHasChanged();
}
Connect the ThemeManagerTheme with MudThemeProvider
to control all the theme colors. You can also connect MudAppBar
and MudDrawer
directly.
<MudThemeProvider Theme="_themeManager.Theme" />
<MudAppBar Elevation="_themeManager.AppBarElevation">
<MudDrawer @bind-Open="_drawerOpen" ClipMode="_themeManager.DrawerClipMode" Elevation="_themeManager.DrawerElevation">
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net7.0 is compatible. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 is compatible. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. |
-
net7.0
- Microsoft.AspNetCore.Components (>= 7.0.20)
- MudBlazor (>= 7.0.0)
-
net8.0
- Microsoft.AspNetCore.Components (>= 8.0.6)
- MudBlazor (>= 7.0.0)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.