feat: initialize.
This commit is contained in:
13
demo/Ursa.Demo/Pages/VerificationCodeDemo.axaml
Normal file
13
demo/Ursa.Demo/Pages/VerificationCodeDemo.axaml
Normal file
@@ -0,0 +1,13 @@
|
||||
<UserControl xmlns="https://github.com/avaloniaui"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
||||
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
||||
xmlns:u="https://irihi.tech/ursa"
|
||||
mc:Ignorable="d" d:DesignWidth="800" d:DesignHeight="450"
|
||||
x:Class="Ursa.Demo.Pages.VerificationCodeDemo">
|
||||
<StackPanel>
|
||||
<u:VerificationCode CountOfDigit="4" Name="v4"/>
|
||||
<ListBox ItemsSource="{Binding #v4.Digits}"></ListBox>
|
||||
<u:VerificationCode CountOfDigit="6" PasswordChar="*" />
|
||||
</StackPanel>
|
||||
</UserControl>
|
||||
13
demo/Ursa.Demo/Pages/VerificationCodeDemo.axaml.cs
Normal file
13
demo/Ursa.Demo/Pages/VerificationCodeDemo.axaml.cs
Normal file
@@ -0,0 +1,13 @@
|
||||
using Avalonia;
|
||||
using Avalonia.Controls;
|
||||
using Avalonia.Markup.Xaml;
|
||||
|
||||
namespace Ursa.Demo.Pages;
|
||||
|
||||
public partial class VerificationCodeDemo : UserControl
|
||||
{
|
||||
public VerificationCodeDemo()
|
||||
{
|
||||
InitializeComponent();
|
||||
}
|
||||
}
|
||||
@@ -56,6 +56,7 @@ public class MainViewViewModel : ViewModelBase
|
||||
MenuKeys.MenuKeyTwoTonePathIcon => new TwoTonePathIconDemoViewModel(),
|
||||
MenuKeys.MenuKeyThemeToggler => new ThemeTogglerDemoViewModel(),
|
||||
MenuKeys.MenuKeyToolBar => new ToolBarDemoViewModel(),
|
||||
MenuKeys.MenuKeyVerificationCode => new VerificationCodeDemoViewModel(),
|
||||
};
|
||||
}
|
||||
}
|
||||
@@ -42,7 +42,8 @@ public class MenuViewModel: ViewModelBase
|
||||
new() { MenuHeader = "Theme Toggler", Key = MenuKeys.MenuKeyThemeToggler, Status = "New" },
|
||||
new() { MenuHeader = "Timeline", Key = MenuKeys.MenuKeyTimeline, Status = "WIP" },
|
||||
new() { MenuHeader = "TwoTonePathIcon", Key = MenuKeys.MenuKeyTwoTonePathIcon},
|
||||
new() { MenuHeader = "ToolBar", Key = MenuKeys.MenuKeyToolBar, Status = "New" }
|
||||
new() { MenuHeader = "ToolBar", Key = MenuKeys.MenuKeyToolBar, Status = "New" },
|
||||
new() { MenuHeader = "Verification Code", Key = MenuKeys.MenuKeyVerificationCode, Status = "New" },
|
||||
};
|
||||
}
|
||||
}
|
||||
@@ -81,5 +82,6 @@ public static class MenuKeys
|
||||
public const string MenuKeyTwoTonePathIcon = "TwoTonePathIcon";
|
||||
public const string MenuKeyThemeToggler = "ThemeToggler";
|
||||
public const string MenuKeyToolBar = "ToolBar";
|
||||
public const string MenuKeyVerificationCode = "VerificationCode";
|
||||
|
||||
}
|
||||
@@ -0,0 +1,8 @@
|
||||
using CommunityToolkit.Mvvm.ComponentModel;
|
||||
|
||||
namespace Ursa.Demo.ViewModels;
|
||||
|
||||
public class VerificationCodeDemoViewModel: ObservableObject
|
||||
{
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user