Compare commits

...
Author SHA1 Message Date
yenda 464ad4d64c fix ens contenthash resolution
Signed-off-by: Andrey Shovkoplyas <motor4ik@gmail.com>
2020-04-02 14:27:36 +02:00
yenda e6da69be7f fix ens contenthash resolution
Signed-off-by: Andrey Shovkoplyas <motor4ik@gmail.com>
2020-04-02 14:27:33 +02:00
Andrey Shovkoplyas 93f17d0deb 1.2.1 2020-04-02 14:26:24 +02:00
André Medeiros b76fa535d9 Fix camera usage description (#10263)
* Fix camera usage description

* Remove contacts usage description as we never access those
2020-04-01 13:21:18 -04:00
Andrea Maria Piana 2a755e07dd Upgrade status-go
Signed-off-by: Andrea Maria Piana <andrea.maria.piana@gmail.com>
2020-03-30 15:52:46 +02:00
Andrea Maria Piana 975b749348 Enable waku node default
Signed-off-by: Andrea Maria Piana <andrea.maria.piana@gmail.com>
2020-03-30 11:06:01 +02:00
jakub 85f65a60d3 use the proper source of publish method
Signed-off-by: Jakub Sokołowski <jakub@status.im>
2020-03-25 17:10:50 +01:00
jakub 3337d9f77a Revert "ci: re-add Play Store upload case for release"
This reverts commit 5f9accaa24.
2020-03-25 16:46:21 +01:00
Roman Volosovskyi cfe748cdeb [#10197] More retries when requesting balances 2020-03-25 16:24:58 +01:00
Gheorghe Pinzaru 68e453b549 Fix android tabbar animation
Signed-off-by: Gheorghe Pinzaru <feross95@gmail.com>
2020-03-25 14:17:32 +01:00
jakub 5f9accaa24 ci: re-add Play Store upload case for release
Signed-off-by: Jakub Sokołowski <jakub@status.im>
2020-03-25 11:21:26 +01:00
Andrey Shovkoplyas 3ece671048 1.2.0 2020-03-25 09:43:49 +01:00
23 changed files with 185 additions and 118 deletions
+1 -1
View File
@@ -1 +1 @@
0.14.0 1.2.1
+1 -1
View File
@@ -75,7 +75,7 @@ pipeline {
steps { script { steps { script {
switch (btype) { switch (btype) {
case 'nightly': build(job: 'misc/status.im', wait: false); break case 'nightly': build(job: 'misc/status.im', wait: false); break
case 'release': gh.publishReleaseMobile(); break case 'release': github.publishReleaseMobile(); break
} }
} } } }
} }
+1
View File
@@ -43,6 +43,7 @@
"react-native-mail" "react-native-mail"
"react-native-shake" "react-native-shake"
"@react-native-community/netinfo" "@react-native-community/netinfo"
"react-native-gesture-handler"
"react-native-safe-area-context"] "react-native-safe-area-context"]
;; Desktop modules ;; Desktop modules
:desktop-modules ["buffer" :desktop-modules ["buffer"
@@ -274,3 +274,6 @@
(def safe-area-consumer (adapt-class (object/get js-dependencies/safe-area-context "SafeAreaConsumer"))) (def safe-area-consumer (adapt-class (object/get js-dependencies/safe-area-context "SafeAreaConsumer")))
(def safe-area-view (adapt-class (object/get js-dependencies/safe-area-context "SafeAreaView"))) (def safe-area-view (adapt-class (object/get js-dependencies/safe-area-context "SafeAreaView")))
(def touchable-without-feedback-gesture (adapt-class (object/get js-dependencies/react-native-gesture-handler "TouchableWithoutFeedback")))
+1 -3
View File
@@ -78,9 +78,7 @@
</dict> </dict>
</dict> </dict>
<key>NSCameraUsageDescription</key> <key>NSCameraUsageDescription</key>
<string>Please allow Status to use your phone camera</string> <string>The app uses your camera to scan QR codes.</string>
<key>NSContactsUsageDescription</key>
<string>We need to access your contacts</string>
<key>NSLocationAlwaysUsageDescription</key> <key>NSLocationAlwaysUsageDescription</key>
<string>Location access is required for some DApps to function properly.</string> <string>Location access is required for some DApps to function properly.</string>
<key>NSLocationWhenInUseUsageDescription</key> <key>NSLocationWhenInUseUsageDescription</key>
@@ -43,3 +43,5 @@
(def react-navigation-native (js/require "@react-navigation/native")) (def react-navigation-native (js/require "@react-navigation/native"))
(def react-navigation-stack (js/require "@react-navigation/stack")) (def react-navigation-stack (js/require "@react-navigation/stack"))
(def react-navigation-bottom-tabs (js/require "@react-navigation/bottom-tabs")) (def react-navigation-bottom-tabs (js/require "@react-navigation/bottom-tabs"))
(def react-native-gesture-handler (js/require "react-native-gesture-handler"))
+1
View File
@@ -104,6 +104,7 @@
{:preview-privacy? config/blank-preview? {:preview-privacy? config/blank-preview?
:wallet/visible-tokens {:mainnet #{:SNT}} :wallet/visible-tokens {:mainnet #{:SNT}}
:currency :usd :currency :usd
:waku-enabled true
:log-level config/log-level-status-go}) :log-level config/log-level-status-go})
(defn default-visible-tokens [chain] (defn default-visible-tokens [chain]
+21 -5
View File
@@ -7,7 +7,8 @@
(:refer-clojure :exclude [name]) (:refer-clojure :exclude [name])
(:require [clojure.string :as string] (:require [clojure.string :as string]
[status-im.ethereum.core :as ethereum] [status-im.ethereum.core :as ethereum]
[status-im.ethereum.json-rpc :as json-rpc])) [status-im.ethereum.json-rpc :as json-rpc]
[status-im.ethereum.abi-spec :as abi-spec]))
;; this is the addresses of ens registries for the different networks ;; this is the addresses of ens registries for the different networks
(def ens-registries (def ens-registries
@@ -96,6 +97,24 @@
(fn [[name]] (fn [[name]]
(cb name))})) (cb name))}))
(defn cleanup-hash [raw-hash]
;; NOTE: it would be better if our abi-spec/decode was able to do that
(let [;; ignore hex prefix
[_ raw-hash-rest] (split-at 2 raw-hash)
;; the first field gives us the length of the next one in hex and has
;; a length of 32 bytes
;; 1 byte is 2 chars here
[next-field-length-hex raw-hash-rest] (split-at 64 raw-hash-rest)
next-field-length (* ^number (abi-spec/hex-to-number (string/join next-field-length-hex)) 2)
;; we get the next field which is the length of the hash and is
;; expected to be 32 bytes as well
[hash-field-length-hex raw-hash-rest] (split-at next-field-length
raw-hash-rest)
hash-field-length (* ^number (abi-spec/hex-to-number (string/join hash-field-length-hex)) 2)
;; we get the hash
[hash _] (split-at hash-field-length raw-hash-rest)]
(str "0x" (string/join hash))))
(defn contenthash (defn contenthash
[resolver ens-name cb] [resolver ens-name cb]
(json-rpc/eth-call (json-rpc/eth-call
@@ -105,10 +124,7 @@
:on-success :on-success
(fn [raw-hash] (fn [raw-hash]
;; NOTE: it would be better if our abi-spec/decode was able to do that ;; NOTE: it would be better if our abi-spec/decode was able to do that
(let [hash (subs raw-hash 130) (cb (cleanup-hash raw-hash)))}))
[cid & hash-and-zeros] (string/split hash "1b20")
hash (str "0x" cid "1b20" (subs (apply str hash-and-zeros) 0 64))]
(cb hash)))}))
(defn content (defn content
[resolver ens-name cb] [resolver ens-name cb]
+14 -4
View File
@@ -7,7 +7,8 @@
[status-im.native-module.core :as status] [status-im.native-module.core :as status]
[status-im.utils.money :as money] [status-im.utils.money :as money]
[status-im.utils.types :as types] [status-im.utils.types :as types]
[taoensso.timbre :as log])) [taoensso.timbre :as log]
[status-im.utils.utils :as utils]))
(def json-rpc-api (def json-rpc-api
{"eth_call" {} {"eth_call" {}
@@ -171,11 +172,20 @@
"mailservers_getChatRequestRanges" {} "mailservers_getChatRequestRanges" {}
"mailservers_deleteChatRequestRange" {}}) "mailservers_deleteChatRequestRange" {}})
(defn on-error-retry [call-method {:keys [method number-of-retries on-error] :as arg}] (defn on-error-retry
[call-method {:keys [method number-of-retries delay on-error] :as arg}]
(if (pos? number-of-retries) (if (pos? number-of-retries)
(fn [] (fn []
(log/debug "[on-error-retry]" method "number-of-retries" number-of-retries) (let [updated-delay (if delay
(call-method (update arg :number-of-retries dec))) (min 2000 (* 2 delay))
50)]
(log/debug "[on-error-retry]" method
"number-of-retries" number-of-retries
"delay" delay)
(utils/set-timeout #(call-method (-> arg
(update :number-of-retries dec)
(assoc :delay updated-delay)))
updated-delay)))
on-error)) on-error))
(defn call-ext-method [waku-enabled? method] (defn call-ext-method [waku-enabled? method]
+64 -57
View File
@@ -11,19 +11,17 @@
[status-im.i18n :as i18n] [status-im.i18n :as i18n]
[re-frame.core :as re-frame])) [re-frame.core :as re-frame]))
(defonce visible? (animation/create-value 0)) (defonce visible-native (animation/create-value 0))
(defonce minimized-state (reagent/atom nil))
(defonce last-to-value (atom 1)) (defonce last-to-value (atom 1))
(defn animate (defn animate
([visible duration to] ([visible-native duration to]
(animate visible duration to nil)) (animate visible-native duration to nil))
([visible duration to callback] ([visible-native duration to callback]
(when (not= to @last-to-value) (when (not= to @last-to-value)
(reset! last-to-value to) (reset! last-to-value to)
(animation/start (animation/start
(animation/timing visible (animation/timing visible-native
{:toValue to {:toValue to
:duration duration :duration duration
:easing (animation/cubic) :easing (animation/cubic)
@@ -37,12 +35,8 @@
(defn minimize-bar [route-name] (defn minimize-bar [route-name]
(if (main-tab? route-name) (if (main-tab? route-name)
(do (animate visible-native 150 0)
(reset! minimized-state false) (animate visible-native 150 1)))
(animate visible? 150 0))
(do
(reset! minimized-state true)
(animate visible? 150 1))))
(def tabs-list-data (def tabs-list-data
(->> (->>
@@ -73,31 +67,35 @@
(fn [{:keys [icon label active? nav-stack on-press (fn [{:keys [icon label active? nav-stack on-press
accessibility-label count-subscription]}] accessibility-label count-subscription]}]
(let [count (when count-subscription @(re-frame/subscribe [count-subscription]))] (let [count (when count-subscription @(re-frame/subscribe [count-subscription]))]
[react/touchable-highlight {:style tabs.styles/touchable-container [react/view {:style tabs.styles/touchable-container}
:on-press on-press [react/touchable-without-feedback-gesture
:accessibility-label accessibility-label} {:style {:height "100%"
[react/view {:style tabs.styles/tab-container} :width "100%"}
[react/view {:style tabs.styles/icon-container} :on-press on-press
[vector-icons/icon icon (tabs.styles/icon active?)] :accessibility-label accessibility-label}
(when count [react/view {:style tabs.styles/tab-container}
(cond [react/view {:style tabs.styles/icon-container}
(or (pos? count) (pos? (:other count))) [vector-icons/icon icon (tabs.styles/icon active?)]
[react/view {:style (if (= nav-stack :chat-stack) (when count
tabs.styles/message-counter (cond
tabs.styles/counter)} (or (pos? count) (pos? (:other count)))
[badge/message-counter (or (:other count) count) true]] [react/view {:style (if (= nav-stack :chat-stack)
(pos? (:public count)) tabs.styles/message-counter
[react/view {:style tabs.styles/counter-public-container} tabs.styles/counter)}
[react/view {:style tabs.styles/counter-public [badge/message-counter (or (:other count) count) true]]
:accessibility-label :public-unread-badge}]]))] (pos? (:public count))
(when-not platform/desktop? [react/view {:style tabs.styles/counter-public-container}
[react/view {:style tabs.styles/tab-title-container} [react/view {:style tabs.styles/counter-public
[react/text {:style (tabs.styles/tab-title active?)} :accessibility-label :public-unread-badge}]]))]
label]])]]))) (when-not platform/desktop?
[react/view {:style tabs.styles/tab-title-container}
[react/text {:style (tabs.styles/tab-title active?)}
label]])]]])))
(defn tabs [] (defn tabs []
(let [listeners (atom []) (let [listeners (atom [])
keyboard-shown? (reagent/atom false)] keyboard-shown? (reagent/atom false)
keyboard-visible (animation/create-value 0)]
(reagent/create-class (reagent/create-class
{:component-did-mount {:component-did-mount
(fn [] (fn []
@@ -106,10 +104,20 @@
listeners listeners
[(.addListener react/keyboard "keyboardDidShow" [(.addListener react/keyboard "keyboardDidShow"
(fn [] (fn []
(reset! keyboard-shown? true))) (reset! keyboard-shown? true)
(reagent/flush)
(animation/start
(animation/timing keyboard-visible
{:toValue 1
:duration 200}))))
(.addListener react/keyboard "keyboardDidHide" (.addListener react/keyboard "keyboardDidHide"
(fn [] (fn []
(reset! keyboard-shown? false)))]))) (animation/start
(animation/timing keyboard-visible
{:toValue 0
:duration 200})
#(do (reset! keyboard-shown? false)
(reagent/flush)))))])))
:component-will-unmount :component-will-unmount
(fn [] (fn []
(when (not-empty @listeners) (when (not-empty @listeners)
@@ -118,25 +126,24 @@
(.remove listener))))) (.remove listener)))))
:reagent-render :reagent-render
(fn [{:keys [navigate index inset]}] (fn [{:keys [navigate index inset]}]
[react/animated-view {:style (tabs.styles/tabs-wrapper @keyboard-shown? @minimized-state inset)} [react/animated-view {:style (tabs.styles/tabs-wrapper @keyboard-shown? keyboard-visible)
[react/animated-view {:style (tabs.styles/animated-container visible?)} :pointer-events (if @keyboard-shown? "none" "auto")}
[react/view [react/animated-view {:style (tabs.styles/space-handler inset)
{:style tabs.styles/tabs-container} :pointer-events "none"}]
[react/view {:style tabs.styles/tabs} [react/animated-view {:style (tabs.styles/animated-container visible-native inset)}
(for [[route-index (for [[route-index
{:keys [nav-stack accessibility-label count-subscription content]}] {:keys [nav-stack accessibility-label count-subscription content]}]
tabs-list-data tabs-list-data
:let [{:keys [icon title]} content]]
:let [{:keys [icon title]} content]] ^{:key nav-stack}
^{:key nav-stack} [tab
[tab {:icon icon
{:icon icon :label title
:label title :on-press #(navigate (name nav-stack))
:on-press #(navigate (name nav-stack)) :accessibility-label accessibility-label
:accessibility-label accessibility-label :count-subscription count-subscription
:count-subscription count-subscription :active? (= (str index) (str route-index))
:active? (= (str index) (str route-index)) :nav-stack nav-stack}])]
:nav-stack nav-stack}])]]]
[react/view [react/view
{:style (tabs.styles/ios-titles-cover inset)}]])}))) {:style (tabs.styles/ios-titles-cover inset)}]])})))
+31 -31
View File
@@ -15,7 +15,7 @@
(def tabs-diff (- tabs-height minimized-tabs-height)) (def tabs-diff (- tabs-height minimized-tabs-height))
(def minimized-tab-ratio (def minimized-tab-ratio
(/ minimized-tabs-height tabs-height)) (/ tabs-height minimized-tabs-height))
(def counter (def counter
{:right 0 {:right 0
@@ -81,30 +81,23 @@
{:color (if active? colors/blue colors/gray) {:color (if active? colors/blue colors/gray)
:font-size 11}) :font-size 11})
(styles/def tabs-container (defn animated-container [visible? inset]
{:height minimized-tabs-height {:flex-direction :row
:align-self :stretch :shadow-radius 4
:shadow-offset {:width 0 :height -5}
:shadow-opacity 0.3
:shadow-color "rgba(0, 9, 26, 0.12)"
:elevation 8
:background-color :white :background-color :white
:ios {:shadow-radius 4 :position :absolute
:shadow-offset {:width 0 :height -5} :left 0
:shadow-opacity 0.3 :right 0
:shadow-color "rgba(0, 9, 26, 0.12)"} :height tabs-height
:desktop {:background-color :white :bottom inset
:shadow-radius 4 :transform [{:translateY
:shadow-offset {:width 0 :height -5} (animation/interpolate visible?
:shadow-opacity 0.3 {:inputRange [0 1]
:shadow-color "rgba(0, 9, 26, 0.12)"}}) :outputRange [0 tabs-diff]})}]})
(def tabs
{:align-self :stretch
:padding-horizontal 8
:flex-direction :row})
(defn animated-container [visible?]
{:transform [{:translateY
(animation/interpolate visible?
{:inputRange [0 1]
:outputRange [(- tabs-diff) 0]})}]})
(defn ios-titles-cover [inset] (defn ios-titles-cover [inset]
{:background-color :white {:background-color :white
@@ -115,11 +108,18 @@
:right 0 :right 0
:left 0}) :left 0})
(defn tabs-wrapper [keyboard minimized inset] (defn tabs-wrapper [keyboard visible]
(merge {:padding-bottom inset (merge {:padding-horizontal 8
:elevation 8 :elevation 8
:padding-top (if minimized 0 tabs-diff) :left 0
:background-color :white} :right 0
:bottom 0
:transform [{:translateY
(animation/interpolate visible
{:inputRange [0 1]
:outputRange [0 tabs-height]})}]}
(when keyboard (when keyboard
{:position :absolute {:position :absolute})))
:bottom (- tabs-height)})))
(defn space-handler [inset]
{:height (+ inset minimized-tabs-height)})
+6 -2
View File
@@ -4,7 +4,6 @@
[clojure.string :as string] [clojure.string :as string]
[re-frame.core :as re-frame] [re-frame.core :as re-frame]
[status-im.i18n :as i18n] [status-im.i18n :as i18n]
[status-im.ui.components.tabbar.styles :as main-tabs.styles]
[status-im.ui.components.styles :as components.styles] [status-im.ui.components.styles :as components.styles]
[status-im.constants :as constants] [status-im.constants :as constants]
[status-im.utils.platform :as utils.platform] [status-im.utils.platform :as utils.platform]
@@ -112,7 +111,12 @@
:label :t/invite-friends}])]) :label :t/invite-friends}])])
(views/defview bottom-container [{:keys [on-press disabled label accessibility-label]}] (views/defview bottom-container [{:keys [on-press disabled label accessibility-label]}]
[react/view {:style main-tabs.styles/tabs-container} [react/view {:style {:height 52
:elevation 8
:shadow-radius 4
:shadow-offset {:width 0 :height -5}
:shadow-opacity 0.3
:shadow-color "rgba(0, 9, 26, 0.12)"}}
[react/view {:style components.styles/flex}] [react/view {:style components.styles/flex}]
[react/view {:style styles/bottom-container} [react/view {:style styles/bottom-container}
[components.common/bottom-button [components.common/bottom-button
+6 -3
View File
@@ -4,7 +4,6 @@
[status-im.i18n :as i18n] [status-im.i18n :as i18n]
[reagent.core :as reagent] [reagent.core :as reagent]
[clojure.string :as string] [clojure.string :as string]
[status-im.ui.components.tabbar.styles :as main-tabs.styles]
[status-im.ui.components.colors :as colors] [status-im.ui.components.colors :as colors]
[status-im.ui.components.icons.vector-icons :as icons] [status-im.ui.components.icons.vector-icons :as icons]
[status-im.utils.platform :as utils.platform] [status-im.utils.platform :as utils.platform]
@@ -52,8 +51,12 @@
(defn footer [syncing] (defn footer [syncing]
[react/touchable-highlight {:on-press (when-not @syncing [react/touchable-highlight {:on-press (when-not @syncing
synchronize-installations!) synchronize-installations!)
;; TODO: Inspect the need of coupling with tabbar here :style {:height 52
:style main-tabs.styles/tabs-container} :elevation 8
:shadow-radius 4
:shadow-offset {:width 0 :height -5}
:shadow-opacity 0.3
:shadow-color "rgba(0, 9, 26, 0.12)"}}
[react/view [react/view
{:style styles/footer-content} {:style styles/footer-content}
[react/text [react/text
@@ -1,7 +1,8 @@
(ns status-im.ui.screens.routing.browser-stack (ns status-im.ui.screens.routing.browser-stack
(:require [status-im.ui.screens.routing.core :as navigation] (:require [status-im.ui.screens.routing.core :as navigation]
[status-im.ui.screens.browser.open-dapp.views :as open-dapp] [status-im.ui.screens.browser.open-dapp.views :as open-dapp]
[status-im.ui.screens.browser.views :as browser])) [status-im.ui.screens.browser.views :as browser]
[status-im.ui.components.tabbar.styles :as tabbar.styles]))
(defonce stack (navigation/create-stack)) (defonce stack (navigation/create-stack))
@@ -9,6 +10,7 @@
[stack {:initial-route-name :open-dapp [stack {:initial-route-name :open-dapp
:header-mode :none} :header-mode :none}
[{:name :open-dapp [{:name :open-dapp
:style {:padding-bottom tabbar.styles/tabs-diff}
:component open-dapp/open-dapp} :component open-dapp/open-dapp}
{:name :browser {:name :browser
:back-handler :noop :back-handler :noop
@@ -7,6 +7,7 @@
[status-im.ui.screens.profile.group-chat.views :as profile.group-chat] [status-im.ui.screens.profile.group-chat.views :as profile.group-chat]
[status-im.chat.models.loading :as chat.loading] [status-im.chat.models.loading :as chat.loading]
[status-im.ui.screens.group.events :as group.events] [status-im.ui.screens.group.events :as group.events]
[status-im.ui.components.tabbar.styles :as tabbar.styles]
[status-im.ui.screens.stickers.views :as stickers])) [status-im.ui.screens.stickers.views :as stickers]))
(defonce stack (navigation/create-stack)) (defonce stack (navigation/create-stack))
@@ -16,6 +17,7 @@
:header-mode :none} :header-mode :none}
[{:name :home [{:name :home
:on-focus [::chat.loading/offload-all-messages] :on-focus [::chat.loading/offload-all-messages]
:style {:padding-bottom tabbar.styles/tabs-diff}
:component home/home} :component home/home}
{:name :chat {:name :chat
:on-focus [::chat.loading/load-messages] :on-focus [::chat.loading/load-messages]
+8 -3
View File
@@ -45,14 +45,19 @@
(remove-back-handler-listener "hardwareBackPress" on-back-press)))) (remove-back-handler-listener "hardwareBackPress" on-back-press))))
#js []))) #js [])))
(defn wrapped-screen-style [{:keys [insets]} insets-obj] (defn wrapped-screen-style [{:keys [insets style]} insets-obj]
(merge (merge
{:background-color :white {:background-color :white
:flex 1} :flex 1}
style
(when (get insets :bottom) (when (get insets :bottom)
{:padding-bottom (oget insets-obj "bottom")}) {:padding-bottom (+ (oget insets-obj "bottom")
(get style :padding-bottom)
(get style :padding-vertical))})
(when (get insets :top true) (when (get insets :top true)
{:padding-top (oget insets-obj "top")}))) {:padding-top (+ (oget insets-obj "top")
(get style :padding-top)
(get style :padding-vertical))})))
(defn presentation-type [{:keys [transition] :as opts}] (defn presentation-type [{:keys [transition] :as opts}]
(if (and platform/ios? (= transition :presentation-ios)) (if (and platform/ios? (= transition :presentation-ios))
@@ -35,6 +35,7 @@
[status-im.ui.screens.profile.tribute-to-talk.views :as tr-to-talk] [status-im.ui.screens.profile.tribute-to-talk.views :as tr-to-talk]
[status-im.ui.screens.hardwallet.pin.views :as hardwallet.pin] [status-im.ui.screens.hardwallet.pin.views :as hardwallet.pin]
[status-im.ui.screens.hardwallet.settings.views :as hardwallet.settings] [status-im.ui.screens.hardwallet.settings.views :as hardwallet.settings]
[status-im.ui.components.tabbar.styles :as tabbar.styles]
[status-im.ui.screens.routing.core :as navigation])) [status-im.ui.screens.routing.core :as navigation]))
(defonce stack (navigation/create-stack)) (defonce stack (navigation/create-stack))
@@ -43,6 +44,7 @@
[stack {:initial-route-name :my-profile [stack {:initial-route-name :my-profile
:header-mode :none} :header-mode :none}
[{:name :my-profile [{:name :my-profile
:style {:padding-bottom tabbar.styles/tabs-diff}
:component profile.user/my-profile} :component profile.user/my-profile}
{:name :contacts-list {:name :contacts-list
:component contacts-list/contacts-list} :component contacts-list/contacts-list}
@@ -10,6 +10,7 @@
[status-im.ui.screens.wallet.add-new.views :as add-account] [status-im.ui.screens.wallet.add-new.views :as add-account]
[status-im.ui.screens.wallet.account-settings.views :as account-settings] [status-im.ui.screens.wallet.account-settings.views :as account-settings]
[status-im.ui.screens.wallet.events :as wallet.events] [status-im.ui.screens.wallet.events :as wallet.events]
[status-im.ui.components.tabbar.styles :as tabbar.styles]
[status-im.ui.screens.routing.core :as navigation])) [status-im.ui.screens.routing.core :as navigation]))
(defonce stack (navigation/create-stack)) (defonce stack (navigation/create-stack))
@@ -18,6 +19,7 @@
[stack {:initial-route-name :wallet [stack {:initial-route-name :wallet
:header-mode :none} :header-mode :none}
[{:name :wallet [{:name :wallet
:style {:padding-bottom tabbar.styles/tabs-diff}
:component wallet.accounts/accounts-overview} :component wallet.accounts/accounts-overview}
{:name :wallet-account {:name :wallet-account
:component wallet.account/account} :component wallet.account/account}
+1 -2
View File
@@ -32,10 +32,9 @@
(cond (cond
(and (string/starts-with? hex "0xe40101")) (and (string/starts-with? hex "0xe40101"))
;; content type can be 2 or 4 bytes ;; content type can be 2 or 4 bytes
;; we expect 1b20 (hash algorithm and hash length 64) ;; we expect 1b20 (hash algorithm keccak256 and hash length 64)
;; before the hash so we split the contenthash there ;; before the hash so we split the contenthash there
(when-let [hash (second (string/split hex "1b20"))] (when-let [hash (second (string/split hex "1b20"))]
(when (= 0x20 (count hash)))
{:namespace :swarm {:namespace :swarm
:hash hash}) :hash hash})
(and (= 78 (count hex)) (and (= 78 (count hex))
+2 -2
View File
@@ -34,7 +34,7 @@
{:method "eth_getBalance" {:method "eth_getBalance"
:params [address "latest"] :params [address "latest"]
:on-success on-success :on-success on-success
:number-of-retries 4 :number-of-retries 50
:on-error on-error})) :on-error on-error}))
(re-frame/reg-fx (re-frame/reg-fx
@@ -180,7 +180,7 @@
(json-rpc/call (json-rpc/call
{:method "wallet_getTokensBalances" {:method "wallet_getTokensBalances"
:params [addresses (keys tokens)] :params [addresses (keys tokens)]
:number-of-retries 4 :number-of-retries 50
:on-success :on-success
(fn [results] (fn [results]
(when-let [balances (clean-up-results results tokens (if init? nil assets))] (when-let [balances (clean-up-results results tokens (if init? nil assets))]
+3 -3
View File
@@ -2,7 +2,7 @@
"_comment": "DO NOT EDIT THIS FILE BY HAND. USE 'scripts/update-status-go.sh <tag>' instead", "_comment": "DO NOT EDIT THIS FILE BY HAND. USE 'scripts/update-status-go.sh <tag>' instead",
"owner": "status-im", "owner": "status-im",
"repo": "status-go", "repo": "status-go",
"version": "v0.49.0", "version": "v0.50.2",
"commit-sha1": "d7bb02540a4356fb507a08ed73491c659b076fb1", "commit-sha1": "44272944abeb3c32cc0ca6b089e783cb530037d4",
"src-sha256": "0i6s085qq67aiyzjs2lrjfnaqvbh1v1jxdsi84c176y150lwb8lw" "src-sha256": "1n6fsqnxpbn5srdxg37iqpw57xipfxan3sh35aa3vg8y9dhns1cn"
} }
@@ -67,3 +67,5 @@
(def react-navigation-stack #js {:createStackNavigator identity (def react-navigation-stack #js {:createStackNavigator identity
:TransitionPresets #js {:ModalPresentationIOS #js {}}}) :TransitionPresets #js {:ModalPresentationIOS #js {}}})
(def react-navigation-bottom-tabs #js {:createBottomTabNavigator identity}) (def react-navigation-bottom-tabs #js {:createBottomTabNavigator identity})
(def react-native-gesture-handler #js {})
@@ -9,3 +9,11 @@
(ens/namehash "eth"))) (ens/namehash "eth")))
(is (= "0xde9b09fd7c5f901e23a3f19fecc54828e9c848539801e86591bd9801b019f84f" (is (= "0xde9b09fd7c5f901e23a3f19fecc54828e9c848539801e86591bd9801b019f84f"
(ens/namehash "foo.eth")))) (ens/namehash "foo.eth"))))
(deftest cleanup-hash
;; simpledapp.eth
(is (= "0xe30101701220795c1ea0ceaf4ceedc9896f14b73bb30e978e4855ee221b9a57f5a934268280e"
(ens/cleanup-hash "0x00000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000026e30101701220795c1ea0ceaf4ceedc9896f14b73bb30e978e4855ee221b9a57f5a934268280e0000000000000000000000000000000000000000000000000000")))
;; ethereum.eth
(is (= "0xe301017012206e70f0f72e2bcd0ad69bb2b15ee9e0f4f88693f6b2f485e48699e7d6f8dbd62a"
(ens/cleanup-hash "0x00000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000026e301017012206e70f0f72e2bcd0ad69bb2b15ee9e0f4f88693f6b2f485e48699e7d6f8dbd62a0000000000000000000000000000000000000000000000000000"))))