@@ -87,10 +87,8 @@ fun ReceiveQrScreen(
8787 )
8888 }
8989
90- // QR vs Details toggle state
9190 var showDetails by remember { mutableStateOf(false ) }
9291
93- // Dynamic tab visibility
9492 val visibleTabs = remember(walletState, lightningState) {
9593 buildList {
9694 add(ReceiveTab .SAVINGS )
@@ -169,6 +167,7 @@ fun ReceiveQrScreen(
169167 modifier = Modifier .weight(1f )
170168 )
171169 }
170+
172171 showDetails -> {
173172 ReceiveDetailsView (
174173 tab = selectedTab,
@@ -178,6 +177,7 @@ fun ReceiveQrScreen(
178177 modifier = Modifier .weight(1f )
179178 )
180179 }
180+
181181 else -> {
182182 ReceiveQrView (
183183 uri = currentInvoice,
@@ -195,9 +195,21 @@ fun ReceiveQrScreen(
195195 AnimatedVisibility (visible = lightningState.nodeLifecycleState.isRunning()) {
196196 PrimaryButton (
197197 text = stringResource(
198- if (showDetails) R .string.wallet__receive_show_qr
199- else R .string.wallet__receive_show_details
198+ when {
199+ showingCjitOnboarding -> R .string.wallet__receive__cjit
200+ showDetails -> R .string.wallet__receive_show_qr
201+ else -> R .string.wallet__receive_show_details
202+ }
200203 ),
204+ icon = {
205+ if (showingCjitOnboarding) {
206+ Icon (
207+ painter = painterResource(R .drawable.ic_lightning_alt),
208+ tint = Colors .Purple ,
209+ contentDescription = null
210+ )
211+ }
212+ },
201213 onClick = { showDetails = ! showDetails },
202214 fullWidth = true ,
203215 modifier = Modifier .testTag(" ReceiveToggleButton" )
@@ -475,7 +487,7 @@ private fun PreviewSavingsMode() {
475487 onchainAddress = " bcrt1qfserxgtuesul4m9zva56wzk849yf9l8rk4qy0l" ,
476488 channels = emptyList()
477489 ),
478- lightningState = to.bitkit.repositories. LightningState (
490+ lightningState = LightningState (
479491 nodeLifecycleState = NodeLifecycleState .Running ,
480492 shouldBlockLightningReceive = false ,
481493 isGeoBlocked = false
@@ -545,7 +557,7 @@ private fun PreviewAutoMode() {
545557 bip21 = " bitcoin:bcrt1qfserxgtuesul4m9zva56wzk849yf9l8rk4qy0l?lightning=lnbcrt500u1pn7umn7pp5x0s9lt9fwrff6rp70pz3guwnjgw97sjuv79..." ,
546558 channels = listOf (mockChannel)
547559 ),
548- lightningState = to.bitkit.repositories. LightningState (
560+ lightningState = LightningState (
549561 nodeLifecycleState = NodeLifecycleState .Running ,
550562 shouldBlockLightningReceive = false ,
551563 isGeoBlocked = false
@@ -570,7 +582,7 @@ private fun PreviewSpendingMode() {
570582 nodeLifecycleState = NodeLifecycleState .Running ,
571583 bolt11 = " lnbcrt500u1pn7umn7pp5x0s9lt9fwrff6rp70pz3guwnjgw97sjuv79vhx9n2ps8q6tcdehhxapqd9h8vmmfvdjjqen0wgsyqvpsxqcrqvpsxqcrqvpsxqcrqvpsxqcrqvpsxqcrqvpsxqcrqvpsxqcrqvpsxq"
572584 ),
573- lightningState = to.bitkit.repositories. LightningState (
585+ lightningState = LightningState (
574586 nodeLifecycleState = NodeLifecycleState .Running ,
575587 shouldBlockLightningReceive = false ,
576588 isGeoBlocked = false
@@ -593,7 +605,7 @@ private fun PreviewNodeNotReady() {
593605 walletState = MainUiState (
594606 nodeLifecycleState = NodeLifecycleState .Starting ,
595607 ),
596- lightningState = to.bitkit.repositories. LightningState (
608+ lightningState = LightningState (
597609 nodeLifecycleState = NodeLifecycleState .Starting ,
598610 shouldBlockLightningReceive = false ,
599611 isGeoBlocked = false
@@ -615,7 +627,7 @@ private fun PreviewSmall() {
615627 walletState = MainUiState (
616628 nodeLifecycleState = NodeLifecycleState .Running ,
617629 ),
618- lightningState = to.bitkit.repositories. LightningState (
630+ lightningState = LightningState (
619631 nodeLifecycleState = NodeLifecycleState .Running ,
620632 shouldBlockLightningReceive = false ,
621633 isGeoBlocked = false
0 commit comments