Skip to content

Commit

Permalink
lint
Browse files Browse the repository at this point in the history
  • Loading branch information
OmarBasem committed Dec 15, 2023
1 parent 5dcc990 commit 5b6d888
Showing 1 changed file with 22 additions and 53 deletions.
75 changes: 22 additions & 53 deletions src/status_im2/contexts/wallet/account/tabs/about/view.cljs
Original file line number Diff line number Diff line change
Expand Up @@ -2,72 +2,41 @@
(:require
[quo.core :as quo]
[react-native.core :as rn]
[react-native.platform :as platform]
[react-native.share :as share]
[status-im2.contexts.profile.utils :as profile.utils]
[status-im2.contexts.wallet.account.tabs.about.style :as style]
[utils.i18n :as i18n]
[utils.re-frame :as rf]))

(defn about-options
[]
(let [{:keys [address] :as account} (rf/sub [:wallet/current-viewing-account])
share-title (str (:name account) " " (i18n/label :t/address))]
[quo/action-drawer
[[{:icon :i/link
:accessibility-label :view-on-eth
:label (i18n/label :t/view-on-eth)
:right-icon :i/external}
{:icon :i/link
:accessibility-label :view-on-opt
:label (i18n/label :t/view-on-opt)
:right-icon :i/external}
{:icon :i/link
:accessibility-label :view-on-arb
:label (i18n/label :t/view-on-arb)
:right-icon :i/external}
{:icon :i/copy
:accessibility-label :copy-address
:label (i18n/label :t/copy-address)}
{:icon :i/qr-code
:accessibility-label :show-address-qr
:label (i18n/label :t/show-address-qr)}
{:icon :i/share
:accessibility-label :share-address
:label (i18n/label :t/share-address)
:on-press (fn []
(rf/dispatch [:hide-bottom-sheet])
(js/setTimeout
#(share/open
(if platform/ios?
{:activityItemSources [{:placeholderItem {:type "text"
:content address}
:item {:default {:type "text"
:content
address}}
:linkMetadata {:title share-title}}]}
{:title share-title
:subject share-title
:message address}))
600))}]]]))
[quo/action-drawer
[[{:icon :i/link
:accessibility-label :view-on-eth
:label (i18n/label :t/view-on-eth)
:right-icon :i/external}
{:icon :i/link
:accessibility-label :view-on-opt
:label (i18n/label :t/view-on-opt)
:right-icon :i/external}
{:icon :i/link
:accessibility-label :view-on-arb
:label (i18n/label :t/view-on-arb)
:right-icon :i/external}
{:icon :i/copy
:accessibility-label :copy-address
:label (i18n/label :t/copy-address)}
{:icon :i/qr-code
:accessibility-label :show-address-qr
:label (i18n/label :t/show-address-qr)}
{:icon :i/share
:accessibility-label :share-address
:label (i18n/label :t/share-address)}]]])

(defn view
[]
(let [{:keys [customization-color] :as profile} (rf/sub [:profile/profile-with-image])
<<<<<<< HEAD
<<<<<<< HEAD
{:keys [address path watch-only?]} (rf/sub [:wallet/current-viewing-account])
networks (rf/sub [:wallet/network-details])]
=======
{:keys [type address path]} (rf/sub [:wallet/current-viewing-account])
networks (rf/sub [:wallet/network-details])
watch-only? (= type :watch)]
>>>>>>> 98eea7f5e (u)
=======
{:keys [type address path]} (rf/sub [:wallet/current-viewing-account])
networks (rf/sub [:wallet/network-details])
watch-only? (= type :watch)]
>>>>>>> 948aca4a9 (wallet: share address)
[rn/view {:style style/about-tab}
[quo/data-item
{:description :default
Expand Down

0 comments on commit 5b6d888

Please sign in to comment.