feat(bot): ComponentsV2 system/member/group cards
Some checks are pending
Build and push Docker image / .net docker build (push) Waiting to run
.net checks / run .net tests (push) Waiting to run
.net checks / dotnet-format (push) Waiting to run
Build and push Rust service Docker images / rust docker build (push) Waiting to run
rust checks / cargo fmt (push) Waiting to run

This commit is contained in:
Iris System 2025-09-07 10:16:50 +12:00
parent 695d1debf2
commit fbf51b41c1
20 changed files with 600 additions and 18 deletions

View file

@ -16,6 +16,7 @@ public class CoreConfig
public string? SeqLogUrl { get; set; }
public string? DispatchProxyUrl { get; set; }
public string? DispatchProxyToken { get; set; }
public string DashboardBaseUrl { get; set; } = "https://dash.pluralkit.local";
public LogEventLevel ConsoleLogLevel { get; set; } = LogEventLevel.Debug;
public LogEventLevel ElasticLogLevel { get; set; } = LogEventLevel.Information;

View file

@ -22,6 +22,7 @@ public class SystemConfigPatch: PatchObject
public Partial<bool> ProxyErrorMessageEnabled { get; set; }
public Partial<bool> HidDisplaySplit { get; set; }
public Partial<bool> HidDisplayCaps { get; set; }
public Partial<bool> CardShowColorHex { get; set; }
public Partial<string?> NameFormat { get; set; }
public Partial<SystemConfig.HidPadFormat> HidListPadding { get; set; }
public Partial<SystemConfig.ProxySwitchAction> ProxySwitch { get; set; }
@ -41,6 +42,7 @@ public class SystemConfigPatch: PatchObject
.With("hid_display_split", HidDisplaySplit)
.With("hid_display_caps", HidDisplayCaps)
.With("hid_list_padding", HidListPadding)
.With("card_show_color_hex", CardShowColorHex)
.With("proxy_switch", ProxySwitch)
.With("name_format", NameFormat)
);
@ -107,6 +109,9 @@ public class SystemConfigPatch: PatchObject
if (HidListPadding.IsPresent)
o.Add("hid_list_padding", HidListPadding.Value.ToUserString());
if (CardShowColorHex.IsPresent)
o.Add("card_show_color_hex", CardShowColorHex.Value);
if (ProxySwitch.IsPresent)
o.Add("proxy_switch", ProxySwitch.Value.ToUserString());
@ -150,6 +155,9 @@ public class SystemConfigPatch: PatchObject
if (o.ContainsKey("hid_display_caps"))
patch.HidDisplayCaps = o.Value<bool>("hid_display_caps");
if (o.ContainsKey("card_show_color_hex"))
patch.CardShowColorHex = o.Value<bool>("card_show_color_hex");
if (o.ContainsKey("proxy_switch"))
patch.ProxySwitch = o.Value<string>("proxy_switch") switch
{

View file

@ -23,6 +23,7 @@ public class SystemConfig
public bool ProxyErrorMessageEnabled { get; }
public bool HidDisplaySplit { get; }
public bool HidDisplayCaps { get; }
public bool CardShowColorHex { get; }
public HidPadFormat HidListPadding { get; }
public ProxySwitchAction ProxySwitch { get; }
public string NameFormat { get; }
@ -60,6 +61,7 @@ public static class SystemConfigExt
o.Add("hid_display_split", cfg.HidDisplaySplit);
o.Add("hid_display_caps", cfg.HidDisplayCaps);
o.Add("hid_list_padding", cfg.HidListPadding.ToUserString());
o.Add("card_show_color_hex", cfg.CardShowColorHex);
o.Add("proxy_switch", cfg.ProxySwitch.ToUserString());
o.Add("name_format", cfg.NameFormat);