Add initial project structure and configuration files for Marechai.App

This commit is contained in:
2025-11-14 01:50:56 +00:00
parent f85dc22bf6
commit cf24356030
50 changed files with 1875 additions and 0 deletions

View File

@@ -0,0 +1,33 @@
using System.Threading.Tasks;
using System.Windows.Input;
using Uno.Extensions.Navigation;
namespace Marechai.App.Presentation;
public partial class MainViewModel : ObservableObject
{
private INavigator _navigator;
[ObservableProperty] private string? name;
public MainViewModel(
IStringLocalizer localizer,
IOptions<AppConfig> appInfo,
INavigator navigator)
{
_navigator = navigator;
Title = "Main";
Title += $" - {localizer["ApplicationName"]}";
Title += $" - {appInfo?.Value?.Environment}";
GoToSecond = new AsyncRelayCommand(GoToSecondView);
}
public string? Title { get; }
public ICommand GoToSecond { get; }
private async Task GoToSecondView()
{
await _navigator.NavigateViewModelAsync<SecondViewModel>(this, data: new Entity(Name!));
}
}