feat(plugins): implement CoA Dynamic Plugin Architecture (FV1) in CSM

This commit is contained in:
Дмитрий committed 2026-10-31 09:23:10 +05:00
1 parent c5eac64477
commit 90f93074c2
7 files changed
+1264 -70

No files matched your search

+5 -2
View File
@@ -48,13 +48,13 @@ export interface ServiceStatus {
}
export interface StatusView {
observed: { mysql: ServiceStatus; auth: ServiceStatus; world: ServiceStatus; secondary_world?: ServiceStatus | null };
observed: { mysql: ServiceStatus; auth: ServiceStatus; world: ServiceStatus; secondary_world?: ServiceStatus | null; reborn_world?: ServiceStatus | null };
busy: boolean;
path_exists: boolean;
}
export type RealmMode = "coa" | "wildcard" | "reborn";
export interface RealmProfiles { active: RealmMode; wildcard_created: boolean; reborn_created: boolean; reborn_supported: boolean; supported: boolean; recovery_pending: boolean; simultaneous: boolean; secondary_world_port: number | null; secondary_running: boolean }
export interface RealmProfiles { active: RealmMode; wildcard_created: boolean; reborn_created: boolean; reborn_supported: boolean; supported: boolean; recovery_pending: boolean; simultaneous: boolean; secondary_world_port: number | null; secondary_running: boolean; with_reborn: boolean; reborn_world_port: number | null; reborn_running: boolean }
export interface DatabaseCheck {
realm: RealmMode;
migrations: { id: string; db: string; status: "applied" | "pending" | "failed"; error: string | null }[];
@@ -429,6 +429,7 @@ export interface FriendsStatus {
auth_port: number;
world_port: number;
secondary_world_port?: number | null;
reborn_world_port?: number | null;
}
export interface InternetCheck {
@@ -472,6 +473,7 @@ export const api = {
realmProfiles: (id: string) => invoke<RealmProfiles>("realm_profiles", { id }),
realmSelect: (id: string, mode: RealmMode, restart: boolean) => invoke<RealmProfiles>("realm_select", { id, mode, restart }),
realmSimultaneous: (id: string, enabled: boolean) => invoke<RealmProfiles>("realm_simultaneous", { id, enabled }),
realmWithReborn: (id: string, enabled: boolean) => invoke<RealmProfiles>("realm_with_reborn", { id, enabled }),
checkDatabase: (id: string) => invoke<DatabaseCheck[]>("check_database", { id }),
repairServer: (id: string) => invoke<RepairReport>("repair_server", { id }),
defaultInstallDir: () => invoke<string>("default_install_dir"),
@@ -511,6 +513,7 @@ export const api = {
realmlistActivate: (id: string, profileId: string) => invoke<string[]>("realmlist_activate", { id, profileId }),
modulesList: (id: string) => invoke<ModuleView[]>("modules_list", { id }),
moduleSetEnabled: (id: string, module: string, enabled: boolean) => invoke<void>("module_set_enabled", { id, module, enabled }),
pluginsRepair: (id: string) => invoke<string[]>("plugins_repair", { id }),
moduleSettings: (id: string, module: string) => invoke<ModuleSetting[]>("module_settings", { id, module }),
moduleSaveSettings: (id: string, module: string, changes: Record<string, string>) => invoke<string[]>("module_save_settings", { id, module, changes }),
allSettings: (id: string) => invoke<AllSetting[]>("all_settings", { id }),