[Fixes #8001] Fixes white flash on Android

Signed-off-by: Igor Mandrigin <i@mandrigin.ru>
This commit is contained in:
Julien Eluard 2019-04-23 13:50:04 +02:00 committed by Igor Mandrigin
parent c98f547349
commit bdb672e131
No known key found for this signature in database
GPG Key ID: 4A0EDDE26E66BC8B
2 changed files with 23 additions and 28 deletions

View File

@ -3,18 +3,13 @@
(:require [status-im.ui.components.colors :as colors] (:require [status-im.ui.components.colors :as colors]
[status-im.ui.components.styles :as styles])) [status-im.ui.components.styles :as styles]))
(def input-container (defstyle input
{:flex-direction :row {:border-radius styles/border-radius
:align-items :center
:border-radius styles/border-radius
:height 36
:background-color colors/gray-lighter :background-color colors/gray-lighter
:margin-horizontal 16 :margin-horizontal 16
:margin-bottom 9 :margin-bottom 9
:margin-top 24}) :margin-top 24
:height 36
(defstyle input
{:flex 1
:padding-horizontal 14 :padding-horizontal 14
:desktop {:height 30 :desktop {:height 30
:width "100%"} :width "100%"}

View File

@ -50,7 +50,6 @@
url-text (atom nil)] url-text (atom nil)]
[react/keyboard-avoiding-view {:style {:flex 1}} [react/keyboard-avoiding-view {:style {:flex 1}}
[status-bar/status-bar] [status-bar/status-bar]
[react/view styles/input-container
[react/text-input {:on-change-text #(reset! url-text %) [react/text-input {:on-change-text #(reset! url-text %)
:on-submit-editing #(re-frame/dispatch [:browser.ui/dapp-url-submitted @url-text]) :on-submit-editing #(re-frame/dispatch [:browser.ui/dapp-url-submitted @url-text])
:placeholder (i18n/label :t/enter-url) :placeholder (i18n/label :t/enter-url)
@ -58,15 +57,16 @@
:auto-correct false :auto-correct false
:style styles/input :style styles/input
:accessibility-label :dapp-url-input :accessibility-label :dapp-url-input
:return-key-type :go}]] :return-key-type :go}]
[components/separator] [components/separator]
(if (empty? browsers) (if (empty? browsers)
[list-header true] [list-header true]
[list/flat-list {:header [list-header false] [react/scroll-view
:data browsers [list-header false]
[list/flat-list {:data browsers
:footer [react/view :footer [react/view
{:style {:height tabs.styles/tabs-diff {:style {:height tabs.styles/tabs-diff
:align-self :stretch}}] :align-self :stretch}}]
:key-fn :browser-id :key-fn :browser-id
:end-fill-color colors/white :end-fill-color colors/white
:render-fn list-item}])])) :render-fn list-item}]])]))