trtc-sdk-v5 5.20.2-beta.6 → 5.20.2-beta.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.
@@ -1,5 +1,5 @@
1
1
  {
2
- "sdk": "5.20.2-beta.6",
2
+ "sdk": "5.20.2-beta.8",
3
3
  "pdfjs": "5.7.284",
4
4
  "pptSdk": "1.0.0",
5
5
  "sha256": {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "trtc-sdk-v5",
3
- "version": "5.20.2-beta.6",
3
+ "version": "5.20.2-beta.8",
4
4
  "description": "Tencent Cloud RTC SDK for Web",
5
5
  "main": "trtc.js",
6
6
  "types": "index.d.ts",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rtc-plugin/audio-player",
3
- "version": "5.20.2-beta.6",
3
+ "version": "5.20.2-beta.8",
4
4
  "description": "TRTC Web SDK AudioPlayer plugin - unified audio player supporting PCM, URL, and Track sources",
5
5
  "main": "./audio-player.esm.js",
6
6
  "module": "./audio-player.esm.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rtc-plugin/cdn-streaming",
3
- "version": "5.20.2-beta.6",
3
+ "version": "5.20.2-beta.8",
4
4
  "description": "TRTC Web SDK 5.x CDN streaming plugin",
5
5
  "main": "./cdn-streaming.esm.js",
6
6
  "module": "./cdn-streaming.esm.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rtc-plugin/chorus",
3
- "version": "5.20.2-beta.6",
3
+ "version": "5.20.2-beta.8",
4
4
  "description": "TRTC Web SDK 5.x Chorus plugin",
5
5
  "main": "./chorus.esm.js",
6
6
  "module": "./chorus.esm.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rtc-plugin/cross-room",
3
- "version": "5.20.2-beta.6",
3
+ "version": "5.20.2-beta.8",
4
4
  "description": "TRTC Web SDK 5.x Cross Room plugin",
5
5
  "main": "./cross-room.esm.js",
6
6
  "module": "./cross-room.esm.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rtc-plugin/custom-encryption",
3
- "version": "5.20.2-beta.6",
3
+ "version": "5.20.2-beta.8",
4
4
  "main": "./custom-encryption.esm.js",
5
5
  "module": "./custom-encryption.esm.js",
6
6
  "types": "./custom-encryption.esm.d.ts"
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rtc-plugin/device-detector",
3
- "version": "5.20.2-beta.6",
3
+ "version": "5.20.2-beta.8",
4
4
  "description": "TRTC Web SDK 5.x device detector plugin",
5
5
  "main": "./device-detector.esm.js",
6
6
  "module": "./device-detector.esm.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rtc-plugin/lebplayer",
3
- "version": "5.20.2-beta.6",
3
+ "version": "5.20.2-beta.8",
4
4
  "description": "TRTC Web SDK 5.x LEBPlayer plugin",
5
5
  "main": "./lebplayer.esm.js",
6
6
  "module": "./lebplayer.esm.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rtc-plugin/realtime-transcriber",
3
- "version": "5.20.2-beta.6",
3
+ "version": "5.20.2-beta.8",
4
4
  "description": "TRTC Web SDK 5.x Realtime Transcriber plugin",
5
5
  "main": "./realtime-transcriber.esm.js",
6
6
  "module": "./realtime-transcriber.esm.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rtc-plugin/small-stream-auto-switcher",
3
- "version": "5.20.2-beta.6",
3
+ "version": "5.20.2-beta.8",
4
4
  "description": "",
5
5
  "main": "./small-stream-auto-switcher.esm.js",
6
6
  "keywords": [],
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rtc-plugin/video-decoder",
3
- "version": "5.20.2-beta.6",
3
+ "version": "5.20.2-beta.8",
4
4
  "description": "Video decoder plugin for TRTC",
5
5
  "main": "./video-decoder.esm.js",
6
6
  "module": "./video-decoder.esm.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rtc-plugin/basic-beauty",
3
- "version": "5.20.2-beta.6",
3
+ "version": "5.20.2-beta.8",
4
4
  "description": "TRTC Web SDK 5.x basic-beauty plugin",
5
5
  "main": "./basic-beauty.esm.js",
6
6
  "module": "./basic-beauty.esm.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rtc-plugin/beauty",
3
- "version": "5.20.2-beta.6",
3
+ "version": "5.20.2-beta.8",
4
4
  "description": "TRTC Web SDK 5.x beauty plugin",
5
5
  "main": "./beauty.esm.js",
6
6
  "module": "./beauty.esm.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rtc-plugin/face-detection",
3
- "version": "5.20.2-beta.6",
3
+ "version": "5.20.2-beta.8",
4
4
  "description": "TRTC Web SDK 5.x face detection plugin",
5
5
  "main": "./face-detection.esm.js",
6
6
  "module": "./face-detection.esm.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rtc-plugin/video-mixer",
3
- "version": "5.20.2-beta.6",
3
+ "version": "5.20.2-beta.8",
4
4
  "description": "TRTC Web SDK 5.x videoMixer plugin",
5
5
  "main": "./video-mixer.esm.js",
6
6
  "module": "./video-mixer.esm.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rtc-plugin/virtual-background",
3
- "version": "5.20.2-beta.6",
3
+ "version": "5.20.2-beta.8",
4
4
  "description": "TRTC Web SDK 5.x virtual background plugin",
5
5
  "main": "./virtual-background.esm.js",
6
6
  "module": "./virtual-background.esm.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rtc-plugin/watermark",
3
- "version": "5.20.2-beta.6",
3
+ "version": "5.20.2-beta.8",
4
4
  "description": "TRTC Web SDK 5.x watermark plugin",
5
5
  "main": "./watermark.esm.js",
6
6
  "module": "./watermark.esm.js",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rtc-plugin/voice-changer",
3
- "version": "5.20.2-beta.6",
3
+ "version": "5.20.2-beta.8",
4
4
  "description": "",
5
5
  "main": "./voice-changer.esm.js",
6
6
  "keywords": [],
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rtc-plugin/whiteboard",
3
- "version": "5.20.2-beta.6",
3
+ "version": "5.20.2-beta.8",
4
4
  "description": "TRTC Web SDK Whiteboard plugin",
5
5
  "main": "./whiteboard.esm.js",
6
6
  "module": "./whiteboard.esm.js",
@@ -85,6 +85,13 @@ export enum WhiteboardEvent {
85
85
  */
86
86
  UNAVAILABLE = 'unavailable',
87
87
  ERROR = 'error',
88
+ /**
89
+ * Host only: a window's content (image / video / PDF / PPT) failed to load —
90
+ * too large, corrupt, unsupported, or unreachable. The window itself stays
91
+ * and can still be annotated, it just has no backdrop. Kept separate from
92
+ * `ERROR`: that one means the session is gone.
93
+ */
94
+ CONTENT_LOAD_ERROR = 'content-load-error',
88
95
  /** Host + Guest: undo availability changed. */
89
96
  UNDO_STATE_CHANGED = 'undo-state-changed',
90
97
  /** Host + Guest: redo availability changed. */
@@ -141,6 +148,34 @@ export interface WhiteboardUnavailableInfo {
141
148
  reason: WhiteboardUnavailableReason;
142
149
  }
143
150
 
151
+ /**
152
+ * Reasons carried by `WhiteboardEvent.CONTENT_LOAD_ERROR`.
153
+ *
154
+ * - `invalid-url`: the URL is malformed (not a full http(s) / blob address,
155
+ * bad host, or a disallowed protocol); rejected before any
156
+ * request is made.
157
+ * - `file-too-large`: the file exceeds the size cap.
158
+ * - `corrupt`: the file is damaged or cannot be decoded.
159
+ * - `unsupported`: unsupported format, or the parser component (pdf.js /
160
+ * the PPT SDK) is not deployed.
161
+ * - `network`: the resource could not be fetched (non-2xx, CORS, offline).
162
+ * - `unknown`: none of the above.
163
+ */
164
+ export type WhiteboardContentLoadReason =
165
+ | 'invalid-url' | 'file-too-large' | 'corrupt' | 'unsupported' | 'network' | 'unknown';
166
+
167
+ /** Payload carried by `CONTENT_LOAD_ERROR`. */
168
+ export interface WhiteboardContentLoadErrorInfo {
169
+ /** Id of the window whose content failed to load; `'m'` for the main board. */
170
+ winId: string;
171
+ /** Content type: `'image' | 'video' | 'canvas' | 'pdf' | 'ppt'`. */
172
+ contentType: string;
173
+ /** Why loading failed. */
174
+ reason: WhiteboardContentLoadReason;
175
+ /** Raw English error text, for diagnostics. */
176
+ message: string;
177
+ }
178
+
144
179
  /**
145
180
  * Whiteboard start options.
146
181
  *
@@ -860,6 +895,8 @@ export default class Whiteboard {
860
895
  on(event: WhiteboardEvent.UNAVAILABLE | 'unavailable', handler: (info: WhiteboardUnavailableInfo) => void): this;
861
896
  /** Subscribe to `ERROR`. */
862
897
  on(event: WhiteboardEvent.ERROR | 'error', handler: (err: Error) => void): this;
898
+ /** Subscribe to `CONTENT_LOAD_ERROR` (host only). */
899
+ on(event: WhiteboardEvent.CONTENT_LOAD_ERROR | 'content-load-error', handler: (info: WhiteboardContentLoadErrorInfo) => void): this;
863
900
  /** Subscribe to `UNDO_STATE_CHANGED` (host + guest). */
864
901
  on(event: WhiteboardEvent.UNDO_STATE_CHANGED | 'undo-state-changed', handler: (info: { available: boolean }) => void): this;
865
902
  /** Subscribe to `REDO_STATE_CHANGED` (host + guest). */
@@ -873,6 +910,7 @@ export default class Whiteboard {
873
910
  once(event: WhiteboardEvent.AVAILABLE | 'available', handler: (info: WhiteboardAvailableInfo) => void): this;
874
911
  once(event: WhiteboardEvent.UNAVAILABLE | 'unavailable', handler: (info: WhiteboardUnavailableInfo) => void): this;
875
912
  once(event: WhiteboardEvent.ERROR | 'error', handler: (err: Error) => void): this;
913
+ once(event: WhiteboardEvent.CONTENT_LOAD_ERROR | 'content-load-error', handler: (info: WhiteboardContentLoadErrorInfo) => void): this;
876
914
  once(event: WhiteboardEvent.UNDO_STATE_CHANGED | 'undo-state-changed', handler: (info: { available: boolean }) => void): this;
877
915
  once(event: WhiteboardEvent.REDO_STATE_CHANGED | 'redo-state-changed', handler: (info: { available: boolean }) => void): this;
878
916
  once(event: WhiteboardEvent.PAGE_STATE_CHANGED | 'page-state-changed', handler: (info: WhiteboardPageStateInfo) => void): this;