mirror of
https://github.com/wwiinnddyy/LanMountainDesktop.git
synced 2026-06-22 00:54:26 +08:00
settings_re4
This commit is contained in:
@@ -0,0 +1,57 @@
|
||||
using System.Collections.Generic;
|
||||
using System.Collections.ObjectModel;
|
||||
using Avalonia.Controls;
|
||||
using FluentIcons.Common;
|
||||
|
||||
namespace LanMountainDesktop.ViewModels;
|
||||
|
||||
public sealed class ComponentLibraryWindowViewModel : ViewModelBase
|
||||
{
|
||||
public string Title { get; set; } = "Widgets";
|
||||
|
||||
public ObservableCollection<ComponentLibraryCategoryViewModel> Categories { get; } = [];
|
||||
|
||||
public ObservableCollection<ComponentLibraryItemViewModel> Components { get; } = [];
|
||||
}
|
||||
|
||||
public sealed class ComponentLibraryCategoryViewModel
|
||||
{
|
||||
public ComponentLibraryCategoryViewModel(
|
||||
string id,
|
||||
string title,
|
||||
Symbol icon,
|
||||
IReadOnlyList<ComponentLibraryItemViewModel> components)
|
||||
{
|
||||
Id = id;
|
||||
Title = title;
|
||||
Icon = icon;
|
||||
Components = components;
|
||||
}
|
||||
|
||||
public string Id { get; }
|
||||
|
||||
public string Title { get; }
|
||||
|
||||
public Symbol Icon { get; }
|
||||
|
||||
public IReadOnlyList<ComponentLibraryItemViewModel> Components { get; }
|
||||
}
|
||||
|
||||
public sealed class ComponentLibraryItemViewModel
|
||||
{
|
||||
public ComponentLibraryItemViewModel(
|
||||
string componentId,
|
||||
string displayName,
|
||||
Control? previewControl)
|
||||
{
|
||||
ComponentId = componentId;
|
||||
DisplayName = displayName;
|
||||
PreviewControl = previewControl;
|
||||
}
|
||||
|
||||
public string ComponentId { get; }
|
||||
|
||||
public string DisplayName { get; }
|
||||
|
||||
public Control? PreviewControl { get; }
|
||||
}
|
||||
1299
LanMountainDesktop/ViewModels/SettingsViewModels.cs
Normal file
1299
LanMountainDesktop/ViewModels/SettingsViewModels.cs
Normal file
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user