@urun-sh/core 0.1.47 → 0.1.48
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/{chunk-O7ZS2RQJ.mjs → chunk-DFVMGNRH.mjs} +4 -4
- package/dist/index.d.mts +7 -3
- package/dist/index.d.ts +7 -3
- package/dist/index.js +5 -5
- package/dist/index.mjs +1 -1
- package/dist/internal.d.mts +1 -1
- package/dist/internal.d.ts +1 -1
- package/dist/internal.js +1 -1
- package/dist/internal.mjs +1 -1
- package/dist/{transport-DwP_VpLT.d.mts → transport-C3iRb9nz.d.mts} +41 -1
- package/dist/{transport-DwP_VpLT.d.ts → transport-C3iRb9nz.d.ts} +41 -1
- package/package.json +1 -1
package/dist/internal.mjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as e,b as o,c as r,d as n,e as t,g as s,h as p,i as a}from"./chunk-
|
|
1
|
+
import{a as e,b as o,c as r,d as n,e as t,g as s,h as p,i as a}from"./chunk-DFVMGNRH.mjs";export{e as ChannelMultiplexer,o as DeferredChannelMultiplexer,a as TransportSession,p as decodeDocSyncFrame,s as encodeDocSyncFrame,t as ensureNodeWebRTC,r as isNodeRuntime,n as nodeMediasoupHandlerName};
|
|
@@ -1,5 +1,37 @@
|
|
|
1
1
|
|
|
2
2
|
|
|
3
|
+
interface MediaChunkSource {
|
|
4
|
+
|
|
5
|
+
start(onChunk: (chunk: Uint8Array) => void, onEnd: () => void): void;
|
|
6
|
+
|
|
7
|
+
stop(): void;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
interface MediaChunkBinding {
|
|
11
|
+
|
|
12
|
+
track(): MediaStreamTrack | null;
|
|
13
|
+
|
|
14
|
+
onTrack(cb: (track: MediaStreamTrack | null) => void): () => void;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
type MediaChunkSourceFactory = (binding: MediaChunkBinding) => MediaChunkSource;
|
|
18
|
+
|
|
19
|
+
type ChunkReadable = ReadableStream<Uint8Array> & AsyncIterable<Uint8Array>;
|
|
20
|
+
|
|
21
|
+
interface StreamChunkOptions {
|
|
22
|
+
|
|
23
|
+
source?: MediaChunkSourceFactory;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
interface MediaRecorderChunkSourceOptions {
|
|
27
|
+
|
|
28
|
+
mimeType?: string;
|
|
29
|
+
|
|
30
|
+
timesliceMs?: number;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
declare function mediaRecorderChunkSource(binding: MediaChunkBinding, options?: MediaRecorderChunkSourceOptions): MediaChunkSource;
|
|
34
|
+
|
|
3
35
|
type TransportState = 'connecting' | 'connected' | 'reconnecting' | 'renegotiating' | 'disconnected' | 'failed';
|
|
4
36
|
|
|
5
37
|
type SessionPhaseName = 'idle' | 'queued' | 'provisioning' | 'connecting' | 'live' | 'error' | 'ended';
|
|
@@ -190,6 +222,10 @@ interface SessionStream {
|
|
|
190
222
|
|
|
191
223
|
seek(target: number | 'live'): Promise<void>;
|
|
192
224
|
|
|
225
|
+
chunks(options?: StreamChunkOptions): ChunkReadable;
|
|
226
|
+
|
|
227
|
+
onSeeked(handler: (target: number | 'live') => void): () => void;
|
|
228
|
+
|
|
193
229
|
on(event: 'track', handler: (track: MediaStreamTrack | null) => void): () => void;
|
|
194
230
|
|
|
195
231
|
messages(): AsyncIterable<unknown>;
|
|
@@ -337,6 +373,8 @@ interface TransportEvents {
|
|
|
337
373
|
stateChange: (state: TransportState) => void;
|
|
338
374
|
|
|
339
375
|
phase: (phase: SessionPhase) => void;
|
|
376
|
+
|
|
377
|
+
seeked: (stream: string, target: number | 'live') => void;
|
|
340
378
|
}
|
|
341
379
|
interface SessionStartOptions {
|
|
342
380
|
app?: string;
|
|
@@ -453,6 +491,8 @@ declare class TransportSession {
|
|
|
453
491
|
private _flushStreamSubscribes;
|
|
454
492
|
private _handleMessage;
|
|
455
493
|
|
|
494
|
+
private _onStreamSeeked;
|
|
495
|
+
|
|
456
496
|
private _onStatus;
|
|
457
497
|
private _onRouterCapabilities;
|
|
458
498
|
private _onCreateRecvTransport;
|
|
@@ -488,4 +528,4 @@ declare class TransportSession {
|
|
|
488
528
|
private _emitError;
|
|
489
529
|
}
|
|
490
530
|
|
|
491
|
-
export { type App as A, type ChannelEndpoint as C, DeferredChannelMultiplexer as D, type Layer as L, type RequestOptions as R, type SceneContext as S, TransportSession as T, type AppOptions as a, type AttachOptions as b, type ChannelMessage as c, ChannelMultiplexer as d, type ChannelName as e, type
|
|
531
|
+
export { type App as A, encodeDocSyncFrame as B, type ChannelEndpoint as C, DeferredChannelMultiplexer as D, mediaRecorderChunkSource as E, type Layer as L, type MediaChunkBinding as M, type RequestOptions as R, type SceneContext as S, TransportSession as T, type AppOptions as a, type AttachOptions as b, type ChannelMessage as c, ChannelMultiplexer as d, type ChannelName as e, type ChunkReadable as f, type LayoutConfig as g, type LayoutContext as h, type MediaChunkSource as i, type MediaChunkSourceFactory as j, type MediaRecorderChunkSourceOptions as k, type RequestStreamOptions as l, type SceneGraph as m, type Session as n, type SessionDocument as o, type SessionPhase as p, type SessionPhaseName as q, type SessionStartOptions as r, type SessionStream as s, type SessionText as t, type Store as u, type StoreOptions as v, type StreamChunkOptions as w, type TransportSessionOptions as x, type TransportState as y, decodeDocSyncFrame as z };
|
|
@@ -1,5 +1,37 @@
|
|
|
1
1
|
|
|
2
2
|
|
|
3
|
+
interface MediaChunkSource {
|
|
4
|
+
|
|
5
|
+
start(onChunk: (chunk: Uint8Array) => void, onEnd: () => void): void;
|
|
6
|
+
|
|
7
|
+
stop(): void;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
interface MediaChunkBinding {
|
|
11
|
+
|
|
12
|
+
track(): MediaStreamTrack | null;
|
|
13
|
+
|
|
14
|
+
onTrack(cb: (track: MediaStreamTrack | null) => void): () => void;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
type MediaChunkSourceFactory = (binding: MediaChunkBinding) => MediaChunkSource;
|
|
18
|
+
|
|
19
|
+
type ChunkReadable = ReadableStream<Uint8Array> & AsyncIterable<Uint8Array>;
|
|
20
|
+
|
|
21
|
+
interface StreamChunkOptions {
|
|
22
|
+
|
|
23
|
+
source?: MediaChunkSourceFactory;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
interface MediaRecorderChunkSourceOptions {
|
|
27
|
+
|
|
28
|
+
mimeType?: string;
|
|
29
|
+
|
|
30
|
+
timesliceMs?: number;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
declare function mediaRecorderChunkSource(binding: MediaChunkBinding, options?: MediaRecorderChunkSourceOptions): MediaChunkSource;
|
|
34
|
+
|
|
3
35
|
type TransportState = 'connecting' | 'connected' | 'reconnecting' | 'renegotiating' | 'disconnected' | 'failed';
|
|
4
36
|
|
|
5
37
|
type SessionPhaseName = 'idle' | 'queued' | 'provisioning' | 'connecting' | 'live' | 'error' | 'ended';
|
|
@@ -190,6 +222,10 @@ interface SessionStream {
|
|
|
190
222
|
|
|
191
223
|
seek(target: number | 'live'): Promise<void>;
|
|
192
224
|
|
|
225
|
+
chunks(options?: StreamChunkOptions): ChunkReadable;
|
|
226
|
+
|
|
227
|
+
onSeeked(handler: (target: number | 'live') => void): () => void;
|
|
228
|
+
|
|
193
229
|
on(event: 'track', handler: (track: MediaStreamTrack | null) => void): () => void;
|
|
194
230
|
|
|
195
231
|
messages(): AsyncIterable<unknown>;
|
|
@@ -337,6 +373,8 @@ interface TransportEvents {
|
|
|
337
373
|
stateChange: (state: TransportState) => void;
|
|
338
374
|
|
|
339
375
|
phase: (phase: SessionPhase) => void;
|
|
376
|
+
|
|
377
|
+
seeked: (stream: string, target: number | 'live') => void;
|
|
340
378
|
}
|
|
341
379
|
interface SessionStartOptions {
|
|
342
380
|
app?: string;
|
|
@@ -453,6 +491,8 @@ declare class TransportSession {
|
|
|
453
491
|
private _flushStreamSubscribes;
|
|
454
492
|
private _handleMessage;
|
|
455
493
|
|
|
494
|
+
private _onStreamSeeked;
|
|
495
|
+
|
|
456
496
|
private _onStatus;
|
|
457
497
|
private _onRouterCapabilities;
|
|
458
498
|
private _onCreateRecvTransport;
|
|
@@ -488,4 +528,4 @@ declare class TransportSession {
|
|
|
488
528
|
private _emitError;
|
|
489
529
|
}
|
|
490
530
|
|
|
491
|
-
export { type App as A, type ChannelEndpoint as C, DeferredChannelMultiplexer as D, type Layer as L, type RequestOptions as R, type SceneContext as S, TransportSession as T, type AppOptions as a, type AttachOptions as b, type ChannelMessage as c, ChannelMultiplexer as d, type ChannelName as e, type
|
|
531
|
+
export { type App as A, encodeDocSyncFrame as B, type ChannelEndpoint as C, DeferredChannelMultiplexer as D, mediaRecorderChunkSource as E, type Layer as L, type MediaChunkBinding as M, type RequestOptions as R, type SceneContext as S, TransportSession as T, type AppOptions as a, type AttachOptions as b, type ChannelMessage as c, ChannelMultiplexer as d, type ChannelName as e, type ChunkReadable as f, type LayoutConfig as g, type LayoutContext as h, type MediaChunkSource as i, type MediaChunkSourceFactory as j, type MediaRecorderChunkSourceOptions as k, type RequestStreamOptions as l, type SceneGraph as m, type Session as n, type SessionDocument as o, type SessionPhase as p, type SessionPhaseName as q, type SessionStartOptions as r, type SessionStream as s, type SessionText as t, type Store as u, type StoreOptions as v, type StreamChunkOptions as w, type TransportSessionOptions as x, type TransportState as y, decodeDocSyncFrame as z };
|