parent
6a169bd0bd
commit
5bb954f8a7
|
@ -196,10 +196,6 @@ status-im.desktop.core/init
|
|||
status-im.chat.models-test/test-db
|
||||
quo.design-system.spacing/padding-vertical
|
||||
status-im.utils.money/percent-change
|
||||
status-im.utils.platform/isMacOs?
|
||||
status-im.utils.platform/isNix?
|
||||
status-im.utils.platform/isWin?
|
||||
status-im.utils.platform/android-version>=
|
||||
utils.debounce/clear-all
|
||||
status-im.transport.db/create-chat
|
||||
status-im.utils.priority-map/priority-map
|
||||
|
|
|
@ -18,7 +18,7 @@
|
|||
[status-im.ui.components.list-selection :as list-selection]
|
||||
[utils.re-frame :as rf]
|
||||
[utils.url :as url]
|
||||
[status-im.utils.platform :as platform]
|
||||
[react-native.platform :as platform]
|
||||
[status-im.utils.random :as random]
|
||||
[status-im.utils.types :as types]
|
||||
[status-im.utils.universal-links.utils :as links]
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
[react-native.fs :as fs]
|
||||
[status-im2.constants :as constants]
|
||||
[utils.re-frame :as rf]
|
||||
[status-im.utils.platform :as platform]
|
||||
[react-native.platform :as platform]
|
||||
[taoensso.timbre :as log]))
|
||||
|
||||
(def temp-image-url (str (fs/cache-dir) "/StatusIm_Image.jpeg"))
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
[status-im.chat.models.loading :as chat.loading]
|
||||
[status-im.data-store.messages :as data-store.messages]
|
||||
[status-im.transport.message.protocol :as protocol]
|
||||
[status-im.utils.platform :as platform]
|
||||
[react-native.platform :as platform]
|
||||
[status-im.utils.types :as types]
|
||||
[status-im2.contexts.chat.messages.delete-message.events :as delete-message]
|
||||
[status-im2.contexts.chat.messages.list.events :as message-list]
|
||||
|
|
|
@ -10,7 +10,7 @@
|
|||
[utils.re-frame :as rf]
|
||||
[utils.datetime :as datetime]
|
||||
[status-im.utils.keychain.core :as keychain]
|
||||
[status-im.utils.platform :as platform]
|
||||
[react-native.platform :as platform]
|
||||
[status-im.utils.types :as types]
|
||||
[status-im2.navigation.events :as navigation]
|
||||
[taoensso.timbre :as log]))
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
[status-im.ethereum.core :as ethereum]
|
||||
[status-im.keycard.keycard :as keycard]
|
||||
[native-module.core :as native-module]
|
||||
[status-im.utils.platform :as platform]
|
||||
[react-native.platform :as platform]
|
||||
[status-im.utils.types :as types]
|
||||
[taoensso.timbre :as log]))
|
||||
|
||||
|
|
|
@ -15,7 +15,7 @@
|
|||
[utils.re-frame :as rf]
|
||||
[utils.datetime :as datetime]
|
||||
[status-im.utils.keychain.core :as keychain]
|
||||
[status-im.utils.platform :as platform]
|
||||
[react-native.platform :as platform]
|
||||
[status-im.utils.types :as types]
|
||||
[status-im2.navigation.events :as navigation]
|
||||
[taoensso.timbre :as log]
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
[native-module.core :as native-module]
|
||||
[status-im.ui.components.react :as react]
|
||||
[utils.re-frame :as rf]
|
||||
[status-im.utils.platform :as platform]
|
||||
[react-native.platform :as platform]
|
||||
[status-im.utils.types :as types]
|
||||
[utils.security.core :as security]))
|
||||
|
||||
|
|
|
@ -3,9 +3,9 @@
|
|||
[native-module.core :as native-module]
|
||||
[status-im2.config :as config]
|
||||
[utils.re-frame :as rf]
|
||||
[status-im.utils.platform :as utils.platform]
|
||||
[status-im.utils.types :as types]
|
||||
[clojure.string :as string]))
|
||||
[clojure.string :as string]
|
||||
[react-native.platform :as platform]))
|
||||
|
||||
(defn- add-custom-bootnodes
|
||||
[config network all-bootnodes]
|
||||
|
@ -173,7 +173,7 @@
|
|||
:WakuV2Config (merge (assoc wakuv2-config :Enabled wakuv2-enabled)
|
||||
wakuv2-default-config)
|
||||
:ShhextConfig
|
||||
{:BackupDisabledDataDir (utils.platform/no-backup-directory)
|
||||
{:BackupDisabledDataDir (if platform/android? "/../no_backup" "/")
|
||||
:InstallationID installation-id
|
||||
:MaxMessageDeliveryAttempts config/max-message-delivery-attempts
|
||||
:MailServerConfirmations config/mailserver-confirmations-enabled?
|
||||
|
@ -205,7 +205,7 @@
|
|||
which will take care of building up the proper config based on settings in
|
||||
app-db"
|
||||
{:events [::save-new-config]}
|
||||
[{:keys [db]} config {:keys [on-success]}]
|
||||
[_ config {:keys [on-success]}]
|
||||
{:json-rpc/call [{:method "settings_saveSetting"
|
||||
:params [:node-config config]
|
||||
:on-success on-success}]})
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
[status-im.multiaccounts.update.core :as multiaccounts.update]
|
||||
[status-im2.config :as config]
|
||||
[utils.re-frame :as rf]
|
||||
[status-im.utils.platform :as utils.platform]
|
||||
[react-native.platform :as utils.platform]
|
||||
[status-im2.common.json-rpc.events :as json-rpc]
|
||||
[status-im2.navigation.events :as navigation]
|
||||
[taoensso.timbre :as log]))
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
[reagent.core :as reagent]
|
||||
[status-im.ui.components.animation :as anim]
|
||||
[status-im.ui.components.react :as react]
|
||||
[status-im.utils.platform :as platform])
|
||||
[react-native.platform :as platform])
|
||||
(:require-macros [status-im.utils.views :as views]))
|
||||
|
||||
(def back-listener (atom nil))
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
(ns status-im.ui.components.emoji-thumbnail.styles
|
||||
(:require [quo.design-system.colors :as colors]
|
||||
[status-im.ui.components.emoji-thumbnail.utils :as emoji-utils]
|
||||
[status-im.utils.platform :as platform]))
|
||||
[react-native.platform :as platform]))
|
||||
|
||||
(defn emoji-thumbnail-icon
|
||||
[color size]
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
(ns status-im.ui.components.emoji-thumbnail.utils
|
||||
(:require [status-im.utils.platform :as platform]))
|
||||
(:require [react-native.platform :as platform]))
|
||||
|
||||
(defn emoji-font-size
|
||||
[container_size]
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
[reagent.core :as reagent]
|
||||
[status-im.ui.components.list.styles :as styles]
|
||||
[status-im.ui.components.react :as react]
|
||||
[status-im.utils.platform :as platform]))
|
||||
[react-native.platform :as platform]))
|
||||
|
||||
(def flat-list-class (reagent/adapt-react-class (.-FlatList react-native)))
|
||||
(def section-list-class (reagent/adapt-react-class (.-SectionList react-native)))
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
[status-im.ui.components.dialog :as dialog]
|
||||
[status-im.ui.components.react :as react]
|
||||
[utils.url :as url]
|
||||
[status-im.utils.platform :as platform]))
|
||||
[react-native.platform :as platform]))
|
||||
|
||||
(defn open-share
|
||||
[content]
|
||||
|
|
|
@ -12,7 +12,7 @@
|
|||
[reagent.core :as reagent]
|
||||
[utils.i18n :as i18n]
|
||||
[status-im.ui.components.typography :as typography]
|
||||
[status-im.utils.platform :as platform]
|
||||
[react-native.platform :as platform]
|
||||
[status-im.utils.utils :as utils])
|
||||
(:require-macros [status-im.utils.views :as views]))
|
||||
|
||||
|
|
|
@ -1,10 +0,0 @@
|
|||
(ns status-im.ui.components.tabbar.core
|
||||
(:require [status-im.utils.platform :as platform]))
|
||||
|
||||
(defn get-height
|
||||
[]
|
||||
(if platform/android?
|
||||
56
|
||||
(if platform/iphone-x?
|
||||
84
|
||||
50)))
|
|
@ -2,7 +2,7 @@
|
|||
(:require ["react-native-webview" :default rn-webview]
|
||||
[reagent.core :as reagent]
|
||||
[status-im2.config :as config]
|
||||
[status-im.utils.platform :as platform]))
|
||||
[react-native.platform :as platform]))
|
||||
|
||||
(def webview-class
|
||||
(reagent/adapt-react-class rn-webview))
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
[status-im2.constants :as constants]
|
||||
[utils.i18n :as i18n]
|
||||
[status-im.ui.components.react :as react]
|
||||
[status-im.utils.platform :as platform]
|
||||
[react-native.platform :as platform]
|
||||
[utils.debounce :as debounce])
|
||||
(:require-macros [status-im.utils.views :refer [defview letsubs]]))
|
||||
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
[status-im.ui.components.icons.icons :as icons]
|
||||
[status-im.ui.components.react :as react]
|
||||
[status-im.ui.screens.keycard.pin.styles :as styles]
|
||||
[status-im.utils.platform :as platform]))
|
||||
[react-native.platform :as platform]))
|
||||
|
||||
(def default-pin-retries-number 3)
|
||||
(def default-puk-retries-number 5)
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
[status-im.ui.screens.signing.views :as signing]
|
||||
[status-im.ui.screens.wallet.request.views :as request]
|
||||
[status-im.ui.screens.wallet.signing-phrase.views :as signing-phrase]
|
||||
[status-im.utils.platform :as platform]))
|
||||
[react-native.platform :as platform]))
|
||||
|
||||
(defn hide-panel-anim
|
||||
[bottom-anim-value alpha-value window-height]
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
[status-im.ui.components.common.common :as components.common]
|
||||
[status-im.ui.components.react :as react]
|
||||
[status-im2.config :as config]
|
||||
[status-im.utils.platform :as platform])
|
||||
[react-native.platform :as platform])
|
||||
(:require-macros [status-im.utils.views :as views]))
|
||||
|
||||
(defn separator
|
||||
|
|
|
@ -12,7 +12,7 @@
|
|||
[status-im.ui.screens.profile.visibility-status.styles :as styles]
|
||||
[status-im.ui.screens.profile.visibility-status.utils :as utils]
|
||||
[utils.re-frame :as rf]
|
||||
[status-im.utils.platform :as platform]))
|
||||
[react-native.platform :as platform]))
|
||||
|
||||
;; === Code Related to visibility-status-button ===
|
||||
|
||||
|
|
|
@ -22,7 +22,7 @@
|
|||
[status-im.ui.screens.signing.sheets :as sheets]
|
||||
[status-im.ui.screens.signing.styles :as styles]
|
||||
[status-im.ui.screens.wallet.components.views :as wallet.components]
|
||||
[status-im.utils.platform :as platform]
|
||||
[react-native.platform :as platform]
|
||||
[status-im.utils.types :as types]
|
||||
[status-im.utils.utils :as utils]
|
||||
[status-im.wallet.utils :as wallet.utils]
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
[status-im.utils.build :as build]
|
||||
[utils.re-frame :as rf]
|
||||
[utils.datetime :as datetime]
|
||||
[status-im.utils.platform :as platform]
|
||||
[react-native.platform :as platform]
|
||||
[status-im.utils.types :as types]
|
||||
[status-im2.common.log :as log]
|
||||
[status-im2.config :as config]))
|
||||
|
|
|
@ -1,40 +0,0 @@
|
|||
(ns status-im.utils.platform
|
||||
(:require ["react-native" :as react-native :refer (Dimensions)]))
|
||||
|
||||
(def platform
|
||||
(.-Platform react-native))
|
||||
|
||||
(def os
|
||||
(when platform
|
||||
(.-OS ^js platform)))
|
||||
|
||||
(def version
|
||||
(when platform
|
||||
(.-Version ^js platform)))
|
||||
|
||||
;; iPhone X dimensions
|
||||
(def x-height 812)
|
||||
(def xs-height 896)
|
||||
|
||||
(defn iphone-x-dimensions?
|
||||
[]
|
||||
(let [{:keys [height]} (-> Dimensions
|
||||
(.get "window")
|
||||
(js->clj :keywordize-keys true))]
|
||||
(or (= height x-height) (= height xs-height))))
|
||||
|
||||
(def android? (= os "android"))
|
||||
(def ios? (= os "ios"))
|
||||
(def iphone-x? (and ios? (iphone-x-dimensions?)))
|
||||
|
||||
(defn no-backup-directory
|
||||
[]
|
||||
(cond
|
||||
android? "/../no_backup"
|
||||
ios? "/"))
|
||||
|
||||
(defn android-version>=
|
||||
[v]
|
||||
(and android? (>= version v)))
|
||||
|
||||
(def low-device? (and android? (< version 29)))
|
|
@ -4,7 +4,7 @@
|
|||
[style]
|
||||
`(let [style# ~style
|
||||
common# (dissoc style# :android :ios)
|
||||
platform# (keyword status-im.utils.platform/os)
|
||||
platform# (keyword react-native.platform/os)
|
||||
platform-specific# (get style# platform#)]
|
||||
(if platform-specific#
|
||||
(merge common# platform-specific#)
|
||||
|
|
|
@ -1,3 +1,3 @@
|
|||
(ns status-im.utils.styles
|
||||
(:require-macros status-im.utils.styles)
|
||||
(:require status-im.utils.platform))
|
||||
(:require react-native.platform))
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
(ns status-im2.common.bottom-sheet.style
|
||||
(:require [quo2.foundations.colors :as colors]
|
||||
[quo2.theme :as theme]
|
||||
[status-im.utils.platform :as platform]))
|
||||
[react-native.platform :as platform]))
|
||||
|
||||
(defn handle
|
||||
[theme]
|
||||
|
|
|
@ -3,13 +3,13 @@
|
|||
[re-frame.core :as re-frame]
|
||||
[status-im.data-store.settings :as data-store.settings]
|
||||
[status-im.node.core :as node]
|
||||
[status-im.utils.platform :as utils.platform]
|
||||
[status-im2.config :as config]
|
||||
[status-im2.constants :as constants]
|
||||
[taoensso.timbre :as log]
|
||||
[utils.re-frame :as rf]
|
||||
[utils.security.core :as security]
|
||||
[utils.transforms :as transforms]))
|
||||
[utils.transforms :as transforms]
|
||||
[react-native.platform :as platform]))
|
||||
|
||||
(rf/defn local-pairing-update-role
|
||||
{:events [:syncing/update-role]}
|
||||
|
@ -60,7 +60,7 @@
|
|||
{:receiverConfig {:kdfIterations config/default-kdf-iterations
|
||||
:nodeConfig final-node-config
|
||||
:settingCurrentNetwork config/default-network
|
||||
:deviceType utils.platform/os
|
||||
:deviceType platform/os
|
||||
:deviceName
|
||||
(native-module/get-installation-name)}}))]
|
||||
(rf/dispatch [:syncing/update-role constants/local-pairing-role-receiver])
|
||||
|
@ -87,7 +87,7 @@
|
|||
(clj->js {:senderConfig {:keyUID key-uid
|
||||
:keystorePath ""
|
||||
:password sha3-pwd
|
||||
:deviceType utils.platform/os}
|
||||
:deviceType platform/os}
|
||||
:serverConfig {:timeout 0}}))]
|
||||
(native-module/get-connection-string-for-bootstrapping-another-device
|
||||
config-map
|
||||
|
|
Loading…
Reference in New Issue