diff --git a/app/_locales/am/messages.json b/app/_locales/am/messages.json index 992cdc88e24a..3b06df1b6d7b 100644 --- a/app/_locales/am/messages.json +++ b/app/_locales/am/messages.json @@ -504,12 +504,6 @@ "prev": { "message": "የቀደመ" }, - "primaryCurrencySetting": { - "message": "ተቀዳሚ የገንዘብ ዓይነት" - }, - "primaryCurrencySettingDescription": { - "message": "ዋጋዎች በራሳቸው የሰንሰለት ገንዘብ ዓይነት (ለምሳሌ ETH) በቅድሚያ እንዲታዪ ይምረጡ። ዋጋዎች በተመረጠ የፊያት ገንዘብ ዓይነት እንዲታዩ ደግሞ ፊያትን ይምረጡ።" - }, "privacyMsg": { "message": "የግለኝነት መጠበቂያ ህግ" }, diff --git a/app/_locales/ar/messages.json b/app/_locales/ar/messages.json index 0d00ae364528..593babd3a649 100644 --- a/app/_locales/ar/messages.json +++ b/app/_locales/ar/messages.json @@ -520,12 +520,6 @@ "prev": { "message": "السابق" }, - "primaryCurrencySetting": { - "message": "العملة الأساسية" - }, - "primaryCurrencySettingDescription": { - "message": "حدد خيار \"المحلية\" لتحديد أولويات عرض القيم بالعملة المحلية للسلسلة (مثلاً ETH). حدد Fiat لتحديد أولويات عرض القيم بعملات fiat المحددة الخاصة بك." - }, "privacyMsg": { "message": "سياسة الخصوصية" }, diff --git a/app/_locales/bg/messages.json b/app/_locales/bg/messages.json index fcd984be91b8..6c2888c608c5 100644 --- a/app/_locales/bg/messages.json +++ b/app/_locales/bg/messages.json @@ -519,12 +519,6 @@ "prev": { "message": "Предишен" }, - "primaryCurrencySetting": { - "message": "Основна валута" - }, - "primaryCurrencySettingDescription": { - "message": "Изберете местна, за да приоритизирате показването на стойности в основната валута на веригата (например ETH). Изберете Fiat, за да поставите приоритет на показването на стойности в избраната от вас fiat валута." - }, "privacyMsg": { "message": "Политика за поверителност" }, diff --git a/app/_locales/bn/messages.json b/app/_locales/bn/messages.json index 15a5dbcbfd91..904d516766a7 100644 --- a/app/_locales/bn/messages.json +++ b/app/_locales/bn/messages.json @@ -513,12 +513,6 @@ "prev": { "message": "পূর্ববর্তী" }, - "primaryCurrencySetting": { - "message": "প্রাথমিক মুদ্রা" - }, - "primaryCurrencySettingDescription": { - "message": "চেনটিতে (যেমন ETH) দেশীয় মুদ্রায় মানগুলি প্রদর্শনকে অগ্রাধিকার দিতে দেশীয় নির্বাচন করুন। আপনার নির্দেশিত মুদ্রায় মানগুলির প্রদর্শনকে অগ্রাধিকার দিতে নির্দেশিত নির্বাচন করুন।" - }, "privacyMsg": { "message": "সম্মত হয়েছেন" }, diff --git a/app/_locales/ca/messages.json b/app/_locales/ca/messages.json index 10b6fdd4b0b8..55208e7a00d0 100644 --- a/app/_locales/ca/messages.json +++ b/app/_locales/ca/messages.json @@ -504,12 +504,6 @@ "personalAddressDetected": { "message": "Adreça personal detectada. Introduir l'adreça del contracte de fitxa." }, - "primaryCurrencySetting": { - "message": "Divisa principal" - }, - "primaryCurrencySettingDescription": { - "message": "Selecciona Natiu per a prioritzar la mostra de valors en la divisa nadiua de la cadena (p. ex. ETH). Selecciona Fiat per prioritzar la mostra de valors en la divisa fiduciària seleccionada." - }, "privacyMsg": { "message": "Política de privadesa" }, diff --git a/app/_locales/da/messages.json b/app/_locales/da/messages.json index fc619bbef0a0..910fc43b07d6 100644 --- a/app/_locales/da/messages.json +++ b/app/_locales/da/messages.json @@ -504,12 +504,6 @@ "prev": { "message": "Forrige" }, - "primaryCurrencySetting": { - "message": "Primær Valuta" - }, - "primaryCurrencySettingDescription": { - "message": "Vælg lokal for fortrinsvis at vise værdier i kædens (f.eks. ETH) lokale valuta. Vælg Fiat for fortrinsvis at vise værdier i din valgte fiat valuta." - }, "privacyMsg": { "message": "Privatlivspolitik" }, diff --git a/app/_locales/de/messages.json b/app/_locales/de/messages.json index 7b27d7d33230..eb4eea16bc91 100644 --- a/app/_locales/de/messages.json +++ b/app/_locales/de/messages.json @@ -3992,12 +3992,6 @@ "priceUnavailable": { "message": "Preis nicht verfügbar" }, - "primaryCurrencySetting": { - "message": "Hauptwährung" - }, - "primaryCurrencySettingDescription": { - "message": "Wählen Sie 'Nativ', um dem Anzeigen von Werten in der nativen Währung der Chain (z. B. ETH) Vorrang zu geben. Wählen Sie 'Fiat', um dem Anzeigen von Werten in Ihrer gewählten Fiat-Währung Vorrang zu geben." - }, "primaryType": { "message": "Primärer Typ" }, diff --git a/app/_locales/el/messages.json b/app/_locales/el/messages.json index 83367518528e..f5c56122ef3e 100644 --- a/app/_locales/el/messages.json +++ b/app/_locales/el/messages.json @@ -3992,12 +3992,6 @@ "priceUnavailable": { "message": "μη διαθέσιμη τιμή" }, - "primaryCurrencySetting": { - "message": "Κύριο νόμισμα" - }, - "primaryCurrencySettingDescription": { - "message": "Επιλέξτε εγχώριο για να δώσετε προτεραιότητα στην εμφάνιση των τιμών στο νόμισμα της αλυσίδας (π.χ. ETH). Επιλέξτε Παραστατικό για να δώσετε προτεραιότητα στην εμφάνιση τιμών στο επιλεγμένο παραστατικό νόμισμα." - }, "primaryType": { "message": "Βασικός τύπος" }, diff --git a/app/_locales/en/messages.json b/app/_locales/en/messages.json index 1b81a5c93eb5..05cd23fe5ad7 100644 --- a/app/_locales/en/messages.json +++ b/app/_locales/en/messages.json @@ -396,6 +396,10 @@ "advancedPriorityFeeToolTip": { "message": "Priority fee (aka “miner tip”) goes directly to miners and incentivizes them to prioritize your transaction." }, + "aggregatedBalancePopover": { + "message": "This reflects the value of all tokens you own on a given network. If you prefer seeing this value in ETH or other currencies, go to $1.", + "description": "$1 represents the settings page" + }, "agreeTermsOfUse": { "message": "I agree to MetaMask's $1", "description": "$1 is the `terms` link" @@ -4113,12 +4117,6 @@ "priceUnavailable": { "message": "price unavailable" }, - "primaryCurrencySetting": { - "message": "Primary currency" - }, - "primaryCurrencySettingDescription": { - "message": "Select native to prioritize displaying values in the native currency of the chain (e.g. ETH). Select Fiat to prioritize displaying values in your selected fiat currency." - }, "primaryType": { "message": "Primary type" }, @@ -6604,6 +6602,9 @@ "yourBalance": { "message": "Your balance" }, + "yourBalanceIsAggregated": { + "message": "Your balance is aggregated" + }, "yourNFTmayBeAtRisk": { "message": "Your NFT may be at risk" }, diff --git a/app/_locales/en_GB/messages.json b/app/_locales/en_GB/messages.json index fb3cefda9265..606e8eb6d818 100644 --- a/app/_locales/en_GB/messages.json +++ b/app/_locales/en_GB/messages.json @@ -4024,12 +4024,6 @@ "priceUnavailable": { "message": "price unavailable" }, - "primaryCurrencySetting": { - "message": "Primary currency" - }, - "primaryCurrencySettingDescription": { - "message": "Select native to prioritize displaying values in the native currency of the chain (e.g. ETH). Select Fiat to prioritize displaying values in your selected fiat currency." - }, "primaryType": { "message": "Primary type" }, diff --git a/app/_locales/es/messages.json b/app/_locales/es/messages.json index 03182da659a4..3dbff4153784 100644 --- a/app/_locales/es/messages.json +++ b/app/_locales/es/messages.json @@ -3989,12 +3989,6 @@ "priceUnavailable": { "message": "precio no disponible" }, - "primaryCurrencySetting": { - "message": "Moneda principal" - }, - "primaryCurrencySettingDescription": { - "message": "Seleccione Nativa para dar prioridad a mostrar los valores en la moneda nativa de la cadena (p. ej., ETH). Seleccione Fiduciaria para dar prioridad a mostrar los valores en la moneda fiduciaria seleccionada." - }, "primaryType": { "message": "Tipo principal" }, diff --git a/app/_locales/es_419/messages.json b/app/_locales/es_419/messages.json index 11f543db6acc..72e530afc447 100644 --- a/app/_locales/es_419/messages.json +++ b/app/_locales/es_419/messages.json @@ -1509,12 +1509,6 @@ "prev": { "message": "Ant." }, - "primaryCurrencySetting": { - "message": "Moneda principal" - }, - "primaryCurrencySettingDescription": { - "message": "Seleccione Nativa para dar prioridad a mostrar los valores en la moneda nativa de la cadena (p. ej., ETH). Seleccione Fiduciaria para dar prioridad a mostrar los valores en la moneda fiduciaria seleccionada." - }, "priorityFee": { "message": "Tarifa de prioridad" }, diff --git a/app/_locales/et/messages.json b/app/_locales/et/messages.json index a4fa6b72ecf1..d0932270dce2 100644 --- a/app/_locales/et/messages.json +++ b/app/_locales/et/messages.json @@ -513,12 +513,6 @@ "prev": { "message": "Eelm" }, - "primaryCurrencySetting": { - "message": "Põhivaluuta" - }, - "primaryCurrencySettingDescription": { - "message": "Valige omavääring, et prioriseerida vääringu kuvamist ahela omavääringus (nt ETH). Valige Fiat, et prioriseerida vääringu kuvamist valitud fiat-vääringus." - }, "privacyMsg": { "message": "privaatsuspoliitika" }, diff --git a/app/_locales/fa/messages.json b/app/_locales/fa/messages.json index c58e01945a51..d5c93ebe8808 100644 --- a/app/_locales/fa/messages.json +++ b/app/_locales/fa/messages.json @@ -519,12 +519,6 @@ "prev": { "message": "قبلی" }, - "primaryCurrencySetting": { - "message": "واحد پول اصلی" - }, - "primaryCurrencySettingDescription": { - "message": "برای اولویت دهی نمایش قیمت ها در واحد پولی اصلی زنجیره (مثلًا ETH)، اصلی را انتخاب کنید. برای اولویت دهی نمایش قیمت ها در فیات واحد پولی شما، فیات را انتخاب کنید." - }, "privacyMsg": { "message": "خط‌مشی رازداری" }, diff --git a/app/_locales/fi/messages.json b/app/_locales/fi/messages.json index 530afeafb419..a4ad460fb3ca 100644 --- a/app/_locales/fi/messages.json +++ b/app/_locales/fi/messages.json @@ -516,12 +516,6 @@ "prev": { "message": "Aiemp." }, - "primaryCurrencySetting": { - "message": "Ensisijainen valuutta" - }, - "primaryCurrencySettingDescription": { - "message": "Valitse natiivivaihtoehto näyttääksesi arvot ensisijaisesti ketjun natiivivaluutalla (esim. ETH). Valitse oletusmääräys asettaaksesi valitsemasi oletusvaluutan ensisijaiseksi." - }, "privacyMsg": { "message": "Tietosuojakäytäntö" }, diff --git a/app/_locales/fil/messages.json b/app/_locales/fil/messages.json index 4b1bb1e058ca..f78b1df839ef 100644 --- a/app/_locales/fil/messages.json +++ b/app/_locales/fil/messages.json @@ -451,12 +451,6 @@ "prev": { "message": "Nakaraan" }, - "primaryCurrencySetting": { - "message": "Pangunahing Currency" - }, - "primaryCurrencySettingDescription": { - "message": "Piliin ang native para bigyang priyoridad ang pagpapakita ng mga halaga sa native currency ng chain (hal. ETH). Piliin ang Fiat para bigyang priyoridad ang pagpapakita ng mga halaga sa napili mong fiat currency." - }, "privacyMsg": { "message": "Patakaran sa Privacy" }, diff --git a/app/_locales/fr/messages.json b/app/_locales/fr/messages.json index f7164e2d61ea..beefe622b5d0 100644 --- a/app/_locales/fr/messages.json +++ b/app/_locales/fr/messages.json @@ -3992,12 +3992,6 @@ "priceUnavailable": { "message": "prix non disponible" }, - "primaryCurrencySetting": { - "message": "Devise principale" - }, - "primaryCurrencySettingDescription": { - "message": "Sélectionnez « natif » pour donner la priorité à l’affichage des valeurs dans la devise native de la chaîne (par ex. ETH). Sélectionnez « fiduciaire » pour donner la priorité à l’affichage des valeurs dans la devise de votre choix." - }, "primaryType": { "message": "Type principal" }, diff --git a/app/_locales/he/messages.json b/app/_locales/he/messages.json index a7fdf1662184..b6ec8797a942 100644 --- a/app/_locales/he/messages.json +++ b/app/_locales/he/messages.json @@ -516,12 +516,6 @@ "prev": { "message": "הקודם" }, - "primaryCurrencySetting": { - "message": "מטבע ראשי" - }, - "primaryCurrencySettingDescription": { - "message": "בחר/י 'מקומי' כדי לתעדף הצגת ערכים במטבע המקומי של הצ'יין (למשל ETH). בחר/י פיאט כדי לתעדף הצגת ערכים במטבע הפיאט שבחרת." - }, "privacyMsg": { "message": "מדיניות הפרטיות" }, diff --git a/app/_locales/hi/messages.json b/app/_locales/hi/messages.json index 1e2f0307bb78..3ebc41409ca1 100644 --- a/app/_locales/hi/messages.json +++ b/app/_locales/hi/messages.json @@ -3992,12 +3992,6 @@ "priceUnavailable": { "message": "प्राइस अनुपलब्ध है" }, - "primaryCurrencySetting": { - "message": "प्राथमिक मुद्रा" - }, - "primaryCurrencySettingDescription": { - "message": "चेन की ओरिजिनल करेंसी (जैसे ETH) में प्रदर्शित वैल्यूज़ को प्राथमिकता देने के लिए ओरिजिनल को चुनें। अपनी चुना गया फिएट करेंसी में प्रदर्शित वैल्यूज़ को प्राथमिकता देने के लिए फिएट को चुनें।" - }, "primaryType": { "message": "प्राइमरी टाइप" }, diff --git a/app/_locales/hr/messages.json b/app/_locales/hr/messages.json index 26cbd3838807..b7e337e877aa 100644 --- a/app/_locales/hr/messages.json +++ b/app/_locales/hr/messages.json @@ -516,12 +516,6 @@ "prev": { "message": "Prethodno" }, - "primaryCurrencySetting": { - "message": "Glavna valuta" - }, - "primaryCurrencySettingDescription": { - "message": "Odaberite da se prvo prikazuju valute u osnovnoj valuti bloka (npr. ETH). Odaberite mogućnost Fiat za prikazivanje valuta u odabranoj valuti Fiat." - }, "privacyMsg": { "message": "Pravilnik o zaštiti privatnosti" }, diff --git a/app/_locales/ht/messages.json b/app/_locales/ht/messages.json index 267547371bcd..76d0a8726661 100644 --- a/app/_locales/ht/messages.json +++ b/app/_locales/ht/messages.json @@ -359,12 +359,6 @@ "prev": { "message": "Avan" }, - "primaryCurrencySetting": { - "message": "Lajan ou itilize pi plis la" - }, - "primaryCurrencySettingDescription": { - "message": "Chwazi ETH pou bay priyorite montre valè nan ETH. Chwazi Fiat priyorite montre valè nan lajan ou chwazi a." - }, "privacyMsg": { "message": "Règleman sou enfòmasyon prive" }, diff --git a/app/_locales/hu/messages.json b/app/_locales/hu/messages.json index a244ad8abb7b..933067070194 100644 --- a/app/_locales/hu/messages.json +++ b/app/_locales/hu/messages.json @@ -516,12 +516,6 @@ "prev": { "message": "Előző" }, - "primaryCurrencySetting": { - "message": "Elsődleges pénznem" - }, - "primaryCurrencySettingDescription": { - "message": "Válaszd a helyit, hogy az értékek elsősorban a helyi pénznemben jelenjenek meg (pl. ETH). Válaszd a Fiatot, hogy az értékek elsősorban a választott fiat pénznemben jelenjenek meg." - }, "privacyMsg": { "message": "Adatvédelmi szabályzat" }, diff --git a/app/_locales/id/messages.json b/app/_locales/id/messages.json index 41bfb6733211..2fd3d6812d9f 100644 --- a/app/_locales/id/messages.json +++ b/app/_locales/id/messages.json @@ -3992,12 +3992,6 @@ "priceUnavailable": { "message": "harga tidak tersedia" }, - "primaryCurrencySetting": { - "message": "Mata uang primer" - }, - "primaryCurrencySettingDescription": { - "message": "Pilih asal untuk memprioritaskan nilai yang ditampilkan dalam mata uang asal chain (contoh, ETH). Pilih Fiat untuk memprioritaskan nilai yang ditampilkan dalam mata uang fiat yang Anda pilih." - }, "primaryType": { "message": "Tipe primer" }, diff --git a/app/_locales/it/messages.json b/app/_locales/it/messages.json index 770968a70f00..1f8e49c6a759 100644 --- a/app/_locales/it/messages.json +++ b/app/_locales/it/messages.json @@ -1198,12 +1198,6 @@ "prev": { "message": "Precedente" }, - "primaryCurrencySetting": { - "message": "Moneta Primaria" - }, - "primaryCurrencySettingDescription": { - "message": "Seleziona ETH per privilegiare la visualizzazione dei valori nella moneta nativa della blockhain. Seleziona Fiat per privilegiare la visualizzazione dei valori nella moneta selezionata." - }, "privacyMsg": { "message": "Politica sulla Privacy" }, diff --git a/app/_locales/ja/messages.json b/app/_locales/ja/messages.json index 184c82751dfa..51a0c7c8a670 100644 --- a/app/_locales/ja/messages.json +++ b/app/_locales/ja/messages.json @@ -3992,12 +3992,6 @@ "priceUnavailable": { "message": "価格が利用できません" }, - "primaryCurrencySetting": { - "message": "プライマリ通貨" - }, - "primaryCurrencySettingDescription": { - "message": "チェーンのネイティブ通貨 (ETHなど) による値の表示を優先するには、「ネイティブ」を選択します。選択した法定通貨による値の表示を優先するには、「法定通貨」を選択します。" - }, "primaryType": { "message": "基本型" }, diff --git a/app/_locales/kn/messages.json b/app/_locales/kn/messages.json index 095670da3fb3..cf0a72815725 100644 --- a/app/_locales/kn/messages.json +++ b/app/_locales/kn/messages.json @@ -519,12 +519,6 @@ "prev": { "message": "ಹಿಂದಿನ" }, - "primaryCurrencySetting": { - "message": "ಪ್ರಾಥಮಿಕ ಕರೆನ್ಸಿ" - }, - "primaryCurrencySettingDescription": { - "message": "ಸರಪಳಿಯ ಸ್ಥಳೀಯ ಕರೆನ್ಸಿಯಲ್ಲಿ ಮೌಲ್ಯಗಳನ್ನು ಪ್ರದರ್ಶಿಸಲು ಆದ್ಯತೆ ನೀಡಲು ಸ್ಥಳೀಯವನ್ನು ಆಯ್ಕೆಮಾಡಿ (ಉದಾ. ETH). ನಿಮ್ಮ ಆಯ್ಕೆಮಾಡಿದ ಫಿಯೆಟ್ ಕರೆನ್ಸಿಯಲ್ಲಿ ಮೌಲ್ಯಗಳನ್ನು ಪ್ರದರ್ಶಿಸಲು ಆದ್ಯತೆ ನೀಡಲು ಫಿಯೆಟ್ ಆಯ್ಕೆಮಾಡಿ." - }, "privacyMsg": { "message": "ಗೌಪ್ಯತೆ ನೀತಿ" }, diff --git a/app/_locales/ko/messages.json b/app/_locales/ko/messages.json index 08c350155187..b7b3f79ee70a 100644 --- a/app/_locales/ko/messages.json +++ b/app/_locales/ko/messages.json @@ -3992,12 +3992,6 @@ "priceUnavailable": { "message": "가격 사용 불가" }, - "primaryCurrencySetting": { - "message": "기본 통화" - }, - "primaryCurrencySettingDescription": { - "message": "체인의 고유 통화(예: ETH)로 값을 우선 표시하려면 고유를 선택합니다. 선택한 명목 통화로 값을 우선 표시하려면 명목을 선택합니다." - }, "primaryType": { "message": "기본 유형" }, diff --git a/app/_locales/lt/messages.json b/app/_locales/lt/messages.json index f14348b4000e..29952fa04cef 100644 --- a/app/_locales/lt/messages.json +++ b/app/_locales/lt/messages.json @@ -519,12 +519,6 @@ "prev": { "message": "Peržiūra" }, - "primaryCurrencySetting": { - "message": "Pagrindinė valiuta" - }, - "primaryCurrencySettingDescription": { - "message": "Rinkitės vietinę, kad vertės pirmiausia būtų rodomos vietine grandinės valiuta (pvz., ETH). Rinkitės standartinę, kad vertės pirmiausia būtų rodomos jūsų pasirinkta standartine valiuta." - }, "privacyMsg": { "message": "Privatumo politika" }, diff --git a/app/_locales/lv/messages.json b/app/_locales/lv/messages.json index 596858c017d5..f2795543268d 100644 --- a/app/_locales/lv/messages.json +++ b/app/_locales/lv/messages.json @@ -519,12 +519,6 @@ "prev": { "message": "Iepr." }, - "primaryCurrencySetting": { - "message": "Primārā valūta" - }, - "primaryCurrencySettingDescription": { - "message": "Atlasīt vietējo, lai piešķirtu attēlotajām vērtībām prioritātes ķēdes vietējā vērtībā (piemēram, ETH). Atlasiet Fiat, lai piešķirtu augstāku prioritāti vērtībām jūsu atlasītajā fiat valūtā." - }, "privacyMsg": { "message": "Privātuma politika" }, diff --git a/app/_locales/ms/messages.json b/app/_locales/ms/messages.json index a45288f90ae8..0d8543038312 100644 --- a/app/_locales/ms/messages.json +++ b/app/_locales/ms/messages.json @@ -503,12 +503,6 @@ "prev": { "message": "Sebelumnya" }, - "primaryCurrencySetting": { - "message": "Mata Wang Utama" - }, - "primaryCurrencySettingDescription": { - "message": "Pilih natif untuk mengutamakan nilai paparan dalam mata wang natif rantaian (cth. ETH). Pilih Fiat untuk mengutamakan nilai paparan dalam mata wang fiat yang anda pilih." - }, "privacyMsg": { "message": "Dasar Privasi" }, diff --git a/app/_locales/no/messages.json b/app/_locales/no/messages.json index 20aa168b32a4..aa8bb94b97d0 100644 --- a/app/_locales/no/messages.json +++ b/app/_locales/no/messages.json @@ -507,12 +507,6 @@ "prev": { "message": "Tidligere" }, - "primaryCurrencySetting": { - "message": "Hovedvaluta " - }, - "primaryCurrencySettingDescription": { - "message": "Velg nasjonal for å prioritere å vise verdier i nasjonal valuta i kjeden (f.eks. ETH). Velg Fiat for å prioritere visning av verdier i den valgte fiat-valutaen." - }, "privacyMsg": { "message": "Personvernerklæring" }, diff --git a/app/_locales/ph/messages.json b/app/_locales/ph/messages.json index 2c1094cff462..d2897373e35c 100644 --- a/app/_locales/ph/messages.json +++ b/app/_locales/ph/messages.json @@ -972,12 +972,6 @@ "prev": { "message": "Nakaraan" }, - "primaryCurrencySetting": { - "message": "Pangunahing Currency" - }, - "primaryCurrencySettingDescription": { - "message": "Piliin ang native para maisapriyoridad ang pagpapakita ng mga value sa native na currency ng chain (hal. ETH). Piliin ang Fiat para maisapriyoridad ang pagpapakita ng mga value sa napili mong fiat currency." - }, "privacyMsg": { "message": "Patakaran sa Pagkapribado" }, diff --git a/app/_locales/pl/messages.json b/app/_locales/pl/messages.json index 61ea570e855d..572d3a650c20 100644 --- a/app/_locales/pl/messages.json +++ b/app/_locales/pl/messages.json @@ -513,12 +513,6 @@ "prev": { "message": "Poprzednie" }, - "primaryCurrencySetting": { - "message": "Waluta podstawowa" - }, - "primaryCurrencySettingDescription": { - "message": "Wybierz walutę natywną, aby preferować wyświetlanie wartości w walucie natywnej łańcucha (np. ETH). Wybierz walutę fiat, aby preferować wyświetlanie wartości w wybranej przez siebie walucie fiat." - }, "privacyMsg": { "message": "Polityka prywatności" }, diff --git a/app/_locales/pt/messages.json b/app/_locales/pt/messages.json index fd7de006e21b..4524d95904f0 100644 --- a/app/_locales/pt/messages.json +++ b/app/_locales/pt/messages.json @@ -3992,12 +3992,6 @@ "priceUnavailable": { "message": "preço não disponível" }, - "primaryCurrencySetting": { - "message": "Moeda principal" - }, - "primaryCurrencySettingDescription": { - "message": "Selecione Nativa para priorizar a exibição de valores na moeda nativa da cadeia (por ex., ETH). Selecione Fiduciária para priorizar a exibição de valores na moeda fiduciária selecionada." - }, "primaryType": { "message": "Tipo primário" }, diff --git a/app/_locales/pt_BR/messages.json b/app/_locales/pt_BR/messages.json index ef9f817ebf7f..c119d1b537d2 100644 --- a/app/_locales/pt_BR/messages.json +++ b/app/_locales/pt_BR/messages.json @@ -1513,12 +1513,6 @@ "prev": { "message": "Anterior" }, - "primaryCurrencySetting": { - "message": "Moeda principal" - }, - "primaryCurrencySettingDescription": { - "message": "Selecione Nativa para priorizar a exibição de valores na moeda nativa da cadeia (por ex., ETH). Selecione Fiduciária para priorizar a exibição de valores na moeda fiduciária selecionada." - }, "priorityFee": { "message": "Taxa de prioridade" }, diff --git a/app/_locales/ro/messages.json b/app/_locales/ro/messages.json index a0a15746b4c0..b404e4956301 100644 --- a/app/_locales/ro/messages.json +++ b/app/_locales/ro/messages.json @@ -510,12 +510,6 @@ "prev": { "message": "Ant" }, - "primaryCurrencySetting": { - "message": "Moneda principală" - }, - "primaryCurrencySettingDescription": { - "message": "Selectați nativ pentru a prioritiza valorile afișate în moneda nativă a lanțului (ex. ETH). Selectați Fiat pentru a prioritiza valorile afișate în moneda selectată fiat." - }, "privacyMsg": { "message": "Politica de Confidențialitate" }, diff --git a/app/_locales/ru/messages.json b/app/_locales/ru/messages.json index 0a67cb30dcb7..d6967b932384 100644 --- a/app/_locales/ru/messages.json +++ b/app/_locales/ru/messages.json @@ -3992,12 +3992,6 @@ "priceUnavailable": { "message": "цена недоступна" }, - "primaryCurrencySetting": { - "message": "Основная валюта" - }, - "primaryCurrencySettingDescription": { - "message": "Выберите «собственная», чтобы установить приоритет отображения значений в собственной валюте блокчейна (например, ETH). Выберите «Фиатная», чтобы установить приоритет отображения значений в выбранной фиатной валюте." - }, "primaryType": { "message": "Основной тип" }, diff --git a/app/_locales/sk/messages.json b/app/_locales/sk/messages.json index 238edf29c36e..4638a667c9f1 100644 --- a/app/_locales/sk/messages.json +++ b/app/_locales/sk/messages.json @@ -491,12 +491,6 @@ "prev": { "message": "Predchádzajúce" }, - "primaryCurrencySetting": { - "message": "Primárna mena" - }, - "primaryCurrencySettingDescription": { - "message": "Vyberte natívne, ak chcete priorizovať zobrazovanie hodnôt v natívnej mene reťazca (napr. ETH). Ak chcete priorizovať zobrazovanie hodnôt vo svojej vybranej mene fiat, zvoľte možnosť Fiat." - }, "privacyMsg": { "message": "Zásady ochrany osobních údajů" }, diff --git a/app/_locales/sl/messages.json b/app/_locales/sl/messages.json index ce63cc9ddb21..7379ac81b3f9 100644 --- a/app/_locales/sl/messages.json +++ b/app/_locales/sl/messages.json @@ -507,12 +507,6 @@ "prev": { "message": "Prej" }, - "primaryCurrencySetting": { - "message": "Glavna valuta" - }, - "primaryCurrencySettingDescription": { - "message": "Izberite Native za prikaz vrednosti v privzeti valuti verige (npr. ETH). Izberite Klasične za prikaz vrednosti v izbrani klasični valuti." - }, "privacyMsg": { "message": "Zasebnost" }, diff --git a/app/_locales/sr/messages.json b/app/_locales/sr/messages.json index 56d60832dfba..be81f85bd867 100644 --- a/app/_locales/sr/messages.json +++ b/app/_locales/sr/messages.json @@ -510,12 +510,6 @@ "prev": { "message": "Prethodno" }, - "primaryCurrencySetting": { - "message": "Primarna valuta" - }, - "primaryCurrencySettingDescription": { - "message": "Izaberite primarnu da biste postavili prioritete u prikazivanju vrednosti u primarnoj valuti lanca (npr. ETH). Izaberite Fiat da biste postavili prioritete u prikazivanju vrednosti u vašoj izabranoj fiat valuti." - }, "privacyMsg": { "message": "Smernice za privatnost" }, diff --git a/app/_locales/sv/messages.json b/app/_locales/sv/messages.json index 43de300985a6..96ca181fb43b 100644 --- a/app/_locales/sv/messages.json +++ b/app/_locales/sv/messages.json @@ -507,12 +507,6 @@ "prev": { "message": "Föregående" }, - "primaryCurrencySetting": { - "message": "Primär valuta" - }, - "primaryCurrencySettingDescription": { - "message": "Välj native för att prioritera visning av värden i den ursprungliga valutan i kedjan (t.ex. ETH). Välj Fiat för att prioritera visning av värden i din valda fiatvaluta." - }, "privacyMsg": { "message": "Integritetspolicy" }, diff --git a/app/_locales/sw/messages.json b/app/_locales/sw/messages.json index 65d2079d5990..1dd5c6603ba6 100644 --- a/app/_locales/sw/messages.json +++ b/app/_locales/sw/messages.json @@ -501,12 +501,6 @@ "prev": { "message": "Hakiki" }, - "primaryCurrencySetting": { - "message": "Sarafu ya Msingi" - }, - "primaryCurrencySettingDescription": { - "message": "Chagua mzawa ili kuweka kipaumbele kuonyesha thamani kwenye sarafu mzawa ya mnyororo (k.m ETH). Chagua Fiat ili uwelke kipaumbale kuonyesha thamani kwenye sarafu yako ya fiat uliyoichagua." - }, "privacyMsg": { "message": "Sera ya Faragha" }, diff --git a/app/_locales/tl/messages.json b/app/_locales/tl/messages.json index bf22f698b417..dac50a5bbece 100644 --- a/app/_locales/tl/messages.json +++ b/app/_locales/tl/messages.json @@ -3992,12 +3992,6 @@ "priceUnavailable": { "message": "hindi available ang presyo" }, - "primaryCurrencySetting": { - "message": "Pangunahing Currency" - }, - "primaryCurrencySettingDescription": { - "message": "Piliin ang native para maisapriyoridad ang pagpapakita ng mga value sa native na currency ng chain (hal. ETH). Piliin ang Fiat para maisapriyoridad ang pagpapakita ng mga value sa napili mong fiat na salapi." - }, "primaryType": { "message": "Pangunahing uri" }, diff --git a/app/_locales/tr/messages.json b/app/_locales/tr/messages.json index 0935ebbcc512..6267e8e5a077 100644 --- a/app/_locales/tr/messages.json +++ b/app/_locales/tr/messages.json @@ -3992,12 +3992,6 @@ "priceUnavailable": { "message": "fiyat mevcut değil" }, - "primaryCurrencySetting": { - "message": "Öncelikli para birimi" - }, - "primaryCurrencySettingDescription": { - "message": "Değerlerin zincirin yerli para biriminde (ör. ETH) görüntülenmesini önceliklendirmek için yerli seçimi yapın. Seçtiğiniz fiat parada değerlerin gösterilmesini önceliklendirmek için Fiat Para seçin." - }, "primaryType": { "message": "Öncelikli tür" }, diff --git a/app/_locales/uk/messages.json b/app/_locales/uk/messages.json index 3df0e035eebb..3d9de1c7203d 100644 --- a/app/_locales/uk/messages.json +++ b/app/_locales/uk/messages.json @@ -519,12 +519,6 @@ "prev": { "message": "Попередній" }, - "primaryCurrencySetting": { - "message": "Первісна валюта" - }, - "primaryCurrencySettingDescription": { - "message": "Оберіть \"рідна\", щоб пріоритезувати показ сум у рідних валютах мережі (напр.ETH). \nОберіть \"фіатна\", щоб пріоритезувати показ сум у ваших обраних фіатних валютах." - }, "privacyMsg": { "message": "Політика конфіденційності" }, diff --git a/app/_locales/vi/messages.json b/app/_locales/vi/messages.json index 3ec031773432..e9fe35668ec0 100644 --- a/app/_locales/vi/messages.json +++ b/app/_locales/vi/messages.json @@ -3992,12 +3992,6 @@ "priceUnavailable": { "message": "giá không khả dụng" }, - "primaryCurrencySetting": { - "message": "Tiền tệ chính" - }, - "primaryCurrencySettingDescription": { - "message": "Chọn Gốc để ưu tiên hiển thị giá trị bằng đơn vị tiền tệ gốc của chuỗi (ví dụ: ETH). Chọn Pháp định để ưu tiên hiển thị giá trị bằng đơn vị tiền pháp định mà bạn chọn." - }, "primaryType": { "message": "Loại chính" }, diff --git a/app/_locales/zh_CN/messages.json b/app/_locales/zh_CN/messages.json index de35cd696b5f..86b7eae47799 100644 --- a/app/_locales/zh_CN/messages.json +++ b/app/_locales/zh_CN/messages.json @@ -3992,12 +3992,6 @@ "priceUnavailable": { "message": "价格不可用" }, - "primaryCurrencySetting": { - "message": "主要货币" - }, - "primaryCurrencySettingDescription": { - "message": "选择原生以优先显示链的原生货币(例如 ETH)的值。选择法币以优先显示以您所选法币显示的值。" - }, "primaryType": { "message": "主要类型" }, diff --git a/app/_locales/zh_TW/messages.json b/app/_locales/zh_TW/messages.json index 558963373965..68ff3c234969 100644 --- a/app/_locales/zh_TW/messages.json +++ b/app/_locales/zh_TW/messages.json @@ -964,12 +964,6 @@ "prev": { "message": "前一頁" }, - "primaryCurrencySetting": { - "message": "主要貨幣" - }, - "primaryCurrencySettingDescription": { - "message": "選擇原生來優先使用鏈上原生貨幣 (例如 ETH) 顯示金額。選擇法定貨幣來優先使用您選擇的法定貨幣顯示金額。" - }, "privacyMsg": { "message": "隱私政策" }, diff --git a/app/scripts/controllers/app-state.js b/app/scripts/controllers/app-state.js index 08b11facf9ca..4ede462bdccb 100644 --- a/app/scripts/controllers/app-state.js +++ b/app/scripts/controllers/app-state.js @@ -74,6 +74,7 @@ export default class AppStateController extends EventEmitter { // States used for displaying the changed network toast switchedNetworkDetails: null, switchedNetworkNeverShowMessage: false, + shouldShowAggregatedBalancePopover: true, // by default user should see popover; currentExtensionPopupId: 0, lastInteractedConfirmationInfo: undefined, }); @@ -465,6 +466,16 @@ export default class AppStateController extends EventEmitter { }); } + /** + * Sets shouldShowAggregatedBalancePopover to false once the user toggles + * the setting to show native token as main balance. + */ + setAggregatedBalancePopoverShown() { + this.store.updateState({ + shouldShowAggregatedBalancePopover: false, + }); + } + /** * Sets a property indicating the model of the user's Trezor hardware wallet * diff --git a/app/scripts/metamask-controller.js b/app/scripts/metamask-controller.js index 0cceb966d5db..011204b57f19 100644 --- a/app/scripts/metamask-controller.js +++ b/app/scripts/metamask-controller.js @@ -3477,6 +3477,10 @@ export default class MetamaskController extends EventEmitter { appStateController.setSwitchedNetworkNeverShowMessage.bind( appStateController, ), + setAggregatedBalancePopoverShown: + appStateController.setAggregatedBalancePopoverShown.bind( + appStateController, + ), getLastInteractedConfirmationInfo: appStateController.getLastInteractedConfirmationInfo.bind( appStateController, diff --git a/test/e2e/tests/account/metamask-responsive-ui.spec.js b/test/e2e/tests/account/metamask-responsive-ui.spec.js index d9e9aa2f965c..c77bd6ae4566 100644 --- a/test/e2e/tests/account/metamask-responsive-ui.spec.js +++ b/test/e2e/tests/account/metamask-responsive-ui.spec.js @@ -75,7 +75,7 @@ describe('MetaMask Responsive UI', function () { const balance = await driver.findElement( '[data-testid="eth-overview__primary-currency"]', ); - assert.ok(/^0\sETH$/u.test(await balance.getText())); + assert.ok(/^0ETH$/u.test(await balance.getText())); }, ); }); diff --git a/test/e2e/tests/metrics/state-snapshots/errors-after-init-opt-in-background-state.json b/test/e2e/tests/metrics/state-snapshots/errors-after-init-opt-in-background-state.json index ba4faed1b82a..572f4cb334ce 100644 --- a/test/e2e/tests/metrics/state-snapshots/errors-after-init-opt-in-background-state.json +++ b/test/e2e/tests/metrics/state-snapshots/errors-after-init-opt-in-background-state.json @@ -29,6 +29,7 @@ "fullScreenGasPollTokens": "object", "recoveryPhraseReminderHasBeenShown": true, "recoveryPhraseReminderLastShown": "number", + "shouldShowAggregatedBalancePopover": "boolean", "outdatedBrowserWarningLastShown": "object", "nftsDetectionNoticeDismissed": false, "showTestnetMessageInDropdown": true, diff --git a/test/e2e/tests/metrics/state-snapshots/errors-after-init-opt-in-ui-state.json b/test/e2e/tests/metrics/state-snapshots/errors-after-init-opt-in-ui-state.json index 7c996effce3a..65688eb6fa8f 100644 --- a/test/e2e/tests/metrics/state-snapshots/errors-after-init-opt-in-ui-state.json +++ b/test/e2e/tests/metrics/state-snapshots/errors-after-init-opt-in-ui-state.json @@ -87,6 +87,7 @@ "currentMigrationVersion": "number", "balances": "object", "selectedNetworkClientId": "string", + "shouldShowAggregatedBalancePopover": "boolean", "networksMetadata": { "networkConfigurationId": { "EIPS": { "1559": false }, diff --git a/test/e2e/tests/settings/account-token-list.spec.js b/test/e2e/tests/settings/account-token-list.spec.js index eaa560633b2a..e696320fb4e6 100644 --- a/test/e2e/tests/settings/account-token-list.spec.js +++ b/test/e2e/tests/settings/account-token-list.spec.js @@ -79,8 +79,7 @@ describe('Settings', function () { '.eth-overview__primary-container', ); await driver.delay(1000); - assert.equal(await tokenListAmount.getText(), '$42,500.00\nUSD'); - + assert.equal(await tokenListAmount.getText(), '$42,500.00USD'); await driver.clickElement('[data-testid="account-menu-icon"]'); const accountTokenValue = await driver.waitForSelector( '.multichain-account-list-item .multichain-account-list-item__asset', diff --git a/test/e2e/tests/settings/localization.spec.js b/test/e2e/tests/settings/localization.spec.js index a57b94effa9b..57dbfd5f68cf 100644 --- a/test/e2e/tests/settings/localization.spec.js +++ b/test/e2e/tests/settings/localization.spec.js @@ -32,9 +32,8 @@ describe('Localization', function () { '[data-testid="eth-overview__primary-currency"]', ); const balanceText = await primaryBalance.getText(); - const [fiatAmount, fiatUnit] = balanceText.trim().split(/\s+/u); - assert.ok(fiatAmount.startsWith('₱')); - assert.equal(fiatUnit, 'PHP'); + assert.ok(balanceText.startsWith('₱')); + assert.ok(balanceText.endsWith('PHP')); }, ); }); diff --git a/test/e2e/tests/settings/settings-search.spec.js b/test/e2e/tests/settings/settings-search.spec.js index 9e7dceafabfa..e5310241fe81 100644 --- a/test/e2e/tests/settings/settings-search.spec.js +++ b/test/e2e/tests/settings/settings-search.spec.js @@ -9,7 +9,7 @@ const FixtureBuilder = require('../../fixture-builder'); describe('Settings Search', function () { const settingsSearch = { - general: 'Primary currency', + general: 'Show native token as main balance', advanced: 'State logs', contacts: 'Contacts', security: 'Reveal Secret', diff --git a/test/e2e/tests/transaction/send-eth.spec.js b/test/e2e/tests/transaction/send-eth.spec.js index 5c49bba0cf4e..21da51b60622 100644 --- a/test/e2e/tests/transaction/send-eth.spec.js +++ b/test/e2e/tests/transaction/send-eth.spec.js @@ -189,7 +189,9 @@ describe('Send ETH', function () { const balance = await driver.findElement( '[data-testid="eth-overview__primary-currency"]', ); - assert.ok(/^[\d.]+\sETH$/u.test(await balance.getText())); + + assert.ok(/^[\d.]+ETH$/u.test(await balance.getText())); + await driver.clickElement( '[data-testid="account-overview__activity-tab"]', ); @@ -220,7 +222,7 @@ describe('Send ETH', function () { const balance = await driver.findElement( '[data-testid="eth-overview__primary-currency"]', ); - assert.ok(/^[\d.]+\sETH$/u.test(await balance.getText())); + assert.ok(/^[\d.]+ETH$/u.test(await balance.getText())); await openActionMenuAndStartSendFlow(driver); // choose to scan via QR code @@ -437,7 +439,7 @@ describe('Send ETH', function () { const balance = await driver.findElement( '[data-testid="eth-overview__primary-currency"]', ); - assert.ok(/^[\d.]+\sETH$/u.test(await balance.getText())); + assert.ok(/^[\d.]+ETH$/u.test(await balance.getText())); await openActionMenuAndStartSendFlow(driver); diff --git a/ui/components/app/assets/token-cell/__snapshots__/token-cell.test.tsx.snap b/ui/components/app/assets/token-cell/__snapshots__/token-cell.test.tsx.snap index e40a15f69863..3d8322ba141e 100644 --- a/ui/components/app/assets/token-cell/__snapshots__/token-cell.test.tsx.snap +++ b/ui/components/app/assets/token-cell/__snapshots__/token-cell.test.tsx.snap @@ -52,7 +52,7 @@ exports[`Token Cell should match snapshot 1`] = ` class="mm-box mm-box--display-flex" >

@@ -67,7 +67,7 @@ exports[`Token Cell should match snapshot 1`] = ` 5.00

5 diff --git a/ui/components/app/modals/customize-nonce/__snapshots__/customize-nonce.test.js.snap b/ui/components/app/modals/customize-nonce/__snapshots__/customize-nonce.test.js.snap index cab80e399a43..020adaa0c952 100644 --- a/ui/components/app/modals/customize-nonce/__snapshots__/customize-nonce.test.js.snap +++ b/ui/components/app/modals/customize-nonce/__snapshots__/customize-nonce.test.js.snap @@ -75,7 +75,7 @@ exports[`Customize Nonce should match snapshot 1`] = ` class="MuiFormControl-root MuiTextField-root MuiFormControl-marginDense MuiFormControl-fullWidth" >

+$0.00

(+0.00%) diff --git a/ui/components/app/wallet-overview/aggregated-percentage-overview.tsx b/ui/components/app/wallet-overview/aggregated-percentage-overview.tsx index adbdf5c3c800..ef8e92989dda 100644 --- a/ui/components/app/wallet-overview/aggregated-percentage-overview.tsx +++ b/ui/components/app/wallet-overview/aggregated-percentage-overview.tsx @@ -17,7 +17,6 @@ import { Display, TextColor, TextVariant, - FontWeight, } from '../../../helpers/constants/design-system'; import { Box, Text } from '../../component-library'; import { getCalculatedTokenAmount1dAgo } from '../../../helpers/utils/util'; @@ -107,8 +106,7 @@ export const AggregatedPercentageOverview = () => { return ( { {formattedAmountChange} ; + +export const Default = Template.bind({}); diff --git a/ui/components/app/wallet-overview/coin-buttons.tsx b/ui/components/app/wallet-overview/coin-buttons.tsx index 5a8f1a1dea6f..42ddd4373fc3 100644 --- a/ui/components/app/wallet-overview/coin-buttons.tsx +++ b/ui/components/app/wallet-overview/coin-buttons.tsx @@ -60,7 +60,7 @@ import { IconColor, JustifyContent, } from '../../../helpers/constants/design-system'; -import { Box, Icon, IconName } from '../../component-library'; +import { Box, Icon, IconName, IconSize } from '../../component-library'; import IconButton from '../../ui/icon-button'; ///: BEGIN:ONLY_INCLUDE_IF(build-main,build-beta,build-flask) import useRamps from '../../../hooks/ramps/useRamps/useRamps'; @@ -79,6 +79,7 @@ const CoinButtons = ({ defaultSwapsToken, ///: END:ONLY_INCLUDE_IF classPrefix = 'coin', + iconButtonClassName = '', }: { chainId: `0x${string}` | CaipChainId | number; trackingLocation: string; @@ -90,6 +91,7 @@ const CoinButtons = ({ defaultSwapsToken?: SwapsEthToken; ///: END:ONLY_INCLUDE_IF classPrefix?: string; + iconButtonClassName?: string; }) => { const t = useContext(I18nContext); const dispatch = useDispatch(); @@ -191,15 +193,27 @@ const CoinButtons = ({ <> } + iconButtonClassName={iconButtonClassName} + Icon={ + + } label={t('stake')} onClick={handleMmiStakingOnClick} /> {mmiPortfolioEnabled && ( + } label={t('portfolio')} onClick={handleMmiPortfolioOnClick} @@ -308,8 +322,13 @@ const CoinButtons = ({ ///: BEGIN:ONLY_INCLUDE_IF(build-main,build-beta,build-flask) + } disabled={!isBuyableChain} data-testid={`${classPrefix}-overview-buy`} @@ -327,9 +346,9 @@ const CoinButtons = ({ renderInstitutionalButtons() ///: END:ONLY_INCLUDE_IF } - } onClick={handleSwapOnClick} @@ -350,10 +370,15 @@ const CoinButtons = ({ ///: BEGIN:ONLY_INCLUDE_IF(build-main,build-beta,build-flask) + } label={t('bridge')} onClick={handleBridgeOnClick} @@ -365,11 +390,13 @@ const CoinButtons = ({ } } disabled={!isSigningEnabled} @@ -389,11 +416,13 @@ const CoinButtons = ({ )} } label={t('receive')} diff --git a/ui/components/app/wallet-overview/coin-overview.tsx b/ui/components/app/wallet-overview/coin-overview.tsx index aed0fde5eeea..b67311403309 100644 --- a/ui/components/app/wallet-overview/coin-overview.tsx +++ b/ui/components/app/wallet-overview/coin-overview.tsx @@ -1,11 +1,28 @@ -import React, { useContext, useCallback } from 'react'; -import { useSelector } from 'react-redux'; +import React, { useContext, useCallback, useState } from 'react'; +import { useDispatch, useSelector } from 'react-redux'; import classnames from 'classnames'; import { zeroAddress } from 'ethereumjs-util'; import { CaipChainId } from '@metamask/utils'; import type { Hex } from '@metamask/utils'; -import { Icon, IconName, IconSize } from '../../component-library'; -import { IconColor } from '../../../helpers/constants/design-system'; +import { + Box, + ButtonIcon, + ButtonIconSize, + ButtonLink, + ButtonLinkSize, + IconName, + Popover, + PopoverPosition, + Text, +} from '../../component-library'; +import { + AlignItems, + BlockSize, + Display, + JustifyContent, + TextAlign, + TextVariant, +} from '../../../helpers/constants/design-system'; import { MetaMetricsContext } from '../../../contexts/metametrics'; import { MetaMetricsEventCategory, @@ -18,12 +35,14 @@ import UserPreferencedCurrencyDisplay from '../user-preferenced-currency-display import { PRIMARY } from '../../../helpers/constants/common'; import { getDataCollectionForMarketing, + getShouldShowAggregatedBalancePopover, getMetaMetricsId, getParticipateInMetaMetrics, getPreferences, getSelectedAccount, getShouldHideZeroBalanceTokens, getTokensMarketData, + getIsTestnet, ///: BEGIN:ONLY_INCLUDE_IF(build-main,build-beta,build-flask) SwapsEthToken, ///: END:ONLY_INCLUDE_IF @@ -33,6 +52,9 @@ import Spinner from '../../ui/spinner'; import { PercentageAndAmountChange } from '../../multichain/token-list-item/price/percentage-and-amount-change/percentage-and-amount-change'; import { getMultichainIsEvm } from '../../../selectors/multichain'; import { useAccountTotalFiatBalance } from '../../../hooks/useAccountTotalFiatBalance'; +import { setAggregatedBalancePopover } from '../../../store/actions'; +import { useTheme } from '../../../hooks/useTheme'; +import { getSpecificSettingsRoute } from '../../../helpers/utils/settings-search'; import WalletOverview from './wallet-overview'; import CoinButtons from './coin-buttons'; import { AggregatedPercentageOverview } from './aggregated-percentage-overview'; @@ -75,11 +97,22 @@ export const CoinOverview = ({ ///: END:ONLY_INCLUDE_IF const t = useContext(I18nContext); + const dispatch = useDispatch(); const trackEvent = useContext(MetaMetricsContext); + const showNativeTokenAsMainBalanceRoute = getSpecificSettingsRoute( + t, + t('general'), + t('showNativeTokenAsMainBalance'), + ); + const metaMetricsId = useSelector(getMetaMetricsId); const isMetaMetricsEnabled = useSelector(getParticipateInMetaMetrics); const isMarketingEnabled = useSelector(getDataCollectionForMarketing); + const theme = useTheme(); + + const shouldShowPopover = useSelector(getShouldShowAggregatedBalancePopover); + const isTestnet = useSelector(getIsTestnet); const selectedAccount = useSelector(getSelectedAccount); const shouldHideZeroBalanceTokens = useSelector( @@ -94,9 +127,28 @@ export const CoinOverview = ({ const isEvm = useSelector(getMultichainIsEvm); const balanceToDisplay = - showNativeTokenAsMainBalance || !isEvm ? balance : totalFiatBalance; + showNativeTokenAsMainBalance || isTestnet || !isEvm + ? balance + : totalFiatBalance; const tokensMarketData = useSelector(getTokensMarketData); + const [isOpen, setIsOpen] = useState(true); + + const handleMouseEnter = () => { + setIsOpen(true); + }; + + const handleClick = () => { + setIsOpen(!isOpen); + dispatch(setAggregatedBalancePopover()); + }; + + const [referenceElement, setReferenceElement] = useState(); + + // eslint-disable-next-line @typescript-eslint/no-explicit-any + const setBoxRef = (ref: any) => { + setReferenceElement(ref); + }; const handlePortfolioOnClick = useCallback(() => { const url = getPortfolioUrl( @@ -121,12 +173,37 @@ export const CoinOverview = ({ if (isEvm) { if (showNativeTokenAsMainBalance) { return ( - + + + + + {t('portfolio')} + + ); } - return ; + return ( + + + + {t('portfolio')} + + + ); } return null; }; @@ -142,25 +219,91 @@ export const CoinOverview = ({

{balanceToDisplay ? ( - + <> + + + + {shouldShowPopover && + !isTestnet && + !showNativeTokenAsMainBalance ? ( + + + + + {t('yourBalanceIsAggregated')} + + + + + + { + // eslint-disable-next-line @typescript-eslint/ban-ts-comment + // @ts-ignore: Expected 0-1 arguments, but got 2. + t('aggregatedBalancePopover', [ + + {t('settings')} + , + ]) + } + + + + ) : null} + ) : ( )} @@ -170,20 +313,6 @@ export const CoinOverview = ({ )}
-
-
- {t('portfolio')} - -
-
{renderPercentageAndAmountChange()}
@@ -201,6 +330,7 @@ export const CoinOverview = ({ defaultSwapsToken, ///: END:ONLY_INCLUDE_IF classPrefix, + iconButtonClassName: `${classPrefix}-overview__icon-button`, }} /> } diff --git a/ui/components/app/wallet-overview/index.scss b/ui/components/app/wallet-overview/index.scss index bbbf57075c24..32135fac6fda 100644 --- a/ui/components/app/wallet-overview/index.scss +++ b/ui/components/app/wallet-overview/index.scss @@ -3,11 +3,9 @@ .wallet-overview { display: flex; justify-content: space-between; - align-items: center; + align-items: start; flex: 1; - min-height: 209px; min-width: 0; - padding-top: 10px; flex-direction: column; width: 100%; @@ -16,30 +14,26 @@ display: flex; gap: 4px; flex-direction: column; - align-items: center; + align-items: start; width: 100%; } - &__buttons { - display: flex; - flex-direction: row; - height: 68px; - margin-bottom: 24px; + &__icon_button { + margin-top: 0 !important; } - &__portfolio_button { + &__buttons { display: flex; flex-direction: row; - gap: 6px; - cursor: pointer; - align-items: center; - color: var(--color-primary-default); + height: 100%; + margin-bottom: 16px; + padding: 0 16px; } &__currency-wrapper { display: flex; flex-direction: row; - gap: 10px; + gap: 8px; } } @@ -61,14 +55,17 @@ display: flex; flex-direction: column; min-width: 0; - gap: 4px; position: relative; - align-items: center; + align-items: start; margin: 16px 0; padding: 0 16px; max-width: 326px; } + &__icon-button { + margin-top: 0 !important; + } + &__primary-container { display: flex; max-width: inherit; @@ -80,17 +77,13 @@ @include design-system.H2; color: var(--color-text-default); + font-weight: 700; } &__cached-star { margin-left: 4px; } - &__portfolio-button { - height: inherit; - padding-inline-start: 16px; - } - &__cached-balance, &__cached-star { color: var(--color-warning-default); @@ -158,12 +151,13 @@ color: var(--color-text-alternative); } - &__portfolio-button { - height: inherit; - padding-inline-start: 16px; - } - &__button:last-of-type { margin-right: 0; } } + +.balance-popover { + &__container { + z-index: design-system.$modal-z-index; + } +} diff --git a/ui/components/multichain/token-list-item/__snapshots__/token-list-item.test.tsx.snap b/ui/components/multichain/token-list-item/__snapshots__/token-list-item.test.tsx.snap index 5c75df62eef1..1330a1490244 100644 --- a/ui/components/multichain/token-list-item/__snapshots__/token-list-item.test.tsx.snap +++ b/ui/components/multichain/token-list-item/__snapshots__/token-list-item.test.tsx.snap @@ -59,7 +59,7 @@ exports[`TokenListItem should render correctly 1`] = ` data-testid="multichain-token-list-item-secondary-value" />

diff --git a/ui/components/multichain/token-list-item/price/percentage-and-amount-change/__snapshots__/percentage-and-amount-change.test.tsx.snap b/ui/components/multichain/token-list-item/price/percentage-and-amount-change/__snapshots__/percentage-and-amount-change.test.tsx.snap index e8ca2345490f..7f88ca5456ec 100644 --- a/ui/components/multichain/token-list-item/price/percentage-and-amount-change/__snapshots__/percentage-and-amount-change.test.tsx.snap +++ b/ui/components/multichain/token-list-item/price/percentage-and-amount-change/__snapshots__/percentage-and-amount-change.test.tsx.snap @@ -6,14 +6,14 @@ exports[`PercentageChange Component render renders correctly 1`] = ` class="mm-box mm-box--display-flex" >

+$12.21

(+5.12%) diff --git a/ui/components/multichain/token-list-item/price/percentage-and-amount-change/percentage-and-amount-change.tsx b/ui/components/multichain/token-list-item/price/percentage-and-amount-change/percentage-and-amount-change.tsx index 2d4a7341cad4..daff27d6cddf 100644 --- a/ui/components/multichain/token-list-item/price/percentage-and-amount-change/percentage-and-amount-change.tsx +++ b/ui/components/multichain/token-list-item/price/percentage-and-amount-change/percentage-and-amount-change.tsx @@ -5,7 +5,6 @@ import { isHexString, zeroAddress } from 'ethereumjs-util'; import { Text, Box } from '../../../../component-library'; import { Display, - FontWeight, TextColor, TextVariant, } from '../../../../../helpers/constants/design-system'; @@ -34,8 +33,7 @@ export const renderPercentageWithNumber = ( return (

+5.12% diff --git a/ui/components/multichain/token-list-item/price/percentage-change/percentage-change.tsx b/ui/components/multichain/token-list-item/price/percentage-change/percentage-change.tsx index bec1857012b1..e540db80a8f1 100644 --- a/ui/components/multichain/token-list-item/price/percentage-change/percentage-change.tsx +++ b/ui/components/multichain/token-list-item/price/percentage-change/percentage-change.tsx @@ -2,7 +2,6 @@ import React from 'react'; import { Box, Text } from '../../../../component-library'; import { Display, - FontWeight, TextColor, TextVariant, } from '../../../../../helpers/constants/design-system'; @@ -35,8 +34,7 @@ export const PercentageChange = ({ return ( {primary} {isNativeCurrency ? '' : tokenSymbol} diff --git a/ui/components/ui/dropdown/dropdown.scss b/ui/components/ui/dropdown/dropdown.scss index 53e06559b541..395a61b68eee 100644 --- a/ui/components/ui/dropdown/dropdown.scss +++ b/ui/components/ui/dropdown/dropdown.scss @@ -3,7 +3,7 @@ .dropdown { position: relative; display: inline-block; - height: 36px; + height: 48px; &__select { appearance: none; diff --git a/ui/components/ui/icon-button/icon-button.js b/ui/components/ui/icon-button/icon-button.js index 69830128ebcd..30b14c0aa205 100644 --- a/ui/components/ui/icon-button/icon-button.js +++ b/ui/components/ui/icon-button/icon-button.js @@ -16,6 +16,7 @@ export default function IconButton(props) { label, tooltipRender, className, + iconButtonClassName = '', ...otherProps } = props; const renderWrapper = tooltipRender ?? defaultRender; @@ -31,7 +32,10 @@ export default function IconButton(props) { > {renderWrapper( <> -

+
{Icon}
{label.length > 10 ? ( @@ -66,5 +70,6 @@ IconButton.propTypes = { label: PropTypes.string.isRequired, tooltipRender: PropTypes.func, className: PropTypes.string, + iconButtonClassName: PropTypes.string, 'data-testid': PropTypes.string, }; diff --git a/ui/components/ui/icon-button/icon-button.scss b/ui/components/ui/icon-button/icon-button.scss index 97529366befa..e09373b23744 100644 --- a/ui/components/ui/icon-button/icon-button.scss +++ b/ui/components/ui/icon-button/icon-button.scss @@ -6,11 +6,11 @@ align-items: center; background-color: unset; text-align: center; - width: 60px; + width: 64px; @include design-system.H7; - font-size: 13px; + font-size: 12px; cursor: pointer; color: var(--color-primary-default); @@ -21,9 +21,9 @@ height: 36px; width: 36px; background: var(--color-primary-default); - border-radius: 18px; + border-radius: 99px; margin-top: 6px; - margin-bottom: 5px; + margin-bottom: 4px; margin-inline: auto; } diff --git a/ui/components/ui/text-field/text-field.component.js b/ui/components/ui/text-field/text-field.component.js index a7637e76a729..e80d5e43fc73 100644 --- a/ui/components/ui/text-field/text-field.component.js +++ b/ui/components/ui/text-field/text-field.component.js @@ -77,13 +77,15 @@ const styles = { border: '1px solid var(--color-border-default)', color: 'var(--color-text-default)', height: '48px', - borderRadius: '6px', padding: '0 16px', display: 'flex', alignItems: 'center', '&$inputFocused': { border: '1px solid var(--color-primary-default)', }, + borderRadius: '8px', + fontSize: '0.875rem', + fontFamily: 'Euclid Circular B, Roboto, Helvetica, Arial, sans-serif', }, largeInputLabel: { ...inputLabelBase, @@ -203,6 +205,7 @@ const getBorderedThemeInputProps = ({ max, autoComplete, }, + disableUnderline: 'true', }, }); diff --git a/ui/helpers/constants/settings.js b/ui/helpers/constants/settings.js index f4529ed1d6ad..569999f8900e 100644 --- a/ui/helpers/constants/settings.js +++ b/ui/helpers/constants/settings.js @@ -34,9 +34,9 @@ const SETTINGS_CONSTANTS = [ }, { tabMessage: (t) => t('general'), - sectionMessage: (t) => t('primaryCurrencySetting'), - descriptionMessage: (t) => t('primaryCurrencySettingDescription'), - route: `${GENERAL_ROUTE}#primary-currency`, + sectionMessage: (t) => t('showNativeTokenAsMainBalance'), + descriptionMessage: (t) => t('showNativeTokenAsMainBalance'), + route: `${GENERAL_ROUTE}#show-native-token-as-main-balance`, iconName: IconName.Setting, }, { diff --git a/ui/helpers/utils/settings-search.js b/ui/helpers/utils/settings-search.js index 447a39901059..af13e1d71c65 100644 --- a/ui/helpers/utils/settings-search.js +++ b/ui/helpers/utils/settings-search.js @@ -25,6 +25,15 @@ function getFilteredSettingsRoutes(t, tabMessage) { }); } +export function getSpecificSettingsRoute(t, tabMessage, sectionMessage) { + return getSettingsRoutes().find((routeObject) => { + return ( + routeObject.tabMessage(t) === tabMessage && + routeObject.sectionMessage(t) === sectionMessage + ); + }); +} + /** * @param {Function} t - context.t function * @param {string} tabMessage diff --git a/ui/helpers/utils/settings-search.test.js b/ui/helpers/utils/settings-search.test.js index 709b0354a4e7..1e440b8f0aff 100644 --- a/ui/helpers/utils/settings-search.test.js +++ b/ui/helpers/utils/settings-search.test.js @@ -4,6 +4,7 @@ import { getSettingsRoutes, getNumberOfSettingRoutesInTab, handleSettingsRefs, + getSpecificSettingsRoute, } from './settings-search'; const t = (key) => { @@ -209,4 +210,17 @@ describe('Settings Search Utils', () => { expect(handleSettingsRefs(t, t('general'), settingsRefs)).toBeUndefined(); }); }); + + describe('getSpecificSettingsRoute', () => { + it('should return show native token as main balance route', () => { + const result = getSpecificSettingsRoute( + t, + t('general'), + t('showNativeTokenAsMainBalance'), + ); + expect(result.route).toBe( + '/settings/general#show-native-token-as-main-balance', + ); + }); + }); }); diff --git a/ui/pages/asset/components/__snapshots__/asset-page.test.tsx.snap b/ui/pages/asset/components/__snapshots__/asset-page.test.tsx.snap index ef6e6331d2ba..95828e3e250e 100644 --- a/ui/pages/asset/components/__snapshots__/asset-page.test.tsx.snap +++ b/ui/pages/asset/components/__snapshots__/asset-page.test.tsx.snap @@ -43,7 +43,7 @@ exports[`AssetPage should render a native asset 1`] = ` data-theme="light" >
@@ -61,7 +61,7 @@ exports[`AssetPage should render a native asset 1`] = ` data-theme="light" >
@@ -79,7 +79,7 @@ exports[`AssetPage should render a native asset 1`] = ` data-theme="light" > @@ -99,7 +99,7 @@ exports[`AssetPage should render a native asset 1`] = ` data-theme="light" > @@ -118,7 +118,7 @@ exports[`AssetPage should render a native asset 1`] = ` data-theme="light" > @@ -137,7 +137,7 @@ exports[`AssetPage should render a native asset 1`] = ` data-theme="light" > @@ -156,7 +156,7 @@ exports[`AssetPage should render a native asset 1`] = ` data-theme="light" > @@ -236,7 +236,7 @@ exports[`AssetPage should render a native asset 1`] = ` data-testid="multichain-token-list-item-secondary-value" />

0 TEST @@ -352,7 +352,7 @@ exports[`AssetPage should render an ERC20 asset without prices 1`] = ` data-theme="light" > @@ -371,7 +371,7 @@ exports[`AssetPage should render an ERC20 asset without prices 1`] = ` data-theme="light" > @@ -390,7 +390,7 @@ exports[`AssetPage should render an ERC20 asset without prices 1`] = ` data-theme="light" > @@ -409,7 +409,7 @@ exports[`AssetPage should render an ERC20 asset without prices 1`] = ` data-theme="light" > @@ -427,7 +427,7 @@ exports[`AssetPage should render an ERC20 asset without prices 1`] = ` data-theme="light" > @@ -446,7 +446,7 @@ exports[`AssetPage should render an ERC20 asset without prices 1`] = ` data-theme="light" > @@ -515,7 +515,7 @@ exports[`AssetPage should render an ERC20 asset without prices 1`] = ` class="mm-box mm-box--display-flex" >

@@ -528,7 +528,7 @@ exports[`AssetPage should render an ERC20 asset without prices 1`] = ` data-testid="multichain-token-list-item-secondary-value" />

0 @@ -835,7 +835,7 @@ exports[`AssetPage should render an ERC20 token with prices 1`] = ` data-theme="light" > @@ -854,7 +854,7 @@ exports[`AssetPage should render an ERC20 token with prices 1`] = ` data-theme="light" > @@ -873,7 +873,7 @@ exports[`AssetPage should render an ERC20 token with prices 1`] = ` data-theme="light" > @@ -892,7 +892,7 @@ exports[`AssetPage should render an ERC20 token with prices 1`] = ` data-theme="light" > @@ -910,7 +910,7 @@ exports[`AssetPage should render an ERC20 token with prices 1`] = ` data-theme="light" > @@ -929,7 +929,7 @@ exports[`AssetPage should render an ERC20 token with prices 1`] = ` data-theme="light" > @@ -998,7 +998,7 @@ exports[`AssetPage should render an ERC20 token with prices 1`] = ` class="mm-box mm-box--display-flex" >

@@ -1011,7 +1011,7 @@ exports[`AssetPage should render an ERC20 token with prices 1`] = ` data-testid="multichain-token-list-item-secondary-value" />

0 diff --git a/ui/pages/asset/components/token-buttons.tsx b/ui/pages/asset/components/token-buttons.tsx index a07cdaca2d48..bb3f129bade8 100644 --- a/ui/pages/asset/components/token-buttons.tsx +++ b/ui/pages/asset/components/token-buttons.tsx @@ -48,7 +48,12 @@ import { JustifyContent, } from '../../../helpers/constants/design-system'; import IconButton from '../../../components/ui/icon-button/icon-button'; -import { Box, Icon, IconName } from '../../../components/component-library'; +import { + Box, + Icon, + IconName, + IconSize, +} from '../../../components/component-library'; ///: BEGIN:ONLY_INCLUDE_IF(build-main,build-beta,build-flask) import { getIsNativeTokenBuyable } from '../../../ducks/ramps'; ///: END:ONLY_INCLUDE_IF @@ -115,7 +120,11 @@ const TokenButtons = ({ + } label={t('buyAndSell')} data-testid="token-overview-buy" @@ -144,7 +153,11 @@ const TokenButtons = ({ + } label={t('stake')} data-testid="token-overview-mmi-stake" @@ -163,6 +176,7 @@ const TokenButtons = ({ } label={t('portfolio')} @@ -215,6 +229,7 @@ const TokenButtons = ({ } label={t('send')} @@ -229,6 +244,7 @@ const TokenButtons = ({ } onClick={() => { @@ -281,7 +297,11 @@ const TokenButtons = ({ className="token-overview__button" data-testid="token-overview-bridge" Icon={ - + } label={t('bridge')} onClick={() => { diff --git a/ui/pages/home/index.scss b/ui/pages/home/index.scss index 03b4cd5d7cf9..5a85a3eb5d3c 100644 --- a/ui/pages/home/index.scss +++ b/ui/pages/home/index.scss @@ -20,6 +20,7 @@ min-width: 0; display: flex; flex-direction: column; + padding-top: 8px; } &__connect-status-text { diff --git a/ui/pages/settings/advanced-tab/__snapshots__/advanced-tab.component.test.js.snap b/ui/pages/settings/advanced-tab/__snapshots__/advanced-tab.component.test.js.snap index fcc11ec8336b..6318abd37570 100644 --- a/ui/pages/settings/advanced-tab/__snapshots__/advanced-tab.component.test.js.snap +++ b/ui/pages/settings/advanced-tab/__snapshots__/advanced-tab.component.test.js.snap @@ -501,7 +501,7 @@ exports[`AdvancedTab Component should match snapshot 1`] = ` class="MuiFormControl-root MuiTextField-root MuiFormControl-marginDense MuiFormControl-fullWidth" >

{ return ( - + ); }; @@ -73,7 +79,11 @@ export default function SettingsSearch({ onClick={() => handleSearch('')} style={{ cursor: 'pointer' }} > - + )} @@ -93,6 +103,7 @@ export default function SettingsSearch({ autoComplete="off" startAdornment={renderStartAdornment()} endAdornment={renderEndAdornment()} + theme="bordered" /> ); } diff --git a/ui/pages/settings/settings-tab/settings-tab.component.js b/ui/pages/settings/settings-tab/settings-tab.component.js index 53e4d282c788..c1bf514d7dc1 100644 --- a/ui/pages/settings/settings-tab/settings-tab.component.js +++ b/ui/pages/settings/settings-tab/settings-tab.component.js @@ -9,7 +9,6 @@ import { FlexDirection, JustifyContent, AlignItems, - FontWeight, } from '../../../helpers/constants/design-system'; import Dropdown from '../../../components/ui/dropdown'; import ToggleButton from '../../../components/ui/toggle-button'; @@ -103,8 +102,7 @@ export default class SettingsTab extends PureComponent {
{t('currencyConversion')} @@ -144,8 +142,7 @@ export default class SettingsTab extends PureComponent {
{t('currentLanguage')} @@ -187,8 +184,7 @@ export default class SettingsTab extends PureComponent {
{t('hideZeroBalanceTokens')} @@ -229,20 +225,16 @@ export default class SettingsTab extends PureComponent {
{t('accountIdenticon')} {t('jazzAndBlockies')} @@ -348,8 +340,7 @@ export default class SettingsTab extends PureComponent {
{t('showNativeTokenAsMainBalance')} @@ -410,9 +401,8 @@ export default class SettingsTab extends PureComponent {
{this.context.t('theme')} diff --git a/ui/pages/swaps/dropdown-input-pair/__snapshots__/dropdown-input-pair.test.js.snap b/ui/pages/swaps/dropdown-input-pair/__snapshots__/dropdown-input-pair.test.js.snap index 01a3a89ad4c5..d58907ed2684 100644 --- a/ui/pages/swaps/dropdown-input-pair/__snapshots__/dropdown-input-pair.test.js.snap +++ b/ui/pages/swaps/dropdown-input-pair/__snapshots__/dropdown-input-pair.test.js.snap @@ -5,7 +5,7 @@ exports[`DropdownInputPair renders the component with initial props 1`] = ` class="MuiFormControl-root MuiTextField-root dropdown-input-pair__input MuiFormControl-marginDense MuiFormControl-fullWidth" >
{ diff --git a/ui/store/actions.ts b/ui/store/actions.ts index d7184c569e51..647d7fa1343b 100644 --- a/ui/store/actions.ts +++ b/ui/store/actions.ts @@ -4849,6 +4849,10 @@ export function neverShowSwitchedNetworkMessage() { ]); } +export function setAggregatedBalancePopover() { + return submitRequestToBackground('setAggregatedBalancePopoverShown'); +} + /** * Sends the background state the networkClientId and domain upon network switch *