From 967a685c3d036d1a049c3dffe888b8f61b4bd106 Mon Sep 17 00:00:00 2001 From: HashEngineering Date: Tue, 13 Aug 2024 09:41:38 -0700 Subject: [PATCH 01/21] chore: use dashj 21.0.0-CJ-SNAPSHOT --- build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle b/build.gradle index 7f6905ea5..9e6fdc936 100644 --- a/build.gradle +++ b/build.gradle @@ -3,7 +3,7 @@ buildscript { kotlin_version = '1.9.23' coroutinesVersion = '1.6.4' ok_http_version = '4.9.1' - dashjVersion = '20.0.5-CJ-SNAPSHOT' + dashjVersion = '21.0.0-CJ-SNAPSHOT' hiltVersion = '2.51' hiltCompilerVersion = '1.2.0' hiltWorkVersion = '1.0.0' From 3de6da4a43fb5fcbc7928df4096a26b7ce62c838 Mon Sep 17 00:00:00 2001 From: HashEngineering Date: Thu, 15 Aug 2024 11:55:12 -0700 Subject: [PATCH 02/21] chore: move dashpay strings to strings-dashpay.xml --- .tx/config | 7 + wallet/res/values/strings-dashpay.xml | 387 ++++++++++++++++++++++++++ wallet/res/values/strings-extra.xml | 246 +--------------- wallet/res/values/strings.xml | 21 +- 4 files changed, 411 insertions(+), 250 deletions(-) create mode 100644 wallet/res/values/strings-dashpay.xml diff --git a/.tx/config b/.tx/config index c5327270e..0c2bce2d4 100644 --- a/.tx/config +++ b/.tx/config @@ -50,6 +50,13 @@ source_lang = en type = ANDROID lang_map = sl_SI: sl, zh_TW: zh-rTW +[o:dash:p:dash-mobile-wallets:r:strings-dashpay] +file_filter = wallet/res/values-/strings-dashpay.xml +source_file = wallet/res/values/strings-dashpay.xml +source_lang = en +type = ANDROID +lang_map = sl_SI: sl, zh_TW: zh-rTW + [o:dash:p:dash-mobile-wallets:r:strings-uphold] file_filter = integrations/uphold/src/main/res/values-/strings-uphold.xml source_file = integrations/uphold/src/main/res/values/strings-uphold.xml diff --git a/wallet/res/values/strings-dashpay.xml b/wallet/res/values/strings-dashpay.xml new file mode 100644 index 000000000..f67d31089 --- /dev/null +++ b/wallet/res/values/strings-dashpay.xml @@ -0,0 +1,387 @@ + + + + Choose your Dash\nUsername + Between 3 and 23 characters + Letters, numbers and hyphens only + Must start and end with a letter or number + Validating username… + Username available + Username taken + Communication error with Dash Platform + Register + + Confirm & Pay + Confirm + I Accept + Upgrade Fee + You have chose %s as your username. Username cannot be changed once it is registered. + Invitation Fee + Each invitation will be funded with this amount so that the receiver can quickly create their username on the Dash Network + Invite + Invite your friends & family + Help your friends and family join the Dash Network. Invite them to the world of social banking. + Create a new Invitation + Invite your friends and family to the Dash Network + Invite Someone to join the Dash Network + or + Invitation + Invitation Created Successfully + Tag for your reference + eg: Dad + Preview Invitation + Copy Invitation Link + Send Invitation + Send again + Maybe later + Join Now + You have been invited by %s. Start using Dash cryptocurrency. + Close + Insufficient Wallet Balance + You need at least %s Dash to create an invitation + Error Creating Invitation + There was a problem creating your invitation. Please try again. + Wait for syncing to complete and try again. + Creating invitation + Verifying invitation + Invitations are single use only. Do not share with a group. + DashPay invitation + Invitation already claimed + Your invitation from %s has been already claimed + Invalid Invitation + Your invitation from %s is not valid + Username already found + You cannot claim this invite since you already have a Dash username + Onboarding Error + Onboarding is in process, please claim your invite after you have created your wallet. + Get your Username + Add your Friends & Family + Invite your family, find your friends by searching their usernames + Personalize + Upload your picture, personalize your identity + Continue + A contact request has been sent to %s since they invited you. + + Your username %s is being created on the Dash Network + Let me know when it\'s done + Upgrading to Evolution + (1/3) Processing Payment + (2/3) Creating ID + (2/3) Recovering ID + (3/3) Registering Username + (3/3) Recovering Username + Hello %s, + Your account is ready + Error Upgrading + Error Upgrading from invite + Retry + Username Unavailable + Please choose another + + Upgrade Fee + Invite Fee + Topup Fee + Find a user on the Dash Network + Search for a User on the Dash Network + enter the username to search here + Add a New Contact + Send Contact Request + Sending Contact Request + Inviting + Accepting Contact Request + Accepting + There are no users that match + Searching for username "%" on the Dash Network + Contact Request Pending + Pay + %s has requested to be a friend + Accept + Ignore + + There are no contacts that match + + Contacts + Send to a Contact + Search for a contact + Contact Requests + Add new contact + Contact Requests (%d) + Contact Requests + view all + My Contacts + Sort by: + + Name + + + Notifications + Notifications (%d) + Activity + New + Earlier + There are no new notifications + %s has accepted your contact request. + You have accepted the contact request from %s + You sent a contact request to %s + %s has sent you a contact request + + Your username %s has been successfully created on the Dash Network + + Not a valid Dash Username or Identity\n\n%s + Sending to + Add % as your contact to <b>Pay Directly to Username</b> and <b>Retain Mutual Transaction History</b> + Once % accepts your request you can <b>Pay Directly to Username</b> + Payments made directly to addresses won’t be retained in activity. + Error loading identity + + Edit Profile + Display Name + About me + %1$d/%2$d characters + @string/char_count + Save + Take a Photo with Camera + Select from Gallery + Join DashPay + Create your Username, find friends & family with their usernames and add them to your contacts + Move and Zoom your photo to find the perfect fit + Select + Unable to load image. + Upload Error + Unable to upload your picture.\nPlease try again. + Try again + Please Wait + Uploading your picture to the network + Picture Upload Policy + The image you select will be uploaded to Imgur anonymously. + Image uploaded can be viewed publicly by anyone. + You can always delete the image uploaded, as long as you have access to this wallet. + Are you sure? + This image will no longer be used on the Dash network + Agree + Yes + No + + Updating Profile on Dash Network + No account information is stored on the Dash Network or by the DashPay wallet. + Image uploaded can be viewed publicly by anyone. + You can always delete or change the image as long as you have access to the wallet on this device. + + Uploading your picture to the network + Please Wait + Unable to upload your picture. Please try again. + Upload Error + + Google Drive + Imgur + Google Drive authorization failed. + + + Try Again + Cancel + Error updating profile + Code: %s + Public URL + Paste your image URL + Unable to fetch image. Please enter a valid image URL. + You can specify any URL which is publicly available on the internet so users can see it on the Dash network. + More info + Fetching Image + + Gravatar + Enter your Gravatar Email ID + Fetching your Gravatar + sample@email.com + Your Email is not stored in the DashPay wallet nor on any servers. It is used once to get your Gravatar account details and then discarded. + Unable to fetch your Gravatar. Please enter a valid Gravatar email ID. + + Where would you like to store your picture? + Your image will always be in your control. Dash does not store any of your data including your profile picture. + Sign in required + Google Drive + No account required + + Create Username, add your friends… + Create your Username, find your friends and add them to your contacts + Join + + More Suggestions + Users that matches + who are currently not in your contacts + No matching users in your contacts + There are no users that matches with the name + in your contacts + Save Changes + Would you like to save the changes you made to your profile? + Invite your friends and family to join the Dash Network. + You need at least %s to get started + Insufficient credits to perform this action. + + Developer mode activated: all features enabled! + Developer mode deactivated. + Create a new invitation + Invitations History + Filter Invitations + No invites have been created. + There are no claimed invites. + There are no pending invites. + Invitation used by + Invitation claimed. Username registration pending. + + All + Pending + Claimed + + + + Private Note + Add Note + Edit Note + Note + + Select your username privacy preferences + Please note that you will not be able to change this later + Intermediate privacy level requires a reliable internet connection + Advanced privacy level requires a reliable internet connection + It is recommended to be on a Wi-Fi network to avoid losing any funds + Continue Anyway + Welcome to Dash Pay + Pay to usernames. No more alphanumeric addresses. + Create a username + "Add your friends & family" + Invite your family, find your friends by searching their usernames. + Personalise profile + Upload your picture, personalize your identity. + In case you lose your passphrase you will lose your right to your requested username. + Keep your passphrase safe + Pay now and if not approved, you can create a different name without paying again [check if true] + In case your request is not approved + Any username that has a number 2–9 or is longer than 20 characters will be automatically approved + Voting is only required in some cases + The Dash network must vote to approve your username before it is created. + What is username voting? + Some usernames can be blocked + If enough of the network determines that a username is inappropriate, they can block it + Username Voting + As a masternode owner you can vote to approve requested usernames before users will be able to create it. + Vote only on duplicates + You can review all requests but you only need to vote on duplicates + All + %d usernames + %d requests + Search by username + Type + Only duplicates + Only requests with links + With links + Date: %s + Votes: %s + + + New to old + Old to new + High to low + Low to high + + + + All + I have approved + I have not approved + + + Create your username + Please not that you will not be able to change it in the future + Request Username + The Dash network will vote on this username. We will notify you of the results on %s. + Username is available + Username is unavailable or blocked + Username is taken + + Voting: + This username has already been requested, but you can request it too and let the network vote to decide if you can have it + Request details + Review the posting bellow to verify the ownership of this username + Vote to Approve + Identity + Link + Not provided + Cancel Approval + Verify your identity to enhance your chances of getting your requested username + If somebody else requests the same username as you, we will let the network decide whom to give this username + The link you send will be visible only to the network owners + Verify your identity + Copy the text + Please vote to approve my requested Dash username - %s + Prove your identity + Make a post with the text above on a well known social media or messaging platform to verify that you are the original owner of the requested username and paste the link bellow + Paste the link + Enter your voting key + Masternode Voting Key + You have entered an invalid key + Add your voting keys + The IP address(es) below are associated with this wallet + Masternode IP address + %d votes will be cast as you have multiple voting keys stored in the wallet + Add Masternode Voting Key + Your vote was submitted + Your vote was cancelled + Quick Voting + By tapping the "Vote for All" button, you will automatically vote for all of the filtered usernames (%d) that were submitted first + Vote for All + Username Voting Period Active + There was a network error, you can try again at no extra cost + Requested · Voting: 1 Mar – 15 Mar + Cancel Request + After the voting ends we will notify you about its results + None + Verify Now + If you tap “Cancel Request”, you will still have a chance to request another username without paying again + Do you really want to cancel the username request? + If you tap “Cancel Request”, you will still have a chance to request another username without paying again + Can’t open + The link is invalid + You have %s Dash. Some usernames cost up to %s Dash. + To request a username on the Dash Network, you need to have more than %s Dash + + + CoinJoin + Turned off + Mixing your Dash coins will make your transactions more private + You will only be able to spend Dash that has been mixed when this is turned on. This can be turned off at any time. + Newly received Dash will be automatically mixed when the wallet is opened + Turning this feature on will result a higher battery usage + Select mixing level + You can change or stop the mixing level at any time + Mixing Transactions + These are mixing related transactions. + Intermediate + Advanced + Advanced users who have a very high level of technical expertise can determine your transaction history + It would be very difficult for advanced users with any level of technical expertise to determine your transaction history + up to 30 minutes + Multiple hours + Start Mixing + Stop Mixing + Mixing + Mixing Paused + Not Started + %s (%d%%) %s of %s + %1$s of %2$s + Fully Mixed + Are you sure you want to change the privacy level? + Are you sure you want to stop mixing? + Any funds that have been mixed will be combined with your unmixed funds + Mixed balance: + + + Your credit balance is low + Your credit balance is fully depleted + "You can continue to use DashPay for payments but you cannot update your profile or add more contacts until you top up your credit balance + Top-up your credits to continue making changes to your profile and adding contacts + Maybe later + Buy Credits + You don’t have enough funds to buy credits + %s - %d contacts / %d profile updates + + diff --git a/wallet/res/values/strings-extra.xml b/wallet/res/values/strings-extra.xml index e1f86b898..eddf81c9c 100644 --- a/wallet/res/values/strings-extra.xml +++ b/wallet/res/values/strings-extra.xml @@ -380,67 +380,6 @@ Invalid Private Key Okay - Choose your Dash\nUsername - Between 3 and 23 characters - Letters, numbers and hyphens only - Must start and end with a letter or number - Validating username… - Username available - Username taken - Communication error with Dash Platform - Register - - Confirm & Pay - Confirm - I Accept - Upgrade Fee - You have chose %s as your username. Username cannot be changed once it is registered. - Invitation Fee - Each invitation will be funded with this amount so that the receiver can quickly create their username on the Dash Network - Invite - Invite your friends & family - Help your friends and family join the Dash Network. Invite them to the world of social banking. - Create a new Invitation - Invite your friends and family to the Dash Network - Invite Someone to join the Dash Network - or - Invitation - Invitation Created Successfully - Tag for your reference - eg: Dad - Preview Invitation - Copy Invitation Link - Send Invitation - Send again - Maybe later - Join Now - You have been invited by %s. Start using Dash cryptocurrency. - Close - Insufficient Wallet Balance - You need at least %s Dash to create an invitation - Error Creating Invitation - There was a problem creating your invitation. Please try again. - Wait for syncing to complete and try again. - Creating invitation - Verifying invitation - Invitations are single use only. Do not share with a group. - DashPay invitation - Invitation already claimed - Your invitation from %s has been already claimed - Invalid Invitation - Your invitation from %s is not valid - Username already found - You cannot claim this invite since you already have a Dash username - Onboarding Error - Onboarding is in process, please claim your invite after you have created your wallet. - Get your Username - Add your Friends & Family - Invite your family, find your friends by searching their usernames - Personalize - Upload your picture, personalize your identity - Continue - A contact request has been sent to %s since they invited you. - Let\'s Get Started Welcome to DashPay Step 1 @@ -453,160 +392,7 @@ Please Wait Your wallet is being restored - Your username %s is being created on the Dash Network - Let me know when it\'s done - Upgrading to Evolution - (1/3) Processing Payment - (2/3) Creating ID - (2/3) Recovering ID - (3/3) Registering Username - (3/3) Recovering Username - Hello %s, - Your account is ready - Error Upgrading - Error Upgrading from invite - Retry - Username Unavailable - Please choose another - - Upgrade Fee - Invite Fee - Topup Fee - Find a user on the Dash Network - Search for a User on the Dash Network - enter the username to search here - Add a New Contact - Send Contact Request - Sending Contact Request - Inviting - Accepting Contact Request - Accepting - There are no users that match - Searching for username "%" on the Dash Network - Contact Request Pending - Pay - %s has requested to be a friend - Accept - Ignore - - There are no contacts that match - - Contacts - Send to a Contact - Search for a contact - Contact Requests - Add new contact - Contact Requests (%d) - Contact Requests - view all - My Contacts - Sort by: - - Name - - Notifications - Notifications (%d) - Activity - New - Earlier - There are no new notifications - %s has accepted your contact request. - You have accepted the contact request from %s - You sent a contact request to %s - %s has sent you a contact request - - Your username %s has been successfully created on the Dash Network - - Not a valid Dash Username or Identity\n\n%s - Sending to - Add % as your contact to <b>Pay Directly to Username</b> and <b>Retain Mutual Transaction History</b> - Once % accepts your request you can <b>Pay Directly to Username</b> - Payments made directly to addresses won’t be retained in activity. - Error loading identity - - Edit Profile - Display Name - About me - %1$d/%2$d characters - @string/char_count - Save - Take a Photo with Camera - Select from Gallery - Join DashPay - Create your Username, find friends & family with their usernames and add them to your contacts - Move and Zoom your photo to find the perfect fit - Select - Unable to load image. - Upload Error - Unable to upload your picture.\nPlease try again. - Try again - Please Wait - Uploading your picture to the network - Picture Upload Policy - The image you select will be uploaded to Imgur anonymously. - Image uploaded can be viewed publicly by anyone. - You can always delete the image uploaded, as long as you have access to this wallet. - Are you sure? - This image will no longer be used on the Dash network - Agree - Yes - No - - Updating Profile on Dash Network - No account information is stored on the Dash Network or by the DashPay wallet. - Image uploaded can be viewed publicly by anyone. - You can always delete or change the image as long as you have access to the wallet on this device. - - Uploading your picture to the network - Please Wait - Unable to upload your picture. Please try again. - Upload Error - - Google Drive - Imgur - Google Drive authorization failed. - - - Try Again - Cancel - Error updating profile - Code: %s - Public URL - Paste your image URL - Unable to fetch image. Please enter a valid image URL. - You can specify any URL which is publicly available on the internet so users can see it on the Dash network. - More info - Fetching Image - - Gravatar - Enter your Gravatar Email ID - Fetching your Gravatar - sample@email.com - Your Email is not stored in the DashPay wallet nor on any servers. It is used once to get your Gravatar account details and then discarded. - Unable to fetch your Gravatar. Please enter a valid Gravatar email ID. - - Where would you like to store your picture? - Your image will always be in your control. Dash does not store any of your data including your profile picture. - Sign in required - Google Drive - No account required - - Create Username, add your friends… - Create your Username, find your friends and add them to your contacts - Join - - More Suggestions - Users that matches - who are currently not in your contacts - No matching users in your contacts - There are no users that matches with the name - in your contacts - Save Changes - Would you like to save the changes you made to your profile? - Invite your friends and family to join the Dash Network. - You need at least %s to get started - Insufficient credits to perform this action. Network Unavailable Unable to fetch contact details @@ -614,21 +400,7 @@ Unable to provide suggestions Unable to update your profile - Developer mode activated: all features enabled! - Developer mode deactivated. - Create a new invitation - Invitations History - Filter Invitations - No invites have been created. - There are no claimed invites. - There are no pending invites. - Invitation used by - Invitation claimed. Username registration pending. - - All - Pending - Claimed - + Today Yesterday @@ -660,11 +432,7 @@ You may lose %s Reset Wallet - - Private Note - Add Note - Edit Note - Note + Reclassify Your Transactions @@ -704,14 +472,4 @@ Prices weren\'t retrieved. Fiat values may be incorrect. Prices are at least 30 minutes old. Fiat values may be incorrect. Prices have fluctuated more than 50% since the last update. - - - Your credit balance is low - Your credit balance is fully depleted - "You can continue to use DashPay for payments but you cannot update your profile or add more contacts until you top up your credit balance - Top-up your credits to continue making changes to your profile and adding contacts - Maybe later - Buy Credits - You don’t have enough funds to buy credits - %s - %d contacts / %d profile updates \ No newline at end of file diff --git a/wallet/res/values/strings.xml b/wallet/res/values/strings.xml index 1a1c6df7c..f684820a5 100644 --- a/wallet/res/values/strings.xml +++ b/wallet/res/values/strings.xml @@ -413,6 +413,8 @@ Do you want to receive payments in the background? This app is configured to continue running after not being visible for some time.\n\nWe suggest allowing this app to always stay up-to-date with the blockchain, even in the background.\n\nDon\'t worry, we will always mind your battery usage. Open Settings + + Select your username privacy preferences Please note that you will not be able to change this later Intermediate privacy level requires a reliable internet connection @@ -428,12 +430,14 @@ Upload your picture, personalize your identity. In case you lose your passphrase you will lose your right to your requested username. Keep your passphrase safe - Pay now and if not approved, you can create a different name without paying again + Pay now and if not approved, you can create a different name without paying again [check if true] In case your request is not approved - After voting is completed on X you can create any username that has not already been created - Voting will not be required forever + Any username that has a number 2–9 or is longer than 20 characters will be automatically approved + Voting is only required in some cases The Dash network must vote to approve your username before it is created. What is username voting? + Some usernames can be blocked + If enough of the network determines that a username is inappropriate, they can block it Username Voting As a masternode owner you can vote to approve requested usernames before users will be able to create it. Vote only on duplicates @@ -462,9 +466,14 @@ I have not approved - Request your username - Once the voting ends you can create any username you want as long as it hasn’t already been created + Create your username + Please not that you will not be able to change it in the future Request Username + The Dash network will vote on this username. We will notify you of the results on %s. + Username is available + Username is unavailable or blocked + Username is taken + Voting: This username has already been requested, but you can request it too and let the network vote to decide if you can have it Request details @@ -508,7 +517,7 @@ If you tap “Cancel Request”, you will still have a chance to request another username without paying again Can’t open The link is invalid - You should have more than %s Dash to create a username + You have %s Dash. Some usernames cost up to %s Dash. To request a username on the Dash Network, you need to have more than %s Dash From c751326e026dfb7952130e823127993e654f5336 Mon Sep 17 00:00:00 2001 From: HashEngineering Date: Thu, 15 Aug 2024 11:56:11 -0700 Subject: [PATCH 03/21] feat: move balance requirement to WelcomeToDashPayFragment --- .../res/layout/fragment_welcome_to_dashpay.xml | 16 ++++++++++++++++ .../username/voting/WelcomeToDashPayFragment.kt | 13 ++++++++++++- 2 files changed, 28 insertions(+), 1 deletion(-) diff --git a/wallet/res/layout/fragment_welcome_to_dashpay.xml b/wallet/res/layout/fragment_welcome_to_dashpay.xml index d14994736..9427e195b 100644 --- a/wallet/res/layout/fragment_welcome_to_dashpay.xml +++ b/wallet/res/layout/fragment_welcome_to_dashpay.xml @@ -164,6 +164,22 @@ + + () override fun onViewCreated(view: View, savedInstanceState: Bundle?) { super.onViewCreated(view, savedInstanceState) @@ -21,5 +24,13 @@ class WelcomeToDashPayFragment : Fragment(R.layout.fragment_welcome_to_dashpay) binding.welcomeDashpayContinueBtn.setOnClickListener { safeNavigate(WelcomeToDashPayFragmentDirections.welcomeToDashPayFragmentToUsernameVotingInfoFragment()) } + + binding.balanceRequirementDisclaimer.text = getString( + R.string.welcome_request_username_min_balance_disclaimer, + requestUserNameViewModel.walletBalance.toPlainString(), + Constants.DASH_PAY_FEE_CONTESTED.toPlainString() + ) + binding.balanceRequirementDisclaimer.isVisible = !requestUserNameViewModel.canAffordIdentityCreation() + binding.welcomeDashpayContinueBtn.isEnabled = requestUserNameViewModel.canAffordIdentityCreation() } } From 93ec4d41af75315e3013fcc4fbb054a7f6761555 Mon Sep 17 00:00:00 2001 From: HashEngineering Date: Thu, 15 Aug 2024 12:03:39 -0700 Subject: [PATCH 04/21] feat: update Username Voting Info fragment --- wallet/res/drawable/ic_face_sad.xml | 10 +++ wallet/res/drawable/ic_voting_icon.xml | 9 +++ .../layout/fragment_username_voting_info.xml | 73 +++++++++++++------ .../voting/UsernameVotingInfoFragment.kt | 8 -- 4 files changed, 70 insertions(+), 30 deletions(-) create mode 100644 wallet/res/drawable/ic_face_sad.xml create mode 100644 wallet/res/drawable/ic_voting_icon.xml diff --git a/wallet/res/drawable/ic_face_sad.xml b/wallet/res/drawable/ic_face_sad.xml new file mode 100644 index 000000000..5fb0d4619 --- /dev/null +++ b/wallet/res/drawable/ic_face_sad.xml @@ -0,0 +1,10 @@ + + + diff --git a/wallet/res/drawable/ic_voting_icon.xml b/wallet/res/drawable/ic_voting_icon.xml new file mode 100644 index 000000000..277415085 --- /dev/null +++ b/wallet/res/drawable/ic_voting_icon.xml @@ -0,0 +1,9 @@ + + + diff --git a/wallet/res/layout/fragment_username_voting_info.xml b/wallet/res/layout/fragment_username_voting_info.xml index 7b0ef558f..14d14fb8b 100644 --- a/wallet/res/layout/fragment_username_voting_info.xml +++ b/wallet/res/layout/fragment_username_voting_info.xml @@ -60,10 +60,11 @@ android:id="@+id/create_a_username_icon" android:layout_width="wrap_content" android:layout_height="wrap_content" - app:srcCompat ="@drawable/ic_blue_clock" + app:srcCompat ="@drawable/ic_voting_icon" app:layout_constraintEnd_toStartOf="@id/create_a_username_title" app:layout_constraintStart_toStartOf="parent" - app:layout_constraintTop_toTopOf="parent" /> + app:layout_constraintBottom_toBottomOf="@id/create_a_username_title" + app:layout_constraintTop_toTopOf="@id/create_a_username_title" /> @@ -82,12 +83,55 @@ android:layout_width="0dp" android:layout_height="wrap_content" android:layout_marginTop="2dp" - android:text="@string/after_voting" + android:text="@string/voting_requirement_subtitle" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintStart_toStartOf="@+id/create_a_username_title" app:layout_constraintTop_toBottomOf="@+id/create_a_username_title" /> + + + + + + + + + @@ -176,27 +220,12 @@ - - \ No newline at end of file diff --git a/wallet/src/de/schildbach/wallet/ui/username/voting/UsernameVotingInfoFragment.kt b/wallet/src/de/schildbach/wallet/ui/username/voting/UsernameVotingInfoFragment.kt index 6a31cfb83..af92eec97 100644 --- a/wallet/src/de/schildbach/wallet/ui/username/voting/UsernameVotingInfoFragment.kt +++ b/wallet/src/de/schildbach/wallet/ui/username/voting/UsernameVotingInfoFragment.kt @@ -33,14 +33,6 @@ class UsernameVotingInfoFragment : Fragment(R.layout.fragment_username_voting_in UsernameVotingInfoFragmentDirections.usernameVotingInfoFragmentToRequestUsernameFragment() ) } - - binding.balanceRequirementDisclaimer.text = getString( - R.string.welcome_request_username_min_balance_disclaimer, - Constants.DASH_PAY_FEE.toPlainString() - ) - binding.balanceRequirementDisclaimer.isVisible = !requestUserNameViewModel.canAffordIdentityCreation() - binding.usernameVotingInfoContinueBtn.isEnabled = requestUserNameViewModel.canAffordIdentityCreation() - lifecycleScope.launchWhenStarted { lifecycleScope.launch { dashPayViewModel.setIsDashPayInfoShown(true) From e27e9b9542f67744e13bc1ffc73b29a204c7d076 Mon Sep 17 00:00:00 2001 From: HashEngineering Date: Thu, 15 Aug 2024 12:05:18 -0700 Subject: [PATCH 05/21] feat: update RequestUsernameFragment to new designs --- wallet/res/drawable/ic_check_circle_empty.xml | 12 + ...te_check.xml => ic_check_circle_green.xml} | 0 wallet/res/drawable/ic_error_circle.xml | 9 + wallet/res/drawable/ic_warning_triangle.xml | 9 + .../layout/activity_onboard_from_invite.xml | 6 +- .../res/layout/fragment_request_username.xml | 220 ++++++++++++++---- wallet/res/values/strings-dashpay.xml | 2 +- wallet/res/values/strings.xml | 135 ----------- .../ui/invite/OnboardFromInviteActivity.kt | 7 +- .../voting/RequestUserNameViewModel.kt | 98 +++++++- .../voting/RequestUsernameFragment.kt | 120 ++++++++-- 11 files changed, 409 insertions(+), 209 deletions(-) create mode 100644 wallet/res/drawable/ic_check_circle_empty.xml rename wallet/res/drawable/{ic_onboard_from_invite_check.xml => ic_check_circle_green.xml} (100%) create mode 100644 wallet/res/drawable/ic_error_circle.xml create mode 100644 wallet/res/drawable/ic_warning_triangle.xml diff --git a/wallet/res/drawable/ic_check_circle_empty.xml b/wallet/res/drawable/ic_check_circle_empty.xml new file mode 100644 index 000000000..2a413f8df --- /dev/null +++ b/wallet/res/drawable/ic_check_circle_empty.xml @@ -0,0 +1,12 @@ + + + diff --git a/wallet/res/drawable/ic_onboard_from_invite_check.xml b/wallet/res/drawable/ic_check_circle_green.xml similarity index 100% rename from wallet/res/drawable/ic_onboard_from_invite_check.xml rename to wallet/res/drawable/ic_check_circle_green.xml diff --git a/wallet/res/drawable/ic_error_circle.xml b/wallet/res/drawable/ic_error_circle.xml new file mode 100644 index 000000000..ab475b1c2 --- /dev/null +++ b/wallet/res/drawable/ic_error_circle.xml @@ -0,0 +1,9 @@ + + + diff --git a/wallet/res/drawable/ic_warning_triangle.xml b/wallet/res/drawable/ic_warning_triangle.xml new file mode 100644 index 000000000..7dbe447c6 --- /dev/null +++ b/wallet/res/drawable/ic_warning_triangle.xml @@ -0,0 +1,9 @@ + + + diff --git a/wallet/res/layout/activity_onboard_from_invite.xml b/wallet/res/layout/activity_onboard_from_invite.xml index 40f37153e..4533e9fa8 100644 --- a/wallet/res/layout/activity_onboard_from_invite.xml +++ b/wallet/res/layout/activity_onboard_from_invite.xml @@ -61,7 +61,7 @@ android:layout_height="wrap_content" android:drawablePadding="8dp" android:text="@string/onboard_from_invite_step1" - app:drawableEndCompat="@drawable/ic_onboard_from_invite_check" /> + app:drawableEndCompat="@drawable/ic_check_circle_green" /> + app:drawableEndCompat="@drawable/ic_check_circle_green" /> + app:drawableEndCompat="@drawable/ic_check_circle_green" /> - + + + + + + + + - + + + + + + + + + - + + + + + + + + + - + android:layout_marginTop="8dp"> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +