Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/ant-design-blazor/ant-design-icons-blazor
⭐ Ant Design SVG Icons of Blazor
https://github.com/ant-design-blazor/ant-design-icons-blazor
Last synced: about 8 hours ago
JSON representation
⭐ Ant Design SVG Icons of Blazor
- Host: GitHub
- URL: https://github.com/ant-design-blazor/ant-design-icons-blazor
- Owner: ant-design-blazor
- License: mit
- Created: 2020-05-11T10:29:35.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2024-07-07T07:28:17.000Z (4 months ago)
- Last Synced: 2024-09-16T12:29:26.083Z (about 2 months ago)
- Language: C#
- Size: 275 KB
- Stars: 8
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Funding: .github/FUNDING.yml
- License: LICENSE.txt
Awesome Lists containing this project
README
AntDesign Icons for Blazor
## How it works?
Generate Icon components from official ant-design-icons repo with Source Generators.
You can add all icons from https://ant.design/components/icon
## Usage
- Install package
```bash
$ dotnet add package AntDesign.Icons
```- Add `@using AntDesign.Icons` to your `_Imports.razor` file
- We offer two ways to use it.
1. One is the component approach, which can be placed anywhere in the razor template.
```razor
```2. The other is the static method approach, which returns RenderFargment that can be used as an attribute value or as a variable.
```razor
@AlertTwotone.RenderIcon(twoToneColor:["#52c41a", "#398439"])
```They have the same parameters and achieve the same functionality.
### Parameters
## API
| Property | Description | Type | Default Value |
| --- | --- | --- | --- |
| Class | class Name of Icon |string | - |
| Style | Style properties of icon, like fontSize and color| string |
| Spin | Rotate icon with animation | boolean |- |
| Rotate |Rotate by n degrees | int | - |
| TwoToneColor |Only supports the two-tone icon. Specify the primary color.| string[] | - |## Development
- Install the .NET Compiler Platform SDK with VS2022 for debug the Source Generators.
- Set `AntDesign.Icons.Generator` as startup project.
- Press F5 or click `Debug` button on top of VS2022.