feat: move termix identity into a plugin (C6)

This commit is contained in:
LukeGus committed 2026-09-24 20:50:54 -05:00
1 parent 6e56c90aac
commit 4dbce08379
157 files changed
+20743 -5766

No files matched your search

+15
View File
@@ -530,6 +530,19 @@ export interface PluginWsTarget {
protocols?: string[];
}
/** Where the frontend runs, for a plugin that behaves differently in the desktop app. */
export interface DesktopApi {
/** True inside the Termix desktop app. */
readonly available: boolean;
/**
* The remote server the desktop app is connected to for sync, or null
* outside the desktop app and while it runs standalone.
*/
remoteServerUrl: () => Promise<string | null>;
/** Called when the desktop app connects to or leaves a remote server. */
onRemoteServerChange: (listener: () => void) => Disposer;
}
export interface TermixAppInfo {
readonly pluginId: string;
readonly manifest: PluginManifest;
@@ -629,6 +642,8 @@ export interface TermixApp extends TermixAppInfo {
options?: { origin?: unknown },
) => Promise<PluginWsTarget | null>;
tabs: TabsApi;
/** The desktop app, when the frontend runs in it. */
desktop: DesktopApi;
/** Registered cleanup, run when the plugin is disabled. */
onDispose: (dispose: Disposer) => void;
}