@advwebrec/grainloading 0.5.1 → 0.5.3
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/DISCLOSURE +19 -0
- package/LICENSE +661 -0
- package/README.md +69 -5
- package/dist/bundle/client.js +1 -1
- package/dist/bundle/sw-stub.js +1 -1
- package/dist/bundle/sw.js +1 -1
- package/dist/types/index.d.ts +24 -1
- package/package.json +15 -1
package/dist/types/index.d.ts
CHANGED
|
@@ -13,6 +13,12 @@ export interface FirestoreSignalConfig {
|
|
|
13
13
|
ttlSeconds?: number;
|
|
14
14
|
}
|
|
15
15
|
|
|
16
|
+
export interface GoodputMonitorOptions {
|
|
17
|
+
minBytes?: number;
|
|
18
|
+
minSampleMs?: number;
|
|
19
|
+
maxGoodputMbps?: number;
|
|
20
|
+
}
|
|
21
|
+
|
|
16
22
|
export interface YuriRTCConfig {
|
|
17
23
|
firebase: {
|
|
18
24
|
apiKey: string;
|
|
@@ -28,6 +34,15 @@ export interface YuriRTCConfig {
|
|
|
28
34
|
rtdb?: RtdbSignalConfig;
|
|
29
35
|
firestore?: FirestoreSignalConfig;
|
|
30
36
|
};
|
|
37
|
+
recovery?: {
|
|
38
|
+
/** Durable module sources used by service-worker-injected documents. */
|
|
39
|
+
clientUrls?: string[];
|
|
40
|
+
};
|
|
41
|
+
transport?: {
|
|
42
|
+
adaptiveTcp?: GoodputMonitorOptions & {
|
|
43
|
+
enabled?: boolean;
|
|
44
|
+
};
|
|
45
|
+
};
|
|
31
46
|
}
|
|
32
47
|
|
|
33
48
|
/** Compatibility type retained for existing consumers. */
|
|
@@ -42,10 +57,18 @@ export interface ConnectionDiagnostics {
|
|
|
42
57
|
signalElapsedMs: number;
|
|
43
58
|
}
|
|
44
59
|
|
|
60
|
+
export interface ConnectionOptions {
|
|
61
|
+
transport?: "auto" | "tcp";
|
|
62
|
+
}
|
|
63
|
+
|
|
45
64
|
export declare class YuriRTCClient {
|
|
46
65
|
constructor(config: YuriRTCConfig, shellPath?: string);
|
|
47
|
-
connect(
|
|
66
|
+
connect(
|
|
67
|
+
registration?: ServiceWorkerRegistration,
|
|
68
|
+
options?: ConnectionOptions
|
|
69
|
+
): Promise<ConnectionDiagnostics>;
|
|
48
70
|
onDisconnect(listener: (reason: string) => void): () => void;
|
|
71
|
+
onAdaptiveTcpSuggested(listener: () => void): () => void;
|
|
49
72
|
request(
|
|
50
73
|
url: string,
|
|
51
74
|
init?: { method?: string; headers?: HeadersInit }
|
package/package.json
CHANGED
|
@@ -1,12 +1,26 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@advwebrec/grainloading",
|
|
3
|
-
"version": "0.5.
|
|
3
|
+
"version": "0.5.3",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "YuriRTC browser client and service worker transport.",
|
|
6
6
|
"license": "AGPL-3.0-only",
|
|
7
|
+
"contentPolicy": {
|
|
8
|
+
"class": "dual-use"
|
|
9
|
+
},
|
|
10
|
+
"repository": {
|
|
11
|
+
"type": "git",
|
|
12
|
+
"url": "git+https://github.com/EDUrocks-Group/YuriRTC.git",
|
|
13
|
+
"directory": "packages/loader"
|
|
14
|
+
},
|
|
15
|
+
"homepage": "https://github.com/EDUrocks-Group/YuriRTC#readme",
|
|
16
|
+
"bugs": {
|
|
17
|
+
"url": "https://github.com/EDUrocks-Group/YuriRTC/issues"
|
|
18
|
+
},
|
|
7
19
|
"main": "./dist/bundle/client.js",
|
|
8
20
|
"types": "./dist/types/index.d.ts",
|
|
9
21
|
"files": [
|
|
22
|
+
"DISCLOSURE",
|
|
23
|
+
"LICENSE",
|
|
10
24
|
"dist/bundle/client.js",
|
|
11
25
|
"dist/bundle/sw.js",
|
|
12
26
|
"dist/bundle/sw-stub.js",
|