Skip to content

Commit 309c38f

Browse files
Merge pull request #5621 from simpledotorg/master
2 parents 48a61f1 + 41963ec commit 309c38f

File tree

6 files changed

+36
-6
lines changed

6 files changed

+36
-6
lines changed

CHANGELOG.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,16 @@
88
- Bump AndroidX Test Runner to v1.7.0
99
- Bump AndroidX Test Rules to v1.7.0
1010
- Bump AndroidX JUnit to v1.3.0
11+
- Bump Jackson Core to v2.20.0
12+
- Bump Play Services Auth to v21.4.0
13+
- Bump Material Components to v1.12.0
14+
- Bump Kotlin to v2.2.20
15+
- Bump AndroidX Work to v2.10.4
16+
- Bump AndroidX ViewModel to v2.9.4
17+
18+
### Changes
19+
20+
- Hide next button when registration is going
1121

1222
## 2025.09.09
1323

app/src/main/java/org/simple/clinic/registration/phone/RegistrationPhoneScreen.kt

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -174,6 +174,14 @@ class RegistrationPhoneScreen :
174174
progressView.visibility = View.GONE
175175
}
176176

177+
override fun showNextButton() {
178+
nextButtonFrame.visibility = View.VISIBLE
179+
}
180+
181+
override fun hideNextButton() {
182+
nextButtonFrame.visibility = View.GONE
183+
}
184+
177185
override fun openLoginPinEntryScreen() {
178186
router.push(LoginPinScreenKey())
179187
}

app/src/main/java/org/simple/clinic/registration/phone/RegistrationPhoneUi.kt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,4 +7,6 @@ interface RegistrationPhoneUi {
77
fun hideAnyError()
88
fun showProgressIndicator()
99
fun hideProgressIndicator()
10+
fun showNextButton()
11+
fun hideNextButton()
1012
}

app/src/main/java/org/simple/clinic/registration/phone/RegistrationPhoneUiRenderer.kt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,10 @@ class RegistrationPhoneUiRenderer(
2121
if (mode == RegistrationUiMode.RegistrationOngoing) {
2222
registrationResultValueCallback.clear()
2323
ui.showProgressIndicator()
24+
ui.hideNextButton()
2425
} else {
2526
ui.hideProgressIndicator()
27+
ui.showNextButton()
2628
}
2729
}
2830

app/src/test/java/org/simple/clinic/registration/phone/RegistrationPhoneScreenLogicTest.kt

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -155,6 +155,7 @@ class RegistrationPhoneScreenLogicTest {
155155

156156
// then
157157
verify(ui).showProgressIndicator()
158+
verify(ui).hideNextButton()
158159
verify(findUserWithPhoneNumber).find(inputNumber)
159160
}
160161

@@ -176,6 +177,8 @@ class RegistrationPhoneScreenLogicTest {
176177
// then
177178
verify(ui).showProgressIndicator()
178179
verify(ui).hideProgressIndicator()
180+
verify(ui).hideNextButton()
181+
verify(ui).showNextButton()
179182
verify(ui).showUnexpectedErrorMessage()
180183

181184
clearInvocations(ui)
@@ -186,6 +189,8 @@ class RegistrationPhoneScreenLogicTest {
186189
// then
187190
verify(ui).showProgressIndicator()
188191
verify(ui).hideProgressIndicator()
192+
verify(ui).hideNextButton()
193+
verify(ui).showNextButton()
189194
verify(ui).showNetworkErrorMessage()
190195
}
191196

@@ -291,6 +296,7 @@ class RegistrationPhoneScreenLogicTest {
291296

292297
// then
293298
verify(ui).showProgressIndicator()
299+
verify(ui).hideNextButton()
294300
verify(facilitySync).pullWithResult()
295301
}
296302

@@ -324,6 +330,7 @@ class RegistrationPhoneScreenLogicTest {
324330

325331
// then
326332
verify(ui).hideProgressIndicator()
333+
verify(ui).showNextButton()
327334
verify(ui).showNetworkErrorMessage()
328335
verify(findUserWithPhoneNumber, never()).find(phoneNumber)
329336
}
@@ -342,6 +349,7 @@ class RegistrationPhoneScreenLogicTest {
342349

343350
// then
344351
verify(ui).hideProgressIndicator()
352+
verify(ui).showNextButton()
345353
verify(ui).showUnexpectedErrorMessage()
346354
verify(findUserWithPhoneNumber, never()).find(phoneNumber)
347355
}

gradle/libs.versions.toml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,16 +5,16 @@ androidx-cameraView = "1.4.2"
55
androidx-camera = "1.4.2"
66
androidx-paging = "3.3.6"
77
androidx-room = "2.7.2"
8-
androidx-work = "2.10.3"
8+
androidx-work = "2.10.4"
99
androidx-security-crypto = "1.1.0-alpha07"
10-
androidx-viewmodel = "2.9.3"
10+
androidx-viewmodel = "2.9.4"
1111
androidx-lifecycle = "2.9.4"
1212
androidx-activity = "1.10.1"
1313

1414
chucker = "4.2.0"
1515
dagger = "2.57.1"
1616

17-
kotlin = "2.2.10"
17+
kotlin = "2.2.20"
1818

1919
ksp = "2.2.10-2.0.2"
2020

@@ -116,7 +116,7 @@ itemanimators = "com.mikepenz:itemanimators:1.1.0"
116116

117117
itext7 = "com.itextpdf:itext7-core:7.2.5"
118118

119-
jackson-core = "com.fasterxml.jackson.core:jackson-core:2.19.2"
119+
jackson-core = "com.fasterxml.jackson.core:jackson-core:2.20.0"
120120

121121
jbcrypt = "org.mindrot:jbcrypt:0.4"
122122

@@ -140,7 +140,7 @@ logback-classic = "ch.qos.logback:logback-classic:1.2.11"
140140

141141
lottie = "com.airbnb.android:lottie-compose:6.6.7"
142142

143-
material = "com.google.android.material:material:1.12.0"
143+
material = "com.google.android.material:material:1.13.0"
144144

145145
mockito-kotlin = "org.mockito.kotlin:mockito-kotlin:5.4.0"
146146

@@ -160,7 +160,7 @@ okhttp-interceptor-logging = { module = "com.squareup.okhttp3:logging-intercepto
160160
openCsv = "com.opencsv:opencsv:5.12.0"
161161

162162
play-app-update = "com.google.android.play:app-update-ktx:2.1.0"
163-
play-services-auth = "com.google.android.gms:play-services-auth:21.3.0"
163+
play-services-auth = "com.google.android.gms:play-services-auth:21.4.0"
164164
play-services-location = "com.google.android.gms:play-services-location:21.3.0"
165165
play-services-mlkit-barcode = "com.google.android.gms:play-services-mlkit-barcode-scanning:18.3.1"
166166

0 commit comments

Comments
 (0)