From 4c4a8b65d49049921ea619fe4babb8560ee86f16 Mon Sep 17 00:00:00 2001 From: Alexander Date: Mon, 8 Jul 2024 13:55:32 +0200 Subject: [PATCH] Add QR scanner to connect Dapps through Connected Dapps screen (#20647) * Add QR scanner to connect Dapps through Connected Dapps screen * Style fix * use-mount --- resources/images/dapps/WalletConnect@2x.png | Bin 0 -> 6731 bytes resources/images/dapps/WalletConnect@3x.png | Bin 0 -> 12290 bytes .../components/tags/context_tag/schema.cljs | 2 +- src/quo/components/tags/context_tag/view.cljs | 173 +++++++++--------- src/quo/foundations/resources.cljs | 13 +- .../wallet/common/account_switcher/view.cljs | 2 +- .../connected_dapps/scan_dapp/style.cljs | 11 ++ .../connected_dapps/scan_dapp/view.cljs | 44 +++++ .../contexts/wallet/connected_dapps/view.cljs | 2 +- .../wallet/wallet_connect/events.cljs | 23 +-- src/status_im/navigation/screens.cljs | 15 +- translations/en.json | 3 + 12 files changed, 179 insertions(+), 109 deletions(-) create mode 100644 resources/images/dapps/WalletConnect@2x.png create mode 100644 resources/images/dapps/WalletConnect@3x.png create mode 100644 src/status_im/contexts/wallet/connected_dapps/scan_dapp/style.cljs create mode 100644 src/status_im/contexts/wallet/connected_dapps/scan_dapp/view.cljs diff --git a/resources/images/dapps/WalletConnect@2x.png b/resources/images/dapps/WalletConnect@2x.png new file mode 100644 index 0000000000000000000000000000000000000000..6ae713eb62d42093eb835682e711076079587aac GIT binary patch literal 6731 zcmV-R8noq!P)TK1D9ad-xNjK55s*1nd(QQ`{dM=dk9o6Vg&WQ8?0bFw`a6E# z*KY=fKVj)#F1szDS307HaU2G)9trg5n-V=zvT*ewFqG-~5Y?gI;w^v=!p61@SF$1e zi3-DKSUkXJ&|`%}Km8_^XI?6o5qMi^TD{nXBBh9d zC-p+pq|Uz{1~ysC)B{2<2@$$RKl*D-Zaw+J#u9wWvda>vZ5^pAb+9~3&6-JFxs z01yg5v{1}Ew+V(tzt{zpo-}|8JTBxz@FIrrTs|$2bB%oqUe)iz30a|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|BEne|TW*Ksxm9fqvj!t9?Z{002ovPDHLkV1gRy0xkdm literal 0 HcmV?d00001 diff --git a/resources/images/dapps/WalletConnect@3x.png b/resources/images/dapps/WalletConnect@3x.png new file mode 100644 index 0000000000000000000000000000000000000000..c69ecf6f2dbe6573829ad29e0eaecfb0b3617a06 GIT binary patch literal 12290 zcmV+dF#XSoP)HB!C`#T*2Wvcib`V7y@_P z`@`W6!Rt^&lprF{KoC(tlprEh7v_=bWpmyQ=Ha)xCE@xDz_N zyKB{2tJYj=KE65EYK8v~X!Rw!-vL&5zyLIkRPg!%HK6%3lSaSRsy}w4!e;t+n63|N zdI8?k{2t2M1P7ZoT%m^XE+>U|A)R@N9;81jh$+Ww=oQ42foAs*gPUB}P>TPCzT^p@ zv5CHXkeR;WyJ{oeW%RCKu)jjr(BPj+A6F0?`Xh{pk$J4_GP=oizf`mkt#-AMB*dL4 z+8b$wZ^mv;yDftom^!HQaHB?Z!C;-Ij*Xtib@pz|?A?yREPiQB&!h2OO&>*X)|ngp z&FZ#lXJtm}&pVgu-BKjp)jDP2y4_8T?=}n;#%f$jZwJjcc|~ZRN6_svU0eCe1*EV^ z!@KgX?>XzR8_+w>V4tzq!nb&%gU9ci8Ar2aa1-X&7_4)zY@ar3sVM!_Coa;LVi(dbS;65|+lsrBSHGIFtzJ`N{WdR`uLoYnP$oR{<|5PyyJ9u( z^c8#tuUd`Rs+}vUuiB(*$SL~UV{XuPO6ysD8z|Fi{`eQ&OR$q^r>$THDl9Uhr~&^W zvh{2$22}gTQ~2KS3T}ns^=ra7bq!o;ZKfzsU2*r->TB3Zv{M-Di{v{Xuwp>7XK>2~ zQf3`<$Y5lP=3SsgHj_uf`nGoULForp}|`Sl1kVnhjQ5yP7SAy>=ffZcTftMW`~fUMtsZ zpdxGTxmsO^IiNXVaGkl?O=KZQhVgj^Zs#yKsr@>GTZSs*_ho`64fQKECrq9-gR`02 zn(<_U?v3T^4_?2PG}ys+?HW(X40dNdMA;0^4qVKh$+PM`>s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GhDAPjW-{GOkHzwlFJBdsTwA~QhyM<=&(lODLTKD*E>AzdZ)HDc7Zp&JV zf+YU(cd`M6SSQh>ln#BVGv-|TD=)-VYP=j}qSrH*Q;s^4S8)8kJawVP6|6(olJ2mg_bD{7J+yCFIr}3A z<z17-Shw%`n*Z+iY&&Wz;n*ah%nz&RIuen-sKi>=W{q&kX~ys3xyJ zK~(QL1FY3HvqfTb19i(5{;VFj{V`*ocT*10Trb}u4SvqOf;x6_(zPT#I`=EA(J!`g z)loZo!ppGG6IN^B>$bjH6Z~N04_zkKt#RcO>kF5(a%by6u4P?DPrV6qK>3W0#@QYZ ztL1B}J@+dgbDP!CT3kAjl-k@XbD3IZF#q6^veaobzMC7bH74sd3(I9wPKz^Rl0^H0 z_zFu1fkxZbO+XNx(Z0_4oXKrQUSw3cc7DAZrnY^9!L!RNv~53tkkREO&eGOGip{a& zJn&ym%Q`);7J>ZC0zb?J_r|hpo|vK3iQwKJm3_*LVJEO{mvv zRX?|ikXemaTGX%2kTTPMijb~->~?1zWdS?UX zh~|{ROsme)1GX(mdjsa1JQi)7bi)BDE!EM$;J9JOlrwVFa98x+q-*I{vZaFF>{&Q% z)2+oh!59LXa|SaplP$}AKq)Pjw;u+$!=50^iAd$H+HD$Is$pLh<>m~)IvS7nRcp}emq_mxozNG7K1KK64HcY#e!Axv`DOI_Q)c<+y zGPrfDxX$4A!HHU}O&FXkQFi63jkJq*h-ftr(lA_0T^L9#FsFIN?Jzh?SEm1-F`}1q8c#}Xu#~=TcVTQmyB&iAVq*+&2Wb$=7z?(~B#G&UoUEM? z*-0zMtCjk5r{@*cZQ7uQu^ZBE%iu5t%q9%vR2t<$M1mQu=M~4k(anqdWri76+})WP zrgsH{8)?;M;d5U^^=6{SD^_IVle4VEh|uIwV9yO%>@ag8%>k07*qoM6N<$f{wc%8vp without-watched first - :address) - ) + :address)) :fx [[:dispatch [:open-modal :screen/wallet.wallet-connect-session-proposal]]]} {:fx [[:dispatch @@ -190,27 +189,25 @@ (fn [_ [scanned-text]] (let [parsed-uri (wallet-connect/parse-uri scanned-text) version (:version parsed-uri) + valid-wc-uri? (wc-utils/valid-uri? parsed-uri) expired? (-> parsed-uri :expiryTimestamp wc-utils/timestamp-expired?) version-supported? (wc-utils/version-supported? version)] - (cond - expired? + (if (or (not valid-wc-uri?) expired? (not version-supported?)) {:fx [[:dispatch [:toasts/upsert {:type :negative :theme :dark - :text (i18n/label :t/wallet-connect-qr-expired)}]]]} + :text (cond (not valid-wc-uri?) + (i18n/label :t/wallet-connect-wrong-qr) - (not version-supported?) - {:fx [[:dispatch - [:toasts/upsert - {:type :negative - :theme :dark - :text (i18n/label :t/wallet-connect-version-not-supported - {:version version})}]]]} + expired? + (i18n/label :t/wallet-connect-qr-expired) - :else + (not version-supported?) + (i18n/label :t/wallet-connect-version-not-supported + {:version version}))}]]]} {:fx [[:dispatch [:wallet-connect/pair scanned-text]]]})))) (rf/reg-event-fx diff --git a/src/status_im/navigation/screens.cljs b/src/status_im/navigation/screens.cljs index 812f5f4930..d7b72a78f5 100644 --- a/src/status_im/navigation/screens.cljs +++ b/src/status_im/navigation/screens.cljs @@ -108,6 +108,7 @@ [status-im.contexts.wallet.bridge.select-asset.view :as wallet-bridge-select-asset] [status-im.contexts.wallet.collectible.view :as wallet-collectible] [status-im.contexts.wallet.common.scan-account.view :as wallet-scan-address] + [status-im.contexts.wallet.connected-dapps.scan-dapp.view :as wallet-scan-dapp] [status-im.contexts.wallet.connected-dapps.view :as wallet-connected-dapps] [status-im.contexts.wallet.send.from.view :as wallet-select-from] [status-im.contexts.wallet.send.select-address.view :as wallet-select-address] @@ -411,10 +412,6 @@ :options {:insets {:top? true}} :component wallet-accounts/view} - {:name :screen/wallet.connected-dapps - :options {:insets {:top? true}} - :component wallet-connected-dapps/view} - {:name :screen/wallet.wallet-connect-session-proposal :options {:sheet? true} :component wallet-connect-session-proposal/view} @@ -549,6 +546,16 @@ :options {:sheet? true} :component wallet-connect-send-transaction/view} + {:name :screen/wallet.connected-dapps + :options {:insets {:top? true}} + :component wallet-connected-dapps/view} + + {:name :screen/wallet.scan-dapp + :options (merge + options/dark-screen + {:modalPresentationStyle :overCurrentContext}) + :component wallet-scan-dapp/view} + ;; Settings {:name :screen/settings-password diff --git a/translations/en.json b/translations/en.json index cc12be4486..dea6d1742e 100644 --- a/translations/en.json +++ b/translations/en.json @@ -2733,8 +2733,11 @@ "dapp-will-be-able-to": "{{dapp-name}} will be able to:", "check-your-account-balance-and-activity": "Check your account balance and activity", "request-txns-and-message-signing": "Request transactions and message signing", + "wallet-connect-label": "WalletConnect", + "wallet-connect-via": "via", "wallet-connect-qr-expired": "WalletConnect QR has expired", "wallet-connect-version-not-supported": "WalletConnect version {{version}} is not supported", + "wallet-connect-wrong-qr": "It’s not a WalletConnect QR", "add-network-preferences": "Add network preferences", "saved-address-network-preference-selection-description": "Only change if you know which networks the address owner is happy to to receive funds on", "add-preferences": "Add preferences",