@skyvexsoftware/stratos-sdk 0.7.7 → 0.7.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/types/context.d.ts +13 -1
- package/package.json +1 -1
package/dist/types/context.d.ts
CHANGED
|
@@ -229,7 +229,19 @@ export type PluginUIContext = {
|
|
|
229
229
|
get<T>(key: string): T | undefined;
|
|
230
230
|
get<T>(key: string, defaultValue: T): T;
|
|
231
231
|
};
|
|
232
|
-
/**
|
|
232
|
+
/**
|
|
233
|
+
* Real-time bridge between this plugin's background and UI modules.
|
|
234
|
+
*
|
|
235
|
+
* - `on(event, handler)` subscribes to broadcasts the background made via
|
|
236
|
+
* `ctx.ipc.send(event, payload)`. The shell scopes the channel to the
|
|
237
|
+
* current plugin id automatically — pass the leaf event name on both
|
|
238
|
+
* ends. Plugin A's UI cannot receive plugin B's broadcasts.
|
|
239
|
+
* - `off(event, handler)` removes a previously registered handler.
|
|
240
|
+
* - `emit` is intentionally not implemented. Send UI→background traffic
|
|
241
|
+
* through HTTP routes registered via `ctx.server.registerRouter`.
|
|
242
|
+
* - `connected` is always `true` in the renderer; the underlying Electron
|
|
243
|
+
* IPC pipe has no connection lifecycle.
|
|
244
|
+
*/
|
|
233
245
|
socket: {
|
|
234
246
|
connected: boolean;
|
|
235
247
|
emit(event: string, data: unknown): void;
|