From 4654402feb2c3c3ebbb45d2f5014c6b1324ceaac Mon Sep 17 00:00:00 2001 From: andrey Date: Tue, 15 Nov 2022 06:56:33 +0100 Subject: [PATCH] new structure fixes --- src/status_im/ui/screens/screens.cljs | 13 ------------- src/status_im2/navigation/screens.cljs | 16 ++++++++++++++-- src/status_im2/setup/hot_reload.cljs | 4 +++- src/status_im2/subs/home.cljs | 2 +- 4 files changed, 18 insertions(+), 17 deletions(-) diff --git a/src/status_im/ui/screens/screens.cljs b/src/status_im/ui/screens/screens.cljs index f854562f96..e4d26661c1 100644 --- a/src/status_im/ui/screens/screens.cljs +++ b/src/status_im/ui/screens/screens.cljs @@ -209,19 +209,6 @@ :component onboarding.phrase/wizard-recovery-success} ;;CHAT - - ;Home - {:name :home - :component (if config/new-ui-enabled? chat.home/home old-chat.home/home-old)} - - ;Chat - {:name :chat - :options {:popGesture false - :hardwareBackButton {:dismissModalOnPress false - :popStackOnPress false} - :topBar {:visible false}} - :component chat/chat} - ;Pinned messages {:name :chat-pinned-messages ;TODO custom subtitle diff --git a/src/status_im2/navigation/screens.cljs b/src/status_im2/navigation/screens.cljs index e9f4ed5dfd..1e944642e9 100644 --- a/src/status_im2/navigation/screens.cljs +++ b/src/status_im2/navigation/screens.cljs @@ -1,6 +1,8 @@ (ns status-im2.navigation.screens (:require [status-im2.setup.config :as config] [status-im.ui2.screens.quo2-preview.main :as quo2.preview] + [status-im.ui2.screens.chat.home :as chat.home] + [status-im.ui2.screens.chat.view :as chat] [status-im.ui2.screens.communities.discover-communities :as discover-communities] ;; TODO (14/11/22 flexsurfer) move to status-im2 namespace @@ -11,16 +13,26 @@ []) (defn screens [] - (concat [{:name :shell-stack + (concat (old-screens/screens) + + [{:name :shell-stack :insets {:top false} :component shell-stack/shell-stack} + {:name :home + :component chat.home/home} + + {:name :chat + :options {:topBar {:visible false}} + :component chat/chat} + {:name :discover-communities ;;TODO animated-header scroll behaviours :options {:topBar {:visible false}} :component discover-communities/communities}] - (old-screens/screens) + (when config/quo-preview-enabled? quo2.preview/screens) + (when config/quo-preview-enabled? quo2.preview/main-screens))) diff --git a/src/status_im2/setup/hot_reload.cljs b/src/status_im2/setup/hot_reload.cljs index 3778cc4add..3f82a68ce4 100644 --- a/src/status_im2/setup/hot_reload.cljs +++ b/src/status_im2/setup/hot_reload.cljs @@ -50,6 +50,8 @@ [rn/view {:pointerEvents :none :style {:position :absolute :top 0 :left 0 :right 0 :bottom 0 :justify-content :center :align-items :center}} - [rn/view {:width 64 :height 64 :background-color :blue}] + [rn/view {:width 64 :height 64 :background-color "#0000FF30" :border-radius 32 + :justify-content :center :align-items :center} + [rn/activity-indicator {:animating true}]] [rn/text {:style {:margin-top 10 :color (if @warning? :red :black)}} @label]]))) diff --git a/src/status_im2/subs/home.cljs b/src/status_im2/subs/home.cljs index 0584c7b8cc..673bacc050 100644 --- a/src/status_im2/subs/home.cljs +++ b/src/status_im2/subs/home.cljs @@ -13,7 +13,7 @@ :<- [:home-items-show-number] (fn [[search-filter filtered-chats communities view-id home-items-show-number]] (if (or (= view-id :home) - (and config/new-ui-enabled? (= view-id :chat-stack))) + (and config/new-ui-enabled? (= view-id :shell-stack))) (let [communities-count (count communities) chats-count (count filtered-chats) ;; If we have both communities & chats we want to display