Compare commits

..
Author SHA1 Message Date
Andrea Maria Piana bed2057d97 Add caching of token amounts
https://github.com/status-im/status-go/compare/1f7816dd...022b6fd4
2024-08-16 13:31:50 +01:00
Andrea Maria Piana ce87945736 Check price is nil 2024-08-16 12:56:05 +01:00
Andrea Maria Piana f4e0c69d72 test caching
https://github.com/status-im/status-go/compare/1f7816dd...022b6fd4
2024-08-16 12:55:22 +01:00
09c4e33834 Jc/cp3 (#21058)
* chore(status-go) bump to latest

https://github.com/status-im/status-go/compare/a93c8572...dd787c98

* feature: require manual acceptance of terms-of-use and privacy-statement (#21010)

This change changes the initial onboarding screen to require users to manually accept the terms-of-use and privacy-statement before continuing to onboard into the app.


* Hide provider down toast
---------

Co-authored-by: Yevheniia Berdnyk <ie.berdnyk@gmail.com>

* 👓 Hide chain down toasts (#21055)

---------

Co-authored-by: Sean Hagstrom <sean@seanhagstrom.com>
Co-authored-by: Yevheniia Berdnyk <ie.berdnyk@gmail.com>
Co-authored-by: Shivek Khurana <khuranashivek@outlook.com>
2024-08-15 15:57:06 +01:00
Andrea Maria Piana 5b79f40de1 add logs 2024-08-15 12:52:40 +01:00
Andrea Maria Piana 6b29021075 [Remove me] Set credentials to test:test in prod proxy
Prod server is misconfigured, it's using test server credentials.
This commit hardcodes those credentials to continue testing. It will
break once prod is updated.
2024-08-15 08:29:08 +01:00
Andrea Maria Piana 236dc37159 Revert "REMOVE ME, log config"
This reverts commit b43fc6fabf.
2024-08-15 08:28:33 +01:00
Andrea Maria Piana b43fc6fabf REMOVE ME, log config 2024-08-15 08:03:35 +01:00
Andrea Maria Piana 3d205c837c drive stage from config
https://github.com/status-im/status-go/compare/1f7816dd...5bb7c6a8
2024-08-14 20:12:32 +01:00
frank 5c8fc2f700 fix_:enable light client after sync (#21041) (#21042) 2024-08-14 16:46:50 +05:30
Jamie Caprani 1c9d69416b cherry pick to release (#21038) 2024-08-13 15:48:17 +01:00
Andrea Maria Piana 26fb0b20e7 update status-go version 2024-08-13 14:00:50 +01:00
Mohsen b47f53777d [#20971] fix: app crash when collectible max limit is nan (#20992) 2024-08-12 10:24:45 -03:00
Parvesh Monu 1d298d0a5d Improve theme switch (#20984) 2024-08-12 10:24:45 -03:00
Andrea Maria Piana b6f59bc5c0 update status-go version 2024-08-12 13:54:40 +01:00
Andrea Maria Piana 38dd9c46c2 update status-go version 2024-08-12 13:49:42 +01:00
Ulises Manuel 2b6e782e80 fix(wallet): Remove redirection to send flow when the user scans an address QR code (#20979) 2024-08-08 17:28:32 +01:00
Andrea Maria Piana c32f31f8cd update status-go version 2024-08-08 13:57:27 +01:00
flexsurfer 50e41c8ed5 Token-gated permissions are not displayed on community's homepage #20965 (#20976) 2024-08-08 13:50:14 +01:00
Siddarth Kumar 93b748a629 update status-go version to latest release 2024-08-07 14:50:33 +05:30
frankandSiddarth Kumar a324481206 chore:enable status proxy (#20931)
* feat_: enable status proxy

* chore: update jenkins lib

* chore: add missing env reference

---------

Co-authored-by: Siddarth Kumar <siddarthkay@gmail.com>
2024-08-07 14:46:44 +05:30
Jamie Caprani 254717971e Cherry pick to release branch (#20963) 2024-08-06 15:43:10 +01:00
Icaro Motta 05279c111e Bump status-go version 2024-08-02 11:20:20 -03:00
Lungu Cristian b4a49bfe55 Fix typed-data chainid check (#20943)
* fix: typed-data chainid check & toast on sign fail

* fix: parsing the chain-id and error-handling
2024-08-02 11:20:20 -03:00
Sean Hagstrom e5c3357317 fix: remove mobile-data sync setting inside legacy settings (#20942) 2024-08-02 11:20:20 -03:00
Parvesh Monu da2e5ff1c0 fix 'Usage data' bottom sheet reappears after reopening the app if you swipe it down on onboarding (#20945) 2024-08-02 11:20:20 -03:00
Parvesh Monu f69f075e29 fix Mobile app doesn't allow taking screenshots when the 'Block Screenshots' toggle is turned off (#20941) 2024-08-02 11:20:20 -03:00
Ulises Manuel 81350b978f fix(wallet): Error while bridging tokens due to bonderFees (#20929) 2024-08-02 11:20:20 -03:00
Brian Sztamfater f59dca0589 chore: bump react-native-camera-link version to Status fork to remove usage of ML Kit (#20891) 2024-08-02 11:20:20 -03:00
Brian Sztamfater 745e5d75fb fix(wallet): inverted values of receiver and sender when displaying bridging routes (#20893)
Signed-off-by: Brian Sztamfater <brian@status.im>
2024-08-02 11:20:20 -03:00
Mohamed Javid 7c6f2bf878 fix(android): send and bridge ERC-20 tokens (#20924)
This commit adds the missing "encodeFunctionCall" method in Android

Signed-off-by: Mohamed Javid <19339952+smohamedjavid@users.noreply.github.com>
2024-08-02 11:20:20 -03:00
Icaro MottaandMohamed Javid 29203e57ec Update release branch 2.30.x (#20925)
* fix_: use usd as default currency (#20916)

This commit uses "usd" currency as default for the fiat price calculation for the tokens. 

Every currency has a different format - decimal which we need to rely on a separate RPC to fetch currency format and do the calculation. So, this PR will change to use usd as the default for v2.30.

Signed-off-by: Mohamed Javid <19339952+smohamedjavid@users.noreply.github.com>

* Bump status-go version

---------

Signed-off-by: Mohamed Javid <19339952+smohamedjavid@users.noreply.github.com>
Co-authored-by: Mohamed Javid <19339952+smohamedjavid@users.noreply.github.com>
2024-07-30 16:09:44 -03:00
Icaro Motta 0f15c0192d Update release branch 2.30.x (#20903)
Revisions from develop:

- 59ceddbaa develop origin/develop fix(wallet): fix bridge transactions (#20902)
- 99ccbc338 Cover wallet send events with tests Part 2 #20411 #20533 (#20721)
- 8c2d5398b Enabling WalletConnect feature flag (#20906)
- 67c83b13e fix(wallet): remove edit routes button in bridging (#20874)
- 11a84ba14 feat(wallet): disable complex routing (#20901)
- 1f5bb579c chore(wallet): disable bridging on unsupported tokens (#20846)
- 4586f8007 Add toggle in advanced settings for mobile data
- 55c620e59 fix: create password for small screen (#20645)
- 525609f0a Wallet Activity: transactions are not sorted by time #20808 (#20862)
- 90653955a chore(settings): Disable telemetry option (#20881)
- d27ab756d fix_:display group message using the new ui (#20787)
- c6a1db633 ci: enable split apks & build only for arm64-v8a (#20683)
- 73777e052 Ensure keycard account can send transaction after upgrading from v1 to v2 #20552 (#20845)
- a6d3fc374 [#20524] fix: the missed keypairs are shown in the key pair list screen (#20888)
- a671c7083 fix broken screen and navigation when syncing fails (#20887)
- a45991b6d 🥅 Filter connected dapps based on testnet mode, reject proposals and requests gracefully (#20799)
- 2e9fa22e4 feat: wallet router v2 (#20631)
- 737d8c4d5 rename sub to fix error when requesting to join community (#20868)
- 3aa7e103f Sync process is blocked on Enabled notifications screen (#20883)
- c1d2d44da perf: Fix app freeze after login (#20729)
- 0fed8113d e2e: updated testnet switching and added one test into smoke
- 53c35cb55 fix(wallet): Linear gradient exception on invalid colors for watched account cards (#20854)
- be8236554 chore(settings)_: Remove testnet toggle from legacy advanced settings (#20875)
- eae8a6559 feat(wallet)_: Add beta info box in activity tab (#20873)
- fe54a25a3 fix: not clearing network & web3-wallet on logout (#20886)
- 15a4219ef Reject wallet-connect request by dragging the modal down (#20763) (#20836)
- 2ffbdac89 WalletConnect show expired toast (#20857)
- 402eb8397 fix Issue with scrolling WalletConnect transaction on Android (#20867)
- ff88049a0 Fix WalletConnect header alignment on Android (#20860)
- cee21241d WalletConnect no internet edge-cases (#20826)
- 60ad7c8a2 chore(tests): New match-strict? cljs.test directive (#20825)
- 4989c9278 fix_: Adding own address as saved addresses (#20839)
2024-07-30 11:28:07 -03:00
Andrea Maria Piana a1784c5e1f Merge branch 'develop' into release/2.30.x
https://github.com/status-im/status-go/compare/4a43b2b2...4a43b2b2
2024-07-24 13:48:37 +01:00
Andrea Maria Piana 45cf31d469 Enable lightclient by default 2024-07-05 09:22:33 +01:00
Andrea Maria Piana f958d95467 Bump status-go version 2024-07-05 09:21:52 +01:00
Andrea Maria Piana 894f8f26ee Bump release to 2.30.0 2024-07-05 09:20:15 +01:00
91 changed files with 1517 additions and 1080 deletions
+1
View File
@@ -35,3 +35,4 @@ FAST_CREATE_COMMUNITY_ENABLED=1
TEST_NETWORKS_ENABLED=1
SHOW_NOT_IMPLEMENTED_FEATURES=0
ENABLE_ALERT_BANNER=0
FLAG_WALLET_CONNECT_ENABLED=1
+1
View File
@@ -38,4 +38,5 @@ SHOW_NOT_IMPLEMENTED_FEATURES=1
DELETE_MESSAGE_FOR_ME_UNDO_TIME_LIMIT=10000
DELETE_MESSAGE_UNDO_TIME_LIMIT=10000
ENABLE_ALERT_BANNER=0
FLAG_WALLET_CONNECT_ENABLED=1
MOBILE_DATA_SYNCING_TOGGLE_ENABLE=0
+1
View File
@@ -36,3 +36,4 @@ LOCAL_PAIRING_ENABLED=1
FAST_CREATE_COMMUNITY_ENABLED=1
TEST_NETWORKS_ENABLED=1
ENABLE_ALERT_BANNER=1
FLAG_WALLET_CONNECT_ENABLED=1
+1
View File
@@ -23,3 +23,4 @@ DELETE_MESSAGE_ENABLED=1
FAST_CREATE_COMMUNITY_ENABLED=0
TEST_NETWORKS_ENABLED=0
ENABLE_ALERT_BANNER=1
FLAG_WALLET_CONNECT_ENABLED=1
+2
View File
@@ -19,3 +19,5 @@ MAX_IMAGES_BATCH=1
DELETE_MESSAGE_ENABLED=1
FAST_CREATE_COMMUNITY_ENABLED=0
TEST_NETWORKS_ENABLED=0
STATUS_PROXY_STAGE_NAME=prod
FLAG_WALLET_CONNECT_ENABLED=1
+1 -1
View File
@@ -1 +1 @@
2.29.0
2.30.0
+1 -1
View File
@@ -1,5 +1,5 @@
#!/usr/bin/env groovy
library 'status-jenkins-lib@v1.9.3'
library 'status-jenkins-lib@v1.9.4'
/* Options section can't access functions in objects. */
def isPRBuild = utils.isPRBuild()
+1 -1
View File
@@ -1,5 +1,5 @@
#!/usr/bin/env groovy
library 'status-jenkins-lib@v1.9.3'
library 'status-jenkins-lib@v1.9.4'
import groovy.json.JsonBuilder
+1 -1
View File
@@ -1,5 +1,5 @@
#!/usr/bin/env groovy
library 'status-jenkins-lib@v1.9.3'
library 'status-jenkins-lib@v1.9.4'
pipeline {
agent { label 'linux' }
+1 -1
View File
@@ -1,5 +1,5 @@
#!/usr/bin/env groovy
library 'status-jenkins-lib@v1.9.3'
library 'status-jenkins-lib@v1.9.4'
/* Options section can't access functions in objects. */
def isPRBuild = utils.isPRBuild()
+1 -1
View File
@@ -1,5 +1,5 @@
#!/usr/bin/env groovy
library 'status-jenkins-lib@v1.9.3'
library 'status-jenkins-lib@v1.9.4'
/* Options section can't access functions in objects. */
def isPRBuild = utils.isPRBuild()
+1 -1
View File
@@ -1,5 +1,5 @@
#!/usr/bin/env groovy
library 'status-jenkins-lib@v1.9.3'
library 'status-jenkins-lib@v1.9.4'
pipeline {
+1 -1
View File
@@ -1,5 +1,5 @@
#!/usr/bin/env groovy
library 'status-jenkins-lib@v1.9.3'
library 'status-jenkins-lib@v1.9.4'
pipeline {
+1 -1
View File
@@ -1,5 +1,5 @@
#!/usr/bin/env groovy
library 'status-jenkins-lib@v1.9.3'
library 'status-jenkins-lib@v1.9.4'
pipeline {
+1 -1
View File
@@ -1,5 +1,5 @@
#!/usr/bin/env groovy
library 'status-jenkins-lib@v1.9.3'
library 'status-jenkins-lib@v1.9.4'
pipeline {
agent { label 'macos' }
+1 -1
View File
@@ -1,5 +1,5 @@
#!/usr/bin/env groovy
library 'status-jenkins-lib@v1.9.3'
library 'status-jenkins-lib@v1.9.4'
pipeline {
agent { label params.AGENT_LABEL }
+1 -1
View File
@@ -1,5 +1,5 @@
#!/usr/bin/env groovy
library 'status-jenkins-lib@v1.9.3'
library 'status-jenkins-lib@v1.9.4'
pipeline {
agent { label 'linux' }
+1 -1
View File
@@ -1,5 +1,5 @@
#!/usr/bin/env groovy
library 'status-jenkins-lib@v1.9.3'
library 'status-jenkins-lib@v1.9.4'
pipeline {
agent {
@@ -62,6 +62,11 @@ public class EncryptionUtils extends ReactContextBaseJavaModule {
return Statusgo.encodeTransfer(to, value);
}
@ReactMethod(isBlockingSynchronousMethod = true)
public String encodeFunctionCall(final String method, final String paramsJSON) {
return Statusgo.encodeFunctionCall(method, paramsJSON);
}
@ReactMethod(isBlockingSynchronousMethod = true)
public String decodeParameters(final String decodeParamJSON) {
return Statusgo.decodeParameters(decodeParamJSON);
+317 -460
View File
File diff suppressed because it is too large Load Diff
+1 -19
View File
@@ -45,7 +45,6 @@ androidx.core:core-splashscreen:1.0.0
androidx.core:core:1.0.0
androidx.core:core:1.1.0
androidx.core:core:1.1.0-rc01
androidx.core:core:1.2.0
androidx.core:core:1.6.0
androidx.core:core:1.9.0
androidx.cursoradapter:cursoradapter:1.0.0
@@ -68,7 +67,6 @@ androidx.documentfile:documentfile:1.0.0
androidx.drawerlayout:drawerlayout:1.0.0
androidx.emoji2:emoji2-views-helper:1.2.0
androidx.emoji2:emoji2:1.2.0
androidx.exifinterface:exifinterface:1.0.0
androidx.exifinterface:exifinterface:1.1.0-beta01
androidx.exifinterface:exifinterface:1.1.0-rc01
androidx.exifinterface:exifinterface:1.2.0
@@ -518,15 +516,7 @@ com.googlecode.javaewah:JavaEWAH:1.1.12
com.googlecode.javaewah:JavaEWAH:1.1.13
com.googlecode.json-simple:json-simple:1.1
com.googlecode.juniversalchardet:juniversalchardet:1.0.3
com.google.android.datatransport:transport-api:2.2.1
com.google.android.datatransport:transport-backend-cct:2.3.3
com.google.android.datatransport:transport-runtime:2.2.6
com.google.android.gms:play-services-basement:18.0.0
com.google.android.gms:play-services-base:18.0.1
com.google.android.gms:play-services-mlkit-barcode-scanning:18.0.0
com.google.android.gms:play-services-tasks:18.0.1
com.google.android.material:material:1.2.0-alpha03
com.google.android.odml:image:1.0.0-beta1
com.google.android:annotations:4.1.1.4
com.google.api.grpc:proto-google-common-protos:1.12.0
com.google.api.grpc:proto-google-common-protos:2.0.1
@@ -553,10 +543,6 @@ com.google.errorprone:error_prone_annotations:2.3.4
com.google.errorprone:error_prone_annotations:2.4.0
com.google.errorprone:error_prone_annotations:2.9.0
com.google.errorprone:error_prone_annotations:2.11.0
com.google.firebase:firebase-annotations:16.0.0
com.google.firebase:firebase-components:16.1.0
com.google.firebase:firebase-encoders-json:17.1.0
com.google.firebase:firebase-encoders:16.1.0
com.google.flatbuffers:flatbuffers-java:1.12.0
com.google.guava:failureaccess:1.0.1
com.google.guava:guava:17.0
@@ -572,11 +558,6 @@ com.google.guava:listenablefuture:9999.0-empty-to-avoid-conflict-with-guava
com.google.j2objc:j2objc-annotations:1.1
com.google.j2objc:j2objc-annotations:1.3
com.google.jimfs:jimfs:1.1
com.google.mlkit:barcode-scanning-common:17.0.0
com.google.mlkit:barcode-scanning:17.0.2
com.google.mlkit:common:18.0.0
com.google.mlkit:vision-common:17.0.0
com.google.mlkit:vision-interfaces:16.0.0
com.google.prefab:cli:2.0.0
com.google.protobuf:protobuf-java-util:3.4.0
com.google.protobuf:protobuf-java-util:3.10.0
@@ -591,6 +572,7 @@ com.google.testing.platform:core-proto:0.0.8-alpha04
com.google.testing.platform:core-proto:0.0.8-alpha07
com.google.testing.platform:core-proto:0.0.8-alpha08
com.google.test.platform:core-proto:0.0.2-dev
com.google.zxing:core:3.4.1
com.ibm.icu:icu4j:53.1
com.intellij:annotations:12.0
com.parse.bolts:bolts-tasks:1.4.0
+35 -44
View File
@@ -87,7 +87,6 @@ https://dl.google.com/dl/android/maven2/androidx/documentfile/documentfile/1.0.0
https://dl.google.com/dl/android/maven2/androidx/drawerlayout/drawerlayout/1.0.0/drawerlayout-1.0.0.pom
https://dl.google.com/dl/android/maven2/androidx/emoji2/emoji2-views-helper/1.2.0/emoji2-views-helper-1.2.0.pom
https://dl.google.com/dl/android/maven2/androidx/emoji2/emoji2/1.2.0/emoji2-1.2.0.pom
https://dl.google.com/dl/android/maven2/androidx/exifinterface/exifinterface/1.0.0/exifinterface-1.0.0.pom
https://dl.google.com/dl/android/maven2/androidx/exifinterface/exifinterface/1.1.0-beta01/exifinterface-1.1.0-beta01.pom
https://dl.google.com/dl/android/maven2/androidx/exifinterface/exifinterface/1.1.0-rc01/exifinterface-1.1.0-rc01.pom
https://dl.google.com/dl/android/maven2/androidx/exifinterface/exifinterface/1.2.0/exifinterface-1.2.0.pom
@@ -481,26 +480,8 @@ https://dl.google.com/dl/android/maven2/com/android/zipflinger/7.0.4/zipflinger-
https://dl.google.com/dl/android/maven2/com/android/zipflinger/7.2.1/zipflinger-7.2.1.pom
https://dl.google.com/dl/android/maven2/com/android/zipflinger/7.3.1/zipflinger-7.3.1.pom
https://dl.google.com/dl/android/maven2/com/android/zipflinger/8.1.1/zipflinger-8.1.1.pom
https://dl.google.com/dl/android/maven2/com/google/android/datatransport/transport-api/2.2.1/transport-api-2.2.1.pom
https://dl.google.com/dl/android/maven2/com/google/android/datatransport/transport-backend-cct/2.3.3/transport-backend-cct-2.3.3.pom
https://dl.google.com/dl/android/maven2/com/google/android/datatransport/transport-runtime/2.2.5/transport-runtime-2.2.5.pom
https://dl.google.com/dl/android/maven2/com/google/android/datatransport/transport-runtime/2.2.6/transport-runtime-2.2.6.pom
https://dl.google.com/dl/android/maven2/com/google/android/gms/play-services-basement/18.0.0/play-services-basement-18.0.0.pom
https://dl.google.com/dl/android/maven2/com/google/android/gms/play-services-base/18.0.1/play-services-base-18.0.1.pom
https://dl.google.com/dl/android/maven2/com/google/android/gms/play-services-mlkit-barcode-scanning/18.0.0/play-services-mlkit-barcode-scanning-18.0.0.pom
https://dl.google.com/dl/android/maven2/com/google/android/gms/play-services-tasks/18.0.1/play-services-tasks-18.0.1.pom
https://dl.google.com/dl/android/maven2/com/google/android/material/material/1.0.0/material-1.0.0.pom
https://dl.google.com/dl/android/maven2/com/google/android/material/material/1.2.0-alpha03/material-1.2.0-alpha03.pom
https://dl.google.com/dl/android/maven2/com/google/android/odml/image/1.0.0-beta1/image-1.0.0-beta1.pom
https://dl.google.com/dl/android/maven2/com/google/firebase/firebase-annotations/16.0.0/firebase-annotations-16.0.0.pom
https://dl.google.com/dl/android/maven2/com/google/firebase/firebase-components/16.1.0/firebase-components-16.1.0.pom
https://dl.google.com/dl/android/maven2/com/google/firebase/firebase-encoders-json/17.1.0/firebase-encoders-json-17.1.0.pom
https://dl.google.com/dl/android/maven2/com/google/firebase/firebase-encoders/16.1.0/firebase-encoders-16.1.0.pom
https://dl.google.com/dl/android/maven2/com/google/mlkit/barcode-scanning-common/17.0.0/barcode-scanning-common-17.0.0.pom
https://dl.google.com/dl/android/maven2/com/google/mlkit/barcode-scanning/17.0.2/barcode-scanning-17.0.2.pom
https://dl.google.com/dl/android/maven2/com/google/mlkit/common/18.0.0/common-18.0.0.pom
https://dl.google.com/dl/android/maven2/com/google/mlkit/vision-common/17.0.0/vision-common-17.0.0.pom
https://dl.google.com/dl/android/maven2/com/google/mlkit/vision-interfaces/16.0.0/vision-interfaces-16.0.0.pom
https://dl.google.com/dl/android/maven2/com/google/prefab/cli/2.0.0/cli-2.0.0.pom
https://dl.google.com/dl/android/maven2/com/google/testing/platform/core-proto/0.0.8-alpha04/core-proto-0.0.8-alpha04.pom
https://dl.google.com/dl/android/maven2/com/google/testing/platform/core-proto/0.0.8-alpha07/core-proto-0.0.8-alpha07.pom
@@ -523,12 +504,12 @@ https://repo.maven.apache.org/maven2/commons-codec/commons-codec/1.6/commons-cod
https://repo.maven.apache.org/maven2/commons-codec/commons-codec/1.9/commons-codec-1.9.pom
https://repo.maven.apache.org/maven2/commons-codec/commons-codec/1.10/commons-codec-1.10.pom
https://repo.maven.apache.org/maven2/commons-codec/commons-codec/1.11/commons-codec-1.11.pom
https://repo.maven.apache.org/maven2/commons-codec/commons-codec/1.17.0/commons-codec-1.17.0.pom
https://repo.maven.apache.org/maven2/commons-codec/commons-codec/1.17.1/commons-codec-1.17.1.pom
https://repo.maven.apache.org/maven2/commons-io/commons-io/2.4/commons-io-2.4.pom
https://repo.maven.apache.org/maven2/commons-io/commons-io/2.16.1/commons-io-2.16.1.pom
https://repo.maven.apache.org/maven2/commons-logging/commons-logging/1.1.1/commons-logging-1.1.1.pom
https://repo.maven.apache.org/maven2/commons-logging/commons-logging/1.2/commons-logging-1.2.pom
https://repo.maven.apache.org/maven2/commons-logging/commons-logging/1.3.2/commons-logging-1.3.2.pom
https://repo.maven.apache.org/maven2/commons-logging/commons-logging/1.3.3/commons-logging-1.3.3.pom
https://repo.maven.apache.org/maven2/com/adobe/xmp/xmpcore/6.1.11/xmpcore-6.1.11.pom
https://repo.maven.apache.org/maven2/com/afollestad/material-dialogs/commons/0.9.6.0/commons-0.9.6.0.pom
https://repo.maven.apache.org/maven2/com/afollestad/material-dialogs/core/0.9.6.0/core-0.9.6.0.pom
@@ -628,22 +609,22 @@ https://repo.maven.apache.org/maven2/com/facebook/soloader/soloader/0.10.1/soloa
https://repo.maven.apache.org/maven2/com/facebook/soloader/soloader/0.10.5/soloader-0.10.5.pom
https://repo.maven.apache.org/maven2/com/facebook/yoga/proguard-annotations/1.19.0/proguard-annotations-1.19.0.pom
https://repo.maven.apache.org/maven2/com/fasterxml/jackson/core/jackson-annotations/2.11.1/jackson-annotations-2.11.1.pom
https://repo.maven.apache.org/maven2/com/fasterxml/jackson/core/jackson-annotations/2.17.1/jackson-annotations-2.17.1.pom
https://repo.maven.apache.org/maven2/com/fasterxml/jackson/core/jackson-annotations/2.17.2/jackson-annotations-2.17.2.pom
https://repo.maven.apache.org/maven2/com/fasterxml/jackson/core/jackson-core/2.11.1/jackson-core-2.11.1.pom
https://repo.maven.apache.org/maven2/com/fasterxml/jackson/core/jackson-core/2.17.1/jackson-core-2.17.1.pom
https://repo.maven.apache.org/maven2/com/fasterxml/jackson/core/jackson-core/2.17.2/jackson-core-2.17.2.pom
https://repo.maven.apache.org/maven2/com/fasterxml/jackson/core/jackson-databind/2.11.1/jackson-databind-2.11.1.pom
https://repo.maven.apache.org/maven2/com/fasterxml/jackson/core/jackson-databind/2.17.1/jackson-databind-2.17.1.pom
https://repo.maven.apache.org/maven2/com/fasterxml/jackson/core/jackson-databind/2.17.2/jackson-databind-2.17.2.pom
https://repo.maven.apache.org/maven2/com/fasterxml/jackson/dataformat/jackson-dataformat-xml/2.11.1/jackson-dataformat-xml-2.11.1.pom
https://repo.maven.apache.org/maven2/com/fasterxml/jackson/jackson-base/2.11.1/jackson-base-2.11.1.pom
https://repo.maven.apache.org/maven2/com/fasterxml/jackson/jackson-base/2.17.1/jackson-base-2.17.1.pom
https://repo.maven.apache.org/maven2/com/fasterxml/jackson/jackson-base/2.17.2/jackson-base-2.17.2.pom
https://repo.maven.apache.org/maven2/com/fasterxml/jackson/jackson-bom/2.11.1/jackson-bom-2.11.1.pom
https://repo.maven.apache.org/maven2/com/fasterxml/jackson/jackson-bom/2.17.1/jackson-bom-2.17.1.pom
https://repo.maven.apache.org/maven2/com/fasterxml/jackson/jackson-bom/2.17.2/jackson-bom-2.17.2.pom
https://repo.maven.apache.org/maven2/com/fasterxml/jackson/jackson-parent/2.11/jackson-parent-2.11.pom
https://repo.maven.apache.org/maven2/com/fasterxml/jackson/jackson-parent/2.17/jackson-parent-2.17.pom
https://repo.maven.apache.org/maven2/com/fasterxml/jackson/module/jackson-modules-base/2.11.1/jackson-modules-base-2.11.1.pom
https://repo.maven.apache.org/maven2/com/fasterxml/jackson/module/jackson-modules-base/2.17.1/jackson-modules-base-2.17.1.pom
https://repo.maven.apache.org/maven2/com/fasterxml/jackson/module/jackson-modules-base/2.17.2/jackson-modules-base-2.17.2.pom
https://repo.maven.apache.org/maven2/com/fasterxml/jackson/module/jackson-module-jaxb-annotations/2.11.1/jackson-module-jaxb-annotations-2.11.1.pom
https://repo.maven.apache.org/maven2/com/fasterxml/jackson/module/jackson-module-jaxb-annotations/2.17.1/jackson-module-jaxb-annotations-2.17.1.pom
https://repo.maven.apache.org/maven2/com/fasterxml/jackson/module/jackson-module-jaxb-annotations/2.17.2/jackson-module-jaxb-annotations-2.17.2.pom
https://repo.maven.apache.org/maven2/com/fasterxml/jackson/module/jackson-module-kotlin/2.11.1/jackson-module-kotlin-2.11.1.pom
https://repo.maven.apache.org/maven2/com/fasterxml/oss-parent/38/oss-parent-38.pom
https://repo.maven.apache.org/maven2/com/fasterxml/oss-parent/58/oss-parent-58.pom
@@ -712,7 +693,7 @@ https://repo.maven.apache.org/maven2/com/google/errorprone/error_prone_annotatio
https://repo.maven.apache.org/maven2/com/google/errorprone/error_prone_annotations/2.10.0/error_prone_annotations-2.10.0.pom
https://repo.maven.apache.org/maven2/com/google/errorprone/error_prone_annotations/2.11.0/error_prone_annotations-2.11.0.pom
https://repo.maven.apache.org/maven2/com/google/errorprone/error_prone_annotations/2.27.0/error_prone_annotations-2.27.0.pom
https://repo.maven.apache.org/maven2/com/google/errorprone/error_prone_annotations/2.28.0/error_prone_annotations-2.28.0.pom
https://repo.maven.apache.org/maven2/com/google/errorprone/error_prone_annotations/2.29.2/error_prone_annotations-2.29.2.pom
https://repo.maven.apache.org/maven2/com/google/errorprone/error_prone_parent/2.0.18/error_prone_parent-2.0.18.pom
https://repo.maven.apache.org/maven2/com/google/errorprone/error_prone_parent/2.2.0/error_prone_parent-2.2.0.pom
https://repo.maven.apache.org/maven2/com/google/errorprone/error_prone_parent/2.3.1/error_prone_parent-2.3.1.pom
@@ -725,7 +706,7 @@ https://repo.maven.apache.org/maven2/com/google/errorprone/error_prone_parent/2.
https://repo.maven.apache.org/maven2/com/google/errorprone/error_prone_parent/2.10.0/error_prone_parent-2.10.0.pom
https://repo.maven.apache.org/maven2/com/google/errorprone/error_prone_parent/2.11.0/error_prone_parent-2.11.0.pom
https://repo.maven.apache.org/maven2/com/google/errorprone/error_prone_parent/2.27.0/error_prone_parent-2.27.0.pom
https://repo.maven.apache.org/maven2/com/google/errorprone/error_prone_parent/2.28.0/error_prone_parent-2.28.0.pom
https://repo.maven.apache.org/maven2/com/google/errorprone/error_prone_parent/2.29.2/error_prone_parent-2.29.2.pom
https://repo.maven.apache.org/maven2/com/google/flatbuffers/flatbuffers-java/1.12.0/flatbuffers-java-1.12.0.pom
https://repo.maven.apache.org/maven2/com/google/google/1/google-1.pom
https://repo.maven.apache.org/maven2/com/google/guava/failureaccess/1.0.1/failureaccess-1.0.1.pom
@@ -770,7 +751,7 @@ https://repo.maven.apache.org/maven2/com/google/protobuf/protobuf-bom/3.13.0/pro
https://repo.maven.apache.org/maven2/com/google/protobuf/protobuf-bom/3.17.2/protobuf-bom-3.17.2.pom
https://repo.maven.apache.org/maven2/com/google/protobuf/protobuf-bom/3.19.2/protobuf-bom-3.19.2.pom
https://repo.maven.apache.org/maven2/com/google/protobuf/protobuf-bom/3.19.3/protobuf-bom-3.19.3.pom
https://repo.maven.apache.org/maven2/com/google/protobuf/protobuf-bom/4.27.0/protobuf-bom-4.27.0.pom
https://repo.maven.apache.org/maven2/com/google/protobuf/protobuf-bom/4.28.0-RC1/protobuf-bom-4.28.0-RC1.pom
https://repo.maven.apache.org/maven2/com/google/protobuf/protobuf-javalite/3.17.2/protobuf-javalite-3.17.2.pom
https://repo.maven.apache.org/maven2/com/google/protobuf/protobuf-javalite/3.19.2/protobuf-javalite-3.19.2.pom
https://repo.maven.apache.org/maven2/com/google/protobuf/protobuf-java-util/3.4.0/protobuf-java-util-3.4.0.pom
@@ -787,7 +768,7 @@ https://repo.maven.apache.org/maven2/com/google/protobuf/protobuf-java/3.13.0/pr
https://repo.maven.apache.org/maven2/com/google/protobuf/protobuf-java/3.17.2/protobuf-java-3.17.2.pom
https://repo.maven.apache.org/maven2/com/google/protobuf/protobuf-java/3.19.2/protobuf-java-3.19.2.pom
https://repo.maven.apache.org/maven2/com/google/protobuf/protobuf-java/3.19.3/protobuf-java-3.19.3.pom
https://repo.maven.apache.org/maven2/com/google/protobuf/protobuf-java/4.27.0/protobuf-java-4.27.0.pom
https://repo.maven.apache.org/maven2/com/google/protobuf/protobuf-java/4.28.0-RC1/protobuf-java-4.28.0-RC1.pom
https://repo.maven.apache.org/maven2/com/google/protobuf/protobuf-lite/3.0.1/protobuf-lite-3.0.1.pom
https://repo.maven.apache.org/maven2/com/google/protobuf/protobuf-parent/3.0.0/protobuf-parent-3.0.0.pom
https://repo.maven.apache.org/maven2/com/google/protobuf/protobuf-parent/3.4.0/protobuf-parent-3.4.0.pom
@@ -798,9 +779,11 @@ https://repo.maven.apache.org/maven2/com/google/protobuf/protobuf-parent/3.13.0/
https://repo.maven.apache.org/maven2/com/google/protobuf/protobuf-parent/3.17.2/protobuf-parent-3.17.2.pom
https://repo.maven.apache.org/maven2/com/google/protobuf/protobuf-parent/3.19.2/protobuf-parent-3.19.2.pom
https://repo.maven.apache.org/maven2/com/google/protobuf/protobuf-parent/3.19.3/protobuf-parent-3.19.3.pom
https://repo.maven.apache.org/maven2/com/google/protobuf/protobuf-parent/4.27.0/protobuf-parent-4.27.0.pom
https://repo.maven.apache.org/maven2/com/google/truth/truth-parent/1.4.2/truth-parent-1.4.2.pom
https://repo.maven.apache.org/maven2/com/google/truth/truth/1.4.2/truth-1.4.2.pom
https://repo.maven.apache.org/maven2/com/google/protobuf/protobuf-parent/4.28.0-RC1/protobuf-parent-4.28.0-RC1.pom
https://repo.maven.apache.org/maven2/com/google/truth/truth-parent/1.4.4/truth-parent-1.4.4.pom
https://repo.maven.apache.org/maven2/com/google/truth/truth/1.4.4/truth-1.4.4.pom
https://repo.maven.apache.org/maven2/com/google/zxing/core/3.4.1/core-3.4.1.pom
https://repo.maven.apache.org/maven2/com/google/zxing/zxing-parent/3.4.1/zxing-parent-3.4.1.pom
https://repo.maven.apache.org/maven2/com/ibm/icu/icu4j/53.1/icu4j-53.1.pom
https://repo.maven.apache.org/maven2/com/intellij/annotations/12.0/annotations-12.0.pom
https://repo.maven.apache.org/maven2/com/parse/bolts/bolts-tasks/1.4.0/bolts-tasks-1.4.0.pom
@@ -971,9 +954,11 @@ https://repo.maven.apache.org/maven2/net/bytebuddy/byte-buddy-agent/1.14.15/byte
https://repo.maven.apache.org/maven2/net/bytebuddy/byte-buddy-parent/1.11.13/byte-buddy-parent-1.11.13.pom
https://repo.maven.apache.org/maven2/net/bytebuddy/byte-buddy-parent/1.11.19/byte-buddy-parent-1.11.19.pom
https://repo.maven.apache.org/maven2/net/bytebuddy/byte-buddy-parent/1.14.15/byte-buddy-parent-1.14.15.pom
https://repo.maven.apache.org/maven2/net/bytebuddy/byte-buddy-parent/1.14.17/byte-buddy-parent-1.14.17.pom
https://repo.maven.apache.org/maven2/net/bytebuddy/byte-buddy/1.11.13/byte-buddy-1.11.13.pom
https://repo.maven.apache.org/maven2/net/bytebuddy/byte-buddy/1.11.19/byte-buddy-1.11.19.pom
https://repo.maven.apache.org/maven2/net/bytebuddy/byte-buddy/1.14.15/byte-buddy-1.14.15.pom
https://repo.maven.apache.org/maven2/net/bytebuddy/byte-buddy/1.14.17/byte-buddy-1.14.17.pom
https://repo.maven.apache.org/maven2/net/java/dev/jna/jna-platform/5.6.0/jna-platform-5.6.0.pom
https://repo.maven.apache.org/maven2/net/java/dev/jna/jna/5.6.0/jna-5.6.0.pom
https://repo.maven.apache.org/maven2/net/java/jvnet-parent/1/jvnet-parent-1.pom
@@ -1018,6 +1003,7 @@ https://repo.maven.apache.org/maven2/org/apache/apache/18/apache-18.pom
https://repo.maven.apache.org/maven2/org/apache/apache/21/apache-21.pom
https://repo.maven.apache.org/maven2/org/apache/apache/23/apache-23.pom
https://repo.maven.apache.org/maven2/org/apache/apache/31/apache-31.pom
https://repo.maven.apache.org/maven2/org/apache/apache/32/apache-32.pom
https://repo.maven.apache.org/maven2/org/apache/commons/commons-compress/1.8.1/commons-compress-1.8.1.pom
https://repo.maven.apache.org/maven2/org/apache/commons/commons-compress/1.12/commons-compress-1.12.pom
https://repo.maven.apache.org/maven2/org/apache/commons/commons-compress/1.20/commons-compress-1.20.pom
@@ -1037,6 +1023,7 @@ https://repo.maven.apache.org/maven2/org/apache/commons/commons-parent/42/common
https://repo.maven.apache.org/maven2/org/apache/commons/commons-parent/48/commons-parent-48.pom
https://repo.maven.apache.org/maven2/org/apache/commons/commons-parent/52/commons-parent-52.pom
https://repo.maven.apache.org/maven2/org/apache/commons/commons-parent/69/commons-parent-69.pom
https://repo.maven.apache.org/maven2/org/apache/commons/commons-parent/71/commons-parent-71.pom
https://repo.maven.apache.org/maven2/org/apache/httpcomponents/httpclient/4.1.1/httpclient-4.1.1.pom
https://repo.maven.apache.org/maven2/org/apache/httpcomponents/httpclient/4.2.6/httpclient-4.2.6.pom
https://repo.maven.apache.org/maven2/org/apache/httpcomponents/httpclient/4.5.2/httpclient-4.5.2.pom
@@ -1091,7 +1078,7 @@ https://repo.maven.apache.org/maven2/org/checkerframework/checker-qual/2.8.1/che
https://repo.maven.apache.org/maven2/org/checkerframework/checker-qual/2.11.1/checker-qual-2.11.1.pom
https://repo.maven.apache.org/maven2/org/checkerframework/checker-qual/3.5.0/checker-qual-3.5.0.pom
https://repo.maven.apache.org/maven2/org/checkerframework/checker-qual/3.12.0/checker-qual-3.12.0.pom
https://repo.maven.apache.org/maven2/org/checkerframework/checker-qual/3.44.0/checker-qual-3.44.0.pom
https://repo.maven.apache.org/maven2/org/checkerframework/checker-qual/3.45.0/checker-qual-3.45.0.pom
https://repo.maven.apache.org/maven2/org/codehaus/codehaus-parent/4/codehaus-parent-4.pom
https://repo.maven.apache.org/maven2/org/codehaus/groovy/groovy-xml/3.0.9/groovy-xml-3.0.9.pom
https://repo.maven.apache.org/maven2/org/codehaus/groovy/groovy-xml/3.0.10/groovy-xml-3.0.10.pom
@@ -1101,21 +1088,21 @@ https://repo.maven.apache.org/maven2/org/codehaus/mojo/animal-sniffer-annotation
https://repo.maven.apache.org/maven2/org/codehaus/mojo/animal-sniffer-annotations/1.17/animal-sniffer-annotations-1.17.pom
https://repo.maven.apache.org/maven2/org/codehaus/mojo/animal-sniffer-annotations/1.18/animal-sniffer-annotations-1.18.pom
https://repo.maven.apache.org/maven2/org/codehaus/mojo/animal-sniffer-annotations/1.19/animal-sniffer-annotations-1.19.pom
https://repo.maven.apache.org/maven2/org/codehaus/mojo/animal-sniffer-annotations/1.23/animal-sniffer-annotations-1.23.pom
https://repo.maven.apache.org/maven2/org/codehaus/mojo/animal-sniffer-annotations/1.24/animal-sniffer-annotations-1.24.pom
https://repo.maven.apache.org/maven2/org/codehaus/mojo/animal-sniffer-parent/1.14/animal-sniffer-parent-1.14.pom
https://repo.maven.apache.org/maven2/org/codehaus/mojo/animal-sniffer-parent/1.17/animal-sniffer-parent-1.17.pom
https://repo.maven.apache.org/maven2/org/codehaus/mojo/animal-sniffer-parent/1.18/animal-sniffer-parent-1.18.pom
https://repo.maven.apache.org/maven2/org/codehaus/mojo/animal-sniffer-parent/1.19/animal-sniffer-parent-1.19.pom
https://repo.maven.apache.org/maven2/org/codehaus/mojo/animal-sniffer-parent/1.23/animal-sniffer-parent-1.23.pom
https://repo.maven.apache.org/maven2/org/codehaus/mojo/animal-sniffer-parent/1.24/animal-sniffer-parent-1.24.pom
https://repo.maven.apache.org/maven2/org/codehaus/mojo/mojo-parent/34/mojo-parent-34.pom
https://repo.maven.apache.org/maven2/org/codehaus/mojo/mojo-parent/40/mojo-parent-40.pom
https://repo.maven.apache.org/maven2/org/codehaus/mojo/mojo-parent/50/mojo-parent-50.pom
https://repo.maven.apache.org/maven2/org/codehaus/mojo/mojo-parent/74/mojo-parent-74.pom
https://repo.maven.apache.org/maven2/org/codehaus/mojo/mojo-parent/84/mojo-parent-84.pom
https://repo.maven.apache.org/maven2/org/codehaus/woodstox/stax2-api/4.2.1/stax2-api-4.2.1.pom
https://repo.maven.apache.org/maven2/org/easymock/easymockclassextension/3.2/easymockclassextension-3.2.pom
https://repo.maven.apache.org/maven2/org/easymock/easymock-parent/3.2/easymock-parent-3.2.pom
https://repo.maven.apache.org/maven2/org/easymock/easymock-parent/5.2.0/easymock-parent-5.2.0.pom
https://repo.maven.apache.org/maven2/org/easymock/easymock/5.2.0/easymock-5.2.0.pom
https://repo.maven.apache.org/maven2/org/easymock/easymock-parent/5.3.0/easymock-parent-5.3.0.pom
https://repo.maven.apache.org/maven2/org/easymock/easymock/5.3.0/easymock-5.3.0.pom
https://repo.maven.apache.org/maven2/org/eclipse/angus/angus-activation-project/2.0.2/angus-activation-project-2.0.2.pom
https://repo.maven.apache.org/maven2/org/eclipse/angus/angus-activation/2.0.2/angus-activation-2.0.2.pom
https://repo.maven.apache.org/maven2/org/eclipse/ee4j/project/1.0.2/project-1.0.2.pom
@@ -1146,9 +1133,10 @@ https://repo.maven.apache.org/maven2/org/glassfish/jaxb/txw2/2.3.1/txw2-2.3.1.po
https://repo.maven.apache.org/maven2/org/glassfish/jaxb/txw2/2.3.2/txw2-2.3.2.pom
https://repo.maven.apache.org/maven2/org/glassfish/jaxb/txw2/4.0.5/txw2-4.0.5.pom
https://repo.maven.apache.org/maven2/org/hamcrest/hamcrest-core/1.3/hamcrest-core-1.3.pom
https://repo.maven.apache.org/maven2/org/hamcrest/hamcrest-core/2.2/hamcrest-core-2.2.pom
https://repo.maven.apache.org/maven2/org/hamcrest/hamcrest-core/3.0-rc1/hamcrest-core-3.0-rc1.pom
https://repo.maven.apache.org/maven2/org/hamcrest/hamcrest-parent/1.3/hamcrest-parent-1.3.pom
https://repo.maven.apache.org/maven2/org/hamcrest/hamcrest/2.2/hamcrest-2.2.pom
https://repo.maven.apache.org/maven2/org/hamcrest/hamcrest/3.0-rc1/hamcrest-3.0-rc1.pom
https://repo.maven.apache.org/maven2/org/jacoco/org.jacoco.build/0.7.4.201502262128/org.jacoco.build-0.7.4.201502262128.pom
https://repo.maven.apache.org/maven2/org/jacoco/org.jacoco.build/0.8.12/org.jacoco.build-0.8.12.pom
https://repo.maven.apache.org/maven2/org/jacoco/org.jacoco.core/0.7.4.201502262128/org.jacoco.core-0.7.4.201502262128.pom
@@ -1248,7 +1236,7 @@ https://repo.maven.apache.org/maven2/org/jetbrains/kotlin/kotlin-reflect/1.6.10/
https://repo.maven.apache.org/maven2/org/jetbrains/kotlin/kotlin-reflect/1.6.20/kotlin-reflect-1.6.20.pom
https://repo.maven.apache.org/maven2/org/jetbrains/kotlin/kotlin-reflect/1.7.22/kotlin-reflect-1.7.22.pom
https://repo.maven.apache.org/maven2/org/jetbrains/kotlin/kotlin-reflect/1.8.20-RC2/kotlin-reflect-1.8.20-RC2.pom
https://repo.maven.apache.org/maven2/org/jetbrains/kotlin/kotlin-reflect/2.0.0/kotlin-reflect-2.0.0.pom
https://repo.maven.apache.org/maven2/org/jetbrains/kotlin/kotlin-reflect/2.0.20-Beta2/kotlin-reflect-2.0.20-Beta2.pom
https://repo.maven.apache.org/maven2/org/jetbrains/kotlin/kotlin-scripting-common/1.6.20/kotlin-scripting-common-1.6.20.pom
https://repo.maven.apache.org/maven2/org/jetbrains/kotlin/kotlin-scripting-common/1.7.22/kotlin-scripting-common-1.7.22.pom
https://repo.maven.apache.org/maven2/org/jetbrains/kotlin/kotlin-scripting-common/1.8.0/kotlin-scripting-common-1.8.0.pom
@@ -1353,7 +1341,7 @@ https://repo.maven.apache.org/maven2/org/jetbrains/kotlin/kotlin-stdlib/1.8.20-R
https://repo.maven.apache.org/maven2/org/jetbrains/kotlin/kotlin-stdlib/1.8.21/kotlin-stdlib-1.8.21.pom
https://repo.maven.apache.org/maven2/org/jetbrains/kotlin/kotlin-stdlib/1.9.0/kotlin-stdlib-1.9.0.pom
https://repo.maven.apache.org/maven2/org/jetbrains/kotlin/kotlin-stdlib/1.9.21/kotlin-stdlib-1.9.21.pom
https://repo.maven.apache.org/maven2/org/jetbrains/kotlin/kotlin-stdlib/2.0.0/kotlin-stdlib-2.0.0.pom
https://repo.maven.apache.org/maven2/org/jetbrains/kotlin/kotlin-stdlib/2.0.20-Beta2/kotlin-stdlib-2.0.20-Beta2.pom
https://repo.maven.apache.org/maven2/org/jetbrains/kotlin/kotlin-tooling-core/1.7.22/kotlin-tooling-core-1.7.22.pom
https://repo.maven.apache.org/maven2/org/jetbrains/kotlin/kotlin-tooling-core/1.8.0/kotlin-tooling-core-1.8.0.pom
https://repo.maven.apache.org/maven2/org/jetbrains/kotlin/kotlin-tooling-core/1.9.0/kotlin-tooling-core-1.9.0.pom
@@ -1372,6 +1360,7 @@ https://repo.maven.apache.org/maven2/org/jetbrains/trove4j/trove4j/20160824/trov
https://repo.maven.apache.org/maven2/org/json/json/20180813/json-20180813.pom
https://repo.maven.apache.org/maven2/org/json/json/20240303/json-20240303.pom
https://repo.maven.apache.org/maven2/org/jsoup/jsoup/1.13.1/jsoup-1.13.1.pom
https://repo.maven.apache.org/maven2/org/jspecify/jspecify/1.0.0/jspecify-1.0.0.pom
https://repo.maven.apache.org/maven2/org/junit/junit-bom/5.11.0-M2/junit-bom-5.11.0-M2.pom
https://repo.maven.apache.org/maven2/org/jvnet/staxex/stax-ex/1.7.7/stax-ex-1.7.7.pom
https://repo.maven.apache.org/maven2/org/jvnet/staxex/stax-ex/1.8.1/stax-ex-1.8.1.pom
@@ -1383,8 +1372,10 @@ https://repo.maven.apache.org/maven2/org/mockito/mockito-core/5.12.0/mockito-cor
https://repo.maven.apache.org/maven2/org/mockito/mockito-inline/4.0.0/mockito-inline-4.0.0.pom
https://repo.maven.apache.org/maven2/org/objenesis/objenesis-parent/3.2/objenesis-parent-3.2.pom
https://repo.maven.apache.org/maven2/org/objenesis/objenesis-parent/3.3/objenesis-parent-3.3.pom
https://repo.maven.apache.org/maven2/org/objenesis/objenesis-parent/3.4/objenesis-parent-3.4.pom
https://repo.maven.apache.org/maven2/org/objenesis/objenesis/3.2/objenesis-3.2.pom
https://repo.maven.apache.org/maven2/org/objenesis/objenesis/3.3/objenesis-3.3.pom
https://repo.maven.apache.org/maven2/org/objenesis/objenesis/3.4/objenesis-3.4.pom
https://repo.maven.apache.org/maven2/org/ow2/asm/asm-analysis/5.0.3/asm-analysis-5.0.3.pom
https://repo.maven.apache.org/maven2/org/ow2/asm/asm-analysis/5.1/asm-analysis-5.1.pom
https://repo.maven.apache.org/maven2/org/ow2/asm/asm-analysis/6.0/asm-analysis-6.0.pom
+1 -1
View File
@@ -41,7 +41,7 @@
"react-native-background-timer": "^2.1.1",
"react-native-biometrics": "^3.0.1",
"react-native-blob-util": "^0.13.18",
"react-native-camera-kit": "14.0.0-beta13",
"react-native-camera-kit": "git+https://github.com/status-im/react-native-camera-kit.git#refs/tags/v14.0.0-beta15-status-v1",
"react-native-config": "^1.5.0",
"react-native-dialogs": "1.1.2",
"react-native-draggable-flatlist": "4.0.1",
+54
View File
@@ -0,0 +1,54 @@
Last updated: 2023-09-22
Who we are
Status is developing a set of open source projects that use peer-to-peer technologies to help people transact securely, communicate freely, and organise with confidence. Anyone participating in these projects helps to build technology and tools that empowers people to advance their own sovereign communities.
Whenever “Status” or “we” or “us” or any similar variation, are used in these terms, were referring to Status Research & Development GmbH, a Swiss company with its registered office at Baarerstrasse 10, Zug, Switzerland, and includes its “representatives”, which means Status affiliates, directors, officers, employees, agents and any other representatives of Status. For the purposes of these terms, “representatives” also includes Status core contributors without prejudice to the other legal categories mentioned.
Status does not provide any services, such as financial services, to users of Status Software or any third party. Status is not an intermediary, agent, advisor, or custodian, and does not owe you any fiduciary duty.
Status Software
At Status, we strive to develop open source software that can serve as a secure communication tool that helps to uphold human rights. Status Software is specifically designed to facilitate the free flow of information, protect the right to private, secure communications and promote the sovereignty of individuals.
Status Software is composed of a secure messaging tool, a crypto wallet, and a Web 3 browser integrated together. The software developed by Status in this regard is simply called “Status Software” and you can find more details about its development on Status GitHub page.
Our role in your privacy
This Privacy Statement applies to you as a user of Status Software.
Under the relevant data protection legislation, we would be under certain obligations if we process any personal data when you use Status Software. Personal data means all information by which a person can be directly or indirectly identified, in line with the definitions of the General Data Protection Regulation (GDPR), the Swiss Federal Act on Data Protection of June 19, 1992 (DPA) (as amended from time to time) and its ordinances, and other relevant legislation on the protection of personal data. When we refer to privacy legislation in this Privacy Statement, we mean GDPR and all such relevant legislation.
However, since we do not collect or process any of your personal data when you use Status Software, we have decided to inform you of the following instead:
- Ethereum is a public blockchain:
Ethereum is the community-run technology powering the cryptocurrency ether (ETH) and thousands of decentralized applications (DApps). Status Software provides a mobile portal and streamlined access to Ethereums growing ecosystem of decentralized applications.
The Ethereum public network is accessible to anyone in the world with an internet connection. Anyone can read or create transactions on a public blockchain and validate the transactions being executed. Therefore, information you share on the Ethereum blockchain is public, whether or not you use Status Software.
You will also be able to create (and join) open and public communities on Status Software that are accessible to other users. We note that content in these open and public communities will be accessible to all other users of Status Software. Nonetheless, all content will still be protected by the same end-to-end encryption utilised in Status Software.
Ethereum Name Service (ENS) allows Ethereum addresses to be replaced by custom text-based names. Anyone can register a stateofus.eth username by staking the required Status Network Tokens (SNT) from within the profile tab on Status Software. When you register an ENS name with a given wallet address, that address becomes associated with the username, reducing the privacy of that account.
- Offering secure, private messaging:
When generating an account, a randomisation process is started on your own device that generates a key pair. Status does not have visibility of or access to your private keys. You will then be given display name options to choose from (derived from this key pair). Your display name will only be shared if you choose to share it by chatting with Status or other users.
Within Status Software, you can create a list of trusted contacts based on the chat keys you choose to trust. Your trusted contacts are also stored locally on your own device. This means that Status has no access to your contact list and does not collect or process any personal data in this respect.
On Status Software, you can exchange messages with other users, including photos and audio messages. Only the recipient of a message can decrypt the message by opening it on their own device. This means that Status can never access any user messages in private chats.
Messaging on Status Software uses an open source, peer-to-peer protocol with end-to-end encryption and metadata suppression, to protect your messages from third parties (including Status). End-to-end encryption means that only the sender and recipient of a message can read its contents, and no one else. This protocol, known as Waku, relies on a distributed network of nodes instead of a centralised server which means that there is no central party or server from which messages can be intercepted, modified or blocked. Learn more about Waku and how it works on Wakus website.
- A quick bite on cookies:
We do not set any cookies for the use of Status Software. However, the Web 3.0 browser embedded within Status Software technically supports the use of cookies set by third party websites. Status is not responsible for nor is it able to influence whether such cookies are set by such third party websites and you should consult the relevant privacy policies of such third party websites.
Changes to Status Privacy Statement
It is unlikely that this Privacy Statement will change because we do not intend to collect or process your personal data, ever. That said, we reserve the right to modify or replace any part of this Privacy Statement at any time and in our sole discretion.
If you have any questions about the Status Software Privacy Statement, please contact us at legal@status.im or through the appropriate means of communication indicated on Status website.
This document is CC-BY-SA.
+19 -19
View File
@@ -38,7 +38,7 @@ You not only release Status liability on a number of items, but also agree th
- Arbitration
If a dispute arises between you and Status, we will seek to first solve it amicably with you before proceeding to the use of an arbitration administered by the Swiss Chambers Arbitration Institution.
&nbsp;
2. About Status Software
@@ -77,7 +77,7 @@ Within Messaging, you will also be able to participate in Status Community Space
2.1.2 Web 3 browser
Status Software also includes a Web 3 browser through which you may access and interact with Web 3, exchanges, marketplaces, games and more. We will refer to the Web 3 browser in these terms as the “Web 3 Browser”.
&nbsp;
3. Privacy
@@ -95,7 +95,7 @@ If you use third party services offered through Status Software, your privacy ma
Learn more about how we protect your data on Status Software by reading the Status Privacy Statement and relevant security page on the Status website.
&nbsp;
4. Using third party services and interacting with Web 3
@@ -114,19 +114,19 @@ You are solely responsible for your use of Third Party Services and your interac
In principle, Status does not provide any advice, recommendation, support or endorse Third Party Services you may use or any aspect of Web 3 that you may interact with through Status Software. Their integration or availability through Status Software does not imply any support or endorsement by Status. Status may also receive a fee from certain third parties who provide the Third Party Services.
Please also note that Status participates in the development of other open source projects that utilise peer-to-peer technologies, which you can find more details about on Status GitHub page.
&nbsp;
5. Nodes
The use of Status Software on your device will turn it into a node that supports the Waku network.
In general, by participating in or interacting with Web 3 networks, you may choose or be required to operate a node or perform other functions in support of such a network. Status is not responsible for the operation or functioning of such nodes.
&nbsp;
6. Security
Although security is a top priority for us and many functions of Status Software are privacy-mode by default, we cannot guarantee the full security of Status Software and we are not responsible for alerting you to potential security risks. We intend to continuously update the security measures of Status Software and we will from time to time post updates on the security of Status Software through our communication channels.
&nbsp;
7. Content
@@ -142,7 +142,7 @@ You acknowledge that Status has no means of monitoring, moderating, removing, mo
1. could be offensive, indecent, or otherwise objectionable;
2. contains technical inaccuracies, typographical mistakes, and other errors; or
3. could violate others rights, including but not limited to privacy, publicity, intellectual property, or other proprietary rights.
&nbsp;
8. Acceptable use of Status software
@@ -167,12 +167,12 @@ You shall not, nor try to, encourage or assist others using Status Software to:
12. engage in any activity through Status Software that may be in violation of applicable law, rules or regulations in your jurisdiction;
13. interfere, disrupt, negatively affect, or inhibit other users from their use of Status Software; or
14. engage in any attack, hack, denial-of-service attack, interference, or exploit of any smart contract in connection with use of Status Software.
&nbsp;
9. Fees
When you use Status Software to interact with Third Party Services or Web 3, you may incur costs and may have to pay various fees, such as service fees, transfer fees, transaction fees, swap fees, bridge fees or network fees. You will be solely liable for any such fees, costs and expenses. Status has no control over and is unable to influence these fees in any manner.
&nbsp;
10. Intellectual property and branding
@@ -187,7 +187,7 @@ Status (and its affiliates as the case may be) owns all the rights to Status bra
We love to see creative work from the Status community, but please let us know in advance and in writing if you want to use trademarks, logos, or graphics or modify them from our standard colours and designs. If you write articles, blogs, create websites, or talk about Status, please make sure it is clear that you are not speaking for, on behalf of, or under endorsement by Status.
To request permission to use our copyrighted material or trademarks or any other intellectual property, such as logos, please contact: marketing@status.im. If we grant you permission, you must follow our guidelines and instructions for using our intellectual property.
&nbsp;
11. Risks
@@ -222,7 +222,7 @@ With Status Software, you can interact with and transact in Digital Assets and t
You acknowledge that there may be legal and regulatory implications applicable to you while using Status Software and interacting with Web 3 and that may also adversely impact your use of Status Software.
You are solely responsible for evaluating the legal and regulatory implications and taking appropriate actions, which could include obtaining any necessary licences, permits or approvals. Additionally, you are solely responsible for any tax implications, such as the payment of any taxes, resulting from your activities conducted through Status Software, including any transactions in Digital Assets.
&nbsp;
12. Disclaimers
@@ -233,7 +233,7 @@ Status Software is provided on an “as is” basis. Status does not make any ex
4. regarding the value, utility or legality of any Digital Asset;
5. regarding the completeness, accuracy, legality, utility, suitability, functionality, security or availability of any smart contract that you may interact with or deploy; or
6. regarding the completeness, accuracy, legality, utility, reliability, suitability or availability of any user content.
&nbsp;
13. Releases you should read closely
@@ -250,13 +250,13 @@ You release Status from all liability related to any claim, cause of action, con
10. your content or other users content;
11. any unauthorised third party activities, including without limitation the use of viruses, phishing, brute forcing, or other means of attack against Status Software; and
12. any risks identified in these terms or any that a reasonable person should have been aware of in relation to using Status Software.
&nbsp;
14. Limitation of liability
Status will not be held liable to you under any contract, negligence, strict liability, or other legal or equitable theory for any lost profits, cost of procurement for substitute services, or any special, incidental, or consequential damages related to, arising from, or in any way connected with these terms, Status, your use of Status Software, particularly where Status has indicated that it is not responsible. This includes without limitation, your use of SNT or other Digital Assets (creating, distributing, transacting in or otherwise) even if Status has been advised of the possibility of such damages.
In any event, Status aggregate liability for any claims is limited to EUR 100 (one hundred Euros). This limitation of liability will apply to the extent permitted by applicable law.
&nbsp;
15. Indemnity
@@ -268,7 +268,7 @@ You shall indemnify and hold harmless Status from and against any and all claims
5. your harm to or violation of the rights of any third party, including any privacy, intellectual property, publicity, confidentiality, property or any other rights;
6. your use of Third Party Services or any aspect of Web 3; or
7. any misrepresentation or fraudulent statements made by you.
&nbsp;
16. Restricted jurisdictions
@@ -277,7 +277,7 @@ Status is a Swiss company which makes Status Software available through third pa
You acknowledge that Status Software is not intended for use or distribution in any jurisdiction where such use or distribution of software that is similar or identical to Status Software is prohibited or restricted in any way. Your use of Status Software does not and will not subject Status to such jurisdiction under any circumstance, particularly if there are any prohibitions or restrictions on the use of such software. Status reserves the right to limit the availability of Status Software in any jurisdiction.
Status does not conduct any business activities (i.e. activities undertaken for the purpose of earning a profit) within the United States of America, District of Columbia, Puerto Rico, the U.S. Virgin Islands, and all other U.S. territories and possessions, as well as all Swiss embargoed countries.
&nbsp;
17. Materials provided are solely for informational purposes
@@ -286,7 +286,7 @@ Status provides materials and other information through Status Software for info
You should always conduct your own research and seek independent professional advice if necessary. The materials and other information that Status may provide through Status Software does not constitute financial, legal, tax, or other advice and should not be treated as such.
Additionally, Status is not responsible for any information, content, or services contained on any third party websites accessible or linked through the Status Software. By linking such third party websites, Status does not represent or imply that it endorses or supports such third party websites or content therein, or that it believes such third party websites and content therein to be accurate, useful or non-harmful. Status has no control over such third party websites and will not be liable for your use of or activities on any third party websites accessed through Status Software. The terms and conditions, including privacy policies, of such third party websites govern your use of their websites.If you access such third party websites through Status Software, it is at your own risk and you are solely responsible for your activities on such third party websites.
&nbsp;
18. Governing law and dispute resolution
@@ -305,14 +305,14 @@ If a (potential) dispute arises, you must first use your reasonable efforts to r
If you and Status are unable to further resolve this dispute within sixty (60) calendar days of Status receiving this notice of dispute, then any such dispute will be referred to and finally resolved by you and Status through an arbitration administered by the Swiss Chambers Arbitration Institution in accordance with the Swiss Rules of International Arbitration for the time being in force, which rules are deemed to be incorporated herein by reference. The arbitral decision may be enforced in any court. The arbitration will be held in Zug, Switzerland, and may be conducted via video conference virtual/online methods if possible. The tribunal will consist of one arbitrator, and all proceedings as well as communications between the parties will be kept confidential. The language of the arbitration will be in English. Payment of all relevant fees in respect of the arbitration, including filing, administration and arbitrator fees will be in accordance with the Swiss Rules of International Arbitration.
Regardless of any applicable statute of limitations, you must bring any claims within one year after the claim arose or the time when you should have reasonably known about the claim. You also waive the right to participate in a class action lawsuit or a classwide arbitration against Status.
&nbsp;
19. What happens if you stop using Status Software
If, at any time, you no longer agree to these terms, you must immediately stop using Status Software and uninstall it from all your devices. You acknowledge that even after uninstalling Status Software from all your devices, messages (including content) you have sent may still remain on the recipients device, blockchain transactions you have may still be recorded on the blockchain, and any smart contracts you have deployed to a blockchain may still remain deployed.
Even after you have stopped using Status Software, all provisions of these terms which by their nature should survive termination shall survive termination. These provisions include, but are not limited to, warranty disclaimers, indemnity, limitations of liability, dispute resolution, and governing law.
&nbsp;
20. General provisions
+4
View File
@@ -67,6 +67,8 @@
:closure-defines
{status-im.config/POKT_TOKEN #shadow/env "POKT_TOKEN"
status-im.config/INFURA_TOKEN #shadow/env "INFURA_TOKEN"
status-im.config/STATUS_BUILD_PROXY_USER #shadow/env "STATUS_BUILD_PROXY_USER"
status-im.config/STATUS_BUILD_PROXY_PASSWORD #shadow/env "STATUS_BUILD_PROXY_PASSWORD"
status-im.config/MIXPANEL_APP_ID #shadow/env "MIXPANEL_APP_ID"
status-im.config/MIXPANEL_TOKEN #shadow/env "MIXPANEL_TOKEN"
status-im.config/OPENSEA_API_KEY #shadow/env "OPENSEA_API_KEY"
@@ -103,6 +105,8 @@
{:closure-defines
{status-im.config/POKT_TOKEN #shadow/env "POKT_TOKEN"
status-im.config/INFURA_TOKEN #shadow/env "INFURA_TOKEN"
status-im.config/STATUS_BUILD_PROXY_USER #shadow/env "STATUS_BUILD_PROXY_USER"
status-im.config/STATUS_BUILD_PROXY_PASSWORD #shadow/env "STATUS_BUILD_PROXY_PASSWORD"
status-im.config/OPENSEA_API_KEY #shadow/env "OPENSEA_API_KEY"
status-im.config/MIXPANEL_APP_ID #shadow/env "MIXPANEL_APP_ID"
status-im.config/MIXPANEL_TOKEN #shadow/env "MIXPANEL_TOKEN"
@@ -98,16 +98,16 @@
(update :categories <-categories-rpc)
(assoc :role-permissions?
(->> community
:tokenPermissions
:token-permissions
vals
(some role-permission?)))
(assoc :membership-permissions?
(->> community
:tokenPermissions
:token-permissions
vals
(some membership-permission?)))
(assoc :token-images
(reduce (fn [acc {sym :symbol image :image}]
(assoc acc sym image))
{}
(:communityTokensMetadata community))))))
(:tokens-metadata community))))))
+1 -2
View File
@@ -102,8 +102,7 @@
(let [current-theme-type (get-in cofx [:db :profile/profile :appearance])]
(when (and (multiaccounts.model/logged-in? db)
(= current-theme-type status-im.constants/theme-type-system))
{:profile.settings/switch-theme-fx
[(get-in db [:profile/profile :appearance]) (:view-id db)]})))
{:dispatch [:theme/switch]})))
(defn- on-biometric-auth-fail
[{:keys [code]}]
@@ -13,19 +13,17 @@
(native-module/logout)))
(rf/defn initialize-app-db
[{{:keys [keycard initials-avatar-font-file biometrics]
:network/keys [type status expensive?]
:wallet-connect/keys [web3-wallet]}
[{{:keys [keycard initials-avatar-font-file biometrics]
:network/keys [type status expensive?]}
:db}]
{:db (assoc db/app-db
:network/type type
:network/status status
:network/expensive? expensive?
:initials-avatar-font-file initials-avatar-font-file
:keycard (dissoc keycard :secrets :pin :application-info)
:biometrics biometrics
:syncing nil
:wallet-connect/web3-wallet web3-wallet)})
:network/type type
:network/status status
:network/expensive? expensive?
:initials-avatar-font-file initials-avatar-font-file
:keycard (dissoc keycard :secrets :pin :application-info)
:biometrics biometrics
:syncing nil)})
(rf/defn logout-method
{:events [::logout-method]}
@@ -13,8 +13,7 @@
(views/defview sync-settings
[]
(views/letsubs [{:keys [syncing-on-mobile-network?
backup-enabled?
(views/letsubs [{:keys [backup-enabled?
default-sync-period
use-mailservers?]}
[:profile/profile]
@@ -27,16 +26,6 @@
:on-press #(rf/dispatch [:navigate-back])}]
[react/scroll-view
[components/list-header (i18n/label :t/data-syncing)]
[list.item/list-item
{:size :small
:title (i18n/label :t/mobile-network-settings)
:accessibility-label :notifications-button
:on-press #(re-frame/dispatch [:navigate-to :mobile-network-settings])
:chevron true
:accessory :text
:accessory-text (if syncing-on-mobile-network?
(i18n/label :t/mobile-network-use-mobile)
(i18n/label :t/mobile-network-use-wifi))}]
[list.item/list-item
{:size :small
:title (i18n/label :t/backup-settings)
+6 -1
View File
@@ -333,7 +333,7 @@
[flag]
(log/debug "[native-module] set-blank-preview-flag")
;; Sometimes the app crashes during logout because `flag` is nil.
(when flag
(when-not (nil? flag)
(.setBlankPreviewFlag ^js (encryption) flag)))
(defn get-device-model-info
@@ -387,6 +387,11 @@
(log/debug "[native-module] encode-transfer")
(.encodeTransfer ^js (encryption) to-norm amount-hex))
(defn encode-function-call
[method params]
(log/debug "[native-module] encode-function-call")
(.encodeFunctionCall ^js (encryption) method (types/clj->json params)))
(defn decode-parameters
[bytes-string types]
(log/debug "[native-module] decode-parameters")
@@ -20,7 +20,7 @@
[:actions [:maybe [:enum :one-action :two-actions :two-vertical-actions]]]
[:description {:optional true} [:maybe [:enum :top :bottom :top-error]]]
[:description-text {:optional true} [:maybe [:or :string :schema.common/hiccup]]]
[:description-top-text {:optional true} [:maybe :string]]
[:description-top-text {:optional true} [:maybe [:or :string :schema.common/hiccup]]]
[:error-message {:optional true} [:maybe :string]]
[:role {:optional true} [:maybe [:enum :admin :member :token-master :owner]]]
[:context-tag-props {:optional true} [:maybe context-tag.schema/?schema]]
@@ -58,20 +58,23 @@
:style {:color (colors/theme-colors colors/danger-50 colors/danger-60 theme)}}
error-message]])
(when (and (= description :top) (or role context-tag-props))
[rn/view {:style style/description-top}
[text/text
{:size :paragraph-2
:style (style/description-top-text scroll? blur? theme)}
(or description-top-text (i18n/label :t/eligible-to-join-as))]
[context-tag/view
(if role
{:type :icon
:size 24
:icon (role role-icon)
:blur? blur?
:context (i18n/label (keyword "t" role))}
context-tag-props)]])
(when (= description :top)
(if (vector? description-top-text)
description-top-text
(when (or role context-tag-props)
[rn/view {:style style/description-top}
[text/text
{:size :paragraph-2
:style (style/description-top-text scroll? blur? theme)}
(or description-top-text (i18n/label :t/eligible-to-join-as))]
[context-tag/view
(if role
{:type :icon
:size 24
:icon (role role-icon)
:blur? blur?
:context (i18n/label (keyword "t" role))}
context-tag-props)]])))
[rn/view {:style (style/buttons-container actions buttons-container-style)}
(when (or (= actions :two-actions)
@@ -3,14 +3,30 @@
[quo.core :as quo]
[react-native.core :as rn]
[status-im.common.home.title-column.style :as style]
[status-im.common.plus-button.view :as plus-button]))
[status-im.common.plus-button.view :as plus-button]
[utils.i18n :as i18n]))
(defn view
[{:keys [label handler accessibility-label customization-color]}]
[{:keys [beta? label handler accessibility-label customization-color]}]
[rn/view style/title-column
[rn/view {:flex 1}
[rn/view
{:style {:flex 1
:align-items :center
:flex-direction :row}}
[quo/text style/title-column-text
label]]
label]
(when beta?
[rn/view
{:style {:padding-top 6
:padding-bottom 2}}
[quo/tag
{:accessibility-label :communities-chat-beta-tag
:size 32
:type :label
:label (i18n/label :t/beta)
:labelled? true
:blurred? false}]])]
(when handler
[plus-button/plus-button
{:on-press handler
+8
View File
@@ -0,0 +1,8 @@
(ns status-im.common.theme.effects
(:require
[status-im.common.theme.core :as theme]
[utils.re-frame :as rf]))
(rf/reg-fx :theme/legacy-theme-fx
(fn [theme]
(theme/set-legacy-theme theme)))
+15 -3
View File
@@ -1,7 +1,8 @@
(ns status-im.common.theme.events
(:require
[re-frame.core :as re-frame]
[status-im.common.theme.core :as theme]))
[status-im.common.theme.core :as theme]
[status-im.common.theme.utils :as utils]))
(re-frame/reg-fx
:theme/init-theme
@@ -10,5 +11,16 @@
(re-frame/reg-event-fx
:theme/switch
(fn [{db :db} [theme]]
{:db (assoc db :theme theme)}))
(fn [{db :db} [{:keys [theme view-id theme-type]}]]
"Switches the theme and triggers related effects.
Parameters:
- theme: Optional theme keyword to apply. If not provided, defaults to the theme determined by theme-type.
- theme-type: Optional theme type to determine the theme. If not provided, defaults to the theme type from the user's profile.
- view-id: Optional view ID for updating status color. If not provided, uses the current view ID from the database."
(let [theme-type (or theme-type (get-in db [:profile/profile :appearance]))
theme (or theme (utils/theme-type->theme-value theme-type))]
{:db (assoc db :theme theme)
:fx [[:theme/legacy-theme-fx theme]
[:dispatch
[:reload-status-nav-color
(or view-id (:view-id db))]]]})))
+17
View File
@@ -0,0 +1,17 @@
(ns status-im.common.theme.utils
(:require
[status-im.common.theme.core :as theme]
[status-im.constants :as constants]))
(defn theme-type->theme-value
"Converts theme type identifier to a theme keyword.
Returns `:light` or `:dark` based on `theme-type`:
- `theme-type-light` (1): Light theme.
- `theme-type-dark` (2): Dark theme.
- `theme-type-system` (0): Uses system preference."
[theme-type]
(condp = theme-type
constants/theme-type-dark :dark
constants/theme-type-light :light
constants/theme-type-system (if (theme/device-theme-dark?) :dark :light)
:dark))
+4
View File
@@ -12,6 +12,8 @@
(goog-define INFURA_TOKEN "")
(goog-define POKT_TOKEN "3ef2018191814b7e1009b8d9")
(goog-define STATUS_BUILD_PROXY_USER "")
(goog-define STATUS_BUILD_PROXY_PASSWORD "")
(goog-define OPENSEA_API_KEY "")
(goog-define RARIBLE_MAINNET_API_KEY "")
(goog-define RARIBLE_TESTNET_API_KEY "")
@@ -45,6 +47,8 @@
(def mixpanel-token MIXPANEL_TOKEN)
(def opensea-api-key OPENSEA_API_KEY)
(def status-proxy-enabled? true)
(def status-proxy-stage-name (get-config :STATUS_PROXY_STAGE_NAME "test"))
(def bootnodes-settings-enabled? (enabled? (get-config :BOOTNODES_SETTINGS_ENABLED "1")))
(def mailserver-confirmations-enabled? (enabled? (get-config :MAILSERVER_CONFIRMATIONS_ENABLED)))
(def pairing-popup-disabled? (enabled? (get-config :PAIRING_POPUP_DISABLED "0")))
+8
View File
@@ -554,6 +554,14 @@
(def ^:const send-type-erc-721-transfer 6)
(def ^:const send-type-erc-1155-transfer 7)
(def ^:const multi-transaction-type-send 0)
(def ^:const multi-transaction-type-approve 1)
(def ^:const multi-transaction-type-bridge 2)
(def ^:const multi-transaction-type-swap 3)
(def ^:const multi-transaction-type-unknown 255)
(def ^:const contract-function-signature-erc20-approve "approve(address,uint256)")
(def ^:const bridge-name-transfer "Transfer")
(def ^:const bridge-name-erc-721-transfer "ERC721Transfer")
(def ^:const bridge-name-erc-1155-transfer "ERC1155Transfer")
@@ -46,6 +46,10 @@
(when (show-confirmation-modal? db)
{:fx [[:dispatch
[:show-bottom-sheet
{:content (fn [] [modal-view])
:shell? true}]]]})))
{:content (fn [] [modal-view])
;; When in the profiles screen do biometric auth after the metrics sheet is dismissed
;; https://github.com/status-im/status-mobile/issues/20932
:on-close (when (= (:view-id db) :screen/profile.profiles)
#(rf/dispatch [:profile.login/login-with-biometric-if-available
(get-in db [:profile/login :key-uid])]))
:shell? true}]]]})))
@@ -3,37 +3,61 @@
[legacy.status-im.utils.build :as build]
[react-native.platform :as platform]))
(defn user-journey-event
[action]
(defn key-value-event
[event-name val-key value]
{:metric
{:eventName "user-journey"
{:eventName event-name
:platform platform/os
:appVersion build/app-short-version
:eventValue {:action action}}})
:eventValue {val-key value}}})
(defn user-journey-event
[action]
(key-value-event "user-journey" :action action))
(defn navigation-event
[view-id]
(key-value-event "navigation" :viewId view-id))
(def ^:const app-started-event "app-started")
(def ^:const navigate-to-create-profile-event "navigate-to-create-profile")
(def ^:const communities-tab-clicked "communities-tab-clicked")
(def ^:const wallet-tab-clicked "wallet-tab-clicked")
(def ^:const chats-tab-clicked "chats-tab-clicked")
(def ^:const view-ids-to-track
#{;; Tabs
:communities-stack
:chats-stack
:wallet-stack
;; Onboarding
:screen/onboarding.intro
:screen/onboarding.new-to-status
:screen/onboarding.sync-or-recover-profile
:screen/onboarding.enter-seed-phrase
:screen/onboarding.create-profile
:screen/onboarding.create-profile-password
:screen/onboarding.enable-biometrics
:screen/onboarding.generating-keys
:screen/onboarding.enable-notifications
:screen/onboarding.sign-in-intro
:screen/onboarding.sign-in
:screen/onboarding.syncing-progress
:screen/onboarding.syncing-progress-intro
:screen/onboarding.syncing-results
:screen/onboarding.welcome})
(defn track-view-id-event
[view-id]
(case view-id
:communities-stack (user-journey-event communities-tab-clicked)
:chats-stack (user-journey-event chats-tab-clicked)
:wallet-stack (user-journey-event wallet-tab-clicked)
nil))
(when (contains? view-ids-to-track view-id)
(navigation-event (name view-id))))
(defn tracked-event
[[event-name second-parameter]]
(case event-name
:onboarding/navigate-to-create-profile
(user-journey-event navigate-to-create-profile-event)
:profile/get-profiles-overview-success
(user-journey-event app-started-event)
:centralized-metrics/toggle-centralized-metrics
(key-value-event "events.metrics-enabled" :enabled second-parameter)
:set-view-id
(track-view-id-event second-parameter)
@@ -5,31 +5,75 @@
[react-native.platform :as platform]
[status-im.contexts.centralized-metrics.tracking :as tracking]))
(def platform-os platform/os)
(def app-version build/app-short-version)
(deftest key-value-event-test
(testing "creates correct key-value event"
(let [event-name "test-event"
val-key :test-key
value "test-value"
expected {:metric
{:eventName event-name
:platform platform-os
:appVersion app-version
:eventValue {val-key value}}}]
(is (= expected (tracking/key-value-event event-name val-key value))))))
(deftest user-journey-event-test
(testing "creates correct metric event"
(let [action "some-action"
expected {:metric {:eventName "user-journey"
:platform platform/os
:appVersion build/app-short-version
:eventValue {:action action}}}]
(testing "creates correct user journey event"
(let [action "test-action"
expected {:metric
{:eventName "user-journey"
:platform platform-os
:appVersion app-version
:eventValue {:action action}}}]
(is (= expected (tracking/user-journey-event action))))))
(deftest navigation-event-test
(testing "creates correct navigation event"
(let [view-id :test-view-id
expected {:metric
{:eventName "navigation"
:platform platform-os
:appVersion app-version
:eventValue {:viewId view-id}}}]
(is (= expected (tracking/navigation-event view-id))))))
(deftest track-view-id-event-test
(testing "returns correct event for view-id"
(is (= (tracking/user-journey-event tracking/communities-tab-clicked)
(testing "returns correct navigation event for view-id"
(is (= {:metric
{:eventName "navigation"
:platform platform-os
:appVersion app-version
:eventValue {:viewId "communities-stack"}}}
(tracking/track-view-id-event :communities-stack)))
(is (= (tracking/user-journey-event tracking/chats-tab-clicked)
(tracking/track-view-id-event :chats-stack)))
(is (= (tracking/user-journey-event tracking/wallet-tab-clicked)
(tracking/track-view-id-event :wallet-stack)))
(is (= {:metric
{:eventName "navigation"
:platform platform-os
:appVersion app-version
:eventValue {:viewId "onboarding.create-profile"}}}
(tracking/track-view-id-event :screen/onboarding.create-profile)))
(is (nil? (tracking/track-view-id-event :unknown-stack)))))
(deftest tracked-event-test
(testing "returns correct event for given inputs"
(is (= (tracking/user-journey-event tracking/navigate-to-create-profile-event)
(tracking/tracked-event [:onboarding/navigate-to-create-profile])))
(is (= (tracking/user-journey-event tracking/app-started-event)
(is (= {:metric
{:eventName "user-journey"
:platform platform-os
:appVersion app-version
:eventValue {:action tracking/app-started-event}}}
(tracking/tracked-event [:profile/get-profiles-overview-success])))
(is (= (tracking/track-view-id-event :wallet-stack)
(is (= {:metric
{:eventName "events.metrics-enabled"
:platform platform-os
:appVersion app-version
:eventValue {:enabled true}}}
(tracking/tracked-event [:centralized-metrics/toggle-centralized-metrics true])))
(is (= {:metric
{:eventName "navigation"
:platform platform-os
:appVersion app-version
:eventValue {:viewId "wallet-stack"}}}
(tracking/tracked-event [:set-view-id :wallet-stack])))
(is (nil? (tracking/tracked-event [:unknown-event])))))
@@ -6,6 +6,7 @@
[react-native.core :as rn]
[react-native.gesture :as gesture]
[react-native.safe-area :as safe-area]
[reagent.core :as reagent]
[status-im.common.contact-list-item.view :as contact-list-item]
[status-im.common.contact-list.view :as contact-list]
[status-im.common.home.actions.view :as actions]
@@ -27,28 +28,26 @@
(defn add-member-contact-item-render
[{:keys [public-key] :as item} _ _ {:keys [group admin? current-pk]}]
(let [{:keys [contacts]} group
member? (contains? contacts public-key)
selected? (or member? (rf/sub [:contacts/is-participant-selected? public-key]))
[checked? set-checked] (rn/use-state selected?)
disabled? (or (= current-pk public-key) (and (not admin?) member?))]
(let [on-toggle (fn []
(set-checked (not checked?))
(group-chat-member-toggle member? (not checked?) public-key))]
(if disabled?
(let [{:keys [contacts]} group
member? (contains? contacts public-key)
checked? (reagent/atom member?)]
(if (or (= current-pk public-key) (and (not admin?) member?))
(fn []
[contact-list-item/contact-list-item
{:disabled? true
:accessory {:disabled? true
:type :checkbox
:checked? checked?}}
item]
[contact-list-item/contact-list-item
{:disabled? (or disabled? (and admin? member?))
:on-press (when-not disabled? on-toggle)
:accessory {:type :checkbox
:checked? checked?
:on-check on-toggle}}
item]))))
:checked? @checked?}}
item])
(fn []
(let [on-toggle #(group-chat-member-toggle member? (swap! checked? not) public-key)]
[contact-list-item/contact-list-item
{:on-press on-toggle
:allow-multiple-presses? true
:accessory {:type :checkbox
:checked? @checked?
:on-check on-toggle}}
item])))))
(defn add-manage-members
[{:keys [scroll-enabled? on-scroll]}]
@@ -145,10 +144,7 @@
{:content (fn [] [actions/group-details-actions
group])}])}]
:icon-name :i/arrow-left
:on-press (fn []
(rf/dispatch [:group/clear-added-participants])
(rf/dispatch [:group/clear-removed-members])
(rf/dispatch [:navigate-back]))}]
:on-press #(rf/dispatch [:navigate-back])}]
[quo/page-top
{:title chat-name
:avatar {:group? true
+2 -1
View File
@@ -118,7 +118,8 @@
(defn- banner-data
[profile-link]
{:title-props
{:label (i18n/label :t/messages)
{:beta? true
:label (i18n/label :t/messages)
:handler #(rf/dispatch
[:show-bottom-sheet {:content chat.actions.view/new-chat}])
:accessibility-label :new-chat-button}
@@ -64,7 +64,8 @@
(def ^:private banner-data
{:title-props
{:label (i18n/label :t/communities)
{:beta? true
:label (i18n/label :t/communities)
:handler (when config/fast-create-community-enabled?
#(rf/dispatch [:show-bottom-sheet {:content actions.home-plus/view}]))
:accessibility-label :new-communities-button}
+1 -2
View File
@@ -66,8 +66,7 @@
:network/on-network-type-change
(fn [{:keys [db]} [network-type expensive?]]
{:db (assoc db :network/type network-type)
:fx [[:effects.network/notify-status-go network-type expensive?]
[:dispatch [:network/on-network-status-change]]]}))
:fx [[:effects.network/notify-status-go network-type expensive?]]}))
(rf/reg-event-fx
:network/on-network-status-change
@@ -7,16 +7,21 @@
:justify-content :flex-end})
(def text-container
{:text-align :center
:margin-top 4
:flex-wrap :wrap})
{:flex 1
:flex-direction :row
:flex-wrap :wrap
:align-self :center})
(def terms-privacy-container
{:gap 8
:padding-horizontal 20
:padding-vertical 8})
(def plain-text
{:color colors/white-opa-70})
(def highlighted-text
{:flex 1
:color colors/white})
{:color colors/white})
(defn bottom-actions-container
[bottom-insets]
@@ -6,45 +6,73 @@
[status-im.contexts.onboarding.common.background.view :as background]
[status-im.contexts.onboarding.common.overlay.view :as overlay]
[status-im.contexts.onboarding.intro.style :as style]
[status-im.contexts.onboarding.privacy.view :as privacy]
[status-im.contexts.onboarding.terms.view :as terms]
[utils.i18n :as i18n]
[utils.re-frame :as rf]))
(defn view
[]
[rn/view {:style style/page-container}
[background/view false]
[quo/bottom-actions
{:container-style (style/bottom-actions-container (safe-area/get-bottom))
:actions :two-vertical-actions
:description :bottom
:description-text [quo/text
{:style style/text-container
:size :paragraph-2
:weight :regular}
[quo/text {:style style/plain-text}
(i18n/label :t/by-continuing-you-accept)]
[quo/text
{:on-press #(rf/dispatch [:show-bottom-sheet
{:content (fn [] [terms/terms-of-use])
:shell? true}])
:style style/highlighted-text}
(i18n/label :t/terms-of-service)]]
:button-one-label (i18n/label :t/sync-or-recover-profile)
:button-one-props {:type :dark-grey
:accessibility-label :already-use-status-button
:on-press (fn []
(when-let [blur-show-fn @overlay/blur-show-fn-atom]
(blur-show-fn))
(rf/dispatch
[:open-modal
:screen/onboarding.sync-or-recover-profile]))}
:button-two-label (i18n/label :t/create-profile)
:button-two-props {:accessibility-label :new-to-status-button
:on-press
(fn []
(when-let [blur-show-fn @overlay/blur-show-fn-atom]
(blur-show-fn))
(rf/dispatch
[:open-modal :screen/onboarding.new-to-status]))}}]
[overlay/view]])
(let [[terms-accepted? set-terms-accepted?] (rn/use-state false)]
[rn/view {:style style/page-container}
[background/view false]
[quo/bottom-actions
{:container-style (style/bottom-actions-container (safe-area/get-bottom))
:actions :two-vertical-actions
:description :top
:description-top-text [rn/view
{:style style/terms-privacy-container
:flex-direction :row}
[rn/view
{:accessibility-label :terms-privacy-checkbox-container}
[quo/selectors
{:type :checkbox
:blur? true
:checked? terms-accepted?
:on-change #(set-terms-accepted? not)}]]
[rn/view {:style {:flex 1}}
[rn/view {:style style/text-container}
[quo/text
{:style style/plain-text
:size :paragraph-2}
(str (i18n/label :t/accept-status-tos-prefix) " ")]
[quo/text
{:on-press #(rf/dispatch [:show-bottom-sheet
{:content (fn [] [terms/terms-of-use])
:shell? true}])
:style style/highlighted-text
:size :paragraph-2
:weight :medium}
(i18n/label :t/terms-of-service)]
[quo/text
{:style style/plain-text
:size :paragraph-2}
" & "]
[quo/text
{:on-press #(rf/dispatch [:show-bottom-sheet
{:content (fn [] [privacy/privacy-statement])
:shell? true}])
:style style/highlighted-text
:size :paragraph-2
:weight :medium}
(i18n/label :t/intro-privacy-statement)]]]]
:button-one-label (i18n/label :t/sync-or-recover-profile)
:button-one-props {:type :dark-grey
:disabled? (not terms-accepted?)
:accessibility-label :already-use-status-button
:on-press (fn []
(when-let [blur-show-fn @overlay/blur-show-fn-atom]
(blur-show-fn))
(rf/dispatch
[:open-modal
:screen/onboarding.sync-or-recover-profile]))}
:button-two-label (i18n/label :t/create-profile)
:button-two-props {:accessibility-label :new-to-status-button
:disabled? (not terms-accepted?)
:on-press
(fn []
(when-let [blur-show-fn @overlay/blur-show-fn-atom]
(blur-show-fn))
(rf/dispatch
[:open-modal :screen/onboarding.new-to-status]))}}]
[overlay/view]]))
@@ -0,0 +1,11 @@
(ns status-im.contexts.onboarding.privacy.view
(:require-macros [legacy.status-im.utils.slurp :refer [slurp]])
(:require [quo.core :as quo]
[react-native.gesture :as gesture]))
(def privacy-statement-text (slurp "resources/privacy.mdwn"))
(defn privacy-statement
[]
[gesture/scroll-view {:margin 20}
[quo/text privacy-statement-text]])
@@ -19,10 +19,10 @@
:icon-name :i/close
:right-side [{:icon-name (if light? :i/dark :i/light)
:on-press #(if light?
(rf/dispatch [:theme/switch :dark])
(rf/dispatch [:theme/switch :light]))}]
(rf/dispatch [:theme/switch {:theme :dark}])
(rf/dispatch [:theme/switch {:theme :light}]))}]
:on-press #(if (or logged-in? (not= (rf/sub [:view-id]) :quo-preview))
(rf/dispatch [:navigate-back])
(do
(rf/dispatch [:theme/switch :dark])
(rf/dispatch [:theme/switch {:theme :dark}])
(rf/dispatch [:init-root root])))}]))
@@ -50,7 +50,7 @@
(fn []
(rn/use-effect (fn []
(when @blur?
(rf/dispatch [:theme/switch :dark])))
(rf/dispatch [:theme/switch {:theme :dark}])))
[@blur?])
[preview/preview-container {:state state :descriptor descriptor}
[rn/view
@@ -377,8 +377,8 @@
(rn/use-effect (fn []
(when blur-dark-only?
(if blur?
(rf/dispatch [:theme/switch :dark])
(rf/dispatch [:theme/switch :light]))))
(rf/dispatch [:theme/switch {:theme :dark}])
(rf/dispatch [:theme/switch {:theme :light}]))))
[blur? blur-dark-only?])
[rn/view
{:style {:top (safe-area/get-top)
+21 -15
View File
@@ -9,21 +9,27 @@
(defn login
[]
{;; Temporary fix until https://github.com/status-im/status-go/issues/3024 is resolved
:wakuV2Nameserver "8.8.8.8"
:openseaAPIKey config/opensea-api-key
:poktToken config/POKT_TOKEN
:infuraToken config/INFURA_TOKEN
:raribleMainnetAPIKey config/RARIBLE_MAINNET_API_KEY
:raribleTestnetAPIKey config/RARIBLE_TESTNET_API_KEY
:alchemyEthereumMainnetToken config/ALCHEMY_ETHEREUM_MAINNET_TOKEN
:alchemyEthereumGoerliToken config/ALCHEMY_ETHEREUM_GOERLI_TOKEN
:alchemyEthereumSepoliaToken config/ALCHEMY_ETHEREUM_SEPOLIA_TOKEN
:alchemyOptimismMainnetToken config/ALCHEMY_OPTIMISM_MAINNET_TOKEN
:alchemyOptimismGoerliToken config/ALCHEMY_OPTIMISM_GOERLI_TOKEN
:alchemyOptimismSepoliaToken config/ALCHEMY_OPTIMISM_SEPOLIA_TOKEN
:alchemyArbitrumMainnetToken config/ALCHEMY_ARBITRUM_MAINNET_TOKEN
:alchemyArbitrumGoerliToken config/ALCHEMY_ARBITRUM_GOERLI_TOKEN
:alchemyArbitrumSepoliaToken config/ALCHEMY_ARBITRUM_SEPOLIA_TOKEN})
:wakuV2Nameserver "8.8.8.8"
:statusProxyEnabled config/status-proxy-enabled?
:statusProxyStageName config/status-proxy-stage-name
:statusProxyMarketUser "test"
:statusProxyMarketPassword "test"
:statusProxyBlockchainUser "test"
:statusProxyBlockchainPassword "test"
:openseaAPIKey config/opensea-api-key
:poktToken config/POKT_TOKEN
:infuraToken config/INFURA_TOKEN
:raribleMainnetAPIKey config/RARIBLE_MAINNET_API_KEY
:raribleTestnetAPIKey config/RARIBLE_TESTNET_API_KEY
:alchemyEthereumMainnetToken config/ALCHEMY_ETHEREUM_MAINNET_TOKEN
:alchemyEthereumGoerliToken config/ALCHEMY_ETHEREUM_GOERLI_TOKEN
:alchemyEthereumSepoliaToken config/ALCHEMY_ETHEREUM_SEPOLIA_TOKEN
:alchemyOptimismMainnetToken config/ALCHEMY_OPTIMISM_MAINNET_TOKEN
:alchemyOptimismGoerliToken config/ALCHEMY_OPTIMISM_GOERLI_TOKEN
:alchemyOptimismSepoliaToken config/ALCHEMY_OPTIMISM_SEPOLIA_TOKEN
:alchemyArbitrumMainnetToken config/ALCHEMY_ARBITRUM_MAINNET_TOKEN
:alchemyArbitrumGoerliToken config/ALCHEMY_ARBITRUM_GOERLI_TOKEN
:alchemyArbitrumSepoliaToken config/ALCHEMY_ARBITRUM_SEPOLIA_TOKEN})
(defn create
[]
+1 -1
View File
@@ -54,7 +54,7 @@
(update :profile/login #(select-profile % key-uid)))
db-with-settings)
:fx [[:dispatch [:init-root :screen/profile.profiles]]
(when key-uid
(when (and key-uid userConfirmed)
[:effects.biometric/check-if-available
{:key-uid key-uid
:on-success (fn [auth-method]
@@ -4,7 +4,6 @@
[native-module.core :as native-module]
[status-im.common.keychain.events :as keychain]
[status-im.config :as config]
[status-im.constants :as constants]
status-im.contexts.profile.login.effects
[status-im.contexts.profile.rpc :as profile.rpc]
[status-im.feature-flags :as ff]
@@ -80,11 +79,7 @@
[[:dispatch [:onboarding/finalize-setup]]]
:else
[[:profile.settings/switch-theme-fx
[(or (:appearance settings)
constants/theme-type-dark)
:shell-stack]]
[:dispatch [:init-root :shell-stack]]
[[:dispatch [:init-root :shell-stack]]
[:dispatch [:profile/show-testnet-mode-banner-if-enabled]]]))})))
;; login phase 2: we want to load and show chats faster, so we split login into 2 phases
@@ -1,10 +1,7 @@
(ns status-im.contexts.profile.settings.effects
(:require [native-module.core :as native-module]
[re-frame.core :as re-frame]
[react-native.platform :as platform]
[status-im.common.theme.core :as theme]
[status-im.constants :as constants]
[utils.re-frame :as rf]))
[react-native.platform :as platform]))
(re-frame/reg-fx
:profile.settings/blank-preview-flag-changed
@@ -16,15 +13,3 @@
(fn [value]
(when platform/android?
(native-module/toggle-webview-debug value))))
(re-frame/reg-fx
:profile.settings/switch-theme-fx
(fn [[theme-type view-id]]
(let [theme (if (or (= theme-type constants/theme-type-dark)
(and (= theme-type constants/theme-type-system)
(theme/device-theme-dark?)))
:dark
:light)]
(theme/set-legacy-theme theme)
(rf/dispatch [:theme/switch theme])
(rf/dispatch [:reload-status-nav-color view-id]))))
@@ -95,14 +95,7 @@
(rf/reg-event-fx :profile.settings/change-appearance
(fn [_ [theme]]
{:fx [[:dispatch [:profile.settings/profile-update :appearance theme]]
[:profile.settings/switch-theme-fx [theme :appearance]]]}))
(rf/reg-event-fx :profile.settings/switch-theme
(fn [{:keys [db]} [theme view-id]]
(let [theme (or theme
(get-in db [:profile/profile :appearance])
constants/theme-type-dark)]
{:fx [[:profile.settings/switch-theme-fx [theme view-id]]]})))
[:dispatch [:theme/switch {:theme-type theme}]]]}))
(rf/reg-fx :profile.settings/get-profile-picture
(fn [key-uid]
@@ -1,33 +1,47 @@
(ns status-im.contexts.shell.qr-reader.sheets.scanned-wallet-address
(:require
[quo.core :as quo]
[status-im.contexts.wallet.common.utils :as utils]
[status-im.contexts.wallet.common.utils.networks :as network-utils]
[react-native.clipboard :as clipboard]
[status-im.feature-flags :as ff]
[utils.i18n :as i18n]
[utils.re-frame :as rf]))
(defn- copy-address
[address]
(clipboard/set-string address)
(rf/dispatch [:toasts/upsert
{:type :positive
:text (i18n/label :t/address-copied)}]))
#_(defn- send-to-address
[address]
(let [[_ split-address] (network-utils/split-network-full-address address)]
(rf/dispatch
[:wallet/select-send-address
{:address address
:recipient {:recipient-type :address
:label (utils/get-shortened-address split-address)}
:stack-id :wallet-select-address
:start-flow? true}])))
(defn view
[address]
(let [[_ splitted-address] (network-utils/split-network-full-address address)]
[:<>
[quo/drawer-top
{:title address
:type :address}]
[quo/action-drawer
[[{:icon :i/send
[:<>
[quo/drawer-top {:title address :type :address}]
[quo/action-drawer
[[{:icon :i/copy
:accessibility-label :send-asset
:label (i18n/label :t/copy-address)
:on-press #(copy-address address)}
;; Originally, the flow went to the send flow, but it has been removed to avoid bugs,
;; please check https://github.com/status-im/status-mobile/issues/20972 for more context
;; The previous code has been commented out to be reintroduced in the future easily.
#_{:icon :i/send
:accessibility-label :send-asset
:label (i18n/label :t/send-to-this-address)
:on-press (fn []
(rf/dispatch [:wallet/select-send-address
{:address address
:recipient {:recipient-type :address
:label (utils/get-shortened-address
splitted-address)}
:stack-id :wallet-select-address
:start-flow? true}]))}
(when (ff/enabled? :ff/wallet.saved-addresses)
{:icon :i/save
:accessibility-label :save-address
:label (i18n/label :t/save-address)
:on-press #(js/alert "feature not implemented")})]]]]))
:on-press #(send-to-address address)}
(when (ff/enabled? :ff/wallet.saved-addresses)
{:icon :i/save
:accessibility-label :save-address
:label (i18n/label :t/save-address)
:on-press #(js/alert "feature not implemented")})]]]])
+1 -1
View File
@@ -34,7 +34,7 @@
:WakuV2Config {;; Temporary fix until https://github.com/status-im/status-go/issues/3024
;; is resolved
:Nameserver "8.8.8.8"
:LightClient false}
:LightClient true}
:ShhextConfig {:VerifyTransactionURL config/verify-transaction-url
:VerifyENSURL config/verify-ens-url
:VerifyENSContractAddress config/verify-ens-contract-address
@@ -6,11 +6,12 @@
(defn collectible-balance
[collectible]
(-> collectible
:ownership
first
:balance
js/parseInt))
(let [balance (-> collectible
:ownership
first
:balance
js/parseInt)]
(if (js/Number.isNaN balance) 0 balance)))
(def supported-collectible-types
#{"image/jpeg"
@@ -5,6 +5,7 @@
[status-im.contexts.wallet.sheets.buy-token.view :as buy-token]
[status-im.feature-flags :as ff]
[utils.i18n :as i18n]
[utils.money :as money]
[utils.re-frame :as rf]))
(defn- action-buy
@@ -21,6 +22,7 @@
{:icon :i/send
:accessibility-label :send
:label (i18n/label :t/send)
:disabled? (:disabled? send-params)
:on-press (fn []
(rf/dispatch [:hide-bottom-sheet])
(rf/dispatch [:wallet/clean-send-data])
@@ -69,31 +71,35 @@
(defn token-value-drawer
[token watch-only? entry-point]
(let [token-symbol (:token token)
token-data (first (rf/sub [:wallet/current-viewing-account-tokens-filtered
token-symbol]))
selected-account? (rf/sub [:wallet/current-viewing-account-address])
token-owners (rf/sub [:wallet/operable-addresses-with-token-symbol token-symbol])
send-params (if selected-account?
{:token token-data
:stack-id :screen/wallet.accounts
:start-flow? true
:owners token-owners}
{:token-symbol token-symbol
:stack-id :wallet-stack
:start-flow? true
:owners token-owners})
bridge-params (if selected-account?
{:token token-data
:bridge-disabled? (send-utils/bridge-disabled? token-symbol)
:stack-id :screen/wallet.accounts
:start-flow? true
:owners token-owners}
{:token-symbol token-symbol
:bridge-disabled? (send-utils/bridge-disabled? token-symbol)
:stack-id :wallet-stack
:start-flow? true
:owners token-owners})]
(let [token-symbol (:token token)
token-data (first (rf/sub [:wallet/current-viewing-account-tokens-filtered
token-symbol]))
fiat-unformatted-value (get-in token [:values :fiat-unformatted-value])
has-balance? (money/greater-than fiat-unformatted-value (money/bignumber "0"))
selected-account? (rf/sub [:wallet/current-viewing-account-address])
token-owners (rf/sub [:wallet/operable-addresses-with-token-symbol token-symbol])
send-params (if selected-account?
{:token token-data
:stack-id :screen/wallet.accounts
:disabled? (not has-balance?)
:start-flow? true
:owners token-owners}
{:token-symbol token-symbol
:stack-id :wallet-stack
:start-flow? true
:owners token-owners})
bridge-params (if selected-account?
{:token token-data
:bridge-disabled? (or (not has-balance?)
(send-utils/bridge-disabled? token-symbol))
:stack-id :screen/wallet.accounts
:start-flow? true
:owners token-owners}
{:token-symbol token-symbol
:bridge-disabled? (send-utils/bridge-disabled? token-symbol)
:stack-id :wallet-stack
:start-flow? true
:owners token-owners})]
[quo/action-drawer
[(cond->> [(when (ff/enabled? ::ff/wallet.assets-modal-manage-tokens)
(action-manage-tokens watch-only?))
+15 -10
View File
@@ -7,6 +7,7 @@
[utils.number :as number]
[utils.string]))
(def missing-price-decimals 6) ; if we don't have the monetary value of the token, we default to 6 decimals
(defn get-first-name
[full-name]
(first (string/split full-name #" ")))
@@ -66,16 +67,20 @@
(defn get-standard-crypto-format
"For full details: https://github.com/status-im/status-mobile/issues/18225"
[{:keys [market-values-per-currency]} token-units]
(if (or (nil? token-units)
(nil? market-values-per-currency)
(money/equal-to token-units 0))
"0"
(let [price (-> market-values-per-currency :usd :price)
one-cent-value (if (pos? price) (/ 0.01 price) 0)
decimals-count (calc-max-crypto-decimals one-cent-value)]
(if (< token-units one-cent-value)
(str "<" (number/remove-trailing-zeroes (.toFixed one-cent-value decimals-count)))
(number/remove-trailing-zeroes (.toFixed token-units decimals-count))))))
(cond (or (nil? token-units)
(money/equal-to token-units 0))
"0"
(nil? (-> market-values-per-currency :usd :price))
(number/remove-trailing-zeroes (.toFixed token-units missing-price-decimals))
:else
(let [price (-> market-values-per-currency :usd :price)
one-cent-value (if (pos? price) (/ 0.01 price) 0)
decimals-count (calc-max-crypto-decimals one-cent-value)]
(if (< token-units one-cent-value)
(str "<" (number/remove-trailing-zeroes (.toFixed one-cent-value decimals-count)))
(number/remove-trailing-zeroes (.toFixed token-units decimals-count))))))
(defn get-market-value
[currency {:keys [market-values-per-currency]}]
@@ -64,6 +64,11 @@
(is (= (utils/get-standard-crypto-format {:market-values-per-currency market-values-per-currency}
token-units)
"0.005")))
(let [market-values-per-currency {:usd {:price nil}}
token-units (money/bignumber 0.0123456)]
(is (= (utils/get-standard-crypto-format {:market-values-per-currency market-values-per-currency}
token-units)
"0.012346")))
(let [market-values-per-currency {:usd {:price 0.005}}
token-units (money/bignumber 0.01)]
(is (= (utils/get-standard-crypto-format {:market-values-per-currency market-values-per-currency}
@@ -213,8 +213,7 @@
[new-path]
(let [bonder-fees (:tx-bonder-fees new-path)
token-fees (+ (money/wei->ether bonder-fees)
(money/wei->ether
(:tx-token-fees new-path)))]
(money/wei->ether (:tx-token-fees new-path)))]
{:from (:from-chain new-path)
:amount-in-locked (:amount-in-locked new-path)
:amount-in (:amount-in new-path)
+9 -11
View File
@@ -274,7 +274,7 @@
(rf/reg-event-fx :wallet/get-keypairs get-keypairs)
(rf/reg-event-fx :wallet/bridge-select-token
(fn [{:keys [db]} [{:keys [token token-symbol stack-id]}]]
(fn [{:keys [db]} [{:keys [token token-symbol stack-id start-flow?]}]]
(let [missing-recipient? (-> db :wallet :ui :send :to-address nil?)
to-address (-> db :wallet :current-viewing-account-address)]
{:db (cond-> db
@@ -285,7 +285,7 @@
:fx [[:dispatch
[:wallet/wizard-navigate-forward
{:current-screen stack-id
:start-flow? true
:start-flow? start-flow?
:flow-id :wallet-bridge-flow}]]]})))
(rf/reg-event-fx :wallet/start-bridge
@@ -296,7 +296,6 @@
{:start-flow? true
:flow-id :wallet-bridge-flow}]]]}))
(rf/reg-event-fx :wallet/select-bridge-network
(fn [{:keys [db]} [{:keys [network-chain-id stack-id]}]]
{:db (assoc-in db [:wallet :ui :send :bridge-to-chain-id] network-chain-id)
@@ -497,16 +496,15 @@
(string/join ", ")))]
(when (seq down-chain-ids)
(log/info "[wallet] Chain(s) down: " down-chain-ids)
(log/info "[wallet] Chain name(s) down: " chain-names)
(log/info "[wallet] Test network enabled: " (boolean test-networks-enabled?))
(log/info "[wallet] Goerli network enabled: " (boolean is-goerli-enabled?)))
{:db (assoc-in db [:wallet :statuses :blockchains] chains)
:fx [(when chains-down?
[:dispatch
[:toasts/upsert
{:id :chains-down
:type :negative
:text (i18n/label :t/provider-is-down {:chains chain-names})
:duration constants/toast-chain-down-duration}]])]})))
;; NOTE <shivekkhurana>: We used to show an error toast, but disabled it because the down
;; signal is sent randomly. Needs to be investigated and enabled again !
;; Context: https://github.com/status-im/status-mobile/issues/21054
{:db (assoc-in db [:wallet :statuses :blockchains] chains)})))
(rf/reg-event-fx :wallet/reset-selected-networks
(fn [{:keys [db]}]
+7 -6
View File
@@ -21,12 +21,13 @@
:label (i18n/label :t/add-account)
:sub-label (i18n/label :t/add-account-description)
:on-press #(rf/dispatch [:navigate-to :screen/wallet.create-account])}
{:icon :i/reveal
:accessibility-label :add-a-contact
:label (i18n/label :t/add-address-to-watch)
:sub-label (i18n/label :t/add-address-to-watch-description)
:on-press #(rf/dispatch [:navigate-to :screen/wallet.add-address-to-watch])
:add-divider? true}]]])
(when (ff/enabled? ::ff/wallet.add-watched-address)
{:icon :i/reveal
:accessibility-label :add-a-contact
:label (i18n/label :t/add-address-to-watch)
:sub-label (i18n/label :t/add-address-to-watch-description)
:on-press #(rf/dispatch [:navigate-to :screen/wallet.add-address-to-watch])
:add-divider? true})]]])
(defn- new-account-card-data
[]
+119 -58
View File
@@ -10,6 +10,7 @@
[status-im.contexts.wallet.send.utils :as send-utils]
[taoensso.timbre :as log]
[utils.address :as address]
[utils.hex :as utils.hex]
[utils.money :as money]
[utils.number]
[utils.re-frame :as rf]))
@@ -76,11 +77,11 @@
:token-networks-ids token-networks-ids
:tx-type tx-type
:receiver? true})
(->
(cond->
(send-utils/reset-loading-network-amounts-to-zero
receiver-network-values)
vec
(conj {:type :edit})))
(not= tx-type :tx/bridge) (conj {:type :edit})))
network-links (when routes-available?
(send-utils/network-links chosen-route
sender-network-values
@@ -104,9 +105,7 @@
cleaned-receiver-network-values (-> (get-in db [:wallet :ui :send :receiver-network-values])
(send-utils/reset-loading-network-amounts-to-zero))]
{:db (-> db
(update-in [:wallet :ui :send]
dissoc
:route)
(update-in [:wallet :ui :send] dissoc :route)
(assoc-in [:wallet :ui :send :sender-network-values] cleaned-sender-network-values)
(assoc-in [:wallet :ui :send :receiver-network-values] cleaned-receiver-network-values)
(assoc-in [:wallet :ui :send :loading-suggested-routes?] false)
@@ -206,7 +205,7 @@
{:db (cond-> db
:always (update-in [:wallet :ui :send]
#(-> %
(dissoc :collectible)
(dissoc :collectible :tx-type)
(assoc :token-not-supported-in-receiver-networks?
unsupported-token?)))
token-symbol (assoc-in [:wallet :ui :send :token-symbol] token-symbol)
@@ -218,6 +217,11 @@
entry-point (assoc-in [:wallet :ui :send :entry-point] entry-point))
:fx [[:dispatch [:wallet/clean-suggested-routes]]
[:dispatch
;; ^:flush-dom allows us to make sure the re-frame DB state is always synced
;; before the navigation occurs, so the new screen is always rendered with
;; the DB state set by this event. By adding the metadata we are omitting
;; a 1-frame blink when the screen is mounted.
^:flush-dom
[:wallet/wizard-navigate-forward
{:current-screen stack-id
:start-flow? start-flow?
@@ -402,11 +406,11 @@
receiver-networks)))
network-chain-ids))
from-locked-amount (update-vals from-locked-amounts to-hex)
transaction-type (case tx-type
:tx/collectible-erc-721 constants/send-type-erc-721-transfer
:tx/collectible-erc-1155 constants/send-type-erc-1155-transfer
:tx/bridge constants/send-type-bridge
constants/send-type-transfer)
send-type (case tx-type
:tx/collectible-erc-721 constants/send-type-erc-721-transfer
:tx/collectible-erc-1155 constants/send-type-erc-1155-transfer
:tx/bridge constants/send-type-bridge
constants/send-type-transfer)
balances-per-chain (when token (:balances-per-chain token))
sender-token-available-networks-for-suggested-routes
(when token
@@ -447,7 +451,7 @@
:tx-type tx-type
:receiver? true}))
params [{:uuid (str (random-uuid))
:sendType transaction-type
:sendType send-type
:addrFrom from-address
:addrTo to-address
:amountIn amount-in
@@ -490,24 +494,48 @@
{:event :wallet/stop-get-suggested-routes
:error error}))}]}))
(rf/reg-event-fx :wallet/handle-suggested-routes
(defn- bridge-amount-greater-than-bonder-fees?
[{{token-decimals :decimals} :from-token
bonder-fees :tx-bonder-fees
amount-in :amount-in}]
(let [bonder-fees (utils.money/token->unit bonder-fees token-decimals)
amount-to-bridge (utils.money/token->unit amount-in token-decimals)]
(> amount-to-bridge bonder-fees)))
(defn- remove-multichain-routes
[routes]
(if (> (count routes) 1)
[] ;; if route is multichain, we remove it
routes))
(defn- remove-invalid-bonder-fees-routes
[routes]
(filter bridge-amount-greater-than-bonder-fees? routes))
(defn- ->old-route-paths
[routes]
(map data-store/new->old-route-path routes))
(rf/reg-event-fx
:wallet/handle-suggested-routes
(fn [_ data]
(if-let [error (some-> data
first
:ErrorResponse
(#(if (= (:code %) "0") "An error occurred" (:details %))))]
(do
(if-let [{:keys [code details]} (-> data :ErrorResponse first)]
(let [error-message (if (= code "0") "An error occurred" details)]
(log/error "failed to get suggested routes (async)"
{:event :wallet/handle-suggested-routes
:error error})
{:fx [[:dispatch [:wallet/suggested-routes-error error]]]})
(let [suggested-routes-new-data (data-store/rpc->suggested-routes data)
suggested-routes (-> suggested-routes-new-data
first
(update :best #(map data-store/new->old-route-path %))
(update :candidates #(map data-store/new->old-route-path %)))]
{:fx [[:dispatch
[:wallet/suggested-routes-success suggested-routes]]]}))))
:error error-message})
{:fx [[:dispatch [:wallet/suggested-routes-error error-message]]]})
(let [best-routes-fix (comp ->old-route-paths
remove-invalid-bonder-fees-routes
remove-multichain-routes)
candidates-fix (comp ->old-route-paths
remove-invalid-bonder-fees-routes)
routes (-> data
(first)
(data-store/rpc->suggested-routes)
(update :best best-routes-fix)
(update :candidates candidates-fix))]
{:fx [[:dispatch [:wallet/suggested-routes-success routes]]]}))))
(rf/reg-event-fx :wallet/add-authorized-transaction
(fn [{:keys [db]} [transaction]]
@@ -581,6 +609,29 @@
:gwei
gas-price))))))
(defn- approval-path
[{:keys [route from-address to-address token-address]}]
(let [{:keys [from]} route
from-chain-id (:chain-id from)
approval-amount-required (:approval-amount-required route)
approval-amount-required-sanitized (-> approval-amount-required
(utils.hex/normalize-hex)
(native-module/hex-to-number))
approval-contract-address (:approval-contract-address route)
data (native-module/encode-function-call
constants/contract-function-signature-erc20-approve
[approval-contract-address
approval-amount-required-sanitized])
tx-data (transaction-data {:from-address from-address
:to-address to-address
:token-address token-address
:route route
:data data
:eth-transfer? false})]
{:BridgeName constants/bridge-name-transfer
:ChainID from-chain-id
:TransferTx tx-data}))
(defn- transaction-path
[{:keys [from-address to-address token-id token-address route data eth-transfer?]}]
(let [{:keys [bridge-name amount-in bonder-fees from
@@ -617,7 +668,8 @@
(= bridge-name constants/bridge-name-hop)
(assoc :HopTx
(assoc tx-data
:ChainID to-chain-id
:ChainID from-chain-id
:ChainIDTo to-chain-id
:Symbol token-id
:Recipient to-address
:Amount amount-in
@@ -634,14 +686,14 @@
:Amount amount-in)))))
(defn- multi-transaction-command
[{:keys [from-address to-address from-asset to-asset amount-out transfer-type]
:or {transfer-type constants/send-type-transfer}}]
[{:keys [from-address to-address from-asset to-asset amount-out multi-transaction-type]
:or {multi-transaction-type constants/multi-transaction-type-unknown}}]
{:fromAddress from-address
:toAddress to-address
:fromAsset from-asset
:toAsset to-asset
:fromAmount amount-out
:type transfer-type})
:type multi-transaction-type})
(rf/reg-event-fx :wallet/send-transaction
(fn [{:keys [db]} [sha3-pwd]]
@@ -649,11 +701,9 @@
first-route (first routes)
from-address (get-in db [:wallet :current-viewing-account-address])
transaction-type (get-in db [:wallet :ui :send :tx-type])
transaction-type-param (case transaction-type
:tx/collectible-erc-721 constants/send-type-erc-721-transfer
:tx/collectible-erc-1155 constants/send-type-erc-1155-transfer
:tx/bridge constants/send-type-bridge
constants/send-type-transfer)
multi-transaction-type (if (= :tx/bridge transaction-type)
constants/multi-transaction-type-bridge
constants/multi-transaction-type-send)
token (get-in db [:wallet :ui :send :token])
collectible (get-in db [:wallet :ui :send :collectible])
first-route-from-chain-id (get-in first-route [:from :chain-id])
@@ -668,30 +718,41 @@
erc20-transfer?
(get-in token [:balances-per-chain first-route-from-chain-id :address]))
to-address (get-in db [:wallet :ui :send :to-address])
transaction-paths (mapv (fn [route]
(let [data (when erc20-transfer?
(native-module/encode-transfer
(address/normalized-hex to-address)
(:amount-in route)))]
(transaction-path {:to-address to-address
:from-address from-address
:route route
:token-address token-address
:token-id (if collectible
(money/to-hex (js/parseInt
token-id))
token-id)
:data data
:eth-transfer? eth-transfer?})))
transaction-paths (into []
(mapcat
(fn [route]
(let [approval-required? (:approval-required route)
data (when erc20-transfer?
(native-module/encode-transfer
(address/normalized-hex to-address)
(:amount-in route)))
base-path (transaction-path
{:to-address to-address
:from-address from-address
:route route
:token-address token-address
:token-id (if collectible
(money/to-hex
(js/parseInt token-id))
token-id)
:data data
:eth-transfer? eth-transfer?})]
(if approval-required?
[(approval-path {:route route
:token-address token-address
:from-address from-address
:to-address to-address})
base-path]
[base-path]))))
routes)
request-params
[(multi-transaction-command
{:from-address from-address
:to-address to-address
:from-asset token-id
:to-asset token-id
:amount-out (if eth-transfer? (:amount-out first-route) "0x0")
:transfer-type transaction-type-param})
{:from-address from-address
:to-address to-address
:from-asset token-id
:to-asset token-id
:amount-out (if eth-transfer? (:amount-out first-route) "0x0")
:multi-transaction-type multi-transaction-type})
transaction-paths
sha3-pwd]]
(log/info "multi transaction called")
@@ -1,6 +1,7 @@
(ns status-im.contexts.wallet.send.events-test
(:require
[cljs.test :refer-macros [is testing]]
[cljs.test :refer-macros [is testing run-tests]]
matcher-combinators.test
[re-frame.db :as rf-db]
[status-im.contexts.wallet.common.utils.networks :as network-utils]
status-im.contexts.wallet.send.events
@@ -14,7 +15,10 @@
:description
"dogs are cute and this one is the cutestdogs are cute and this one is the cutest"
:ownership [{:address "0x01"
:balance balance}]})
:balance balance}]
:id {:contract-id {:address "0x11"
:chain-id 1}
:token-id "some-id"}})
(h/deftest-event :wallet/update-receiver-networks
[event-id dispatch]
@@ -170,13 +174,14 @@
:networks #{{:chain-id 421614}
{:chain-id 11155420}
{:chain-id 11155111}}}
receiver-networks [421614 11155420]]
receiver-networks [421614 11155420]
expected-db {:wallet {:ui {:other-props :value}}}]
(reset! rf-db/app-db
{:wallet {:ui {:send {:token-display-name token-symbol
:token token
:receiver-networks receiver-networks}
:other-props :value}}})
(is (not (contains? (get-in (dispatch [event-id]) [:db :wallet :ui]) :send)))))
(is (match-strict? expected-db (:db (dispatch [event-id]))))))
(h/deftest-event :wallet/select-address-tab
[event-id dispatch]
@@ -187,38 +192,37 @@
(h/deftest-event :wallet/clean-send-address
[event-id dispatch]
(reset! rf-db/app-db
{:wallet {:ui {:send {:to-address "0x01"
:recipient {:recipient-type :saved-address
:label "label"}
:other-props :value}}}})
(is (not (contains? (get-in (dispatch [event-id]) [:db :wallet :ui :send]) :to-address)))
(is (not (contains? (get-in (dispatch [event-id]) [:db :wallet :ui :send]) :recipient)))
(is (contains? (get-in (dispatch [event-id]) [:db :wallet :ui :send]) :other-props)))
(let [expected-db {:wallet {:ui {:send {:other-props :value}}}}]
(reset! rf-db/app-db
{:wallet {:ui {:send {:to-address "0x01"
:recipient {:recipient-type :saved-address
:label "label"}
:other-props :value}}}})
(is (match-strict? expected-db (:db (dispatch [event-id]))))))
(h/deftest-event :wallet/clean-send-amount
[event-id dispatch]
(reset! rf-db/app-db
{:wallet {:ui {:send {:amount 10
:other-props :value}}}})
(is (not (contains? (get-in (dispatch [event-id]) [:db :wallet :ui :send]) :amount)))
(is (contains? (get-in (dispatch [event-id]) [:db :wallet :ui :send]) :other-props)))
(let [expected-db {:wallet {:ui {:send {:other-props :value}}}}]
(reset! rf-db/app-db
{:wallet {:ui {:send {:amount 10
:other-props :value}}}})
(is (match-strict? expected-db (:db (dispatch [event-id]))))))
(h/deftest-event :wallet/clean-disabled-from-networks
[event-id dispatch]
(reset! rf-db/app-db
{:wallet {:ui {:send {:disabled-from-chain-ids [:optimism]
:other-props :value}}}})
(is (not (contains? (get-in (dispatch [event-id]) [:db :wallet :ui :send]) :disabled-from-chain-ids)))
(is (contains? (get-in (dispatch [event-id]) [:db :wallet :ui :send]) :other-props)))
(let [expected-db {:wallet {:ui {:send {:other-props :value}}}}]
(reset! rf-db/app-db
{:wallet {:ui {:send {:disabled-from-chain-ids [:optimism]
:other-props :value}}}})
(is (match-strict? expected-db (:db (dispatch [event-id]))))))
(h/deftest-event :wallet/clean-from-locked-amounts
[event-id dispatch]
(reset! rf-db/app-db
{:wallet {:ui {:send {:from-locked-amounts "value"
:other-props :value}}}})
(is (not (contains? (get-in (dispatch [event-id]) [:db :wallet :ui :send]) :from-locked-amounts)))
(is (contains? (get-in (dispatch [event-id]) [:db :wallet :ui :send]) :other-props)))
(let [expected-db {:wallet {:ui {:send {:other-props :value}}}}]
(reset! rf-db/app-db
{:wallet {:ui {:send {:from-locked-amounts "value"
:other-props :value}}}})
(is (match-strict? expected-db (:db (dispatch [event-id]))))))
(h/deftest-event :wallet/disable-from-networks
[event-id dispatch]
@@ -247,55 +251,42 @@
(h/deftest-event :wallet/clean-selected-token
[event-id dispatch]
(reset! rf-db/app-db
{:wallet {:ui {:send {:other-props :value
:token "ETH"
:token-display-name "ETH"
:tx-type :tx/collectible-erc-721}}}})
(is (not (contains? (get-in (dispatch [event-id]) [:db :wallet :ui :send]) :token)))
(is (not (contains? (get-in (dispatch [event-id]) [:db :wallet :ui :send]) :token-display-name)))
(is (not (contains? (get-in (dispatch [event-id]) [:db :wallet :ui :send]) :tx-type)))
(is (contains? (get-in (dispatch [event-id]) [:db :wallet :ui :send]) :other-props)))
(let [expected-db {:wallet {:ui {:send {:other-props :value}}}}]
(reset! rf-db/app-db
{:wallet {:ui {:send {:other-props :value
:token "ETH"
:token-display-name "ETH"
:tx-type :tx/collectible-erc-721}}}})
(is (match-strict? expected-db (:db (dispatch [event-id]))))))
(h/deftest-event :wallet/clean-selected-collectible
[event-id dispatch]
(reset! rf-db/app-db
{:wallet {:ui {:send {:other-props :value
:collectible "ETH"
:token-display-name "ETH"
:amount 10}}}})
(is (not (contains? (get-in (dispatch [event-id]) [:db :wallet :ui :send]) :collectible)))
(is (not (contains? (get-in (dispatch [event-id]) [:db :wallet :ui :send]) :token-display-name)))
(is (not (contains? (get-in (dispatch [event-id]) [:db :wallet :ui :send]) :amount)))
(is (contains? (get-in (dispatch [event-id]) [:db :wallet :ui :send]) :other-props)))
(let [expected-db {:wallet {:ui {:send {:other-props :value}}}}]
(reset! rf-db/app-db
{:wallet {:ui {:send {:other-props :value
:collectible "ETH"
:token-display-name "ETH"
:amount 10}}}})
(is (match-strict? expected-db (:db (dispatch [event-id]))))))
(h/deftest-event :wallet/clean-suggested-routes
[event-id dispatch]
(reset! rf-db/app-db
{:wallet {:ui {:send
{:other-props :value
:suggested-routes ["1" "2"]
:route "1"
:amount 10
:from-values-by-chain [{:chain-id 1} {:chain-id 10} {:chain-id 42161}]
:to-values-by-chain [{:chain-id 1} {:chain-id 10} {:chain-id 42161}]
:sender-network-values [:eth :arb1]
:receiver-network-values [:eth :arb1]
:network-links [{:from-chain-id 1
:to-chain-id 10
:position-diff 1}]
:loading-suggested-routes? false}}}})
(is (not (contains? (get-in (dispatch [event-id]) [:db :wallet :ui :send]) :suggested-routes)))
(is (not (contains? (get-in (dispatch [event-id]) [:db :wallet :ui :send]) :route)))
(is (not (contains? (get-in (dispatch [event-id]) [:db :wallet :ui :send]) :amount)))
(is (not (contains? (get-in (dispatch [event-id]) [:db :wallet :ui :send]) :from-values-by-chain)))
(is (not (contains? (get-in (dispatch [event-id]) [:db :wallet :ui :send]) :to-values-by-chain)))
(is (not (contains? (get-in (dispatch [event-id]) [:db :wallet :ui :send]) :sender-network-values)))
(is (not (contains? (get-in (dispatch [event-id]) [:db :wallet :ui :send]) :receiver-network-values)))
(is (not (contains? (get-in (dispatch [event-id]) [:db :wallet :ui :send]) :network-links)))
(is (not (contains? (get-in (dispatch [event-id]) [:db :wallet :ui :send])
:loading-suggested-routes?)))
(is (contains? (get-in (dispatch [event-id]) [:db :wallet :ui :send]) :other-props)))
(let [expected-db {:wallet {:ui {:send {:other-props :value}}}}]
(reset! rf-db/app-db
{:wallet {:ui {:send
{:other-props :value
:suggested-routes ["1" "2"]
:route "1"
:amount 10
:from-values-by-chain [{:chain-id 1} {:chain-id 10} {:chain-id 42161}]
:to-values-by-chain [{:chain-id 1} {:chain-id 10} {:chain-id 42161}]
:sender-network-values [:eth :arb1]
:receiver-network-values [:eth :arb1]
:network-links [{:from-chain-id 1
:to-chain-id 10
:position-diff 1}]
:loading-suggested-routes? false}}}})
(is (match-strict? expected-db (:db (dispatch [event-id]))))))
(h/deftest-event :wallet/suggested-routes-error
[event-id dispatch]
@@ -453,3 +444,287 @@
:recipient recipient
:stack-id stack-id
:start-flow? start-flow?}])))))))
(h/deftest-event :wallet/suggested-routes-success
[event-id dispatch]
(let [timestamp :timestamp
suggested-routes {:Best
[{:From {:isTest false
:chainName "Arbitrum"
:chainId 42161}
:AmountInLocked false
:AmountIn "0x5af3107a4000"
:MaxAmountIn "0x4f7920c6831d6"
:GasFees {:gasPrice "0.01"
:baseFee "0.008750001"
:eip1559Enabled true}
:BridgeName "Transfer"
:AmountOut "0x5af3107a4000"
:To {:isTest false
:chainName "Arbitrum"
:chainId 42161}
:Cost "0.006539438247064285301"
:GasAmount 108197}]
:Candidates
[{:From {:isTest false
:chainName "Arbitrum"
:chainId 42161}
:AmountInLocked false
:AmountIn "0x5af3107a4000"
:MaxAmountIn "0x4f7920c6831d6"
:GasFees {:gasPrice "0.01"
:baseFee "0.008750001"
:eip1559Enabled true}
:BridgeName "Transfer"
:AmountOut "0x5af3107a4000"
:To {:isTest false
:chainName "Arbitrum"
:chainId 42161}
:Cost "0.006539438247064285301"
:GasAmount 108197}
{:From {:isTest false
:chainName "Ethereum"
:chainId 1}
:AmountInLocked false
:AmountIn "0x0"
:MaxAmountIn "0x245aa392272e6"
:GasFees {:gasPrice "1.01"
:baseFee "1.008750001"
:eip1559Enabled true}
:BridgeName "Transfer"
:AmountOut "0x0"
:To {:isTest false
:chainName "Arbitrum"
:chainId 42161}
:Cost "1.906539438247064285301"
:GasAmount 23487}]
:NativeChainTokenPrice 123
:TokenPrice 123}
suggested-routes-data suggested-routes
chosen-route (:best suggested-routes-data)
token-symbol "ETH"
token {:symbol "ETH"
:name "Ether"
:networks #{{:chain-id 421614}
{:chain-id 11155420}
{:chain-id 11155111}}}
token-networks (:networks token)
routes-available? (pos? (count chosen-route))
sender-network-values [1 10]
receiver-network-values [1 10]
receiver-networks [1 10 421614]
token-decimals (if (collectible-with-balance 1) 0 (:decimals token))
native-token? (and token (= token-symbol "ETH"))
from-network-amounts-by-chain (send-utils/network-amounts-by-chain {:route chosen-route
:token-decimals
token-decimals
:native-token?
native-token?
:receiver? false})
to-network-amounts-by-chain (send-utils/network-amounts-by-chain {:route chosen-route
:token-decimals
token-decimals
:native-token?
native-token?
:receiver? true})
to-network-values-for-ui (send-utils/network-values-for-ui to-network-amounts-by-chain)
tx-type :tx/collectible-erc-1155
from-network-values-for-ui (send-utils/network-values-for-ui from-network-amounts-by-chain)
disabled-from-chain-ids [:421614]
token-networks-ids (when token-networks (mapv #(:chain-id %) token-networks))
sender-possible-chain-ids (mapv :chain-id sender-network-values)
receiver-network-values (if routes-available?
(send-utils/network-amounts
{:network-values to-network-values-for-ui
:disabled-chain-ids disabled-from-chain-ids
:receiver-networks receiver-networks
:token-networks-ids token-networks-ids
:tx-type tx-type
:receiver? true})
(cond->
(send-utils/reset-loading-network-amounts-to-zero
receiver-network-values)
(not= tx-type :tx/bridge) (conj {:type :edit})))
sender-network-values (if routes-available?
(send-utils/network-amounts
{:network-values
(if (= tx-type :tx/bridge)
from-network-values-for-ui
(send-utils/add-zero-values-to-network-values
from-network-values-for-ui
sender-possible-chain-ids))
:disabled-chain-ids disabled-from-chain-ids
:receiver-networks receiver-networks
:token-networks-ids token-networks-ids
:from-locked-amounts {}
:tx-type tx-type
:receiver? false})
(send-utils/reset-loading-network-amounts-to-zero
sender-network-values))
expected-db {:wallet {:ui {:send
{:other-props :value
:suggested-routes suggested-routes-data
:route chosen-route
:token token
:disabled-from-chain-ids disabled-from-chain-ids
:suggested-routes-call-timestamp timestamp
:collectible (collectible-with-balance 1)
:token-display-name token-symbol
:receiver-networks receiver-networks
:tx-type tx-type
:from-values-by-chain from-network-values-for-ui
:to-values-by-chain to-network-values-for-ui
:sender-network-values sender-network-values
:receiver-network-values receiver-network-values
:network-links (when routes-available?
(send-utils/network-links
chosen-route
sender-network-values
receiver-network-values))
:loading-suggested-routes? false
:from-locked-amounts {}}}}}]
(reset! rf-db/app-db
{:wallet {:ui {:send {:other-props :value
:suggested-routes-call-timestamp timestamp
:token token
:collectible (collectible-with-balance 1)
:token-display-name token-symbol
:receiver-networks receiver-networks
:receiver-network-values [1 10]
:sender-network-values [1 10]
:tx-type tx-type
:disabled-from-chain-ids disabled-from-chain-ids
:from-locked-amounts {}}}}})
(is (match? expected-db (:db (dispatch [event-id suggested-routes timestamp]))))))
(h/deftest-event :wallet/add-authorized-transaction
[event-id dispatch]
(let [hashes {:chain-1 ["tx-1" "tx-2" "tx-3"]
:chain-2 ["tx-4" "tx-5"]
:chain-3 ["tx-6" "tx-7" "tx-8" "tx-9"]}
transaction-id "txid-1"
expected-result {:db {:wallet {:ui {:send {:transaction-ids ["tx-1" "tx-2" "tx-3"
"tx-4" "tx-5" "tx-6"
"tx-7" "tx-8" "tx-9"]}}
:transactions (send-utils/map-multitransaction-by-ids
transaction-id
hashes)}}
:fx [[:dispatch [:wallet/end-transaction-flow]]
[:dispatch-later
[{:ms 2000
:dispatch [:wallet/clean-just-completed-transaction]}]]]}]
(is (match? expected-result
(dispatch [event-id
{:id transaction-id
:hashes hashes}])))))
(h/deftest-event :wallet/select-from-account
[event-id dispatch]
(let [stack-id :screen/stack
start-flow? false
address "0x01"]
(testing "when tx-type is :tx/bridge and token-symbol is nil"
(let [flow-id :wallet-bridge-flow
tx-type :tx/bridge
expected-result {:db {:wallet {:ui {:send {:to-address address
:tx-type tx-type}}}}
:fx [[:dispatch [:wallet/switch-current-viewing-account address]]
[:dispatch
[:wallet/wizard-navigate-forward
{:current-screen stack-id
:start-flow? start-flow?
:flow-id flow-id}]]]}]
(reset! rf-db/app-db {:wallet {:ui {:send {:tx-type tx-type}}}})
(is (match? expected-result
(dispatch [event-id
{:address address
:stack-id stack-id
:start-flow? start-flow?}])))))
(testing "when tx-type is not :tx/bridge and token-symbol is nil"
(let [flow-id :wallet-send-flow
tx-type :tx/collectible-erc-721
expected-result {:db {:wallet {:ui {:send {:tx-type tx-type}}}}
:fx [[:dispatch [:wallet/switch-current-viewing-account address]]
[:dispatch
[:wallet/wizard-navigate-forward
{:current-screen stack-id
:start-flow? start-flow?
:flow-id flow-id}]]]}]
(reset! rf-db/app-db {:wallet {:ui {:send {:tx-type tx-type}}}})
(is (match? expected-result
(dispatch [event-id
{:address address
:stack-id stack-id
:start-flow? start-flow?}])))))
(testing "when tx-type is :tx/bridge and token-symbol is not nil"
(let [flow-id :wallet-bridge-flow
tx-type :tx/bridge
tokens [{:symbol "ETH"
:chain-id 1
:balances-per-chain {1 {:raw-balance (money/bignumber 100)}
10 {:raw-balance (money/bignumber 200)}
42161 {:raw-balance (money/bignumber 300)}}
:decimals 2}]
network-details #{{:chain-id 1}
{:chain-id 10}
{:chain-id 42161}}
expected-result {:db {:wallet {:ui {:send {:to-address address
:tx-type tx-type
:token-symbol "ETH"
:token (assoc (first tokens)
:networks #{nil}
:total-balance
(money/bignumber 6))}}
:accounts {address {:tokens tokens}}}}
:fx [[:dispatch [:wallet/switch-current-viewing-account address]]
[:dispatch
[:wallet/wizard-navigate-forward
{:current-screen stack-id
:start-flow? start-flow?
:flow-id flow-id}]]]}]
(reset! rf-db/app-db {:wallet {:ui {:send {:tx-type tx-type
:token-symbol "ETH"}}
:accounts {address {:tokens tokens}}}})
(is (match? expected-result
(dispatch [event-id
{:address address
:stack-id stack-id
:start-flow? start-flow?
:netork-details network-details}])))))
(testing "when tx-type is not :tx/bridge and token-symbol is not nil"
(let [flow-id :wallet-send-flow
tx-type :tx/collectible-erc-721
tokens [{:symbol "ETH"
:chain-id 1
:balances-per-chain {1 {:raw-balance (money/bignumber 100)}
10 {:raw-balance (money/bignumber 200)}
42161 {:raw-balance (money/bignumber 300)}}
:decimals 2}]
network-details #{{:chain-id 1}
{:chain-id 10}
{:chain-id 42161}}
expected-result {:db {:wallet {:ui {:send {:tx-type tx-type
:token-symbol "ETH"
:token (assoc (first tokens)
:networks #{nil}
:total-balance
(money/bignumber 6))}}
:accounts {address {:tokens tokens}}}}
:fx [[:dispatch [:wallet/switch-current-viewing-account address]]
[:dispatch
[:wallet/wizard-navigate-forward
{:current-screen stack-id
:start-flow? start-flow?
:flow-id flow-id}]]]}]
(reset! rf-db/app-db {:wallet {:ui {:send {:tx-type tx-type
:token-symbol "ETH"}}
:accounts {address {:tokens tokens}}}})
(is (match? expected-result
(dispatch [event-id
{:address address
:stack-id stack-id
:start-flow? start-flow?
:netork-details network-details}])))))))
(run-tests)
@@ -100,7 +100,8 @@
:wallet/wallet-send-enabled-from-chain-ids [1]
:wallet/wallet-send-amount nil
:wallet/wallet-send-tx-type :tx/send
:wallet/wallet-send-fee-fiat-formatted "$5,00"})
:wallet/wallet-send-fee-fiat-formatted "$5,00"
:wallet/total-amount (money/bignumber "250")})
(h/describe "Send > input amount screen"
(h/setup-restorable-re-frame)
@@ -221,9 +221,9 @@
(number/remove-trailing-zeroes
(.toFixed (/ input-amount conversion-rate)
crypto-decimals)))
send-amount (rf/sub [:wallet/wallet-send-amount])
total-amount-receiver (rf/sub [:wallet/total-amount true])
amount-text (str (number/remove-trailing-zeroes
(.toFixed (js/parseFloat send-amount)
(.toFixed total-amount-receiver
(min token-decimals 6)))
" "
token-symbol)
@@ -124,7 +124,7 @@
:customization-color (:color account)}]])]))
(defn- user-summary
[{:keys [account-props theme label accessibility-label summary-type recipient account-to?]}]
[{:keys [account-props theme label accessibility-label summary-type recipient bridge-tx? account-to?]}]
(let [network-values (rf/sub [:wallet/network-values account-to?])
summary-info-type (case (:recipient-type recipient)
:saved-address :saved-account
@@ -144,7 +144,7 @@
:networks? true
:values network-values
:account-props (cond-> account-props
account-to?
(and account-to? (not bridge-tx?))
(assoc
:size 32
:name (:label recipient)
@@ -225,6 +225,7 @@
bridge-to-chain-id]))
loading-suggested-routes? (rf/sub
[:wallet/wallet-send-loading-suggested-routes?])
total-amount-receiver (rf/sub [:wallet/total-amount true])
from-account-props {:customization-color account-color
:size 32
:emoji (:emoji account)
@@ -249,8 +250,8 @@
[transaction-details
{:estimated-time-min estimated-time-min
:max-fees fee-formatted
:token-display-name token-display-name
:amount amount
:token-display-name token-symbol
:amount total-amount-receiver
:to-network bridge-to-network
:theme theme
:route route
@@ -298,5 +299,6 @@
from-account-props
user-props)
:recipient recipient
:bridge-tx? (= transaction-type :tx/bridge)
:account-to? true
:theme theme}]]]]))))
@@ -47,7 +47,7 @@
[{:keys [route token-decimals native-token? receiver?]}]
(reduce
(fn [acc path]
(let [amount-hex (if receiver? (:amount-in path) (:amount-out path))
(let [amount-hex (if receiver? (:amount-out path) (:amount-in path))
amount-units (native-module/hex-to-number
(utils.hex/normalize-hex amount-hex))
amount (money/with-precision
@@ -32,10 +32,10 @@
(deftest network-amounts-by-chain-test
(testing "Correctly calculates network amounts for transaction with native token"
(let [route [{:amount-in "0xde0b6b3a7640000"
:to {:chain-id 1}}
{:amount-in "0xde0b6b3a7640000"
:to {:chain-id 10}}]
(let [route [{:amount-out "0xde0b6b3a7640000"
:to {:chain-id 1}}
{:amount-out "0xde0b6b3a7640000"
:to {:chain-id 10}}]
token-decimals 18
native-token? true
receiver? true
@@ -50,10 +50,10 @@
(testing
"Correctly calculates network amounts for transaction with native token and multiple routes to same chain-id"
(let [route [{:amount-in "0xde0b6b3a7640000"
:to {:chain-id 1}}
{:amount-in "0xde0b6b3a7640000"
:to {:chain-id 1}}]
(let [route [{:amount-out "0xde0b6b3a7640000"
:to {:chain-id 1}}
{:amount-out "0xde0b6b3a7640000"
:to {:chain-id 1}}]
token-decimals 18
native-token? true
receiver? true
@@ -66,10 +66,10 @@
(is (money/equal-to (get result chain-id) exp-value)))))
(testing "Correctly calculates network amounts for transaction with non-native token"
(let [route [{:amount-out "0x1e8480"
:from {:chain-id 1}}
{:amount-out "0x1e8480"
:from {:chain-id 10}}]
(let [route [{:amount-in "0x1e8480"
:from {:chain-id 1}}
{:amount-in "0x1e8480"
:from {:chain-id 10}}]
token-decimals 6
native-token? false
receiver? false
@@ -1,5 +1,6 @@
(ns status-im.contexts.wallet.wallet-connect.core
(:require [clojure.edn :as edn]
[clojure.set :as set]
[clojure.string :as string]
[native-module.core :as native-module]
[status-im.constants :as constants]
@@ -119,10 +120,24 @@
(networks/get-network-details)
(add-full-testnet-name)))
(defn session-networks-allowed?
[testnet-mode? {:keys [chains]}]
(let [chain-ids (set (map (fn [chain]
(-> chain
(string/split ":")
second
js/parseInt))
chains))]
(if testnet-mode?
(set/subset? chain-ids (set/union constants/sepolia-chain-ids constants/goerli-chain-ids))
(set/subset? chain-ids constants/mainnet-chain-ids))))
(defn event-should-be-handled?
[db {:keys [topic]}]
(some #(= topic %)
(map :topic (:wallet-connect/sessions db))))
(let [testnet-mode? (get-in db [:profile/profile :test-networks-enabled?])]
(some #(and (= (:topic %) topic)
(session-networks-allowed? testnet-mode? %))
(:wallet-connect/sessions db))))
(defn sdk-session->db-session
[{:keys [topic expiry pairingTopic] :as session}]
@@ -67,7 +67,7 @@
(rf/reg-event-fx
:wallet-connect/on-session-proposal
(fn [{:keys [db]} [proposal]]
(log/info "Received Wallet Connect session proposal: " {:id (:id proposal)})
(log/info "Received Wallet Connect session proposal: " proposal)
(let [accounts (get-in db [:wallet :accounts])
current-viewing-address (get-in db [:wallet :current-viewing-account-address])
available-accounts (wallet-connect-core/filter-operable-accounts (vals accounts))
@@ -117,7 +117,7 @@
:wallet-connect/on-session-delete
(fn [{:keys [db]} [{:keys [topic] :as event}]]
(when (wallet-connect-core/event-should-be-handled? db event)
(log/info "Received Wallet Connect session delete: " event)
(log/info "Received Wallet Connect session delete from the SDK: " event)
{:fx [[:dispatch [:wallet-connect/disconnect-session topic]]]})))
(rf/reg-event-fx
@@ -140,6 +140,7 @@
(fn [{:keys [db]} [{:keys [topic on-success on-fail]}]]
(let [web3-wallet (get db :wallet-connect/web3-wallet)
network-status (:network/status db)]
(log/info "Disconnecting dApp session" topic)
(if (= network-status :online)
{:fx [[:effects.wallet-connect/disconnect
{:web3-wallet web3-wallet
@@ -262,6 +263,9 @@
(or (< expiry (/ now 1000))
(not (contains? session-topics topic))))
persisted-sessions)]
(when (seq expired-sessions)
(log/info "Updating WalletConnect persisted sessions due to expired/inactive sessions"
{:expired expired-sessions}))
{:fx (mapv (fn [{:keys [topic]}]
[:dispatch [:wallet-connect/disconnect-session topic]])
expired-sessions)
@@ -324,6 +328,7 @@
(rf/reg-event-fx
:wallet-connect/disconnect-session
(fn [{:keys [db]} [topic]]
(log/info "Removing session from persistance and state" topic)
{:db (update db
:wallet-connect/sessions
(fn [sessions]
@@ -27,6 +27,7 @@
(fn [{:keys [db]} [event]]
(let [method (wallet-connect-core/get-request-method event)
existing-event (get-in db [:wallet-connect/current-request :event])]
(log/info "Processing Wallet Connect session request" method)
;; NOTE: make sure we don't show two requests at the same time
(when-not existing-event
{:db (-> db
@@ -125,38 +126,37 @@
(rf/reg-event-fx
:wallet-connect/process-sign-typed
(fn [{:keys [db]}]
(let [[address raw-data] (wallet-connect-core/get-db-current-request-params db)
parsed-raw-data (transforms/js-parse raw-data)
session-chain-id (-> (wallet-connect-core/get-db-current-request-event db)
(get-in [:params :chainId])
wallet-connect-core/eip155->chain-id)
data-chain-id (-> parsed-raw-data
transforms/js->clj
signing/typed-data-chain-id)
parsed-data (try (-> parsed-raw-data
(transforms/js-dissoc :types :primaryType)
(transforms/js-stringify 2))
(catch js/Error _ nil))]
(cond
(nil? parsed-data)
(try
(let [[address raw-data] (wallet-connect-core/get-db-current-request-params db)
parsed-raw-data (transforms/js-parse raw-data)
session-chain-id (-> (wallet-connect-core/get-db-current-request-event db)
(get-in [:params :chainId])
wallet-connect-core/eip155->chain-id)
data-chain-id (-> parsed-raw-data
transforms/js->clj
signing/typed-data-chain-id)
parsed-data (-> parsed-raw-data
(transforms/js-dissoc :types :primaryType)
(transforms/js-stringify 2))]
(if (and data-chain-id
(not= session-chain-id data-chain-id))
{:fx [[:dispatch
[:wallet-connect/wrong-typed-data-chain-id
{:expected-chain-id session-chain-id
:wrong-chain-id data-chain-id}]]]}
{:db (update-in db
[:wallet-connect/current-request]
assoc
:address (string/lower-case address)
:display-data (or parsed-data raw-data)
:raw-data raw-data)
:fx [[:dispatch [:wallet-connect/show-request-modal]]]}))
(catch js/Error err
{:fx [[:dispatch
[:wallet-connect/on-processing-error
(ex-info "Failed to parse JSON typed data" {:data raw-data})]]]}
(not= session-chain-id data-chain-id)
{:fx [[:dispatch
[:wallet-connect/wrong-typed-data-chain-id
{:expected-chain-id session-chain-id
:wrong-chain-id data-chain-id}]]]}
:else
{:db (update-in db
[:wallet-connect/current-request]
assoc
:address (string/lower-case address)
:display-data (or parsed-data raw-data)
:raw-data raw-data)
:fx [[:dispatch [:wallet-connect/show-request-modal]]]}))))
(ex-info "Failed to parse JSON typed data"
{:error err
:data (wallet-connect-core/get-db-current-request-params db)})]]]}))))
(rf/reg-event-fx
:wallet-connect/wrong-typed-data-chain-id
@@ -168,20 +168,20 @@
wallet-connect-core/chain-id->network-details
:full-name)
toast-message (i18n/label :t/wallet-connect-typed-data-wrong-chain-id-warning
{:wrong-chain wrong-network-name
{:wrong-chain (or wrong-network-name
(wallet-connect-core/chain-id->eip155
wrong-chain-id))
:expected-chain expected-network-name})]
{:fx [[:dispatch
[:toasts/upsert
{:type :negative
:theme :dark
:text toast-message}]]
{:type :negative
:text toast-message}]]
[:dispatch
[:wallet-connect/on-processing-error
(ex-info "Can't proceed signing typed data due to wrong chain-id included in the data"
{:expected-chain-id expected-chain-id
:wrong-chain-id wrong-chain-id})]]]})))
;; TODO: we should reject a request if processing fails
(rf/reg-event-fx
:wallet-connect/on-processing-error
(fn [{:keys [db]} [error]]
@@ -193,4 +193,5 @@
:method method
:wallet-connect-event event
:event :wallet-connect/on-processing-error})
{:fx [[:dispatch [:wallet-connect/dismiss-request-modal]]]})))
;; FIXME(@clauxx/@alwx): rename this event eventually
{:fx [[:dispatch [:wallet-connect/on-request-modal-dismissed]]]})))
@@ -106,7 +106,11 @@
:method method
:wallet-connect-event event
:event :wallet-connect/on-sign-error})
{:fx [[:dispatch [:wallet-connect/dismiss-request-modal]]]})))
{:fx [[:dispatch [:wallet-connect/dismiss-request-modal]]
[:dispatch
[:toasts/upsert
{:type :negative
:text (i18n/label :t/something-went-wrong)}]]]})))
(rf/reg-event-fx
:wallet-connect/send-response
@@ -4,6 +4,7 @@
[status-im.contexts.wallet.wallet-connect.core :as core]
[status-im.contexts.wallet.wallet-connect.rpc :as rpc]
[utils.hex :as hex]
[utils.number :as number]
[utils.transforms :as transforms]))
(defn typed-data-chain-id
@@ -16,7 +17,8 @@
(some #(= "chainId" (:name %))))
data-chain-id (-> typed-data
:domain
:chainId)]
:chainId
number/parse-int)]
(when chain-id-type?
data-chain-id)))
+1
View File
@@ -12,6 +12,7 @@
status-im.common.peer-stats.events
status-im.common.shared-urls.events
status-im.common.signals.events
status-im.common.theme.effects
status-im.common.theme.events
[status-im.common.toasts.events]
status-im.common.universal-links
+1
View File
@@ -22,6 +22,7 @@
:FLAG_WALLET_SETTINGS_IMPORT_ALL_KEYPAIRS)
::shell.jump-to (enabled-in-env? :ENABLE_JUMP_TO)
::wallet.add-watched-address (enabled-in-env? :FLAG_ADD_WATCHED_ADDRESS)
::wallet.advanced-sending (enabled-in-env? :FLAG_ADVANCED_SENDING)
::wallet.assets-modal-hide (enabled-in-env? :FLAG_ASSETS_MODAL_HIDE)
::wallet.assets-modal-manage-tokens (enabled-in-env? :FLAG_ASSETS_MODAL_MANAGE_TOKENS)
+1 -3
View File
@@ -74,9 +74,7 @@
(let [[status-bar-theme] (get-status-nav-color root-id theme)
root (get (roots/roots status-bar-theme) root-id)]
(dismiss-all-modals)
(rf/dispatch [:profile.settings/switch-theme
(get roots/themes root-id)
root-id])
(rf/dispatch [:theme/switch {:view-id root-id}])
(reset! state/root-id (or (get-in root [:root :stack :id]) root-id))
(navigation/set-root root)
(state/navigation-state-reset [{:id root-id
-11
View File
@@ -1,19 +1,8 @@
(ns status-im.navigation.roots
(:require
[quo.foundations.colors :as colors]
[status-im.constants :as constants]
[status-im.navigation.options :as options]))
;; Theme Order for navigation roots
;; 1. Themes hardcoded in below map
;; 2. If nil or no entry in map, then theme stored in
;; [:db :profile/profile :appearance] will be used (for mulitaccounts)
;; 3). Fallback theme - Dark
(def themes
{:screen/onboarding.intro constants/theme-type-dark
:screen/profile.profiles constants/theme-type-dark
:shell-stack nil})
(defn roots-internal
[status-bar-theme]
{:screen/onboarding.intro
-7
View File
@@ -127,13 +127,6 @@
{:title title
:data data})))))
(re-frame/reg-sub
:contacts/is-participant-selected?
:<- [:group-chat/selected-participants]
(fn [selected-participants [_ id]]
(-> selected-participants
(contains? id))))
(re-frame/reg-sub
:contacts/blocked
:<- [:contacts/contacts]
+3 -3
View File
@@ -20,9 +20,9 @@
(re-frame/reg-sub
:profile/currency
:<- [:profile/profile]
(fn [{:keys [currency]}]
(or currency constants/profile-default-currency)))
(fn []
;; returns "usd" by default as the support for other currencies are in progress on Mobile
constants/profile-default-currency))
(re-frame/reg-sub
:profile/syncing-on-mobile-network?
+15 -1
View File
@@ -1,6 +1,7 @@
(ns status-im.subs.wallet.networks
(:require [re-frame.core :as re-frame]
[status-im.contexts.wallet.common.utils.networks :as network-utils]))
[status-im.contexts.wallet.common.utils.networks :as network-utils]
[utils.money :as money]))
(def max-network-prefixes 2)
@@ -80,3 +81,16 @@
{:amount amount :token-symbol token-symbol})))
{}
network-values))))
(re-frame/reg-sub
:wallet/total-amount
:<- [:wallet/wallet-send]
(fn [{:keys [from-values-by-chain to-values-by-chain]} [_ to-values?]]
(let [network-values (if to-values? to-values-by-chain from-values-by-chain)]
(reduce
(fn [acc amount]
(if (money/bignumber? amount)
(money/add acc amount)
acc))
(money/bignumber 0)
(vals network-values)))))
+2 -13
View File
@@ -1,8 +1,6 @@
(ns status-im.subs.wallet.wallet-connect
(:require [clojure.set :as set]
[clojure.string :as string]
(:require [clojure.string :as string]
[re-frame.core :as rf]
[status-im.constants :as constants]
[status-im.contexts.wallet.common.utils :as wallet-utils]
[status-im.contexts.wallet.wallet-connect.core :as wallet-connect-core]
[status-im.contexts.wallet.wallet-connect.transactions :as transactions]
@@ -66,16 +64,7 @@
:<- [:profile/test-networks-enabled?]
(fn [[sessions testnet-mode?]]
(filter
(fn [{:keys [chains]}]
(let [chain-ids (set (map (fn [chain]
(-> chain
(string/split ":")
second
js/parseInt))
chains))]
(if testnet-mode?
(set/subset? chain-ids (set/union constants/sepolia-chain-ids constants/goerli-chain-ids))
(set/subset? chain-ids constants/mainnet-chain-ids))))
(partial wallet-connect-core/session-networks-allowed? testnet-mode?)
sessions)))
(rf/reg-sub
+3 -2
View File
@@ -12,9 +12,10 @@
[re-frame.events :as rf-events]
[re-frame.registrar :as rf-registrar]
[re-frame.subs :as rf-subs]
[taoensso.timbre :as log] ;; We must require this namespace to register the custom cljs.test
;; directive `match-strict?`.
[taoensso.timbre :as log]
test-helpers.matchers))
;; We must require `test-helpers.matchers` this namespace to register the custom cljs.test
;; directive `match-strict?`.
(defn db
"A simple wrapper to get the latest value from the app db."
+3 -3
View File
@@ -3,7 +3,7 @@
"_comment": "Instead use: scripts/update-status-go.sh <rev>",
"owner": "status-im",
"repo": "status-go",
"version": "v0.182.39",
"commit-sha1": "9755b3de7ae64929066d2b8a26222d8d41ceda87",
"src-sha256": "02b2fshb7phhsr7mghg4s6qr1n1c8xawaz4pw04q8hpv5vfnjcxz"
"version": "test/set-api-proxy-test-debug",
"commit-sha1": "022b6fd45b99819ec14baabd6d482ae85ed468bf",
"src-sha256": "03p7x3s9005ghi02x334077nxwdhwlkxmvhcnc07lsygfsnzkkzk"
}
@@ -240,6 +240,7 @@ class TestWalletOneDevice(MultipleSharedDeviceTestCase):
self.errors.verify_no_errors()
@marks.testrail_id(727232)
@marks.skip("The feature is disabled in https://github.com/status-im/status-mobile/pull/20955")
@marks.xfail(reason="Missing networks in account address, https://github.com/status-im/status-mobile/issues/20166")
def test_wallet_add_remove_watch_only_account(self):
self.wallet_view.just_fyi("Adding new watch only account")
+4
View File
@@ -149,6 +149,8 @@ class SignInView(BaseView):
# intro screen
self.i_m_new_in_status_button = Button(self.driver, accessibility_id="new-to-status-button")
self.terms_and_privacy_checkbox = Button(
self.driver, xpath="//*[@content-desc='terms-privacy-checkbox-container']/*[@content-desc='checkbox-off']")
self.create_profile_button = Button(self.driver, accessibility_id='new-to-status-button')
self.not_now_button = Button(self.driver, xpath="//*[@text='Not now']")
self.sync_or_recover_profile_button = Button(self.driver, accessibility_id='already-use-status-button')
@@ -236,6 +238,7 @@ class SignInView(BaseView):
self.driver.info("## Creating new multiaccount (password:'%s', keycard:'%s', enable_notification: '%s')" %
(password, str(keycard), str(enable_notifications)), device=False)
if first_user:
self.terms_and_privacy_checkbox.click()
self.create_profile_button.click_until_presence_of_element(self.generate_keys_button)
self.not_now_button.wait_and_click()
else:
@@ -275,6 +278,7 @@ class SignInView(BaseView):
self.driver.info("## Recover access(password:%s, keycard:%s)" % (password, str(keycard)), device=False)
if not second_user:
self.terms_and_privacy_checkbox.click()
self.sync_or_recover_profile_button.click_until_presence_of_element(self.generate_keys_button)
self.not_now_button.wait_and_click()
else:
+2
View File
@@ -186,6 +186,7 @@
"balance": "Balance",
"begin-set-up": "Begin setup",
"below-base-fee": "max fee below base fee",
"beta": "Beta",
"bio": "Bio",
"bio-added": "Bio added",
"bio-is-too-long": "Bio is too long",
@@ -1174,6 +1175,7 @@
"intro-message1": "Welcome to Status!\nTap this message to set your password and get started.",
"intro-privacy-policy-note1": "Status does not collect or profit from your personal data. By continuing, you agree with the ",
"intro-privacy-policy-note2": "privacy policy",
"intro-privacy-statement": "Privacy Statement",
"intro-text": "Status is your gateway to the decentralized web",
"intro-text1": "Chat over a peer-to-peer, encrypted network where messages cant be censored or hacked",
"intro-text2": "Send and receive digital assets anywhere in the world—no bank account required",
+3 -4
View File
@@ -9372,10 +9372,9 @@ react-native-blob-util@^0.13.18:
base-64 "0.1.0"
glob "^7.1.6"
react-native-camera-kit@14.0.0-beta13:
version "14.0.0-beta13"
resolved "https://registry.yarnpkg.com/react-native-camera-kit/-/react-native-camera-kit-14.0.0-beta13.tgz#7d1c40571e7e7ce2c4b6bd6f58807f7573217c3c"
integrity sha512-49q6l/Y3j1QMUDPGqIqkUzdraNtKWVQz5X4U8qfixSe+MeWe0N1vWlWWr8iH1apxQCS5v0dKPlYot0e3VKy05g==
"react-native-camera-kit@git+https://github.com/status-im/react-native-camera-kit.git#refs/tags/v14.0.0-beta15-status-v1":
version "14.0.0-beta15"
resolved "git+https://github.com/status-im/react-native-camera-kit.git#90821bc45c950c98119acc896651997a5357dd4f"
react-native-config@^1.5.0:
version "1.5.0"