https://github.com/tsjdev-apps/controlslib-maui
.NET MAUI Controls Library with custom controls
https://github.com/tsjdev-apps/controlslib-maui
Last synced: 5 months ago
JSON representation
.NET MAUI Controls Library with custom controls
- Host: GitHub
- URL: https://github.com/tsjdev-apps/controlslib-maui
- Owner: tsjdev-apps
- License: mit
- Created: 2023-10-14T18:21:43.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2025-07-14T20:11:17.000Z (11 months ago)
- Last Synced: 2025-09-30T09:54:34.688Z (9 months ago)
- Language: C#
- Size: 422 KB
- Stars: 1
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Controls Library for .NET MAUI
This repository contains some custom made controls for your .NET MAUI application.
This library is currently under development and for the moment there is a `HyperlinkLabel`, an `InitialsControl`, a `RatingControl`, and a `StaticChipControl` available.
## Installation
Install the package via [NuGet](https://www.nuget.org/packages/tsjdevapps.MauiControlsLib).
[](https://www.nuget.org/packages/tsjdevapps.MauiControlsLib)
## Initialization
Open the class `MauiProgram` and call `UseMauiControlsLib()` on the `MauiAppBuilder`.
```csharp
MauiAppBuilder builder = MauiApp.CreateBuilder();
builder
.UseMauiApp()
.UseMauiControlsLib() // <--
.ConfigureFonts(fonts =>
{
fonts.AddFont("OpenSans-Regular.ttf", "OpenSansRegular");
fonts.AddFont("OpenSans-Semibold.ttf", "OpenSansSemibold");
});
return builder.Build();
```
In order to make use of the control within XAML you can use this namespace:
```xml
xmlns:controls="http://www.tsjdev-apps.de/controls/maui"
```
## Available Controls
### HyperlinkLabel
You can use the `HyperlinkLabel` in your .NET MAUI application to show a simple label, which will open a website on a tap.
The following table explains all the available properties and their default value.
| **name** | **type** | **default value** | **description** |
|-|-|-|-|
| `Url` | `string` | `null` | The url which should be opened |
*Screenshot of `HyperlinkLabel` on **Android***

*Screenshot of `HyperlinkLabel` on **Windows***

### InitialsControl
You can use the `InitialsControl` in your .NET MAUI application to show a round badge with the initials of a person.
The following table explains all the available properties and their default value.
| **name** | **type** | **default value** | **description** |
|-|-|-|-|
| `DefaultBackgroundColor` | `Color` | `Colors.LightGray` | Indicates the default background color if no `name` is available |
| `TextColorLight` | `Color` | `Colors.White` | Indicates the light text color |
| `TextColorDark` | `Color` | `Colors.Black` | Indicates the dark text color |
| `Name` | `string` | `string.Empty` | Indicates the name to take the initials from |
| `Size` | `ControlSize` | `ControlSize.Small` | Indicates the size of the control |
*Screenshot of `InitialsControl` on **Android***

*Screenshot of `InitialsControl` on **Windows***

### RatingControl
You can use the `RatingControl` in your .NET MAUI application.
The following table explains all the available properties and their default value.
| **name** | **type** | **default value** | **description** |
|-|-|-|-|
| `Amount` | `int` | `5` | Indicates the number of rating items to be displayed |
| `CurrentValue` | `float` | `2.5f` | Indicates the current rating value to be displayed |
| `ItemSize` | `float` | `24f` | Indicates the size of each rating item |
| `ItemSpacing` | `float` | `6f` | Indicates the spacing between each rating item. |
| `FillColor` | `Color` | `Colors.Yellow` | Indicates the fill color to be used for each rating item |
| `UnfillColor` | `Color` | `Colors.LightGray` | Indicates the unfill color to be used for each rating item |
| `Path` | `string` | `` | Indicates the path used to draw each rating item |
*Screenshot of `RatingControl` on **Android***

*Screenshot of `RatingControl` on **Windows***

### StaticChipControl
You can use the `StaticChipControl` in your .NET MAUI application.
The following table explains all the available properties and their default value.
| **name** | **type** | **default value** | **description** |
|-|-|-|-|
| `Text` | `string` | `string.Empty` | Indicates the text of the chip to be displayed |
| `Color` | `Color` | `Colors.LightGray` | Indicates the background color of the chip |
| `TextColor` | `Color` | `Colors.Black` | Indicates the text color of the text |
| `ImageSource` | `ImageSource` | `null` | Indicates the icon of the chip |
*Screenshot of `StaticChipControl` on **Android***

*Screenshot of `StaticChipControl` on **Windows***

## Buy Me A Coffee
I appreciate any form of support to keep my *Open Source* activities going.
Whatever you decide, be it reading and sharing my blog posts, using my NuGet packages or buying me a coffee/book, thank you ❤️.
[](https://www.buymeacoffee.com/tsjdevapps)
## Contributing
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.
## License
[MIT](https://choosealicense.com/licenses/mit/)