Skip to content

Commit 42e376b

Browse files
authored
Merge pull request #3242 from GCWing/wgq/mobile-account-signin
refactor(mobile): replace QR pairing with account sign-in
2 parents 1c77f15 + a58f654 commit 42e376b

98 files changed

Lines changed: 2642 additions & 6921 deletions

File tree

Some content is hidden

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

‎scripts/check-harmonyos-architecture.mjs‎

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -127,12 +127,10 @@ const requiredPresentationFiles = [
127127
'components/AppRootOverlaySurfaces.ets',
128128
'components/ChatMessageChrome.ets',
129129
'components/RemoteSessionRow.ets',
130-
'components/ConnectManualPairingOverlay.ets',
131130
'components/ConversationHeader.ets',
132131
'components/ConversationRouteSurface.ets',
133132
'components/ToolInteractionPanels.ets',
134133
'components/WideConversationHost.ets',
135-
'components/platform/InlineQrScanner.ets',
136134
'components/remote/RemoteSurfaceHost.ets',
137135
'policy/ConversationHeaderPolicy.ets',
138136
'policy/ChatMessageStructurePolicy.ets',

‎src/apps/mobile/android/app/build.gradle.kts‎

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -77,11 +77,6 @@ dependencies {
7777
implementation(libs.androidx.activity.compose)
7878
implementation(libs.androidx.lifecycle.viewmodel.compose)
7979
implementation(libs.androidx.lifecycle.runtime.compose)
80-
implementation("androidx.camera:camera-camera2:1.4.2")
81-
implementation("androidx.camera:camera-lifecycle:1.4.2")
82-
implementation("androidx.camera:camera-view:1.4.2")
83-
// Bundle QR recognition so pairing also works without Play Services downloads.
84-
implementation("com.google.mlkit:barcode-scanning:17.3.0")
8580
implementation(libs.androidx.window)
8681

8782
testImplementation("junit:junit:4.13.2")
-773 Bytes
Binary file not shown.

‎src/apps/mobile/android/app/src/androidTest/kotlin/com/openbitfun/mobile/app/AccountRemoteScreenTest.kt‎

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@ import androidx.compose.ui.test.onNodeWithText
1515
import androidx.compose.ui.test.performClick
1616
import com.openbitfun.mobile.app.ui.remote.CONNECT_ACCOUNT_DEVICE_REFRESH_TEST_TAG
1717
import com.openbitfun.mobile.app.ui.remote.CONNECT_ACCOUNT_DEVICE_ROW_TEST_TAG_PREFIX
18-
import com.openbitfun.mobile.app.ui.remote.CONNECT_ACCOUNT_DEVICE_SCAN_TEST_TAG
1918
import com.openbitfun.mobile.app.ui.remote.ConnectAccountDeviceScreen
2019
import com.openbitfun.mobile.app.ui.remote.AccountRemoteScreen
2120
import com.openbitfun.mobile.app.ui.theme.OpenBitFunTheme
@@ -109,10 +108,9 @@ class AccountRemoteScreenTest {
109108
}
110109

111110
@Test
112-
fun aSignedInAccountWithoutATargetCanRefreshSelectOrScan() {
111+
fun aSignedInAccountWithoutATargetCanRefreshOrSelect() {
113112
var refreshes = 0
114113
var selected = ""
115-
var scans = 0
116114
composeRule.setContent {
117115
OpenBitFunTheme(dark = false) {
118116
ConnectAccountDeviceScreen(
@@ -129,7 +127,6 @@ class AccountRemoteScreenTest {
129127
onBack = {},
130128
onRefresh = { refreshes += 1 },
131129
onSelect = { selected = it },
132-
onOpenScanner = { scans += 1 },
133130
modifier = Modifier,
134131
)
135132
}
@@ -139,11 +136,9 @@ class AccountRemoteScreenTest {
139136
composeRule.onNodeWithTag(CONNECT_ACCOUNT_DEVICE_REFRESH_TEST_TAG).performClick()
140137
composeRule.onNodeWithTag(CONNECT_ACCOUNT_DEVICE_ROW_TEST_TAG_PREFIX + "desk-1").performClick()
141138
composeRule.onNodeWithTag(CONNECT_ACCOUNT_DEVICE_ROW_TEST_TAG_PREFIX + "desk-2").performClick()
142-
composeRule.onNodeWithTag(CONNECT_ACCOUNT_DEVICE_SCAN_TEST_TAG).performClick()
143139

144140
assertEquals(1, refreshes)
145141
assertEquals("desk-1", selected)
146-
assertEquals(1, scans)
147142
}
148143

149144
@Test
@@ -165,7 +160,6 @@ class AccountRemoteScreenTest {
165160
onBack = {},
166161
onRefresh = {},
167162
onSelect = { selected = it },
168-
onOpenScanner = {},
169163
modifier = Modifier,
170164
)
171165
}

‎src/apps/mobile/android/app/src/androidTest/kotlin/com/openbitfun/mobile/app/InlineQrDecoderTest.kt‎

Lines changed: 0 additions & 34 deletions
This file was deleted.

0 commit comments

Comments
 (0)