Initial commit
This commit is contained in:
@@ -0,0 +1,32 @@
|
||||
using MudBlazor;
|
||||
|
||||
namespace RobotNet10.MapEditor.Models;
|
||||
|
||||
/// <summary>
|
||||
/// Model for tree item in LayoutTreePanel
|
||||
/// </summary>
|
||||
public class TreeItemModel
|
||||
{
|
||||
public string Id { get; set; } = Guid.NewGuid().ToString();
|
||||
public string Text { get; set; } = "";
|
||||
public string Icon { get; set; } = "";
|
||||
public TreeItemType Type { get; set; }
|
||||
public object? Data { get; set; }
|
||||
public bool IsExpanded { get; set; } = false;
|
||||
public List<TreeItemModel> Children { get; set; } = new();
|
||||
|
||||
// UI Properties
|
||||
public string? BadgeText { get; set; }
|
||||
public Color BadgeColor { get; set; } = Color.Default;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Type of tree item
|
||||
/// </summary>
|
||||
public enum TreeItemType
|
||||
{
|
||||
Layout,
|
||||
Version,
|
||||
Level
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user