Skip to main content

syncfusion-blazor-themes

Customize and apply Syncfusion Blazor themes — Theme Studio color customization, CSS/SCSS integration, lightweight themes, component filtering, and Sass variable overrides

来源信息

仓库
syncfusion/blazor-ui-components-skills
最近来源活动
2026年7月6日 07:20
检测到的 SKILL.md 语言
英语
星标
4
分支
1

安装方式

默认使用会先检查来源的 Prompt;你也可以切换为直接命令,或下载本地副本。

检查来源文件

决定是否安装前,请先阅读 SKILL.md,以及 SkillsMP 当前展示的配套文件。

文件资源管理器
2 个文件

正在显示 SKILL.md

SKILL.md
来源说明 · 只读预览
name
syncfusion-blazor-themes
description
Customize and apply Syncfusion Blazor themes — Theme Studio color customization, CSS/SCSS integration, lightweight themes, component filtering, and Sass variable overrides
metadata
{"author":"Syncfusion Inc","version":"34.1.29"}
# Syncfusion Blazor Themes Complete guidance for applying and customizing Syncfusion Blazor component themes using Theme Studio, SCSS overrides, and production-ready best practices. ## When to Use Use this skill when you need to: - Apply a built-in Syncfusion theme (Material 3, Bootstrap 5, Fluent, Tailwind, etc.) - Customize theme colors interactively using Theme Studio - Generate a filtered, minimal CSS bundle for only the components you use - Override theme variables with Sass `@use` and CSS custom properties - Use lightweight theme variants to reduce bundle size - Import and re-use saved theme settings (`settings.json`) **Do NOT use for:** - Initial Blazor project setup → use `syncfusion-blazor-common` - Script loading and CRG bundles → use `syncfusion-blazor-common` - CSP configuration for stylesheets → use `syncfusion-blazor-security` ## Quick Reference - **Full Theme Studio guide**: See [theme-appearance.md](references/theme-appearance.md) ## Available Themes at a Glance | Theme | Description | |-------|-------------| | **Material 3** | Google Material Design 3 (recommended default) | | **Bootstrap 5** | Bootstrap 5 design system | | **Fluent / Fluent 2** | Microsoft Fluent Design System | | **Tailwind CSS** | Tailwind CSS design tokens | | **Bootstrap 4** | Bootstrap 4 design system | | **Material** | Original Material Design | | **High Contrast** | WCAG-compliant accessible theme | > **Lightweight variants** (e.g., `fluent2-lite.css`) exclude web fonts — ideal for offline or bandwidth-constrained environments. ## Quick Setup: Add a Theme ### Blazor Web App (.NET 8+) Add to `<head>` in `~/Components/App.razor`: ```html <link href="_content/Syncfusion.Blazor.Themes/material3.css" rel="stylesheet" /> ``` ### Blazor WebAssembly Standalone Add to `<head>` in `wwwroot/index.html`: ```html <link href="_content/Syncfusion.Blazor.Themes/material3.css" rel="stylesheet" /> ``` > ⚠️ **Important**: Only reference **one** Syncfusion base theme at a time to avoid style conflicts. ## Theme Studio Workflow 1. Open [Blazor Theme Studio](https://blazor.syncfusion.com/themestudio/?theme=material3) 2. Select a base theme and customize colors with live preview 3. Filter to include only the components used in your app (reduces CSS size) 4. Download the package — includes `.css`, `.scss`, and `settings.json` 5. Copy the CSS to `~/wwwroot/styles/` and reference it in your host page 6. Save `settings.json` to version control for future updates ## SCSS Variable Override Example ```scss /* Custom.scss */ :root { --color-primary-override: 54, 34, 89; } @use 'material3.scss' with ( $primary: var(#{--color-primary-override}) );
在 GitHub 查看