@ikonai/sdk 1.0.7 → 1.0.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/assets/{audio-capture-worker-kpORDYGU.js → audio-capture-worker-D0tD-mzj.js} +105 -80
- package/assets/{audio-playback-worker-DPybcm1k.js → audio-playback-worker-CM2aCt54.js} +295 -263
- package/assets/{protocol-worker-DIKCgk1A.js → protocol-worker-CH5R2dxZ.js} +116 -93
- package/assets/{video-capture-worker-DP3lFDjq.js → video-capture-worker-DZZ0ggvo.js} +32 -32
- package/assets/{video-playback-worker-qauTQ7Et.js → video-playback-worker-C7sQMgD-.js} +9 -9
- package/client/ikon-client-config.d.ts +0 -14
- package/functions/function-registry.d.ts +32 -1
- package/index.d.ts +4 -3
- package/index.js +1385 -1280
- package/package.json +1 -1
- package/utils/debug-mode.d.ts +14 -0
- package/utils/logger.d.ts +17 -0
package/package.json
CHANGED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Initialize debug mode based on URL params (?debug=true).
|
|
3
|
+
* Call this early in SDK initialization.
|
|
4
|
+
* Returns true if debug mode is enabled.
|
|
5
|
+
*/
|
|
6
|
+
export declare function initializeDebugMode(): boolean;
|
|
7
|
+
/**
|
|
8
|
+
* Check if debug mode is currently enabled.
|
|
9
|
+
*/
|
|
10
|
+
export declare function isDebugModeEnabled(): boolean;
|
|
11
|
+
/**
|
|
12
|
+
* Enable debug mode programmatically (e.g., from server's GlobalState.DebugMode).
|
|
13
|
+
*/
|
|
14
|
+
export declare function enableDebugMode(): void;
|
package/utils/logger.d.ts
CHANGED
|
@@ -22,6 +22,17 @@ export interface LogEntry {
|
|
|
22
22
|
* The sink can decide what to do with the log (e.g., send to backend).
|
|
23
23
|
*/
|
|
24
24
|
export type LogSink = (entry: LogEntry) => void;
|
|
25
|
+
/**
|
|
26
|
+
* Log event listener type for subscribing to specific log levels.
|
|
27
|
+
*/
|
|
28
|
+
export type LogEventListener = (entry: LogEntry) => void;
|
|
29
|
+
/**
|
|
30
|
+
* Options for subscribing to log events.
|
|
31
|
+
*/
|
|
32
|
+
export interface LogEventSubscriptionOptions {
|
|
33
|
+
/** Minimum log level to receive (default: LogLevel.WARN) */
|
|
34
|
+
minLevel?: LogLevel;
|
|
35
|
+
}
|
|
25
36
|
/**
|
|
26
37
|
* Set the minimum log level for console output.
|
|
27
38
|
*/
|
|
@@ -40,6 +51,12 @@ export declare function setLogSink(sink: LogSink | null): void;
|
|
|
40
51
|
* Get the current log sink.
|
|
41
52
|
*/
|
|
42
53
|
export declare function getLogSink(): LogSink | null;
|
|
54
|
+
/**
|
|
55
|
+
* Subscribe to log events.
|
|
56
|
+
* By default, subscribes to WARN and ERROR level logs.
|
|
57
|
+
* Returns an unsubscribe function.
|
|
58
|
+
*/
|
|
59
|
+
export declare function subscribeToLogEvents(listener: LogEventListener, options?: LogEventSubscriptionOptions): () => void;
|
|
43
60
|
/**
|
|
44
61
|
* Logger interface with component name.
|
|
45
62
|
*/
|