Skip to content

Commit

Permalink
fix(ui): various ui fixes (#1070)
Browse files Browse the repository at this point in the history
Description
---

- changed airdrop buttons from text buttons to more obvious looking
buttons + style tweaks
- prevent updating seed words if no changes were made 
  - checking `isDirty` and only enable button if yes
- if `isDirty` but seed words were only removed and pasted back (not
changed at all) do nothing
- add a confirmation modal if you are about to update the seed words 
- fixed emoji id address lineheight

Motivation and Context
---
- #968
- #960
- #943

How Has This Been Tested?
---

- locally


https://github.com/user-attachments/assets/972c463d-fe09-4d92-86cb-f40b31cab3ed


https://github.com/user-attachments/assets/bfced277-00b1-4dfb-89f0-305a405ea2fc


<img width="1121" alt="image"
src="https://github.com/user-attachments/assets/5669fbf3-8382-4af2-ba89-624621fe3913">

What process can a PR reviewer use to test or verify this change?
---

- [ ] check if airdrop settings buttons look properly clickable
- [ ] check that seedwords aren't updated if you've not made any changes
to them
- [ ] check that you are prompted to confirm before updating if you have
indeed made changes to the seedwords
- [ ] check that the tari address is not smushed


Breaking Changes
---

- [x] None
  • Loading branch information
shanimal08 authored Nov 18, 2024
1 parent 3d15a0d commit 20a9218
Show file tree
Hide file tree
Showing 21 changed files with 252 additions and 177 deletions.
26 changes: 14 additions & 12 deletions public/locales/af/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,23 @@
"applyInviteCode": "Pas Uitnodigingskode Toe",
"cancel": "Cancel",
"change-language": "Verander taal",
"confirm-import-wallet": "Abandon current wallet?",
"confirm-import-wallet-copy": "Are you sure you want to import a new wallet?",
"connected-peers": "Gekoppelde Eweknieë",
"connected-to-tari": "Gekoppel aan die Tari Netwerk",
"control-port": "Beheerpoort",
"cpu-mining-enabled": "SVE Mynbou",
"custom-power-levels": {
"choose-cpu-power-level": "Kies hoeveel jy wil hê jou SVE moet aan mynbou toegewys word <span>({{current}} uit {{max}} kerns)</span>",
"choose-gpu-power-level": "Kies hoeveel jy wil hê jou GPU moet aan mynbou toegewys word <span>({{current}} uit {{max}} drade)</span>",
"cpu-power-level": "SVE Kerns",
"cpu-warning": "Hoë SVE-gebruik kan oorverhitting veroorsaak, energieverbruik verhoog, en kan oor tyd tot hardeware skade lei. Monitor asseblief gebruik om veilige en doeltreffende werking te verseker.",
"gpu-power-level": "GPU Krag %",
"gpu-warning": "Hoë GPU-gebruik kan oorverhitting veroorsaak, energieverbruik verhoog, en kan oor tyd tot hardeware skade lei. Monitor asseblief gebruik om veilige en doeltreffende werking te verseker.",
"saved": "Veranderinge Toepas",
"title": "Pasgemaakte Modus",
"warning": "Waarskuwing"
},
"debug-info": "Ontfoutingsinligting",
"disconnect": "Ontkoppel van Airdrop",
"errors": {
Expand Down Expand Up @@ -115,16 +128,5 @@
"visual-mode": "Visuele modus",
"yes": "Yes",
"your-feedback": "Beskryf asseblief u probleem",
"your-reference": "U verwysing",
"custom-power-levels": {
"title": "Pasgemaakte Modus",
"warning": "Waarskuwing",
"saved": "Veranderinge Toepas",
"gpu-power-level": "GPU Krag %",
"cpu-power-level": "SVE Kerns",
"choose-gpu-power-level": "Kies hoeveel jy wil hê jou GPU moet aan mynbou toegewys word <span>({{current}} uit {{max}} drade)</span>",
"choose-cpu-power-level": "Kies hoeveel jy wil hê jou SVE moet aan mynbou toegewys word <span>({{current}} uit {{max}} kerns)</span>",
"cpu-warning": "Hoë SVE-gebruik kan oorverhitting veroorsaak, energieverbruik verhoog, en kan oor tyd tot hardeware skade lei. Monitor asseblief gebruik om veilige en doeltreffende werking te verseker.",
"gpu-warning": "Hoë GPU-gebruik kan oorverhitting veroorsaak, energieverbruik verhoog, en kan oor tyd tot hardeware skade lei. Monitor asseblief gebruik om veilige en doeltreffende werking te verseker."
}
"your-reference": "U verwysing"
}
26 changes: 14 additions & 12 deletions public/locales/cn/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,23 @@
"applyInviteCode": "应用邀请代码",
"cancel": "取消",
"change-language": "更改语言",
"confirm-import-wallet": "Abandon current wallet?",
"confirm-import-wallet-copy": "Are you sure you want to import a new wallet?",
"connected-peers": "已连接的节点",
"connected-to-tari": "已连接到Tari网络",
"control-port": "控制端口",
"cpu-mining-enabled": "CPU 挖矿",
"custom-power-levels": {
"choose-cpu-power-level": "选择您希望分配给挖矿的CPU数量 <span>({{current}} / {{max}} 核心)</span>",
"choose-gpu-power-level": "选择您希望分配给挖矿的GPU数量 <span>({{current}} / {{max}} 线程)</span>",
"cpu-power-level": "CPU核心",
"cpu-warning": "高CPU使用率可能导致过热、增加能耗,并可能导致硬件损坏。请监控使用情况以确保安全高效的操作。",
"gpu-power-level": "GPU功率%",
"gpu-warning": "高GPU使用率可能导致过热、增加能耗,并可能导致硬件损坏。请监控使用情况以确保安全高效的操作。",
"saved": "应用更改",
"title": "自定义模式",
"warning": "警告"
},
"debug-info": "调试信息",
"disconnect": "断开与空投的连接",
"errors": {
Expand Down Expand Up @@ -115,16 +128,5 @@
"visual-mode": "视觉模式",
"yes": "",
"your-feedback": "请描述您的问题",
"your-reference": "您的参考",
"custom-power-levels": {
"title": "自定义模式",
"warning": "警告",
"saved": "应用更改",
"gpu-power-level": "GPU功率%",
"cpu-power-level": "CPU核心",
"choose-gpu-power-level": "选择您希望分配给挖矿的GPU数量 <span>({{current}} / {{max}} 线程)</span>",
"choose-cpu-power-level": "选择您希望分配给挖矿的CPU数量 <span>({{current}} / {{max}} 核心)</span>",
"cpu-warning": "高CPU使用率可能导致过热、增加能耗,并可能导致硬件损坏。请监控使用情况以确保安全高效的操作。",
"gpu-warning": "高GPU使用率可能导致过热、增加能耗,并可能导致硬件损坏。请监控使用情况以确保安全高效的操作。"
}
"your-reference": "您的参考"
}
26 changes: 14 additions & 12 deletions public/locales/de/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,23 @@
"applyInviteCode": "Einladungscode anwenden",
"cancel": "Abbrechen",
"change-language": "Sprache",
"confirm-import-wallet": "Abandon current wallet?",
"confirm-import-wallet-copy": "Are you sure you want to import a new wallet?",
"connected-peers": "Verbundenen Peers",
"connected-to-tari": "Mit dem Tari-Netzwerk verbunden",
"control-port": "Steuerport",
"cpu-mining-enabled": "CPU-Mining",
"custom-power-levels": {
"choose-cpu-power-level": "Wählen Sie, wie viel Ihrer CPU für das Mining zugewiesen werden soll <span>({{current}} von {{max}} Kernen)</span>",
"choose-gpu-power-level": "Wählen Sie, wie viel Ihrer GPU für das Mining zugewiesen werden soll <span>({{current}} von {{max}} Threads)</span>",
"cpu-power-level": "CPU-Kerne",
"cpu-warning": "Hohe CPU-Nutzung kann Überhitzung verursachen, den Energieverbrauch erhöhen und im Laufe der Zeit zu Hardwareschäden führen. Bitte überwachen Sie die Nutzung, um einen sicheren und effizienten Betrieb zu gewährleisten.",
"gpu-power-level": "GPU-Leistung %",
"gpu-warning": "Hohe GPU-Nutzung kann Überhitzung verursachen, den Energieverbrauch erhöhen und im Laufe der Zeit zu Hardwareschäden führen. Bitte überwachen Sie die Nutzung, um einen sicheren und effizienten Betrieb zu gewährleisten.",
"saved": "Änderungen werden übernommen",
"title": "Benutzerdefinierter Modus",
"warning": "Warnung"
},
"debug-info": "Debuggen",
"disconnect": "Von Airdrop trennen",
"errors": {
Expand Down Expand Up @@ -115,16 +128,5 @@
"visual-mode": "Visueller Modus",
"yes": "Ja",
"your-feedback": "Beschreibe dein Problem, einschließlich deines Telegram-Namens, falls vorhanden, damit wir dich mit Updates kontaktieren können.",
"your-reference": "Dein Verweis:<br/><bold>{{logRef}}</bold>",
"custom-power-levels": {
"title": "Benutzerdefinierter Modus",
"warning": "Warnung",
"saved": "Änderungen werden übernommen",
"gpu-power-level": "GPU-Leistung %",
"cpu-power-level": "CPU-Kerne",
"choose-gpu-power-level": "Wählen Sie, wie viel Ihrer GPU für das Mining zugewiesen werden soll <span>({{current}} von {{max}} Threads)</span>",
"choose-cpu-power-level": "Wählen Sie, wie viel Ihrer CPU für das Mining zugewiesen werden soll <span>({{current}} von {{max}} Kernen)</span>",
"cpu-warning": "Hohe CPU-Nutzung kann Überhitzung verursachen, den Energieverbrauch erhöhen und im Laufe der Zeit zu Hardwareschäden führen. Bitte überwachen Sie die Nutzung, um einen sicheren und effizienten Betrieb zu gewährleisten.",
"gpu-warning": "Hohe GPU-Nutzung kann Überhitzung verursachen, den Energieverbrauch erhöhen und im Laufe der Zeit zu Hardwareschäden führen. Bitte überwachen Sie die Nutzung, um einen sicheren und effizienten Betrieb zu gewährleisten."
}
"your-reference": "Dein Verweis:<br/><bold>{{logRef}}</bold>"
}
18 changes: 10 additions & 8 deletions public/locales/en/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,20 +5,22 @@
"applyInviteCode": "Apply Invite Code",
"cancel": "Cancel",
"change-language": "Language",
"confirm-import-wallet": "Import new wallet",
"confirm-import-wallet-copy": "Are you sure you want to import a new wallet?\nYour current wallet will be abandoned.",
"connected-peers": "Connected Peers",
"connected-to-tari": "Connected to the Tari Network",
"control-port": "Control Port",
"cpu-mining-enabled": "CPU Mining",
"custom-power-levels": {
"title": "Custom Mode",
"warning": "Warning",
"saved": "Applying Changes",
"gpu-power-level": "GPU Power",
"cpu-power-level": "CPU Cores",
"choose-gpu-power-level": "Choose how much you want your GPU to be allocated to mining <span>({{current}} out of {{max}} threads)</span>",
"choose-cpu-power-level": "Choose how much you want your CPU to be allocated to mining <span>({{current}} out of {{max}} cores)</span>",
"choose-gpu-power-level": "Choose how much you want your GPU to be allocated to mining <span>({{current}} out of {{max}} threads)</span>",
"cpu-power-level": "CPU Cores",
"cpu-warning": "Sustained high CPU usage may cause overheating, and hardware failure.",
"gpu-warning": "Sustained high GPU usage may cause overheating, and hardware failure."
"gpu-power-level": "GPU Power",
"gpu-warning": "Sustained high GPU usage may cause overheating, and hardware failure.",
"saved": "Applying Changes",
"title": "Custom Mode",
"warning": "Warning"
},
"debug-info": "Debug",
"disconnect": "Disconnect from Airdrop",
Expand Down Expand Up @@ -127,4 +129,4 @@
"yes": "Yes",
"your-feedback": "Describe your issue, including your Telegram handle if you have one, so that we can contact you with updates.",
"your-reference": "Your reference:<br/><bold>{{logRef}}</bold>"
}
}
26 changes: 14 additions & 12 deletions public/locales/fr/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,23 @@
"applyInviteCode": "Appliquer le code d\"invitation",
"cancel": "Cancel",
"change-language": "Langue",
"confirm-import-wallet": "Abandon current wallet?",
"confirm-import-wallet-copy": "Are you sure you want to import a new wallet?",
"connected-peers": "Pairs connectés",
"connected-to-tari": "Connecté au réseau Tari",
"control-port": "Port de contrôle",
"cpu-mining-enabled": "Minage CPU",
"custom-power-levels": {
"choose-cpu-power-level": "Choisissez combien de votre CPU vous souhaitez allouer au minage <span>({{current}} sur {{max}} cœurs)</span>",
"choose-gpu-power-level": "Choisissez combien de votre GPU vous souhaitez allouer au minage <span>({{current}} sur {{max}} threads)</span>",
"cpu-power-level": "Cœurs CPU",
"cpu-warning": "Une utilisation élevée du CPU peut provoquer une surchauffe, augmenter la consommation d\"énergie et peut entraîner des dommages matériels au fil du temps. Veuillez surveiller l\"utilisation pour assurer un fonctionnement sûr et efficace.",
"gpu-power-level": "Puissance GPU %",
"gpu-warning": "Une utilisation élevée du GPU peut provoquer une surchauffe, augmenter la consommation d\"énergie et peut entraîner des dommages matériels au fil du temps. Veuillez surveiller l\"utilisation pour assurer un fonctionnement sûr et efficace.",
"saved": "Application des modifications",
"title": "Mode personnalisé",
"warning": "Avertissement"
},
"debug-info": "Déboguer",
"disconnect": "Se déconnecter de l\"Airdrop",
"errors": {
Expand Down Expand Up @@ -115,16 +128,5 @@
"visual-mode": "Mode visuel",
"yes": "Yes",
"your-feedback": "Veuillez décrire votre problème",
"your-reference": "Votre référence :<br/><bold>{{logRef}}</bold>",
"custom-power-levels": {
"title": "Mode personnalisé",
"warning": "Avertissement",
"saved": "Application des modifications",
"gpu-power-level": "Puissance GPU %",
"cpu-power-level": "Cœurs CPU",
"choose-gpu-power-level": "Choisissez combien de votre GPU vous souhaitez allouer au minage <span>({{current}} sur {{max}} threads)</span>",
"choose-cpu-power-level": "Choisissez combien de votre CPU vous souhaitez allouer au minage <span>({{current}} sur {{max}} cœurs)</span>",
"cpu-warning": "Une utilisation élevée du CPU peut provoquer une surchauffe, augmenter la consommation d\"énergie et peut entraîner des dommages matériels au fil du temps. Veuillez surveiller l\"utilisation pour assurer un fonctionnement sûr et efficace.",
"gpu-warning": "Une utilisation élevée du GPU peut provoquer une surchauffe, augmenter la consommation d\"énergie et peut entraîner des dommages matériels au fil du temps. Veuillez surveiller l\"utilisation pour assurer un fonctionnement sûr et efficace."
}
"your-reference": "Votre référence :<br/><bold>{{logRef}}</bold>"
}
26 changes: 14 additions & 12 deletions public/locales/hi/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,23 @@
"applyInviteCode": "आमंत्रण कोड लागू करें",
"cancel": "रद्द करें",
"change-language": "भाषा",
"confirm-import-wallet": "Abandon current wallet?",
"confirm-import-wallet-copy": "Are you sure you want to import a new wallet?",
"connected-peers": "जुड़े हुए सहकर्मी",
"connected-to-tari": "Tari नेटवर्क से जुड़ा",
"control-port": "कंट्रोल पोर्ट",
"cpu-mining-enabled": "सीपीयू माइनिंग",
"custom-power-levels": {
"choose-cpu-power-level": "चुनें कि आप अपने CPU को माइनिंग के लिए कितना आवंटित करना चाहते हैं <span>({{current}} में से {{max}} कोर)</span>",
"choose-gpu-power-level": "चुनें कि आप अपने GPU को माइनिंग के लिए कितना आवंटित करना चाहते हैं <span>({{current}} में से {{max}} थ्रेड्स)</span>",
"cpu-power-level": "CPU कोर",
"cpu-warning": "उच्च CPU उपयोग से ओवरहीटिंग हो सकती है, ऊर्जा खपत बढ़ सकती है, और समय के साथ हार्डवेयर को नुकसान हो सकता है। कृपया सुरक्षित और कुशल संचालन सुनिश्चित करने के लिए उपयोग की निगरानी करें।",
"gpu-power-level": "GPU पावर %",
"gpu-warning": "उच्च GPU उपयोग से ओवरहीटिंग हो सकती है, ऊर्जा खपत बढ़ सकती है, और समय के साथ हार्डवेयर को नुकसान हो सकता है। कृपया सुरक्षित और कुशल संचालन सुनिश्चित करने के लिए उपयोग की निगरानी करें।",
"saved": "परिवर्तनों को लागू किया जा रहा है",
"title": "कस्टम मोड",
"warning": "चेतावनी"
},
"debug-info": "डीबग",
"disconnect": "एयरड्रॉप से डिस्कनेक्ट करें",
"errors": {
Expand Down Expand Up @@ -115,16 +128,5 @@
"visual-mode": "दृश्य मोड",
"yes": "हाँ",
"your-feedback": "कृपया अपनी समस्या का वर्णन करें",
"your-reference": "आपका संदर्भ",
"custom-power-levels": {
"title": "कस्टम मोड",
"warning": "चेतावनी",
"saved": "परिवर्तनों को लागू किया जा रहा है",
"gpu-power-level": "GPU पावर %",
"cpu-power-level": "CPU कोर",
"choose-gpu-power-level": "चुनें कि आप अपने GPU को माइनिंग के लिए कितना आवंटित करना चाहते हैं <span>({{current}} में से {{max}} थ्रेड्स)</span>",
"choose-cpu-power-level": "चुनें कि आप अपने CPU को माइनिंग के लिए कितना आवंटित करना चाहते हैं <span>({{current}} में से {{max}} कोर)</span>",
"cpu-warning": "उच्च CPU उपयोग से ओवरहीटिंग हो सकती है, ऊर्जा खपत बढ़ सकती है, और समय के साथ हार्डवेयर को नुकसान हो सकता है। कृपया सुरक्षित और कुशल संचालन सुनिश्चित करने के लिए उपयोग की निगरानी करें।",
"gpu-warning": "उच्च GPU उपयोग से ओवरहीटिंग हो सकती है, ऊर्जा खपत बढ़ सकती है, और समय के साथ हार्डवेयर को नुकसान हो सकता है। कृपया सुरक्षित और कुशल संचालन सुनिश्चित करने के लिए उपयोग की निगरानी करें।"
}
"your-reference": "आपका संदर्भ"
}
26 changes: 14 additions & 12 deletions public/locales/id/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,23 @@
"applyInviteCode": "Terapkan Kode Undangan",
"cancel": "Batal",
"change-language": "Bahasa",
"confirm-import-wallet": "Abandon current wallet?",
"confirm-import-wallet-copy": "Are you sure you want to import a new wallet?",
"connected-peers": "Rekan Terhubung",
"connected-to-tari": "Terhubung ke Jaringan Tari",
"control-port": "Port Kontrol",
"cpu-mining-enabled": "Penambangan CPU",
"custom-power-levels": {
"choose-cpu-power-level": "Pilih seberapa banyak Anda ingin CPU Anda dialokasikan untuk menambang <span>({{current}} dari {{max}} inti)</span>",
"choose-gpu-power-level": "Pilih seberapa banyak Anda ingin GPU Anda dialokasikan untuk menambang <span>({{current}} dari {{max}} thread)</span>",
"cpu-power-level": "Inti CPU",
"cpu-warning": "Penggunaan CPU yang tinggi dapat menyebabkan panas berlebih, meningkatkan konsumsi energi, dan dapat menyebabkan kerusakan perangkat keras seiring waktu. Harap pantau penggunaan untuk memastikan operasi yang aman dan efisien.",
"gpu-power-level": "Daya GPU %",
"gpu-warning": "Penggunaan GPU yang tinggi dapat menyebabkan panas berlebih, meningkatkan konsumsi energi, dan dapat menyebabkan kerusakan perangkat keras seiring waktu. Harap pantau penggunaan untuk memastikan operasi yang aman dan efisien.",
"saved": "Menerapkan Perubahan",
"title": "Mode Kustom",
"warning": "Peringatan"
},
"debug-info": "Debug",
"disconnect": "Putuskan dari Airdrop",
"errors": {
Expand Down Expand Up @@ -115,16 +128,5 @@
"visual-mode": "Mode visual",
"yes": "Ya",
"your-feedback": "Silakan jelaskan masalah Anda",
"your-reference": "Referensi Anda",
"custom-power-levels": {
"title": "Mode Kustom",
"warning": "Peringatan",
"saved": "Menerapkan Perubahan",
"gpu-power-level": "Daya GPU %",
"cpu-power-level": "Inti CPU",
"choose-gpu-power-level": "Pilih seberapa banyak Anda ingin GPU Anda dialokasikan untuk menambang <span>({{current}} dari {{max}} thread)</span>",
"choose-cpu-power-level": "Pilih seberapa banyak Anda ingin CPU Anda dialokasikan untuk menambang <span>({{current}} dari {{max}} inti)</span>",
"cpu-warning": "Penggunaan CPU yang tinggi dapat menyebabkan panas berlebih, meningkatkan konsumsi energi, dan dapat menyebabkan kerusakan perangkat keras seiring waktu. Harap pantau penggunaan untuk memastikan operasi yang aman dan efisien.",
"gpu-warning": "Penggunaan GPU yang tinggi dapat menyebabkan panas berlebih, meningkatkan konsumsi energi, dan dapat menyebabkan kerusakan perangkat keras seiring waktu. Harap pantau penggunaan untuk memastikan operasi yang aman dan efisien."
}
"your-reference": "Referensi Anda"
}
Loading

0 comments on commit 20a9218

Please sign in to comment.