using AuroraDesk.Presentation.ViewModels.Base;
using ReactiveUI;
namespace AuroraDesk.Presentation.ViewModels.Pages;
///
/// 设置页面ViewModel
///
public class SettingsPageViewModel : RoutableViewModel
{
private bool _darkMode = false;
private string _language = "zh-CN";
private bool _notifications = true;
private int _refreshInterval = 30;
///
/// 构造函数
///
/// 宿主 Screen
public SettingsPageViewModel(IScreen hostScreen) : base(hostScreen, "Settings")
{
}
///
/// 深色模式
///
public bool DarkMode
{
get => _darkMode;
set => this.RaiseAndSetIfChanged(ref _darkMode, value);
}
///
/// 语言设置
///
public string Language
{
get => _language;
set => this.RaiseAndSetIfChanged(ref _language, value);
}
///
/// 通知设置
///
public bool Notifications
{
get => _notifications;
set => this.RaiseAndSetIfChanged(ref _notifications, value);
}
///
/// 刷新间隔(秒)
///
public int RefreshInterval
{
get => _refreshInterval;
set => this.RaiseAndSetIfChanged(ref _refreshInterval, value);
}
}