Skip to content

Commit 07e6846

Browse files
authored
Merge branch 'main' into md_bcsc_2636_remove_account_ios
2 parents 815415c + 2c44f6b commit 07e6846

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

53 files changed

+2924
-126
lines changed

.github/workflows/quality.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ jobs:
1515

1616
- uses: actions/setup-python@v4
1717
with:
18-
python-version: '3.11'
18+
python-version: "3.11"
1919

2020
- name: Setup NodeJS
2121
uses: ./.github/workflows/actions/setup-node
@@ -30,7 +30,7 @@ jobs:
3030

3131
- name: Install dependencies
3232
working-directory: app
33-
run: yarn install --immutable-cache
33+
run: yarn install --immutable
3434

3535
- name: Cache bcsc-core build output
3636
uses: actions/cache@v3
@@ -70,7 +70,7 @@ jobs:
7070

7171
- uses: actions/setup-python@v5
7272
with:
73-
python-version: '3.11'
73+
python-version: "3.11"
7474

7575
- name: Setup NodeJS
7676
uses: ./.github/workflows/actions/setup-node
@@ -85,7 +85,7 @@ jobs:
8585

8686
- name: Install dependencies
8787
working-directory: app
88-
run: yarn install --immutable-cache
88+
run: yarn install --immutable
8989

9090
- name: Automated testing
9191
run: yarn test

app/android/app/gradle.lockfile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -303,6 +303,7 @@ org.jetbrains.kotlinx:kotlinx-coroutines-core:1.6.4=_internal-unified-test-platf
303303
org.jetbrains.kotlinx:kotlinx-coroutines-core:1.8.1=debugCompileClasspath,debugRuntimeClasspath,debugUnitTestCompileClasspath,debugUnitTestRuntimeClasspath,releaseCompileClasspath,releaseRuntimeClasspath,releaseUnitTestCompileClasspath,releaseUnitTestRuntimeClasspath
304304
org.jetbrains:annotations:13.0=_internal-unified-test-platform-android-device-provider-gradle,_internal-unified-test-platform-android-test-plugin-host-additional-test-output,_internal-unified-test-platform-android-test-plugin-host-apk-installer,_internal-unified-test-platform-android-test-plugin-host-coverage,_internal-unified-test-platform-android-test-plugin-host-device-info,_internal-unified-test-platform-android-test-plugin-host-emulator-control,_internal-unified-test-platform-android-test-plugin-host-logcat,_internal-unified-test-platform-android-test-plugin-host-retention,_internal-unified-test-platform-android-test-plugin-result-listener-gradle,debugAndroidTestCompileClasspath,kotlinBuildToolsApiClasspath,kotlinCompilerClasspath,kotlinKlibCommonizerClasspath
305305
org.jetbrains:annotations:23.0.0=_internal-unified-test-platform-android-device-provider-ddmlib,debugCompileClasspath,debugRuntimeClasspath,debugUnitTestCompileClasspath,debugUnitTestRuntimeClasspath,releaseCompileClasspath,releaseRuntimeClasspath,releaseUnitTestCompileClasspath,releaseUnitTestRuntimeClasspath
306+
org.jitsi:webrtc:124.0.0=debugAndroidTestCompileClasspath,debugCompileClasspath,debugRuntimeClasspath,debugUnitTestCompileClasspath,debugUnitTestRuntimeClasspath,releaseCompileClasspath,releaseRuntimeClasspath,releaseUnitTestCompileClasspath,releaseUnitTestRuntimeClasspath
306307
org.ow2.asm:asm-analysis:9.2=androidJacocoAnt
307308
org.ow2.asm:asm-commons:9.2=androidJacocoAnt
308309
org.ow2.asm:asm-tree:9.2=androidJacocoAnt

app/android/app/src/main/AndroidManifest.xml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,12 @@
11
<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="ca.bc.gov.BCWallet"
22
xmlns:tools="http://schemas.android.com/tools">
3+
<uses-feature android:name="android.hardware.camera" />
4+
<uses-feature android:name="android.hardware.camera.autofocus" />
5+
<uses-feature android:name="android.hardware.audio.output" />
6+
<uses-feature android:name="android.hardware.microphone" />
7+
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
8+
<uses-permission android:name="android.permission.CHANGE_NETWORK_STATE" />
9+
<uses-permission android:name="android.permission.MODIFY_AUDIO_SETTINGS" />
310
<uses-permission android:name="android.permission.USE_BIOMETRIC" />
411
<uses-permission android:name="android.permission.USE_FINGERPRINT" />
512
<uses-permission android:name="android.permission.INTERNET" />
@@ -8,6 +15,13 @@
815
<uses-permission android:name="android.permission.CAMERA" />
916
<uses-permission android:name="android.permission.POST_NOTIFICATIONS" />
1017
<uses-permission android:name="android.permission.RECORD_AUDIO" />
18+
19+
<!-- Additional permissions for react-native-incall-manager (live call) -->
20+
<uses-permission android:name="android.permission.WAKE_LOCK" />
21+
<uses-permission android:name="android.permission.BLUETOOTH" />
22+
<uses-permission android:name="android.permission.BLUETOOTH_CONNECT" />
23+
<uses-permission android:name="android.permission.FOREGROUND_SERVICE" />
24+
<uses-permission android:name="android.permission.FOREGROUND_SERVICE_PHONE_CALL" />
1125

1226
<queries>
1327
<intent>

app/ios/AriesBifold/AppDelegate.mm

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
#import "AppDelegate.h"
22

3+
#import <WebRTCModuleOptions.h>
34
#import <Firebase.h>
45
#import <React/RCTBridge.h>
56
#import <React/RCTBundleURLProvider.h>
@@ -11,6 +12,9 @@ @implementation AppDelegate
1112

1213
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
1314
{
15+
// allows background WebRTC
16+
[WebRTCModuleOptions sharedInstance].enableMultitaskingCameraAccess = YES;
17+
1418
[FIRApp configure];
1519
self.moduleName = @"BCWallet";
1620
// You can add your custom initial props in the dictionary below.
@@ -20,7 +24,7 @@ - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(
2024
// Because certain file operations can reset resource values, we
2125
// excluded file’s resource values each time the application starts.
2226
[self excludeDotAFJFolderFromBackup];
23-
27+
2428
return [super application:application didFinishLaunchingWithOptions:launchOptions];
2529
}
2630

app/ios/AriesBifold/Info.plist

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,10 @@
6464
</dict>
6565
</dict>
6666
</dict>
67+
<key>NSBluetoothAlwaysUsageDescription</key>
68+
<string>$(PRODUCT_NAME) needs access to Bluetooth to manage audio routing during calls</string>
69+
<key>NSBluetoothPeripheralUsageDescription</key>
70+
<string>$(PRODUCT_NAME) needs access to Bluetooth to connect to audio devices during calls</string>
6771
<key>NSCameraUsageDescription</key>
6872
<string>Camera used for QR Code scanning and video calls</string>
6973
<key>NSFaceIDUsageDescription</key>
@@ -84,6 +88,8 @@
8488
<key>UIBackgroundModes</key>
8589
<array>
8690
<string>remote-notification</string>
91+
<string>audio</string>
92+
<string>voip</string>
8793
</array>
8894
<key>UILaunchStoryboardName</key>
8995
<string>LaunchScreen</string>

app/ios/Podfile.lock

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,9 @@ PODS:
153153
- React
154154
- React-callinvoker
155155
- React-Core
156+
- JitsiWebRTC (124.0.2)
156157
- libevent (2.1.12)
158+
- Mute (0.6.1)
157159
- nanopb (2.30908.0):
158160
- nanopb/decode (= 2.30908.0)
159161
- nanopb/encode (= 2.30908.0)
@@ -1070,6 +1072,12 @@ PODS:
10701072
- glog
10711073
- RCT-Folly (= 2022.05.16.00)
10721074
- React-Core
1075+
- react-native-volume-manager (1.10.0):
1076+
- Mute
1077+
- React-Core
1078+
- react-native-webrtc (124.0.6):
1079+
- JitsiWebRTC (~> 124.0.0)
1080+
- React-Core
10731081
- react-native-webview (13.10.7):
10741082
- glog
10751083
- RCT-Folly (= 2022.05.16.00)
@@ -1241,6 +1249,8 @@ PODS:
12411249
- React-jsi (= 0.73.11)
12421250
- React-logger (= 0.73.11)
12431251
- React-perflogger (= 0.73.11)
1252+
- ReactNativeIncallManager (4.2.1):
1253+
- React-Core
12441254
- RNArgon2 (2.0.1):
12451255
- CatCrypto
12461256
- React-Core
@@ -1349,6 +1359,8 @@ DEPENDENCIES:
13491359
- react-native-splash-screen (from `../node_modules/react-native-splash-screen`)
13501360
- react-native-tcp-socket (from `../node_modules/react-native-tcp-socket`)
13511361
- react-native-video (from `../node_modules/react-native-video`)
1362+
- react-native-volume-manager (from `../node_modules/react-native-volume-manager`)
1363+
- react-native-webrtc (from `../node_modules/react-native-webrtc`)
13521364
- react-native-webview (from `../node_modules/react-native-webview`)
13531365
- React-nativeconfig (from `../node_modules/react-native/ReactCommon`)
13541366
- React-NativeModulesApple (from `../node_modules/react-native/ReactCommon/react/nativemodule/core/platform/ios`)
@@ -1370,6 +1382,7 @@ DEPENDENCIES:
13701382
- React-runtimescheduler (from `../node_modules/react-native/ReactCommon/react/renderer/runtimescheduler`)
13711383
- React-utils (from `../node_modules/react-native/ReactCommon/react/utils`)
13721384
- ReactCommon/turbomodule/core (from `../node_modules/react-native/ReactCommon`)
1385+
- ReactNativeIncallManager (from `../node_modules/react-native-incall-manager`)
13731386
- RNArgon2 (from `../node_modules/react-native-argon2`)
13741387
- "RNCAsyncStorage (from `../node_modules/@react-native-async-storage/async-storage`)"
13751388
- "RNCClipboard (from `../node_modules/@react-native-clipboard/clipboard`)"
@@ -1404,7 +1417,9 @@ SPEC REPOS:
14041417
- GoogleAppMeasurement
14051418
- GoogleDataTransport
14061419
- GoogleUtilities
1420+
- JitsiWebRTC
14071421
- libevent
1422+
- Mute
14081423
- nanopb
14091424
- PromisesObjC
14101425
- SDWebImage
@@ -1498,6 +1513,10 @@ EXTERNAL SOURCES:
14981513
:path: "../node_modules/react-native-tcp-socket"
14991514
react-native-video:
15001515
:path: "../node_modules/react-native-video"
1516+
react-native-volume-manager:
1517+
:path: "../node_modules/react-native-volume-manager"
1518+
react-native-webrtc:
1519+
:path: "../node_modules/react-native-webrtc"
15011520
react-native-webview:
15021521
:path: "../node_modules/react-native-webview"
15031522
React-nativeconfig:
@@ -1540,6 +1559,8 @@ EXTERNAL SOURCES:
15401559
:path: "../node_modules/react-native/ReactCommon/react/utils"
15411560
ReactCommon:
15421561
:path: "../node_modules/react-native/ReactCommon"
1562+
ReactNativeIncallManager:
1563+
:path: "../node_modules/react-native-incall-manager"
15431564
RNArgon2:
15441565
:path: "../node_modules/react-native-argon2"
15451566
RNCAsyncStorage:
@@ -1601,7 +1622,9 @@ SPEC CHECKSUMS:
16011622
GoogleUtilities: ea963c370a38a8069cc5f7ba4ca849a60b6d7d15
16021623
hermes-engine: d992945b77c506e5164e6a9a77510c9d57472c59
16031624
indy-vdr: aada31078a9ed270dd618fadb4cf69bcdc333d68
1625+
JitsiWebRTC: b47805ab5668be38e7ee60e2258f49badfe8e1d0
16041626
libevent: 4049cae6c81cdb3654a443be001fb9bdceff7913
1627+
Mute: 20135a96076f140cc82bfc8b810e2d6150d8ec7e
16051628
nanopb: a0ba3315591a9ae0a16a309ee504766e90db0c96
16061629
PromisesObjC: f5707f49cb48b9636751c5b2e7d227e43fba9f47
16071630
RCT-Folly: cd21f1661364f975ae76b3308167ad66b09f53f5
@@ -1637,6 +1660,8 @@ SPEC CHECKSUMS:
16371660
react-native-splash-screen: 95994222cc95c236bd3cdc59fe45ed5f27969594
16381661
react-native-tcp-socket: ae8abcfebc071216302a09d9ed1e375d4e877484
16391662
react-native-video: d74d94fbaeee3c0d8f6570173289f43fe210066f
1663+
react-native-volume-manager: d9d2863a2374420af89c89662333ea6adf506988
1664+
react-native-webrtc: 96fdff9e3a942ed88cafe01898da1c93fd628957
16401665
react-native-webview: f802f655c8446404bb0c134da9335a8cf667e8cb
16411666
React-nativeconfig: 8fd29a35a3e4e8c37682d976667663d834ba6165
16421667
React-NativeModulesApple: 83d7077877f8eda8e1b6055b3f8f16f7db8463b5
@@ -1658,6 +1683,7 @@ SPEC CHECKSUMS:
16581683
React-runtimescheduler: 398069b748d97567cc7585cc9a97284ad19d72fa
16591684
React-utils: e8549669b504c18929b2e9aa4d87657e530a91a4
16601685
ReactCommon: 9c38e8797dc2ac72edf63cd18cf450d918575666
1686+
ReactNativeIncallManager: dccd3e7499caa3bb73d3acfedf4fb0360f1a87d5
16611687
RNArgon2: 708e188b7a4d4ec8baf62463927c47abef453a94
16621688
RNCAsyncStorage: 9350c2956f996b3ff1ac7cfdb50901c113a27640
16631689
RNCClipboard: f6679d470d0da2bce2a37b0af7b9e0bf369ecda5

app/package.json

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,7 @@
6868
"@hyperledger/aries-askar-react-native": "0.2.3",
6969
"@hyperledger/indy-vdr-react-native": "0.2.2",
7070
"@hyperledger/indy-vdr-shared": "0.2.2",
71+
"@pexip/infinity-api": "~19.1.2",
7172
"@react-native-async-storage/async-storage": "~1.22.3",
7273
"@react-native-clipboard/clipboard": "~1.16.3",
7374
"@react-native-community/netinfo": "~11.3.3",
@@ -109,6 +110,7 @@
109110
"react-native-get-random-values": "~1.8.0",
110111
"react-native-gifted-chat": "*",
111112
"react-native-inappbrowser-reborn": "~3.7.0",
113+
"react-native-incall-manager": "~4.2.1",
112114
"react-native-keychain": "~8.1.3",
113115
"react-native-localize": "~2.2.6",
114116
"react-native-logs": "~5.1.0",
@@ -127,6 +129,8 @@
127129
"react-native-vector-icons": "~10.0.3",
128130
"react-native-video": "~6.16.1",
129131
"react-native-vision-camera": "~4.3.2",
132+
"react-native-volume-manager": "~1.10.0",
133+
"react-native-webrtc": "~124.0.6",
130134
"react-native-webview": "~13.10.7",
131135
"reflect-metadata": "~0.1.14",
132136
"rxjs": "~7.8.2",
Lines changed: 17 additions & 0 deletions
Loading

app/src/bcsc-theme/api/client.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@ interface BCSCEndpoints {
4242
token: string
4343
credential: string
4444
evidence: string
45+
video: string
4546
}
4647

4748
class BCSCService {
@@ -95,6 +96,7 @@ class BCSCService {
9596
token: `${this.baseURL}/device/token`,
9697
credential: `${this.baseURL}/credentials/v1/person`,
9798
evidence: `${this.baseURL}/evidence`,
99+
video: `${this.baseURL}/video`,
98100
}
99101

100102
// Add interceptors
@@ -158,8 +160,9 @@ class BCSCService {
158160
savedServices: response.data['saved_services_endpoint'],
159161
token: response.data['token_endpoint'],
160162
credential: response.data['credential_endpoint'],
161-
// TODO(bm): request backend team to add evidence endpoint to the response
163+
// TODO(bm): request backend team to add evidence and video endpoints to the response
162164
evidence: `${this.baseURL}/evidence`,
165+
video: `${this.baseURL}/video`,
163166
}
164167
}
165168

app/src/bcsc-theme/api/hooks/useApi.tsx

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ import useUserApi from './useUserApi'
88
import useEvidenceApi from './useEvidenceApi'
99
import useMetadataApi from './useMetadataApi'
1010
import useJwksApi from './useJwksApi'
11+
import useVideoCallApi from './useVideoCallApi'
1112

1213
const useApi = () => {
1314
const config = useConfigApi()
@@ -19,6 +20,7 @@ const useApi = () => {
1920
const evidence = useEvidenceApi()
2021
const metadata = useMetadataApi()
2122
const jwks = useJwksApi()
23+
const video = useVideoCallApi()
2224

2325
return useMemo(
2426
() => ({
@@ -31,8 +33,9 @@ const useApi = () => {
3133
evidence,
3234
metadata,
3335
jwks,
36+
video,
3437
}),
35-
[config, pairing, registration, authorization, token, user, evidence, metadata, jwks]
38+
[config, pairing, registration, authorization, token, user, evidence, metadata, jwks, video]
3639
)
3740
}
3841

0 commit comments

Comments
 (0)