Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -231,7 +231,6 @@ internal fun buildNavGraphForLaunch(
target = AppRoute.OnboardingFlow(
phase = AppRoute.OnboardingFlow.Phase.Permissions,
skipContacts = true,
newAccount = true,
),
allowBack = false,
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -188,8 +188,6 @@ class BuildNavGraphForLaunchTest {
)
val target = assertIs<AppRoute.OnboardingFlow>(route.target)
assertEquals(AppRoute.OnboardingFlow.Phase.Permissions, target.phase)
// Display-name entry follows the access key, so this is an account still being created.
assertTrue(target.newAccount)
}

// -- Authenticating --
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -313,7 +313,7 @@ val NavBarButton.label: Int
/**
* The glyph for [this] tab at the weight its selection calls for (node 10000:111297). Every tab is
* drawn as an outline until it is selected, where it fills in, white in both states. The unsuffixed
* drawable is the outline, so `ic_nav_tipcard` is also the outline the tutorial card reuses.
* drawable is the outline.
*
* The scanner tab carries the tip card glyph because scanning one is what that tab is for. The You
* tab draws the user's own photo when there is one (see the avatar branch above) and falls back to
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
package com.flipcash.app.core.ui.onboarding

import androidx.compose.foundation.background
import androidx.compose.foundation.clickable
import androidx.compose.foundation.layout.Arrangement
import androidx.compose.foundation.layout.Column
import androidx.compose.foundation.layout.Row
import androidx.compose.foundation.layout.padding
import androidx.compose.foundation.layout.size
import androidx.compose.material.icons.Icons
import androidx.compose.material.icons.outlined.AddCircleOutline
import androidx.compose.material3.Icon
import androidx.compose.material3.Text
import androidx.compose.runtime.Composable
import androidx.compose.ui.Alignment
import androidx.compose.ui.Modifier
import androidx.compose.ui.draw.clip
import androidx.compose.ui.graphics.Color
import androidx.compose.ui.res.stringResource
import androidx.compose.ui.unit.dp
import com.flipcash.core.R
import com.getcode.theme.CodeTheme
import com.getcode.theme.extraSmall

/** The wallet tab's call to add money, shown until the account has been funded. */
@Composable
fun AddMoneyRow(
modifier: Modifier = Modifier,
onClick: () -> Unit,
) {
Row(
modifier = modifier
.clip(CodeTheme.shapes.extraSmall)
.background(color = Color.White.copy(0.05f))
.clickable(onClick = onClick)
.padding(CodeTheme.dimens.grid.x3),
horizontalArrangement = Arrangement.spacedBy(CodeTheme.dimens.grid.x2),
) {
Icon(
modifier = Modifier.align(Alignment.Top).size(24.dp),
imageVector = Icons.Outlined.AddCircleOutline,
tint = CodeTheme.colors.textMain,
contentDescription = null,
)
Column(modifier = Modifier.weight(1f)) {
Text(
text = stringResource(R.string.title_addMoney),
style = CodeTheme.typography.textMedium,
color = CodeTheme.colors.textMain,
)
Text(
text = stringResource(R.string.subtitle_addMoney),
style = CodeTheme.typography.textSmall,
color = CodeTheme.colors.textSecondary,
)
}
}
}

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -85,9 +85,6 @@ sealed interface AppRoute : NavKey, Parcelable {
val fromDeeplink: Boolean = false,
val resumeAt: ResumePoint = ResumePoint.Login,
val skipContacts: Boolean = true,
// Set when onboarding is creating the account rather than signing in to one; decides
// where the permissions phase releases to.
val newAccount: Boolean = false,
) : AppRoute, FlowRoute {
enum class Phase { Account, Permissions }
enum class ResumePoint { Login, AccessKey, AccessKeyThenPurchase, PostAccessKey }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,7 @@ package com.flipcash.app.core.navigation
import com.flipcash.app.core.AppRoute

/**
* The top-level route the app releases to when onboarding finishes creating a new account, and
* under a launch deeplink (whose token and cash-link actions open on the wallet).
* The base route every resolved launch deeplink opens on.
*
* The wallet is a flat tab home (not a sheet), so this route is applied with `replaceAll` /
* [com.getcode.navigation.core.NavOptions.PopUpTo.ClearAll], exactly like a tab switch from the
Expand Down
6 changes: 3 additions & 3 deletions apps/flipcash/core/src/main/res/drawable/ic_people_circle.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<!-- IconPeopleCircle — "Finish Your Profile" checklist (node 9544:18148). White stroke, tinted
at the call site. The export carries a 50% group opacity; it is dropped here so the row's
own ColorFilter.tint controls the colour, matching the other tutorial icons. -->
<!-- IconPeopleCircle — community chats (node 9544:18148). White stroke, tinted at the call site.
The export carries a 50% group opacity; it is dropped here so the call site's
ColorFilter.tint controls the colour. -->
<vector xmlns:android="http://schemas.android.com/apk/res/android"
android:width="24dp"
android:height="24dp"
Expand Down
18 changes: 9 additions & 9 deletions apps/flipcash/core/src/main/res/values/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -565,10 +565,6 @@
<string name="title_addMoney">Add Money</string>
<string name="subtitle_addMoney">Add money to your account</string>

<string name="title_scanTipCard">Scan a Profile Card</string>
<string name="subtitle_scanTipCard">Send your first message</string>


<!-- Copy matches iOS's "Finish Your Profile" display-name step. -->


Expand Down Expand Up @@ -1536,6 +1532,8 @@
<string name="error_description_usernameTooShort">Usernames must be a minimum of %1$d characters</string>
<string name="error_title_usernameMinimumBalance">%1$s Minimum Balance Required</string>
<string name="error_description_usernameMinimumBalance">In order to stop username squatting getting a username requires a total Flipcash balance of at least %1$s</string>
<string name="error_title_usernameBalanceRequired">%1$s Balance Required</string>
<string name="error_description_usernameBalanceRequired">Setting a custom username requires a balance of %1$s or more</string>
<string name="error_title_usernameCheckFailed">Something Went Wrong</string>
<string name="error_description_usernameCheckFailed">Please try again</string>

Expand Down Expand Up @@ -1576,6 +1574,7 @@
<string name="title_setProfilePicture">Set Profile Picture</string>
<string name="title_cover">Cover</string>
<string name="action_changeCover">Change cover</string>
<string name="action_addCoverPhoto">Add cover photo</string>
<string name="error_title_coverNotAllowed">Couldn\'t Upload Your Cover</string>
<string name="error_description_coverNotAllowed">This image isn\'t allowed as a cover. Please try a different image. If you think it was rejected in error please DM @flipcash on X</string>
<string name="placeholder_profileDisplayName">Your Name</string>
Expand Down Expand Up @@ -1656,15 +1655,15 @@
<string name="error_title_failedToReport">Something Went Wrong</string>
<string name="error_description_failedToReport">We were unable to send your report. Please try again</string>

<string name="title_tipOnboarding">Send Your First Tip</string>

<!-- You tab (tip card) -->
<string name="action_editProfile">Edit Profile</string>
<string name="action_claimYourUsernameLink">Claim your username ›</string>
<string name="action_completeYourProfile">Complete Your Profile</string>
<string name="action_changePhoto">Change photo</string>
<string name="action_addProfilePhoto">Add profile photo</string>
<string name="label_editProfileName">Name</string>
<string name="placeholder_editProfileName">Add a name</string>
<string name="action_claimUsername">Claim your username</string>
<string name="placeholder_editProfileUsername">Add a username</string>
<string name="placeholder_minimumToChat">Not set</string>
<string name="title_shareProfileToChats">Share Profile</string>
<string name="title_shareMessageToChats">Share Message</string>
Expand Down Expand Up @@ -1695,8 +1694,9 @@
<string name="title_bio">Bio</string>
<string name="placeholder_bio">Add a bio</string>

<string name="title_featuredGroups">Favorite Public Groups</string>
<string name="placeholder_featuredGroups">Add groups</string>
<string name="title_featuredGroups">Favorite Community Chats</string>
<string name="text_featuredGroupsNone">None yet</string>
<string name="placeholder_featuredGroups">Add chats</string>
<plurals name="value_featuredGroupCount">
<item quantity="one">1 group</item>
<item quantity="other">%1$s groups</item>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ import kotlin.test.Test
import kotlin.test.assertEquals

/**
* Home is where both launch and the end of onboarding release the user to — the Wallet tab, not the
* camera — so a freshly onboarded user lands on their balance.
* [homeRoute] is where launch deeplinks open. Cold launch and the end of onboarding both use
* [launchRoute] (Chats).
*/
class HomeRouteTest {

Expand All @@ -17,7 +17,7 @@ class HomeRouteTest {

@Test
fun `home is a nav bar tab home`() {
// Guards the release path: it's applied with ClearAll, so it must map to a tab or the
// Deeplinks apply it with ClearAll, so it must map to a tab or the
// hoisted nav bar would render with no selection.
assertEquals(NavBarButton.Wallet, homeRoute.asNavBarTab())
}
Expand Down
1 change: 0 additions & 1 deletion apps/flipcash/features/balance/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ dependencies {
implementation(project(":apps:flipcash:shared:transaction-history"))
implementation(project(":apps:flipcash:shared:analytics"))
testImplementation(testFixtures(project(":apps:flipcash:shared:analytics")))
implementation(project(":apps:flipcash:shared:chat"))
implementation(project(":apps:flipcash:shared:featureflags"))
implementation(project(":apps:flipcash:shared:funding"))
implementation(project(":apps:flipcash:shared:tokens"))
Expand Down
Loading
Loading