Made sidebar item collection extendable via interface. Refactored settings to system

This commit is contained in:
2025-12-27 23:54:48 +01:00
parent 05c05f1b72
commit ba942b2f8f
7 changed files with 91 additions and 56 deletions

View File

@@ -0,0 +1,17 @@
using System.Diagnostics.CodeAnalysis;
namespace Moonlight.Frontend.Models;
public record SidebarItem
{
public string Name { get; init; }
public string Path { get; init; }
public bool IsExactPath { get; init; }
public string? Group { get; init; }
public int Order { get; init; }
// Used to prevent the IL-Trimming from removing this type as its dynamically assigned a type and we
// need it to work properly
[DynamicallyAccessedMembers(DynamicallyAccessedMemberTypes.All)]
public Type IconType { get; init; }
}