re add progress root and popover overlay (#19241)

This commit is contained in:
Parvesh Monu 2024-03-14 16:48:08 +05:30 committed by GitHub
parent aab62dd19e
commit bccf0f8d11
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
4 changed files with 37 additions and 3 deletions

View File

@ -28,7 +28,8 @@
[{:keys [db] :as cofx} {:keys [auth-method logout?]}]
(let [key-uid (get-in db [:profile/profile :key-uid])]
(rf/merge cofx
{:effects.shell/reset-state nil
{:set-root :progress
:effects.shell/reset-state nil
:hide-popover nil
::logout nil
:profile.settings/webview-debug-changed false

View File

@ -106,4 +106,9 @@
(navigation/register-component
"bottom-sheet-old"
(fn [] (gesture/gesture-handler-root-hoc views/sheet-comp-old))
(fn [] views/sheet-comp-old)))
(fn [] views/sheet-comp-old))
(navigation/register-component
"popover"
(fn [] (gesture/gesture-handler-root-hoc views/popover-comp))
(fn [] views/popover-comp)))

View File

@ -14,7 +14,7 @@
:profiles constants/theme-type-dark
:shell-stack nil})
(defn roots
(defn roots-internal
[]
{:intro
{:root
@ -49,3 +49,19 @@
{:root {:stack {:children [{:component {:name :syncing-results
:id :syncing-results
:options (options/dark-root-options)}}]}}}})
(defn old-roots
[]
{:progress
{:root {:stack {:children [{:component {:name :progress
:id :progress
:options (options/root-options nil)}}]
:options (assoc (options/root-options nil)
:topBar
{:visible false})}}}})
(defn roots
[]
(merge
(old-roots)
(roots-internal)))

View File

@ -1,6 +1,7 @@
(ns status-im.navigation.view
(:require
[legacy.status-im.bottom-sheet.sheets :as bottom-sheets-old]
[legacy.status-im.ui.screens.popover.views :as popover]
[quo.foundations.colors :as colors]
[quo.theme :as theme]
[react-native.core :as rn]
@ -125,3 +126,14 @@
[inactive]
[bottom-sheets-old/bottom-sheet]])
functional-compiler))
(def popover-comp
(reagent/reactify-component
(fn []
^{:key (str "popover" @reloader/cnt)}
[:<>
[inactive]
[popover/popover]
(when js/goog.DEBUG
[reloader/reload-view])])
functional-compiler))