mirror of
https://github.com/status-im/status-react.git
synced 2025-02-03 22:56:19 +00:00
[Mobile] Show status-go version on separate line in About.
Signed-off-by: Igor Mandrigin <i@mandrigin.ru>
This commit is contained in:
parent
513a9cadbe
commit
f5bfd63f0e
@ -8,7 +8,8 @@
|
|||||||
[re-frame.core :as re-frame]))
|
[re-frame.core :as re-frame]))
|
||||||
|
|
||||||
(views/defview about-app []
|
(views/defview about-app []
|
||||||
(views/letsubs [version [:get-app-version]]
|
(views/letsubs [app-version [:get-app-short-version]
|
||||||
|
node-version [:get-app-node-version]]
|
||||||
[react/view {:flex 1}
|
[react/view {:flex 1}
|
||||||
[status-bar/status-bar]
|
[status-bar/status-bar]
|
||||||
[toolbar/simple-toolbar (i18n/label :t/about-app)]
|
[toolbar/simple-toolbar (i18n/label :t/about-app)]
|
||||||
@ -22,6 +23,12 @@
|
|||||||
(when status-im.utils.platform/ios?
|
(when status-im.utils.platform/ios?
|
||||||
[profile.components/settings-item-separator])
|
[profile.components/settings-item-separator])
|
||||||
[profile.components/settings-item
|
[profile.components/settings-item
|
||||||
{:item-text (i18n/label :t/version {:version version})
|
{:item-text (i18n/label :t/version {:version app-version})
|
||||||
|
:accessibility-label :version
|
||||||
|
:hide-arrow? true}]
|
||||||
|
(when status-im.utils.platform/ios?
|
||||||
|
[profile.components/settings-item-separator])
|
||||||
|
[profile.components/settings-item
|
||||||
|
{:item-text node-version
|
||||||
:accessibility-label :version
|
:accessibility-label :version
|
||||||
:hide-arrow? true}]]]]))
|
:hide-arrow? true}]]]]))
|
||||||
|
@ -4,6 +4,13 @@
|
|||||||
[status-im.utils.build :as build]
|
[status-im.utils.build :as build]
|
||||||
[status-im.utils.platform :as platform]))
|
[status-im.utils.platform :as platform]))
|
||||||
|
|
||||||
|
(defn- node-version [{:keys [web3-node-version]}]
|
||||||
|
(str "status-go v" (or web3-node-version "N/A") ""))
|
||||||
|
|
||||||
|
(def app-short-version
|
||||||
|
(let [version (if platform/desktop? build/version build/build-no)]
|
||||||
|
(str build/version " (" version ")")))
|
||||||
|
|
||||||
(re-frame/reg-sub
|
(re-frame/reg-sub
|
||||||
:get-profile-unread-messages-number
|
:get-profile-unread-messages-number
|
||||||
:<- [:account/account]
|
:<- [:account/account]
|
||||||
@ -12,9 +19,16 @@
|
|||||||
|
|
||||||
(re-frame/reg-sub
|
(re-frame/reg-sub
|
||||||
:get-app-version
|
:get-app-version
|
||||||
(fn [{:keys [web3-node-version]}]
|
(fn [db]
|
||||||
(let [version (if platform/desktop? build/version build/build-no)]
|
(str app-short-version "; " (node-version db))))
|
||||||
(str build/version " (" version "); node " (or web3-node-version "N/A") ""))))
|
|
||||||
|
(re-frame/reg-sub
|
||||||
|
:get-app-short-version
|
||||||
|
(fn [db] app-short-version))
|
||||||
|
|
||||||
|
(re-frame/reg-sub
|
||||||
|
:get-app-node-version
|
||||||
|
node-version)
|
||||||
|
|
||||||
(re-frame/reg-sub
|
(re-frame/reg-sub
|
||||||
:get-device-UUID
|
:get-device-UUID
|
||||||
|
Loading…
x
Reference in New Issue
Block a user