Added server tab provider. Moved power actions to seperate controller
This commit is contained in:
@@ -1,7 +1,22 @@
|
||||
using MoonlightServers.Frontend.UI.Components.Servers.ServerTabs;
|
||||
|
||||
namespace MoonlightServers.Frontend.Models;
|
||||
|
||||
public class ServerTab
|
||||
{
|
||||
public string Path { get; set; }
|
||||
public string Name { get; set; }
|
||||
public string Name { get; private set; }
|
||||
public string Path { get; private set; }
|
||||
public int Priority { get; set; }
|
||||
public Type ComponentType { get; private set; }
|
||||
|
||||
public static ServerTab CreateFromComponent<T>(string name, string path, int priority) where T : BaseServerTab
|
||||
{
|
||||
return new()
|
||||
{
|
||||
Name = name,
|
||||
Path = path,
|
||||
Priority = priority,
|
||||
ComponentType = typeof(T)
|
||||
};
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user