livevoice-sdk-react-native 1.0.3 → 2.0.0

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.
Files changed (185) hide show
  1. package/LICENSE +1 -1
  2. package/README.md +5 -5
  3. package/android/{generated/java/io/livevoice/react → app/build/generated/source/codegen/java/com/facebook/fbreact/specs}/NativeLiveVoiceSdkSpec.java +2 -2
  4. package/android/{generated → app/build/generated/source/codegen}/jni/CMakeLists.txt +1 -9
  5. package/android/{generated → app/build/generated/source/codegen}/jni/RNLiveVoiceSpec-generated.cpp +3 -3
  6. package/android/app/build/generated/source/codegen/jni/react/renderer/components/RNLiveVoiceSpec/RNLiveVoiceSpecJSI.h +341 -0
  7. package/android/build.gradle +41 -84
  8. package/android/gradle.properties +10 -6
  9. package/android/src/main/java/io/livevoice/react/LiveVoiceModule.kt +17 -16
  10. package/android/src/main/java/io/livevoice/react/LiveVoiceSdkReactNativePackage.kt +12 -13
  11. package/android/src/main/java/io/livevoice/react/Mappings.kt +36 -5
  12. package/android/src/main/java/io/livevoice/react/NativeModels.kt +2 -0
  13. package/android/src/main/java/io/livevoice/react/__SDK.kt +1 -1
  14. package/ios/LiveVoiceSdkReactNative.h +5 -5
  15. package/ios/{LivevoiceSdkReactNative.mm → LiveVoiceSdkReactNative.mm} +59 -74
  16. package/ios/__SDK.h +1 -1
  17. package/lib/module/components/ChannelView.js +14 -38
  18. package/lib/module/components/ChannelView.js.map +1 -1
  19. package/lib/module/components/LiveVoiceView.js +46 -23
  20. package/lib/module/components/LiveVoiceView.js.map +1 -1
  21. package/lib/module/components/PlayButtonView.js +243 -84
  22. package/lib/module/components/PlayButtonView.js.map +1 -1
  23. package/lib/module/icons/captions@1x.png +0 -0
  24. package/lib/module/icons/captions@2x.png +0 -0
  25. package/lib/module/icons/pause@1x.png +0 -0
  26. package/lib/module/icons/pause@2x.png +0 -0
  27. package/lib/module/icons/play@1x.png +0 -0
  28. package/lib/module/icons/play@2x.png +0 -0
  29. package/lib/module/index.js +19 -21
  30. package/lib/module/index.js.map +1 -1
  31. package/lib/module/specs/NativeLiveVoiceSdk.js +4 -0
  32. package/lib/module/specs/NativeLiveVoiceSdk.js.map +1 -1
  33. package/lib/module/util/Colors.js +2 -1
  34. package/lib/module/util/Colors.js.map +1 -1
  35. package/lib/typescript/package.json +1 -0
  36. package/lib/typescript/src/components/AudioOutputSwitchView.d.ts.map +1 -0
  37. package/lib/typescript/src/components/BrandingView.d.ts.map +1 -0
  38. package/lib/typescript/{commonjs/src → src}/components/ChannelView.d.ts +4 -2
  39. package/lib/typescript/src/components/ChannelView.d.ts.map +1 -0
  40. package/lib/typescript/src/components/ErrorView.d.ts.map +1 -0
  41. package/lib/typescript/src/components/LiveVoiceView.d.ts.map +1 -0
  42. package/lib/typescript/src/components/PlayButtonView.d.ts +341 -0
  43. package/lib/typescript/src/components/PlayButtonView.d.ts.map +1 -0
  44. package/lib/typescript/src/components/ReconnectingView.d.ts.map +1 -0
  45. package/lib/typescript/src/components/WarningView.d.ts.map +1 -0
  46. package/lib/typescript/src/components/index.d.ts.map +1 -0
  47. package/lib/typescript/{commonjs/src → src}/index.d.ts +11 -15
  48. package/lib/typescript/src/index.d.ts.map +1 -0
  49. package/lib/typescript/{commonjs/src → src}/specs/NativeLiveVoiceSdk.d.ts +3 -3
  50. package/lib/typescript/src/specs/NativeLiveVoiceSdk.d.ts.map +1 -0
  51. package/lib/typescript/{commonjs/src → src}/util/Colors.d.ts +2 -1
  52. package/lib/typescript/src/util/Colors.d.ts.map +1 -0
  53. package/lib/typescript/src/util/ForegroundServiceConfig.d.ts.map +1 -0
  54. package/lib/typescript/src/util/PlayingState.d.ts.map +1 -0
  55. package/lib/typescript/src/util/Translations.d.ts.map +1 -0
  56. package/lib/typescript/{module/src → src}/util/UIState.d.ts +22 -1
  57. package/lib/typescript/src/util/UIState.d.ts.map +1 -0
  58. package/livevoice-sdk-react-native.podspec +6 -27
  59. package/package.json +33 -123
  60. package/src/components/ChannelView.tsx +18 -25
  61. package/src/components/LiveVoiceView.tsx +110 -59
  62. package/src/components/PlayButtonView.tsx +280 -87
  63. package/src/icons/captions@1x.png +0 -0
  64. package/src/icons/captions@2x.png +0 -0
  65. package/src/icons/pause@1x.png +0 -0
  66. package/src/icons/pause@2x.png +0 -0
  67. package/src/icons/play@1x.png +0 -0
  68. package/src/icons/play@2x.png +0 -0
  69. package/src/index.tsx +95 -79
  70. package/src/specs/NativeLiveVoiceSdk.ts +7 -5
  71. package/src/util/Colors.ts +3 -1
  72. package/src/util/UIState.ts +25 -1
  73. package/android/generated/jni/react/renderer/components/RNLiveVoiceSpec/RNLiveVoiceSpecJSI-generated.cpp +0 -245
  74. package/android/generated/jni/react/renderer/components/RNLiveVoiceSpec/RNLiveVoiceSpecJSI.h +0 -398
  75. package/android/src/main/AndroidManifest.xml +0 -3
  76. package/ios/generated/RNLiveVoiceSpec/RNLiveVoiceSpec-generated.mm +0 -292
  77. package/ios/generated/RNLiveVoiceSpec/RNLiveVoiceSpec.h +0 -101
  78. package/ios/generated/RNLiveVoiceSpecJSI-generated.cpp +0 -245
  79. package/ios/generated/RNLiveVoiceSpecJSI.h +0 -398
  80. package/lib/commonjs/components/AudioOutputSwitchView.js +0 -144
  81. package/lib/commonjs/components/AudioOutputSwitchView.js.map +0 -1
  82. package/lib/commonjs/components/BrandingView.js +0 -78
  83. package/lib/commonjs/components/BrandingView.js.map +0 -1
  84. package/lib/commonjs/components/ChannelView.js +0 -117
  85. package/lib/commonjs/components/ChannelView.js.map +0 -1
  86. package/lib/commonjs/components/ErrorView.js +0 -88
  87. package/lib/commonjs/components/ErrorView.js.map +0 -1
  88. package/lib/commonjs/components/LiveVoiceView.js +0 -107
  89. package/lib/commonjs/components/LiveVoiceView.js.map +0 -1
  90. package/lib/commonjs/components/PlayButtonView.js +0 -161
  91. package/lib/commonjs/components/PlayButtonView.js.map +0 -1
  92. package/lib/commonjs/components/ReconnectingView.js +0 -109
  93. package/lib/commonjs/components/ReconnectingView.js.map +0 -1
  94. package/lib/commonjs/components/WarningView.js +0 -58
  95. package/lib/commonjs/components/WarningView.js.map +0 -1
  96. package/lib/commonjs/components/index.js +0 -94
  97. package/lib/commonjs/components/index.js.map +0 -1
  98. package/lib/commonjs/icons/branding.png +0 -0
  99. package/lib/commonjs/icons/cpu.png +0 -0
  100. package/lib/commonjs/icons/headphones.png +0 -0
  101. package/lib/commonjs/icons/mic.png +0 -0
  102. package/lib/commonjs/icons/pause.png +0 -0
  103. package/lib/commonjs/icons/play.png +0 -0
  104. package/lib/commonjs/icons/speaker.png +0 -0
  105. package/lib/commonjs/index.js +0 -327
  106. package/lib/commonjs/index.js.map +0 -1
  107. package/lib/commonjs/specs/NativeLiveVoiceSdk.js +0 -19
  108. package/lib/commonjs/specs/NativeLiveVoiceSdk.js.map +0 -1
  109. package/lib/commonjs/util/Colors.js +0 -30
  110. package/lib/commonjs/util/Colors.js.map +0 -1
  111. package/lib/commonjs/util/ForegroundServiceConfig.js +0 -33
  112. package/lib/commonjs/util/ForegroundServiceConfig.js.map +0 -1
  113. package/lib/commonjs/util/PlayingState.js +0 -24
  114. package/lib/commonjs/util/PlayingState.js.map +0 -1
  115. package/lib/commonjs/util/Translations.js +0 -47
  116. package/lib/commonjs/util/Translations.js.map +0 -1
  117. package/lib/commonjs/util/UIState.js +0 -6
  118. package/lib/commonjs/util/UIState.js.map +0 -1
  119. package/lib/module/icons/pause.png +0 -0
  120. package/lib/module/icons/play.png +0 -0
  121. package/lib/typescript/commonjs/package.json +0 -1
  122. package/lib/typescript/commonjs/src/components/AudioOutputSwitchView.d.ts.map +0 -1
  123. package/lib/typescript/commonjs/src/components/BrandingView.d.ts.map +0 -1
  124. package/lib/typescript/commonjs/src/components/ChannelView.d.ts.map +0 -1
  125. package/lib/typescript/commonjs/src/components/ErrorView.d.ts.map +0 -1
  126. package/lib/typescript/commonjs/src/components/LiveVoiceView.d.ts.map +0 -1
  127. package/lib/typescript/commonjs/src/components/PlayButtonView.d.ts +0 -146
  128. package/lib/typescript/commonjs/src/components/PlayButtonView.d.ts.map +0 -1
  129. package/lib/typescript/commonjs/src/components/ReconnectingView.d.ts.map +0 -1
  130. package/lib/typescript/commonjs/src/components/WarningView.d.ts.map +0 -1
  131. package/lib/typescript/commonjs/src/components/index.d.ts.map +0 -1
  132. package/lib/typescript/commonjs/src/index.d.ts.map +0 -1
  133. package/lib/typescript/commonjs/src/specs/NativeLiveVoiceSdk.d.ts.map +0 -1
  134. package/lib/typescript/commonjs/src/util/Colors.d.ts.map +0 -1
  135. package/lib/typescript/commonjs/src/util/ForegroundServiceConfig.d.ts.map +0 -1
  136. package/lib/typescript/commonjs/src/util/PlayingState.d.ts.map +0 -1
  137. package/lib/typescript/commonjs/src/util/Translations.d.ts.map +0 -1
  138. package/lib/typescript/commonjs/src/util/UIState.d.ts +0 -45
  139. package/lib/typescript/commonjs/src/util/UIState.d.ts.map +0 -1
  140. package/lib/typescript/module/src/components/AudioOutputSwitchView.d.ts +0 -6
  141. package/lib/typescript/module/src/components/AudioOutputSwitchView.d.ts.map +0 -1
  142. package/lib/typescript/module/src/components/BrandingView.d.ts +0 -6
  143. package/lib/typescript/module/src/components/BrandingView.d.ts.map +0 -1
  144. package/lib/typescript/module/src/components/ChannelView.d.ts +0 -13
  145. package/lib/typescript/module/src/components/ChannelView.d.ts.map +0 -1
  146. package/lib/typescript/module/src/components/ErrorView.d.ts +0 -9
  147. package/lib/typescript/module/src/components/ErrorView.d.ts.map +0 -1
  148. package/lib/typescript/module/src/components/LiveVoiceView.d.ts +0 -6
  149. package/lib/typescript/module/src/components/LiveVoiceView.d.ts.map +0 -1
  150. package/lib/typescript/module/src/components/PlayButtonView.d.ts +0 -146
  151. package/lib/typescript/module/src/components/PlayButtonView.d.ts.map +0 -1
  152. package/lib/typescript/module/src/components/ReconnectingView.d.ts +0 -9
  153. package/lib/typescript/module/src/components/ReconnectingView.d.ts.map +0 -1
  154. package/lib/typescript/module/src/components/WarningView.d.ts +0 -8
  155. package/lib/typescript/module/src/components/WarningView.d.ts.map +0 -1
  156. package/lib/typescript/module/src/components/index.d.ts +0 -9
  157. package/lib/typescript/module/src/components/index.d.ts.map +0 -1
  158. package/lib/typescript/module/src/index.d.ts +0 -149
  159. package/lib/typescript/module/src/index.d.ts.map +0 -1
  160. package/lib/typescript/module/src/specs/NativeLiveVoiceSdk.d.ts +0 -48
  161. package/lib/typescript/module/src/specs/NativeLiveVoiceSdk.d.ts.map +0 -1
  162. package/lib/typescript/module/src/util/Colors.d.ts +0 -13
  163. package/lib/typescript/module/src/util/Colors.d.ts.map +0 -1
  164. package/lib/typescript/module/src/util/ForegroundServiceConfig.d.ts +0 -12
  165. package/lib/typescript/module/src/util/ForegroundServiceConfig.d.ts.map +0 -1
  166. package/lib/typescript/module/src/util/PlayingState.d.ts +0 -7
  167. package/lib/typescript/module/src/util/PlayingState.d.ts.map +0 -1
  168. package/lib/typescript/module/src/util/Translations.d.ts +0 -22
  169. package/lib/typescript/module/src/util/Translations.d.ts.map +0 -1
  170. package/lib/typescript/module/src/util/UIState.d.ts.map +0 -1
  171. package/react-native.config.js +0 -12
  172. package/src/icons/pause.png +0 -0
  173. package/src/icons/play.png +0 -0
  174. /package/android/{generated → app/build/generated/source/codegen}/jni/RNLiveVoiceSpec.h +0 -0
  175. /package/lib/{typescript/module → module}/package.json +0 -0
  176. /package/lib/typescript/{commonjs/src → src}/components/AudioOutputSwitchView.d.ts +0 -0
  177. /package/lib/typescript/{commonjs/src → src}/components/BrandingView.d.ts +0 -0
  178. /package/lib/typescript/{commonjs/src → src}/components/ErrorView.d.ts +0 -0
  179. /package/lib/typescript/{commonjs/src → src}/components/LiveVoiceView.d.ts +0 -0
  180. /package/lib/typescript/{commonjs/src → src}/components/ReconnectingView.d.ts +0 -0
  181. /package/lib/typescript/{commonjs/src → src}/components/WarningView.d.ts +0 -0
  182. /package/lib/typescript/{commonjs/src → src}/components/index.d.ts +0 -0
  183. /package/lib/typescript/{commonjs/src → src}/util/ForegroundServiceConfig.d.ts +0 -0
  184. /package/lib/typescript/{commonjs/src → src}/util/PlayingState.d.ts +0 -0
  185. /package/lib/typescript/{commonjs/src → src}/util/Translations.d.ts +0 -0
package/src/index.tsx CHANGED
@@ -9,83 +9,90 @@
9
9
  * SPDX-License-Identifier: MIT
10
10
  */
11
11
 
12
- import LiveVoiceSdkReactNative from './specs/NativeLiveVoiceSdk';
13
- import { type UiState } from './util/UIState';
14
- import { type ForegroundServiceConfig, serviceDisabled } from './util/ForegroundServiceConfig';
12
+ import LiveVoiceSdkReactNative from "./specs/NativeLiveVoiceSdk";
13
+ import { type UiState, type AvailableSubtitle } from "./util/UIState";
14
+ import {
15
+ type ForegroundServiceConfig,
16
+ serviceDisabled,
17
+ } from "./util/ForegroundServiceConfig";
15
18
 
16
- export type AvailableSubtitleConfigs = { [key: string]: (string | null)[] }
17
- export type Claims = { hideBranding: boolean, customUiAllowed: boolean }
19
+ export type Claims = { hideBranding: boolean; customUiAllowed: boolean };
18
20
 
19
- export * from './components'
20
- export * from './util/Translations'
21
- export * from './util/ForegroundServiceConfig'
22
- export * from './util/UIState'
23
- export * from './util/PlayingState'
21
+ export * from "./components";
22
+ export * from "./util/Translations";
23
+ export * from "./util/ForegroundServiceConfig";
24
+ export * from "./util/UIState";
25
+ export * from "./util/PlayingState";
24
26
 
25
27
  /**
26
28
  * Initialize the LiveVoice SDK.
27
- *
29
+ *
28
30
  * @param {ForegroundServiceConfig} [androidServiceConfig=serviceDisabled] - Pass the service config on Android.
29
31
  */
30
- export function initialize(androidServiceConfig: ForegroundServiceConfig = serviceDisabled): void {
31
- let serviceTypeAsString: string | null
32
- switch (androidServiceConfig.type) {
33
- case 'Disabled':
34
- serviceTypeAsString = null
35
- break
36
- case 'Enabled':
37
- if (androidServiceConfig.message == null)
38
- serviceTypeAsString = 'LV_NOTIFICATION_DEFAULT_MESSAGE'
39
- else
40
- serviceTypeAsString = androidServiceConfig.message
41
- break
42
- }
32
+ export function initialize(
33
+ androidServiceConfig: ForegroundServiceConfig = serviceDisabled,
34
+ ): void {
35
+ let serviceTypeAsString: string | null;
36
+ switch (androidServiceConfig.type) {
37
+ case "Disabled":
38
+ serviceTypeAsString = null;
39
+ break;
40
+ case "Enabled":
41
+ if (androidServiceConfig.message == null)
42
+ serviceTypeAsString = "LV_NOTIFICATION_DEFAULT_MESSAGE";
43
+ else serviceTypeAsString = androidServiceConfig.message;
44
+ break;
45
+ }
43
46
 
44
- // Interface cannot take default-parameter, so we need to wrap it here
45
- LiveVoiceSdkReactNative.initialize(serviceTypeAsString);
47
+ // Interface cannot take default-parameter, so we need to wrap it here
48
+ LiveVoiceSdkReactNative.initialize(serviceTypeAsString);
46
49
  }
47
50
 
48
51
  /**
49
52
  * Join an event.
50
- *
53
+ *
51
54
  * @abstract By joining an event you can display the event's channels.
52
- *
55
+ *
53
56
  * @param {string} joinCode - The listener code of your event. You can find it on the event page of the admin web-interface by clicking on 'Share with your audience'.
54
57
  * @param {string | null} password - The optional password to join the event. If a password has been set for listeners in your event, it can be found in the 'Access' tab of the event page of the admin web-interface.
55
58
  * @param {string} apiKey - Your API key. You can find your API key in the account page when logged in on the website.
56
59
  */
57
- export function joinEvent(joinCode: string, password: string | null, apiKey: string): void {
58
- return LiveVoiceSdkReactNative.joinEvent(joinCode, password, apiKey);
60
+ export function joinEvent(
61
+ joinCode: string,
62
+ password: string | null,
63
+ apiKey: string,
64
+ ): void {
65
+ return LiveVoiceSdkReactNative.joinEvent(joinCode, password, apiKey);
59
66
  }
60
67
 
61
68
  /**
62
69
  * Leave the current event.
63
- *
70
+ *
64
71
  * @abstract You can explicitly leave an event to tear down any network connections the SDK uses when you no longer display any channels.
65
72
  */
66
73
  export function leaveEvent(): void {
67
- return LiveVoiceSdkReactNative.leaveEvent();
74
+ return LiveVoiceSdkReactNative.leaveEvent();
68
75
  }
69
76
 
70
77
  /**
71
78
  * Reconnect when a connection error occurred.
72
- *
79
+ *
73
80
  * @abstract Call this method to try to reconnect when a connection error has occurred.
74
81
  */
75
82
  export function reconnect(): void {
76
- return LiveVoiceSdkReactNative.reconnect();
83
+ return LiveVoiceSdkReactNative.reconnect();
77
84
  }
78
85
 
79
86
  /**
80
87
  * Get the claims for the current event.
81
- *
88
+ *
82
89
  * @abstract The claims determine the authorized features for an API key. Claims are available, once an event has been joined.
83
90
  * @returns {Claims | null} The authorization claims, or `nil` if not yet joined
84
91
  */
85
92
  export function getCurrentClaims(): Claims | null {
86
- const claims = LiveVoiceSdkReactNative.getCurrentClaims()
87
- if (claims == null) return null
88
- return JSON.parse(claims)
93
+ const claims = LiveVoiceSdkReactNative.getCurrentClaims();
94
+ if (claims == null) return null;
95
+ return JSON.parse(claims);
89
96
  }
90
97
 
91
98
  /**
@@ -96,7 +103,7 @@ export function getCurrentClaims(): Claims | null {
96
103
  * @returns {UiState} The current view state
97
104
  */
98
105
  export function getCurrentUiState(): UiState {
99
- return JSON.parse(LiveVoiceSdkReactNative.getCurrentUiState())
106
+ return JSON.parse(LiveVoiceSdkReactNative.getCurrentUiState());
100
107
  }
101
108
 
102
109
  /**
@@ -104,13 +111,14 @@ export function getCurrentUiState(): UiState {
104
111
  *
105
112
  * @abstract You should only need to call this method to get an initial value. Use {@link onAvailableSubtitleConfigsChanged}
106
113
  ` to be updated when the available subtitle configurations change.
107
- * @returns {AvailableSubtitleConfigs} The current available subtitle configuration
114
+ * @returns {[AvailableSubtitle]} The current available subtitles
108
115
  */
109
- export function getCurrentSubtitleConfiguration(): AvailableSubtitleConfigs {
110
- return JSON.parse(LiveVoiceSdkReactNative.getCurrentAvailableSubtitleConfigs())
116
+ export function getCurrentSubtitleConfiguration(): [AvailableSubtitle] {
117
+ return JSON.parse(
118
+ LiveVoiceSdkReactNative.getCurrentAvailableSubtitleConfigs(),
119
+ );
111
120
  }
112
121
 
113
-
114
122
  /**
115
123
  * Get the current subtitle elemens LiveVoice SDK.
116
124
  *
@@ -119,7 +127,7 @@ export function getCurrentSubtitleConfiguration(): AvailableSubtitleConfigs {
119
127
  * @returns {[String]} The current subtitles
120
128
  */
121
129
  export function getCurrentSubtitles(): [String] {
122
- return JSON.parse(LiveVoiceSdkReactNative.getCurrentSubtitles())
130
+ return JSON.parse(LiveVoiceSdkReactNative.getCurrentSubtitles());
123
131
  }
124
132
 
125
133
  /**
@@ -130,7 +138,7 @@ export function getCurrentSubtitles(): [String] {
130
138
  * @returns {boolean} `true` for the speaker and `false` for the receiver.
131
139
  */
132
140
  export function getCurrentAudioState(): boolean {
133
- return LiveVoiceSdkReactNative.getCurrentAudioState();
141
+ return LiveVoiceSdkReactNative.getCurrentAudioState();
134
142
  }
135
143
 
136
144
  /**
@@ -138,7 +146,7 @@ export function getCurrentAudioState(): boolean {
138
146
  * @param {boolean} value - Set to `true` to use the speaker, and `false` to use the receiver.
139
147
  */
140
148
  export function setLiveVoiceUseSpeaker(value: boolean): void {
141
- return LiveVoiceSdkReactNative.setLiveVoiceUseSpeaker(value);
149
+ return LiveVoiceSdkReactNative.setLiveVoiceUseSpeaker(value);
142
150
  }
143
151
 
144
152
  /**
@@ -147,14 +155,14 @@ export function setLiveVoiceUseSpeaker(value: boolean): void {
147
155
  * @param {number} [id] - The channel ID.
148
156
  */
149
157
  export function startChannel(id: number): void {
150
- return LiveVoiceSdkReactNative.startChannel(id);
158
+ return LiveVoiceSdkReactNative.startChannel(id);
151
159
  }
152
160
 
153
161
  /**
154
162
  * Stop playing the currently playing channel.
155
163
  */
156
164
  export function stopChannel(): void {
157
- return LiveVoiceSdkReactNative.stopChannel();
165
+ return LiveVoiceSdkReactNative.stopChannel();
158
166
  }
159
167
 
160
168
  /**
@@ -162,75 +170,83 @@ export function stopChannel(): void {
162
170
  * @abstract The SDK can receive a single stream of subtitle fragments at a time.
163
171
  * You can stop receiving subtitles using {@link stopSubtitles()}.
164
172
  * Whenever you call this method, any previous subtitle streams are stopped automatically and you receive the subtitles for the requested channel and language instead.
165
- *
173
+ *
166
174
  * Note: You have to make sure that subtitles for the given channel and language are enabled in the web-interface. You can use the {@link onAvailableSubtitleConfigsChanged} handler to check if subtitles are available for a given channel in a given language.
167
- *
175
+ *
168
176
  * @param {number | null} channelId - The channel to receive subtitles for. Set to `null` to always receive subtitles for the currently playing channel.
169
- * @param {string | null} language - The language code for the translation, or `null` to request the transcript.
170
177
  */
171
- export function startSubtitles(channelId: number | null, language: string | null) {
172
- const nativeSafeId = (channelId == null) ? -1 : channelId
173
- LiveVoiceSdkReactNative.startSubtitles(nativeSafeId, language)
178
+ export function startSubtitles(channelId: number | null) {
179
+ const nativeSafeId = channelId == null ? -1 : channelId;
180
+ LiveVoiceSdkReactNative.startSubtitles(nativeSafeId);
174
181
  }
175
182
 
176
183
  /**
177
184
  * Stop receiving subtitles.
178
185
  */
179
186
  export function stopSubtitles(): void {
180
- return LiveVoiceSdkReactNative.stopSubtitles();
187
+ return LiveVoiceSdkReactNative.stopSubtitles();
181
188
  }
182
189
 
183
190
  // Event handlers
184
191
 
185
192
  /**
186
193
  * Handle changes of the audio output.
187
- *
194
+ *
188
195
  * @returns {object} - An object with a `remove` method to unsubscribe from the event.
189
196
  */
190
- export function onAudioOutputChanged(handler: (useSpeaker: boolean) => void): { remove: () => void; } {
191
- return LiveVoiceSdkReactNative.onAudioOutputChanged((data: boolean) => {
192
- handler(data);
193
- });
197
+ export function onAudioOutputChanged(handler: (useSpeaker: boolean) => void): {
198
+ remove: () => void;
199
+ } {
200
+ return LiveVoiceSdkReactNative.onAudioOutputChanged((data: boolean) => {
201
+ handler(data);
202
+ });
194
203
  }
195
204
 
196
205
  /**
197
206
  * Handle changes of the UI state.
198
- *
207
+ *
199
208
  * @returns {object} - An object with a `remove` method to unsubscribe from the event.
200
209
  */
201
- export function onUiStateChanged(handler: (arg: UiState) => void): { remove: () => void; } {
202
- return LiveVoiceSdkReactNative.onUiStateChanged((data: string) => {
203
- handler(JSON.parse(data))
204
- });
210
+ export function onUiStateChanged(handler: (arg: UiState) => void): {
211
+ remove: () => void;
212
+ } {
213
+ return LiveVoiceSdkReactNative.onUiStateChanged((data: string) => {
214
+ handler(JSON.parse(data));
215
+ });
205
216
  }
206
217
 
207
218
  /**
208
219
  * Handle changes of the available subtitles.
209
- *
220
+ *
210
221
  * @returns { object } - An object with a`remove` method to unsubscribe from the event.
211
222
  */
212
- export function onAvailableSubtitleConfigsChanged(handler: (arg: AvailableSubtitleConfigs) => void): { remove: () => void; } {
213
- return LiveVoiceSdkReactNative.onAvailableSubtitleConfigsChanged((data: string) => {
214
- const mapOfSubtitles: AvailableSubtitleConfigs = JSON.parse(data);
215
- handler(mapOfSubtitles)
216
- })
223
+ export function onAvailableSubtitleConfigsChanged(
224
+ handler: (arg: [AvailableSubtitle]) => void,
225
+ ): { remove: () => void } {
226
+ return LiveVoiceSdkReactNative.onAvailableSubtitleConfigsChanged(
227
+ (data: string) => {
228
+ handler(JSON.parse(data));
229
+ },
230
+ );
217
231
  }
218
232
 
219
233
  /**
220
234
  * Handle changes of the available subtitles.
221
- *
235
+ *
222
236
  * @returns {object} - An object with a `remove` method to unsubscribe from the event.
223
237
  */
224
- export function onSubtitlesChanged(handler: (arg: [String]) => void): { remove: () => void; } {
225
- return LiveVoiceSdkReactNative.onSubtitlesChanged((data: string) => {
226
- const mapOfSubtitles: [String] = JSON.parse(data);
227
- handler(mapOfSubtitles)
228
- })
238
+ export function onSubtitlesChanged(handler: (arg: [String]) => void): {
239
+ remove: () => void;
240
+ } {
241
+ return LiveVoiceSdkReactNative.onSubtitlesChanged((data: string) => {
242
+ const mapOfSubtitles: [String] = JSON.parse(data);
243
+ handler(mapOfSubtitles);
244
+ });
229
245
  }
230
246
 
231
247
  /**
232
248
  * Open the LiveVoice website in the device's default browser.
233
249
  */
234
250
  export function openLiveVoiceWebsite(): void {
235
- return LiveVoiceSdkReactNative.openLiveVoiceWebsite();
236
- }
251
+ return LiveVoiceSdkReactNative.openLiveVoiceWebsite();
252
+ }
@@ -9,9 +9,11 @@
9
9
  * SPDX-License-Identifier: MIT
10
10
  */
11
11
 
12
- import { type TurboModule } from 'react-native';
13
- import { TurboModuleRegistry } from 'react-native';
14
- import { type EventEmitter } from 'react-native/Libraries/Types/CodegenTypes';
12
+ import { TurboModuleRegistry, type TurboModule, type CodegenTypes } from 'react-native';
13
+
14
+ // Type alias is required for backwards compatibility with RN < 0.80 codegen parsers
15
+ // which statically look for the exact identifier name 'EventEmitter'
16
+ type EventEmitter<T> = CodegenTypes.EventEmitter<T>;
15
17
 
16
18
  export interface Spec extends TurboModule {
17
19
  initialize(androidServiceConfig: string | null): void
@@ -36,7 +38,7 @@ export interface Spec extends TurboModule {
36
38
  /**
37
39
  * @param channelId: -1 denotes an unspecified channel (i.e: the currently playing one)
38
40
  */
39
- startSubtitles(channelId: number, languageCode: string | null): void
41
+ startSubtitles(channelId: number): void
40
42
  stopSubtitles(): void
41
43
 
42
44
  openLiveVoiceWebsite(): void
@@ -74,4 +76,4 @@ export interface Spec extends TurboModule {
74
76
  accessibilityChannelStop(): string
75
77
  }
76
78
 
77
- export default TurboModuleRegistry.getEnforcing<Spec>('LiveVoiceModule');
79
+ export default TurboModuleRegistry.getEnforcing<Spec>('LiveVoiceModule');
@@ -11,7 +11,6 @@
11
11
 
12
12
  export const COLORS = {
13
13
  primary: '#F1521B',
14
- primaryOutline: 'rgba(241, 82, 27, 0.2)',
15
14
 
16
15
  bg: '#F5F5F5',
17
16
  bgDark: '#1E1F23',
@@ -19,6 +18,9 @@ export const COLORS = {
19
18
  cardBg: '#fff',
20
19
  cardBgDark: '#212429',
21
20
 
21
+ divider: '#f0f0f0',
22
+ dividerDark: '#333333',
23
+
22
24
  white: '#fff',
23
25
  black: '#191919',
24
26
  gray: '#808080',
@@ -59,7 +59,31 @@ export interface Channel {
59
59
  id: number;
60
60
  name: string;
61
61
  isOnline: boolean;
62
+ hasAudio: boolean;
63
+ hasSubtitles: boolean;
62
64
  isAudioMuted: boolean;
63
- isAiSpeaker: boolean;
65
+ aiTranslationInfo: AITranslationInfo | null;
66
+ dependenChannels: [DependentChannel];
64
67
  playingState: PlayingState;
68
+ }
69
+
70
+ export interface AITranslationInfo {
71
+ sourceID: number;
72
+ targetLanguage: string;
73
+ }
74
+
75
+ export interface DependentChannel {
76
+ id: number;
77
+ name: string;
78
+ sourceChannelID: number;
79
+ language: string;
80
+ hasSubtitles: boolean;
81
+ hasAudio: boolean;
82
+ }
83
+
84
+ export interface AvailableSubtitle {
85
+ id: number;
86
+ name: string;
87
+ language: string | null;
88
+ parent: number | null;
65
89
  }
@@ -1,245 +0,0 @@
1
- /**
2
- * This code was generated by [react-native-codegen](https://www.npmjs.com/package/react-native-codegen).
3
- *
4
- * Do not edit this file as changes may cause incorrect behavior and will be lost
5
- * once the code is regenerated.
6
- *
7
- * @generated by codegen project: GenerateModuleCpp.js
8
- */
9
-
10
- #include "RNLiveVoiceSpecJSI.h"
11
-
12
- namespace facebook::react {
13
-
14
- static jsi::Value __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_initialize(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
15
- static_cast<NativeLiveVoiceSdkCxxSpecJSI *>(&turboModule)->initialize(
16
- rt,
17
- count <= 0 || args[0].isNull() || args[0].isUndefined() ? std::nullopt : std::make_optional(args[0].asString(rt))
18
- );
19
- return jsi::Value::undefined();
20
- }
21
- static jsi::Value __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_joinEvent(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
22
- static_cast<NativeLiveVoiceSdkCxxSpecJSI *>(&turboModule)->joinEvent(
23
- rt,
24
- count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asString(rt),
25
- count <= 1 || args[1].isNull() || args[1].isUndefined() ? std::nullopt : std::make_optional(args[1].asString(rt)),
26
- count <= 2 ? throw jsi::JSError(rt, "Expected argument in position 2 to be passed") : args[2].asString(rt)
27
- );
28
- return jsi::Value::undefined();
29
- }
30
- static jsi::Value __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_leaveEvent(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
31
- static_cast<NativeLiveVoiceSdkCxxSpecJSI *>(&turboModule)->leaveEvent(
32
- rt
33
- );
34
- return jsi::Value::undefined();
35
- }
36
- static jsi::Value __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_reconnect(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
37
- static_cast<NativeLiveVoiceSdkCxxSpecJSI *>(&turboModule)->reconnect(
38
- rt
39
- );
40
- return jsi::Value::undefined();
41
- }
42
- static jsi::Value __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_getCurrentClaims(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
43
- auto result = static_cast<NativeLiveVoiceSdkCxxSpecJSI *>(&turboModule)->getCurrentClaims(
44
- rt
45
- );
46
- return result ? jsi::Value(std::move(*result)) : jsi::Value::null();
47
- }
48
- static jsi::Value __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_getCurrentUiState(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
49
- return static_cast<NativeLiveVoiceSdkCxxSpecJSI *>(&turboModule)->getCurrentUiState(
50
- rt
51
- );
52
- }
53
- static jsi::Value __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_getCurrentAudioState(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
54
- return static_cast<NativeLiveVoiceSdkCxxSpecJSI *>(&turboModule)->getCurrentAudioState(
55
- rt
56
- );
57
- }
58
- static jsi::Value __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_getCurrentSubtitles(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
59
- return static_cast<NativeLiveVoiceSdkCxxSpecJSI *>(&turboModule)->getCurrentSubtitles(
60
- rt
61
- );
62
- }
63
- static jsi::Value __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_getCurrentAvailableSubtitleConfigs(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
64
- return static_cast<NativeLiveVoiceSdkCxxSpecJSI *>(&turboModule)->getCurrentAvailableSubtitleConfigs(
65
- rt
66
- );
67
- }
68
- static jsi::Value __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_setLiveVoiceUseSpeaker(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
69
- static_cast<NativeLiveVoiceSdkCxxSpecJSI *>(&turboModule)->setLiveVoiceUseSpeaker(
70
- rt,
71
- count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asBool()
72
- );
73
- return jsi::Value::undefined();
74
- }
75
- static jsi::Value __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_startChannel(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
76
- static_cast<NativeLiveVoiceSdkCxxSpecJSI *>(&turboModule)->startChannel(
77
- rt,
78
- count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asNumber()
79
- );
80
- return jsi::Value::undefined();
81
- }
82
- static jsi::Value __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_stopChannel(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
83
- static_cast<NativeLiveVoiceSdkCxxSpecJSI *>(&turboModule)->stopChannel(
84
- rt
85
- );
86
- return jsi::Value::undefined();
87
- }
88
- static jsi::Value __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_startSubtitles(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
89
- static_cast<NativeLiveVoiceSdkCxxSpecJSI *>(&turboModule)->startSubtitles(
90
- rt,
91
- count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asNumber(),
92
- count <= 1 || args[1].isNull() || args[1].isUndefined() ? std::nullopt : std::make_optional(args[1].asString(rt))
93
- );
94
- return jsi::Value::undefined();
95
- }
96
- static jsi::Value __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_stopSubtitles(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
97
- static_cast<NativeLiveVoiceSdkCxxSpecJSI *>(&turboModule)->stopSubtitles(
98
- rt
99
- );
100
- return jsi::Value::undefined();
101
- }
102
- static jsi::Value __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_openLiveVoiceWebsite(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
103
- static_cast<NativeLiveVoiceSdkCxxSpecJSI *>(&turboModule)->openLiveVoiceWebsite(
104
- rt
105
- );
106
- return jsi::Value::undefined();
107
- }
108
- static jsi::Value __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_channelStatusOffline(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
109
- return static_cast<NativeLiveVoiceSdkCxxSpecJSI *>(&turboModule)->channelStatusOffline(
110
- rt
111
- );
112
- }
113
- static jsi::Value __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_noChannels(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
114
- return static_cast<NativeLiveVoiceSdkCxxSpecJSI *>(&turboModule)->noChannels(
115
- rt
116
- );
117
- }
118
- static jsi::Value __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_isAiChannelStatusMessage(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
119
- return static_cast<NativeLiveVoiceSdkCxxSpecJSI *>(&turboModule)->isAiChannelStatusMessage(
120
- rt
121
- );
122
- }
123
- static jsi::Value __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_sdkNoMatchingChannels(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
124
- return static_cast<NativeLiveVoiceSdkCxxSpecJSI *>(&turboModule)->sdkNoMatchingChannels(
125
- rt
126
- );
127
- }
128
- static jsi::Value __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_errorScreenRetrying(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
129
- return static_cast<NativeLiveVoiceSdkCxxSpecJSI *>(&turboModule)->errorScreenRetrying(
130
- rt
131
- );
132
- }
133
- static jsi::Value __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_errorScreenRetryingIn(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
134
- return static_cast<NativeLiveVoiceSdkCxxSpecJSI *>(&turboModule)->errorScreenRetryingIn(
135
- rt,
136
- count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asNumber()
137
- );
138
- }
139
- static jsi::Value __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_sdkErrorGeneric(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
140
- return static_cast<NativeLiveVoiceSdkCxxSpecJSI *>(&turboModule)->sdkErrorGeneric(
141
- rt
142
- );
143
- }
144
- static jsi::Value __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_sdkErrorInactive(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
145
- return static_cast<NativeLiveVoiceSdkCxxSpecJSI *>(&turboModule)->sdkErrorInactive(
146
- rt
147
- );
148
- }
149
- static jsi::Value __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_sdkErrorInvalidApiKey(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
150
- return static_cast<NativeLiveVoiceSdkCxxSpecJSI *>(&turboModule)->sdkErrorInvalidApiKey(
151
- rt
152
- );
153
- }
154
- static jsi::Value __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_sdkErrorListenerLimitReached(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
155
- return static_cast<NativeLiveVoiceSdkCxxSpecJSI *>(&turboModule)->sdkErrorListenerLimitReached(
156
- rt
157
- );
158
- }
159
- static jsi::Value __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_sdkErrorNoNetwork(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
160
- return static_cast<NativeLiveVoiceSdkCxxSpecJSI *>(&turboModule)->sdkErrorNoNetwork(
161
- rt
162
- );
163
- }
164
- static jsi::Value __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_sdkErrorNotFound(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
165
- return static_cast<NativeLiveVoiceSdkCxxSpecJSI *>(&turboModule)->sdkErrorNotFound(
166
- rt
167
- );
168
- }
169
- static jsi::Value __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_sdkErrorRequestFailed(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
170
- return static_cast<NativeLiveVoiceSdkCxxSpecJSI *>(&turboModule)->sdkErrorRequestFailed(
171
- rt,
172
- count <= 0 ? throw jsi::JSError(rt, "Expected argument in position 0 to be passed") : args[0].asNumber()
173
- );
174
- }
175
- static jsi::Value __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_sdkErrorWrongPassword(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
176
- return static_cast<NativeLiveVoiceSdkCxxSpecJSI *>(&turboModule)->sdkErrorWrongPassword(
177
- rt
178
- );
179
- }
180
- static jsi::Value __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_streamingByTitle(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
181
- return static_cast<NativeLiveVoiceSdkCxxSpecJSI *>(&turboModule)->streamingByTitle(
182
- rt
183
- );
184
- }
185
- static jsi::Value __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_errorRetryNowButton(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
186
- return static_cast<NativeLiveVoiceSdkCxxSpecJSI *>(&turboModule)->errorRetryNowButton(
187
- rt
188
- );
189
- }
190
- static jsi::Value __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_accessibilityChannelPlay(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
191
- return static_cast<NativeLiveVoiceSdkCxxSpecJSI *>(&turboModule)->accessibilityChannelPlay(
192
- rt
193
- );
194
- }
195
- static jsi::Value __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_accessibilityChannelStatusMuted(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
196
- return static_cast<NativeLiveVoiceSdkCxxSpecJSI *>(&turboModule)->accessibilityChannelStatusMuted(
197
- rt
198
- );
199
- }
200
- static jsi::Value __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_accessibilityChannelStop(jsi::Runtime &rt, TurboModule &turboModule, const jsi::Value* args, size_t count) {
201
- return static_cast<NativeLiveVoiceSdkCxxSpecJSI *>(&turboModule)->accessibilityChannelStop(
202
- rt
203
- );
204
- }
205
-
206
- NativeLiveVoiceSdkCxxSpecJSI::NativeLiveVoiceSdkCxxSpecJSI(std::shared_ptr<CallInvoker> jsInvoker)
207
- : TurboModule("LiveVoiceModule", jsInvoker) {
208
- methodMap_["initialize"] = MethodMetadata {1, __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_initialize};
209
- methodMap_["joinEvent"] = MethodMetadata {3, __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_joinEvent};
210
- methodMap_["leaveEvent"] = MethodMetadata {0, __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_leaveEvent};
211
- methodMap_["reconnect"] = MethodMetadata {0, __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_reconnect};
212
- methodMap_["getCurrentClaims"] = MethodMetadata {0, __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_getCurrentClaims};
213
- methodMap_["getCurrentUiState"] = MethodMetadata {0, __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_getCurrentUiState};
214
- methodMap_["getCurrentAudioState"] = MethodMetadata {0, __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_getCurrentAudioState};
215
- methodMap_["getCurrentSubtitles"] = MethodMetadata {0, __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_getCurrentSubtitles};
216
- methodMap_["getCurrentAvailableSubtitleConfigs"] = MethodMetadata {0, __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_getCurrentAvailableSubtitleConfigs};
217
- methodMap_["setLiveVoiceUseSpeaker"] = MethodMetadata {1, __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_setLiveVoiceUseSpeaker};
218
- methodMap_["startChannel"] = MethodMetadata {1, __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_startChannel};
219
- methodMap_["stopChannel"] = MethodMetadata {0, __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_stopChannel};
220
- methodMap_["startSubtitles"] = MethodMetadata {2, __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_startSubtitles};
221
- methodMap_["stopSubtitles"] = MethodMetadata {0, __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_stopSubtitles};
222
- methodMap_["openLiveVoiceWebsite"] = MethodMetadata {0, __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_openLiveVoiceWebsite};
223
- methodMap_["channelStatusOffline"] = MethodMetadata {0, __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_channelStatusOffline};
224
- methodMap_["noChannels"] = MethodMetadata {0, __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_noChannels};
225
- methodMap_["isAiChannelStatusMessage"] = MethodMetadata {0, __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_isAiChannelStatusMessage};
226
- methodMap_["sdkNoMatchingChannels"] = MethodMetadata {0, __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_sdkNoMatchingChannels};
227
- methodMap_["errorScreenRetrying"] = MethodMetadata {0, __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_errorScreenRetrying};
228
- methodMap_["errorScreenRetryingIn"] = MethodMetadata {1, __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_errorScreenRetryingIn};
229
- methodMap_["sdkErrorGeneric"] = MethodMetadata {0, __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_sdkErrorGeneric};
230
- methodMap_["sdkErrorInactive"] = MethodMetadata {0, __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_sdkErrorInactive};
231
- methodMap_["sdkErrorInvalidApiKey"] = MethodMetadata {0, __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_sdkErrorInvalidApiKey};
232
- methodMap_["sdkErrorListenerLimitReached"] = MethodMetadata {0, __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_sdkErrorListenerLimitReached};
233
- methodMap_["sdkErrorNoNetwork"] = MethodMetadata {0, __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_sdkErrorNoNetwork};
234
- methodMap_["sdkErrorNotFound"] = MethodMetadata {0, __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_sdkErrorNotFound};
235
- methodMap_["sdkErrorRequestFailed"] = MethodMetadata {1, __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_sdkErrorRequestFailed};
236
- methodMap_["sdkErrorWrongPassword"] = MethodMetadata {0, __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_sdkErrorWrongPassword};
237
- methodMap_["streamingByTitle"] = MethodMetadata {0, __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_streamingByTitle};
238
- methodMap_["errorRetryNowButton"] = MethodMetadata {0, __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_errorRetryNowButton};
239
- methodMap_["accessibilityChannelPlay"] = MethodMetadata {0, __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_accessibilityChannelPlay};
240
- methodMap_["accessibilityChannelStatusMuted"] = MethodMetadata {0, __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_accessibilityChannelStatusMuted};
241
- methodMap_["accessibilityChannelStop"] = MethodMetadata {0, __hostFunction_NativeLiveVoiceSdkCxxSpecJSI_accessibilityChannelStop};
242
- }
243
-
244
-
245
- } // namespace facebook::react