Skip to content

Commit

Permalink
[#9636] Remove chat menu item and toggle app switching privacy on by …
Browse files Browse the repository at this point in the history
…default
  • Loading branch information
flexsurfer committed Dec 12, 2019
1 parent 6a800b2 commit 80ecd04
Show file tree
Hide file tree
Showing 15 changed files with 14 additions and 129 deletions.
2 changes: 1 addition & 1 deletion src/status_im/constants.cljs
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@
(merge testnet-networks mainnet-networks sidechain-networks))

(def default-multiaccount-settings
{:preview-privacy? false
{:preview-privacy? true
:wallet {:visible-tokens {}}})

(def currencies
Expand Down
5 changes: 5 additions & 0 deletions src/status_im/multiaccounts/core.cljs
Original file line number Diff line number Diff line change
Expand Up @@ -139,3 +139,8 @@
(multiaccounts.update/update-settings
(assoc settings :preview-privacy? private?)
{}))))

(fx/defn switch-preview-privacy-mode-flag
[{:keys [db]}]
(let [private? (get-in db [:multiaccount :settings :preview-privacy?])]
{::blank-preview-flag-changed private?}))
7 changes: 5 additions & 2 deletions src/status_im/multiaccounts/login/core.cljs
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,8 @@
[status-im.utils.identicon :as identicon]
[status-im.ethereum.eip55 :as eip55]
[status-im.popover.core :as popover]
[status-im.hardwallet.nfc :as nfc]))
[status-im.hardwallet.nfc :as nfc]
[status-im.multiaccounts.core :as multiaccounts]))

(def rpc-endpoint "https://goerli.infura.io/v3/f315575765b14720b32382a61a89341a")
(def contract-address "0xfbf4c8e2B41fAfF8c616a0E49Fb4365a5355Ffaf")
Expand Down Expand Up @@ -177,7 +178,8 @@
(contact/initialize-contacts)
(stickers/init-stickers-packs)
(mobile-network/on-network-status-change)
(chaos-mode/check-chaos-mode))))
(chaos-mode/check-chaos-mode)
(multiaccounts/switch-preview-privacy-mode-flag))))

(defn get-new-auth-method [auth-method save-password?]
(if save-password?
Expand Down Expand Up @@ -252,6 +254,7 @@
:mailserver-topics {}
:default-mailserver true})
(chaos-mode/check-chaos-mode)
(multiaccounts/switch-preview-privacy-mode-flag)
(when-not platform/desktop?
(initialize-wallet nil)))))

Expand Down
5 changes: 0 additions & 5 deletions src/status_im/ui/screens/add_new/db.cljs

This file was deleted.

9 changes: 0 additions & 9 deletions src/status_im/ui/screens/add_new/events.cljs

This file was deleted.

20 changes: 0 additions & 20 deletions src/status_im/ui/screens/add_new/models.cljs

This file was deleted.

55 changes: 0 additions & 55 deletions src/status_im/ui/screens/add_new/views.cljs

This file was deleted.

2 changes: 0 additions & 2 deletions src/status_im/ui/screens/db.cljs
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
status-im.mailserver.db
status-im.ens.db
status-im.browser.db
status-im.ui.screens.add-new.db
status-im.ui.screens.add-new.new-public-chat.db
status-im.ui.components.bottom-sheet.core
[status-im.wallet.db :as wallet.db]))
Expand Down Expand Up @@ -211,7 +210,6 @@
:universal-links/url
:browser/browsers
:browser/options
:new/open-dapp
:navigation/screen-params
:chat/cooldowns
:chat/cooldown-enabled?
Expand Down
1 change: 0 additions & 1 deletion src/status_im/ui/screens/events.cljs
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
(ns status-im.ui.screens.events
(:require status-im.events
status-im.ui.screens.add-new.events
status-im.ui.screens.add-new.new-chat.events
status-im.ui.screens.group.chat-settings.events
status-im.ui.screens.group.events
Expand Down
12 changes: 2 additions & 10 deletions src/status_im/ui/screens/home/sheet/views.cljs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
(ns status-im.ui.screens.home.sheet.views
(:require-macros [status-im.utils.views :refer [defview letsubs] :as views])
(:require-macros [status-im.utils.views :refer [defview letsubs]])
(:require [re-frame.core :as re-frame]
[status-im.i18n :as i18n]
[status-im.ui.components.colors :as colors]
Expand Down Expand Up @@ -34,14 +34,6 @@
:accessibility-label :join-public-chat-button
:icon :main-icons/public-chat
:on-press #(hide-sheet-and-dispatch [:navigate-to :new-public-chat])}]
[list-item/list-item
{:theme :action
:title :t/scan-qr
:accessibility-label :scan-qr-code-button
:icon :main-icons/qr
:on-press #(hide-sheet-and-dispatch [:qr-scanner.ui/scan-qr-code-pressed
{:title (i18n/label :t/scan-qr)
:handler :handle-qr-code}])}]
[list-item/list-item
{:theme :action
:title :t/invite-friends
Expand Down Expand Up @@ -110,7 +102,7 @@

(def add-new
{:content add-new-view
:content-height 320})
:content-height 280})

(def public-chat-actions
{:content public-chat-actions-view
Expand Down
1 change: 0 additions & 1 deletion src/status_im/ui/screens/routing/chat_stack.cljs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
:chat
:select-chat
:profile
:new
:take-picture
:new-group
:add-participants-toggle-list
Expand Down
2 changes: 0 additions & 2 deletions src/status_im/ui/screens/routing/screens.cljs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
[status-im.ui.screens.multiaccounts.views :as multiaccounts]
[status-im.ui.screens.add-new.new-chat.views :as new-chat]
[status-im.ui.screens.add-new.new-public-chat.view :as new-public-chat]
[status-im.ui.screens.add-new.views :as add-new]
[status-im.ui.screens.bootnodes-settings.edit-bootnode.views
:as
edit-bootnode]
Expand Down Expand Up @@ -119,7 +118,6 @@
:chat chat/chat
:select-chat chat/select-chat
:profile profile.contact/profile
:new add-new/add-new
:new-chat [:modal new-chat/new-chat]
:qr-scanner [:modal qr-scanner/qr-scanner]
:new-group group/new-group
Expand Down
2 changes: 0 additions & 2 deletions test/cljs/status_im/test/runner.cljs
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@
[status-im.test.tribute-to-talk.core]
[status-im.test.tribute-to-talk.db]
[status-im.test.tribute-to-talk.whitelist]
[status-im.test.ui.screens.add-new.models]
[status-im.test.ui.screens.currency-settings.models]
[status-im.test.ui.screens.wallet.db]
[status-im.test.utils.async]
Expand Down Expand Up @@ -114,7 +113,6 @@
'status-im.test.tribute-to-talk.core
'status-im.test.tribute-to-talk.db
'status-im.test.tribute-to-talk.whitelist
'status-im.test.ui.screens.add-new.models
'status-im.test.ui.screens.currency-settings.models
'status-im.test.ui.screens.wallet.db
'status-im.test.utils.async
Expand Down
18 changes: 0 additions & 18 deletions test/cljs/status_im/test/ui/screens/add-new/models.cljs

This file was deleted.

2 changes: 1 addition & 1 deletion translations/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -508,7 +508,7 @@
"help": "help",
"help-capitalized": "Help",
"help-center": "Help Center",
"hide-content-when-switching-apps": "Hide content when switching apps",
"hide-content-when-switching-apps": "White out Status when switching apps",
"history": "History",
"hold-card": "Hold card to the back\n of your phone",
"home": "Home",
Expand Down

0 comments on commit 80ecd04

Please sign in to comment.