https://github.com/lk-code/fluent-maui
a lot of useful components for .NET MAUI projects
https://github.com/lk-code/fluent-maui
Last synced: 5 months ago
JSON representation
a lot of useful components for .NET MAUI projects
- Host: GitHub
- URL: https://github.com/lk-code/fluent-maui
- Owner: lk-code
- License: mit
- Created: 2023-04-20T12:18:50.000Z (about 3 years ago)
- Default Branch: main
- Last Pushed: 2025-02-17T15:42:06.000Z (over 1 year ago)
- Last Synced: 2025-10-02T15:00:00.387Z (9 months ago)
- Language: C#
- Size: 346 KB
- Stars: 6
- Watchers: 1
- Forks: 1
- Open Issues: 7
-
Metadata Files:
- Readme: README.md
- Funding: .github/FUNDING.yml
- License: LICENSE
Awesome Lists containing this project
README
# FluentMAUI

a lot of useful components for .NET MAUI projects
Fluent MAUI consists of several nuget libraries. Each library contains components for a specific purpose.
## FluentMaui.UI
**For examples you can view the sample apps. this can be found at the /samples-directory**
First you need to initialize FluentMaui.UI in your MauiProgram.cs:
`builder.UseFluentUi(options =>`
`{`
`});`
In your App.xaml, add the following lines for the styles:
`xmlns:fmui="clr-namespace:FluentMAUI.UI;assembly=FluentMAUI.UI"`
`...`
``
``
### ToggleButton
`xmlns:fmcontrols="clr-namespace:FluentMAUI.UI.Controls;assembly=FluentMAUI.UI"`
`...`
``
#### access via Event
``
#### access via Binding
``
#### access via Command
you can use the EventToCommandBehavior from .NET MAUI Community Toolkit
``
``
``
**notice:** you can find an example for the EventArgs-Converter (ToggledEventArgsConverter) in the samples-app.
#### ToggleButton Theming
* BackgroundColor: **Color**
* TextColor: **Color**
* CheckedBackgroundColor: **Color**
* CheckedTextColor: **Color**
### WidgetView
The WidgetView is based on the .NET MAUI Border control. You can use it to add any controls as child elements.
`xmlns:fmcontrols="clr-namespace:FluentMAUI.UI.Controls;assembly=FluentMAUI.UI"`
`...`
``
#### WidgetView Theming
* BackgroundStyleType: **BackgroundStyleTypes** (Flat, Gradient) - If the Gradient property is used and the
BackgroundColor property has been set, then a gradient is automatically generated as the background. The gradient is
based on BackgroundColor and becomes darker towards the bottom (15% by default). Alternatively, the background can be
set directly with a brush.
## FluentMaui.Configuration
An easy way to load appsettings into your .NET MAUI app.
Also, besides the primary appsettings.json, there is an option to load appsettings per platform and environment (e.g. *
*appsettings.android.json**, **appsettings.Debug.json** or **appsettings.ios.Release.json**, etc.).
The filename pattern is as follows: **appsettings.{platform}.{environment}.json** (platform and environment are both
optional)
**platforms:**
* maccatalyst
* ios
* android
* winui
**environments:**
* Debug
* Release
### configure
`builder.UseFluentConfiguration(options =>`
`{`
`// LoadAppsettingsFrom-Assembly is optional for ios, macos, winui BUT REQUIRED on android`
`options.LoadAppsettingsFrom = Assembly.GetExecutingAssembly();`
`});`
* **LoadAppsettingsFrom:** Define the assembly where the appsettings are located as resource files (EmbeddedResource).