livevoice-sdk-react-native 1.0.3 → 2.0.1
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/LICENSE +1 -1
- package/README.md +119 -7
- package/android/build.gradle +52 -84
- package/android/gradle.properties +10 -6
- package/android/src/main/java/io/livevoice/react/LiveVoiceModule.kt +93 -126
- package/android/src/main/java/io/livevoice/react/LiveVoiceSdkReactNativePackage.kt +12 -13
- package/android/src/main/java/io/livevoice/react/__SDK.kt +16 -2
- package/ios/LiveVoiceSdkReactNative.h +5 -5
- package/ios/LiveVoiceSdkReactNative.mm +308 -0
- package/ios/__SDK.h +16 -2
- package/lib/module/components/AudioOutputSwitchView.js +13 -13
- package/lib/module/components/AudioOutputSwitchView.js.map +1 -1
- package/lib/module/components/BrandingView.js +13 -11
- package/lib/module/components/BrandingView.js.map +1 -1
- package/lib/module/components/ChannelView.js +27 -48
- package/lib/module/components/ChannelView.js.map +1 -1
- package/lib/module/components/ErrorView.js +12 -10
- package/lib/module/components/ErrorView.js.map +1 -1
- package/lib/module/components/LiveVoiceView.js +153 -61
- package/lib/module/components/LiveVoiceView.js.map +1 -1
- package/lib/module/components/PlayButtonView.js +255 -94
- package/lib/module/components/PlayButtonView.js.map +1 -1
- package/lib/module/components/ReconnectingView.js +16 -13
- package/lib/module/components/ReconnectingView.js.map +1 -1
- package/lib/module/components/WarningView.js +12 -10
- package/lib/module/components/WarningView.js.map +1 -1
- package/lib/module/components/index.js +12 -10
- package/lib/module/components/index.js.map +1 -1
- package/lib/module/icons/captions@1x.png +0 -0
- package/lib/module/icons/captions@2x.png +0 -0
- package/lib/module/icons/pause@1x.png +0 -0
- package/lib/module/icons/pause@2x.png +0 -0
- package/lib/module/icons/play@1x.png +0 -0
- package/lib/module/icons/play@2x.png +0 -0
- package/lib/module/index.js +14 -222
- package/lib/module/index.js.map +1 -1
- package/lib/module/sdk/LiveVoiceSdk.js +371 -0
- package/lib/module/sdk/LiveVoiceSdk.js.map +1 -0
- package/lib/module/sdk/LiveVoiceState.js +66 -0
- package/lib/module/sdk/LiveVoiceState.js.map +1 -0
- package/lib/module/specs/NativeLiveVoiceSdk.js +16 -10
- package/lib/module/specs/NativeLiveVoiceSdk.js.map +1 -1
- package/lib/module/util/Colors.js +14 -11
- package/lib/module/util/Colors.js.map +1 -1
- package/lib/module/util/ForegroundServiceConfig.js +21 -11
- package/lib/module/util/ForegroundServiceConfig.js.map +1 -1
- package/lib/module/util/PlayingState.js +12 -10
- package/lib/module/util/PlayingState.js.map +1 -1
- package/lib/module/util/Translations.js +12 -10
- package/lib/module/util/Translations.js.map +1 -1
- package/lib/module/util/logger.js +76 -0
- package/lib/module/util/logger.js.map +1 -0
- package/lib/typescript/package.json +1 -0
- package/lib/typescript/src/components/AudioOutputSwitchView.d.ts.map +1 -0
- package/lib/typescript/src/components/BrandingView.d.ts.map +1 -0
- package/lib/typescript/{commonjs/src → src}/components/ChannelView.d.ts +4 -2
- package/lib/typescript/src/components/ChannelView.d.ts.map +1 -0
- package/lib/typescript/src/components/ErrorView.d.ts.map +1 -0
- package/lib/typescript/src/components/LiveVoiceView.d.ts +28 -0
- package/lib/typescript/src/components/LiveVoiceView.d.ts.map +1 -0
- package/lib/typescript/src/components/PlayButtonView.d.ts +341 -0
- package/lib/typescript/src/components/PlayButtonView.d.ts.map +1 -0
- package/lib/typescript/src/components/ReconnectingView.d.ts.map +1 -0
- package/lib/typescript/src/components/WarningView.d.ts.map +1 -0
- package/lib/typescript/src/components/index.d.ts.map +1 -0
- package/lib/typescript/src/index.d.ts +7 -0
- package/lib/typescript/src/index.d.ts.map +1 -0
- package/lib/typescript/src/sdk/LiveVoiceSdk.d.ts +210 -0
- package/lib/typescript/src/sdk/LiveVoiceSdk.d.ts.map +1 -0
- package/lib/typescript/src/sdk/LiveVoiceState.d.ts +12 -0
- package/lib/typescript/src/sdk/LiveVoiceState.d.ts.map +1 -0
- package/lib/typescript/{module/src → src}/specs/NativeLiveVoiceSdk.d.ts +6 -3
- package/lib/typescript/src/specs/NativeLiveVoiceSdk.d.ts.map +1 -0
- package/lib/typescript/{commonjs/src → src}/util/Colors.d.ts +2 -1
- package/lib/typescript/src/util/Colors.d.ts.map +1 -0
- package/lib/typescript/src/util/ForegroundServiceConfig.d.ts +19 -0
- package/lib/typescript/src/util/ForegroundServiceConfig.d.ts.map +1 -0
- package/lib/typescript/src/util/PlayingState.d.ts.map +1 -0
- package/lib/typescript/src/util/Translations.d.ts.map +1 -0
- package/lib/typescript/src/util/UIState.d.ts +86 -0
- package/lib/typescript/src/util/UIState.d.ts.map +1 -0
- package/lib/typescript/src/util/logger.d.ts +23 -0
- package/lib/typescript/src/util/logger.d.ts.map +1 -0
- package/livevoice-sdk-react-native.podspec +20 -41
- package/package.json +41 -122
- package/src/components/AudioOutputSwitchView.tsx +13 -13
- package/src/components/BrandingView.tsx +13 -11
- package/src/components/ChannelView.tsx +32 -36
- package/src/components/ErrorView.tsx +12 -10
- package/src/components/LiveVoiceView.tsx +231 -89
- package/src/components/PlayButtonView.tsx +293 -98
- package/src/components/ReconnectingView.tsx +20 -13
- package/src/components/WarningView.tsx +12 -10
- package/src/components/index.tsx +12 -10
- package/src/icons/captions@1x.png +0 -0
- package/src/icons/captions@2x.png +0 -0
- package/src/icons/pause@1x.png +0 -0
- package/src/icons/pause@2x.png +0 -0
- package/src/icons/play@1x.png +0 -0
- package/src/icons/play@2x.png +0 -0
- package/src/index.tsx +19 -236
- package/src/sdk/LiveVoiceSdk.ts +408 -0
- package/src/sdk/LiveVoiceState.ts +89 -0
- package/src/specs/NativeLiveVoiceSdk.ts +24 -16
- package/src/util/Colors.ts +15 -11
- package/src/util/ForegroundServiceConfig.tsx +21 -11
- package/src/util/PlayingState.ts +12 -10
- package/src/util/Translations.ts +12 -10
- package/src/util/UIState.ts +54 -13
- package/src/util/logger.ts +92 -0
- package/android/generated/java/io/livevoice/react/NativeLiveVoiceSdkSpec.java +0 -186
- package/android/generated/jni/CMakeLists.txt +0 -36
- package/android/generated/jni/RNLiveVoiceSpec-generated.cpp +0 -235
- package/android/generated/jni/RNLiveVoiceSpec.h +0 -31
- package/android/generated/jni/react/renderer/components/RNLiveVoiceSpec/RNLiveVoiceSpecJSI-generated.cpp +0 -245
- package/android/generated/jni/react/renderer/components/RNLiveVoiceSpec/RNLiveVoiceSpecJSI.h +0 -398
- package/android/src/main/AndroidManifest.xml +0 -3
- package/android/src/main/java/io/livevoice/react/Mappings.kt +0 -54
- package/android/src/main/java/io/livevoice/react/NativeModels.kt +0 -77
- package/ios/LivevoiceSdkReactNative.mm +0 -250
- package/ios/generated/RNLiveVoiceSpec/RNLiveVoiceSpec-generated.mm +0 -292
- package/ios/generated/RNLiveVoiceSpec/RNLiveVoiceSpec.h +0 -101
- package/ios/generated/RNLiveVoiceSpecJSI-generated.cpp +0 -245
- package/ios/generated/RNLiveVoiceSpecJSI.h +0 -398
- package/lib/commonjs/components/AudioOutputSwitchView.js +0 -144
- package/lib/commonjs/components/AudioOutputSwitchView.js.map +0 -1
- package/lib/commonjs/components/BrandingView.js +0 -78
- package/lib/commonjs/components/BrandingView.js.map +0 -1
- package/lib/commonjs/components/ChannelView.js +0 -117
- package/lib/commonjs/components/ChannelView.js.map +0 -1
- package/lib/commonjs/components/ErrorView.js +0 -88
- package/lib/commonjs/components/ErrorView.js.map +0 -1
- package/lib/commonjs/components/LiveVoiceView.js +0 -107
- package/lib/commonjs/components/LiveVoiceView.js.map +0 -1
- package/lib/commonjs/components/PlayButtonView.js +0 -161
- package/lib/commonjs/components/PlayButtonView.js.map +0 -1
- package/lib/commonjs/components/ReconnectingView.js +0 -109
- package/lib/commonjs/components/ReconnectingView.js.map +0 -1
- package/lib/commonjs/components/WarningView.js +0 -58
- package/lib/commonjs/components/WarningView.js.map +0 -1
- package/lib/commonjs/components/index.js +0 -94
- package/lib/commonjs/components/index.js.map +0 -1
- package/lib/commonjs/icons/branding.png +0 -0
- package/lib/commonjs/icons/cpu.png +0 -0
- package/lib/commonjs/icons/headphones.png +0 -0
- package/lib/commonjs/icons/mic.png +0 -0
- package/lib/commonjs/icons/pause.png +0 -0
- package/lib/commonjs/icons/play.png +0 -0
- package/lib/commonjs/icons/speaker.png +0 -0
- package/lib/commonjs/index.js +0 -327
- package/lib/commonjs/index.js.map +0 -1
- package/lib/commonjs/specs/NativeLiveVoiceSdk.js +0 -19
- package/lib/commonjs/specs/NativeLiveVoiceSdk.js.map +0 -1
- package/lib/commonjs/util/Colors.js +0 -30
- package/lib/commonjs/util/Colors.js.map +0 -1
- package/lib/commonjs/util/ForegroundServiceConfig.js +0 -33
- package/lib/commonjs/util/ForegroundServiceConfig.js.map +0 -1
- package/lib/commonjs/util/PlayingState.js +0 -24
- package/lib/commonjs/util/PlayingState.js.map +0 -1
- package/lib/commonjs/util/Translations.js +0 -47
- package/lib/commonjs/util/Translations.js.map +0 -1
- package/lib/commonjs/util/UIState.js +0 -6
- package/lib/commonjs/util/UIState.js.map +0 -1
- package/lib/module/icons/pause.png +0 -0
- package/lib/module/icons/play.png +0 -0
- package/lib/typescript/commonjs/package.json +0 -1
- package/lib/typescript/commonjs/src/components/AudioOutputSwitchView.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/components/BrandingView.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/components/ChannelView.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/components/ErrorView.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/components/LiveVoiceView.d.ts +0 -6
- package/lib/typescript/commonjs/src/components/LiveVoiceView.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/components/PlayButtonView.d.ts +0 -146
- package/lib/typescript/commonjs/src/components/PlayButtonView.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/components/ReconnectingView.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/components/WarningView.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/components/index.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/index.d.ts +0 -149
- package/lib/typescript/commonjs/src/index.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/specs/NativeLiveVoiceSdk.d.ts +0 -48
- package/lib/typescript/commonjs/src/specs/NativeLiveVoiceSdk.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/util/Colors.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/util/ForegroundServiceConfig.d.ts +0 -12
- package/lib/typescript/commonjs/src/util/ForegroundServiceConfig.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/util/PlayingState.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/util/Translations.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/util/UIState.d.ts +0 -45
- package/lib/typescript/commonjs/src/util/UIState.d.ts.map +0 -1
- package/lib/typescript/module/src/components/AudioOutputSwitchView.d.ts +0 -6
- package/lib/typescript/module/src/components/AudioOutputSwitchView.d.ts.map +0 -1
- package/lib/typescript/module/src/components/BrandingView.d.ts +0 -6
- package/lib/typescript/module/src/components/BrandingView.d.ts.map +0 -1
- package/lib/typescript/module/src/components/ChannelView.d.ts +0 -13
- package/lib/typescript/module/src/components/ChannelView.d.ts.map +0 -1
- package/lib/typescript/module/src/components/ErrorView.d.ts +0 -9
- package/lib/typescript/module/src/components/ErrorView.d.ts.map +0 -1
- package/lib/typescript/module/src/components/LiveVoiceView.d.ts +0 -6
- package/lib/typescript/module/src/components/LiveVoiceView.d.ts.map +0 -1
- package/lib/typescript/module/src/components/PlayButtonView.d.ts +0 -146
- package/lib/typescript/module/src/components/PlayButtonView.d.ts.map +0 -1
- package/lib/typescript/module/src/components/ReconnectingView.d.ts +0 -9
- package/lib/typescript/module/src/components/ReconnectingView.d.ts.map +0 -1
- package/lib/typescript/module/src/components/WarningView.d.ts +0 -8
- package/lib/typescript/module/src/components/WarningView.d.ts.map +0 -1
- package/lib/typescript/module/src/components/index.d.ts +0 -9
- package/lib/typescript/module/src/components/index.d.ts.map +0 -1
- package/lib/typescript/module/src/index.d.ts +0 -149
- package/lib/typescript/module/src/index.d.ts.map +0 -1
- package/lib/typescript/module/src/specs/NativeLiveVoiceSdk.d.ts.map +0 -1
- package/lib/typescript/module/src/util/Colors.d.ts +0 -13
- package/lib/typescript/module/src/util/Colors.d.ts.map +0 -1
- package/lib/typescript/module/src/util/ForegroundServiceConfig.d.ts +0 -12
- package/lib/typescript/module/src/util/ForegroundServiceConfig.d.ts.map +0 -1
- package/lib/typescript/module/src/util/PlayingState.d.ts +0 -7
- package/lib/typescript/module/src/util/PlayingState.d.ts.map +0 -1
- package/lib/typescript/module/src/util/Translations.d.ts +0 -22
- package/lib/typescript/module/src/util/Translations.d.ts.map +0 -1
- package/lib/typescript/module/src/util/UIState.d.ts +0 -45
- package/lib/typescript/module/src/util/UIState.d.ts.map +0 -1
- package/react-native.config.js +0 -12
- package/src/icons/pause.png +0 -0
- package/src/icons/play.png +0 -0
- /package/lib/{typescript/module → module}/package.json +0 -0
- /package/lib/typescript/{commonjs/src → src}/components/AudioOutputSwitchView.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/components/BrandingView.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/components/ErrorView.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/components/ReconnectingView.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/components/WarningView.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/components/index.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/util/PlayingState.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/util/Translations.d.ts +0 -0
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
//===----------------------------------------------------------------------===//
|
|
4
|
+
//
|
|
5
|
+
// This source file is part of the LiveVoice SDK project
|
|
6
|
+
//
|
|
7
|
+
// Copyright (c) LiveVoice GmbH
|
|
8
|
+
// Licensed under the MIT license
|
|
9
|
+
//
|
|
10
|
+
// See LICENSE for license information
|
|
11
|
+
//
|
|
12
|
+
// SPDX-License-Identifier: MIT
|
|
13
|
+
//
|
|
14
|
+
//===----------------------------------------------------------------------===//
|
|
15
|
+
|
|
16
|
+
// Internal state accessors used by LiveVoiceView. These are intentionally NOT re-exported from
|
|
17
|
+
// the package entry point (`src/index.tsx`); the public, app-facing way to consume state is the
|
|
18
|
+
// `renderChannel` prop on `LiveVoiceView`. The deprecated public wrappers in `LiveVoiceSdk.ts`
|
|
19
|
+
// delegate here, which keeps the SDK's own usage free of deprecation warnings.
|
|
20
|
+
|
|
21
|
+
import LiveVoiceSdkReactNative from "../specs/NativeLiveVoiceSdk.js";
|
|
22
|
+
import { logUiState } from "../util/logger.js";
|
|
23
|
+
|
|
24
|
+
/** Authorization features for the joined event. Internal: the view uses it for branding/gating. */
|
|
25
|
+
|
|
26
|
+
export function getCurrentClaims() {
|
|
27
|
+
const claims = LiveVoiceSdkReactNative.getCurrentClaims();
|
|
28
|
+
if (claims == null) return null;
|
|
29
|
+
return JSON.parse(claims);
|
|
30
|
+
}
|
|
31
|
+
export function getCurrentUiState() {
|
|
32
|
+
return parseUiState(LiveVoiceSdkReactNative.getCurrentUiState());
|
|
33
|
+
}
|
|
34
|
+
export function onUiStateChanged(handler) {
|
|
35
|
+
return LiveVoiceSdkReactNative.onUiStateChanged(data => {
|
|
36
|
+
const state = parseUiState(data);
|
|
37
|
+
logUiState(state);
|
|
38
|
+
handler(state);
|
|
39
|
+
});
|
|
40
|
+
}
|
|
41
|
+
function parseUiState(data) {
|
|
42
|
+
return hydrateUiState(JSON.parse(data));
|
|
43
|
+
}
|
|
44
|
+
function hydrateUiState(state) {
|
|
45
|
+
if (state.type === 'ready') {
|
|
46
|
+
const {
|
|
47
|
+
isHeadphonesOnly: _ignored,
|
|
48
|
+
...publicState
|
|
49
|
+
} = state;
|
|
50
|
+
return publicState;
|
|
51
|
+
}
|
|
52
|
+
if (state.type !== 'reconnecting') {
|
|
53
|
+
return state;
|
|
54
|
+
}
|
|
55
|
+
if (state.state.type !== 'awaitingRetry') {
|
|
56
|
+
return state;
|
|
57
|
+
}
|
|
58
|
+
return {
|
|
59
|
+
...state,
|
|
60
|
+
state: {
|
|
61
|
+
...state.state,
|
|
62
|
+
retryAt: new Date(state.state.atTimestamp * 1000)
|
|
63
|
+
}
|
|
64
|
+
};
|
|
65
|
+
}
|
|
66
|
+
//# sourceMappingURL=LiveVoiceState.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["LiveVoiceSdkReactNative","logUiState","getCurrentClaims","claims","JSON","parse","getCurrentUiState","parseUiState","onUiStateChanged","handler","data","state","hydrateUiState","type","isHeadphonesOnly","_ignored","publicState","retryAt","Date","atTimestamp"],"sourceRoot":"../../../src","sources":["sdk/LiveVoiceState.ts"],"mappings":";;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;;AAEA,OAAOA,uBAAuB,MAAM,gCAA6B;AAEjE,SAASC,UAAU,QAAQ,mBAAgB;;AAE3C;;AAqBA,OAAO,SAASC,gBAAgBA,CAAA,EAAkB;EAChD,MAAMC,MAAM,GAAGH,uBAAuB,CAACE,gBAAgB,CAAC,CAAC;EACzD,IAAIC,MAAM,IAAI,IAAI,EAAE,OAAO,IAAI;EAC/B,OAAOC,IAAI,CAACC,KAAK,CAACF,MAAM,CAAC;AAC3B;AAEA,OAAO,SAASG,iBAAiBA,CAAA,EAAY;EAC3C,OAAOC,YAAY,CAACP,uBAAuB,CAACM,iBAAiB,CAAC,CAAC,CAAC;AAClE;AAEA,OAAO,SAASE,gBAAgBA,CAACC,OAA+B,EAE9D;EACA,OAAOT,uBAAuB,CAACQ,gBAAgB,CAAEE,IAAY,IAAK;IAChE,MAAMC,KAAK,GAAGJ,YAAY,CAACG,IAAI,CAAC;IAChCT,UAAU,CAACU,KAAK,CAAC;IACjBF,OAAO,CAACE,KAAK,CAAC;EAChB,CAAC,CAAC;AACJ;AAEA,SAASJ,YAAYA,CAACG,IAAY,EAAW;EAC3C,OAAOE,cAAc,CAACR,IAAI,CAACC,KAAK,CAACK,IAAI,CAAgB,CAAC;AACxD;AAEA,SAASE,cAAcA,CAACD,KAAkB,EAAW;EACnD,IAAIA,KAAK,CAACE,IAAI,KAAK,OAAO,EAAE;IAC1B,MAAM;MAAEC,gBAAgB,EAAEC,QAAQ;MAAE,GAAGC;IAAY,CAAC,GAAGL,KAAK;IAC5D,OAAOK,WAAW;EACpB;EAEA,IAAIL,KAAK,CAACE,IAAI,KAAK,cAAc,EAAE;IACjC,OAAOF,KAAK;EACd;EAEA,IAAIA,KAAK,CAACA,KAAK,CAACE,IAAI,KAAK,eAAe,EAAE;IACxC,OAAOF,KAAK;EACd;EAEA,OAAO;IACL,GAAGA,KAAK;IACRA,KAAK,EAAE;MACL,GAAGA,KAAK,CAACA,KAAK;MACdM,OAAO,EAAE,IAAIC,IAAI,CAACP,KAAK,CAACA,KAAK,CAACQ,WAAW,GAAG,IAAI;IAClD;EACF,CAAC;AACH","ignoreList":[]}
|
|
@@ -1,16 +1,22 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
3
|
+
//===----------------------------------------------------------------------===//
|
|
4
|
+
//
|
|
5
|
+
// This source file is part of the LiveVoice SDK project
|
|
6
|
+
//
|
|
7
|
+
// Copyright (c) LiveVoice GmbH
|
|
8
|
+
// Licensed under the MIT license
|
|
9
|
+
//
|
|
10
|
+
// See LICENSE for license information
|
|
11
|
+
//
|
|
12
|
+
// SPDX-License-Identifier: MIT
|
|
13
|
+
//
|
|
14
|
+
//===----------------------------------------------------------------------===//
|
|
13
15
|
|
|
14
16
|
import { TurboModuleRegistry } from 'react-native';
|
|
17
|
+
|
|
18
|
+
// Type alias is required for backwards compatibility with RN < 0.80 codegen parsers
|
|
19
|
+
// which statically look for the exact identifier name 'EventEmitter'
|
|
20
|
+
|
|
15
21
|
export default TurboModuleRegistry.getEnforcing('LiveVoiceModule');
|
|
16
22
|
//# sourceMappingURL=NativeLiveVoiceSdk.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["TurboModuleRegistry","getEnforcing"],"sourceRoot":"../../../src","sources":["specs/NativeLiveVoiceSdk.ts"],"mappings":";;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;
|
|
1
|
+
{"version":3,"names":["TurboModuleRegistry","getEnforcing"],"sourceRoot":"../../../src","sources":["specs/NativeLiveVoiceSdk.ts"],"mappings":";;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,SAASA,mBAAmB,QAA6C,cAAc;;AAEvF;AACA;;AAoEA,eAAeA,mBAAmB,CAACC,YAAY,CAAO,iBAAiB,CAAC","ignoreList":[]}
|
|
@@ -1,23 +1,26 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
3
|
+
//===----------------------------------------------------------------------===//
|
|
4
|
+
//
|
|
5
|
+
// This source file is part of the LiveVoice SDK project
|
|
6
|
+
//
|
|
7
|
+
// Copyright (c) LiveVoice GmbH
|
|
8
|
+
// Licensed under the MIT license
|
|
9
|
+
//
|
|
10
|
+
// See LICENSE for license information
|
|
11
|
+
//
|
|
12
|
+
// SPDX-License-Identifier: MIT
|
|
13
|
+
//
|
|
14
|
+
//===----------------------------------------------------------------------===//
|
|
13
15
|
|
|
14
16
|
export const COLORS = {
|
|
15
17
|
primary: '#F1521B',
|
|
16
|
-
primaryOutline: 'rgba(241, 82, 27, 0.2)',
|
|
17
18
|
bg: '#F5F5F5',
|
|
18
19
|
bgDark: '#1E1F23',
|
|
19
20
|
cardBg: '#fff',
|
|
20
21
|
cardBgDark: '#212429',
|
|
22
|
+
divider: '#f0f0f0',
|
|
23
|
+
dividerDark: '#333333',
|
|
21
24
|
white: '#fff',
|
|
22
25
|
black: '#191919',
|
|
23
26
|
gray: '#808080',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["COLORS","primary","
|
|
1
|
+
{"version":3,"names":["COLORS","primary","bg","bgDark","cardBg","cardBgDark","divider","dividerDark","white","black","gray"],"sourceRoot":"../../../src","sources":["util/Colors.ts"],"mappings":";;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,OAAO,MAAMA,MAAM,GAAG;EACpBC,OAAO,EAAE,SAAS;EAElBC,EAAE,EAAE,SAAS;EACbC,MAAM,EAAE,SAAS;EAEjBC,MAAM,EAAE,MAAM;EACdC,UAAU,EAAE,SAAS;EAErBC,OAAO,EAAE,SAAS;EAClBC,WAAW,EAAE,SAAS;EAEtBC,KAAK,EAAE,MAAM;EACbC,KAAK,EAAE,SAAS;EAChBC,IAAI,EAAE,SAAS;EAEf,UAAU,EAAE;AACd,CAAC","ignoreList":[]}
|
|
@@ -1,25 +1,35 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
3
|
+
//===----------------------------------------------------------------------===//
|
|
4
|
+
//
|
|
5
|
+
// This source file is part of the LiveVoice SDK project
|
|
6
|
+
//
|
|
7
|
+
// Copyright (c) LiveVoice GmbH
|
|
8
|
+
// Licensed under the MIT license
|
|
9
|
+
//
|
|
10
|
+
// See LICENSE for license information
|
|
11
|
+
//
|
|
12
|
+
// SPDX-License-Identifier: MIT
|
|
13
|
+
//
|
|
14
|
+
//===----------------------------------------------------------------------===//
|
|
13
15
|
|
|
14
16
|
// Define the union type and interfaces
|
|
15
17
|
|
|
18
|
+
/**
|
|
19
|
+
* Sentinel sent to the native module to request the SDK's built-in default notification
|
|
20
|
+
* message. The Android native module recognizes this exact string (see
|
|
21
|
+
* `DEFAULT_MESSAGE_SENTINEL` in `LiveVoiceModule.kt`) and substitutes the real default — the
|
|
22
|
+
* two must stay in sync. iOS ignores the foreground-service config entirely.
|
|
23
|
+
*/
|
|
24
|
+
export const DEFAULT_MESSAGE_SENTINEL = 'LV_NOTIFICATION_DEFAULT_MESSAGE';
|
|
25
|
+
|
|
16
26
|
// Named exports for the constants and function
|
|
17
27
|
export const serviceDisabled = {
|
|
18
28
|
type: 'Disabled'
|
|
19
29
|
};
|
|
20
30
|
export const serviceEnabledWithDefaultMessage = {
|
|
21
31
|
type: 'Enabled',
|
|
22
|
-
message:
|
|
32
|
+
message: DEFAULT_MESSAGE_SENTINEL
|
|
23
33
|
};
|
|
24
34
|
export const serviceEnabledWithMessage = message => ({
|
|
25
35
|
type: 'Enabled',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["serviceDisabled","type","serviceEnabledWithDefaultMessage","message","serviceEnabledWithMessage"],"sourceRoot":"../../../src","sources":["util/ForegroundServiceConfig.tsx"],"mappings":";;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;;AAYA;AACA,OAAO,MAAMA,eAAyB,GAAG;EAAEC,IAAI,EAAE;AAAW,CAAC;AAE7D,OAAO,MAAMC,gCAAyC,GAAG;EAAED,IAAI,EAAE,SAAS;EAAEE,OAAO,
|
|
1
|
+
{"version":3,"names":["DEFAULT_MESSAGE_SENTINEL","serviceDisabled","type","serviceEnabledWithDefaultMessage","message","serviceEnabledWithMessage"],"sourceRoot":"../../../src","sources":["util/ForegroundServiceConfig.tsx"],"mappings":";;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;;AAYA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMA,wBAAwB,GAAG,iCAAiC;;AAEzE;AACA,OAAO,MAAMC,eAAyB,GAAG;EAAEC,IAAI,EAAE;AAAW,CAAC;AAE7D,OAAO,MAAMC,gCAAyC,GAAG;EAAED,IAAI,EAAE,SAAS;EAAEE,OAAO,EAAEJ;AAAyB,CAAC;AAE/G,OAAO,MAAMK,yBAAyB,GAAID,OAAsB,KAAe;EAC7EF,IAAI,EAAE,SAAS;EACfE;AACF,CAAC,CAAC","ignoreList":[]}
|
|
@@ -1,15 +1,17 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
3
|
+
//===----------------------------------------------------------------------===//
|
|
4
|
+
//
|
|
5
|
+
// This source file is part of the LiveVoice SDK project
|
|
6
|
+
//
|
|
7
|
+
// Copyright (c) LiveVoice GmbH
|
|
8
|
+
// Licensed under the MIT license
|
|
9
|
+
//
|
|
10
|
+
// See LICENSE for license information
|
|
11
|
+
//
|
|
12
|
+
// SPDX-License-Identifier: MIT
|
|
13
|
+
//
|
|
14
|
+
//===----------------------------------------------------------------------===//
|
|
13
15
|
|
|
14
16
|
export let PlayingState = /*#__PURE__*/function (PlayingState) {
|
|
15
17
|
PlayingState["STOPPED"] = "STOPPED";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["PlayingState"],"sourceRoot":"../../../src","sources":["util/PlayingState.ts"],"mappings":";;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,WAAYA,YAAY,0BAAZA,YAAY;EAAZA,YAAY;EAAZA,YAAY;EAAZA,YAAY;EAAA,OAAZA,YAAY;AAAA;AAIvB","ignoreList":[]}
|
|
1
|
+
{"version":3,"names":["PlayingState"],"sourceRoot":"../../../src","sources":["util/PlayingState.ts"],"mappings":";;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,WAAYA,YAAY,0BAAZA,YAAY;EAAZA,YAAY;EAAZA,YAAY;EAAZA,YAAY;EAAA,OAAZA,YAAY;AAAA;AAIvB","ignoreList":[]}
|
|
@@ -1,15 +1,17 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
3
|
+
//===----------------------------------------------------------------------===//
|
|
4
|
+
//
|
|
5
|
+
// This source file is part of the LiveVoice SDK project
|
|
6
|
+
//
|
|
7
|
+
// Copyright (c) LiveVoice GmbH
|
|
8
|
+
// Licensed under the MIT license
|
|
9
|
+
//
|
|
10
|
+
// See LICENSE for license information
|
|
11
|
+
//
|
|
12
|
+
// SPDX-License-Identifier: MIT
|
|
13
|
+
//
|
|
14
|
+
//===----------------------------------------------------------------------===//
|
|
13
15
|
|
|
14
16
|
/**
|
|
15
17
|
* @fileoverview Translated strings for the React Native SDK.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["LiveVoiceSdkReactNative","Translations","channelStatusOffline","noChannels","isAiChannelStatusMessage","sdkNoMatchingChannels","errorScreenRetrying","errorScreenRetryingIn","seconds","sdkErrorGeneric","sdkErrorInactive","sdkErrorInvalidApiKey","sdkErrorListenerLimitReached","sdkErrorNoNetwork","sdkErrorNotFound","sdkErrorRequestFailed","errorCode","sdkErrorWrongPassword","errorRetryNowButton","streamingByTitle","accessibilityChannelPlay","accessibilityChannelStatusMuted","accessibilityChannelStop"],"sourceRoot":"../../../src","sources":["util/Translations.ts"],"mappings":";;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA,OAAOA,uBAAuB,MAAM,gCAA6B;AAEjE,OAAO,MAAMC,YAAY,GAAG;EAC1BC,oBAAoB,EAAEA,CAAA,KAAcF,uBAAuB,CAACE,oBAAoB,CAAC,CAAC;EAClFC,UAAU,EAAEA,CAAA,KAAcH,uBAAuB,CAACG,UAAU,CAAC,CAAC;EAC9DC,wBAAwB,EAAEA,CAAA,KAAcJ,uBAAuB,CAACI,wBAAwB,CAAC,CAAC;EAC1FC,qBAAqB,EAAEA,CAAA,KAAcL,uBAAuB,CAACK,qBAAqB,CAAC,CAAC;EACpFC,mBAAmB,EAAEA,CAAA,KAAcN,uBAAuB,CAACM,mBAAmB,CAAC,CAAC;EAChFC,qBAAqB,EAAGC,OAAe,IAAaR,uBAAuB,CAACO,qBAAqB,CAACC,OAAO,CAAC;EAC1GC,eAAe,EAAEA,CAAA,KAAcT,uBAAuB,CAACS,eAAe,CAAC,CAAC;EACxEC,gBAAgB,EAAEA,CAAA,KAAcV,uBAAuB,CAACU,gBAAgB,CAAC,CAAC;EAC1EC,qBAAqB,EAAEA,CAAA,KAAcX,uBAAuB,CAACW,qBAAqB,CAAC,CAAC;EACpFC,4BAA4B,EAAEA,CAAA,KAAcZ,uBAAuB,CAACY,4BAA4B,CAAC,CAAC;EAClGC,iBAAiB,EAAEA,CAAA,KAAcb,uBAAuB,CAACa,iBAAiB,CAAC,CAAC;EAC5EC,gBAAgB,EAAEA,CAAA,KAAcd,uBAAuB,CAACc,gBAAgB,CAAC,CAAC;EAC1EC,qBAAqB,EAAGC,SAAiB,IAAahB,uBAAuB,CAACe,qBAAqB,CAACC,SAAS,CAAC;EAC9GC,qBAAqB,EAAEA,CAAA,KAAcjB,uBAAuB,CAACiB,qBAAqB,CAAC,CAAC;EACpFC,mBAAmB,EAAEA,CAAA,KAAclB,uBAAuB,CAACkB,mBAAmB,CAAC,CAAC;EAChFC,gBAAgB,EAAEA,CAAA,KAAcnB,uBAAuB,CAACmB,gBAAgB,CAAC,CAAC;EAC1EC,wBAAwB,EAAEA,CAAA,KAAcpB,uBAAuB,CAACoB,wBAAwB,CAAC,CAAC;EAC1FC,+BAA+B,EAAEA,CAAA,KAAcrB,uBAAuB,CAACqB,+BAA+B,CAAC,CAAC;EACxGC,wBAAwB,EAAEA,CAAA,KAActB,uBAAuB,CAACsB,wBAAwB,CAAC;AAC3F,CAAC","ignoreList":[]}
|
|
1
|
+
{"version":3,"names":["LiveVoiceSdkReactNative","Translations","channelStatusOffline","noChannels","isAiChannelStatusMessage","sdkNoMatchingChannels","errorScreenRetrying","errorScreenRetryingIn","seconds","sdkErrorGeneric","sdkErrorInactive","sdkErrorInvalidApiKey","sdkErrorListenerLimitReached","sdkErrorNoNetwork","sdkErrorNotFound","sdkErrorRequestFailed","errorCode","sdkErrorWrongPassword","errorRetryNowButton","streamingByTitle","accessibilityChannelPlay","accessibilityChannelStatusMuted","accessibilityChannelStop"],"sourceRoot":"../../../src","sources":["util/Translations.ts"],"mappings":";;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA;AACA;AACA;AACA;AACA;AACA,OAAOA,uBAAuB,MAAM,gCAA6B;AAEjE,OAAO,MAAMC,YAAY,GAAG;EAC1BC,oBAAoB,EAAEA,CAAA,KAAcF,uBAAuB,CAACE,oBAAoB,CAAC,CAAC;EAClFC,UAAU,EAAEA,CAAA,KAAcH,uBAAuB,CAACG,UAAU,CAAC,CAAC;EAC9DC,wBAAwB,EAAEA,CAAA,KAAcJ,uBAAuB,CAACI,wBAAwB,CAAC,CAAC;EAC1FC,qBAAqB,EAAEA,CAAA,KAAcL,uBAAuB,CAACK,qBAAqB,CAAC,CAAC;EACpFC,mBAAmB,EAAEA,CAAA,KAAcN,uBAAuB,CAACM,mBAAmB,CAAC,CAAC;EAChFC,qBAAqB,EAAGC,OAAe,IAAaR,uBAAuB,CAACO,qBAAqB,CAACC,OAAO,CAAC;EAC1GC,eAAe,EAAEA,CAAA,KAAcT,uBAAuB,CAACS,eAAe,CAAC,CAAC;EACxEC,gBAAgB,EAAEA,CAAA,KAAcV,uBAAuB,CAACU,gBAAgB,CAAC,CAAC;EAC1EC,qBAAqB,EAAEA,CAAA,KAAcX,uBAAuB,CAACW,qBAAqB,CAAC,CAAC;EACpFC,4BAA4B,EAAEA,CAAA,KAAcZ,uBAAuB,CAACY,4BAA4B,CAAC,CAAC;EAClGC,iBAAiB,EAAEA,CAAA,KAAcb,uBAAuB,CAACa,iBAAiB,CAAC,CAAC;EAC5EC,gBAAgB,EAAEA,CAAA,KAAcd,uBAAuB,CAACc,gBAAgB,CAAC,CAAC;EAC1EC,qBAAqB,EAAGC,SAAiB,IAAahB,uBAAuB,CAACe,qBAAqB,CAACC,SAAS,CAAC;EAC9GC,qBAAqB,EAAEA,CAAA,KAAcjB,uBAAuB,CAACiB,qBAAqB,CAAC,CAAC;EACpFC,mBAAmB,EAAEA,CAAA,KAAclB,uBAAuB,CAACkB,mBAAmB,CAAC,CAAC;EAChFC,gBAAgB,EAAEA,CAAA,KAAcnB,uBAAuB,CAACmB,gBAAgB,CAAC,CAAC;EAC1EC,wBAAwB,EAAEA,CAAA,KAAcpB,uBAAuB,CAACoB,wBAAwB,CAAC,CAAC;EAC1FC,+BAA+B,EAAEA,CAAA,KAAcrB,uBAAuB,CAACqB,+BAA+B,CAAC,CAAC;EACxGC,wBAAwB,EAAEA,CAAA,KAActB,uBAAuB,CAACsB,wBAAwB,CAAC;AAC3F,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
//===----------------------------------------------------------------------===//
|
|
4
|
+
//
|
|
5
|
+
// This source file is part of the LiveVoice SDK project
|
|
6
|
+
//
|
|
7
|
+
// Copyright (c) LiveVoice GmbH
|
|
8
|
+
// Licensed under the MIT license
|
|
9
|
+
//
|
|
10
|
+
// See LICENSE for license information
|
|
11
|
+
//
|
|
12
|
+
// SPDX-License-Identifier: MIT
|
|
13
|
+
//
|
|
14
|
+
//===----------------------------------------------------------------------===//
|
|
15
|
+
|
|
16
|
+
export const LiveVoiceLogEvent = {
|
|
17
|
+
init: "LV_INIT",
|
|
18
|
+
joinRequest: "LV_JOIN_REQUEST",
|
|
19
|
+
leave: "LV_LEAVE",
|
|
20
|
+
reconnectRequest: "LV_RECONNECT_REQUEST",
|
|
21
|
+
uiState: "LV_UI_STATE",
|
|
22
|
+
audioOutputSet: "LV_AUDIO_OUTPUT_SET",
|
|
23
|
+
audioOutputChanged: "LV_AUDIO_OUTPUT_CHANGED",
|
|
24
|
+
channelStart: "LV_CHANNEL_START",
|
|
25
|
+
channelStop: "LV_CHANNEL_STOP",
|
|
26
|
+
subtitlesStart: "LV_SUBTITLES_START",
|
|
27
|
+
subtitlesStop: "LV_SUBTITLES_STOP",
|
|
28
|
+
openWebsite: "LV_OPEN_WEBSITE"
|
|
29
|
+
};
|
|
30
|
+
export function logInfo(event, fields) {
|
|
31
|
+
console.info(formatMessage("INFO", event, fields));
|
|
32
|
+
}
|
|
33
|
+
export function logUiState(state) {
|
|
34
|
+
logInfo(LiveVoiceLogEvent.uiState, describeUiState(state));
|
|
35
|
+
}
|
|
36
|
+
export function logAudioOutputChanged(useSpeaker) {
|
|
37
|
+
logInfo(LiveVoiceLogEvent.audioOutputChanged, {
|
|
38
|
+
mode: useSpeaker ? "speaker" : "receiver"
|
|
39
|
+
});
|
|
40
|
+
}
|
|
41
|
+
export function describeForegroundServiceConfig(serviceConfig) {
|
|
42
|
+
if (serviceConfig.type === "Disabled") return "disabled";
|
|
43
|
+
return serviceConfig.message == null ? "default" : "custom";
|
|
44
|
+
}
|
|
45
|
+
function describeUiState(state) {
|
|
46
|
+
switch (state.type) {
|
|
47
|
+
case "loading":
|
|
48
|
+
return {
|
|
49
|
+
type: "loading"
|
|
50
|
+
};
|
|
51
|
+
case "ready":
|
|
52
|
+
return {
|
|
53
|
+
channelCount: state.channels.length,
|
|
54
|
+
outputMode: state.outputMode,
|
|
55
|
+
type: "ready"
|
|
56
|
+
};
|
|
57
|
+
case "error":
|
|
58
|
+
return {
|
|
59
|
+
canBeRetried: state.canBeRetried,
|
|
60
|
+
type: "error"
|
|
61
|
+
};
|
|
62
|
+
case "reconnecting":
|
|
63
|
+
return {
|
|
64
|
+
retryState: describeRetryState(state.state),
|
|
65
|
+
type: "reconnecting"
|
|
66
|
+
};
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
function describeRetryState(state) {
|
|
70
|
+
return state.type;
|
|
71
|
+
}
|
|
72
|
+
function formatMessage(level, event, fields) {
|
|
73
|
+
const fieldText = fields == null ? "" : Object.entries(fields).filter(([, value]) => value != null).sort(([left], [right]) => left.localeCompare(right)).map(([key, value]) => `${key}=${value}`).join(" ");
|
|
74
|
+
return ["[LiveVoiceSDK]", level, event, fieldText].filter(part => part.length > 0).join(" ");
|
|
75
|
+
}
|
|
76
|
+
//# sourceMappingURL=logger.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["LiveVoiceLogEvent","init","joinRequest","leave","reconnectRequest","uiState","audioOutputSet","audioOutputChanged","channelStart","channelStop","subtitlesStart","subtitlesStop","openWebsite","logInfo","event","fields","console","info","formatMessage","logUiState","state","describeUiState","logAudioOutputChanged","useSpeaker","mode","describeForegroundServiceConfig","serviceConfig","type","message","channelCount","channels","length","outputMode","canBeRetried","retryState","describeRetryState","level","fieldText","Object","entries","filter","value","sort","left","right","localeCompare","map","key","join","part"],"sourceRoot":"../../../src","sources":["util/logger.ts"],"mappings":"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","ignoreList":[]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"type":"module"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"AudioOutputSwitchView.d.ts","sourceRoot":"","sources":["../../../../src/components/AudioOutputSwitchView.tsx"],"names":[],"mappings":"AAcA,OAAO,KAAuC,MAAM,OAAO,CAAC;AAW5D,MAAM,WAAW,sBAAsB;IACrC,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB;AAED,eAAO,MAAM,qBAAqB,EAAE,KAAK,CAAC,EAAE,CAAC,sBAAsB,CA2ElE,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"BrandingView.d.ts","sourceRoot":"","sources":["../../../../src/components/BrandingView.tsx"],"names":[],"mappings":"AAaA,OAAO,KAAK,MAAM,OAAO,CAAC;AAa1B,MAAM,WAAW,aAAa;IAC5B,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB;AAED,eAAO,MAAM,YAAY,EAAE,KAAK,CAAC,EAAE,CAAC,aAAa,CAyBhD,CAAC"}
|
|
@@ -5,9 +5,11 @@ export interface ChannelProps {
|
|
|
5
5
|
playingState: PlayingState;
|
|
6
6
|
muted: boolean;
|
|
7
7
|
isOnline: boolean;
|
|
8
|
-
|
|
8
|
+
hasAudio: boolean;
|
|
9
|
+
hasSubtitles: boolean;
|
|
9
10
|
isDarkMode?: boolean;
|
|
10
|
-
|
|
11
|
+
onAudioPress?: () => void;
|
|
12
|
+
onSubtitlesPress?: () => void;
|
|
11
13
|
}
|
|
12
14
|
export declare const ChannelView: React.FC<ChannelProps>;
|
|
13
15
|
//# sourceMappingURL=ChannelView.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ChannelView.d.ts","sourceRoot":"","sources":["../../../../src/components/ChannelView.tsx"],"names":[],"mappings":"AAaA,OAAO,KAAmB,MAAM,OAAO,CAAC;AAGxC,OAAO,EAAE,KAAK,YAAY,EAAE,MAAM,sBAAsB,CAAC;AAIzD,MAAM,WAAW,YAAY;IAC3B,WAAW,EAAE,MAAM,CAAC;IACpB,YAAY,EAAE,YAAY,CAAC;IAC3B,KAAK,EAAE,OAAO,CAAC;IACf,QAAQ,EAAE,OAAO,CAAC;IAClB,QAAQ,EAAE,OAAO,CAAC;IAClB,YAAY,EAAE,OAAO,CAAC;IACtB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,YAAY,CAAC,EAAE,MAAM,IAAI,CAAC;IAC1B,gBAAgB,CAAC,EAAE,MAAM,IAAI,CAAC;CAC/B;AAED,eAAO,MAAM,WAAW,EAAE,KAAK,CAAC,EAAE,CAAC,YAAY,CA4C9C,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ErrorView.d.ts","sourceRoot":"","sources":["../../../../src/components/ErrorView.tsx"],"names":[],"mappings":"AAaA,OAAO,KAAK,MAAM,OAAO,CAAC;AAI1B,OAAO,EAAE,KAAK,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAElD,MAAM,WAAW,UAAU;IACzB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,KAAK,EAAE,UAAU,CAAA;IACjB,OAAO,EAAE,MAAM,IAAI,CAAC;CACrB;AAED,eAAO,MAAM,SAAS,EAAE,KAAK,CAAC,EAAE,CAAC,UAAU,CA6B1C,CAAC"}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { type Channel } from "../util/UIState";
|
|
2
|
+
/** Per-cell helpers passed to {@link LiveVoiceViewProps.renderChannel}, mirroring the native SDKs. */
|
|
3
|
+
export interface ChannelCellHelpers {
|
|
4
|
+
/** Whether this is the last channel in the (filtered) list — e.g. to omit a trailing divider. */
|
|
5
|
+
isLastInList: boolean;
|
|
6
|
+
/** Toggle audio for this channel: starts it if stopped, stops it if playing. */
|
|
7
|
+
onAudioPress: () => void;
|
|
8
|
+
}
|
|
9
|
+
/** Renders a custom channel cell. See {@link LiveVoiceViewProps.renderChannel}. */
|
|
10
|
+
export type RenderChannel = (channel: Channel, helpers: ChannelCellHelpers) => React.ReactNode;
|
|
11
|
+
export interface LiveVoiceViewProps {
|
|
12
|
+
isDarkMode?: boolean;
|
|
13
|
+
/**
|
|
14
|
+
* Return true for channels that should be displayed by the drop-in view.
|
|
15
|
+
*/
|
|
16
|
+
filter?: (channel: Channel) => boolean;
|
|
17
|
+
/**
|
|
18
|
+
* Render a custom channel cell instead of the default one.
|
|
19
|
+
*
|
|
20
|
+
* Requires an API key that permits custom UI. If a `renderChannel` is provided but the joined
|
|
21
|
+
* event's key doesn't allow custom UI, the view shows the invalid-api-key error instead — the
|
|
22
|
+
* same gating the native SDKs apply. When omitted, the default cell is used.
|
|
23
|
+
*/
|
|
24
|
+
renderChannel?: RenderChannel;
|
|
25
|
+
}
|
|
26
|
+
export declare const LiveVoiceView: React.FC<LiveVoiceViewProps>;
|
|
27
|
+
export default LiveVoiceView;
|
|
28
|
+
//# sourceMappingURL=LiveVoiceView.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"LiveVoiceView.d.ts","sourceRoot":"","sources":["../../../../src/components/LiveVoiceView.tsx"],"names":[],"mappings":"AAoCA,OAAO,EAAE,KAAK,OAAO,EAAgB,MAAM,iBAAiB,CAAC;AAG7D,sGAAsG;AACtG,MAAM,WAAW,kBAAkB;IACjC,iGAAiG;IACjG,YAAY,EAAE,OAAO,CAAC;IACtB,gFAAgF;IAChF,YAAY,EAAE,MAAM,IAAI,CAAC;CAC1B;AAED,mFAAmF;AACnF,MAAM,MAAM,aAAa,GAAG,CAC1B,OAAO,EAAE,OAAO,EAChB,OAAO,EAAE,kBAAkB,KACxB,KAAK,CAAC,SAAS,CAAC;AAErB,MAAM,WAAW,kBAAkB;IACjC,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB;;OAEG;IACH,MAAM,CAAC,EAAE,CAAC,OAAO,EAAE,OAAO,KAAK,OAAO,CAAC;IACvC;;;;;;OAMG;IACH,aAAa,CAAC,EAAE,aAAa,CAAC;CAC/B;AAiCD,eAAO,MAAM,aAAa,EAAE,KAAK,CAAC,EAAE,CAAC,kBAAkB,CAwKtD,CAAC;AAEF,eAAe,aAAa,CAAC"}
|