Skip to content

🚀 Maui.Switch #138

@Strypper

Description

@Strypper

Preview

Original Link

License: MIT
Build
FOSSA Status
Codacy Badge

This is a switch/ toggle control that would allow you to create any style switch you'd like.

This component is built on top/of this great library - https://github.com/Phenek/Global.InputForms. Fixes a few issues, adds more options for styling, and improved accessibility.

Take a look at the demo app included in this project -

Public API Changes

<?xml version="1.0" encoding="utf-8" ?>
<ContentPage x:Class="App.MainPage"
             xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
             xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
             xmlns:controls="clr-namespace:App.Controls;assembly=App"
             Padding="{StaticResource PagePadding}">
    <ContentPage.Content>
        <VerticalStackLayout Spacing="20" VerticalOptions="Center">
            <controls:CustomButton Clicked="CustomSwitchBtn_Clicked" Text="CustomSwitch examples" />
            <controls:CustomButton Clicked="SwitchViewBtn_Clicked" Text="SwitchView examples" />
            <controls:CustomButton Clicked="AccessibilityBtn_Clicked" Text="Accessiblity tests" />
            <controls:CustomButton Clicked="PanGestureBtn_Clicked" Text="PanGesture tests" />
        </VerticalStackLayout>
    </ContentPage.Content>
</ContentPage>

Intended Use-Case

Replace the boring built-in MAUI toggle switch for better UI and customizations.

Metadata

Metadata

Assignees

Labels

built-in 🧩Already in the frameworkcommunity 🤝Controls or libraries that came from github communityeffort/mediumMedium amount of work, 4h to 16h actionlevel/normal 🙂In comfort zone, little research and may require using built-in features, but no RnDnew feature 🚀New feature addition

Projects

Status

In Progress

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions